Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cc-form-control-element: add form getter #1206

Closed
pdesoyres-cc opened this issue Oct 17, 2024 · 0 comments · Fixed by #1321 or #1350
Closed

cc-form-control-element: add form getter #1206

pdesoyres-cc opened this issue Oct 17, 2024 · 0 comments · Fixed by #1321 or #1350
Assignees
Labels
enhancement New feature or request

Comments

@pdesoyres-cc
Copy link
Contributor

As stated in MDN documentation: https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement/form, native input elements have a readonly property form that returns the associated <form> element (if any).

We can do the same for our control elements. Since CcFormControlElement uses the ElementInternals API, it's very easy to rely on this._elementInternal inner property to return the associated <form> element.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
1 participant