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

ux-checkbox unchecked state value #69

Closed
ZHollingshead opened this Issue May 3, 2017 · 1 comment

Comments

Projects
None yet
1 participant
@ZHollingshead
Member

ZHollingshead commented May 3, 2017

I'm submitting a feature request

Desired behavior:
To be able to assign a value to the checkbox components unchecked state.

@ZHollingshead

This comment has been minimized.

Show comment
Hide comment
@ZHollingshead

ZHollingshead May 3, 2017

Member

Comments from #22 that led to this

@dspublic commented
Thank you for quick fix and response. Let me take a feature suggestion, what I implemented in my checkbox control.
There's a valueOn (value-on default=true) and valueOff (value-off default=false) and value (checked in your code) controll property.
If value==valueOn then value=valueOff
elseIf value==valueOff or value==null then value=valueOn
else value=null (third state)
In this case we have a value for state on and off, and a null for third one.

@ZHollingshead commented
So if I understand correctly you would like to add additional values to be able to set a value during the unchecked state, is this correct? If so I would probably just add the unchecked state, and let value continue to represent the checked state.

<ux-checkbox value="foo" unchecked-value="bar"></ux-checkbox>

@dspublic commented
Yes, that's correct. It's exactly what I want to suggest.

Member

ZHollingshead commented May 3, 2017

Comments from #22 that led to this

@dspublic commented
Thank you for quick fix and response. Let me take a feature suggestion, what I implemented in my checkbox control.
There's a valueOn (value-on default=true) and valueOff (value-off default=false) and value (checked in your code) controll property.
If value==valueOn then value=valueOff
elseIf value==valueOff or value==null then value=valueOn
else value=null (third state)
In this case we have a value for state on and off, and a null for third one.

@ZHollingshead commented
So if I understand correctly you would like to add additional values to be able to set a value during the unchecked state, is this correct? If so I would probably just add the unchecked state, and let value continue to represent the checked state.

<ux-checkbox value="foo" unchecked-value="bar"></ux-checkbox>

@dspublic commented
Yes, that's correct. It's exactly what I want to suggest.

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