slot="" and ::part() are used for custom elements. They are a separate namespace for authors to use.
Native HTML elements get customized via normal child elements and pseudo-elements:
Similarly, your use of a semi-generic behavior="" attribute, which only has meaning within a certain parent context but can be used on any arbitrary element, is not idiomatic to HTML either. Is there any way to replace that with an idiomatic child-element pattern?
slot="" and ::part() are used for custom elements. They are a separate namespace for authors to use.
Native HTML elements get customized via normal child elements and pseudo-elements:
<summary>for<details>,<option>and<optgroup>for<select>,<legend>for<fieldset>, ...::markerfor<details>,::backdropfor<dialog>,::placeholderfor<input>, etc. (This is maybe related to [selectmenu] Add CSS selector to consistently select selectmenu parts #645.)Similarly, your use of a semi-generic
behavior=""attribute, which only has meaning within a certain parent context but can be used on any arbitrary element, is not idiomatic to HTML either. Is there any way to replace that with an idiomatic child-element pattern?