1 |
|
2 |
|
3 |
|
4 |
|
5 |
|
6 |
|
7 |
|
8 |
|
9 |
|
10 |
|
11 | export type EnableCustomFonts = boolean;
|
12 |
|
13 |
|
14 |
|
15 | export type ConfigurationVersion = string;
|
16 | export type IFontFace = IFontFacePrimitive[] | IFontFacePrimitive;
|
17 | export type IFontFacePrimitive = IFontFaceCamel | IFontFaceCanonical;
|
18 | export type IFontFaceCamel = {
|
19 | fontFamily: string;
|
20 | [k: string]: any | undefined;
|
21 | } & IFontFaceCommon;
|
22 |
|
23 |
|
24 |
|
25 |
|
26 | export type ICSSOM =
|
27 | | ICSSOMPrimitive
|
28 | | ICSSOMPrimitive[]
|
29 | | {
|
30 | [k: string]: ICSSOM;
|
31 | };
|
32 | export type ICSSOMPrimitive = string | number;
|
33 | export type IFontFaceCanonical = {
|
34 | 'font-family': string;
|
35 | [k: string]: any | undefined;
|
36 | } & IFontFaceCommon;
|
37 |
|
38 |
|
39 |
|
40 |
|
41 | export interface Fonts {
|
42 | enabled?: EnableCustomFonts;
|
43 | version?: ConfigurationVersion;
|
44 | styles?: GlobalStyles;
|
45 | fonts?: EmbeddedFonts;
|
46 | fontLicenses?: EmbeddedFontLicenses;
|
47 | [k: string]: any | undefined;
|
48 | }
|
49 |
|
50 |
|
51 |
|
52 | export interface GlobalStyles {
|
53 | '@font-face'?: IFontFace;
|
54 | ':root'?: IJSSRoot;
|
55 | [k: string]: (ICSSOM | IJSS | IFontFace | IJSSRoot) | undefined;
|
56 | }
|
57 | export interface IFontFaceCommon {
|
58 | src: ICSSOM;
|
59 | 'unicode-range'?: ICSSOM;
|
60 | 'font-variant'?: ICSSOM;
|
61 | 'font-feature-settings'?: ICSSOM;
|
62 | 'font-variation-settings'?: ICSSOM;
|
63 | 'font-stretch'?: ICSSOM;
|
64 | 'font-weight'?: ICSSOM;
|
65 | 'font-style'?: ICSSOM;
|
66 | unicodeRange?: ICSSOM;
|
67 | fontVariant?: ICSSOM;
|
68 | fontFeatureSettings?: ICSSOM;
|
69 | fontVariationSettings?: ICSSOM;
|
70 | fontStretch?: ICSSOM;
|
71 | fontWeight?: ICSSOM;
|
72 | fontStyle?: ICSSOM;
|
73 | [k: string]: any | undefined;
|
74 | }
|
75 | export interface IJSSRoot {
|
76 | [k: string]: ICSSOM;
|
77 | }
|
78 | export interface IJSS {
|
79 | [k: string]:
|
80 | | (
|
81 | | IJSS
|
82 | | {
|
83 | [k: string]: any | undefined;
|
84 | }
|
85 | )
|
86 | | undefined;
|
87 | }
|
88 |
|
89 |
|
90 |
|
91 | export interface EmbeddedFonts {
|
92 | [k: string]: IFontFacePrimitive[] | undefined;
|
93 | }
|
94 |
|
95 |
|
96 |
|
97 | export interface EmbeddedFontLicenses {
|
98 | [k: string]: IFontLicensePrimitive;
|
99 | }
|
100 |
|
101 |
|
102 |
|
103 |
|
104 | export interface IFontLicensePrimitive {
|
105 | name: string;
|
106 | spdx: string;
|
107 | text: string;
|
108 | holders: string[];
|
109 | [k: string]: any | undefined;
|
110 | }
|