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

Support code syntax highlighting in exports #5480

Open
DoctorRetromaker opened this issue Feb 9, 2025 · 0 comments
Open

Support code syntax highlighting in exports #5480

DoctorRetromaker opened this issue Feb 9, 2025 · 0 comments

Comments

@DoctorRetromaker
Copy link

DoctorRetromaker commented Feb 9, 2025

Describe the Bug

Adding <code> blocks with the internal «CodeMirror» editor result in a good highlighted render of code in standard book view; however, when the page is exported to «Contained Html File», no highlight is applied.

<code> blocks highlight isn't rendered in the «Contained html ...» and code is rendered with non-highlighted code blocks style.

Steps to Reproduce

  1. Create a simple page and add any program code of any of the supported languages
  2. After «page save», code is displayed with syntax highlight
  3. Export to «Contained Html File»
  4. Open the result HTML file and code is rendered as a code badge, without any syntax highlighting

Expected Behaviour

Get the same rendering inside BookstackApp and in the exported «Contained Html File»

Screenshots or Additional Context

No response

Browser Details

Brave 1.175.175

Exact BookStack Version

24.12.1

@DoctorRetromaker DoctorRetromaker changed the title CodeMirror blocks od code, isn't rendered correctly when exported CodeMirror code blocks, isn't rendered correctly when exported Feb 9, 2025
@ssddanbrown ssddanbrown changed the title CodeMirror code blocks, isn't rendered correctly when exported Support code syntax highlighting in exports Feb 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

2 participants