@schemater/bootstrap-color
v2.1.0
Published
Color input field for `@schemater/core` dependent on [ngx-color-picker](https://github.com/zefoy/ngx-color-picker)
Downloads
4
Readme
Color input field for @schemater/core
dependent on ngx-color-picker
Usage
- Import
SchematerBootstrapColorModule
to Your project - Add
InputColorComponent
into YourSchematerCore.forRoot
configuration toinputComponents
. You can pick name as You want. Example:{name: 'color', component: InputColorComponent}
- 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 ignoredpresetColors: string[]
- array of preset colors. Example:['#fff', '#000', '#2889e9', '#e920e9', '#fff500', 'rgb(236,64,64)']
label: string
- text to print inside colorpicker buttondefaultColor: string
- color (in hex) that will be applied if is null or undefined at init