diff --git a/testing/web-platform/tests/custom-elements/ElementInternals-accessibility.html b/testing/web-platform/tests/custom-elements/ElementInternals-accessibility.html index 6a93f2d9083e..e222ef9d4664 100644 --- a/testing/web-platform/tests/custom-elements/ElementInternals-accessibility.html +++ b/testing/web-platform/tests/custom-elements/ElementInternals-accessibility.html @@ -174,9 +174,23 @@ " ariaColIndex " +/ +/ " ariaColIndexText " +/ +/ +tentative +- +> +ElementInternals +- +accessibility +. +tentative +. +html " ariaColSpan " @@ -189,9 +203,23 @@ " ariaDescribedByElements " +/ +/ " ariaDescription " +/ +/ +tentative +- +> +ElementInternals +- +accessibility +. +tentative +. +html " ariaDetailsElements " @@ -273,9 +301,23 @@ " ariaRowIndex " +/ +/ " ariaRowIndexText " +/ +/ +tentative +- +> +ElementInternals +- +accessibility +. +tentative +. +html " ariaRowSpan " diff --git a/testing/web-platform/tests/custom-elements/ElementInternals-accessibility.tentative.html b/testing/web-platform/tests/custom-elements/ElementInternals-accessibility.tentative.html new file mode 100644 index 000000000000..5f9753bf15c3 --- /dev/null +++ b/testing/web-platform/tests/custom-elements/ElementInternals-accessibility.tentative.html @@ -0,0 +1,200 @@ +< +! +DOCTYPE +HTML +> +< +script +src += +" +/ +resources +/ +testharness +. +js +" +> +< +/ +script +> +< +script +src += +" +/ +resources +/ +testharnessreport +. +js +" +> +< +/ +script +> +< +script +> +class +TestElement +extends +HTMLElement +{ +constructor +( +) +{ +super +( +) +; +this +. +_internals += +this +. +attachInternals +( +) +; +} +get +internals +( +) +{ +return +this +. +_internals +; +} +set +internals +( +val +) +{ +throw +" +Can +' +t +set +internals +! +" +; +} +} +customElements +. +define +( +" +test +- +element +" +TestElement +) +; +< +/ +script +> +< +test +- +element +id += +" +testElement +" +> +< +/ +test +- +element +> +< +script +> +const +element += +document +. +getElementById +( +" +testElement +" +) +; +/ +/ +tentative +properties +const +properties += +[ +" +ariaColIndexText +" +" +ariaDescription +" +" +ariaRowIndexText +" +] +; +for +( +const +property +of +properties +) +{ +test +( +( +) += +> +{ +assert_inherits +( +element +. +internals +property +) +; +} +property ++ +" +is +defined +in +ElementInternals +" +) +; +} +< +/ +script +> diff --git a/testing/web-platform/tests/custom-elements/reactions/AriaMixin-string-attributes.html b/testing/web-platform/tests/custom-elements/reactions/AriaMixin-string-attributes.html index 74330a2ce5b1..c788e3bb9c85 100644 --- a/testing/web-platform/tests/custom-elements/reactions/AriaMixin-string-attributes.html +++ b/testing/web-platform/tests/custom-elements/reactions/AriaMixin-string-attributes.html @@ -228,6 +228,22 @@ < script > +/ +/ +tentative +- +> +AriaMixin +- +string +- +attributes +. +tentative +. +html +/ +/ testReflectAttribute ( ' @@ -433,6 +449,22 @@ ' ) ; +/ +/ +tentative +- +> +AriaMixin +- +string +- +attributes +. +tentative +. +html +/ +/ testReflectAttribute ( ' @@ -502,6 +534,22 @@ ' ) ; +/ +/ +tentative +- +> +AriaMixin +- +string +- +attributes +. +tentative +. +html +/ +/ testReflectAttribute ( ' @@ -1031,6 +1079,22 @@ ' ) ; +/ +/ +tentative +- +> +AriaMixin +- +string +- +attributes +. +tentative +. +html +/ +/ testReflectAttribute ( ' diff --git a/testing/web-platform/tests/custom-elements/reactions/AriaMixin-string-attributes.tentative.html b/testing/web-platform/tests/custom-elements/reactions/AriaMixin-string-attributes.tentative.html new file mode 100644 index 000000000000..655068b0fbf5 --- /dev/null +++ b/testing/web-platform/tests/custom-elements/reactions/AriaMixin-string-attributes.tentative.html @@ -0,0 +1,352 @@ +< +! +DOCTYPE +html +> +< +html +> +< +head +> +< +title +> +Custom +Elements +: +CEReactions +on +Element +interface +< +/ +title +> +< +meta +name += +" +author +" +title += +" +Ryosuke +Niwa +" +href += +" +mailto +: +rniwa +webkit +. +org +" +> +< +meta +name += +" +assert +" +content += +" +String +attributes +of +AriaAttributes +interface +must +have +CEReactions +" +> +< +meta +name += +" +help +" +content += +" +https +: +/ +/ +dom +. +spec +. +whatwg +. +org +/ +# +element +" +> +< +meta +name += +" +help +" +content += +" +https +: +/ +/ +w3c +. +github +. +io +/ +DOM +- +Parsing +/ +" +> +< +script +src += +" +/ +resources +/ +testharness +. +js +" +> +< +/ +script +> +< +script +src += +" +/ +resources +/ +testharnessreport +. +js +" +> +< +/ +script +> +< +script +src += +" +. +. +/ +resources +/ +custom +- +elements +- +helpers +. +js +" +> +< +/ +script +> +< +script +src += +" +. +/ +resources +/ +reactions +. +js +" +> +< +/ +script +> +< +/ +head +> +< +body +> +< +div +id += +" +log +" +> +< +/ +div +> +< +div +id += +" +container +" +> +< +/ +div +> +/ +/ +tentative +properties +that +were +added +mid +- +year +. +. +. +merge +back +in +after +Interop +2024 +completes +< +script +> +testReflectAttribute +( +' +role +' +' +role +' +' +foo +' +' +bar +' +' +role +on +Element +' +) +; +testReflectAttribute +( +' +ariaColIndexText +' +' +aria +- +colindextext +' +' +foo +' +' +bar +' +' +ariaColIndexText +on +Element +' +) +; +testReflectAttribute +( +' +ariaDescription +' +' +aria +- +description +' +' +foo +' +' +bar +' +' +ariaDescription +on +Element +' +) +; +testReflectAttribute +( +' +ariaRowIndexText +' +' +aria +- +rowindextext +' +' +foo +' +' +bar +' +' +ariaRowIndexText +on +Element +' +) +; +< +/ +script +> +< +/ +body +> +< +/ +html +> diff --git a/testing/web-platform/tests/html/dom/aria-attribute-reflection.html b/testing/web-platform/tests/html/dom/aria-attribute-reflection.html index b48fb9fe0a2e..6e43781011fb 100644 --- a/testing/web-platform/tests/html/dom/aria-attribute-reflection.html +++ b/testing/web-platform/tests/html/dom/aria-attribute-reflection.html @@ -1146,108 +1146,23 @@ script > < -div -id -= -" -colindextext -" -aria +! - -colindextext -= -" -x -" -> -< -/ -div -> -< -script -> -test -( -function -( -t -) -{ -var -element -= -document -. -getElementById -( -" -colindextext -" -) -; -assert_equals -( -element -. -ariaColIndexText -" -x -" -) -; -element -. -ariaColIndexText -= -" -y -" -; -assert_equals -( -element -. -getAttribute -( -" -aria - colindextext -" -) -" -y -" -) -; -testNullable -( -element -" -ariaColIndexText -" -" -aria - -colindextext -" -) -; -} -" +> aria - -colindextext attribute -reflects +- +reflection . -" -) -; -< -/ -script +tentative +. +html +- +- > < div @@ -1458,116 +1373,23 @@ script > < -div -id -= -" -description -" -aria +! - -description -= -" -cold -as -ice -" -> -< -/ -div -> -< -script -> -test -( -function -( -t -) -{ -var -element -= -document -. -getElementById -( -" -description -" -) -; -assert_equals -( -element -. -ariaDescription -" -cold -as -ice -" -) -; -element -. -ariaDescription -= -" -hot -as -fire -" -; -assert_equals -( -element -. -getAttribute -( -" -aria - description -" -) -" -hot -as -fire -" -) -; -testNullable -( -element -" -ariaDescription -" -" -aria - -description -" -) -; -} -" +> aria - -description attribute -reflects +- +reflection . -" -) -; -< -/ -script +tentative +. +html +- +- > < div @@ -3864,108 +3686,23 @@ script > < -div -id -= -" -rowindextext -" -aria +! - -rowindextext -= -" -x -" -> -< -/ -div -> -< -script -> -test -( -function -( -t -) -{ -var -element -= -document -. -getElementById -( -" -rowindextext -" -) -; -assert_equals -( -element -. -ariaRowIndexText -" -x -" -) -; -element -. -ariaRowIndexText -= -" -y -" -; -assert_equals -( -element -. -getAttribute -( -" -aria - rowindextext -" -) -" -y -" -) -; -testNullable -( -element -" -ariaRowIndexText -" -" -aria - -rowindextext -" -) -; -} -" +> aria - -rowindextext attribute -reflects +- +reflection . -" -) -; -< -/ -script +tentative +. +html +- +- > < div diff --git a/testing/web-platform/tests/html/dom/aria-attribute-reflection.tentative.html b/testing/web-platform/tests/html/dom/aria-attribute-reflection.tentative.html new file mode 100644 index 000000000000..b3ab8e1d19ab --- /dev/null +++ b/testing/web-platform/tests/html/dom/aria-attribute-reflection.tentative.html @@ -0,0 +1,567 @@ +< +! +DOCTYPE +HTML +> +< +meta +charset += +" +utf +- +8 +" +/ +> +< +title +> +Element +Reflection +for +ARIA +properties +< +/ +title +> +< +link +rel += +help +href += +" +https +: +/ +/ +wicg +. +github +. +io +/ +aom +/ +spec +/ +aria +- +reflection +. +html +" +> +< +link +rel += +" +author +" +title += +" +Meredith +Lane +" +href += +" +meredithl +chromium +. +org +" +> +< +script +src += +" +/ +resources +/ +testharness +. +js +" +> +< +/ +script +> +< +script +src += +" +/ +resources +/ +testharnessreport +. +js +" +> +< +/ +script +> +< +script +> +function +testNullable +( +element +jsAttr +contentAttr +) +{ +var +originalValue += +element +[ +jsAttr +] +; +assert_false +( +originalValue += += += +null +) +; +element +[ +jsAttr +] += +null +; +assert_equals +( +element +[ +jsAttr +] +null +) +; +assert_false +( +element +. +hasAttribute +( +contentAttr +) +) +; +/ +/ +Setting +to +undefined +results +in +same +state +as +setting +to +null +. +element +[ +jsAttr +] += +originalValue +; +element +[ +jsAttr +] += +undefined +; +assert_equals +( +element +[ +jsAttr +] +null +) +; +assert_false +( +element +. +hasAttribute +( +contentAttr +) +) +; +} +< +/ +script +> +< +! +- +- +tentative +- +- +> +< +div +id += +" +colindextext +" +aria +- +colindextext += +" +x +" +> +< +/ +div +> +< +script +> +test +( +function +( +t +) +{ +var +element += +document +. +getElementById +( +" +colindextext +" +) +; +assert_equals +( +element +. +ariaColIndexText +" +x +" +) +; +element +. +ariaColIndexText += +" +y +" +; +assert_equals +( +element +. +getAttribute +( +" +aria +- +colindextext +" +) +" +y +" +) +; +testNullable +( +element +" +ariaColIndexText +" +" +aria +- +colindextext +" +) +; +} +" +aria +- +colindextext +attribute +reflects +. +" +) +; +< +/ +script +> +< +! +- +- +tentative +- +- +> +< +div +id += +" +description +" +aria +- +description += +" +cold +as +ice +" +> +< +/ +div +> +< +script +> +test +( +function +( +t +) +{ +var +element += +document +. +getElementById +( +" +description +" +) +; +assert_equals +( +element +. +ariaDescription +" +cold +as +ice +" +) +; +element +. +ariaDescription += +" +hot +as +fire +" +; +assert_equals +( +element +. +getAttribute +( +" +aria +- +description +" +) +" +hot +as +fire +" +) +; +testNullable +( +element +" +ariaDescription +" +" +aria +- +description +" +) +; +} +" +aria +- +description +attribute +reflects +. +" +) +; +< +/ +script +> +< +! +- +- +tentative +- +- +> +< +div +id += +" +rowindextext +" +aria +- +rowindextext += +" +x +" +> +< +/ +div +> +< +script +> +test +( +function +( +t +) +{ +var +element += +document +. +getElementById +( +" +rowindextext +" +) +; +assert_equals +( +element +. +ariaRowIndexText +" +x +" +) +; +element +. +ariaRowIndexText += +" +y +" +; +assert_equals +( +element +. +getAttribute +( +" +aria +- +rowindextext +" +) +" +y +" +) +; +testNullable +( +element +" +ariaRowIndexText +" +" +aria +- +rowindextext +" +) +; +} +" +aria +- +rowindextext +attribute +reflects +. +" +) +; +< +/ +script +> +< +/ +html +>