• How can I get rid of this gap at the bottom of code snippets?

    View post on imgur.com

    I already removed the margin-bottom of .enlighter-t-wpcustom but there is still quite a big gap. As you can see, I wrap the code snippets into boxes so this gap is very noticeable and doesn’t look good. How can I remove it?

    The page I need help with: [log in to see the link]

Viewing 13 replies - 1 through 13 (of 13 total)
  • Thread Starter flizzywp

    (@flizzywp)

    It seems the gap is only there for Crayon code snippets that are converted through the compatibility mode. Why is that?

    Plugin Author Andi Dittrich

    (@andi-dittrich)

    Hi @flizzywp

    this seems to be a css issue – to investigate it i need a link to a working page which shows the problem.

    maybe your crayon code is wrapped into some containers

    Thread Starter flizzywp

    (@flizzywp)

    Can you take a look at the link I provided now that I disabled Crayon? Thank you very much

    Thread Starter flizzywp

    (@flizzywp)

    Also, while we’re at it, could you tell me what is the styling attribute (in the Theme Customizer) for the annotations (like @Override)? I can’t find it.

    Plugin Author Andi Dittrich

    (@andi-dittrich)

    the issue is caused by your “tab” plugin – it adds an additional <br> element after the codeblock (into the wrapper)

    solution: remove the tab plugin and replace the tabs with native EnlighterJS codegroups

    the “@Override” statement is currently realized as token “s9” – this token has been removed in previous releases but some of the language support files (java/cpp/scala) are not updated yet. I’ll address this issue in the next release

    Thread Starter flizzywp

    (@flizzywp)

    But the space is not there when I use Crayon instead of Enlighter. And it’s also not there if I add native Enlighter snippets. It’s only there for Crayon snippets that are converted to Enlighter snippets.

    Plugin Author Andi Dittrich

    (@andi-dittrich)

    look into the markup…

    Thread Starter flizzywp

    (@flizzywp)

    It must be the Enlighter converter causing the extra <br> then. Because, again, it is not there for native snippets so it’s clearly not the tab plugin’s fault.

    Plugin Author Andi Dittrich

    (@andi-dittrich)

    i fully understand that you’re experiencing this behaviour – but i’m very sure that this is not caused by Enlighter.. Here is the source code of the compatiblity mode – https://github.com/EnlighterJS/Plugin.WordPress/blob/master/modules/compatibility/Crayon.php

    btw. can you switch back to Crayon – then i’ll take a look into it again.

    did you tried to create a testcase with the tab plugin and a standard Enlighter codeblock – i assume that this would cause the same behaviour

    Plugin Author Andi Dittrich

    (@andi-dittrich)

    the keyword k11 for annotations has been added in c9a05cb

    Thread Starter flizzywp

    (@flizzywp)

    I have Crayon enabled now if you want to take a look. I don’t know what you mean by testcase.

    • This reply was modified 4 years, 5 months ago by flizzywp.
    Plugin Author Andi Dittrich

    (@andi-dittrich)

    ok. the br tags are not there – currently i’m not sure whats happening on your site – without a lot of additional time to simulate the issue i cannot help you.

    it seems that the br tag is added by another plugin/template on your site but i cannot tell you which one. it’s not caused by Enlighter…

    —-

    testcases: create a new post including Enlighter codeblocks – with and without the tab plugin and see whats happening (br tags?)

    on your testing site (or offline), you can also try to switch the theme and disable all other plugins (one-by-one) until the issue disappears.

    Thread Starter flizzywp

    (@flizzywp)

    But I already tried adding Enlighter code blocks – they work.
    I will just go ahead and replace all Crayon code blocks for Enlighter manually.

    • This reply was modified 4 years, 5 months ago by flizzywp.
Viewing 13 replies - 1 through 13 (of 13 total)
  • The topic ‘How to get rid of the large space at the bottom?’ is closed to new replies.