Re: [csswg-drafts] [css-anchor] Detecting active @position-fallback (#8171)

The CSS Working Group just discussed `[css-anchor] Detecting active @position-fallback`.

<details><summary>The full IRC log of that discussion</summary>
&lt;TabAtkins> futhark<br>
&lt;JoshT> futhark: we can have fallback positions with @position rules<br>
&lt;JoshT> ... to position based on available space<br>
&lt;JoshT> ... there is desire to style differently based on which fallback is chosen<br>
&lt;JoshT> ... to do so with container queries<br>
&lt;JoshT> ... I have made an explainer. got positive feedback from the TAG<br>
&lt;JoshT> ... the next step is to get a resolution and feedback. resolve to work on it?<br>
&lt;JoshT> ... and to what level to add it to?<br>
&lt;astearns> ack fantasai<br>
&lt;JoshT> fantasai: this is super needed. I think concerned from usability PoV, fallbacks being numbered is not great<br>
&lt;JoshT> futhark: explainer came to a different conclusion. chrome impl uses numbers for simplicity<br>
&lt;lea> What if we name them? `@try top { ... } @try bottom { ... }` etc<br>
&lt;JoshT> fantasai: for position-area values, I think we want to ask 'are you in this mode or the other mode'. relative to the position.<br>
&lt;lea> q?<br>
&lt;lea> q+<br>
&lt;JoshT> ... so if my dropdown is in the top and then bottom, I don't want to index to what order it's in<br>
&lt;JoshT> ... with position-area, you've got the mapping with logical and physical<br>
&lt;emilio> Is it well defined what happens if you do cycles? Or does the new anchor type also imply size containment or so?<br>
&lt;JoshT> ... you want to say if it's inline-start, I want to query if it's left or right<br>
&lt;JoshT> futhark: we discussed should we map to try and names. if we map to position-area, should it match a query for position-area<br>
&lt;lea> q-<br>
&lt;JoshT> fantasai: I think we should query not the fallback, but the region. map between logical and physical, or the name of a position try<br>
&lt;JoshT> ... and then you could add a flip block or flip inline<br>
&lt;JoshT> ... and that would be easier to use and get you what you want: to query the physical location<br>
&lt;JoshT> astearns: could you have more than one fallback in a particular direction<br>
&lt;JoshT> fantasai: you query which one is active<br>
&lt;lea> q+<br>
&lt;JoshT> ... together if you have four items to try, I can query the same way the first and the third position. I think it should be queried based on details of the position<br>
&lt;JoshT> ... like anchor area colon, position: block-start, if i have specified that or the fallback, whatever that is<br>
&lt;JoshT> ... the position try values would be their own named custom srea<br>
&lt;miriam> q+<br>
&lt;astearns> ack lea<br>
&lt;JoshT> ... that's why I use the name of the position try rule<br>
&lt;JoshT> lea: are there any more use cases than arrows?<br>
&lt;JoshT> ... do you just need to know where the element is positioned?<br>
&lt;TabAtkins> q+<br>
&lt;JoshT> ... what you really want is how the element is positioned<br>
&lt;JoshT> ... otherwise it's too specific to anchor positioning<br>
&lt;JoshT> ... we should look at the ergonomics of how we make the arrows. with this API, what does it look like to make arrows? it might look awkward<br>
&lt;JoshT> miriam: I'm curious about the details, whether it involves containment, but I can take it to an issues<br>
&lt;astearns> ack miriam<br>
&lt;JoshT> futhark: we need style containment for counters.<br>
&lt;astearns> ack TabAtkins<br>
&lt;JoshT> TabAtkins: response to lea. needs to be tied to position try because you don't know where the thing you're putting the arrow on is<br>
&lt;JoshT> ... for a tooltip, that needs to be flush<br>
&lt;astearns> ack fantasai<br>
&lt;JoshT> ... needs to be tied to the styles used. could experiment for other stuff. but for this use case, this design is what's required<br>
&lt;JoshT> fantasai: I think this proposal connects really well with the teather proposal<br>
&lt;JoshT> ... to make them easier to do<br>
&lt;lea> Makes sense. Speaking of use cases, there's also transitions: you want a different transition depending on relative position (e.g. growing from the top or from the bottom)<br>
&lt;fantasai> s/teather/tether/<br>
&lt;JoshT> astearns: we can open up issues to discuss these things. can we wait until we've discussed the things that come up in the ussues<br>
&lt;lea> q+<br>
&lt;lea> q-<br>
&lt;JoshT> fantasai: should go in anchor-positioning-2.<br>
</details>


-- 
GitHub Notification of comment by css-meeting-bot
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/8171#issuecomment-2963456372 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 11 June 2025 16:23:39 UTC