- From: Lea Verou via GitHub <sysbot+gh@w3.org>
- Date: Mon, 28 Oct 2024 16:51:52 +0000
- To: public-css-archive@w3.org
@keithamus A numerical argument makes sense when we are comparing path segments, but authors should not have to do mental gymnastics like "0 is the same origin". Basically we need four separate pseudo-class names: 1. Same origin (not functional) 2. Same origin + path (not functional) 3. Same origin + path up to some path segment (functional form of 2) 4. Same origin + path + search (not functional) 5. Same origin + path + search + hash (not functional) — this is the current `:local-link` There is also the question of, how do 4 & 5 work with a missing search/hash in one of the two URLs being compared? I'd argue that the most commonly needed behavior is to match if the link has no search/hash and the page does, but not match if the link has a search/hash and the page doesn't, i.e. the URL also specifies the granularity of the matching. It seems there are three components to naming this: 1. What is the shared prefix? Some options are `:local-*`, `:same-*`, `:current-*`, `:self-*`, `:page-*` 2. Do we use any intermediate words like `-link-`? 3. What are the suffixes for each case? Some options are: 1. For origin, `:*-origin` or `:*-site` 2. For path, I think only `:*-path` has been mentioned 4. For up to search, perhaps `:*-page`? Since traditionally, that's what determined what resource you would get. 5. For up to hash, `:*-link`, `:*-target`, `:*-fragment` My opinion for each: 1. Anything other than `:same-*`. Same as what? 2. Let's not, if we pick the right names, they should make sense without requiring this, hopefully. 3. I vote `site`, `path`, `page`, `target` or `link` (link fits better with the high-level scheme, target has precedent in CSS as a term) -- GitHub Notification of comment by LeaVerou Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/10975#issuecomment-2442121401 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Monday, 28 October 2024 16:51:52 UTC