Re: [w3c/webcomponents] Custom pseudo-classes for host elements via shadow roots (:state) (#738)

Form-associated custom elements discussed in https://github.com/w3c/webcomponents/issues/187 doesn't provide a way to match an element with form-related built-in pseudo classes (*1).  I'd like to extend  the API for them.

Assume that the current API is like:

    this.#internals = this.attachInternals();
    this.#internals.states.add('foo');  // this element matches to custom state 'foo'

I'd like to extend ```states``` to accept the built-in pseudo classes.

    this.#internals.states.add(':checked');  // this element matches to :checked.

*1)  :checked, :indeterminate, :default, :in-range, :out-of-range, :required, :optional, :read-only, :read-write

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/w3c/webcomponents/issues/738#issuecomment-483907256

Received on Wednesday, 17 April 2019 01:57:00 UTC