@ngx-mce/color-picker 21.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +93 -0
- package/fesm2022/ngx-mce-color-picker.mjs +1251 -0
- package/fesm2022/ngx-mce-color-picker.mjs.map +1 -0
- package/package.json +58 -0
- package/types/ngx-mce-color-picker.d.ts +386 -0
package/README.md
ADDED
|
@@ -0,0 +1,93 @@
|
|
|
1
|
+
# Angular Material Color Picker for @angular/material 7.x, 8.x, 9.x, 10.x, 11.x, 12.x, 13.x, 14.x, 15.x, 16.x
|
|
2
|
+
|
|
3
|
+
[](https://travis-ci.com/h2qutc/angular-material-components)
|
|
4
|
+
[](https://www.npmjs.com/package/angular-material-components)
|
|
5
|
+
[](https://www.npmjs.com/package/@ngx-mce/color-picker)
|
|
6
|
+
|
|
7
|
+
## Description
|
|
8
|
+
|
|
9
|
+
An Angular Material Color Picker.
|
|
10
|
+
|
|
11
|
+
<a href="https://buymeacoffee.com/fbf.prog64" target="_blank"><img src="https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png" alt="Buy Me A Coffee" style="height: 60px !important;width: 217px !important;" ></a>
|
|
12
|
+
|
|
13
|
+
## DEMO
|
|
14
|
+
|
|
15
|
+
@see [DEMO stackblitz](https://stackblitz.com/edit/demo-ngx-mat-color-picker)
|
|
16
|
+
|
|
17
|
+

|
|
18
|
+
|
|
19
|
+
Choose the version corresponding to your Angular version:
|
|
20
|
+
|
|
21
|
+
| Angular | @ngx-mce/color-picker |
|
|
22
|
+
| ------- | ------------------------------- |
|
|
23
|
+
| 16 | 16.x+ |
|
|
24
|
+
| 15 | 15.x+ OR 9.x+ for legacy import |
|
|
25
|
+
| 14 | 8.x+ |
|
|
26
|
+
| 13 | 7.x+ |
|
|
27
|
+
| 12 | 6.x+ |
|
|
28
|
+
| 11 | 5.x+ |
|
|
29
|
+
| 10 | 4.x+ |
|
|
30
|
+
| 9 | 2.x+ |
|
|
31
|
+
| 8 | 2.x+ |
|
|
32
|
+
| 7 | 2.x+ |
|
|
33
|
+
|
|
34
|
+
## Getting started
|
|
35
|
+
|
|
36
|
+
```
|
|
37
|
+
npm install --save @ngx-mce/color-picker
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
## Setup
|
|
41
|
+
|
|
42
|
+
```
|
|
43
|
+
import { MAT_COLOR_FORMATS, NgxMatColorPickerModule, NGX_MAT_COLOR_FORMATS } from '@ngx-mce/color-picker';
|
|
44
|
+
|
|
45
|
+
@NgModule({
|
|
46
|
+
...
|
|
47
|
+
imports: [
|
|
48
|
+
...
|
|
49
|
+
NgxMatColorPickerModule
|
|
50
|
+
],
|
|
51
|
+
providers: [
|
|
52
|
+
{ provide: MAT_COLOR_FORMATS, useValue: NGX_MAT_COLOR_FORMATS }
|
|
53
|
+
],
|
|
54
|
+
...
|
|
55
|
+
})
|
|
56
|
+
export class AppModule { }
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
@see
|
|
60
|
+
[src/app/demo-colorpicker/demo-colorpicker.module.ts](src/app/demo-colorpicker/demo-colorpicker.module.ts)
|
|
61
|
+
|
|
62
|
+
## Using the component
|
|
63
|
+
|
|
64
|
+
### Color Picker (ngx-mat-color-picker)
|
|
65
|
+
|
|
66
|
+
```
|
|
67
|
+
<mat-form-field>
|
|
68
|
+
<input matInput [ngxMatColorPicker]="picker" [formControl]="colorCtr" [disabled]="disabled">
|
|
69
|
+
<ngx-mat-color-toggle matSuffix [for]="picker"></ngx-mat-color-toggle>
|
|
70
|
+
<ngx-mat-color-picker #picker [touchUi]="touchUi" [color]="color"></ngx-mat-color-picker>
|
|
71
|
+
</mat-form-field>
|
|
72
|
+
```
|
|
73
|
+
|
|
74
|
+
#### List of @Input
|
|
75
|
+
|
|
76
|
+
| @Input | Type | Default value | Description |
|
|
77
|
+
| ------------ | ------- | ------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
78
|
+
| **disabled** | boolean | null | If true, the picker is readonly and can't be modified |
|
|
79
|
+
| **touchUi** | boolean | false | Whether the calendar UI is in touch mode. In touch mode the calendar opens in a dialog rather than a popup and elements have more padding to allow for bigger touch targets. |
|
|
80
|
+
|
|
81
|
+
## Theming
|
|
82
|
+
|
|
83
|
+
- @see @angular/material
|
|
84
|
+
[Using a pre-built theme](https://material.angular.io/guide/theming#using-a-pre-built-theme)
|
|
85
|
+
- Add the Material Design icon font to your index.html
|
|
86
|
+
|
|
87
|
+
```
|
|
88
|
+
<link href="https://fonts.googleapis.com/icon?family=Material+Icons&display=block" rel="stylesheet">
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
## License
|
|
92
|
+
|
|
93
|
+
MIT
|