3 ms·
Speaking of horizontal scrolling, I wonder what it would take to make HN verbatim text not get cut off horizontally, when viewed on mobile Safari. Anyone know i
by euroclydon 15y ago
Speaking of horizontal scrolling, I wonder what it would take to make HN verbatim text not get cut off horizontally, when viewed on mobile Safari. Anyone know if HN uses a PRE? Does mobile Safari cut off all wide text in PREs?
- uxp 15y agoIts <pre><code>foo</code></pre>. All browsers will not automatically wrap text inside pre tags, since the text inside pre is supposed to have both width and line-breaks preserved. Scroll with two fingers inside the box to view whatever has been hidden by "overflow: scroll;". If you find a site that lets pre code snippets overflow into the right sidebar and off the screen, let them know their site is unusable and to add an overflow CSS rule to make it respect smaller screen widths.
- shadowfiend 15y agoYou can also use white-space: pre-wrap to allow wrapping in preformatted text.
- aiscott 15y agoJust as an FYI, you can drag those HN verbatim/code text elements horizontally on iOS. It wasn't obvious to me because the box doesn't have an outline.