mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-21 13:01:01 +08:00
chore(templates): import required directives for ionic templates
This commit is contained in:
@ -5,7 +5,7 @@ import { Form } from '../../util/form';
|
||||
import { Item } from '../item/item';
|
||||
import { isTrueProperty } from '../../util/util';
|
||||
|
||||
const CHECKBOX_VALUE_ACCESSOR = new Provider(
|
||||
export const CHECKBOX_VALUE_ACCESSOR = new Provider(
|
||||
NG_VALUE_ACCESSOR, {useExisting: forwardRef(() => Checkbox), multi: true});
|
||||
|
||||
|
||||
@ -49,19 +49,20 @@ const CHECKBOX_VALUE_ACCESSOR = new Provider(
|
||||
*/
|
||||
@Component({
|
||||
selector: 'ion-checkbox',
|
||||
template:
|
||||
'<div class="checkbox-icon" [class.checkbox-checked]="_checked">' +
|
||||
'<div class="checkbox-inner"></div>' +
|
||||
'</div>' +
|
||||
'<button role="checkbox" ' +
|
||||
'type="button" ' +
|
||||
'category="item-cover" ' +
|
||||
'[id]="id" ' +
|
||||
'[attr.aria-checked]="_checked" ' +
|
||||
'[attr.aria-labelledby]="_labelId" ' +
|
||||
'[attr.aria-disabled]="_disabled" ' +
|
||||
'class="item-cover">' +
|
||||
'</button>',
|
||||
template: `
|
||||
<div class="checkbox-icon" [class.checkbox-checked]="_checked">
|
||||
<div class="checkbox-inner"></div>
|
||||
</div>
|
||||
<button role="checkbox"
|
||||
type="button"
|
||||
category="item-cover"
|
||||
[id]="id"
|
||||
[attr.aria-checked]="_checked"
|
||||
[attr.aria-labelledby]="_labelId"
|
||||
[attr.aria-disabled]="_disabled"
|
||||
class="item-cover">
|
||||
</button>
|
||||
`,
|
||||
host: {
|
||||
'[class.checkbox-disabled]': '_disabled'
|
||||
},
|
||||
|
Reference in New Issue
Block a user