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

Add Group/Fieldvariants of CheckboxTri? #145

Open
mkrause opened this issue Feb 13, 2025 · 1 comment
Open

Add Group/Fieldvariants of CheckboxTri? #145

mkrause opened this issue Feb 13, 2025 · 1 comment

Comments

@mkrause
Copy link
Collaborator

mkrause commented Feb 13, 2025

See comment here: #136 (comment)

Could maybe just allow customizing the inner element of CheckboxField/CheckboxGroup.

@mkrause mkrause changed the title Update CheckboxField to allow using a CheckboxTri? Add Field/Group variants of CheckboxTri? Feb 13, 2025
@mkrause mkrause changed the title Add Field/Group variants of CheckboxTri? Add Group/Fieldvariants of CheckboxTri? Feb 19, 2025
@mkrause
Copy link
Collaborator Author

mkrause commented Feb 19, 2025

For a CheckboxTriGroup, what would the type of the state be? For CheckboxGroup, this is Set<CheckboxKey>, where if the checkbox is checked then it's in the Set otherwise not. But for CheckboxTri this wouldn't work, since you can't have "half" a set membership.

Instead, we might need to have something like a Map<CheckKey, boolean | 'indeterminate'>.

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

No branches or pull requests

1 participant