Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Help] How to turn off line wrapping in the code blocks #803

Open
3 tasks done
rednafi opened this issue Jan 21, 2022 · 0 comments
Open
3 tasks done

[Help] How to turn off line wrapping in the code blocks #803

rednafi opened this issue Jan 21, 2022 · 0 comments

Comments

@rednafi
Copy link

rednafi commented Jan 21, 2022

Mandatory Step

  • I am using the latest production release of Elegant

Recommended Step

  • I have attached a link to my blog source code repository
  • I have reproduced my pelican configuration files

I need help with turning off line wrapping in the code blocks

Currently, long lines in the code blocks get wrapped like this:

Screenshot from 2022-01-22 04-48-58

This is not very readable, especially on mobile devices. I'd like to completely turn off line wrapping in the code blocks. Longer lines should introduce a horizontal scrollbar both on pcs and phones. How do I achieve that? I've tried putting this CSS snippet in the custom.css file but it seems like it's not doing anything,

pre{
  text-align: left;
  overflow-x: scroll;
  justify-content: left;
  white-space: nowrap;
}

Thank you for your help!

@rednafi rednafi changed the title [Help] [Help] How to turn off line wrapping in the code blocks Jan 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

1 participant