However, it only shows one line:
\n\nIs there an option to set the height to 100%? I can't override the CSS for .prism-code-editor because it's in a shadowroot.
Try adding display: grid to #code-editor. Now the editor's height will match the container. If the editor's content grows taller than the container, it will begin scrolling too. Without display: grid it will overflow out of the container instead of scrolling.
-
|
I'm using the basic setup from the README, and it's looking good: However, it only shows one line: Is there an option to set the height to 100%? I can't override the CSS for |
Beta Was this translation helpful? Give feedback.
-
|
Is my only option to use the advanced setup? https://github.com/FIameCaster/prism-code-editor?tab=readme-ov-file#advanced-usage |
Beta Was this translation helpful? Give feedback.
-
|
Try adding |
Beta Was this translation helpful? Give feedback.
Try adding
display: gridto#code-editor. Now the editor's height will match the container. If the editor's content grows taller than the container, it will begin scrolling too. Withoutdisplay: gridit will overflow out of the container instead of scrolling.