From e27bbd47c7af2383848e7b9235ffa405cdb9a5d3 Mon Sep 17 00:00:00 2001 From: Victor W Allen Date: Mon, 14 Oct 2024 14:02:51 -0700 Subject: [PATCH 1/3] Adds host scoping pseudo-element --- features/host.yml | 10 ++++++++++ features/host.yml.dist | 31 +++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+) create mode 100644 features/host.yml create mode 100644 features/host.yml.dist diff --git a/features/host.yml b/features/host.yml new file mode 100644 index 00000000000..16016fc71c1 --- /dev/null +++ b/features/host.yml @@ -0,0 +1,10 @@ +name: Host +description: The `::host` CSS pseudo-element selects the containing element of the shadow tree in which it is used. +spec: https://drafts.csswg.org/css-scoping-1/ +group: + - selectors + - web-components +compat_features: + - css.selectors.host + - css.selectors.host-context + - css.selectors.hostfunction diff --git a/features/host.yml.dist b/features/host.yml.dist new file mode 100644 index 00000000000..6d60708c374 --- /dev/null +++ b/features/host.yml.dist @@ -0,0 +1,31 @@ +# Generated from: host.yml +# Do not edit this file by hand. Edit the source file instead! + +status: + baseline: false + support: + chrome: "54" + chrome_android: "54" + edge: "79" +compat_features: + # baseline: high + # baseline_low_date: 2020-01-15 + # baseline_high_date: 2022-07-15 + # support: + # chrome: "54" + # chrome_android: "54" + # edge: "79" + # firefox: "63" + # firefox_android: "63" + # safari: "10" + # safari_ios: "10" + - css.selectors.host + - css.selectors.hostfunction + + # ⬇️ Same status as overall feature ⬇️ + # baseline: false + # support: + # chrome: "54" + # chrome_android: "54" + # edge: "79" + - css.selectors.host-context From 8ed0c98cefb6fa4fcb192f670f4027c0634756e5 Mon Sep 17 00:00:00 2001 From: Victor Allen Date: Wed, 16 Oct 2024 08:39:08 -0700 Subject: [PATCH 2/3] Apply suggestions from code review Co-authored-by: James Stuckey Weber --- features/host.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/features/host.yml b/features/host.yml index 16016fc71c1..33c7de7ac68 100644 --- a/features/host.yml +++ b/features/host.yml @@ -1,6 +1,6 @@ name: Host -description: The `::host` CSS pseudo-element selects the containing element of the shadow tree in which it is used. -spec: https://drafts.csswg.org/css-scoping-1/ +description: The `:host` CSS pseudo-class selects the containing element of the shadow tree in which it is used. +https://drafts.csswg.org/css-scoping-1/#host-selector group: - selectors - web-components From 36d42c6e5709a4372896c75a9609bc666c88c2cb Mon Sep 17 00:00:00 2001 From: Victor W Allen Date: Wed, 16 Oct 2024 08:58:48 -0700 Subject: [PATCH 3/3] Splits host-context into a feature --- features/host-context.yml | 8 ++++++++ features/host-context.yml.dist | 11 +++++++++++ features/host.yml | 5 ++--- features/host.yml.dist | 27 +++++++-------------------- 4 files changed, 28 insertions(+), 23 deletions(-) create mode 100644 features/host-context.yml create mode 100644 features/host-context.yml.dist diff --git a/features/host-context.yml b/features/host-context.yml new file mode 100644 index 00000000000..c5660295555 --- /dev/null +++ b/features/host-context.yml @@ -0,0 +1,8 @@ +name: host-context +description: The `:host-context()` CSS pseudo-class selects the containing element of the shadow tree in which it is used if that element or an ancestor matches the provided selector. +spec: https://drafts.csswg.org/css-scoping-1/#host-selector +group: + - selectors + - web-components +compat_features: + - css.selectors.host-context diff --git a/features/host-context.yml.dist b/features/host-context.yml.dist new file mode 100644 index 00000000000..edb77f15c7e --- /dev/null +++ b/features/host-context.yml.dist @@ -0,0 +1,11 @@ +# Generated from: host-context.yml +# Do not edit this file by hand. Edit the source file instead! + +status: + baseline: false + support: + chrome: "54" + chrome_android: "54" + edge: "79" +compat_features: + - css.selectors.host-context diff --git a/features/host.yml b/features/host.yml index 33c7de7ac68..df1d9a8e306 100644 --- a/features/host.yml +++ b/features/host.yml @@ -1,10 +1,9 @@ name: Host -description: The `:host` CSS pseudo-class selects the containing element of the shadow tree in which it is used. -https://drafts.csswg.org/css-scoping-1/#host-selector +description: The `:host` CSS pseudo-class selects the containing element of the shadow tree in which it is used. The `:host()` CSS pseudo-class selects the that element only if it matches the provided selector. +spec: https://drafts.csswg.org/css-scoping-1/#host-selector group: - selectors - web-components compat_features: - css.selectors.host - - css.selectors.host-context - css.selectors.hostfunction diff --git a/features/host.yml.dist b/features/host.yml.dist index 6d60708c374..f42d11af08a 100644 --- a/features/host.yml.dist +++ b/features/host.yml.dist @@ -2,30 +2,17 @@ # Do not edit this file by hand. Edit the source file instead! status: - baseline: false + baseline: high + baseline_low_date: 2020-01-15 + baseline_high_date: 2022-07-15 support: chrome: "54" chrome_android: "54" edge: "79" + firefox: "63" + firefox_android: "63" + safari: "10" + safari_ios: "10" compat_features: - # baseline: high - # baseline_low_date: 2020-01-15 - # baseline_high_date: 2022-07-15 - # support: - # chrome: "54" - # chrome_android: "54" - # edge: "79" - # firefox: "63" - # firefox_android: "63" - # safari: "10" - # safari_ios: "10" - css.selectors.host - css.selectors.hostfunction - - # ⬇️ Same status as overall feature ⬇️ - # baseline: false - # support: - # chrome: "54" - # chrome_android: "54" - # edge: "79" - - css.selectors.host-context