cue-lang / cue

The home of the CUE language! Validate and define text-based and dynamic configuration
https://cuelang.org
Apache License 2.0
4.95k stars 279 forks source link

cuelang.org: inline code blocks are permitted to line wrap #3287

Open jpluscplusm opened 3 weeks ago

jpluscplusm commented 3 weeks ago

What page were you looking at?

https://cuelang.org/docs/howto/embed-files-in-cue-evaluation/

What version of the site were you looking at?

https://github.com/cue-lang/cuelang.org/commit/0425ac00c4d863343bbcbf59f6d137abaf6bd5e0

What did you do?

Published a page that included

`type=<filetype>`

What did you expect?

That any text inside an inline code block wouldn't wrap across lines, and would either be forced to fit on the first line, or would spill over entirely onto the next line.

What did you see instead?

On Chrome/ChromeOS (v126) the type=<filetype> is split across two lines:

image

I'm aware I could manually avoid this with a trailing backslash /before/ the type=<filetype> atom, and a newline in the Markdown source. However, @myitcv has pointed out that white-space: nowrap in CSS might be able to prevent this problem from happening thereby avoiding manual formatting needing to be placed in the source.

myitcv commented 3 weeks ago

@jpluscplusm - please can you add details of your browser user-agent in this report? Because as discussed earlier, I could not reproduce this on Mozilla/5.0 (X11; Linux aarch64; rv:109.0) Gecko/20100101 Firefox/115.0