We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Describe the bug <Textfield/> does not handle input$readOnly attribute correctly. Tested with SMUI version 7.0.0
<Textfield/>
input$readOnly
7.0.0
To Reproduce Steps to reproduce the behavior:
<TextField ... input$readOnly="{true}"/>
<TextField ... input$readOnly="{false}"/>
Idea for this code comes from #280 (comment)
Expected behavior In first case there should be HTML code in style <input ... readonly/>
<input ... readonly/>
In second case there should be attribute readonly omitted but it is rendered as
readonly
<input type="text" readonly="false"/>
that is wrong as readonly="false" is is interpreted by browser as readonly="true".
readonly="false"
readonly="true"
See https://html.spec.whatwg.org/multipage/common-microsyntaxes.html#boolean-attribute and https://html.spec.whatwg.org/multipage/input.html#attr-input-readonly for explanation.
Additional comments The problem is that following code does not work.
<script> import Textfield from "@smui/textfield"; let ro : boolean = false; </script> <TextField ... input$readonly="{ro}"/>
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Describe the bug
<Textfield/>
does not handleinput$readOnly
attribute correctly. Tested with SMUI version7.0.0
To Reproduce
Steps to reproduce the behavior:
<TextField ... input$readOnly="{true}"/>
<TextField ... input$readOnly="{false}"/>
Idea for this code comes from #280 (comment)
Expected behavior
In first case there should be HTML code in style
<input ... readonly/>
In second case there should be attribute
readonly
omitted but it is rendered asthat is wrong as
readonly="false"
is is interpreted by browser asreadonly="true"
.See https://html.spec.whatwg.org/multipage/common-microsyntaxes.html#boolean-attribute and https://html.spec.whatwg.org/multipage/input.html#attr-input-readonly for explanation.
Additional comments
The problem is that following code does not work.
The text was updated successfully, but these errors were encountered: