katschangular-three-states-toggle
v1.0.1
Published
Simple Toggle Switch with three states based on Angular Material
Downloads
37
Maintainers
Readme
Katschangular Three States Toggle
Simple Angular Toggle Switch with three states: true
, false
, and null
/undefined
.
See the demo
What is this
This is a simple Angular Component which supports next to the states true
or false
a thirs state that is null
/undefined
.
It is based on Angular Material
Quick start
<katschangular-three-states-toggle
color="accent"
[label]="label"
[disabled]="disabled"
[(value)]="value">
</katschangular-three-states-toggle>
Detailed instructions
A recommended way to install katschangular-three-states-toggle is through npm package manager using the following command:
npm i -S katschangular-three-states-toggle
Import
KatschangularThreeStatesToggleModule
into the module that declares the component using katschangular-three-states-toggle:import { KatschangularThreeStatesToggleModule } from 'katschangular-three-states-toggle';
Add it to
[imports]
under@NgModule
:imports: [ ... KatschangularThreeStatesToggleModule, ... ]
Use the component in your Template:
<katschangular-three-states-toggle color="accent" [label]="label" [disabled]="disabled" [(value)]="value"> </katschangular-three-states-toggle>