Skip to content
This repository has been archived by the owner on Sep 5, 2024. It is now read-only.

feat(mdCheckbox): Add indeterminate state #1912

Closed
brettstack opened this issue Mar 16, 2015 · 14 comments
Closed

feat(mdCheckbox): Add indeterminate state #1912

brettstack opened this issue Mar 16, 2015 · 14 comments
Labels
for: internal contributor The team will address this issue and community PRs are not requested. type: feature

Comments

@brettstack
Copy link
Contributor

I just replaced a native checkbox with mdCheckbox and realised it doesn't have an indeterminate state.

@epelc
Copy link
Contributor

epelc commented Mar 16, 2015

If anyone doesn't know what this is have a look below

https://css-tricks.com/indeterminate-checkboxes/
image

Also +1 I will need this soon.

@marcysutton
Copy link
Contributor

We have passed this question along to the UX team and will report back.

@marcysutton
Copy link
Contributor

I'm still unclear what the use-case for this would be, and the native versions can only be added with JavaScript (not HTML attributes). That said, I think a line icon just like the Chrome version would communicate effectively.

@brettstack
Copy link
Contributor Author

Use-case: a select-all check box which is checked whem all children are
checked; unchecked when all children are unchecked; and intermediate when
at least 1 but not all children are selected.
On 14 Apr 2015 4:48 pm, "Marcy Sutton" [email protected] wrote:

I'm still unclear what the use-case for this would be, and the native
versions can only be added with JavaScript (not HTML attributes). That
said, I think a line icon just like the Chrome version would communicate
effectively.


Reply to this email directly or view it on GitHub
#1912 (comment).

@epelc
Copy link
Contributor

epelc commented Apr 15, 2015

@marcysutton My use case would be for user specific permissions. Specifically for overriding defaults from a users role. The indeterminate state would be used to default to the parent role for each permission.

@marcysutton
Copy link
Contributor

Cool! thanks for your replies, those help.

@ThomasBurleson
Copy link
Contributor

The UX Material team is adding this feature to the specification.

@brettstack
Copy link
Contributor Author

Thanks!

@ThomasBurleson ThomasBurleson added the for: internal contributor The team will address this issue and community PRs are not requested. label Apr 30, 2015
@ravanscafi
Copy link

+1
Use case: Row selection in tables determine state of "select all" checkbox.

http://www.google.com/design/spec/components/data-tables.html#data-tables-interaction

@marcysutton marcysutton modified the milestones: Backlog, 0.10.0 May 21, 2015
@YuriyVlasenko
Copy link

+1

@ThomasBurleson ThomasBurleson modified the milestones: post-1.0 , Backlog Sep 4, 2015
@langdonx
Copy link

@ThomasBurleson PRs welcome?

md-checkbox.md-indeterminate .md-icon:after {
    box-sizing: border-box;
    transform: rotate(45deg);
    position: absolute;
    left: $checkbox-width / 3;
    top: $checkbox-width / 9;
    display: table;
    width: $checkbox-width / 3;
    height: $checkbox-width * 2 / 3;
    border-width: $checkbox-border-width;
    border-style: solid;
    border-top: 0;
    border-left: 0;
    content: '';
    transform: rotate(0deg);
    border-right: 0;
    top: -2px;
    width: 10px;
    left: 4px;
}

I know input only has indeterminate as a property, but it would make good sense to have it as an attribute here (or a class at the very least). It shouldn't manipulate the model either since input.checked doesn't change when input.indeterminate changes (if indeterminate is true, it will always show the checkbox as indeterminate regardless of the checked property).

@ThomasBurleson ThomasBurleson modified the milestones: post-1.0 , Backlog Jan 5, 2016
@ErinCoughlan ErinCoughlan added EOC in progress Mainly for in progress PRs, but may be used for issues that require multiple PRs labels Feb 11, 2016
@smurugavel
Copy link

+1

1 similar comment
@begemott
Copy link

+1

@devversion
Copy link
Member

SHA 2776ad2

@ThomasBurleson ThomasBurleson removed the in progress Mainly for in progress PRs, but may be used for issues that require multiple PRs label Apr 25, 2016
@Splaktar Splaktar removed this from the - Backlog milestone Feb 23, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
for: internal contributor The team will address this issue and community PRs are not requested. type: feature
Projects
None yet
Development

No branches or pull requests