NOTE: I use _ to represent U+00AD, the conditional hyphen.
In my css I have
body { hyphens:auto; }
<
https://drafts.csswg.org/css-text/#valdef-hyphens-auto> says
"Automatic hyphenation opportunities elsewhere WITHIN A WORD must be
ignored if the word contains a conditional hyphen. ... [emphasis
added]"
I don't know whether "within a word" is meant to include placing a
conditional hyphen immediately before the first character of a word.
If it is, that would make that word automatically hyphens:none, and
one character is obviously shorter than <span class="..."> ...
</span>
Firefox (for several years now) does treat a leading conditional
hyphen that way, and doesn't auto-hyphenate the word. For instance,
"personal" breaks as "per- sonal"
"_personal" goes to the next line as "personal"
"person_al" goes to the next line as "personal"
Chrome (the current version), however, just ignores the leading
conditional hyphen though it does follow the spec for a conditional
hyphen somewhere between the first and last characters of the word.
For instance,
"personal" breaks as "per- sonal"
"_personal" breaks as "per- sonal"
"person_al" goes to the next line as "personal"
Is Chrome wrong here, or is a leading conditional hyphen not within
the meaning of "Within a word" and UAs get to make up their own
minds?
(For those who may be wondering, the documents I'm preparing are not
on the Web, but have a restricted audience where I can be sure that
everyone's PC has the font I specify, and it's not important if they
don't see hyphenation on their phones.)
--
Stan Brown, Tehachapi, California, USA
https://BrownMath.com/