@hive-ui/style-props 0.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/dist/index.d.mts +433 -0
- package/dist/index.mjs +454 -0
- package/package.json +34 -0
package/dist/index.d.mts
ADDED
|
@@ -0,0 +1,433 @@
|
|
|
1
|
+
import { Properties, Property } from "csstype";
|
|
2
|
+
|
|
3
|
+
//#region src/shared.d.ts
|
|
4
|
+
type TLengthStyledSystem = string | number;
|
|
5
|
+
type Theme<TLength = TLengthStyledSystem> = {
|
|
6
|
+
breakpoints?: ObjectOrArray<string>;
|
|
7
|
+
mediaQueries?: {
|
|
8
|
+
[size: string]: string;
|
|
9
|
+
};
|
|
10
|
+
spaces?: ObjectOrArray<Property.Margin<number | string>>;
|
|
11
|
+
fontSizes?: ObjectOrArray<Property.FontSize<number>>;
|
|
12
|
+
colors?: ObjectOrArray<Property.Color>;
|
|
13
|
+
fonts?: ObjectOrArray<Property.FontFamily>;
|
|
14
|
+
fontWeights?: ObjectOrArray<Property.FontWeight>;
|
|
15
|
+
lineHeights?: ObjectOrArray<Property.LineHeight<TLength>>;
|
|
16
|
+
letterSpacings?: ObjectOrArray<Property.LetterSpacing<TLength>>;
|
|
17
|
+
sizes?: ObjectOrArray<Property.Height<TLength> | Property.Width<TLength>>;
|
|
18
|
+
borders?: ObjectOrArray<Property.Border<TLength>>;
|
|
19
|
+
borderStyles?: ObjectOrArray<Property.BorderStyle>;
|
|
20
|
+
borderWidths?: ObjectOrArray<Property.BorderWidth<TLength>>;
|
|
21
|
+
radii?: ObjectOrArray<Property.BorderRadius<TLength>>;
|
|
22
|
+
shadows?: ObjectOrArray<Property.BoxShadow>;
|
|
23
|
+
zIndices?: ObjectOrArray<Property.ZIndex>;
|
|
24
|
+
};
|
|
25
|
+
type ObjectOrArray<T, K extends keyof any = keyof any> = T[] | Record<K, T | Record<K, T> | T[]>;
|
|
26
|
+
type ThemeValue<K extends keyof ThemeType, ThemeType, TVal = any> = ThemeType[K] extends TVal[] ? number : ThemeType[K] extends Record<infer E, TVal> ? E : ThemeType[K] extends ObjectOrArray<infer F> ? F : never;
|
|
27
|
+
type RequiredTheme = Required<Theme>;
|
|
28
|
+
type ResponsiveValue<T, ThemeType extends Theme = RequiredTheme> = T | null | Array<T | null> | { [key in (ThemeValue<"breakpoints", ThemeType> & string) | number]?: T };
|
|
29
|
+
//#endregion
|
|
30
|
+
//#region src/background.d.ts
|
|
31
|
+
declare const BACKGROUND_COLOR_TOKENS: readonly ["colorBackground", "colorBackgroundAvailable", "colorBackgroundBody", "colorBackgroundBodyElevation", "colorBackgroundBodyElevationPrimary", "colorBackgroundBodyInverse", "colorBackgroundBrand", "colorBackgroundBrand10", "colorBackgroundBrand20", "colorBackgroundBrand30", "colorBackgroundBrandHighlight", "colorBackgroundBrandHighlightWeakest", "colorBackgroundBrandStrong", "colorBackgroundBrandStronger", "colorBackgroundBusy", "colorBackgroundDecorative10Weakest", "colorBackgroundDecorative20Weakest", "colorBackgroundDecorative30Weakest", "colorBackgroundDecorative40Weakest", "colorBackgroundDestructive", "colorBackgroundDestructiveStrong", "colorBackgroundDestructiveStronger", "colorBackgroundDestructiveStrongest", "colorBackgroundDestructiveWeak", "colorBackgroundDestructiveWeaker", "colorBackgroundDestructiveWeakest", "colorBackgroundElevation", "colorBackgroundError", "colorBackgroundErrorStrong", "colorBackgroundErrorStronger", "colorBackgroundErrorStrongest", "colorBackgroundErrorWeakest", "colorBackgroundInverse", "colorBackgroundInverseElevation", "colorBackgroundInverseStrong", "colorBackgroundInverseStrongElevation", "colorBackgroundInverseStronger", "colorBackgroundInverseStrongerElevation", "colorBackgroundInverseStrongest", "colorBackgroundInverseWeakElevation", "colorBackgroundNeutralWeakest", "colorBackgroundNew", "colorBackgroundNewWeakest", "colorBackgroundNotification", "colorBackgroundOffline", "colorBackgroundOverlay", "colorBackgroundPrimary", "colorBackgroundPrimaryStrong", "colorBackgroundPrimaryStronger", "colorBackgroundPrimaryStrongest", "colorBackgroundPrimaryWeak", "colorBackgroundPrimaryWeaker", "colorBackgroundPrimaryWeakest", "colorBackgroundRequired", "colorBackgroundRowStriped", "colorBackgroundStrong", "colorBackgroundStrongElevation", "colorBackgroundStronger", "colorBackgroundStrongest", "colorBackgroundSubaccount", "colorBackgroundSuccess", "colorBackgroundSuccessWeakest", "colorBackgroundTrial", "colorBackgroundUnavailable", "colorBackgroundUser", "colorBackgroundWarning", "colorBackgroundWarningWeakest", "colorBackgroundWeak", "colorBackgroundWeakElevation", "colorBackgroundWeaker", "colorBackgroundWeakerElevation", "colorBackgroundWeakest"];
|
|
32
|
+
type BackgroundColorToken = (typeof BACKGROUND_COLOR_TOKENS)[number];
|
|
33
|
+
type BackgroundColor = ResponsiveValue<BackgroundColorToken>;
|
|
34
|
+
type BackgroundImageOptions = Properties["backgroundImage"];
|
|
35
|
+
type BackgroundSizeOptions = Properties["backgroundSize"];
|
|
36
|
+
type BackgroundPositionOptions = Properties["backgroundPosition"];
|
|
37
|
+
type BackgroundRepeatOptions = Properties["backgroundRepeat"];
|
|
38
|
+
type BackgroundAttachmentOptions = Properties["backgroundAttachment"];
|
|
39
|
+
type BackgroundImage = ResponsiveValue<BackgroundImageOptions>;
|
|
40
|
+
type BackgroundSize = ResponsiveValue<BackgroundSizeOptions>;
|
|
41
|
+
type BackgroundPosition = ResponsiveValue<BackgroundPositionOptions>;
|
|
42
|
+
type BackgroundRepeat = ResponsiveValue<BackgroundRepeatOptions>;
|
|
43
|
+
type BackgroundAttachment = ResponsiveValue<BackgroundAttachmentOptions>;
|
|
44
|
+
type BackgroundProps = {
|
|
45
|
+
/**
|
|
46
|
+
* Responsive prop of BackgroundColor tokens for the CSS `background-color` property
|
|
47
|
+
*
|
|
48
|
+
* @type {BackgroundColor}
|
|
49
|
+
* @memberof BackgroundProps
|
|
50
|
+
*/
|
|
51
|
+
backgroundColor?: BackgroundColor;
|
|
52
|
+
/**
|
|
53
|
+
* Responsive prop for the CSS `background-image` property
|
|
54
|
+
*
|
|
55
|
+
* @type {BackgroundImage}
|
|
56
|
+
* @memberof BackgroundProps
|
|
57
|
+
*/
|
|
58
|
+
backgroundImage?: BackgroundImage;
|
|
59
|
+
/**
|
|
60
|
+
* Responsive prop for the CSS `background-size` property
|
|
61
|
+
*
|
|
62
|
+
* @type {BackgroundSize}
|
|
63
|
+
* @memberof BackgroundProps
|
|
64
|
+
*/
|
|
65
|
+
backgroundSize?: BackgroundSize;
|
|
66
|
+
/**
|
|
67
|
+
* Responsive prop for the CSS `background-position` property
|
|
68
|
+
*
|
|
69
|
+
* @type {BackgroundPosition}
|
|
70
|
+
* @memberof BackgroundProps
|
|
71
|
+
*/
|
|
72
|
+
backgroundPosition?: BackgroundPosition;
|
|
73
|
+
/**
|
|
74
|
+
* Responsive prop for the CSS `background-repeat` property
|
|
75
|
+
*
|
|
76
|
+
* @type {BackgroundRepeat}
|
|
77
|
+
* @memberof BackgroundProps
|
|
78
|
+
*/
|
|
79
|
+
backgroundRepeat?: BackgroundRepeat;
|
|
80
|
+
/**
|
|
81
|
+
* Responsive prop for the CSS `background-attachment` property
|
|
82
|
+
*
|
|
83
|
+
* @type {BackgroundAttachment}
|
|
84
|
+
* @memberof BackgroundProps
|
|
85
|
+
*/
|
|
86
|
+
backgroundAttachment?: BackgroundAttachment;
|
|
87
|
+
};
|
|
88
|
+
//#endregion
|
|
89
|
+
//#region src/border.d.ts
|
|
90
|
+
declare const BORDER_COLOR_TOKENS: readonly ["colorBorder", "colorBorderDecorative10Weaker", "colorBorderDecorative20Weaker", "colorBorderDecorative30Weaker", "colorBorderDecorative40Weaker", "colorBorderDestructive", "colorBorderDestructiveStrong", "colorBorderDestructiveStronger", "colorBorderDestructiveStrongest", "colorBorderDestructiveWeak", "colorBorderDestructiveWeaker", "colorBorderDestructiveWeakest", "colorBorderError", "colorBorderErrorStrong", "colorBorderErrorStronger", "colorBorderErrorStrongest", "colorBorderErrorWeak", "colorBorderErrorWeaker", "colorBorderErrorWeakest", "colorBorderInverse", "colorBorderInverseStrong", "colorBorderInverseStronger", "colorBorderInverseStrongest", "colorBorderInverseWeaker", "colorBorderInverseWeakest", "colorBorderNeutral", "colorBorderNeutralWeak", "colorBorderNeutralWeaker", "colorBorderNewWeak", "colorBorderNewWeaker", "colorBorderPrimary", "colorBorderPrimaryStrong", "colorBorderPrimaryStronger", "colorBorderPrimaryStrongest", "colorBorderPrimaryWeak", "colorBorderPrimaryWeaker", "colorBorderPrimaryWeakest", "colorBorderStrong", "colorBorderSuccess", "colorBorderSuccessWeak", "colorBorderSuccessWeaker", "colorBorderSuccessWeakest", "colorBorderUser", "colorBorderWarning", "colorBorderWarningWeak", "colorBorderWarningWeaker", "colorBorderWarningWeakest", "colorBorderWeak", "colorBorderWeaker", "colorBorderWeakest"];
|
|
91
|
+
type BorderColorToken = (typeof BORDER_COLOR_TOKENS)[number];
|
|
92
|
+
type BorderColor = ResponsiveValue<BorderColorToken>;
|
|
93
|
+
type BorderColorProps = {
|
|
94
|
+
/**
|
|
95
|
+
* Responsive prop of BorderColor tokens for the CSS `border-color` property
|
|
96
|
+
*
|
|
97
|
+
* @type {BorderColor}
|
|
98
|
+
* @memberof BorderColorProps
|
|
99
|
+
*/
|
|
100
|
+
borderColor?: BorderColor;
|
|
101
|
+
/**
|
|
102
|
+
* Responsive prop of BorderColor tokens for the CSS `border-bottom-color` property
|
|
103
|
+
*
|
|
104
|
+
* @type {BorderColor}
|
|
105
|
+
* @memberof BorderColorProps
|
|
106
|
+
*/
|
|
107
|
+
borderBottomColor?: BorderColor;
|
|
108
|
+
/**
|
|
109
|
+
* Responsive prop of BorderColor tokens for the CSS `border-left-color` property
|
|
110
|
+
*
|
|
111
|
+
* @type {BorderColor}
|
|
112
|
+
* @memberof BorderColorProps
|
|
113
|
+
*/
|
|
114
|
+
borderLeftColor?: BorderColor;
|
|
115
|
+
/**
|
|
116
|
+
* Responsive prop of BorderColor tokens for the CSS `border-right-color` property
|
|
117
|
+
*
|
|
118
|
+
* @type {BorderColor}
|
|
119
|
+
* @memberof BorderColorProps
|
|
120
|
+
*/
|
|
121
|
+
borderRightColor?: BorderColor;
|
|
122
|
+
/**
|
|
123
|
+
* Responsive prop of BorderColor tokens for the CSS `border-top-color` property
|
|
124
|
+
*
|
|
125
|
+
* @type {BorderColor}
|
|
126
|
+
* @memberof BorderColorProps
|
|
127
|
+
*/
|
|
128
|
+
borderTopColor?: BorderColor;
|
|
129
|
+
};
|
|
130
|
+
declare const RADII_TOKENS: readonly ["borderRadius0", "borderRadius10", "borderRadius20", "borderRadius30", "borderRadius40", "borderRadius50", "borderRadius60", "borderRadius70", "borderRadius80", "borderRadius90", "borderRadiusCircle", "borderRadiusPill"];
|
|
131
|
+
type RadiiOptions = (typeof RADII_TOKENS)[number];
|
|
132
|
+
type BorderRadius = ResponsiveValue<RadiiOptions>;
|
|
133
|
+
type BorderRadiusProps = {
|
|
134
|
+
/**
|
|
135
|
+
* Responsive prop of BorderRadius tokens for the CSS `border-radius` property
|
|
136
|
+
*
|
|
137
|
+
* @type {BorderRadius}
|
|
138
|
+
* @memberof BorderRadiusProps
|
|
139
|
+
*/
|
|
140
|
+
borderRadius?: BorderRadius;
|
|
141
|
+
/**
|
|
142
|
+
* Responsive prop of BorderRadius tokens for the CSS `border-bottom-left-radius` property
|
|
143
|
+
*
|
|
144
|
+
* @type {BorderRadius}
|
|
145
|
+
* @memberof BorderRadiusProps
|
|
146
|
+
*/
|
|
147
|
+
borderBottomLeftRadius?: BorderRadius;
|
|
148
|
+
/**
|
|
149
|
+
* Responsive prop of BorderRadius tokens for the CSS `border-bottom-right-radius` property
|
|
150
|
+
*
|
|
151
|
+
* @type {BorderRadius}
|
|
152
|
+
* @memberof BorderRadiusProps
|
|
153
|
+
*/
|
|
154
|
+
borderBottomRightRadius?: BorderRadius;
|
|
155
|
+
/**
|
|
156
|
+
* Responsive prop of BorderRadius tokens for the CSS `border-top-left-radius` property
|
|
157
|
+
*
|
|
158
|
+
* @type {BorderRadius}
|
|
159
|
+
* @memberof BorderRadiusProps
|
|
160
|
+
*/
|
|
161
|
+
borderTopLeftRadius?: BorderRadius;
|
|
162
|
+
/**
|
|
163
|
+
* Responsive prop of BorderRadius tokens for the CSS `border-top-right-radius` property
|
|
164
|
+
*
|
|
165
|
+
* @type {BorderRadius}
|
|
166
|
+
* @memberof BorderRadiusProps
|
|
167
|
+
*/
|
|
168
|
+
borderTopRightRadius?: BorderRadius;
|
|
169
|
+
};
|
|
170
|
+
declare const BORDER_WIDTH_TOKENS: readonly ["borderWidth0", "borderWidth10", "borderWidth20", "borderWidth30", "borderWidth40"];
|
|
171
|
+
type BorderWidthToken = (typeof BORDER_WIDTH_TOKENS)[number];
|
|
172
|
+
type BorderWidthOptions = BorderWidthToken;
|
|
173
|
+
type BorderWidth = ResponsiveValue<BorderWidthToken>;
|
|
174
|
+
type BorderWidthProps = {
|
|
175
|
+
/**
|
|
176
|
+
* Responsive prop of BorderWidth tokens for the CSS `border-width` property
|
|
177
|
+
*
|
|
178
|
+
* @type {BorderWidth}
|
|
179
|
+
* @memberof BorderWidthProps
|
|
180
|
+
*/
|
|
181
|
+
borderWidth?: BorderWidth;
|
|
182
|
+
/**
|
|
183
|
+
* Responsive prop of BorderWidth tokens for the CSS `border-bottom-width` property
|
|
184
|
+
*
|
|
185
|
+
* @type {BorderWidth}
|
|
186
|
+
* @memberof BorderWidthProps
|
|
187
|
+
*/
|
|
188
|
+
borderBottomWidth?: BorderWidth;
|
|
189
|
+
/**
|
|
190
|
+
* Responsive prop of BorderWidth tokens for the CSS `border-left-width` property
|
|
191
|
+
*
|
|
192
|
+
* @type {BorderWidth}
|
|
193
|
+
* @memberof BorderWidthProps
|
|
194
|
+
*/
|
|
195
|
+
borderLeftWidth?: BorderWidth;
|
|
196
|
+
/**
|
|
197
|
+
* Responsive prop of BorderWidth tokens for the CSS `border-right-width` property
|
|
198
|
+
*
|
|
199
|
+
* @type {BorderWidth}
|
|
200
|
+
* @memberof BorderWidthProps
|
|
201
|
+
*/
|
|
202
|
+
borderRightWidth?: BorderWidth;
|
|
203
|
+
/**
|
|
204
|
+
* Responsive prop of BorderWidth tokens for the CSS `border-top-width` property
|
|
205
|
+
*
|
|
206
|
+
* @type {BorderWidth}
|
|
207
|
+
* @memberof BorderWidthProps
|
|
208
|
+
*/
|
|
209
|
+
borderTopWidth?: BorderWidth;
|
|
210
|
+
};
|
|
211
|
+
//#endregion
|
|
212
|
+
//#region src/color.d.ts
|
|
213
|
+
declare const COLOR_TOKENS: readonly ["colorText", "colorTextBrand", "colorTextBrandHighlight", "colorTextBrandInverse", "colorTextDecorative10", "colorTextDecorative20", "colorTextDecorative30", "colorTextDecorative40", "colorTextDestructive", "colorTextDestructiveStrong", "colorTextDestructiveStronger", "colorTextDestructiveStrongest", "colorTextDestructiveWeak", "colorTextError", "colorTextErrorStrong", "colorTextErrorStronger", "colorTextErrorStrongest", "colorTextErrorWeak", "colorTextIcon", "colorTextIconAvailable", "colorTextIconBrandHighlight", "colorTextIconBrandInverse", "colorTextIconBusy", "colorTextIconError", "colorTextIconInverse", "colorTextIconNeutral", "colorTextIconNew", "colorTextIconNotification", "colorTextIconOffline", "colorTextIconSuccess", "colorTextIconUnavailable", "colorTextIconWarning", "colorTextInverse", "colorTextInverseNew", "colorTextInverseWeak", "colorTextInverseWeaker", "colorTextInverseWeakest", "colorTextLink", "colorTextLinkDestructive", "colorTextLinkDestructiveStrong", "colorTextLinkDestructiveStronger", "colorTextLinkDestructiveStrongest", "colorTextLinkDestructiveWeak", "colorTextLinkStrong", "colorTextLinkStronger", "colorTextLinkStrongest", "colorTextLinkWeak", "colorTextNeutral", "colorTextNew", "colorTextPrimary", "colorTextPrimaryStrong", "colorTextPrimaryStronger", "colorTextPrimaryStrongest", "colorTextPrimaryWeak", "colorTextSubaccount", "colorTextSuccess", "colorTextUser", "colorTextWarning", "colorTextWarningStrong", "colorTextWeak", "colorTextWeaker", "colorTextWeakest"];
|
|
214
|
+
type ColorToken = (typeof COLOR_TOKENS)[number] | "currentColor" | "inherit";
|
|
215
|
+
type Color = ResponsiveValue<ColorToken>;
|
|
216
|
+
type ColorProps = {
|
|
217
|
+
/**
|
|
218
|
+
* Responsive prop of Color tokens for the CSS `color` property
|
|
219
|
+
*
|
|
220
|
+
* @type {Color}
|
|
221
|
+
* @memberof ColorProps
|
|
222
|
+
*/
|
|
223
|
+
color?: Color;
|
|
224
|
+
};
|
|
225
|
+
//#endregion
|
|
226
|
+
//#region src/icon.d.ts
|
|
227
|
+
declare const SIZE_ICON_TOKENS: readonly ["sizeIcon05", "sizeIcon10", "sizeIcon20", "sizeIcon30", "sizeIcon40", "sizeIcon50", "sizeIcon60", "sizeIcon70", "sizeIcon80", "sizeIcon90", "sizeIcon100", "sizeIcon110"];
|
|
228
|
+
type IconSizeToken = (typeof SIZE_ICON_TOKENS)[number];
|
|
229
|
+
type IconSize = ResponsiveValue<IconSizeToken>;
|
|
230
|
+
type IconSizeProps = {
|
|
231
|
+
/**
|
|
232
|
+
* Responsive prop of IconSize tokens for icon sizing.
|
|
233
|
+
*
|
|
234
|
+
* @type {IconSize}
|
|
235
|
+
* @memberof IconSizeProps
|
|
236
|
+
*/
|
|
237
|
+
size?: IconSize;
|
|
238
|
+
};
|
|
239
|
+
//#endregion
|
|
240
|
+
//#region src/shadow.d.ts
|
|
241
|
+
declare const BOX_SHADOW_TOKENS: readonly ["shadow", "shadowBorder", "shadowBorderBottom", "shadowBorderBottomBrand10Strong", "shadowBorderBottomBrand20Strong", "shadowBorderBottomBrand30Strong", "shadowBorderBottomDecorative10Weaker", "shadowBorderBottomDecorative20Weaker", "shadowBorderBottomDecorative30Weaker", "shadowBorderBottomDecorative40Weaker", "shadowBorderBottomErrorWeaker", "shadowBorderBottomInverseNewWeaker", "shadowBorderBottomInverseWeaker", "shadowBorderBottomInverseWeakerInset", "shadowBorderBottomNeutralWeaker", "shadowBorderBottomNewWeaker", "shadowBorderBottomNotificationStronger", "shadowBorderBottomPrimary", "shadowBorderBottomSubaccount", "shadowBorderBottomSuccessWeaker", "shadowBorderBottomWarningWeaker", "shadowBorderBottomWeak", "shadowBorderBottomWeakInset", "shadowBorderBrand10", "shadowBorderBrand20", "shadowBorderBrand30", "shadowBorderDecorative10Weaker", "shadowBorderDecorative20Weaker", "shadowBorderDecorative30Weaker", "shadowBorderDecorative40Weaker", "shadowBorderDestructive", "shadowBorderDestructiveStrong", "shadowBorderDestructiveStronger", "shadowBorderDestructiveStrongest", "shadowBorderDestructiveWeak", "shadowBorderDestructiveWeaker", "shadowBorderError", "shadowBorderErrorStrong", "shadowBorderErrorStronger", "shadowBorderErrorStrongest", "shadowBorderErrorWeak", "shadowBorderErrorWeaker", "shadowBorderInverse", "shadowBorderInverseNewWeaker", "shadowBorderInverseStrong", "shadowBorderInverseStronger", "shadowBorderInverseStrongest", "shadowBorderInverseWeaker", "shadowBorderInverseWeakest", "shadowBorderNeutralWeaker", "shadowBorderNewWeaker", "shadowBorderNotification", "shadowBorderPrimary", "shadowBorderPrimaryStrong", "shadowBorderPrimaryStronger", "shadowBorderPrimaryStrongest", "shadowBorderPrimaryWeak", "shadowBorderPrimaryWeaker", "shadowBorderRightInverseStrong", "shadowBorderStrong", "shadowBorderSubaccount", "shadowBorderSuccessWeaker", "shadowBorderTopInverseStrongest", "shadowBorderTopPrimary", "shadowBorderTopPrimaryStrongest", "shadowBorderUser", "shadowBorderWarningWeaker", "shadowBorderWeak", "shadowBorderWeaker", "shadowCard", "shadowElevation05", "shadowElevation10", "shadowElevation20", "shadowElevationBottom05", "shadowElevationBottomInverse05", "shadowElevationInverse05", "shadowElevationInverse10", "shadowElevationLeft20", "shadowElevationRightInverse05", "shadowElevationTop05", "shadowElevationTop20", "shadowFocus", "shadowFocusInset", "shadowFocusInverse", "shadowFocusInverseInset", "shadowFocusShadowBorder", "shadowHigh", "shadowLeft", "shadowLeftInverse", "shadowLow", "shadowRight", "shadowRightInverse"];
|
|
242
|
+
type BoxShadowToken = (typeof BOX_SHADOW_TOKENS)[number];
|
|
243
|
+
type BoxShadow = ResponsiveValue<BoxShadowToken | Property.BoxShadow>;
|
|
244
|
+
type BoxShadowProps = {
|
|
245
|
+
/**
|
|
246
|
+
* Responsive prop of BoxShadow tokens for the CSS `box-shadow` property
|
|
247
|
+
*
|
|
248
|
+
* @type {BoxShadow}
|
|
249
|
+
* @memberof BoxShadowProps
|
|
250
|
+
*/
|
|
251
|
+
boxShadow?: BoxShadow;
|
|
252
|
+
};
|
|
253
|
+
//#endregion
|
|
254
|
+
//#region src/space.d.ts
|
|
255
|
+
declare const SPACE_TOKENS: readonly ["space0", "space10", "space20", "space30", "space40", "space50", "space60", "space70", "space80", "space90", "space100", "space110", "space120", "space130", "space140", "space150", "space160", "space170", "space180", "space190", "space200", "space210", "space220", "space230", "space240", "space250", "space260", "space270", "space280", "space290", "space300", "space310", "spaceNegative10", "spaceNegative20", "spaceNegative30", "spaceNegative40", "spaceNegative50", "spaceNegative60", "spaceNegative70", "spaceNegative80", "spaceNegative90", "spaceNegative100", "spaceNegative110", "spaceNegative120", "spaceNegative130", "spaceNegative140", "spaceNegative150", "spaceNegative160", "spaceNegative170", "spaceNegative180", "spaceNegative190", "spaceNegative200"];
|
|
256
|
+
type SpaceOptions = (typeof SPACE_TOKENS)[number];
|
|
257
|
+
type Space = ResponsiveValue<SpaceOptions>;
|
|
258
|
+
type Padding = Space;
|
|
259
|
+
type Margin = ResponsiveValue<SpaceOptions | "auto">;
|
|
260
|
+
type Gap = Space;
|
|
261
|
+
type MarginProps = {
|
|
262
|
+
/**
|
|
263
|
+
* Responsive prop of Space tokens for the CSS `margin` property
|
|
264
|
+
*
|
|
265
|
+
* @type {Margin}
|
|
266
|
+
* @memberof MarginProps
|
|
267
|
+
*/
|
|
268
|
+
margin?: Margin;
|
|
269
|
+
/**
|
|
270
|
+
* Responsive prop of Space tokens for the CSS `margin-top` property
|
|
271
|
+
*
|
|
272
|
+
* @type {Margin}
|
|
273
|
+
* @memberof MarginProps
|
|
274
|
+
*/
|
|
275
|
+
marginTop?: Margin;
|
|
276
|
+
/**
|
|
277
|
+
* Responsive prop of Space tokens for the CSS `margin-right` property
|
|
278
|
+
*
|
|
279
|
+
* @type {Margin}
|
|
280
|
+
* @memberof MarginProps
|
|
281
|
+
*/
|
|
282
|
+
marginRight?: Margin;
|
|
283
|
+
/**
|
|
284
|
+
* Responsive prop of Space tokens for the CSS `margin-bottom` property
|
|
285
|
+
*
|
|
286
|
+
* @type {Margin}
|
|
287
|
+
* @memberof MarginProps
|
|
288
|
+
*/
|
|
289
|
+
marginBottom?: Margin;
|
|
290
|
+
/**
|
|
291
|
+
* Responsive prop of Space tokens for the CSS `margin-left` property
|
|
292
|
+
*
|
|
293
|
+
* @type {Margin}
|
|
294
|
+
* @memberof MarginProps
|
|
295
|
+
*/
|
|
296
|
+
marginLeft?: Margin;
|
|
297
|
+
/**
|
|
298
|
+
* Responsive prop of Space tokens for the CSS `margin-left` and `margin-right` properties
|
|
299
|
+
*
|
|
300
|
+
* @type {Margin}
|
|
301
|
+
* @memberof MarginProps
|
|
302
|
+
*/
|
|
303
|
+
marginX?: Margin;
|
|
304
|
+
/**
|
|
305
|
+
* Responsive prop of Space tokens for the CSS `margin-top` and `margin-bottom` properties
|
|
306
|
+
*
|
|
307
|
+
* @type {Margin}
|
|
308
|
+
* @memberof MarginProps
|
|
309
|
+
*/
|
|
310
|
+
marginY?: Margin;
|
|
311
|
+
};
|
|
312
|
+
type PaddingProps = {
|
|
313
|
+
/**
|
|
314
|
+
* Responsive prop of Space tokens for the CSS `padding` property
|
|
315
|
+
*
|
|
316
|
+
* @type {Padding}
|
|
317
|
+
* @memberof PaddingProps
|
|
318
|
+
*/
|
|
319
|
+
padding?: Padding;
|
|
320
|
+
/**
|
|
321
|
+
* Responsive prop of Space tokens for the CSS `padding-top` property
|
|
322
|
+
*
|
|
323
|
+
* @type {Padding}
|
|
324
|
+
* @memberof PaddingProps
|
|
325
|
+
*/
|
|
326
|
+
paddingTop?: Padding;
|
|
327
|
+
/**
|
|
328
|
+
* Responsive prop of Space tokens for the CSS `padding-right` property
|
|
329
|
+
*
|
|
330
|
+
* @type {Padding}
|
|
331
|
+
* @memberof PaddingProps
|
|
332
|
+
*/
|
|
333
|
+
paddingRight?: Padding;
|
|
334
|
+
/**
|
|
335
|
+
* Responsive prop of Space tokens for the CSS `padding-bottom` property
|
|
336
|
+
*
|
|
337
|
+
* @type {Padding}
|
|
338
|
+
* @memberof PaddingProps
|
|
339
|
+
*/
|
|
340
|
+
paddingBottom?: Padding;
|
|
341
|
+
/**
|
|
342
|
+
* Responsive prop of Space tokens for the CSS `padding-left` property
|
|
343
|
+
*
|
|
344
|
+
* @type {Padding}
|
|
345
|
+
* @memberof PaddingProps
|
|
346
|
+
*/
|
|
347
|
+
paddingLeft?: Padding;
|
|
348
|
+
/**
|
|
349
|
+
* Responsive prop of Space tokens for the CSS `padding-left` and `padding-right` properties
|
|
350
|
+
*
|
|
351
|
+
* @type {Padding}
|
|
352
|
+
* @memberof PaddingProps
|
|
353
|
+
*/
|
|
354
|
+
paddingX?: Padding;
|
|
355
|
+
/**
|
|
356
|
+
* Responsive prop of Space tokens for the CSS `padding-top` and `padding-bottom` properties
|
|
357
|
+
*
|
|
358
|
+
* @type {Padding}
|
|
359
|
+
* @memberof PaddingProps
|
|
360
|
+
*/
|
|
361
|
+
paddingY?: Padding;
|
|
362
|
+
};
|
|
363
|
+
type GapProps = {
|
|
364
|
+
/**
|
|
365
|
+
* Responsive prop of Space tokens for the CSS `column-gap` property
|
|
366
|
+
*
|
|
367
|
+
* @type {Gap}
|
|
368
|
+
* @memberof GapProps
|
|
369
|
+
*/
|
|
370
|
+
columnGap?: Gap;
|
|
371
|
+
rowGap?: Gap;
|
|
372
|
+
};
|
|
373
|
+
type SpaceProps = MarginProps & PaddingProps & GapProps;
|
|
374
|
+
//#endregion
|
|
375
|
+
//#region src/typography.d.ts
|
|
376
|
+
declare const FONT_SIZE_TOKENS: readonly ["fontSize10", "fontSize20", "fontSize30", "fontSize40", "fontSize50", "fontSize60", "fontSize70", "fontSize80", "fontSize90", "fontSize100", "fontSize110", "fontSizeBase", "fontSizeDisplay10", "fontSizeDisplay20", "fontSizeDisplay30"];
|
|
377
|
+
type FontSizeToken = (typeof FONT_SIZE_TOKENS)[number] | "inherit";
|
|
378
|
+
type FontSize = ResponsiveValue<FontSizeToken>;
|
|
379
|
+
declare const FONT_WEIGHT_TOKENS: readonly ["fontWeightLight", "fontWeightNormal", "fontWeightMedium", "fontWeightSemibold", "fontWeightBold", "fontWeightExtrabold"];
|
|
380
|
+
type FontWeightToken = (typeof FONT_WEIGHT_TOKENS)[number] | "inherit";
|
|
381
|
+
type FontWeight = ResponsiveValue<FontWeightToken>;
|
|
382
|
+
declare const LINE_HEIGHT_TOKENS: readonly ["lineHeight0", "lineHeight05", "lineHeight10", "lineHeight20", "lineHeight30", "lineHeight40", "lineHeight50", "lineHeight60", "lineHeight70", "lineHeight80", "lineHeight90", "lineHeight100", "lineHeight110", "lineHeightDisplay10", "lineHeightDisplay20", "lineHeightDisplay30"];
|
|
383
|
+
type LineHeightToken = (typeof LINE_HEIGHT_TOKENS)[number] | "inherit";
|
|
384
|
+
type LineHeight = ResponsiveValue<LineHeightToken>;
|
|
385
|
+
declare const FONT_FAMILY_TOKENS: readonly ["fontFamilyCode", "fontFamilyDisplay", "fontFamilyText", "fontFamilyTextChineseSimplified", "fontFamilyTextChineseTraditional", "fontFamilyTextJapanese", "fontFamilyTextKorean"];
|
|
386
|
+
type FontFamilyToken = (typeof FONT_FAMILY_TOKENS)[number] | "inherit";
|
|
387
|
+
type FontFamily = ResponsiveValue<FontFamilyToken>;
|
|
388
|
+
type TypographyProps = {
|
|
389
|
+
/**
|
|
390
|
+
* Responsive prop of FontSize tokens for the CSS `font-size` property
|
|
391
|
+
*
|
|
392
|
+
* @type {FontSize}
|
|
393
|
+
* @memberof FontSizeProps
|
|
394
|
+
*/
|
|
395
|
+
fontSize?: FontSize;
|
|
396
|
+
/**
|
|
397
|
+
* Responsive prop of FontWeight tokens for the CSS `font-weight` property
|
|
398
|
+
*
|
|
399
|
+
* @type {FontWeight}
|
|
400
|
+
* @memberof FontWeightProps
|
|
401
|
+
*/
|
|
402
|
+
fontWeight?: FontWeight;
|
|
403
|
+
/**
|
|
404
|
+
* Responsive prop of LineHeight tokens for the CSS `line-height` property
|
|
405
|
+
*
|
|
406
|
+
* @type {LineHeight}
|
|
407
|
+
* @memberof LineHeightProps
|
|
408
|
+
*/
|
|
409
|
+
lineHeight?: LineHeight;
|
|
410
|
+
/**
|
|
411
|
+
* Responsive prop of FontFamily tokens for the CSS `font-family` property
|
|
412
|
+
*
|
|
413
|
+
* @type {FontFamily}
|
|
414
|
+
* @memberof FontFamilyProps
|
|
415
|
+
*/
|
|
416
|
+
fontFamily?: FontFamily;
|
|
417
|
+
};
|
|
418
|
+
//#endregion
|
|
419
|
+
//#region src/z-index.d.ts
|
|
420
|
+
declare const Z_INDEX_TOKENS: readonly ["zIndex0", "zIndex10", "zIndex20", "zIndex30", "zIndex40", "zIndex50", "zIndex60", "zIndex70", "zIndex80", "zIndex90"];
|
|
421
|
+
type ZIndexToken = (typeof Z_INDEX_TOKENS)[number];
|
|
422
|
+
type ZIndex = ResponsiveValue<ZIndexToken>;
|
|
423
|
+
type ZIndexProps = {
|
|
424
|
+
/**
|
|
425
|
+
* Responsive prop of ZIndex tokens for the CSS `z-index` property
|
|
426
|
+
*
|
|
427
|
+
* @type {ZIndex}
|
|
428
|
+
* @memberof ZIndexProps
|
|
429
|
+
*/
|
|
430
|
+
zIndex?: ZIndex;
|
|
431
|
+
};
|
|
432
|
+
//#endregion
|
|
433
|
+
export { BACKGROUND_COLOR_TOKENS, BORDER_COLOR_TOKENS, BORDER_WIDTH_TOKENS, BOX_SHADOW_TOKENS, BackgroundAttachment, BackgroundAttachmentOptions, BackgroundColor, BackgroundColorToken, BackgroundImage, BackgroundImageOptions, BackgroundPosition, BackgroundPositionOptions, BackgroundProps, BackgroundRepeat, BackgroundRepeatOptions, BackgroundSize, BackgroundSizeOptions, BorderColor, BorderColorProps, BorderColorToken, BorderRadius, BorderRadiusProps, BorderWidth, BorderWidthOptions, BorderWidthProps, BorderWidthToken, BoxShadow, BoxShadowProps, BoxShadowToken, COLOR_TOKENS, Color, ColorProps, ColorToken, FONT_FAMILY_TOKENS, FONT_SIZE_TOKENS, FONT_WEIGHT_TOKENS, FontFamily, FontFamilyToken, FontSize, FontSizeToken, FontWeight, FontWeightToken, Gap, GapProps, IconSize, IconSizeProps, IconSizeToken, LINE_HEIGHT_TOKENS, LineHeight, LineHeightToken, Margin, MarginProps, ObjectOrArray, Padding, PaddingProps, RADII_TOKENS, RadiiOptions, RequiredTheme, ResponsiveValue, SIZE_ICON_TOKENS, SPACE_TOKENS, Space, SpaceOptions, SpaceProps, TLengthStyledSystem, Theme, ThemeValue, TypographyProps, ZIndex, ZIndexProps, ZIndexToken, Z_INDEX_TOKENS };
|
package/dist/index.mjs
ADDED
|
@@ -0,0 +1,454 @@
|
|
|
1
|
+
//#region src/background.ts
|
|
2
|
+
const BACKGROUND_COLOR_TOKENS = [
|
|
3
|
+
"colorBackground",
|
|
4
|
+
"colorBackgroundAvailable",
|
|
5
|
+
"colorBackgroundBody",
|
|
6
|
+
"colorBackgroundBodyElevation",
|
|
7
|
+
"colorBackgroundBodyElevationPrimary",
|
|
8
|
+
"colorBackgroundBodyInverse",
|
|
9
|
+
"colorBackgroundBrand",
|
|
10
|
+
"colorBackgroundBrand10",
|
|
11
|
+
"colorBackgroundBrand20",
|
|
12
|
+
"colorBackgroundBrand30",
|
|
13
|
+
"colorBackgroundBrandHighlight",
|
|
14
|
+
"colorBackgroundBrandHighlightWeakest",
|
|
15
|
+
"colorBackgroundBrandStrong",
|
|
16
|
+
"colorBackgroundBrandStronger",
|
|
17
|
+
"colorBackgroundBusy",
|
|
18
|
+
"colorBackgroundDecorative10Weakest",
|
|
19
|
+
"colorBackgroundDecorative20Weakest",
|
|
20
|
+
"colorBackgroundDecorative30Weakest",
|
|
21
|
+
"colorBackgroundDecorative40Weakest",
|
|
22
|
+
"colorBackgroundDestructive",
|
|
23
|
+
"colorBackgroundDestructiveStrong",
|
|
24
|
+
"colorBackgroundDestructiveStronger",
|
|
25
|
+
"colorBackgroundDestructiveStrongest",
|
|
26
|
+
"colorBackgroundDestructiveWeak",
|
|
27
|
+
"colorBackgroundDestructiveWeaker",
|
|
28
|
+
"colorBackgroundDestructiveWeakest",
|
|
29
|
+
"colorBackgroundElevation",
|
|
30
|
+
"colorBackgroundError",
|
|
31
|
+
"colorBackgroundErrorStrong",
|
|
32
|
+
"colorBackgroundErrorStronger",
|
|
33
|
+
"colorBackgroundErrorStrongest",
|
|
34
|
+
"colorBackgroundErrorWeakest",
|
|
35
|
+
"colorBackgroundInverse",
|
|
36
|
+
"colorBackgroundInverseElevation",
|
|
37
|
+
"colorBackgroundInverseStrong",
|
|
38
|
+
"colorBackgroundInverseStrongElevation",
|
|
39
|
+
"colorBackgroundInverseStronger",
|
|
40
|
+
"colorBackgroundInverseStrongerElevation",
|
|
41
|
+
"colorBackgroundInverseStrongest",
|
|
42
|
+
"colorBackgroundInverseWeakElevation",
|
|
43
|
+
"colorBackgroundNeutralWeakest",
|
|
44
|
+
"colorBackgroundNew",
|
|
45
|
+
"colorBackgroundNewWeakest",
|
|
46
|
+
"colorBackgroundNotification",
|
|
47
|
+
"colorBackgroundOffline",
|
|
48
|
+
"colorBackgroundOverlay",
|
|
49
|
+
"colorBackgroundPrimary",
|
|
50
|
+
"colorBackgroundPrimaryStrong",
|
|
51
|
+
"colorBackgroundPrimaryStronger",
|
|
52
|
+
"colorBackgroundPrimaryStrongest",
|
|
53
|
+
"colorBackgroundPrimaryWeak",
|
|
54
|
+
"colorBackgroundPrimaryWeaker",
|
|
55
|
+
"colorBackgroundPrimaryWeakest",
|
|
56
|
+
"colorBackgroundRequired",
|
|
57
|
+
"colorBackgroundRowStriped",
|
|
58
|
+
"colorBackgroundStrong",
|
|
59
|
+
"colorBackgroundStrongElevation",
|
|
60
|
+
"colorBackgroundStronger",
|
|
61
|
+
"colorBackgroundStrongest",
|
|
62
|
+
"colorBackgroundSubaccount",
|
|
63
|
+
"colorBackgroundSuccess",
|
|
64
|
+
"colorBackgroundSuccessWeakest",
|
|
65
|
+
"colorBackgroundTrial",
|
|
66
|
+
"colorBackgroundUnavailable",
|
|
67
|
+
"colorBackgroundUser",
|
|
68
|
+
"colorBackgroundWarning",
|
|
69
|
+
"colorBackgroundWarningWeakest",
|
|
70
|
+
"colorBackgroundWeak",
|
|
71
|
+
"colorBackgroundWeakElevation",
|
|
72
|
+
"colorBackgroundWeaker",
|
|
73
|
+
"colorBackgroundWeakerElevation",
|
|
74
|
+
"colorBackgroundWeakest"
|
|
75
|
+
];
|
|
76
|
+
//#endregion
|
|
77
|
+
//#region src/border.ts
|
|
78
|
+
const BORDER_COLOR_TOKENS = [
|
|
79
|
+
"colorBorder",
|
|
80
|
+
"colorBorderDecorative10Weaker",
|
|
81
|
+
"colorBorderDecorative20Weaker",
|
|
82
|
+
"colorBorderDecorative30Weaker",
|
|
83
|
+
"colorBorderDecorative40Weaker",
|
|
84
|
+
"colorBorderDestructive",
|
|
85
|
+
"colorBorderDestructiveStrong",
|
|
86
|
+
"colorBorderDestructiveStronger",
|
|
87
|
+
"colorBorderDestructiveStrongest",
|
|
88
|
+
"colorBorderDestructiveWeak",
|
|
89
|
+
"colorBorderDestructiveWeaker",
|
|
90
|
+
"colorBorderDestructiveWeakest",
|
|
91
|
+
"colorBorderError",
|
|
92
|
+
"colorBorderErrorStrong",
|
|
93
|
+
"colorBorderErrorStronger",
|
|
94
|
+
"colorBorderErrorStrongest",
|
|
95
|
+
"colorBorderErrorWeak",
|
|
96
|
+
"colorBorderErrorWeaker",
|
|
97
|
+
"colorBorderErrorWeakest",
|
|
98
|
+
"colorBorderInverse",
|
|
99
|
+
"colorBorderInverseStrong",
|
|
100
|
+
"colorBorderInverseStronger",
|
|
101
|
+
"colorBorderInverseStrongest",
|
|
102
|
+
"colorBorderInverseWeaker",
|
|
103
|
+
"colorBorderInverseWeakest",
|
|
104
|
+
"colorBorderNeutral",
|
|
105
|
+
"colorBorderNeutralWeak",
|
|
106
|
+
"colorBorderNeutralWeaker",
|
|
107
|
+
"colorBorderNewWeak",
|
|
108
|
+
"colorBorderNewWeaker",
|
|
109
|
+
"colorBorderPrimary",
|
|
110
|
+
"colorBorderPrimaryStrong",
|
|
111
|
+
"colorBorderPrimaryStronger",
|
|
112
|
+
"colorBorderPrimaryStrongest",
|
|
113
|
+
"colorBorderPrimaryWeak",
|
|
114
|
+
"colorBorderPrimaryWeaker",
|
|
115
|
+
"colorBorderPrimaryWeakest",
|
|
116
|
+
"colorBorderStrong",
|
|
117
|
+
"colorBorderSuccess",
|
|
118
|
+
"colorBorderSuccessWeak",
|
|
119
|
+
"colorBorderSuccessWeaker",
|
|
120
|
+
"colorBorderSuccessWeakest",
|
|
121
|
+
"colorBorderUser",
|
|
122
|
+
"colorBorderWarning",
|
|
123
|
+
"colorBorderWarningWeak",
|
|
124
|
+
"colorBorderWarningWeaker",
|
|
125
|
+
"colorBorderWarningWeakest",
|
|
126
|
+
"colorBorderWeak",
|
|
127
|
+
"colorBorderWeaker",
|
|
128
|
+
"colorBorderWeakest"
|
|
129
|
+
];
|
|
130
|
+
const RADII_TOKENS = [
|
|
131
|
+
"borderRadius0",
|
|
132
|
+
"borderRadius10",
|
|
133
|
+
"borderRadius20",
|
|
134
|
+
"borderRadius30",
|
|
135
|
+
"borderRadius40",
|
|
136
|
+
"borderRadius50",
|
|
137
|
+
"borderRadius60",
|
|
138
|
+
"borderRadius70",
|
|
139
|
+
"borderRadius80",
|
|
140
|
+
"borderRadius90",
|
|
141
|
+
"borderRadiusCircle",
|
|
142
|
+
"borderRadiusPill"
|
|
143
|
+
];
|
|
144
|
+
const BORDER_WIDTH_TOKENS = [
|
|
145
|
+
"borderWidth0",
|
|
146
|
+
"borderWidth10",
|
|
147
|
+
"borderWidth20",
|
|
148
|
+
"borderWidth30",
|
|
149
|
+
"borderWidth40"
|
|
150
|
+
];
|
|
151
|
+
//#endregion
|
|
152
|
+
//#region src/color.ts
|
|
153
|
+
const COLOR_TOKENS = [
|
|
154
|
+
"colorText",
|
|
155
|
+
"colorTextBrand",
|
|
156
|
+
"colorTextBrandHighlight",
|
|
157
|
+
"colorTextBrandInverse",
|
|
158
|
+
"colorTextDecorative10",
|
|
159
|
+
"colorTextDecorative20",
|
|
160
|
+
"colorTextDecorative30",
|
|
161
|
+
"colorTextDecorative40",
|
|
162
|
+
"colorTextDestructive",
|
|
163
|
+
"colorTextDestructiveStrong",
|
|
164
|
+
"colorTextDestructiveStronger",
|
|
165
|
+
"colorTextDestructiveStrongest",
|
|
166
|
+
"colorTextDestructiveWeak",
|
|
167
|
+
"colorTextError",
|
|
168
|
+
"colorTextErrorStrong",
|
|
169
|
+
"colorTextErrorStronger",
|
|
170
|
+
"colorTextErrorStrongest",
|
|
171
|
+
"colorTextErrorWeak",
|
|
172
|
+
"colorTextIcon",
|
|
173
|
+
"colorTextIconAvailable",
|
|
174
|
+
"colorTextIconBrandHighlight",
|
|
175
|
+
"colorTextIconBrandInverse",
|
|
176
|
+
"colorTextIconBusy",
|
|
177
|
+
"colorTextIconError",
|
|
178
|
+
"colorTextIconInverse",
|
|
179
|
+
"colorTextIconNeutral",
|
|
180
|
+
"colorTextIconNew",
|
|
181
|
+
"colorTextIconNotification",
|
|
182
|
+
"colorTextIconOffline",
|
|
183
|
+
"colorTextIconSuccess",
|
|
184
|
+
"colorTextIconUnavailable",
|
|
185
|
+
"colorTextIconWarning",
|
|
186
|
+
"colorTextInverse",
|
|
187
|
+
"colorTextInverseNew",
|
|
188
|
+
"colorTextInverseWeak",
|
|
189
|
+
"colorTextInverseWeaker",
|
|
190
|
+
"colorTextInverseWeakest",
|
|
191
|
+
"colorTextLink",
|
|
192
|
+
"colorTextLinkDestructive",
|
|
193
|
+
"colorTextLinkDestructiveStrong",
|
|
194
|
+
"colorTextLinkDestructiveStronger",
|
|
195
|
+
"colorTextLinkDestructiveStrongest",
|
|
196
|
+
"colorTextLinkDestructiveWeak",
|
|
197
|
+
"colorTextLinkStrong",
|
|
198
|
+
"colorTextLinkStronger",
|
|
199
|
+
"colorTextLinkStrongest",
|
|
200
|
+
"colorTextLinkWeak",
|
|
201
|
+
"colorTextNeutral",
|
|
202
|
+
"colorTextNew",
|
|
203
|
+
"colorTextPrimary",
|
|
204
|
+
"colorTextPrimaryStrong",
|
|
205
|
+
"colorTextPrimaryStronger",
|
|
206
|
+
"colorTextPrimaryStrongest",
|
|
207
|
+
"colorTextPrimaryWeak",
|
|
208
|
+
"colorTextSubaccount",
|
|
209
|
+
"colorTextSuccess",
|
|
210
|
+
"colorTextUser",
|
|
211
|
+
"colorTextWarning",
|
|
212
|
+
"colorTextWarningStrong",
|
|
213
|
+
"colorTextWeak",
|
|
214
|
+
"colorTextWeaker",
|
|
215
|
+
"colorTextWeakest"
|
|
216
|
+
];
|
|
217
|
+
//#endregion
|
|
218
|
+
//#region src/icon.ts
|
|
219
|
+
const SIZE_ICON_TOKENS = [
|
|
220
|
+
"sizeIcon05",
|
|
221
|
+
"sizeIcon10",
|
|
222
|
+
"sizeIcon20",
|
|
223
|
+
"sizeIcon30",
|
|
224
|
+
"sizeIcon40",
|
|
225
|
+
"sizeIcon50",
|
|
226
|
+
"sizeIcon60",
|
|
227
|
+
"sizeIcon70",
|
|
228
|
+
"sizeIcon80",
|
|
229
|
+
"sizeIcon90",
|
|
230
|
+
"sizeIcon100",
|
|
231
|
+
"sizeIcon110"
|
|
232
|
+
];
|
|
233
|
+
//#endregion
|
|
234
|
+
//#region src/shadow.ts
|
|
235
|
+
const BOX_SHADOW_TOKENS = [
|
|
236
|
+
"shadow",
|
|
237
|
+
"shadowBorder",
|
|
238
|
+
"shadowBorderBottom",
|
|
239
|
+
"shadowBorderBottomBrand10Strong",
|
|
240
|
+
"shadowBorderBottomBrand20Strong",
|
|
241
|
+
"shadowBorderBottomBrand30Strong",
|
|
242
|
+
"shadowBorderBottomDecorative10Weaker",
|
|
243
|
+
"shadowBorderBottomDecorative20Weaker",
|
|
244
|
+
"shadowBorderBottomDecorative30Weaker",
|
|
245
|
+
"shadowBorderBottomDecorative40Weaker",
|
|
246
|
+
"shadowBorderBottomErrorWeaker",
|
|
247
|
+
"shadowBorderBottomInverseNewWeaker",
|
|
248
|
+
"shadowBorderBottomInverseWeaker",
|
|
249
|
+
"shadowBorderBottomInverseWeakerInset",
|
|
250
|
+
"shadowBorderBottomNeutralWeaker",
|
|
251
|
+
"shadowBorderBottomNewWeaker",
|
|
252
|
+
"shadowBorderBottomNotificationStronger",
|
|
253
|
+
"shadowBorderBottomPrimary",
|
|
254
|
+
"shadowBorderBottomSubaccount",
|
|
255
|
+
"shadowBorderBottomSuccessWeaker",
|
|
256
|
+
"shadowBorderBottomWarningWeaker",
|
|
257
|
+
"shadowBorderBottomWeak",
|
|
258
|
+
"shadowBorderBottomWeakInset",
|
|
259
|
+
"shadowBorderBrand10",
|
|
260
|
+
"shadowBorderBrand20",
|
|
261
|
+
"shadowBorderBrand30",
|
|
262
|
+
"shadowBorderDecorative10Weaker",
|
|
263
|
+
"shadowBorderDecorative20Weaker",
|
|
264
|
+
"shadowBorderDecorative30Weaker",
|
|
265
|
+
"shadowBorderDecorative40Weaker",
|
|
266
|
+
"shadowBorderDestructive",
|
|
267
|
+
"shadowBorderDestructiveStrong",
|
|
268
|
+
"shadowBorderDestructiveStronger",
|
|
269
|
+
"shadowBorderDestructiveStrongest",
|
|
270
|
+
"shadowBorderDestructiveWeak",
|
|
271
|
+
"shadowBorderDestructiveWeaker",
|
|
272
|
+
"shadowBorderError",
|
|
273
|
+
"shadowBorderErrorStrong",
|
|
274
|
+
"shadowBorderErrorStronger",
|
|
275
|
+
"shadowBorderErrorStrongest",
|
|
276
|
+
"shadowBorderErrorWeak",
|
|
277
|
+
"shadowBorderErrorWeaker",
|
|
278
|
+
"shadowBorderInverse",
|
|
279
|
+
"shadowBorderInverseNewWeaker",
|
|
280
|
+
"shadowBorderInverseStrong",
|
|
281
|
+
"shadowBorderInverseStronger",
|
|
282
|
+
"shadowBorderInverseStrongest",
|
|
283
|
+
"shadowBorderInverseWeaker",
|
|
284
|
+
"shadowBorderInverseWeakest",
|
|
285
|
+
"shadowBorderNeutralWeaker",
|
|
286
|
+
"shadowBorderNewWeaker",
|
|
287
|
+
"shadowBorderNotification",
|
|
288
|
+
"shadowBorderPrimary",
|
|
289
|
+
"shadowBorderPrimaryStrong",
|
|
290
|
+
"shadowBorderPrimaryStronger",
|
|
291
|
+
"shadowBorderPrimaryStrongest",
|
|
292
|
+
"shadowBorderPrimaryWeak",
|
|
293
|
+
"shadowBorderPrimaryWeaker",
|
|
294
|
+
"shadowBorderRightInverseStrong",
|
|
295
|
+
"shadowBorderStrong",
|
|
296
|
+
"shadowBorderSubaccount",
|
|
297
|
+
"shadowBorderSuccessWeaker",
|
|
298
|
+
"shadowBorderTopInverseStrongest",
|
|
299
|
+
"shadowBorderTopPrimary",
|
|
300
|
+
"shadowBorderTopPrimaryStrongest",
|
|
301
|
+
"shadowBorderUser",
|
|
302
|
+
"shadowBorderWarningWeaker",
|
|
303
|
+
"shadowBorderWeak",
|
|
304
|
+
"shadowBorderWeaker",
|
|
305
|
+
"shadowCard",
|
|
306
|
+
"shadowElevation05",
|
|
307
|
+
"shadowElevation10",
|
|
308
|
+
"shadowElevation20",
|
|
309
|
+
"shadowElevationBottom05",
|
|
310
|
+
"shadowElevationBottomInverse05",
|
|
311
|
+
"shadowElevationInverse05",
|
|
312
|
+
"shadowElevationInverse10",
|
|
313
|
+
"shadowElevationLeft20",
|
|
314
|
+
"shadowElevationRightInverse05",
|
|
315
|
+
"shadowElevationTop05",
|
|
316
|
+
"shadowElevationTop20",
|
|
317
|
+
"shadowFocus",
|
|
318
|
+
"shadowFocusInset",
|
|
319
|
+
"shadowFocusInverse",
|
|
320
|
+
"shadowFocusInverseInset",
|
|
321
|
+
"shadowFocusShadowBorder",
|
|
322
|
+
"shadowHigh",
|
|
323
|
+
"shadowLeft",
|
|
324
|
+
"shadowLeftInverse",
|
|
325
|
+
"shadowLow",
|
|
326
|
+
"shadowRight",
|
|
327
|
+
"shadowRightInverse"
|
|
328
|
+
];
|
|
329
|
+
//#endregion
|
|
330
|
+
//#region src/space.ts
|
|
331
|
+
const SPACE_TOKENS = [
|
|
332
|
+
"space0",
|
|
333
|
+
"space10",
|
|
334
|
+
"space20",
|
|
335
|
+
"space30",
|
|
336
|
+
"space40",
|
|
337
|
+
"space50",
|
|
338
|
+
"space60",
|
|
339
|
+
"space70",
|
|
340
|
+
"space80",
|
|
341
|
+
"space90",
|
|
342
|
+
"space100",
|
|
343
|
+
"space110",
|
|
344
|
+
"space120",
|
|
345
|
+
"space130",
|
|
346
|
+
"space140",
|
|
347
|
+
"space150",
|
|
348
|
+
"space160",
|
|
349
|
+
"space170",
|
|
350
|
+
"space180",
|
|
351
|
+
"space190",
|
|
352
|
+
"space200",
|
|
353
|
+
"space210",
|
|
354
|
+
"space220",
|
|
355
|
+
"space230",
|
|
356
|
+
"space240",
|
|
357
|
+
"space250",
|
|
358
|
+
"space260",
|
|
359
|
+
"space270",
|
|
360
|
+
"space280",
|
|
361
|
+
"space290",
|
|
362
|
+
"space300",
|
|
363
|
+
"space310",
|
|
364
|
+
"spaceNegative10",
|
|
365
|
+
"spaceNegative20",
|
|
366
|
+
"spaceNegative30",
|
|
367
|
+
"spaceNegative40",
|
|
368
|
+
"spaceNegative50",
|
|
369
|
+
"spaceNegative60",
|
|
370
|
+
"spaceNegative70",
|
|
371
|
+
"spaceNegative80",
|
|
372
|
+
"spaceNegative90",
|
|
373
|
+
"spaceNegative100",
|
|
374
|
+
"spaceNegative110",
|
|
375
|
+
"spaceNegative120",
|
|
376
|
+
"spaceNegative130",
|
|
377
|
+
"spaceNegative140",
|
|
378
|
+
"spaceNegative150",
|
|
379
|
+
"spaceNegative160",
|
|
380
|
+
"spaceNegative170",
|
|
381
|
+
"spaceNegative180",
|
|
382
|
+
"spaceNegative190",
|
|
383
|
+
"spaceNegative200"
|
|
384
|
+
];
|
|
385
|
+
//#endregion
|
|
386
|
+
//#region src/typography.ts
|
|
387
|
+
const FONT_SIZE_TOKENS = [
|
|
388
|
+
"fontSize10",
|
|
389
|
+
"fontSize20",
|
|
390
|
+
"fontSize30",
|
|
391
|
+
"fontSize40",
|
|
392
|
+
"fontSize50",
|
|
393
|
+
"fontSize60",
|
|
394
|
+
"fontSize70",
|
|
395
|
+
"fontSize80",
|
|
396
|
+
"fontSize90",
|
|
397
|
+
"fontSize100",
|
|
398
|
+
"fontSize110",
|
|
399
|
+
"fontSizeBase",
|
|
400
|
+
"fontSizeDisplay10",
|
|
401
|
+
"fontSizeDisplay20",
|
|
402
|
+
"fontSizeDisplay30"
|
|
403
|
+
];
|
|
404
|
+
const FONT_WEIGHT_TOKENS = [
|
|
405
|
+
"fontWeightLight",
|
|
406
|
+
"fontWeightNormal",
|
|
407
|
+
"fontWeightMedium",
|
|
408
|
+
"fontWeightSemibold",
|
|
409
|
+
"fontWeightBold",
|
|
410
|
+
"fontWeightExtrabold"
|
|
411
|
+
];
|
|
412
|
+
const LINE_HEIGHT_TOKENS = [
|
|
413
|
+
"lineHeight0",
|
|
414
|
+
"lineHeight05",
|
|
415
|
+
"lineHeight10",
|
|
416
|
+
"lineHeight20",
|
|
417
|
+
"lineHeight30",
|
|
418
|
+
"lineHeight40",
|
|
419
|
+
"lineHeight50",
|
|
420
|
+
"lineHeight60",
|
|
421
|
+
"lineHeight70",
|
|
422
|
+
"lineHeight80",
|
|
423
|
+
"lineHeight90",
|
|
424
|
+
"lineHeight100",
|
|
425
|
+
"lineHeight110",
|
|
426
|
+
"lineHeightDisplay10",
|
|
427
|
+
"lineHeightDisplay20",
|
|
428
|
+
"lineHeightDisplay30"
|
|
429
|
+
];
|
|
430
|
+
const FONT_FAMILY_TOKENS = [
|
|
431
|
+
"fontFamilyCode",
|
|
432
|
+
"fontFamilyDisplay",
|
|
433
|
+
"fontFamilyText",
|
|
434
|
+
"fontFamilyTextChineseSimplified",
|
|
435
|
+
"fontFamilyTextChineseTraditional",
|
|
436
|
+
"fontFamilyTextJapanese",
|
|
437
|
+
"fontFamilyTextKorean"
|
|
438
|
+
];
|
|
439
|
+
//#endregion
|
|
440
|
+
//#region src/z-index.ts
|
|
441
|
+
const Z_INDEX_TOKENS = [
|
|
442
|
+
"zIndex0",
|
|
443
|
+
"zIndex10",
|
|
444
|
+
"zIndex20",
|
|
445
|
+
"zIndex30",
|
|
446
|
+
"zIndex40",
|
|
447
|
+
"zIndex50",
|
|
448
|
+
"zIndex60",
|
|
449
|
+
"zIndex70",
|
|
450
|
+
"zIndex80",
|
|
451
|
+
"zIndex90"
|
|
452
|
+
];
|
|
453
|
+
//#endregion
|
|
454
|
+
export { BACKGROUND_COLOR_TOKENS, BORDER_COLOR_TOKENS, BORDER_WIDTH_TOKENS, BOX_SHADOW_TOKENS, COLOR_TOKENS, FONT_FAMILY_TOKENS, FONT_SIZE_TOKENS, FONT_WEIGHT_TOKENS, LINE_HEIGHT_TOKENS, RADII_TOKENS, SIZE_ICON_TOKENS, SPACE_TOKENS, Z_INDEX_TOKENS };
|
package/package.json
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@hive-ui/style-props",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "Hive UI Style Props",
|
|
5
|
+
"files": [
|
|
6
|
+
"dist"
|
|
7
|
+
],
|
|
8
|
+
"type": "module",
|
|
9
|
+
"exports": {
|
|
10
|
+
".": "./dist/index.mjs",
|
|
11
|
+
"./package.json": "./package.json"
|
|
12
|
+
},
|
|
13
|
+
"publishConfig": {
|
|
14
|
+
"access": "public"
|
|
15
|
+
},
|
|
16
|
+
"scripts": {
|
|
17
|
+
"build": "vp pack",
|
|
18
|
+
"dev": "vp pack --watch",
|
|
19
|
+
"test": "vp test",
|
|
20
|
+
"check": "vp check",
|
|
21
|
+
"prepublishOnly": "vp run build"
|
|
22
|
+
},
|
|
23
|
+
"dependencies": {
|
|
24
|
+
"csstype": "3.2.3"
|
|
25
|
+
},
|
|
26
|
+
"devDependencies": {
|
|
27
|
+
"@types/node": "^25.6.2",
|
|
28
|
+
"@typescript/native-preview": "7.0.0-dev.20260509.2",
|
|
29
|
+
"bumpp": "^11.1.0",
|
|
30
|
+
"typescript": "^6.0.3",
|
|
31
|
+
"vite-plus": "^0.1.20",
|
|
32
|
+
"vitest": "npm:@voidzero-dev/vite-plus-test@^0.1.20"
|
|
33
|
+
}
|
|
34
|
+
}
|