@remember-web/mixin 0.1.11 → 0.1.13

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.
Files changed (77) hide show
  1. package/dist/mixin/src/colors/index.d.ts +4 -0
  2. package/dist/mixin/src/colors/index.d.ts.map +1 -0
  3. package/dist/mixin/src/colors/theme.cjs.js +76 -0
  4. package/dist/mixin/src/colors/theme.cjs.js.map +1 -0
  5. package/dist/mixin/src/colors/theme.d.ts +6 -0
  6. package/dist/mixin/src/colors/theme.d.ts.map +1 -0
  7. package/dist/mixin/src/colors/theme.esm.js +74 -0
  8. package/dist/mixin/src/colors/theme.esm.js.map +1 -0
  9. package/dist/mixin/src/colors/types.d.ts +21 -0
  10. package/dist/mixin/src/colors/types.d.ts.map +1 -0
  11. package/dist/mixin/src/colors/utils.cjs.js +73 -0
  12. package/dist/mixin/src/colors/utils.cjs.js.map +1 -0
  13. package/dist/mixin/src/colors/utils.d.ts +21 -0
  14. package/dist/mixin/src/colors/utils.d.ts.map +1 -0
  15. package/dist/mixin/src/colors/utils.esm.js +61 -0
  16. package/dist/mixin/src/colors/utils.esm.js.map +1 -0
  17. package/dist/mixin/src/colors/variables.cjs.js +78 -0
  18. package/dist/mixin/src/colors/variables.cjs.js.map +1 -0
  19. package/dist/mixin/src/colors/variables.d.ts +32 -0
  20. package/dist/mixin/src/colors/variables.d.ts.map +1 -0
  21. package/dist/mixin/src/colors/variables.esm.js +46 -0
  22. package/dist/mixin/src/colors/variables.esm.js.map +1 -0
  23. package/dist/mixin/src/index.cjs.js +63 -0
  24. package/dist/mixin/src/index.cjs.js.map +1 -0
  25. package/dist/mixin/src/index.d.ts +5 -0
  26. package/dist/mixin/src/index.d.ts.map +1 -0
  27. package/dist/mixin/src/index.esm.js +8 -0
  28. package/dist/mixin/src/index.esm.js.map +1 -0
  29. package/dist/mixin/src/mediaQuery/const.cjs.js +8 -0
  30. package/dist/mixin/src/mediaQuery/const.cjs.js.map +1 -0
  31. package/dist/mixin/src/mediaQuery/const.d.ts +3 -0
  32. package/dist/mixin/src/mediaQuery/const.d.ts.map +1 -0
  33. package/dist/mixin/src/mediaQuery/const.esm.js +5 -0
  34. package/dist/mixin/src/mediaQuery/const.esm.js.map +1 -0
  35. package/dist/mixin/src/mediaQuery/index.cjs.js +43 -0
  36. package/dist/mixin/src/mediaQuery/index.cjs.js.map +1 -0
  37. package/dist/mixin/src/mediaQuery/index.d.ts +10 -0
  38. package/dist/mixin/src/mediaQuery/index.d.ts.map +1 -0
  39. package/dist/mixin/src/mediaQuery/index.esm.js +32 -0
  40. package/dist/mixin/src/mediaQuery/index.esm.js.map +1 -0
  41. package/dist/mixin/src/provider/index.cjs.js +43 -0
  42. package/dist/mixin/src/provider/index.cjs.js.map +1 -0
  43. package/dist/mixin/src/provider/index.d.ts +18 -0
  44. package/dist/mixin/src/provider/index.d.ts.map +1 -0
  45. package/dist/mixin/src/provider/index.esm.js +40 -0
  46. package/dist/mixin/src/provider/index.esm.js.map +1 -0
  47. package/dist/mixin/src/provider/styles.cjs.js +43 -0
  48. package/dist/mixin/src/provider/styles.cjs.js.map +1 -0
  49. package/dist/mixin/src/provider/styles.d.ts +7 -0
  50. package/dist/mixin/src/provider/styles.d.ts.map +1 -0
  51. package/dist/mixin/src/provider/styles.esm.js +35 -0
  52. package/dist/mixin/src/provider/styles.esm.js.map +1 -0
  53. package/dist/mixin/src/typography/const.cjs.js +120 -0
  54. package/dist/mixin/src/typography/const.cjs.js.map +1 -0
  55. package/dist/mixin/src/typography/const.d.ts +102 -0
  56. package/dist/mixin/src/typography/const.d.ts.map +1 -0
  57. package/dist/mixin/src/typography/const.esm.js +113 -0
  58. package/dist/mixin/src/typography/const.esm.js.map +1 -0
  59. package/dist/mixin/src/typography/index.d.ts +4 -0
  60. package/dist/mixin/src/typography/index.d.ts.map +1 -0
  61. package/dist/mixin/src/typography/types.d.ts +3 -0
  62. package/dist/mixin/src/typography/types.d.ts.map +1 -0
  63. package/dist/mixin/src/typography/utils.cjs.js +60 -0
  64. package/dist/mixin/src/typography/utils.cjs.js.map +1 -0
  65. package/dist/mixin/src/typography/utils.d.ts +31 -0
  66. package/dist/mixin/src/typography/utils.d.ts.map +1 -0
  67. package/dist/mixin/src/typography/utils.esm.js +52 -0
  68. package/dist/mixin/src/typography/utils.esm.js.map +1 -0
  69. package/dist/shared/utils/common.cjs.js +8 -0
  70. package/dist/shared/utils/common.cjs.js.map +1 -0
  71. package/dist/shared/utils/common.d.ts +3 -0
  72. package/dist/shared/utils/common.d.ts.map +1 -0
  73. package/dist/shared/utils/common.esm.js +6 -0
  74. package/dist/shared/utils/common.esm.js.map +1 -0
  75. package/package.json +3 -4
  76. package/src/colors/color.stories.tsx +67 -0
  77. package/src/provider/index.tsx +1 -1
