-
Notifications
You must be signed in to change notification settings - Fork 22.4k
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
enhance: html input element - technical summary - attributes #31639
Conversation
Preview URLs (9 pages)
Flaws (4)Note! 6 documents with no flaws that don't need to be listed. 🎉 URL:
URL:
URL:
(comment last updated: 2024-06-24 20:54:05) |
Apologies as I didn't realize this was still in draft. commit e331252 fixes the linting issues with the table (all white space). |
@estelle np, the only reason it's in draft is for this task: #31639 (comment), which I would prefer a more proficient maintainer who is more knowledgeable about the standards of |
You don't want to add the IDL attributes on this page. Those are listed on https://developer.mozilla.org/en-US/docs/Web/API/HTMLInputElement The attributes for this page are listed on https://html.spec.whatwg.org/multipage/input.html#the-input-element under "content attributes". The DOM interface attributes go under the API/HTMLInputElement page |
Okay, Should I revert the change in the html input element general doc page, and reroute the links to valueasdate and valuesasnumber to the API instead? Also, for some reason, |
That's because both value and list are both HTML attributes that you add to the opening tag and IDL attributes that you can retrieve from the input object with JS. |
The valueAsDate and valueAsNumber should not be mentioned on this page at all. So, yes, please revert those additions. Thanks That said, i am unclear why only value is listed under IDL attributes on the month input in the technical summary section. There are way more attributes than that. |
Indeed, and it's not even represented in a schema, no 2-way syncing between docs pages. As I said in the motivations:
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Agree that valueAsDate
and valueAsNumber
should not be listed in the Attributes section of the <input>
element, they are not html element attribute after all
| [`src`](#src) | `image` | Same as `src` attribute for {{htmlelement('img')}}; address of image resource | | ||
| [`step`](#step) | `date`, `month`, `week`, `time`, `datetime-local`, `number`, `range` | Incremental values that are valid | | ||
| [`type`](#type) | all | Type of form control | | ||
| [`value`](#value) | all except `image` | The value of the control. When specified in the HTML, corresponds to the initial value | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| [`value`](#value) | all except `image` | The value of the control. When specified in the HTML, corresponds to the initial value | | |
| [`value`](#value) | all except `image` | The value of the control. When specified in the HTML, corresponds to the initial value | |
Personlly, the change to this sentence seems to be meanless
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This suggestion is invalid because no changes were made to the code
The original value
html input element description seems that "the value of the initial control" seems to be too limited, as value
is simply the value of the control, and when specified in the HTML, it corresponds to the initial value
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Originally it read The initial value of the control
, which was accurate. this is about what the value attribute is when you are writing HTML, not the IDL attribute when you are querying the current value.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yes, this makes sense to me
i fixed the bot issues locally. hopefully this fixes the bot issue.
…\web\html\element\input\index.md #31639 (comment)
Only the |
Let's do that in a different PR. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you.
Also, congratulations on your first merged MDN content PR.
Welcome to the team!
* enhance: html input element - techincal summary - attributes * fix hooks * fix: typo Co-authored-by: Estelle Weyl <estelle@openwebdocs.org> * fixed lint issues locally i fixed the bot issues locally. hopefully this fixes the bot issue. * fix: indentation * fix: `valueAsNumber` and `valueAsNumber` should not be in files\en-us\web\html\element\input\index.md mdn#31639 (comment) --------- Co-authored-by: Estelle Weyl <estelle@openwebdocs.org>
<input type="month">
-IDL attributes
: missingvalueAsDate
andvalueAsNumer
#31590 (comment)Description
General enhancements for docs about html input element - technical summary - attributes
Motivation
The docs about html input element - technical summary - attributes are not complete enough and well build, to me.
I think they should be done using a JSON object as representation schema, to automatically link attributes to their specific elements doc page, and list the specific elements doc page from the attribute section in the general input element doc page.
This is an attempt to make a manual update about them, albeit not being enough
Related issues and pull requests
Close #31590
Tasks