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

Missing prototype in CheckboxesWidget.js #414

Closed
wants to merge 10 commits into from

Conversation

crumblix
Copy link
Collaborator

Reasons for making this change

Missing prototype in CheckboxesWidget.js

Referencing issue:
#413

Checklist

  • I'm updating documentation
    • I've checked the rendering of the Markdown text I've added
    • If I'm adding a new section, I've updated the Table of Content
  • [x ] I'm adding or updating code
    • I've added and/or updated tests
    • I've updated docs if needed
  • I'm adding a new feature
    • I've updated the playground with an example use of the feature

EDORAS\mark added 10 commits November 23, 2016 08:28
… instead of empty string or empty array to be consistent with other field types.
…g on fallback validation and consistent with other control that support it.

Enable the required field for arrays.  Good for where you might want at least one options selected in a checkbox group for example.
…come through as a boolean "false". Convert that to an empty array so that the enumOptions.map will not error in the render. The list will temporarily be empty, but better than erroring and never filling.
…llowing updates. (make compatible with recent checkin)
…dget needs updating still).

NOTE:  Could have converted optionsList to value and label in utils.js however there could be cases where the entire data structure is useful in the widget.
I envisage it could possibily be a grid control with many columns with checkboxes on the left ... using something like ag-grid.   So a simple value/key pairing may not be enough.
Instead extract the value/key data out of the data structure in the widgets themselves.
Coopted the enumOptions variable for this purpose, could be a different name.
Checking for value/key in "items" child for multi select array.  This could be done elsewhere too, but seemed the least invasive.
… instead of empty string or empty array to be consistent with other field types.

Fix accidental syntax error ... should be _onChange.
…come through as a boolean "false". Convert that to an empty array so that the enumOptions.map will not error in the render. The list will temporarily be empty, but better than erroring and never filling.

Move the fix back to where optionsList is being set to False.  A more general fix.
@crumblix
Copy link
Collaborator Author

OK ... that didn't work the way I wanted .... I only want one of those patches in this PR :(

@crumblix
Copy link
Collaborator Author

Also ... that failed auto-test was a syntax error fixed in a later commit. Obviously this system requires each individual commit to be good, rather than the set?

Anyway really I just wanted c7a7b4a in this PR. For the life of my though I can't find how to select/deselect the commits I want in my PR ... I'll keep looking and reading.

Sorry for the confusion, but I will get better at this!

@n1k0
Copy link
Collaborator

n1k0 commented Nov 23, 2016

Hey now worries, things always have to be learned at some point ;)

Try to learn about rebasing, this is exactly what you need here; the idea would be to force push your branch rebased with your single commit here. There are a lot of good tutos out there about this!

@crumblix
Copy link
Collaborator Author

Thanks Nicholas ... will do! :)

@n1k0
Copy link
Collaborator

n1k0 commented Nov 23, 2016

Fixed by #416

@n1k0 n1k0 closed this Nov 23, 2016
@crumblix crumblix deleted the master branch November 30, 2016 02:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants