- From: CSS Meeting Bot via GitHub <sysbot+gh@w3.org>
- Date: Thu, 03 Apr 2025 19:00:59 +0000
- To: public-css-archive@w3.org
The CSS Working Group just discussed ``[css-anchor-position] Is `anchor()` fallback used when outside of inset properties?``, and agreed to the following: * `RESOLVED: anchor() functions are only valid in inset properties, clarify spec` * `RESOLVED: anchor-size() only allowed in properties allowed in @position-try. Clarify spec.` <details><summary>The full IRC log of that discussion</summary> <TabAtkins> fantasai: so there's a question of where anchor() is "valid"<br> <TabAtkins> fantasai: there's parse validity, and there's "does it have a value, or does it use the fallback"<br> <kizu> q+<br> <TabAtkins> fantasai: I think what we mean is that it's only parse-valid in the inset properties<br> <TabAtkins> fantasai: but some of the text in the spec is confusing on that point<br> <TabAtkins> fantasai: so want to double check that's the intention<br> <fantasai> fantasai: and if so, we need to clarify spec<br> <fantasai> TabAtkins: yes that was the intention<br> <astearns> ack kizu<br> <TabAtkins> TabAtkins: they fundamentally don't make sense outside of the inset property<br> <TabAtkins> kizu: in my exploration i found some use-cases for using them outside of those<br> <TabAtkins> kizu: wonder if we could say that an explicit side like "left" is okay outside?<br> <TabAtkins> kizu: there are use-cases both for anchor() and anchor-size() where you might wnat to compute something intersting based on them<br> <TabAtkins> kizu: right now it's very limited. there are workarounds<br> <fantasai> TabAtkins: The reason they're not usable outside 'inset' properties is because they compute to the value that the 'inset' property needs to hit a paricular position<br> <fantasai> TabAtkins: so you need to know which inset property you're in (e.g. left vs top)<br> <fantasai> TabAtkins: and outside the inset properties, we have no context<br> <fantasai> s/top/right/<br> <iank_> `right: anchor(left)` != `left: anchor(left)`<br> <fantasai> TabAtkins: so if you could elaborate on use cases ..?<br> <TabAtkins> kizu: really i just wanted ot use the difference between two anchor positions<br> <TabAtkins> kizu: the acutal value doesn't amtter, just he difference<br> <fantasai> TabAtkins: What you described, diff between two position, is not contextual<br> <bkardell> s/mtter, just he difference/matter, just the difference<br> <fantasai> TabAtkins: if we wanted to do that, we could address it via new function<br> <fantasai> TabAtkins: anchor-distance() or something<br> <fantasai> TabAtkins: similar to anchor-size()<br> <fantasai> TabAtkins: So i think we should reject using anchor() outside insets, but could explore using another anchor function<br> <fantasai> fantasai: separate issue<br> <fantasai> kizu: anchor-size() ?<br> <fantasai> TabAtkins: anchor-size() is already usable more widely<br> <dshin> I think the main reason for rejecting general-use is https://github.com/w3c/csswg-drafts/issues/9827<br> <fantasai> iank_: it's allowed on the size properties, whereas anchor() isn't<br> <TabAtkins> anchor-size() is allowed in a sizing property, an inset property, or a margin property<br> <fantasai> kizu: Background size shadow on the ground would be very useful<br> <TabAtkins> (aka the properties you can adjust in position-try, iirc)<br> <fantasai> kizu: but not allowed currently<br> <fantasai> astearns: not expanding where it's valid, but could add a different function for those use cases<br> <fantasai> astearns: anyone who would object to resolving that the anchor() function is not applicable elsewhere than insets?<br> <fantasai> RESOLVED: anchor() functions are only valid in inset properties, clarify spec<br> <fantasai> astearns: original post here asks about anchor-size()<br> <fantasai> astearns: Is that something to discus snow<br> <fantasai> TabAtkins: Limitation on anchor-size() was due to some processing pipeline timing restrictions<br> <fantasai> TabAtkins: limited to properties allowed in position-try<br> <fantasai> TabAtkins: I should check that lists are synced<br> <fantasai> TabAtkins: I think that's the restriction<br> <fantasai> iank_: We want to avoid stuff that changes element in general<br> <fantasai> iank_: e.g. border isn't allowed, has substantial effects on e.g. tables<br> <fantasai> iank_: margins and size properteis are fine<br> <astearns> ack fantasai<br> <fantasai> PROPOSED: anchor-size() only allowed in properties allowed in @position-try. Clarify spec.<br> <fantasai> astearns: any objections?<br> <fantasai> RESOLVED: anchor-size() only allowed in properties allowed in @position-try. Clarify spec.<br> </details> -- GitHub Notification of comment by css-meeting-bot Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10950#issuecomment-2776675522 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Thursday, 3 April 2025 19:01:00 UTC