@schemater/bootstrap-color
TypeScript icon, indicating that this package has built-in type declarations

2.1.0 • Public • Published

Color input field for @schemater/core dependent on ngx-color-picker

Usage

  1. Import SchematerBootstrapColorModule to Your project
  2. Add InputColorComponent into Your SchematerCore.forRoot configuration to inputComponents. You can pick name as You want. Example: {name: 'color', component: InputColorComponent}
  3. You can add styles @import '@schemater/bootstrap-color/colorpicker.scss

Available options (in field.config)

  • getPresetColorsFromBootstrapVariables: boolean - tries to fetch colors from bootstrap variables. presetColors are ignored

  • presetColors: string[] - array of preset colors. Example: ['#fff', '#000', '#2889e9', '#e920e9', '#fff500', 'rgb(236,64,64)']

  • label: string - text to print inside colorpicker button

  • defaultColor: string - color (in hex) that will be applied if is null or undefined at init

Readme

Keywords

none

Package Sidebar

Install

npm i @schemater/bootstrap-color

Weekly Downloads

0

Version

2.1.0

License

none

Unpacked Size

32.7 kB

Total Files

17

Last publish

Collaborators

  • piernik