@@ -0,0 +1,63 @@
1
+ 'use strict';
2
+
3
+ var variables = require('./colors/variables.cjs.js');
4
+ var utils = require('./colors/utils.cjs.js');
5
+ var index = require('./mediaQuery/index.cjs.js');
6
+ var _const$1 = require('./typography/const.cjs.js');
7
+ var utils$1 = require('./typography/utils.cjs.js');
8
+ var index$1 = require('./provider/index.cjs.js');
9
+ var _const = require('./mediaQuery/const.cjs.js');
10
+
11
+
12
+
13
+ exports.bg100 = variables.bg100;
14
+ exports.bg200 = variables.bg200;
15
+ exports.bg300 = variables.bg300;
16
+ exports.bgHighlight = variables.bgHighlight;
17
+ exports.bgModal100 = variables.bgModal100;
18
+ exports.bgModal200 = variables.bgModal200;
19
+ exports.bgRoleBlue = variables.bgRoleBlue;
20
+ exports.bgRoleGreen = variables.bgRoleGreen;
21
+ exports.bgRoleRed = variables.bgRoleRed;
22
+ exports.bgRoleYellow = variables.bgRoleYellow;
23
+ exports.bgSecondary100 = variables.bgSecondary100;
24
+ exports.contents000 = variables.contents000;
25
+ exports.contents100 = variables.contents100;
26
+ exports.contents150 = variables.contents150;
27
+ exports.contents200 = variables.contents200;
28
+ exports.contents300 = variables.contents300;
29
+ exports.contents999 = variables.contents999;
30
+ exports.disabled = variables.disabled;
31
+ exports.disabledRoleRed = variables.disabledRoleRed;
32
+ exports.disabledSecondary = variables.disabledSecondary;
33
+ exports.divider = variables.divider;
34
+ exports.fixedBgWhite = variables.fixedBgWhite;
35
+ exports.fixedBlack = variables.fixedBlack;
36
+ exports.fixedWhite = variables.fixedWhite;
37
+ exports.primary100 = variables.primary100;
38
+ exports.primary200 = variables.primary200;
39
+ exports.roleBlue = variables.roleBlue;
40
+ exports.roleGreen = variables.roleGreen;
41
+ exports.roleRed = variables.roleRed;
42
+ exports.roleYellow = variables.roleYellow;
43
+ exports.secondary100 = variables.secondary100;
44
+ exports.getBrowserTheme = utils.getBrowserTheme;
45
+ exports.getColorVariableName = utils.getColorVariableName;
46
+ exports.getHexFromRuiCssVariable = utils.getHexFromRuiCssVariable;
47
+ exports.getRgb = utils.getRgb;
48
+ exports.getRgba = utils.getRgba;
49
+ exports.hexToRgb = utils.hexToRgb;
50
+ exports.desktopOnly = index.desktopOnly;
51
+ exports.getDeviceWidthMediaQuery = index.getDeviceWidthMediaQuery;
52
+ exports.mobileOnly = index.mobileOnly;
53
+ exports.phoneOnly = index.phoneOnly;
54
+ exports.PRETENDARD_FONT_FAMILY = _const$1.PRETENDARD_FONT_FAMILY;
55
+ exports.TYPOGRAPHY_STYLES = _const$1.TYPOGRAPHY_STYLES;
56
+ exports.ellipsis = utils$1.ellipsis;
57
+ exports.getTypographyStyles = utils$1.getTypographyStyles;
58
+ exports.textEllipsis = utils$1.textEllipsis;
59
+ exports.RUIProvider = index$1.RUIProvider;
60
+ exports.useRUI = index$1.useRUI;
61
+ exports.DESKTOP_WIDTH = _const.DESKTOP_WIDTH;
62
+ exports.PHONE_WIDTH = _const.PHONE_WIDTH;
63
+ //# sourceMappingURL=index.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,5 @@
1
+ export * from './colors';
2
+ export * from './mediaQuery';
3
+ export * from './typography';
4
+ export * from './provider';
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,UAAU,CAAC;AACzB,cAAc,cAAc,CAAC;AAC7B,cAAc,cAAc,CAAC;AAC7B,cAAc,YAAY,CAAC"}
@@ -0,0 +1,8 @@
1
+ export { bg100, bg200, bg300, bgHighlight, bgModal100, bgModal200, bgRoleBlue, bgRoleGreen, bgRoleRed, bgRoleYellow, bgSecondary100, contents000, contents100, contents150, contents200, contents300, contents999, disabled, disabledRoleRed, disabledSecondary, divider, fixedBgWhite, fixedBlack, fixedWhite, primary100, primary200, roleBlue, roleGreen, roleRed, roleYellow, secondary100 } from './colors/variables.esm.js';
2
+ export { getBrowserTheme, getColorVariableName, getHexFromRuiCssVariable, getRgb, getRgba, hexToRgb } from './colors/utils.esm.js';
3
+ export { desktopOnly, getDeviceWidthMediaQuery, mobileOnly, phoneOnly } from './mediaQuery/index.esm.js';
4
+ export { PRETENDARD_FONT_FAMILY, TYPOGRAPHY_STYLES } from './typography/const.esm.js';
5
+ export { ellipsis, getTypographyStyles, textEllipsis } from './typography/utils.esm.js';
6
+ export { RUIProvider, useRUI } from './provider/index.esm.js';
7
+ export { DESKTOP_WIDTH, PHONE_WIDTH } from './mediaQuery/const.esm.js';
8
+ //# sourceMappingURL=index.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.esm.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;"}
@@ -0,0 +1,8 @@
1
+ 'use strict';
2
+
3
+ var DESKTOP_WIDTH = 768;
4
+ var PHONE_WIDTH = 430;
5
+
6
+ exports.DESKTOP_WIDTH = DESKTOP_WIDTH;
7
+ exports.PHONE_WIDTH = PHONE_WIDTH;
8
+ //# sourceMappingURL=const.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"const.cjs.js","sources":["../../../../src/mediaQuery/const.ts"],"sourcesContent":["export const DESKTOP_WIDTH = 768;\nexport const PHONE_WIDTH = 430;\n"],"names":["DESKTOP_WIDTH","PHONE_WIDTH"],"mappings":";;AAAO,IAAMA,aAAa,GAAG,IAAG;AACzB,IAAMC,WAAW,GAAG;;;;;"}
@@ -0,0 +1,3 @@
1
+ export declare const DESKTOP_WIDTH = 768;
2
+ export declare const PHONE_WIDTH = 430;
3
+ //# sourceMappingURL=const.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"const.d.ts","sourceRoot":"","sources":["../../../../src/mediaQuery/const.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,aAAa,MAAM,CAAC;AACjC,eAAO,MAAM,WAAW,MAAM,CAAC"}
@@ -0,0 +1,5 @@
1
+ var DESKTOP_WIDTH = 768;
2
+ var PHONE_WIDTH = 430;
3
+
4
+ export { DESKTOP_WIDTH, PHONE_WIDTH };
5
+ //# sourceMappingURL=const.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"const.esm.js","sources":["../../../../src/mediaQuery/const.ts"],"sourcesContent":["export const DESKTOP_WIDTH = 768;\nexport const PHONE_WIDTH = 430;\n"],"names":["DESKTOP_WIDTH","PHONE_WIDTH"],"mappings":"AAAO,IAAMA,aAAa,GAAG,IAAG;AACzB,IAAMC,WAAW,GAAG;;;;"}
@@ -0,0 +1,43 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ var _taggedTemplateLiteral = require('@babel/runtime/helpers/taggedTemplateLiteral');
5
+ var styledComponents = require('styled-components');
6
+ var _const = require('./const.cjs.js');
7
+
8
+ function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
9
+
10
+ var _taggedTemplateLiteral__default = /*#__PURE__*/_interopDefault(_taggedTemplateLiteral);
11
+
12
+ var _templateObject;
13
+ function getDeviceWidthMediaQuery(_ref) {
14
+ var maxWidth = _ref.maxWidth,
15
+ minWidth = _ref.minWidth;
16
+ var mediaQueries = [];
17
+ if (maxWidth) {
18
+ mediaQueries.push("(max-width: ".concat(typeof maxWidth === 'string' ? maxWidth : "".concat(maxWidth, "px"), ")"));
19
+ }
20
+ if (minWidth) {
21
+ mediaQueries.push("(min-width: ".concat(typeof minWidth === 'string' ? minWidth : "".concat(minWidth, "px"), ")"));
22
+ }
23
+ return function (cssInterpolation) {
24
+ return styledComponents.css(_templateObject || (_templateObject = _taggedTemplateLiteral__default.default(["\n @media ", " {\n ", "\n }\n "])), mediaQueries.join(' and '), cssInterpolation);
25
+ };
26
+ }
27
+ var mobileOnly = getDeviceWidthMediaQuery({
28
+ maxWidth: _const.DESKTOP_WIDTH - 1
29
+ });
30
+ var desktopOnly = getDeviceWidthMediaQuery({
31
+ minWidth: _const.DESKTOP_WIDTH
32
+ });
33
+ var phoneOnly = getDeviceWidthMediaQuery({
34
+ maxWidth: _const.PHONE_WIDTH
35
+ });
36
+
37
+ exports.DESKTOP_WIDTH = _const.DESKTOP_WIDTH;
38
+ exports.PHONE_WIDTH = _const.PHONE_WIDTH;
39
+ exports.desktopOnly = desktopOnly;
40
+ exports.getDeviceWidthMediaQuery = getDeviceWidthMediaQuery;
41
+ exports.mobileOnly = mobileOnly;
42
+ exports.phoneOnly = phoneOnly;
43
+ //# sourceMappingURL=index.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs.js","sources":["../../../../src/mediaQuery/index.ts"],"sourcesContent":["'use client';\n\nimport { css } from 'styled-components';\nimport type { CSSProp } from 'styled-components';\n\nimport { DESKTOP_WIDTH, PHONE_WIDTH } from './const';\n\nexport * from './const';\n\nexport function getDeviceWidthMediaQuery({\n maxWidth,\n minWidth,\n}: {\n maxWidth?: number | string;\n minWidth?: number | string;\n}) {\n const mediaQueries: string[] = [];\n\n if (maxWidth) {\n mediaQueries.push(\n `(max-width: ${\n typeof maxWidth === 'string' ? maxWidth : `${maxWidth}px`\n })`\n );\n }\n\n if (minWidth) {\n mediaQueries.push(\n `(min-width: ${\n typeof minWidth === 'string' ? minWidth : `${minWidth}px`\n })`\n );\n }\n\n return (cssInterpolation: CSSProp) => css`\n @media ${mediaQueries.join(' and ')} {\n ${cssInterpolation}\n }\n `;\n}\n\nexport const mobileOnly = getDeviceWidthMediaQuery({\n maxWidth: DESKTOP_WIDTH - 1,\n});\nexport const desktopOnly = getDeviceWidthMediaQuery({\n minWidth: DESKTOP_WIDTH,\n});\nexport const phoneOnly = getDeviceWidthMediaQuery({\n maxWidth: PHONE_WIDTH,\n});\n"],"names":["mediaQueries","mobileOnly","desktopOnly","minWidth","phoneOnly","maxWidth"],"mappings":";;;;;;;;;;;AAAa;AASN;AAMJ;;;AAGD;AACEA;AAKF;AAEA;AACEA;AAKF;AAEA;AAAiC;;AAKnC;AAEaC;;AAEb;AACaC;AACXC;AACF;AACaC;AACXC;AACF;;;;;;;"}
@@ -0,0 +1,10 @@
1
+ import type { CSSProp } from 'styled-components';
2
+ export * from './const';
3
+ export declare function getDeviceWidthMediaQuery({ maxWidth, minWidth, }: {
4
+ maxWidth?: number | string;
5
+ minWidth?: number | string;
6
+ }): (cssInterpolation: CSSProp) => import("styled-components").RuleSet<object>;
7
+ export declare const mobileOnly: (cssInterpolation: CSSProp) => import("styled-components").RuleSet<object>;
8
+ export declare const desktopOnly: (cssInterpolation: CSSProp) => import("styled-components").RuleSet<object>;
9
+ export declare const phoneOnly: (cssInterpolation: CSSProp) => import("styled-components").RuleSet<object>;
10
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/mediaQuery/index.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAIjD,cAAc,SAAS,CAAC;AAExB,wBAAgB,wBAAwB,CAAC,EACvC,QAAQ,EACR,QAAQ,GACT,EAAE;IACD,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAC3B,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;CAC5B,sBAmB2B,OAAO,iDAKlC;AAED,eAAO,MAAM,UAAU,qBAPK,OAAO,gDASjC,CAAC;AACH,eAAO,MAAM,WAAW,qBAVI,OAAO,gDAYjC,CAAC;AACH,eAAO,MAAM,SAAS,qBAbM,OAAO,gDAejC,CAAC"}
@@ -0,0 +1,32 @@
1
+ "use client";
2
+ import _taggedTemplateLiteral from '@babel/runtime/helpers/taggedTemplateLiteral';
3
+ import { css } from 'styled-components';
4
+ import { DESKTOP_WIDTH, PHONE_WIDTH } from './const.esm.js';
5
+
6
+ var _templateObject;
7
+ function getDeviceWidthMediaQuery(_ref) {
8
+ var maxWidth = _ref.maxWidth,
9
+ minWidth = _ref.minWidth;
10
+ var mediaQueries = [];
11
+ if (maxWidth) {
12
+ mediaQueries.push("(max-width: ".concat(typeof maxWidth === 'string' ? maxWidth : "".concat(maxWidth, "px"), ")"));
13
+ }
14
+ if (minWidth) {
15
+ mediaQueries.push("(min-width: ".concat(typeof minWidth === 'string' ? minWidth : "".concat(minWidth, "px"), ")"));
16
+ }
17
+ return function (cssInterpolation) {
18
+ return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n @media ", " {\n ", "\n }\n "])), mediaQueries.join(' and '), cssInterpolation);
19
+ };
20
+ }
21
+ var mobileOnly = getDeviceWidthMediaQuery({
22
+ maxWidth: DESKTOP_WIDTH - 1
23
+ });
24
+ var desktopOnly = getDeviceWidthMediaQuery({
25
+ minWidth: DESKTOP_WIDTH
26
+ });
27
+ var phoneOnly = getDeviceWidthMediaQuery({
28
+ maxWidth: PHONE_WIDTH
29
+ });
30
+
31
+ export { DESKTOP_WIDTH, PHONE_WIDTH, desktopOnly, getDeviceWidthMediaQuery, mobileOnly, phoneOnly };
32
+ //# sourceMappingURL=index.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.esm.js","sources":["../../../../src/mediaQuery/index.ts"],"sourcesContent":["'use client';\n\nimport { css } from 'styled-components';\nimport type { CSSProp } from 'styled-components';\n\nimport { DESKTOP_WIDTH, PHONE_WIDTH } from './const';\n\nexport * from './const';\n\nexport function getDeviceWidthMediaQuery({\n maxWidth,\n minWidth,\n}: {\n maxWidth?: number | string;\n minWidth?: number | string;\n}) {\n const mediaQueries: string[] = [];\n\n if (maxWidth) {\n mediaQueries.push(\n `(max-width: ${\n typeof maxWidth === 'string' ? maxWidth : `${maxWidth}px`\n })`\n );\n }\n\n if (minWidth) {\n mediaQueries.push(\n `(min-width: ${\n typeof minWidth === 'string' ? minWidth : `${minWidth}px`\n })`\n );\n }\n\n return (cssInterpolation: CSSProp) => css`\n @media ${mediaQueries.join(' and ')} {\n ${cssInterpolation}\n }\n `;\n}\n\nexport const mobileOnly = getDeviceWidthMediaQuery({\n maxWidth: DESKTOP_WIDTH - 1,\n});\nexport const desktopOnly = getDeviceWidthMediaQuery({\n minWidth: DESKTOP_WIDTH,\n});\nexport const phoneOnly = getDeviceWidthMediaQuery({\n maxWidth: PHONE_WIDTH,\n});\n"],"names":["mediaQueries","mobileOnly","desktopOnly","minWidth","phoneOnly","maxWidth"],"mappings":";;;;;AAAa;AASN;AAMJ;;;AAGD;AACEA;AAKF;AAEA;AACEA;AAKF;AAEA;AAAiC;;AAKnC;AAEaC;;AAEb;AACaC;AACXC;AACF;AACaC;AACXC;AACF;;"}
@@ -0,0 +1,43 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ var react = require('react');
5
+ var utils = require('../colors/utils.cjs.js');
6
+ var styles = require('./styles.cjs.js');
7
+ var jsxRuntime = require('react/jsx-runtime');
8
+
9
+ var RUIContext = /*#__PURE__*/react.createContext(null);
10
+
11
+ /** theme과 setTheme은 사용하는 곳에서 주입,
12
+ * 기본적으로는 브라우저의 미디어쿼리를 통해서 light, dark를 결정 */
13
+ function RUIProvider(_ref) {
14
+ var children = _ref.children,
15
+ customMixins = _ref.customMixins,
16
+ forceTheme = _ref.forceTheme,
17
+ setTheme = _ref.setTheme;
18
+ var currentTheme = forceTheme !== null && forceTheme !== void 0 ? forceTheme : utils.getBrowserTheme();
19
+ var ruiContextValue = react.useMemo(function () {
20
+ return {
21
+ currentTheme: currentTheme,
22
+ setTheme: setTheme
23
+ };
24
+ }, [currentTheme, setTheme]);
25
+ return /*#__PURE__*/jsxRuntime.jsxs(RUIContext.Provider, {
26
+ value: ruiContextValue,
27
+ children: [/*#__PURE__*/jsxRuntime.jsx(styles.RUIGlobalStyle, {
28
+ customMixins: customMixins,
29
+ forceTheme: forceTheme
30
+ }), children]
31
+ });
32
+ }
33
+ function useRUI() {
34
+ var ruiContextValue = react.useContext(RUIContext);
35
+ if (ruiContextValue === null) {
36
+ throw new Error('useRUI must be used within RUIProvider!');
37
+ }
38
+ return ruiContextValue;
39
+ }
40
+
41
+ exports.RUIProvider = RUIProvider;
42
+ exports.useRUI = useRUI;
43
+ //# sourceMappingURL=index.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.cjs.js","sources":["../../../../src/provider/index.tsx"],"sourcesContent":["'use client';\n\nimport type { ReactNode } from 'react';\nimport { createContext, useContext, useMemo } from 'react';\n\nimport type { ColorThemeType, ThemeType } from '@/colors';\nimport { getBrowserTheme } from '@/colors';\n\nimport { RUIGlobalStyle } from './styles';\n\nexport interface RUIContentProps {\n customMixins?: ColorThemeType;\n forceTheme?: ThemeType;\n setTheme?: (theme: ThemeType) => void;\n}\n\nexport interface RUIContextValue {\n currentTheme: ThemeType;\n setTheme: RUIContentProps['setTheme'];\n}\n\nconst RUIContext = createContext<RUIContextValue | null>(null);\n\n/** theme과 setTheme은 사용하는 곳에서 주입,\n * 기본적으로는 브라우저의 미디어쿼리를 통해서 light, dark를 결정 */\nexport function RUIProvider({\n children,\n customMixins,\n forceTheme,\n setTheme,\n}: { children: ReactNode } & RUIContentProps) {\n const currentTheme: ThemeType = forceTheme ?? getBrowserTheme();\n const ruiContextValue: RUIContextValue = useMemo(\n () => ({ currentTheme, setTheme }),\n [currentTheme, setTheme]\n );\n\n return (\n <RUIContext.Provider value={ruiContextValue}>\n <RUIGlobalStyle customMixins={customMixins} forceTheme={forceTheme} />\n {children}\n </RUIContext.Provider>\n );\n}\n\nexport function useRUI() {\n const ruiContextValue = useContext(RUIContext);\n\n if (ruiContextValue === null) {\n throw new Error('useRUI must be used within RUIProvider!');\n }\n\n return ruiContextValue;\n}\n"],"names":["currentTheme","setTheme","value","customMixins","forceTheme"],"mappings":";;;;;;;;AAqBA;;AAEA;AACA;AACO;AAKuC;;;;;;;AAGjCA;AAAcC;;AAAU;AAInC;AACuBC;;AACHC;AAA4BC;;AACnC;AAGf;AAEO;AACL;;AAGE;AACF;AAEA;AACF;;;"}
@@ -0,0 +1,18 @@
1
+ import type { ReactNode } from 'react';
2
+ import type { ColorThemeType, ThemeType } from '../colors';
3
+ export interface RUIContentProps {
4
+ customMixins?: ColorThemeType;
5
+ forceTheme?: ThemeType;
6
+ setTheme?: (theme: ThemeType) => void;
7
+ }
8
+ export interface RUIContextValue {
9
+ currentTheme: ThemeType;
10
+ setTheme: RUIContentProps['setTheme'];
11
+ }
12
+ /** theme과 setTheme은 사용하는 곳에서 주입,
13
+ * 기본적으로는 브라우저의 미디어쿼리를 통해서 light, dark를 결정 */
14
+ export declare function RUIProvider({ children, customMixins, forceTheme, setTheme, }: {
15
+ children: ReactNode;
16
+ } & RUIContentProps): import("react/jsx-runtime").JSX.Element;
17
+ export declare function useRUI(): RUIContextValue;
18
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/provider/index.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAGvC,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,UAAU,CAAC;AAK1D,MAAM,WAAW,eAAe;IAC9B,YAAY,CAAC,EAAE,cAAc,CAAC;IAC9B,UAAU,CAAC,EAAE,SAAS,CAAC;IACvB,QAAQ,CAAC,EAAE,CAAC,KAAK,EAAE,SAAS,KAAK,IAAI,CAAC;CACvC;AAED,MAAM,WAAW,eAAe;IAC9B,YAAY,EAAE,SAAS,CAAC;IACxB,QAAQ,EAAE,eAAe,CAAC,UAAU,CAAC,CAAC;CACvC;AAID;6CAC6C;AAC7C,wBAAgB,WAAW,CAAC,EAC1B,QAAQ,EACR,YAAY,EACZ,UAAU,EACV,QAAQ,GACT,EAAE;IAAE,QAAQ,EAAE,SAAS,CAAA;CAAE,GAAG,eAAe,2CAa3C;AAED,wBAAgB,MAAM,oBAQrB"}
@@ -0,0 +1,40 @@
1
+ "use client";
2
+ import { useMemo, useContext, createContext } from 'react';
3
+ import { getBrowserTheme } from '../colors/utils.esm.js';
4
+ import { RUIGlobalStyle } from './styles.esm.js';
5
+ import { jsxs, jsx } from 'react/jsx-runtime';
6
+
7
+ var RUIContext = /*#__PURE__*/createContext(null);
8
+
9
+ /** theme과 setTheme은 사용하는 곳에서 주입,
10
+ * 기본적으로는 브라우저의 미디어쿼리를 통해서 light, dark를 결정 */
11
+ function RUIProvider(_ref) {
12
+ var children = _ref.children,
13
+ customMixins = _ref.customMixins,
14
+ forceTheme = _ref.forceTheme,
15
+ setTheme = _ref.setTheme;
16
+ var currentTheme = forceTheme !== null && forceTheme !== void 0 ? forceTheme : getBrowserTheme();
17
+ var ruiContextValue = useMemo(function () {
18
+ return {
19
+ currentTheme: currentTheme,
20
+ setTheme: setTheme
21
+ };
22
+ }, [currentTheme, setTheme]);
23
+ return /*#__PURE__*/jsxs(RUIContext.Provider, {
24
+ value: ruiContextValue,
25
+ children: [/*#__PURE__*/jsx(RUIGlobalStyle, {
26
+ customMixins: customMixins,
27
+ forceTheme: forceTheme
28
+ }), children]
29
+ });
30
+ }
31
+ function useRUI() {
32
+ var ruiContextValue = useContext(RUIContext);
33
+ if (ruiContextValue === null) {
34
+ throw new Error('useRUI must be used within RUIProvider!');
35
+ }
36
+ return ruiContextValue;
37
+ }
38
+
39
+ export { RUIProvider, useRUI };
40
+ //# sourceMappingURL=index.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.esm.js","sources":["../../../../src/provider/index.tsx"],"sourcesContent":["'use client';\n\nimport type { ReactNode } from 'react';\nimport { createContext, useContext, useMemo } from 'react';\n\nimport type { ColorThemeType, ThemeType } from '@/colors';\nimport { getBrowserTheme } from '@/colors';\n\nimport { RUIGlobalStyle } from './styles';\n\nexport interface RUIContentProps {\n customMixins?: ColorThemeType;\n forceTheme?: ThemeType;\n setTheme?: (theme: ThemeType) => void;\n}\n\nexport interface RUIContextValue {\n currentTheme: ThemeType;\n setTheme: RUIContentProps['setTheme'];\n}\n\nconst RUIContext = createContext<RUIContextValue | null>(null);\n\n/** theme과 setTheme은 사용하는 곳에서 주입,\n * 기본적으로는 브라우저의 미디어쿼리를 통해서 light, dark를 결정 */\nexport function RUIProvider({\n children,\n customMixins,\n forceTheme,\n setTheme,\n}: { children: ReactNode } & RUIContentProps) {\n const currentTheme: ThemeType = forceTheme ?? getBrowserTheme();\n const ruiContextValue: RUIContextValue = useMemo(\n () => ({ currentTheme, setTheme }),\n [currentTheme, setTheme]\n );\n\n return (\n <RUIContext.Provider value={ruiContextValue}>\n <RUIGlobalStyle customMixins={customMixins} forceTheme={forceTheme} />\n {children}\n </RUIContext.Provider>\n );\n}\n\nexport function useRUI() {\n const ruiContextValue = useContext(RUIContext);\n\n if (ruiContextValue === null) {\n throw new Error('useRUI must be used within RUIProvider!');\n }\n\n return ruiContextValue;\n}\n"],"names":["currentTheme","setTheme","value","customMixins","forceTheme"],"mappings":";;;;;;AAqBA;;AAEA;AACA;AACO;AAKuC;;;;;;;AAGjCA;AAAcC;;AAAU;AAInC;AACuBC;;AACHC;AAA4BC;;AACnC;AAGf;AAEO;AACL;;AAGE;AACF;AAEA;AACF;;"}
@@ -0,0 +1,43 @@
1
+ "use client";
2
+ 'use strict';
3
+
4
+ var _slicedToArray = require('@babel/runtime/helpers/slicedToArray');
5
+ var _defineProperty = require('@babel/runtime/helpers/defineProperty');
6
+ var _taggedTemplateLiteral = require('@babel/runtime/helpers/taggedTemplateLiteral');
7
+ var styledComponents = require('styled-components');
8
+ var theme = require('../colors/theme.cjs.js');
9
+ var utils = require('../colors/utils.cjs.js');
10
+
11
+ function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
12
+
13
+ var _slicedToArray__default = /*#__PURE__*/_interopDefault(_slicedToArray);
14
+ var _defineProperty__default = /*#__PURE__*/_interopDefault(_defineProperty);
15
+ var _taggedTemplateLiteral__default = /*#__PURE__*/_interopDefault(_taggedTemplateLiteral);
16
+
17
+ var _templateObject;
18
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
19
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty__default.default(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
20
+ var RUIGlobalStyle = styledComponents.createGlobalStyle(function (_ref) {
21
+ var customMixins = _ref.customMixins,
22
+ forceTheme = _ref.forceTheme;
23
+ return styledComponents.css(_templateObject || (_templateObject = _taggedTemplateLiteral__default.default(["\n :root {\n ", ";\n\n @media (prefers-color-scheme: dark) {\n ", "\n }\n }\n "])), getThemeCssFragment({
24
+ theme: forceTheme || 'light',
25
+ customMixins: customMixins
26
+ }), getThemeCssFragment({
27
+ theme: forceTheme || 'dark',
28
+ customMixins: customMixins
29
+ }));
30
+ });
31
+ function getThemeCssFragment(_ref2) {
32
+ var theme$1 = _ref2.theme,
33
+ customMixins = _ref2.customMixins;
34
+ return Object.entries(_objectSpread(_objectSpread({}, theme.RUI_COLOR_THEME[theme$1]), customMixins === null || customMixins === void 0 ? void 0 : customMixins[theme$1])).map(function (_ref3) {
35
+ var _ref4 = _slicedToArray__default.default(_ref3, 2),
36
+ key = _ref4[0],
37
+ value = _ref4[1];
38
+ return "".concat(key, ": ").concat(value, "; ").concat(key, "__rgb: ").concat(utils.hexToRgb(value), ";");
39
+ });
40
+ }
41
+
42
+ exports.RUIGlobalStyle = RUIGlobalStyle;
43
+ //# sourceMappingURL=styles.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.cjs.js","sources":["../../../../src/provider/styles.ts"],"sourcesContent":["'use client';\n\nimport { createGlobalStyle, css } from 'styled-components';\n\nimport { RUI_COLOR_THEME } from '@/colors/theme';\nimport { hexToRgb, type ColorThemeType, type ThemeType } from '@/colors';\n\nexport const RUIGlobalStyle = createGlobalStyle<{\n customMixins?: ColorThemeType;\n forceTheme?: ThemeType;\n}>(\n ({ customMixins, forceTheme }) => css`\n :root {\n ${getThemeCssFragment({ theme: forceTheme || 'light', customMixins })};\n\n @media (prefers-color-scheme: dark) {\n ${getThemeCssFragment({ theme: forceTheme || 'dark', customMixins })}\n }\n }\n `\n);\n\nfunction getThemeCssFragment({\n theme,\n customMixins,\n}: {\n theme: ThemeType;\n customMixins?: ColorThemeType;\n}) {\n return Object.entries({\n ...RUI_COLOR_THEME[theme],\n ...customMixins?.[theme],\n }).map(\n ([key, value]) => `${key}: ${value}; ${key}__rgb: ${hexToRgb(value)};`\n );\n}\n"],"names":["customMixins","key","value"],"mappings":";;;;;;;;;;;;;;;;AAAa;AAAA;AAAA;;AAWX;;;;AAE0DA;;;AAGCA;AAAa;AAAE;AAM5E;AAMG;;;AAKC;AAAEC;AAAKC;AAAK;AAAuD;AAEvE;;"}
@@ -0,0 +1,7 @@
1
+ /// <reference types="react" />
2
+ import { type ColorThemeType, type ThemeType } from '../colors';
3
+ export declare const RUIGlobalStyle: import("react").NamedExoticComponent<import("styled-components").ExecutionProps & {
4
+ customMixins?: ColorThemeType | undefined;
5
+ forceTheme?: ThemeType | undefined;
6
+ }>;
7
+ //# sourceMappingURL=styles.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.d.ts","sourceRoot":"","sources":["../../../../src/provider/styles.ts"],"names":[],"mappings":";AAKA,OAAO,EAAY,KAAK,cAAc,EAAE,KAAK,SAAS,EAAE,MAAM,UAAU,CAAC;AAEzE,eAAO,MAAM,cAAc;;;EAa1B,CAAC"}
@@ -0,0 +1,35 @@
1
+ "use client";
2
+ import _slicedToArray from '@babel/runtime/helpers/slicedToArray';
3
+ import _defineProperty from '@babel/runtime/helpers/defineProperty';
4
+ import _taggedTemplateLiteral from '@babel/runtime/helpers/taggedTemplateLiteral';
5
+ import { createGlobalStyle, css } from 'styled-components';
6
+ import { RUI_COLOR_THEME } from '../colors/theme.esm.js';
7
+ import { hexToRgb } from '../colors/utils.esm.js';
8
+
9
+ var _templateObject;
10
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
11
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
12
+ var RUIGlobalStyle = createGlobalStyle(function (_ref) {
13
+ var customMixins = _ref.customMixins,
14
+ forceTheme = _ref.forceTheme;
15
+ return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n :root {\n ", ";\n\n @media (prefers-color-scheme: dark) {\n ", "\n }\n }\n "])), getThemeCssFragment({
16
+ theme: forceTheme || 'light',
17
+ customMixins: customMixins
18
+ }), getThemeCssFragment({
19
+ theme: forceTheme || 'dark',
20
+ customMixins: customMixins
21
+ }));
22
+ });
23
+ function getThemeCssFragment(_ref2) {
24
+ var theme = _ref2.theme,
25
+ customMixins = _ref2.customMixins;
26
+ return Object.entries(_objectSpread(_objectSpread({}, RUI_COLOR_THEME[theme]), customMixins === null || customMixins === void 0 ? void 0 : customMixins[theme])).map(function (_ref3) {
27
+ var _ref4 = _slicedToArray(_ref3, 2),
28
+ key = _ref4[0],
29
+ value = _ref4[1];
30
+ return "".concat(key, ": ").concat(value, "; ").concat(key, "__rgb: ").concat(hexToRgb(value), ";");
31
+ });
32
+ }
33
+
34
+ export { RUIGlobalStyle };
35
+ //# sourceMappingURL=styles.esm.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"styles.esm.js","sources":["../../../../src/provider/styles.ts"],"sourcesContent":["'use client';\n\nimport { createGlobalStyle, css } from 'styled-components';\n\nimport { RUI_COLOR_THEME } from '@/colors/theme';\nimport { hexToRgb, type ColorThemeType, type ThemeType } from '@/colors';\n\nexport const RUIGlobalStyle = createGlobalStyle<{\n customMixins?: ColorThemeType;\n forceTheme?: ThemeType;\n}>(\n ({ customMixins, forceTheme }) => css`\n :root {\n ${getThemeCssFragment({ theme: forceTheme || 'light', customMixins })};\n\n @media (prefers-color-scheme: dark) {\n ${getThemeCssFragment({ theme: forceTheme || 'dark', customMixins })}\n }\n }\n `\n);\n\nfunction getThemeCssFragment({\n theme,\n customMixins,\n}: {\n theme: ThemeType;\n customMixins?: ColorThemeType;\n}) {\n return Object.entries({\n ...RUI_COLOR_THEME[theme],\n ...customMixins?.[theme],\n }).map(\n ([key, value]) => `${key}: ${value}; ${key}__rgb: ${hexToRgb(value)};`\n );\n}\n"],"names":["customMixins","key","value"],"mappings":";;;;;;;;AAAa;AAAA;AAAA;;AAWX;;;;AAE0DA;;;AAGCA;AAAa;AAAE;AAM5E;AAMG;;;AAKC;AAAEC;AAAKC;AAAK;AAAuD;AAEvE;;"}
@@ -0,0 +1,120 @@
1
+ 'use strict';
2
+
3
+ var _defineProperty = require('@babel/runtime/helpers/defineProperty');
4
+
5
+ function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }
6
+
7
+ var _defineProperty__default = /*#__PURE__*/_interopDefault(_defineProperty);
8
+
9
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
10
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty__default.default(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
11
+ /* eslint-disable @typescript-eslint/naming-convention */
12
+
13
+ var LEGACY_TYPOGRAPHY_STYLES = {
14
+ Headline2_B: {
15
+ fontSize: 24,
16
+ lineHeight: 34,
17
+ fontWeight: 600
18
+ },
19
+ Headline3_B: {
20
+ fontSize: 20,
21
+ lineHeight: 26,
22
+ fontWeight: 600
23
+ },
24
+ Headline4_B: {
25
+ fontSize: 16,
26
+ lineHeight: 26,
27
+ fontWeight: 600
28
+ },
29
+ Headline4_M: {
30
+ fontSize: 16,
31
+ lineHeight: 26,
32
+ fontWeight: 400
33
+ },
34
+ Body1_B: {
35
+ fontSize: 14,
36
+ lineHeight: 24,
37
+ fontWeight: 600
38
+ },
39
+ Body1_M: {
40
+ fontSize: 14,
41
+ lineHeight: 24,
42
+ fontWeight: 400
43
+ },
44
+ Body2_B: {
45
+ fontSize: 12,
46
+ lineHeight: 19,
47
+ fontWeight: 600
48
+ },
49
+ Body2_M: {
50
+ fontSize: 12,
51
+ lineHeight: 19,
52
+ fontWeight: 400
53
+ },
54
+ Caption_B: {
55
+ fontSize: 10,
56
+ lineHeight: 14,
57
+ fontWeight: 600
58
+ }
59
+ };
60
+ var TYPOGRAPHY_STYLES = _objectSpread(_objectSpread({}, LEGACY_TYPOGRAPHY_STYLES), {}, {
61
+ Headline: {
62
+ fontSize: 24,
63
+ lineHeight: 34,
64
+ fontWeight: 600
65
+ },
66
+ Title1: {
67
+ fontSize: 20,
68
+ lineHeight: 26,
69
+ fontWeight: 600
70
+ },
71
+ Display: {
72
+ fontSize: 20,
73
+ lineHeight: 26,
74
+ fontWeight: 400
75
+ },
76
+ Title2: {
77
+ fontSize: 16,
78
+ lineHeight: 26,
79
+ fontWeight: 600
80
+ },
81
+ ArticleBody: {
82
+ fontSize: 16,
83
+ lineHeight: 26,
84
+ fontWeight: 400
85
+ },
86
+ Subtitle1: {
87
+ fontSize: 14,
88
+ lineHeight: 24,
89
+ fontWeight: 600
90
+ },
91
+ Body1: {
92
+ fontSize: 14,
93
+ lineHeight: 24,
94
+ fontWeight: 400
95
+ },
96
+ Subtitle2: {
97
+ fontSize: 12,
98
+ lineHeight: 19,
99
+ fontWeight: 600
100
+ },
101
+ Body2: {
102
+ fontSize: 12,
103
+ lineHeight: 19,
104
+ fontWeight: 400
105
+ },
106
+ Caption: {
107
+ fontSize: 10,
108
+ lineHeight: 14,
109
+ fontWeight: 600
110
+ }
111
+ });
112
+
113
+ /**
114
+ * {@link https://github.com/orioncactus/pretendard#html-1}
115
+ */
116
+ var PRETENDARD_FONT_FAMILY = "Pretendard, -apple-system, BlinkMacSystemFont, system-ui, Roboto, 'Helvetica Neue', 'Segoe UI', 'Apple SD Gothic Neo', 'Noto Sans KR', 'Malgun Gothic', 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', sans-serif";
117
+
118
+ exports.PRETENDARD_FONT_FAMILY = PRETENDARD_FONT_FAMILY;
119
+ exports.TYPOGRAPHY_STYLES = TYPOGRAPHY_STYLES;
120
+ //# sourceMappingURL=const.cjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"const.cjs.js","sources":["../../../../src/typography/const.ts"],"sourcesContent":["/* eslint-disable @typescript-eslint/naming-convention */\n\nconst LEGACY_TYPOGRAPHY_STYLES = {\n Headline2_B: {\n fontSize: 24,\n lineHeight: 34,\n fontWeight: 600,\n },\n Headline3_B: {\n fontSize: 20,\n lineHeight: 26,\n fontWeight: 600,\n },\n Headline4_B: {\n fontSize: 16,\n lineHeight: 26,\n fontWeight: 600,\n },\n Headline4_M: {\n fontSize: 16,\n lineHeight: 26,\n fontWeight: 400,\n },\n Body1_B: {\n fontSize: 14,\n lineHeight: 24,\n fontWeight: 600,\n },\n Body1_M: {\n fontSize: 14,\n lineHeight: 24,\n fontWeight: 400,\n },\n Body2_B: {\n fontSize: 12,\n lineHeight: 19,\n fontWeight: 600,\n },\n Body2_M: {\n fontSize: 12,\n lineHeight: 19,\n fontWeight: 400,\n },\n Caption_B: {\n fontSize: 10,\n lineHeight: 14,\n fontWeight: 600,\n },\n} as const;\n\nexport const TYPOGRAPHY_STYLES = {\n ...LEGACY_TYPOGRAPHY_STYLES,\n Headline: {\n fontSize: 24,\n lineHeight: 34,\n fontWeight: 600,\n },\n Title1: {\n fontSize: 20,\n lineHeight: 26,\n fontWeight: 600,\n },\n Display: {\n fontSize: 20,\n lineHeight: 26,\n fontWeight: 400,\n },\n Title2: {\n fontSize: 16,\n lineHeight: 26,\n fontWeight: 600,\n },\n ArticleBody: {\n fontSize: 16,\n lineHeight: 26,\n fontWeight: 400,\n },\n Subtitle1: {\n fontSize: 14,\n lineHeight: 24,\n fontWeight: 600,\n },\n Body1: {\n fontSize: 14,\n lineHeight: 24,\n fontWeight: 400,\n },\n Subtitle2: {\n fontSize: 12,\n lineHeight: 19,\n fontWeight: 600,\n },\n Body2: {\n fontSize: 12,\n lineHeight: 19,\n fontWeight: 400,\n },\n Caption: {\n fontSize: 10,\n lineHeight: 14,\n fontWeight: 600,\n },\n} as const;\n\n/**\n * {@link https://github.com/orioncactus/pretendard#html-1}\n */\nexport const PRETENDARD_FONT_FAMILY =\n \"Pretendard, -apple-system, BlinkMacSystemFont, system-ui, Roboto, 'Helvetica Neue', 'Segoe UI', 'Apple SD Gothic Neo', 'Noto Sans KR', 'Malgun Gothic', 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol', sans-serif\";\n"],"names":["LEGACY_TYPOGRAPHY_STYLES","Headline2_B","fontSize","lineHeight","fontWeight","Headline3_B","Headline4_B","Headline4_M","Body1_B","Body1_M","Body2_B","Body2_M","Caption_B","TYPOGRAPHY_STYLES","_objectSpread","Headline","Title1","Display","Title2","ArticleBody","Subtitle1","Body1","Subtitle2","Body2","Caption","PRETENDARD_FONT_FAMILY"],"mappings":"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"}