ngx-material-color-picker
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

ngx-material-color-picker

npm npm

Unique material color picker concept for Angular (ngx). Requires a dependency for flex-layouts and material themeing/colors. Uses reactive forms to create a custom form control.

Example Image

  1. npm i ngx-material-color-picker --s
  2. Add NgxMaterialColorPickerModule to your feature module.
import { NgxMaterialColorPickerModule } from 'ngx-material-color-picker';

...
imports: [
    NgxMaterialColorPickerModule
]
...

Usage

<div [formGroup]="form">
    <ngx-material-color-picker formControlName="color" [intensity]="form.get('intensity').value"></ngx-material-color-picker>
    <md-slider max="900" min="100" step="100" tickInterval="100" formControlName="intensity"></md-slider>
</div>
 
form: FormGroup;
 
constructor(private fb: FormBuilder) { }
 
ngOnInit() {
    this.form = this.fb.group({
        color: [''],
        intensity: [500]
    });
}

Contributors

Sean perkins
Sean Perkins

Readme

Keywords

none

Package Sidebar

Install

npm i ngx-material-color-picker

Weekly Downloads

1

Version

1.0.0

License

ISC

Last publish

Collaborators

  • sean-perkins