-
Notifications
You must be signed in to change notification settings - Fork 6.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(checkbox): Support checkbox click action config
- Loading branch information
1 parent
541a95e
commit f525f47
Showing
5 changed files
with
140 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
/** | ||
* @license | ||
* Copyright Google LLC All Rights Reserved. | ||
* | ||
* Use of this source code is governed by an MIT-style license that can be | ||
* found in the LICENSE file at https://angular.io/license | ||
*/ | ||
import {InjectionToken} from '@angular/core'; | ||
|
||
|
||
/** | ||
* Checkbox click action when user click on input element. | ||
* noop: Do not toggle checked or indeterminate. | ||
* check: Only toggle checked status, ignore indeterminate. | ||
* check-indeterminate: Toggle checked status, set indeterminate to false. Default behavior. | ||
* undefined: Same as `check-indeterminate`. | ||
*/ | ||
export type MatCheckboxClickAction = 'noop' | 'check' | 'check-indeterminate' | undefined; | ||
|
||
/** | ||
* Injection token that can be used to specify the checkbox click behavior. | ||
*/ | ||
export const MAT_CHECKBOX_CLICK_ACTION = | ||
new InjectionToken<MatCheckboxClickAction>('mat-checkbox-click-action'); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters