@atb-as/theme 11.0.0-alpha.1 → 11.0.0-alpha.11
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/lib/index.js +18 -2
- package/lib/index.js.map +1 -1
- package/lib/theme.d.ts +177 -1517
- package/lib/theme.js +38 -19
- package/lib/theme.js.map +1 -1
- package/lib/themes/atb-theme/dark.d.ts +365 -672
- package/lib/themes/atb-theme/dark.js +361 -666
- package/lib/themes/atb-theme/dark.js.map +1 -1
- package/lib/themes/atb-theme/light.d.ts +365 -672
- package/lib/themes/atb-theme/light.js +361 -666
- package/lib/themes/atb-theme/light.js.map +1 -1
- package/lib/themes/atb-theme/theme.css +760 -0
- package/lib/themes/atb-theme/theme.d.ts +730 -1344
- package/lib/themes/atb-theme/theme.js +11 -6
- package/lib/themes/atb-theme/theme.js.map +1 -1
- package/lib/themes/atb-theme/theme.module.css +760 -0
- package/lib/themes/index.js +8 -1
- package/lib/themes/index.js.map +1 -1
- package/lib/themes-fs/atb-theme/dark.d.ts +722 -0
- package/lib/themes-fs/atb-theme/dark.js +724 -0
- package/lib/themes-fs/atb-theme/dark.js.map +1 -0
- package/lib/themes-fs/atb-theme/light.d.ts +722 -0
- package/lib/themes-fs/atb-theme/light.js +724 -0
- package/lib/themes-fs/atb-theme/light.js.map +1 -0
- package/lib/themes-fs/atb-theme/theme.d.ts +1442 -0
- package/lib/themes-fs/atb-theme/theme.js +16 -0
- package/lib/themes-fs/atb-theme/theme.js.map +1 -0
- package/lib/themes-fs/index.d.ts +1 -0
- package/lib/themes-fs/index.js +13 -0
- package/lib/themes-fs/index.js.map +1 -0
- package/lib/typography/android.js +32 -51
- package/lib/typography/android.js.map +1 -1
- package/lib/typography/index.d.ts +3 -3
- package/lib/typography/index.js +44 -19
- package/lib/typography/index.js.map +1 -1
- package/lib/typography/ios.js +32 -51
- package/lib/typography/ios.js.map +1 -1
- package/lib/typography/types.d.ts +5 -5
- package/lib/typography/types.js +4 -1
- package/lib/typography/types.js.map +1 -1
- package/lib/typography.css +260 -0
- package/lib/typography.module.css +260 -0
- package/lib/utils/override-config.d.ts +1 -1
- package/lib/utils/override-config.js +18 -4
- package/lib/utils/override-config.js.map +1 -1
- package/package.json +16 -11
- package/lib/sizes.d.ts +0 -23
- package/lib/sizes.js +0 -23
- package/lib/sizes.js.map +0 -1
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Do not edit directly, this file was auto-generated.
|
|
4
|
+
*/
|
|
5
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
6
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
7
|
+
};
|
|
8
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9
|
+
var light_1 = __importDefault(require("./light"));
|
|
10
|
+
var dark_1 = __importDefault(require("./dark"));
|
|
11
|
+
var themes = {
|
|
12
|
+
light: light_1.default,
|
|
13
|
+
dark: dark_1.default
|
|
14
|
+
};
|
|
15
|
+
exports.default = themes;
|
|
16
|
+
//# sourceMappingURL=theme.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme.js","sourceRoot":"","sources":["../../../src/themes-fs/atb-theme/theme.ts"],"names":[],"mappings":";AAAA;;GAEG;;;;;AAGH,kDAA2B;AAC3B,gDAAyB;AAEzB,IAAM,MAAM,GAAG;IACb,KAAK,iBAAA;IACL,IAAI,gBAAA;CACL,CAAA;AAED,kBAAe,MAAM,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as AtBThemesFs } from './atb-theme/theme';
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.AtBThemesFs = void 0;
|
|
7
|
+
var theme_1 = require("./atb-theme/theme");
|
|
8
|
+
Object.defineProperty(exports, "AtBThemesFs", { enumerable: true, get: function () { return __importDefault(theme_1).default; } });
|
|
9
|
+
// export {default as NfkThemesFs} from './nfk-theme/theme';
|
|
10
|
+
// export {default as FRAMThemesFs} from './fram-theme/theme';
|
|
11
|
+
// export {default as TromsThemesFs} from './troms-theme/theme';
|
|
12
|
+
// export {default as InnlandetThemesFs} from './innlandet-theme/theme';
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/themes-fs/index.ts"],"names":[],"mappings":";;;;;;AAAA,2CAAyD;AAAjD,qHAAA,OAAO,OAAe;AAC9B,4DAA4D;AAC5D,8DAA8D;AAC9D,gEAAgE;AAChE,wEAAwE"}
|
|
@@ -1,43 +1,48 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __assign = (this && this.__assign) || function () {
|
|
3
|
+
__assign = Object.assign || function(t) {
|
|
4
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
5
|
+
s = arguments[i];
|
|
6
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
7
|
+
t[p] = s[p];
|
|
8
|
+
}
|
|
9
|
+
return t;
|
|
10
|
+
};
|
|
11
|
+
return __assign.apply(this, arguments);
|
|
12
|
+
};
|
|
13
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
|
+
exports.androidTextTypeStyles = exports.androidFontData = void 0;
|
|
15
|
+
var primaryBase = {
|
|
2
16
|
fontSize: 16,
|
|
3
17
|
lineHeight: 20,
|
|
4
18
|
letterSpacing: 0.5,
|
|
5
19
|
};
|
|
6
|
-
|
|
20
|
+
var secondaryBase = {
|
|
7
21
|
fontSize: 14,
|
|
8
22
|
lineHeight: 20,
|
|
9
23
|
letterSpacing: 0.25,
|
|
10
24
|
};
|
|
11
|
-
|
|
25
|
+
var tertiaryBase = {
|
|
12
26
|
fontSize: 12,
|
|
13
27
|
lineHeight: 16,
|
|
14
28
|
letterSpacing: 0.4,
|
|
15
29
|
};
|
|
16
|
-
|
|
30
|
+
var labelBase = {
|
|
17
31
|
fontSize: 10,
|
|
18
32
|
lineHeight: 16,
|
|
19
33
|
letterSpacing: 0,
|
|
20
34
|
};
|
|
21
|
-
|
|
35
|
+
exports.androidFontData = {
|
|
22
36
|
main: {
|
|
23
37
|
url: 'https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&display=swap',
|
|
24
|
-
fontFamily:
|
|
38
|
+
fontFamily: "'Roboto', sans-serif",
|
|
25
39
|
},
|
|
26
40
|
};
|
|
27
|
-
|
|
41
|
+
exports.androidTextTypeStyles = {
|
|
28
42
|
body__primary: primaryBase,
|
|
29
|
-
'body__primary--bold': {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
},
|
|
33
|
-
'body__primary--strike': {
|
|
34
|
-
...primaryBase,
|
|
35
|
-
textDecorationLine: 'line-through',
|
|
36
|
-
},
|
|
37
|
-
'body__primary--underline': {
|
|
38
|
-
...primaryBase,
|
|
39
|
-
textDecorationLine: 'underline',
|
|
40
|
-
},
|
|
43
|
+
'body__primary--bold': __assign(__assign({}, primaryBase), { fontWeight: '500' }),
|
|
44
|
+
'body__primary--strike': __assign(__assign({}, primaryBase), { textDecorationLine: 'line-through' }),
|
|
45
|
+
'body__primary--underline': __assign(__assign({}, primaryBase), { textDecorationLine: 'underline' }),
|
|
41
46
|
'body__primary--big': {
|
|
42
47
|
fontSize: 24,
|
|
43
48
|
lineHeight: 28,
|
|
@@ -61,35 +66,14 @@ export const androidTextTypeStyles = {
|
|
|
61
66
|
fontWeight: 'bold',
|
|
62
67
|
},
|
|
63
68
|
body__secondary: secondaryBase,
|
|
64
|
-
'body__secondary--bold': {
|
|
65
|
-
...secondaryBase,
|
|
66
|
-
fontWeight: '500',
|
|
67
|
-
},
|
|
69
|
+
'body__secondary--bold': __assign(__assign({}, secondaryBase), { fontWeight: '500' }),
|
|
68
70
|
body__tertiary: tertiaryBase,
|
|
69
|
-
'body__tertiary--bold': {
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
},
|
|
73
|
-
'
|
|
74
|
-
|
|
75
|
-
textDecorationLine: 'line-through',
|
|
76
|
-
},
|
|
77
|
-
'body__tertiary--uppercase': {
|
|
78
|
-
...primaryBase,
|
|
79
|
-
textTransform: 'uppercase',
|
|
80
|
-
},
|
|
81
|
-
heading__title: {
|
|
82
|
-
...primaryBase,
|
|
83
|
-
fontWeight: 'bold',
|
|
84
|
-
},
|
|
85
|
-
heading__component: {
|
|
86
|
-
...primaryBase,
|
|
87
|
-
fontWeight: '500',
|
|
88
|
-
},
|
|
89
|
-
heading__paragraph: {
|
|
90
|
-
...primaryBase,
|
|
91
|
-
fontWeight: '500',
|
|
92
|
-
},
|
|
71
|
+
'body__tertiary--bold': __assign(__assign({}, tertiaryBase), { fontWeight: '500' }),
|
|
72
|
+
'body__tertiary--strike': __assign(__assign({}, tertiaryBase), { textDecorationLine: 'line-through' }),
|
|
73
|
+
'body__tertiary--uppercase': __assign(__assign({}, primaryBase), { textTransform: 'uppercase' }),
|
|
74
|
+
heading__title: __assign(__assign({}, primaryBase), { fontWeight: 'bold' }),
|
|
75
|
+
heading__component: __assign(__assign({}, primaryBase), { fontWeight: '500' }),
|
|
76
|
+
heading__paragraph: __assign(__assign({}, primaryBase), { fontWeight: '500' }),
|
|
93
77
|
'heading--medium': {
|
|
94
78
|
fontSize: 20,
|
|
95
79
|
lineHeight: 24,
|
|
@@ -108,9 +92,6 @@ export const androidTextTypeStyles = {
|
|
|
108
92
|
letterSpacing: -0.31,
|
|
109
93
|
fontWeight: 'bold',
|
|
110
94
|
},
|
|
111
|
-
label__uppercase: {
|
|
112
|
-
...labelBase,
|
|
113
|
-
textTransform: 'uppercase',
|
|
114
|
-
},
|
|
95
|
+
label__uppercase: __assign(__assign({}, labelBase), { textTransform: 'uppercase' }),
|
|
115
96
|
};
|
|
116
97
|
//# sourceMappingURL=android.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"android.js","sourceRoot":"","sources":["../../src/typography/android.ts"],"names":[],"mappings":"AAEA,
|
|
1
|
+
{"version":3,"file":"android.js","sourceRoot":"","sources":["../../src/typography/android.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAEA,IAAM,WAAW,GAAc;IAC7B,QAAQ,EAAE,EAAE;IACZ,UAAU,EAAE,EAAE;IACd,aAAa,EAAE,GAAG;CACnB,CAAC;AACF,IAAM,aAAa,GAAc;IAC/B,QAAQ,EAAE,EAAE;IACZ,UAAU,EAAE,EAAE;IACd,aAAa,EAAE,IAAI;CACpB,CAAC;AACF,IAAM,YAAY,GAAc;IAC9B,QAAQ,EAAE,EAAE;IACZ,UAAU,EAAE,EAAE;IACd,aAAa,EAAE,GAAG;CACnB,CAAC;AACF,IAAM,SAAS,GAAc;IAC3B,QAAQ,EAAE,EAAE;IACZ,UAAU,EAAE,EAAE;IACd,aAAa,EAAE,CAAC;CACjB,CAAC;AAEW,QAAA,eAAe,GAAa;IACvC,IAAI,EAAE;QACJ,GAAG,EAAE,+EAA+E;QACpF,UAAU,EAAE,sBAAsB;KACnC;CACF,CAAC;AAEW,QAAA,qBAAqB,GAAmB;IACnD,aAAa,EAAE,WAAW;IAC1B,qBAAqB,wBAChB,WAAW,KACd,UAAU,EAAE,KAAK,GAClB;IACD,uBAAuB,wBAClB,WAAW,KACd,kBAAkB,EAAE,cAAc,GACnC;IACD,0BAA0B,wBACrB,WAAW,KACd,kBAAkB,EAAE,WAAW,GAChC;IACD,oBAAoB,EAAE;QACpB,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAI;KACpB;IACD,0BAA0B,EAAE;QAC1B,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAI;QACnB,UAAU,EAAE,MAAM;KACnB;IACD,sBAAsB,EAAE;QACtB,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAI;KACpB;IACD,4BAA4B,EAAE;QAC5B,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAI;QACnB,UAAU,EAAE,MAAM;KACnB;IACD,eAAe,EAAE,aAAa;IAC9B,uBAAuB,wBAClB,aAAa,KAChB,UAAU,EAAE,KAAK,GAClB;IACD,cAAc,EAAE,YAAY;IAC5B,sBAAsB,wBACjB,YAAY,KACf,UAAU,EAAE,KAAK,GAClB;IACD,wBAAwB,wBACnB,YAAY,KACf,kBAAkB,EAAE,cAAc,GACnC;IACD,2BAA2B,wBACtB,WAAW,KACd,aAAa,EAAE,WAAW,GAC3B;IACD,cAAc,wBACT,WAAW,KACd,UAAU,EAAE,MAAM,GACnB;IACD,kBAAkB,wBACb,WAAW,KACd,UAAU,EAAE,KAAK,GAClB;IACD,kBAAkB,wBACb,WAAW,KACd,UAAU,EAAE,KAAK,GAClB;IACD,iBAAiB,EAAE;QACjB,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,GAAG;QAClB,UAAU,EAAE,MAAM;KACnB;IACD,cAAc,EAAE;QACd,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,CAAC,IAAI;QACpB,UAAU,EAAE,MAAM;KACnB;IACD,gBAAgB,EAAE;QAChB,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,CAAC,IAAI;QACpB,UAAU,EAAE,MAAM;KACnB;IACD,gBAAgB,wBACX,SAAS,KACZ,aAAa,EAAE,WAAW,GAC3B;CACF,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { TextTypeStyles } from '.';
|
|
2
2
|
import { ConfigurationOverride } from '../utils/override-config';
|
|
3
|
-
|
|
4
|
-
|
|
3
|
+
type _MappedPlatforms = 'ios' | 'android';
|
|
4
|
+
type PlatformTypes = _MappedPlatforms | 'web';
|
|
5
5
|
export * from './types';
|
|
6
6
|
export declare const textTypeStyles: {
|
|
7
7
|
android: TextTypeStyles;
|
|
@@ -60,4 +60,4 @@ export declare function createTextTypeStyles(type: PlatformTypes, overrides?: Co
|
|
|
60
60
|
* @param extension - Object to extend original text type style. Can be nested with same keys as style
|
|
61
61
|
* @returns new deep merged intersection
|
|
62
62
|
*/
|
|
63
|
-
export declare function extendTextTypeStyles<T>(type: PlatformTypes, extension: T): ((k: TextTypeStyles) => void) | (T extends any ? (k: T) => void : never) extends (k: infer I) => void ? I : never;
|
|
63
|
+
export declare function extendTextTypeStyles<T extends {}>(type: PlatformTypes, extension: T): ((k: TextTypeStyles) => void) | (T extends any ? (k: T) => void : never) extends (k: infer I) => void ? I : never;
|
package/lib/typography/index.js
CHANGED
|
@@ -1,16 +1,41 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
10
15
|
};
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
16
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
17
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
18
|
+
};
|
|
19
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
20
|
+
exports.fonts = exports.textTypeStyles = void 0;
|
|
21
|
+
exports.getFontBook = getFontBook;
|
|
22
|
+
exports.createTextTypeStyles = createTextTypeStyles;
|
|
23
|
+
exports.extendTextTypeStyles = extendTextTypeStyles;
|
|
24
|
+
var ts_deepmerge_1 = __importDefault(require("ts-deepmerge"));
|
|
25
|
+
var override_config_1 = require("../utils/override-config");
|
|
26
|
+
var android_1 = require("./android");
|
|
27
|
+
var ios_1 = require("./ios");
|
|
28
|
+
var mapType = function (a) {
|
|
29
|
+
return a === 'ios' ? 'ios' : 'android';
|
|
30
|
+
};
|
|
31
|
+
__exportStar(require("./types"), exports);
|
|
32
|
+
exports.textTypeStyles = {
|
|
33
|
+
android: android_1.androidTextTypeStyles,
|
|
34
|
+
ios: ios_1.iosTextTypeStyles,
|
|
35
|
+
};
|
|
36
|
+
exports.fonts = {
|
|
37
|
+
android: android_1.androidFontData,
|
|
38
|
+
ios: ios_1.iosFontData,
|
|
14
39
|
};
|
|
15
40
|
/**
|
|
16
41
|
* Get fonts for platform. Web should use Android as platform.
|
|
@@ -18,8 +43,8 @@ export const fonts = {
|
|
|
18
43
|
* @param overrides - Properties to override base config with
|
|
19
44
|
* @returns text type styles
|
|
20
45
|
*/
|
|
21
|
-
|
|
22
|
-
return fonts[mapType(type)];
|
|
46
|
+
function getFontBook(type) {
|
|
47
|
+
return exports.fonts[mapType(type)];
|
|
23
48
|
}
|
|
24
49
|
/**
|
|
25
50
|
* Create new text type style with optinally overriden defaults.
|
|
@@ -37,10 +62,10 @@ export function getFontBook(type) {
|
|
|
37
62
|
* @param overrides - Properties to override base config with
|
|
38
63
|
* @returns text type styles
|
|
39
64
|
*/
|
|
40
|
-
|
|
65
|
+
function createTextTypeStyles(type, overrides) {
|
|
41
66
|
if (!overrides)
|
|
42
|
-
return textTypeStyles[mapType(type)];
|
|
43
|
-
return overrideConfig(textTypeStyles[mapType(type)], overrides);
|
|
67
|
+
return exports.textTypeStyles[mapType(type)];
|
|
68
|
+
return (0, override_config_1.overrideConfig)(exports.textTypeStyles[mapType(type)], overrides);
|
|
44
69
|
}
|
|
45
70
|
/**
|
|
46
71
|
* Use text type style as base and extend with new properties. Properties
|
|
@@ -67,7 +92,7 @@ export function createTextTypeStyles(type, overrides) {
|
|
|
67
92
|
* @param extension - Object to extend original text type style. Can be nested with same keys as style
|
|
68
93
|
* @returns new deep merged intersection
|
|
69
94
|
*/
|
|
70
|
-
|
|
71
|
-
return
|
|
95
|
+
function extendTextTypeStyles(type, extension) {
|
|
96
|
+
return (0, ts_deepmerge_1.default)(exports.textTypeStyles[mapType(type)], extension);
|
|
72
97
|
}
|
|
73
98
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/typography/index.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/typography/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;AA8BA,kCAEC;AAkBD,oDAMC;AA2BD,oDAEC;AArFD,8DAAiC;AAEjC,4DAA+E;AAE/E,qCAAiE;AACjE,6BAAqD;AAIrD,IAAM,OAAO,GAAG,UAAC,CAAgB;IAC/B,OAAA,CAAC,KAAK,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,SAAS;AAA/B,CAA+B,CAAC;AAElC,0CAAwB;AAEX,QAAA,cAAc,GAAG;IAC5B,OAAO,EAAE,+BAAqB;IAC9B,GAAG,EAAE,uBAAiB;CACvB,CAAC;AAEW,QAAA,KAAK,GAAG;IACnB,OAAO,EAAE,yBAAe;IACxB,GAAG,EAAE,iBAAW;CACjB,CAAC;AAEF;;;;;GAKG;AACH,SAAgB,WAAW,CAAC,IAAmB;IAC7C,OAAO,aAAK,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;AAC9B,CAAC;AAED;;;;;;;;;;;;;;;GAeG;AACH,SAAgB,oBAAoB,CAClC,IAAmB,EACnB,SAAiD;IAEjD,IAAI,CAAC,SAAS;QAAE,OAAO,sBAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,CAAC;IACrD,OAAO,IAAA,gCAAc,EAAC,sBAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,EAAE,SAAS,CAAC,CAAC;AAClE,CAAC;AAED;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,SAAgB,oBAAoB,CAAe,IAAmB,EAAE,SAAY;IAClF,OAAO,IAAA,sBAAK,EAAC,sBAAc,CAAC,OAAO,CAAC,IAAI,CAAC,CAAC,EAAE,SAAS,CAAC,CAAC;AACzD,CAAC"}
|
package/lib/typography/ios.js
CHANGED
|
@@ -1,42 +1,47 @@
|
|
|
1
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
var __assign = (this && this.__assign) || function () {
|
|
3
|
+
__assign = Object.assign || function(t) {
|
|
4
|
+
for (var s, i = 1, n = arguments.length; i < n; i++) {
|
|
5
|
+
s = arguments[i];
|
|
6
|
+
for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
|
|
7
|
+
t[p] = s[p];
|
|
8
|
+
}
|
|
9
|
+
return t;
|
|
10
|
+
};
|
|
11
|
+
return __assign.apply(this, arguments);
|
|
12
|
+
};
|
|
13
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
14
|
+
exports.iosTextTypeStyles = exports.iosFontData = void 0;
|
|
15
|
+
var primaryBase = {
|
|
2
16
|
fontSize: 16,
|
|
3
17
|
lineHeight: 20,
|
|
4
18
|
letterSpacing: -0.31,
|
|
5
19
|
};
|
|
6
|
-
|
|
20
|
+
var secondaryBase = {
|
|
7
21
|
fontSize: 14,
|
|
8
22
|
lineHeight: 20,
|
|
9
23
|
letterSpacing: -0.15,
|
|
10
24
|
};
|
|
11
|
-
|
|
25
|
+
var tertiaryBase = {
|
|
12
26
|
fontSize: 12,
|
|
13
27
|
lineHeight: 16,
|
|
14
28
|
letterSpacing: 0,
|
|
15
29
|
};
|
|
16
|
-
|
|
30
|
+
var labelBase = {
|
|
17
31
|
fontSize: 10,
|
|
18
32
|
lineHeight: 16,
|
|
19
33
|
letterSpacing: 0,
|
|
20
34
|
};
|
|
21
|
-
|
|
35
|
+
exports.iosFontData = {
|
|
22
36
|
main: {
|
|
23
|
-
fontFamily:
|
|
37
|
+
fontFamily: "'SF Pro Text', -apple-system, BlinkMacSystemFont",
|
|
24
38
|
},
|
|
25
39
|
};
|
|
26
|
-
|
|
40
|
+
exports.iosTextTypeStyles = {
|
|
27
41
|
body__primary: primaryBase,
|
|
28
|
-
'body__primary--bold': {
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
},
|
|
32
|
-
'body__primary--strike': {
|
|
33
|
-
...primaryBase,
|
|
34
|
-
textDecorationLine: 'line-through',
|
|
35
|
-
},
|
|
36
|
-
'body__primary--underline': {
|
|
37
|
-
...primaryBase,
|
|
38
|
-
textDecorationLine: 'underline',
|
|
39
|
-
},
|
|
42
|
+
'body__primary--bold': __assign(__assign({}, primaryBase), { fontWeight: '600' }),
|
|
43
|
+
'body__primary--strike': __assign(__assign({}, primaryBase), { textDecorationLine: 'line-through' }),
|
|
44
|
+
'body__primary--underline': __assign(__assign({}, primaryBase), { textDecorationLine: 'underline' }),
|
|
40
45
|
'body__primary--big': {
|
|
41
46
|
fontSize: 24,
|
|
42
47
|
lineHeight: 28,
|
|
@@ -60,35 +65,14 @@ export const iosTextTypeStyles = {
|
|
|
60
65
|
fontWeight: 'bold',
|
|
61
66
|
},
|
|
62
67
|
body__secondary: secondaryBase,
|
|
63
|
-
'body__secondary--bold': {
|
|
64
|
-
...secondaryBase,
|
|
65
|
-
fontWeight: '600',
|
|
66
|
-
},
|
|
68
|
+
'body__secondary--bold': __assign(__assign({}, secondaryBase), { fontWeight: '600' }),
|
|
67
69
|
body__tertiary: tertiaryBase,
|
|
68
|
-
'body__tertiary--bold': {
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
},
|
|
72
|
-
'
|
|
73
|
-
|
|
74
|
-
textDecorationLine: 'line-through',
|
|
75
|
-
},
|
|
76
|
-
'body__tertiary--uppercase': {
|
|
77
|
-
...primaryBase,
|
|
78
|
-
textTransform: 'uppercase',
|
|
79
|
-
},
|
|
80
|
-
heading__title: {
|
|
81
|
-
...primaryBase,
|
|
82
|
-
fontWeight: 'bold',
|
|
83
|
-
},
|
|
84
|
-
heading__component: {
|
|
85
|
-
...primaryBase,
|
|
86
|
-
fontWeight: '600',
|
|
87
|
-
},
|
|
88
|
-
heading__paragraph: {
|
|
89
|
-
...primaryBase,
|
|
90
|
-
fontWeight: '600',
|
|
91
|
-
},
|
|
70
|
+
'body__tertiary--bold': __assign(__assign({}, tertiaryBase), { fontWeight: '600' }),
|
|
71
|
+
'body__tertiary--strike': __assign(__assign({}, tertiaryBase), { textDecorationLine: 'line-through' }),
|
|
72
|
+
'body__tertiary--uppercase': __assign(__assign({}, primaryBase), { textTransform: 'uppercase' }),
|
|
73
|
+
heading__title: __assign(__assign({}, primaryBase), { fontWeight: 'bold' }),
|
|
74
|
+
heading__component: __assign(__assign({}, primaryBase), { fontWeight: '600' }),
|
|
75
|
+
heading__paragraph: __assign(__assign({}, primaryBase), { fontWeight: '600' }),
|
|
92
76
|
'heading--medium': {
|
|
93
77
|
fontSize: 20,
|
|
94
78
|
lineHeight: 24,
|
|
@@ -107,9 +91,6 @@ export const iosTextTypeStyles = {
|
|
|
107
91
|
letterSpacing: -0.31,
|
|
108
92
|
fontWeight: 'bold',
|
|
109
93
|
},
|
|
110
|
-
label__uppercase: {
|
|
111
|
-
...labelBase,
|
|
112
|
-
textTransform: 'uppercase',
|
|
113
|
-
},
|
|
94
|
+
label__uppercase: __assign(__assign({}, labelBase), { textTransform: 'uppercase' }),
|
|
114
95
|
};
|
|
115
96
|
//# sourceMappingURL=ios.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ios.js","sourceRoot":"","sources":["../../src/typography/ios.ts"],"names":[],"mappings":"AAEA,
|
|
1
|
+
{"version":3,"file":"ios.js","sourceRoot":"","sources":["../../src/typography/ios.ts"],"names":[],"mappings":";;;;;;;;;;;;;;AAEA,IAAM,WAAW,GAAc;IAC7B,QAAQ,EAAE,EAAE;IACZ,UAAU,EAAE,EAAE;IACd,aAAa,EAAE,CAAC,IAAI;CACrB,CAAC;AACF,IAAM,aAAa,GAAc;IAC/B,QAAQ,EAAE,EAAE;IACZ,UAAU,EAAE,EAAE;IACd,aAAa,EAAE,CAAC,IAAI;CACrB,CAAC;AACF,IAAM,YAAY,GAAc;IAC9B,QAAQ,EAAE,EAAE;IACZ,UAAU,EAAE,EAAE;IACd,aAAa,EAAE,CAAC;CACjB,CAAC;AACF,IAAM,SAAS,GAAc;IAC3B,QAAQ,EAAE,EAAE;IACZ,UAAU,EAAE,EAAE;IACd,aAAa,EAAE,CAAC;CACjB,CAAC;AAEW,QAAA,WAAW,GAAa;IACnC,IAAI,EAAE;QACJ,UAAU,EAAE,kDAAkD;KAC/D;CACF,CAAC;AAEW,QAAA,iBAAiB,GAAmB;IAC/C,aAAa,EAAE,WAAW;IAC1B,qBAAqB,wBAChB,WAAW,KACd,UAAU,EAAE,KAAK,GAClB;IACD,uBAAuB,wBAClB,WAAW,KACd,kBAAkB,EAAE,cAAc,GACnC;IACD,0BAA0B,wBACrB,WAAW,KACd,kBAAkB,EAAE,WAAW,GAChC;IACD,oBAAoB,EAAE;QACpB,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAI;KACpB;IACD,0BAA0B,EAAE;QAC1B,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAI;QACnB,UAAU,EAAE,MAAM;KACnB;IACD,sBAAsB,EAAE;QACtB,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAI;KACpB;IACD,4BAA4B,EAAE;QAC5B,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,IAAI;QACnB,UAAU,EAAE,MAAM;KACnB;IACD,eAAe,EAAE,aAAa;IAC9B,uBAAuB,wBAClB,aAAa,KAChB,UAAU,EAAE,KAAK,GAClB;IACD,cAAc,EAAE,YAAY;IAC5B,sBAAsB,wBACjB,YAAY,KACf,UAAU,EAAE,KAAK,GAClB;IACD,wBAAwB,wBACnB,YAAY,KACf,kBAAkB,EAAE,cAAc,GACnC;IACD,2BAA2B,wBACtB,WAAW,KACd,aAAa,EAAE,WAAW,GAC3B;IACD,cAAc,wBACT,WAAW,KACd,UAAU,EAAE,MAAM,GACnB;IACD,kBAAkB,wBACb,WAAW,KACd,UAAU,EAAE,KAAK,GAClB;IACD,kBAAkB,wBACb,WAAW,KACd,UAAU,EAAE,KAAK,GAClB;IACD,iBAAiB,EAAE;QACjB,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,CAAC,IAAI;QACpB,UAAU,EAAE,KAAK;KAClB;IACD,cAAc,EAAE;QACd,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,CAAC,IAAI;QACpB,UAAU,EAAE,KAAK;KAClB;IACD,gBAAgB,EAAE;QAChB,QAAQ,EAAE,EAAE;QACZ,UAAU,EAAE,EAAE;QACd,aAAa,EAAE,CAAC,IAAI;QACpB,UAAU,EAAE,MAAM;KACnB;IACD,gBAAgB,wBACX,SAAS,KACZ,aAAa,EAAE,WAAW,GAC3B;CACF,CAAC"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
export declare const textNames: readonly ["body__primary", "body__primary--strike", "body__primary--bold", "body__primary--underline", "body__primary--big", "body__primary--big--bold", "body__primary--jumbo", "body__primary--jumbo--bold", "body__secondary", "body__secondary--bold", "body__tertiary", "body__tertiary--bold", "body__tertiary--uppercase", "body__tertiary--strike", "heading__title", "heading__component", "heading__paragraph", "heading--medium", "heading--big", "heading--jumbo", "label__uppercase"];
|
|
2
|
-
export
|
|
2
|
+
export type FontMetadata = {
|
|
3
3
|
url?: string;
|
|
4
4
|
fontFamily: string;
|
|
5
5
|
};
|
|
6
|
-
export
|
|
6
|
+
export type FontBook = {
|
|
7
7
|
main: FontMetadata;
|
|
8
8
|
[fontName: string]: FontMetadata;
|
|
9
9
|
};
|
|
10
|
-
export
|
|
11
|
-
export
|
|
10
|
+
export type TextNames = (typeof textNames)[number];
|
|
11
|
+
export type TextStyle = {
|
|
12
12
|
fontSize: number;
|
|
13
13
|
letterSpacing: number;
|
|
14
14
|
lineHeight: number;
|
|
@@ -16,6 +16,6 @@ export declare type TextStyle = {
|
|
|
16
16
|
fontWeight?: 'normal' | 'bold' | '100' | '200' | '300' | '400' | '500' | '600' | '700' | '800' | '900';
|
|
17
17
|
textTransform?: 'uppercase' | 'lowercase' | 'capitalize' | 'none';
|
|
18
18
|
};
|
|
19
|
-
export
|
|
19
|
+
export type TextTypeStyles = {
|
|
20
20
|
[key in TextNames]: TextStyle;
|
|
21
21
|
};
|
package/lib/typography/types.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/typography/types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../src/typography/types.ts"],"names":[],"mappings":";;;AAAa,QAAA,SAAS,GAAG;IACvB,eAAe;IACf,uBAAuB;IACvB,qBAAqB;IACrB,0BAA0B;IAC1B,oBAAoB;IACpB,0BAA0B;IAC1B,sBAAsB;IACtB,4BAA4B;IAC5B,iBAAiB;IACjB,uBAAuB;IACvB,gBAAgB;IAChB,sBAAsB;IACtB,2BAA2B;IAC3B,wBAAwB;IACxB,gBAAgB;IAChB,oBAAoB;IACpB,oBAAoB;IACpB,iBAAiB;IACjB,cAAc;IACd,gBAAgB;IAChB,kBAAkB;CACV,CAAC"}
|