@headspace_designsystem/hsds-web-library 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/README.md +184 -0
- package/dist/components/Button/Button.d.ts +3 -0
- package/dist/components/Button/Button.d.ts.map +1 -0
- package/dist/components/Button/Button.types.d.ts +18 -0
- package/dist/components/Button/Button.types.d.ts.map +1 -0
- package/dist/components/Button/index.d.ts +3 -0
- package/dist/components/Button/index.d.ts.map +1 -0
- package/dist/components/index.d.ts +2 -0
- package/dist/components/index.d.ts.map +1 -0
- package/dist/demo.d.ts +2 -0
- package/dist/demo.d.ts.map +1 -0
- package/dist/hsds-web-library.es.js +1927 -0
- package/dist/hsds-web-library.es.js.map +1 -0
- package/dist/hsds-web-library.umd.js +19 -0
- package/dist/hsds-web-library.umd.js.map +1 -0
- package/dist/index.d.ts +17 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/theme/ThemeProvider.d.ts +14 -0
- package/dist/theme/ThemeProvider.d.ts.map +1 -0
- package/dist/theme/index.d.ts +4 -0
- package/dist/theme/index.d.ts.map +1 -0
- package/dist/theme/theme.d.ts +3 -0
- package/dist/theme/theme.d.ts.map +1 -0
- package/dist/theme/types.d.ts +88 -0
- package/dist/theme/types.d.ts.map +1 -0
- package/dist/tokens/index.d.ts +3 -0
- package/dist/tokens/index.d.ts.map +1 -0
- package/dist/tokens/primitives/borders.d.ts +41 -0
- package/dist/tokens/primitives/borders.d.ts.map +1 -0
- package/dist/tokens/primitives/colors.d.ts +67 -0
- package/dist/tokens/primitives/colors.d.ts.map +1 -0
- package/dist/tokens/primitives/index.d.ts +6 -0
- package/dist/tokens/primitives/index.d.ts.map +1 -0
- package/dist/tokens/primitives/shadows.d.ts +38 -0
- package/dist/tokens/primitives/shadows.d.ts.map +1 -0
- package/dist/tokens/primitives/spacing.d.ts +29 -0
- package/dist/tokens/primitives/spacing.d.ts.map +1 -0
- package/dist/tokens/primitives/typography.d.ts +46 -0
- package/dist/tokens/primitives/typography.d.ts.map +1 -0
- package/dist/tokens/semantic/colors.d.ts +154 -0
- package/dist/tokens/semantic/colors.d.ts.map +1 -0
- package/dist/tokens/semantic/index.d.ts +3 -0
- package/dist/tokens/semantic/index.d.ts.map +1 -0
- package/dist/tokens/semantic/typography.d.ts +253 -0
- package/dist/tokens/semantic/typography.d.ts.map +1 -0
- package/package.json +45 -0
|
@@ -0,0 +1,253 @@
|
|
|
1
|
+
export interface TypeStyle {
|
|
2
|
+
fontFamily: string;
|
|
3
|
+
fontSize: string;
|
|
4
|
+
fontWeight: number;
|
|
5
|
+
lineHeight: string;
|
|
6
|
+
letterSpacing: string;
|
|
7
|
+
}
|
|
8
|
+
export declare const desktopTypeScale: {
|
|
9
|
+
readonly heading: {
|
|
10
|
+
/** Heading 3XL — 64px Bold, lh 1.0, ls -3px */
|
|
11
|
+
readonly '3xl': {
|
|
12
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
13
|
+
fontSize: string;
|
|
14
|
+
fontWeight: 700;
|
|
15
|
+
lineHeight: "1";
|
|
16
|
+
letterSpacing: "-3px";
|
|
17
|
+
};
|
|
18
|
+
/** Heading 2XL — 56px Bold, lh 1.1, ls -3px */
|
|
19
|
+
readonly '2xl': {
|
|
20
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
21
|
+
fontSize: string;
|
|
22
|
+
fontWeight: 700;
|
|
23
|
+
lineHeight: "1.1";
|
|
24
|
+
letterSpacing: "-3px";
|
|
25
|
+
};
|
|
26
|
+
/** Heading XL — 48px Bold, lh 1.1, ls -3px */
|
|
27
|
+
readonly xl: {
|
|
28
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
29
|
+
fontSize: string;
|
|
30
|
+
fontWeight: 700;
|
|
31
|
+
lineHeight: "1.1";
|
|
32
|
+
letterSpacing: "-3px";
|
|
33
|
+
};
|
|
34
|
+
/** Heading L — 40px Bold, lh 1.2, ls -3px */
|
|
35
|
+
readonly l: {
|
|
36
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
37
|
+
fontSize: string;
|
|
38
|
+
fontWeight: 700;
|
|
39
|
+
lineHeight: "1.2";
|
|
40
|
+
letterSpacing: "-3px";
|
|
41
|
+
};
|
|
42
|
+
/** Heading M — 32px Bold, lh 1.2, ls -3px */
|
|
43
|
+
readonly m: {
|
|
44
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
45
|
+
fontSize: string;
|
|
46
|
+
fontWeight: 700;
|
|
47
|
+
lineHeight: "1.2";
|
|
48
|
+
letterSpacing: "-3px";
|
|
49
|
+
};
|
|
50
|
+
/** Heading S — 24px Bold, lh 1.2, ls -3px */
|
|
51
|
+
readonly s: {
|
|
52
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
53
|
+
fontSize: string;
|
|
54
|
+
fontWeight: 700;
|
|
55
|
+
lineHeight: "1.2";
|
|
56
|
+
letterSpacing: "-3px";
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
readonly body: {
|
|
60
|
+
/** Body L — 20px Regular, lh 1.5, ls 0 */
|
|
61
|
+
readonly l: {
|
|
62
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
63
|
+
fontSize: string;
|
|
64
|
+
fontWeight: 400;
|
|
65
|
+
lineHeight: "1.5";
|
|
66
|
+
letterSpacing: "0px";
|
|
67
|
+
};
|
|
68
|
+
/** Body M — 18px Regular, lh 1.5, ls 0 */
|
|
69
|
+
readonly m: {
|
|
70
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
71
|
+
fontSize: string;
|
|
72
|
+
fontWeight: 400;
|
|
73
|
+
lineHeight: "1.5";
|
|
74
|
+
letterSpacing: "0px";
|
|
75
|
+
};
|
|
76
|
+
/** Body S — 16px Regular, lh 1.5, ls 0 */
|
|
77
|
+
readonly s: {
|
|
78
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
79
|
+
fontSize: string;
|
|
80
|
+
fontWeight: 400;
|
|
81
|
+
lineHeight: "1.5";
|
|
82
|
+
letterSpacing: "0px";
|
|
83
|
+
};
|
|
84
|
+
/** Body XS — 14px Regular, lh 1.5, ls 0 */
|
|
85
|
+
readonly xs: {
|
|
86
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
87
|
+
fontSize: string;
|
|
88
|
+
fontWeight: 400;
|
|
89
|
+
lineHeight: "1.5";
|
|
90
|
+
letterSpacing: "0px";
|
|
91
|
+
};
|
|
92
|
+
/** Body 2XS — 12px Regular, lh 1.5, ls 0 */
|
|
93
|
+
readonly '2xs': {
|
|
94
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
95
|
+
fontSize: string;
|
|
96
|
+
fontWeight: 400;
|
|
97
|
+
lineHeight: "1.5";
|
|
98
|
+
letterSpacing: "0px";
|
|
99
|
+
};
|
|
100
|
+
/** Body 3XS — 10px Regular, lh 1.5, ls 0 */
|
|
101
|
+
readonly '3xs': {
|
|
102
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
103
|
+
fontSize: string;
|
|
104
|
+
fontWeight: 400;
|
|
105
|
+
lineHeight: "1.5";
|
|
106
|
+
letterSpacing: "0px";
|
|
107
|
+
};
|
|
108
|
+
};
|
|
109
|
+
readonly label: {
|
|
110
|
+
/** Label L — 20px Bold, lh 1.2, ls -3px */
|
|
111
|
+
readonly l: {
|
|
112
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
113
|
+
fontSize: string;
|
|
114
|
+
fontWeight: 700;
|
|
115
|
+
lineHeight: "1.2";
|
|
116
|
+
letterSpacing: "-3px";
|
|
117
|
+
};
|
|
118
|
+
/** Label M — 18px Bold, lh 1.2, ls -3px */
|
|
119
|
+
readonly m: {
|
|
120
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
121
|
+
fontSize: string;
|
|
122
|
+
fontWeight: 700;
|
|
123
|
+
lineHeight: "1.2";
|
|
124
|
+
letterSpacing: "-3px";
|
|
125
|
+
};
|
|
126
|
+
/** Label S — 16px Bold, lh 1.2, ls -3px */
|
|
127
|
+
readonly s: {
|
|
128
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
129
|
+
fontSize: string;
|
|
130
|
+
fontWeight: 700;
|
|
131
|
+
lineHeight: "1.2";
|
|
132
|
+
letterSpacing: "-3px";
|
|
133
|
+
};
|
|
134
|
+
/** Label XS — 14px Bold, lh 1.2, ls -3px */
|
|
135
|
+
readonly xs: {
|
|
136
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
137
|
+
fontSize: string;
|
|
138
|
+
fontWeight: 700;
|
|
139
|
+
lineHeight: "1.2";
|
|
140
|
+
letterSpacing: "-3px";
|
|
141
|
+
};
|
|
142
|
+
/** Label 2XS — 12px Bold, lh 1.2, ls -3px */
|
|
143
|
+
readonly '2xs': {
|
|
144
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
145
|
+
fontSize: string;
|
|
146
|
+
fontWeight: 700;
|
|
147
|
+
lineHeight: "1.2";
|
|
148
|
+
letterSpacing: "-3px";
|
|
149
|
+
};
|
|
150
|
+
/** Label 3XS — 10px Bold, lh 1.2, ls -3px */
|
|
151
|
+
readonly '3xs': {
|
|
152
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
153
|
+
fontSize: string;
|
|
154
|
+
fontWeight: 700;
|
|
155
|
+
lineHeight: "1.2";
|
|
156
|
+
letterSpacing: "-3px";
|
|
157
|
+
};
|
|
158
|
+
};
|
|
159
|
+
readonly link: {
|
|
160
|
+
/** Link L — 20px Regular, lh 1.5, ls 0 */
|
|
161
|
+
readonly l: {
|
|
162
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
163
|
+
fontSize: string;
|
|
164
|
+
fontWeight: 400;
|
|
165
|
+
lineHeight: "1.5";
|
|
166
|
+
letterSpacing: "0px";
|
|
167
|
+
};
|
|
168
|
+
/** Link M — 18px Regular, lh 1.5, ls 0 */
|
|
169
|
+
readonly m: {
|
|
170
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
171
|
+
fontSize: string;
|
|
172
|
+
fontWeight: 400;
|
|
173
|
+
lineHeight: "1.5";
|
|
174
|
+
letterSpacing: "0px";
|
|
175
|
+
};
|
|
176
|
+
/** Link S — 16px Regular, lh 1.5, ls 0 */
|
|
177
|
+
readonly s: {
|
|
178
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
179
|
+
fontSize: string;
|
|
180
|
+
fontWeight: 400;
|
|
181
|
+
lineHeight: "1.5";
|
|
182
|
+
letterSpacing: "0px";
|
|
183
|
+
};
|
|
184
|
+
/** Link XS — 14px Regular, lh 1.5, ls 0 */
|
|
185
|
+
readonly xs: {
|
|
186
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
187
|
+
fontSize: string;
|
|
188
|
+
fontWeight: 400;
|
|
189
|
+
lineHeight: "1.5";
|
|
190
|
+
letterSpacing: "0px";
|
|
191
|
+
};
|
|
192
|
+
/** Link 2XS — 12px Regular, lh 1.5, ls 0 */
|
|
193
|
+
readonly '2xs': {
|
|
194
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
195
|
+
fontSize: string;
|
|
196
|
+
fontWeight: 400;
|
|
197
|
+
lineHeight: "1.5";
|
|
198
|
+
letterSpacing: "0px";
|
|
199
|
+
};
|
|
200
|
+
/** Link 3XS — 10px Regular, lh 1.5, ls 0 */
|
|
201
|
+
readonly '3xs': {
|
|
202
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
203
|
+
fontSize: string;
|
|
204
|
+
fontWeight: 400;
|
|
205
|
+
lineHeight: "1.5";
|
|
206
|
+
letterSpacing: "0px";
|
|
207
|
+
};
|
|
208
|
+
};
|
|
209
|
+
readonly utility: {
|
|
210
|
+
/** Utility L — 14px Mono, lh 1.5, ls 4px */
|
|
211
|
+
readonly l: {
|
|
212
|
+
fontFamily: "\"Apercu Mono\", \"Apercu\", ui-monospace, monospace";
|
|
213
|
+
fontSize: string;
|
|
214
|
+
fontWeight: 400;
|
|
215
|
+
lineHeight: "1.5";
|
|
216
|
+
letterSpacing: "4px";
|
|
217
|
+
};
|
|
218
|
+
/** Utility M — 12px Mono, lh 1.5, ls 4px */
|
|
219
|
+
readonly m: {
|
|
220
|
+
fontFamily: "\"Apercu Mono\", \"Apercu\", ui-monospace, monospace";
|
|
221
|
+
fontSize: string;
|
|
222
|
+
fontWeight: 400;
|
|
223
|
+
lineHeight: "1.5";
|
|
224
|
+
letterSpacing: "4px";
|
|
225
|
+
};
|
|
226
|
+
/** Utility S — 10px Mono, lh 1.5, ls 4px */
|
|
227
|
+
readonly s: {
|
|
228
|
+
fontFamily: "\"Apercu Mono\", \"Apercu\", ui-monospace, monospace";
|
|
229
|
+
fontSize: string;
|
|
230
|
+
fontWeight: 400;
|
|
231
|
+
lineHeight: "1.5";
|
|
232
|
+
letterSpacing: "4px";
|
|
233
|
+
};
|
|
234
|
+
/** Utility XS — 8px Mono, lh 1.5, ls 4px */
|
|
235
|
+
readonly xs: {
|
|
236
|
+
fontFamily: "\"Apercu Mono\", \"Apercu\", ui-monospace, monospace";
|
|
237
|
+
fontSize: string;
|
|
238
|
+
fontWeight: 400;
|
|
239
|
+
lineHeight: "1.5";
|
|
240
|
+
letterSpacing: "4px";
|
|
241
|
+
};
|
|
242
|
+
};
|
|
243
|
+
/** Caption — 20px Medium, lh 1.2, ls -3px */
|
|
244
|
+
readonly caption: {
|
|
245
|
+
fontFamily: "\"Headspace Apercu\", \"Apercu\", system-ui, sans-serif";
|
|
246
|
+
fontSize: string;
|
|
247
|
+
fontWeight: 500;
|
|
248
|
+
lineHeight: "1.2";
|
|
249
|
+
letterSpacing: "-3px";
|
|
250
|
+
};
|
|
251
|
+
};
|
|
252
|
+
export type DesktopTypeScale = typeof desktopTypeScale;
|
|
253
|
+
//# sourceMappingURL=typography.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"typography.d.ts","sourceRoot":"","sources":["../../../src/tokens/semantic/typography.ts"],"names":[],"mappings":"AAqBA,MAAM,WAAW,SAAS;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,QAAQ,EAAE,MAAM,CAAC;IACjB,UAAU,EAAE,MAAM,CAAC;IACnB,UAAU,EAAE,MAAM,CAAC;IACnB,aAAa,EAAE,MAAM,CAAC;CACvB;AAID,eAAO,MAAM,gBAAgB;;QAEzB,+CAA+C;;;;;;;;QAQ/C,+CAA+C;;;;;;;;QAQ/C,8CAA8C;;;;;;;;QAQ9C,6CAA6C;;;;;;;;QAQ7C,6CAA6C;;;;;;;;QAQ7C,6CAA6C;;;;;;;;;;QAW7C,0CAA0C;;;;;;;;QAQ1C,0CAA0C;;;;;;;;QAQ1C,0CAA0C;;;;;;;;QAQ1C,2CAA2C;;;;;;;;QAQ3C,4CAA4C;;;;;;;;QAQ5C,4CAA4C;;;;;;;;;;QAW5C,2CAA2C;;;;;;;;QAQ3C,2CAA2C;;;;;;;;QAQ3C,2CAA2C;;;;;;;;QAQ3C,4CAA4C;;;;;;;;QAQ5C,6CAA6C;;;;;;;;QAQ7C,6CAA6C;;;;;;;;;;QAW7C,0CAA0C;;;;;;;;QAQ1C,0CAA0C;;;;;;;;QAQ1C,0CAA0C;;;;;;;;QAQ1C,2CAA2C;;;;;;;;QAQ3C,4CAA4C;;;;;;;;QAQ5C,4CAA4C;;;;;;;;;;QAW5C,4CAA4C;;;;;;;;QAQ5C,4CAA4C;;;;;;;;QAQ5C,4CAA4C;;;;;;;;QAQ5C,4CAA4C;;;;;;;;;IAU9C,6CAA6C;;;;;;;;CAQrC,CAAC;AAEX,MAAM,MAAM,gBAAgB,GAAG,OAAO,gBAAgB,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@headspace_designsystem/hsds-web-library",
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "HeadSpace Design System — web component library (React + TypeScript + Emotion)",
|
|
5
|
+
"license": "UNLICENSED",
|
|
6
|
+
"type": "module",
|
|
7
|
+
"main": "./dist/hsds-web-library.umd.js",
|
|
8
|
+
"module": "./dist/hsds-web-library.es.js",
|
|
9
|
+
"types": "./dist/index.d.ts",
|
|
10
|
+
"exports": {
|
|
11
|
+
".": {
|
|
12
|
+
"import": "./dist/hsds-web-library.es.js",
|
|
13
|
+
"require": "./dist/hsds-web-library.umd.js",
|
|
14
|
+
"types": "./dist/index.d.ts"
|
|
15
|
+
}
|
|
16
|
+
},
|
|
17
|
+
"files": [
|
|
18
|
+
"dist"
|
|
19
|
+
],
|
|
20
|
+
"sideEffects": false,
|
|
21
|
+
"scripts": {
|
|
22
|
+
"dev": "vite",
|
|
23
|
+
"build": "tsc --noEmit && vite build",
|
|
24
|
+
"typecheck": "tsc --noEmit",
|
|
25
|
+
"clean": "rm -rf dist"
|
|
26
|
+
},
|
|
27
|
+
"peerDependencies": {
|
|
28
|
+
"@emotion/react": ">=11.0.0",
|
|
29
|
+
"@emotion/styled": ">=11.0.0",
|
|
30
|
+
"react": ">=18.0.0",
|
|
31
|
+
"react-dom": ">=18.0.0"
|
|
32
|
+
},
|
|
33
|
+
"devDependencies": {
|
|
34
|
+
"@emotion/babel-plugin": "^11.12.0",
|
|
35
|
+
"@emotion/react": "^11.13.0",
|
|
36
|
+
"@emotion/styled": "^11.13.0",
|
|
37
|
+
"@types/node": "^25.3.3",
|
|
38
|
+
"@types/react": "^18.3.0",
|
|
39
|
+
"@types/react-dom": "^18.3.0",
|
|
40
|
+
"@vitejs/plugin-react": "^4.3.0",
|
|
41
|
+
"typescript": "^5.5.0",
|
|
42
|
+
"vite": "^5.4.0",
|
|
43
|
+
"vite-plugin-dts": "^4.2.0"
|
|
44
|
+
}
|
|
45
|
+
}
|