This project was generated with Angular CLI version 13.3.11.
基于ng-zorro-antd nz-color-picker 组件实现,适用于小于17版本的angular项目
#use npm
npm install @geom_team/ngx-color-picker
#use yarn
yarn add @geom_team/ngx-color-picker
import { NgxColorPickerModule } from '@geom_team/ngx-color-picker'
@NgModule({
declarations: [
// ...
],
imports: [
NgxColorPickerModule
],
providers: [],
bootstrap: [
// ...
]
})
export class AppModule { }
<ngx-color-picker nzShowText [nzDisabledFormat]="true" [(ngModel)]="color" (ngModelChange)="changeColor($event)"></ngx-color-picker>
属性及事件方法与nz-color-picker组件一致