Closed Malvoz closed 5 years ago
from https://github.com/w3c/html/issues/1333#issuecomment-378751253
The mentioned writing-mode is set by CSS. Does that mean that CSS needs to be loaded to compute these properties correctly? Does the use case still hold then?
from https://github.com/w3c/html/issues/1333#issuecomment-383205057
That is a good point, which makes me wonder why there is no writing-mode attribute.
@Malvoz What writing-mode attribute would that be?
@r12a a new HTML attribute ( writing-mode="vertical-lr"
etc.) to allow authors to specify the writing-mode
.
Having an HTML attribute also means writing-mode
isn't affected if a CSS file fails to load. I read and write horizontal-tb
, so others may have more use-cases for such an attribute.
My knee-jerk reaction is to think that this is bringing back presentational markup, and therefore bringing back the issues that led us to remove width and height attributes from html previously. I think that content authors would start not using CSS, but relying on the HTML attributes – which is hardcoding the presentation in a way that may give short-term benefits but longer-term headaches.
I also think that you may have to use these attributes often in a document, especially one that mixes horizontal and vertical text. Using CSS you just declare the presentation once in the stylesheet and apply using classes or other selectors. I'm also dubious that content authors would be happy about adding attributes in order to shave what i presume are microseconds off the rendering.
As for your latter point about CSS not loading, i suppose it may depend on how many fancy things the content author does, but in theory the content should display fine using the horizontal layout - the verticality is only presentational styling. (And there again we come back to the difference between HTML and CSS.)
Sorry, but so far i'm not really seeing how this could work in practical terms.
@r12a
Thank you for your feedback. This isn't much of a personal desire, but there's been very little interest in this elsewhere. Closing! :)
I'm reaching out to the i18n community because I suspect you may find this WICG proposal of interest: https://discourse.wicg.io/t/logical-sizing-attributes-internationalization/2971
tl;dr
Should logical sizing:
inline-size | block-size
exist as HTML attributes in addition to thewidth
andheight
attributes for the purpose of internationalization?Thank you for your time.