Sign in

Code Block Styling

  • This topic has 4 replies, 3 voices, and was last updated 1 month, 3 weeks ago by .
Viewing 5 posts - 1 through 5 (of 5 total)
  • Author
    Posts
  • #9746
    Avatar photov7web

    In publii back end the code blocks are styled with line numbers, dark background and whatever language the code block is in.

    When published, although the code blocks still have a class with “line-numbers language-php”  the item is not styled.

    Where is the css for “line-numbers language-php”? This appears to be the same in multiple themes.

     

     

     

    #9747
    Avatar photoBob

    To highlight the code syntax on the front end, you need to install PrismJs. This feature is exclusively available in our premium documentation themes.

    --
    Do you appreciate the support you've received today? If so, consider donating to the Publii team by clicking here; we'll be sure to use your donation to make Publii even better!

    #9749
    Avatar photov7web

    So if I buy another premium theme this is already installed?

    #9750
    Avatar photoBob

    PrismJs is only supported by the Documentation, ProDocs, and Q-Answers templates.

    --
    Do you appreciate the support you've received today? If so, consider donating to the Publii team by clicking here; we'll be sure to use your donation to make Publii even better!

    #9779
    Avatar photojwoltman

    Sometimes I write code stuff on my blog, which uses the Simple theme.  If there was a premium version of Simple that included PrismJS I would definitely pay for it.  I look through some of the live demos of the other blog-style premium themes but didn’t find one that suited me.  The documentation-style themes look really nice but I wouldn’t use them for my blog.

Viewing 5 posts - 1 through 5 (of 5 total)
  • You must be logged in to reply to this topic.