1 |
|
2 |
|
3 |
|
4 | export declare type Color = string | RGBA | HSLA | ColorTransformation;
|
5 | export declare namespace Color {
|
6 | function rgba(r: number, g: number, b: number, a?: number): Color;
|
7 | function hsla(h: number, s: number, l: number, a?: number): Color;
|
8 | const white: Color;
|
9 | const black: Color;
|
10 | function transparent(v: string, f: number): ColorTransformation;
|
11 | function lighten(v: string, f: number): ColorTransformation;
|
12 | function darken(v: string, f: number): ColorTransformation;
|
13 | }
|
14 | export interface ColorTransformation {
|
15 | kind: 'transparent' | 'lighten' | 'darken';
|
16 | v: string;
|
17 | f: number;
|
18 | }
|
19 | export interface RGBA {
|
20 | |
21 |
|
22 |
|
23 | readonly r: number;
|
24 | |
25 |
|
26 |
|
27 | readonly g: number;
|
28 | |
29 |
|
30 |
|
31 | readonly b: number;
|
32 | |
33 |
|
34 |
|
35 | readonly a: number;
|
36 | }
|
37 | export interface HSLA {
|
38 | |
39 |
|
40 |
|
41 | readonly h: number;
|
42 | |
43 |
|
44 |
|
45 | readonly s: number;
|
46 | |
47 |
|
48 |
|
49 | readonly l: number;
|
50 | |
51 |
|
52 |
|
53 | readonly a: number;
|
54 | }
|
55 | export interface ColorDefaults {
|
56 | light?: Color;
|
57 | dark?: Color;
|
58 |
|
59 | hc?: Color;
|
60 | hcDark?: Color;
|
61 | hcLight?: Color;
|
62 | }
|
63 | export interface ColorDefinition {
|
64 | id: string;
|
65 | defaults?: ColorDefaults;
|
66 | description: string;
|
67 | }
|
68 | export interface ColorCssVariable {
|
69 | name: string;
|
70 | value: string;
|
71 | }
|
72 |
|
\ | No newline at end of file |