UNPKG

2.68 kBPlain TextView Raw
1import type {
2 backgroundColors,
3 borderColors,
4 borderWidths,
5 boxShadows,
6 colorSchemes,
7 colors,
8 dataVisualization,
9 fontSizes,
10 fontWeights,
11 fonts,
12 lineHeights,
13 radii,
14 sizings,
15 spacings,
16 textColors,
17 zIndices,
18} from "../dist/tokens.common";
19
20export type GenericBackgroundColors = Partial<{ [key in keyof typeof backgroundColors]: any }>;
21export type GenericBorderColors = Partial<{ [key in keyof typeof borderColors]: any }>;
22export type GenericBorderWidths = Partial<{ [key in keyof typeof borderWidths]: any }>;
23export type GenericRadii = Partial<{ [key in keyof typeof radii]: any }>;
24export type GenericColors = Partial<{ [key in keyof typeof colors]: any }>;
25export type GenericColorSchemes = Partial<{ [key in keyof typeof colorSchemes]: any }>;
26export type GenericDataVisualization = Partial<{ [key in keyof typeof dataVisualization]: any }>;
27export type GenericFonts = Partial<{ [key in keyof typeof fonts]: any }>;
28export type GenericFontSizes = Partial<{ [key in keyof typeof fontSizes]: any }>;
29export type GenericFontWeights = Partial<{ [key in keyof typeof fontWeights]: any }>;
30export type GenericLineHeights = Partial<{ [key in keyof typeof lineHeights]: any }>;
31export type GenericBoxShadows = Partial<{ [key in keyof typeof boxShadows]: any }>;
32export type GenericSizings = Partial<{ [key in keyof typeof sizings]: any }>;
33export type GenericSpacings = Partial<{ [key in keyof typeof spacings]: any }>;
34export type GenericTextColors = Partial<{ [key in keyof typeof textColors]: any }>;
35export type GenericZIndices = Partial<{ [key in keyof typeof zIndices]: any }>;
36
37/** Flat list of all Paste Design Tokens with generic values */
38export type AllGenericTokens = GenericBackgroundColors &
39 GenericBorderColors &
40 GenericBorderWidths &
41 GenericRadii &
42 GenericColors &
43 GenericColorSchemes &
44 GenericDataVisualization &
45 GenericFonts &
46 GenericFontSizes &
47 GenericFontWeights &
48 GenericLineHeights &
49 GenericBoxShadows &
50 GenericSizings &
51 GenericSpacings &
52 GenericTextColors &
53 GenericZIndices;
54
55/** Categorized list of Design Tokens with generic values */
56export interface GenericTokensShape {
57 backgroundColors: GenericBackgroundColors;
58 borderColors: GenericBorderColors;
59 borderWidths: GenericBorderWidths;
60 colorSchemes: GenericColorSchemes;
61 radii: GenericRadii;
62 colors: GenericColors;
63 dataVisualization: GenericDataVisualization;
64 fonts: GenericFonts;
65 fontSizes: GenericFontSizes;
66 fontWeights: GenericFontWeights;
67 lineHeights: GenericLineHeights;
68 boxShadows: GenericBoxShadows;
69 sizings: GenericSizings;
70 spacings: GenericSpacings;
71 textColors: GenericTextColors;
72 zIndices: GenericZIndices;
73}