4 ms·
For a div, fit-content is already defined as the width of the longest word - that is the minimal intrinsic width of the content. Not amazingly useful, but it ca
by jahewson 3y ago
For a div, fit-content is already defined as the width of the longest word - that is the minimal intrinsic width of the content. Not amazingly useful, but it can’t be changed without breaking existing pages.
The meaning of content width gets more complex when you factor in line breaking, hyphenation and ellipsis.
- Izkata 3y ago> The meaning of content width gets more complex when you factor in line breaking, hyphenation and ellipsis. Don't forget font-face and size. It's usually not done in a noticeable way, or at all, but those can be set to anything for textareas too.