@sofya-ds/tokens 1.1.1 → 1.1.3
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.cjs +29 -16
- package/dist/index.d.cts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +29 -16
- package/package.json +1 -1
package/dist/index.cjs
CHANGED
|
@@ -44,6 +44,7 @@ var sofyaTextStyleNames = [
|
|
|
44
44
|
"h2",
|
|
45
45
|
"h3",
|
|
46
46
|
"h4",
|
|
47
|
+
"h5",
|
|
47
48
|
"body",
|
|
48
49
|
"tiny"
|
|
49
50
|
];
|
|
@@ -237,35 +238,42 @@ function createTextStyleScale(typography) {
|
|
|
237
238
|
return {
|
|
238
239
|
h1: {
|
|
239
240
|
fontFamily: typography.display,
|
|
240
|
-
fontSize: "
|
|
241
|
-
fontWeight: "
|
|
242
|
-
lineHeight: "
|
|
243
|
-
letterSpacing: "0"
|
|
241
|
+
fontSize: "48px",
|
|
242
|
+
fontWeight: "700",
|
|
243
|
+
lineHeight: "53px",
|
|
244
|
+
letterSpacing: "-0.48px"
|
|
244
245
|
},
|
|
245
246
|
h2: {
|
|
246
247
|
fontFamily: typography.display,
|
|
247
|
-
fontSize: "
|
|
248
|
-
fontWeight: "
|
|
249
|
-
lineHeight: "
|
|
250
|
-
letterSpacing: "0"
|
|
248
|
+
fontSize: "36px",
|
|
249
|
+
fontWeight: "600",
|
|
250
|
+
lineHeight: "41px",
|
|
251
|
+
letterSpacing: "-0.18px"
|
|
251
252
|
},
|
|
252
253
|
h3: {
|
|
253
254
|
fontFamily: typography.display,
|
|
254
|
-
fontSize: "
|
|
255
|
+
fontSize: "28px",
|
|
255
256
|
fontWeight: "600",
|
|
256
|
-
lineHeight: "
|
|
257
|
-
letterSpacing: "0"
|
|
257
|
+
lineHeight: "34px",
|
|
258
|
+
letterSpacing: "-0.084px"
|
|
258
259
|
},
|
|
259
260
|
h4: {
|
|
260
261
|
fontFamily: typography.display,
|
|
261
|
-
fontSize: "
|
|
262
|
+
fontSize: "22px",
|
|
263
|
+
fontWeight: "500",
|
|
264
|
+
lineHeight: "28px",
|
|
265
|
+
letterSpacing: "-0.022px"
|
|
266
|
+
},
|
|
267
|
+
h5: {
|
|
268
|
+
fontFamily: typography.display,
|
|
269
|
+
fontSize: "18px",
|
|
262
270
|
fontWeight: "500",
|
|
263
|
-
lineHeight: "
|
|
271
|
+
lineHeight: "23px",
|
|
264
272
|
letterSpacing: "0"
|
|
265
273
|
},
|
|
266
274
|
body: {
|
|
267
275
|
fontFamily: typography.sans,
|
|
268
|
-
fontSize: "
|
|
276
|
+
fontSize: "16px",
|
|
269
277
|
fontWeight: "400",
|
|
270
278
|
lineHeight: "26px",
|
|
271
279
|
letterSpacing: "0"
|
|
@@ -274,8 +282,8 @@ function createTextStyleScale(typography) {
|
|
|
274
282
|
fontFamily: typography.sans,
|
|
275
283
|
fontSize: "12px",
|
|
276
284
|
fontWeight: "400",
|
|
277
|
-
lineHeight: "
|
|
278
|
-
letterSpacing: "0"
|
|
285
|
+
lineHeight: "18px",
|
|
286
|
+
letterSpacing: "0.012px"
|
|
279
287
|
}
|
|
280
288
|
};
|
|
281
289
|
}
|
|
@@ -608,6 +616,11 @@ function themeToCssVariables(theme) {
|
|
|
608
616
|
"--sofya-text-h4-font-weight": textStyles.h4.fontWeight,
|
|
609
617
|
"--sofya-text-h4-line-height": textStyles.h4.lineHeight,
|
|
610
618
|
"--sofya-text-h4-letter-spacing": textStyles.h4.letterSpacing,
|
|
619
|
+
"--sofya-text-h5-font-family": textStyles.h5.fontFamily,
|
|
620
|
+
"--sofya-text-h5-font-size": textStyles.h5.fontSize,
|
|
621
|
+
"--sofya-text-h5-font-weight": textStyles.h5.fontWeight,
|
|
622
|
+
"--sofya-text-h5-line-height": textStyles.h5.lineHeight,
|
|
623
|
+
"--sofya-text-h5-letter-spacing": textStyles.h5.letterSpacing,
|
|
611
624
|
"--sofya-text-body-font-family": textStyles.body.fontFamily,
|
|
612
625
|
"--sofya-text-body-font-size": textStyles.body.fontSize,
|
|
613
626
|
"--sofya-text-body-font-weight": textStyles.body.fontWeight,
|
package/dist/index.d.cts
CHANGED
|
@@ -50,7 +50,7 @@ interface SofyaTypographyScale {
|
|
|
50
50
|
display: string;
|
|
51
51
|
mono: string;
|
|
52
52
|
}
|
|
53
|
-
declare const sofyaTextStyleNames: readonly ["h1", "h2", "h3", "h4", "body", "tiny"];
|
|
53
|
+
declare const sofyaTextStyleNames: readonly ["h1", "h2", "h3", "h4", "h5", "body", "tiny"];
|
|
54
54
|
type SofyaTextStyleName = (typeof sofyaTextStyleNames)[number];
|
|
55
55
|
interface SofyaTextStyle {
|
|
56
56
|
fontFamily: string;
|
package/dist/index.d.ts
CHANGED
|
@@ -50,7 +50,7 @@ interface SofyaTypographyScale {
|
|
|
50
50
|
display: string;
|
|
51
51
|
mono: string;
|
|
52
52
|
}
|
|
53
|
-
declare const sofyaTextStyleNames: readonly ["h1", "h2", "h3", "h4", "body", "tiny"];
|
|
53
|
+
declare const sofyaTextStyleNames: readonly ["h1", "h2", "h3", "h4", "h5", "body", "tiny"];
|
|
54
54
|
type SofyaTextStyleName = (typeof sofyaTextStyleNames)[number];
|
|
55
55
|
interface SofyaTextStyle {
|
|
56
56
|
fontFamily: string;
|
package/dist/index.js
CHANGED
|
@@ -4,6 +4,7 @@ var sofyaTextStyleNames = [
|
|
|
4
4
|
"h2",
|
|
5
5
|
"h3",
|
|
6
6
|
"h4",
|
|
7
|
+
"h5",
|
|
7
8
|
"body",
|
|
8
9
|
"tiny"
|
|
9
10
|
];
|
|
@@ -197,35 +198,42 @@ function createTextStyleScale(typography) {
|
|
|
197
198
|
return {
|
|
198
199
|
h1: {
|
|
199
200
|
fontFamily: typography.display,
|
|
200
|
-
fontSize: "
|
|
201
|
-
fontWeight: "
|
|
202
|
-
lineHeight: "
|
|
203
|
-
letterSpacing: "0"
|
|
201
|
+
fontSize: "48px",
|
|
202
|
+
fontWeight: "700",
|
|
203
|
+
lineHeight: "53px",
|
|
204
|
+
letterSpacing: "-0.48px"
|
|
204
205
|
},
|
|
205
206
|
h2: {
|
|
206
207
|
fontFamily: typography.display,
|
|
207
|
-
fontSize: "
|
|
208
|
-
fontWeight: "
|
|
209
|
-
lineHeight: "
|
|
210
|
-
letterSpacing: "0"
|
|
208
|
+
fontSize: "36px",
|
|
209
|
+
fontWeight: "600",
|
|
210
|
+
lineHeight: "41px",
|
|
211
|
+
letterSpacing: "-0.18px"
|
|
211
212
|
},
|
|
212
213
|
h3: {
|
|
213
214
|
fontFamily: typography.display,
|
|
214
|
-
fontSize: "
|
|
215
|
+
fontSize: "28px",
|
|
215
216
|
fontWeight: "600",
|
|
216
|
-
lineHeight: "
|
|
217
|
-
letterSpacing: "0"
|
|
217
|
+
lineHeight: "34px",
|
|
218
|
+
letterSpacing: "-0.084px"
|
|
218
219
|
},
|
|
219
220
|
h4: {
|
|
220
221
|
fontFamily: typography.display,
|
|
221
|
-
fontSize: "
|
|
222
|
+
fontSize: "22px",
|
|
223
|
+
fontWeight: "500",
|
|
224
|
+
lineHeight: "28px",
|
|
225
|
+
letterSpacing: "-0.022px"
|
|
226
|
+
},
|
|
227
|
+
h5: {
|
|
228
|
+
fontFamily: typography.display,
|
|
229
|
+
fontSize: "18px",
|
|
222
230
|
fontWeight: "500",
|
|
223
|
-
lineHeight: "
|
|
231
|
+
lineHeight: "23px",
|
|
224
232
|
letterSpacing: "0"
|
|
225
233
|
},
|
|
226
234
|
body: {
|
|
227
235
|
fontFamily: typography.sans,
|
|
228
|
-
fontSize: "
|
|
236
|
+
fontSize: "16px",
|
|
229
237
|
fontWeight: "400",
|
|
230
238
|
lineHeight: "26px",
|
|
231
239
|
letterSpacing: "0"
|
|
@@ -234,8 +242,8 @@ function createTextStyleScale(typography) {
|
|
|
234
242
|
fontFamily: typography.sans,
|
|
235
243
|
fontSize: "12px",
|
|
236
244
|
fontWeight: "400",
|
|
237
|
-
lineHeight: "
|
|
238
|
-
letterSpacing: "0"
|
|
245
|
+
lineHeight: "18px",
|
|
246
|
+
letterSpacing: "0.012px"
|
|
239
247
|
}
|
|
240
248
|
};
|
|
241
249
|
}
|
|
@@ -568,6 +576,11 @@ function themeToCssVariables(theme) {
|
|
|
568
576
|
"--sofya-text-h4-font-weight": textStyles.h4.fontWeight,
|
|
569
577
|
"--sofya-text-h4-line-height": textStyles.h4.lineHeight,
|
|
570
578
|
"--sofya-text-h4-letter-spacing": textStyles.h4.letterSpacing,
|
|
579
|
+
"--sofya-text-h5-font-family": textStyles.h5.fontFamily,
|
|
580
|
+
"--sofya-text-h5-font-size": textStyles.h5.fontSize,
|
|
581
|
+
"--sofya-text-h5-font-weight": textStyles.h5.fontWeight,
|
|
582
|
+
"--sofya-text-h5-line-height": textStyles.h5.lineHeight,
|
|
583
|
+
"--sofya-text-h5-letter-spacing": textStyles.h5.letterSpacing,
|
|
571
584
|
"--sofya-text-body-font-family": textStyles.body.fontFamily,
|
|
572
585
|
"--sofya-text-body-font-size": textStyles.body.fontSize,
|
|
573
586
|
"--sofya-text-body-font-weight": textStyles.body.fontWeight,
|