-
Notifications
You must be signed in to change notification settings - Fork 715
[css-display-4] drafting reading-order-items issue #8589 #9845
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Only takes effect on flex containers. | ||
Follows the visual reading order of flex items, | ||
taking the writing mode into account. | ||
Therefore, a document in English, with a 'flex-direction' of 'row-reverse' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So the flex-direction
doesn't impact the reading order? In this example, it is reading left to right because English is dir LTR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
that's right, if you wanted to follow the direction you'd use flow.
Okay, so the six values are:
The descriptions don't say it directly, but And for grid, hm, I'm slightly uncomfortable with Otherwise, +1 from me |
Hmmmm tho if we're not allowing the second keyword in flex/grid to be omitted (and I agree that we shouldn't, none of the values are reasonable as a default), we should probably just combine them into a single hyphenated keyword - |
I still prefer the syntax I proposed here: #8589 (comment) even if you leave out the part about tables and floats and such (though, like grid, I think it would be very useful with tables especially). |
@tabatkins with regard to combined keywords, that's also what fantasai had suggested, and as I wrote this out the separate keywords seemed odd as they have to be used together. I think if they were to be separate we'd need to define a default if someone just used 'grid' for example. So I think hyphenating is likely better. I'll update to that.
I think the I guess if you were placing all your items, and wanted normal ordering apart from one item with I think you are right that having it separate from the grid and flex entries makes it look like something that could apply to other layout methods. |
@bradkemper I find your proposed syntax more confusing. It requires authors to understand what you mean by cross layout in various scenarios, so I feel as if it would be quite difficult to explain. Because of the different way flex and grid layout behave (especially with reverse in flex) I don't think it's easy to have a one size fits all approach. Also, I can see odd things happening if someone were to switch a component from being grid to flex, for example. At least this way, if you are using |
@tabatkins updated as per the above discussion. |
I think that’s easy. Cross axis, cross direction, and cross size are terms used a lot in describing grid and flex-box. Even though we don’t use those terms in the grid spec, it is in the flex spec, the box alignment spec, and I see them in many other CSS Grid related pages on the web.
In layouts with intersecting rows and columns, it would be the direction perpendicular to the reading direction. In one dimensional layout,
I think having six different values is about three values to many. I really don’t see any common use cases for having the row reading order be the reverse of the reading So, for example, for flex:
Yeah, if I specified a visual-based reading order, then DOM order isn’t what I want though. If I had If I had
Yeah, I totally disagree with that statement. See above. In any case, there were a couple other parts to my proposal:
|
@bradkemper I think it would definitely be good to raise all of this as separate issues. Can I suggest we do the following:
I think it would be good to disentangle several different points, and these things might be good to discuss at the upcoming f2f. The planning pages currently have a mysql error so I can't see if you are going to be there, but if not maybe we can schedule them at a time you can be on the call? |
So, I've taken into account all of the above discussion. For the points that @bradkemper raised, I've created three new issues and also added these inline to the draft, I think this is better than comments on a PR that are a bit hidden. We can then deal with each individually. Brad, your final point re tab order, I think this is already accounted for in the draft. The intention is that reading and navigation order are the same. @tabatkins @fantasai while there are still issues to resolve, I think that the current state of this is closer in intention that what is currently published in the ED and does the work detailed in the resolution at TPAC. I'd like to propose we merge this to account for the previous resolution and I'll continue to work on the outstanding issues, and any others that are raised. |
Looks good to me, +1 to merge |
Thanks @rachelandrew. I will use other issues to comment, and will be at the F2F. I agree that you should move forward with what you have, and we can resolve those other issues separately. |
Work on a draft for the
reading-order-items
property.I have:
order
back as in CSS Display 3, as the previous draft changed theorder
property and this does not.reading-order-items
with some examples. Worked examples can be found here.An initial question, is that there is a section on order and accessibility in the specification. The details there are mostly relevant to
order
andreading-order-items
, should this be updated to include both? (Could be done as a separate PR).