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

Conditional "readonly" attribute does not work #1874

Closed
dylanrtt opened this Issue Sep 1, 2015 · 4 comments

Comments

Projects
None yet
6 participants
@dylanrtt
Contributor

dylanrtt commented Sep 1, 2015

I can use a mustache condition block to make an element have a conditional disabled attribute but it does not work with readonly. It simply never applies the attribute regardless of the condition's truthiness.

http://jsbin.com/horehelute/edit?html,js,console,output

@justinbmeyer

This comment has been minimized.

Show comment
Hide comment
@justinbmeyer

justinbmeyer Sep 15, 2015

Contributor

Interesting. I assumed it work would b/c readonly is configured here: https://github.com/bitovi/canjs/blob/minor/util/attr/attr.js#L47

Contributor

justinbmeyer commented Sep 15, 2015

Interesting. I assumed it work would b/c readonly is configured here: https://github.com/bitovi/canjs/blob/minor/util/attr/attr.js#L47

@justinbmeyer

This comment has been minimized.

Show comment
Hide comment
@justinbmeyer

justinbmeyer Sep 15, 2015

Contributor

@alexisabril this is probably pretty simple. Although the test should probably take place in can/util/attr. I would start there to make sure it's doing what it should be doing.

Contributor

justinbmeyer commented Sep 15, 2015

@alexisabril this is probably pretty simple. Although the test should probably take place in can/util/attr. I would start there to make sure it's doing what it should be doing.

@DesignByOnyx

This comment has been minimized.

Show comment
Hide comment
@DesignByOnyx

DesignByOnyx Sep 15, 2015

Contributor

readonly attribute maps to readOnly property - could be a start...

Contributor

DesignByOnyx commented Sep 15, 2015

readonly attribute maps to readOnly property - could be a start...

@daffl

This comment has been minimized.

Show comment
Hide comment
@daffl

daffl Sep 29, 2015

Contributor

Closed via #1920

Contributor

daffl commented Sep 29, 2015

Closed via #1920

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment