acinguiux-ds-react-framework 0.1.6 → 0.1.8
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/build/cjs/react-base/src/theme/typography.js +1 -1
- package/build/cjs/react-base/src/theme/typography.js.map +1 -1
- package/build/esm/react-base/src/theme/typography.d.ts.map +1 -1
- package/build/esm/react-base/src/theme/typography.js +68 -10
- package/build/esm/react-base/src/theme/typography.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const l=require("acinguiux-ds-fabrics"),o=require("./types/typography.js"),i=a=>({...a,fontWeight:`${a.fontWeight??"normal"}`,fontSize:`${a.fontSize??0}px`,lineHeight:`${a.lineHeight??0}px`,paragraphSpacing:`${a.paragraphSpacing??0}px`,letterSpacing:`${a.letterSpacing??0}px`}),g=()=>({display:{extraSmall:{fontFamily:"Arial, sans-serif",fontWeight:600,fontSize:32,fontStyle:"normal",letterSpacing:0,lineHeight:40,paragraphSpacing:48},large:{fontFamily:"Arial, sans-serif",fontWeight:600,fontSize:56,fontStyle:"normal",letterSpacing:0,lineHeight:68,paragraphSpacing:84},medium:{fontFamily:"Arial, sans-serif",fontWeight:600,fontSize:48,fontStyle:"normal",letterSpacing:0,lineHeight:56,paragraphSpacing:72},small:{fontFamily:"Arial, sans-serif",fontWeight:600,fontSize:40,fontStyle:"normal",letterSpacing:0,lineHeight:48,paragraphSpacing:60}},heading:{extraLarge:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:40,fontStyle:"normal",letterSpacing:0,lineHeight:48,paragraphSpacing:60},extraSmall:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:24},large:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:32,fontStyle:"normal",letterSpacing:0,lineHeight:40,paragraphSpacing:48},medium:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:24,fontStyle:"normal",letterSpacing:0,lineHeight:28,paragraphSpacing:36},small:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:20,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:32},smallest:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:20}},label:{regular:{extraSmall:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16},large:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:20},medium:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},small:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:16},smallest:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:10,fontStyle:"normal",letterSpacing:0,lineHeight:12,paragraphSpacing:12}},strong:{extraSmall:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16},large:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:20},medium:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},small:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:16},smallest:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:10,fontStyle:"normal",letterSpacing:0,lineHeight:12,paragraphSpacing:12}}},paragraph:{regular:{extraLarge:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:20,fontStyle:"normal",letterSpacing:0,lineHeight:28,paragraphSpacing:32},large:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:28},medium:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:24},small:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},smallest:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16}},strong:{extraLarge:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:20,fontStyle:"normal",letterSpacing:0,lineHeight:28,paragraphSpacing:32},large:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:28},medium:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:24},small:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},smallest:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16}}}}),t=l.Typography||g(),f=(a,n="medium",e="regular")=>{if(!t||!t[a])return console.warn(`Typography object or kind "${a}" not available during SSR - using fallback values`),{fontFamily:"Arial, sans-serif",fontStyle:"normal",fontWeight:"normal",fontSize:"16px",lineHeight:"24px",paragraphSpacing:"0px",letterSpacing:"0px"};try{return o.isTypographyWeighted(a)?t[a][e]?i(t[a][e][n]):(console.warn(`Typography weight "${e}" not available for kind "${a}" - using fallback`),{fontFamily:"Arial, sans-serif",fontStyle:"normal",fontWeight:"normal",fontSize:"16px",lineHeight:"24px",paragraphSpacing:"0px",letterSpacing:"0px"}):i(t[a][n])}catch(r){return console.warn(`Error accessing typography values for kind "${a}", size "${n}", weight "${e}" - using fallback`,r),{fontFamily:"Arial, sans-serif",fontStyle:"normal",fontWeight:"normal",fontSize:"16px",lineHeight:"24px",paragraphSpacing:"0px",letterSpacing:"0px"}}};exports.typography=f;
|
|
1
|
+
"use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const g=require("./types/typography.js");let i;try{i=require("acinguiux-ds-fabrics").Typography}catch(a){console.warn("Failed to import Typography from acinguiux-ds-fabrics during SSR/build",a),i=null}const r=()=>({display:{extraSmall:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:600,fontSize:32,fontStyle:"normal",letterSpacing:0,lineHeight:40,paragraphSpacing:48},small:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:600,fontSize:40,fontStyle:"normal",letterSpacing:0,lineHeight:48,paragraphSpacing:60},medium:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:600,fontSize:48,fontStyle:"normal",letterSpacing:0,lineHeight:56,paragraphSpacing:72},large:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:600,fontSize:56,fontStyle:"normal",letterSpacing:0,lineHeight:68,paragraphSpacing:84}},heading:{smallest:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:500,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:20},extraSmall:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:500,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:24},small:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:500,fontSize:20,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:32},medium:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:500,fontSize:24,fontStyle:"normal",letterSpacing:0,lineHeight:28,paragraphSpacing:36},large:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:500,fontSize:32,fontStyle:"normal",letterSpacing:0,lineHeight:40,paragraphSpacing:48},extraLarge:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:500,fontSize:40,fontStyle:"normal",letterSpacing:0,lineHeight:48,paragraphSpacing:60}},label:{regular:{smallest:{fontFamily:"Arial",fontWeight:400,fontSize:10,fontStyle:"normal",letterSpacing:0,lineHeight:12,paragraphSpacing:12},extraSmall:{fontFamily:"Arial",fontWeight:400,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16},small:{fontFamily:"Arial",fontWeight:400,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:16},medium:{fontFamily:"Arial",fontWeight:400,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},large:{fontFamily:"Arial",fontWeight:400,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:20}},strong:{smallest:{fontFamily:"Arial",fontWeight:700,fontSize:10,fontStyle:"normal",letterSpacing:0,lineHeight:12,paragraphSpacing:12},extraSmall:{fontFamily:"Arial",fontWeight:700,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16},small:{fontFamily:"Arial",fontWeight:700,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:16},medium:{fontFamily:"Arial",fontWeight:700,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},large:{fontFamily:"Arial",fontWeight:700,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:20}}},paragraph:{regular:{extraLarge:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:400,fontSize:20,fontStyle:"normal",letterSpacing:0,lineHeight:32,paragraphSpacing:32},large:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:400,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:28,paragraphSpacing:28},medium:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:400,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:24},small:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:400,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},extraSmall:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:400,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16}},strong:{extraLarge:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:600,fontSize:20,fontStyle:"normal",letterSpacing:0,lineHeight:32,paragraphSpacing:32},large:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:600,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:28,paragraphSpacing:28},medium:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:600,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:24},small:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:600,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},extraSmall:{fontFamily:"Be Vietnam Pro, sans-serif",fontWeight:600,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16}}}}),f=(()=>{try{return i||r()}catch(a){return console.warn("Typography import failed, using fallback values",a),r()}})(),l=a=>({...a,fontWeight:`${a.fontWeight??"normal"}`,fontSize:`${a.fontSize??0}px`,lineHeight:`${a.lineHeight??0}px`,paragraphSpacing:`${a.paragraphSpacing??0}px`,letterSpacing:`${a.letterSpacing??0}px`}),p=()=>({display:{extraSmall:{fontFamily:"Arial, sans-serif",fontWeight:600,fontSize:32,fontStyle:"normal",letterSpacing:0,lineHeight:40,paragraphSpacing:48},large:{fontFamily:"Arial, sans-serif",fontWeight:600,fontSize:56,fontStyle:"normal",letterSpacing:0,lineHeight:68,paragraphSpacing:84},medium:{fontFamily:"Arial, sans-serif",fontWeight:600,fontSize:48,fontStyle:"normal",letterSpacing:0,lineHeight:56,paragraphSpacing:72},small:{fontFamily:"Arial, sans-serif",fontWeight:600,fontSize:40,fontStyle:"normal",letterSpacing:0,lineHeight:48,paragraphSpacing:60}},heading:{extraLarge:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:40,fontStyle:"normal",letterSpacing:0,lineHeight:48,paragraphSpacing:60},extraSmall:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:24},large:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:32,fontStyle:"normal",letterSpacing:0,lineHeight:40,paragraphSpacing:48},medium:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:24,fontStyle:"normal",letterSpacing:0,lineHeight:28,paragraphSpacing:36},small:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:20,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:32},smallest:{fontFamily:"Arial, sans-serif",fontWeight:500,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:20}},label:{regular:{extraSmall:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16},large:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:20},medium:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},small:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:16},smallest:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:10,fontStyle:"normal",letterSpacing:0,lineHeight:12,paragraphSpacing:12}},strong:{extraSmall:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16},large:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:20},medium:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},small:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:16},smallest:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:10,fontStyle:"normal",letterSpacing:0,lineHeight:12,paragraphSpacing:12}}},paragraph:{regular:{extraLarge:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:20,fontStyle:"normal",letterSpacing:0,lineHeight:28,paragraphSpacing:32},large:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:28},medium:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:24},small:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},smallest:{fontFamily:"Arial, sans-serif",fontWeight:400,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16}},strong:{extraLarge:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:20,fontStyle:"normal",letterSpacing:0,lineHeight:28,paragraphSpacing:32},large:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:18,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:28},medium:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:16,fontStyle:"normal",letterSpacing:0,lineHeight:24,paragraphSpacing:24},small:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:14,fontStyle:"normal",letterSpacing:0,lineHeight:20,paragraphSpacing:20},smallest:{fontFamily:"Arial, sans-serif",fontWeight:700,fontSize:12,fontStyle:"normal",letterSpacing:0,lineHeight:16,paragraphSpacing:16}}}}),t=f||p(),S=(a,n="medium",e="regular")=>{if(!t||!t[a])return console.warn(`Typography object or kind "${a}" not available during SSR - using fallback values`),{fontFamily:"Arial, sans-serif",fontStyle:"normal",fontWeight:"normal",fontSize:"16px",lineHeight:"24px",paragraphSpacing:"0px",letterSpacing:"0px"};try{return g.isTypographyWeighted(a)?t[a][e]?l(t[a][e][n]):(console.warn(`Typography weight "${e}" not available for kind "${a}" - using fallback`),{fontFamily:"Arial, sans-serif",fontStyle:"normal",fontWeight:"normal",fontSize:"16px",lineHeight:"24px",paragraphSpacing:"0px",letterSpacing:"0px"}):l(t[a][n])}catch(o){return console.warn(`Error accessing typography values for kind "${a}", size "${n}", weight "${e}" - using fallback`,o),{fontFamily:"Arial, sans-serif",fontStyle:"normal",fontWeight:"normal",fontSize:"16px",lineHeight:"24px",paragraphSpacing:"0px",letterSpacing:"0px"}}};exports.typography=S;
|
|
2
2
|
//# sourceMappingURL=typography.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typography.js","sources":["../../../../../../react-base/src/theme/typography.ts"],"sourcesContent":["import { Typography, type TypographyType } from 'acinguiux-ds-fabrics';\n\nimport {\n isTypographyWeighted,\n TypographyKind,\n TypographySize,\n TypographyWeights,\n type TypographyElement,\n type TypographyElementPx,\n type TypographyFn,\n} from './types/typography';\n\nconst transformValuesToPx = <T extends TypographyElement>(value: T): TypographyElementPx => ({\n ...value,\n fontWeight: `${value.fontWeight ?? 'normal'}`,\n fontSize: `${value.fontSize ?? 0}px`,\n lineHeight: `${value.lineHeight ?? 0}px`,\n paragraphSpacing: `${value.paragraphSpacing ?? 0}px`,\n letterSpacing: `${value.letterSpacing ?? 0}px`,\n});\n\n// Create a fallback Typography object for SSR when the actual Typography is not available\nconst createFallbackTypography = (): any => ({\n display: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 56, fontStyle: 'normal', letterSpacing: 0, lineHeight: 68, paragraphSpacing: 84 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 48, fontStyle: 'normal', letterSpacing: 0, lineHeight: 56, paragraphSpacing: 72 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 }\n },\n heading: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 },\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 24 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 24, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 36 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 32 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 20 }\n },\n label: {\n regular: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 }\n },\n strong: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 }\n }\n },\n paragraph: {\n regular: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 32 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 28 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }\n },\n strong: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 32 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 28 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }\n }\n }\n});\n\n// Ensure we have a safe Typography object to work with\nconst safeTypography = Typography || createFallbackTypography();\n\n/**\n * typography() is a function that returns a typography element with the specified values.\n *\n * @param kind the typography content type ('label', 'paragraph', 'heading' or 'display')\n * @param size the size of the typography content ('extraSmall', 'small', 'medium', 'large', 'extraLarge' or 'smallest')\n * @param weight the weight of the typography content ('regular' or 'strong')\n * @returns the typography element with the specified values\n *\n * @defaults typography('paragraph', 'medium', 'regular')\n */\nexport const typography: TypographyFn = <\n Kind extends TypographyKind,\n Size extends TypographySize<Kind>,\n Weight extends TypographyWeights<Kind>,\n>(\n kind: Kind,\n size = 'medium' as Size,\n weight = 'regular' as Weight,\n) => {\n // SSR-safe check for Typography object\n if (!safeTypography || !safeTypography[kind]) {\n console.warn(`Typography object or kind \"${kind}\" not available during SSR - using fallback values`);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n\n try {\n if (isTypographyWeighted(kind)) {\n // Additional safety check for weight\n if (!safeTypography[kind][weight]) {\n console.warn(`Typography weight \"${weight}\" not available for kind \"${kind}\" - using fallback`);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n return transformValuesToPx(safeTypography[kind][weight][size as keyof TypographyType[Kind][Weight]] as TypographyElement);\n } else {\n return transformValuesToPx(safeTypography[kind][size as keyof TypographyType[typeof kind]] as TypographyElement);\n }\n } catch (error) {\n console.warn(`Error accessing typography values for kind \"${kind}\", size \"${size}\", weight \"${weight}\" - using fallback`, error);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n};\n"],"names":["transformValuesToPx","value","createFallbackTypography","safeTypography","Typography","typography","kind","size","weight","isTypographyWeighted","error"],"mappings":"uLAYMA,EAAoDC,IAAmC,CAC3F,GAAGA,EACH,WAAY,GAAGA,EAAM,YAAc,QAAQ,GAC3C,SAAU,GAAGA,EAAM,UAAY,CAAC,KAChC,WAAY,GAAGA,EAAM,YAAc,CAAC,KACpC,iBAAkB,GAAGA,EAAM,kBAAoB,CAAC,KAChD,cAAe,GAAGA,EAAM,eAAiB,CAAC,IAC5C,GAGMC,EAA2B,KAAY,CAC3C,QAAS,CACP,WAAY,CAAE,WAAY,oBAAqB,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,EACvJ,MAAO,CAAE,WAAY,oBAAqB,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,EAClJ,OAAQ,CAAE,WAAY,oBAAqB,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI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AyC,CAAsB,CAEnH,OAASG,EAAO,CACd,eAAQ,KAAK,+CAA+CJ,CAAI,YAAYC,CAAI,cAAcC,CAAM,qBAAsBE,CAAK,EACxH,CACL,WAAY,oBACZ,UAAW,SACX,WAAY,SACZ,SAAU,OACV,WAAY,OACZ,iBAAkB,MAClB,cAAe,KAAA,CAEnB,CACF"}
|
|
1
|
+
{"version":3,"file":"typography.js","sources":["../../../../../../react-base/src/theme/typography.ts"],"sourcesContent":["// Import Typography with SSR-safe fallback handling\nlet OriginalTypography: any;\ntry {\n const fabricsModule = require('acinguiux-ds-fabrics');\n OriginalTypography = fabricsModule.Typography;\n} catch (error) {\n console.warn('Failed to import Typography from acinguiux-ds-fabrics during SSR/build', error);\n OriginalTypography = null;\n}\n\nimport type { TypographyType } from 'acinguiux-ds-fabrics';\n\nimport {\n isTypographyWeighted,\n TypographyKind,\n TypographySize,\n TypographyWeights,\n type TypographyElement,\n type TypographyElementPx,\n type TypographyFn,\n} from './types/typography';\n\n// SSR-safe Typography fallback\nconst createTypographyFallback = (): TypographyType => ({\n display: {\n extraSmall: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n small: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 },\n medium: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 48, fontStyle: 'normal', letterSpacing: 0, lineHeight: 56, paragraphSpacing: 72 },\n large: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 56, fontStyle: 'normal', letterSpacing: 0, lineHeight: 68, paragraphSpacing: 84 },\n },\n heading: {\n smallest: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 20 },\n extraSmall: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 24 },\n small: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 32 },\n medium: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 24, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 36 },\n large: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n extraLarge: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 },\n },\n label: {\n regular: {\n smallest: { fontFamily: 'Arial', fontWeight: 400, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 },\n extraSmall: { fontFamily: 'Arial', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n small: { fontFamily: 'Arial', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n medium: { fontFamily: 'Arial', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n large: { fontFamily: 'Arial', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n },\n strong: {\n smallest: { fontFamily: 'Arial', fontWeight: 700, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 },\n extraSmall: { fontFamily: 'Arial', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n small: { fontFamily: 'Arial', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n medium: { fontFamily: 'Arial', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n large: { fontFamily: 'Arial', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n },\n },\n paragraph: {\n regular: {\n extraLarge: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 32, paragraphSpacing: 32 },\n large: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 28 },\n medium: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n extraSmall: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n },\n strong: {\n extraLarge: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 32, paragraphSpacing: 32 },\n large: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 28 },\n medium: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n extraSmall: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n },\n },\n} as any);\n\n// Create a safe Typography object that always has the required structure\nconst Typography = (() => {\n try {\n return OriginalTypography || createTypographyFallback();\n } catch (error) {\n console.warn('Typography import failed, using fallback values', error);\n return createTypographyFallback();\n }\n})();\n\nconst transformValuesToPx = <T extends TypographyElement>(value: T): TypographyElementPx => ({\n ...value,\n fontWeight: `${value.fontWeight ?? 'normal'}`,\n fontSize: `${value.fontSize ?? 0}px`,\n lineHeight: `${value.lineHeight ?? 0}px`,\n paragraphSpacing: `${value.paragraphSpacing ?? 0}px`,\n letterSpacing: `${value.letterSpacing ?? 0}px`,\n});\n\n// Create a fallback Typography object for SSR when the actual Typography is not available\nconst createFallbackTypography = (): any => ({\n display: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 56, fontStyle: 'normal', letterSpacing: 0, lineHeight: 68, paragraphSpacing: 84 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 48, fontStyle: 'normal', letterSpacing: 0, lineHeight: 56, paragraphSpacing: 72 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 }\n },\n heading: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 },\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 24 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 24, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 36 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 32 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 20 }\n },\n label: {\n regular: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 }\n },\n strong: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 }\n }\n },\n paragraph: {\n regular: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 32 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 28 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }\n },\n strong: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 32 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 28 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }\n }\n }\n});\n\n// Ensure we have a safe Typography object to work with\nconst safeTypography = Typography || createFallbackTypography();\n\n/**\n * typography() is a function that returns a typography element with the specified values.\n *\n * @param kind the typography content type ('label', 'paragraph', 'heading' or 'display')\n * @param size the size of the typography content ('extraSmall', 'small', 'medium', 'large', 'extraLarge' or 'smallest')\n * @param weight the weight of the typography content ('regular' or 'strong')\n * @returns the typography element with the specified values\n *\n * @defaults typography('paragraph', 'medium', 'regular')\n */\nexport const typography: TypographyFn = <\n Kind extends TypographyKind,\n Size extends TypographySize<Kind>,\n Weight extends TypographyWeights<Kind>,\n>(\n kind: Kind,\n size = 'medium' as Size,\n weight = 'regular' as Weight,\n) => {\n // SSR-safe check for Typography object\n if (!safeTypography || !safeTypography[kind]) {\n console.warn(`Typography object or kind \"${kind}\" not available during SSR - using fallback values`);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n\n try {\n if (isTypographyWeighted(kind)) {\n // Additional safety check for weight\n if (!safeTypography[kind][weight]) {\n console.warn(`Typography weight \"${weight}\" not available for kind \"${kind}\" - using fallback`);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n return transformValuesToPx(safeTypography[kind][weight][size as keyof TypographyType[Kind][Weight]] as TypographyElement);\n } else {\n return transformValuesToPx(safeTypography[kind][size as keyof TypographyType[typeof kind]] as TypographyElement);\n }\n } catch (error) {\n console.warn(`Error accessing typography values for kind \"${kind}\", size \"${size}\", weight \"${weight}\" - using fallback`, error);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n};\n"],"names":["OriginalTypography","error","createTypographyFallback","Typography","transformValuesToPx","value","createFallbackTypography","safeTypography","typography","kind","size","weight","isTypographyWeighted"],"mappings":"qJACA,IAAIA,EACJ,GAAI,CAEFA,EADsB,QAAQ,sBAAsB,EACjB,UACrC,OAASC,EAAO,CACd,QAAQ,KAAK,yEAA0EA,CAAK,EAC5FD,EAAqB,IACvB,CAeA,MAAME,EAA2B,KAAuB,CACtD,QAAS,CACP,WAAY,CAAE,WAAY,6BAA8B,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,EAChK,MAAO,CAAE,WAAY,6BAA8B,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,EAC3J,OAAQ,CAAE,WAAY,6BAA8B,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,EAC5J,MAAO,CAAE,WAAY,6BAA8B,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,CAAG,EAEhK,QAAS,CACP,SAAU,CAAE,WAAY,6BAA8B,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,EAC9J,WAAY,CAAE,WAAY,6BAA8B,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,EAChK,MAAO,CAAE,WAAY,6BAA8B,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,EAC3J,OAAQ,CAAE,WAAY,6BAA8B,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAA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,WAAY,oBAAqB,WAAY,IAAK,SAAU,GAAI,UAAW,SAAU,cAAe,EAAG,WAAY,GAAI,iBAAkB,EAAA,CAAG,CAC1J,CAEJ,GAGMC,EAAiBJ,GAAcG,EAAA,EAYxBE,EAA2B,CAKtCC,EACAC,EAAO,SACPC,EAAS,YACN,CAEH,GAAI,CAACJ,GAAkB,CAACA,EAAeE,CAAI,EACzC,eAAQ,KAAK,8BAA8BA,CAAI,oDAAoD,EAC5F,CACL,WAAY,oBACZ,UAAW,SACX,WAAY,SACZ,SAAU,OACV,WAAY,OACZ,iBAAkB,MAClB,cAAe,KAAA,EAInB,GAAI,CACF,OAAIG,EAAAA,qBAAqBH,CAAI,EAEtBF,EAAeE,CAAI,EAAEE,CAAM,EAYzBP,EAAoBG,EAAeE,CAAI,EAAEE,CAAM,EAAED,CAA0C,CAAsB,GAXtH,QAAQ,KAAK,sBAAsBC,CAAM,6BAA6BF,CAAI,oBAAoB,EACvF,CACL,WAAY,oBACZ,UAAW,SACX,WAAY,SACZ,SAAU,OACV,WAAY,OACZ,iBAAkB,MAClB,cAAe,KAAA,GAKZL,EAAoBG,EAAeE,CAAI,EAAEC,CAAyC,CAAsB,CAEnH,OAAST,EAAO,CACd,eAAQ,KAAK,+CAA+CQ,CAAI,YAAYC,CAAI,cAAcC,CAAM,qBAAsBV,CAAK,EACxH,CACL,WAAY,oBACZ,UAAW,SACX,WAAY,SACZ,SAAU,OACV,WAAY,OACZ,iBAAkB,MAClB,cAAe,KAAA,CAEnB,CACF"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typography.d.ts","sourceRoot":"","sources":["../../../../../../react-base/src/theme/typography.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"typography.d.ts","sourceRoot":"","sources":["../../../../../../react-base/src/theme/typography.ts"],"names":[],"mappings":"AAYA,OAAO,EAOL,KAAK,YAAY,EAClB,MAAM,oBAAoB,CAAC;AA4H5B;;;;;;;;;GASG;AACH,eAAO,MAAM,UAAU,EAAE,YAsDxB,CAAC"}
|
|
@@ -1,13 +1,71 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
|
|
1
|
+
import { isTypographyWeighted as g } from "./types/typography.js";
|
|
2
|
+
let i;
|
|
3
|
+
try {
|
|
4
|
+
i = require("acinguiux-ds-fabrics").Typography;
|
|
5
|
+
} catch (a) {
|
|
6
|
+
console.warn("Failed to import Typography from acinguiux-ds-fabrics during SSR/build", a), i = null;
|
|
7
|
+
}
|
|
8
|
+
const r = () => ({
|
|
9
|
+
display: {
|
|
10
|
+
extraSmall: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 600, fontSize: 32, fontStyle: "normal", letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },
|
|
11
|
+
small: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 600, fontSize: 40, fontStyle: "normal", letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 },
|
|
12
|
+
medium: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 600, fontSize: 48, fontStyle: "normal", letterSpacing: 0, lineHeight: 56, paragraphSpacing: 72 },
|
|
13
|
+
large: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 600, fontSize: 56, fontStyle: "normal", letterSpacing: 0, lineHeight: 68, paragraphSpacing: 84 }
|
|
14
|
+
},
|
|
15
|
+
heading: {
|
|
16
|
+
smallest: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 500, fontSize: 14, fontStyle: "normal", letterSpacing: 0, lineHeight: 16, paragraphSpacing: 20 },
|
|
17
|
+
extraSmall: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 500, fontSize: 16, fontStyle: "normal", letterSpacing: 0, lineHeight: 20, paragraphSpacing: 24 },
|
|
18
|
+
small: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 500, fontSize: 20, fontStyle: "normal", letterSpacing: 0, lineHeight: 24, paragraphSpacing: 32 },
|
|
19
|
+
medium: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 500, fontSize: 24, fontStyle: "normal", letterSpacing: 0, lineHeight: 28, paragraphSpacing: 36 },
|
|
20
|
+
large: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 500, fontSize: 32, fontStyle: "normal", letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },
|
|
21
|
+
extraLarge: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 500, fontSize: 40, fontStyle: "normal", letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 }
|
|
22
|
+
},
|
|
23
|
+
label: {
|
|
24
|
+
regular: {
|
|
25
|
+
smallest: { fontFamily: "Arial", fontWeight: 400, fontSize: 10, fontStyle: "normal", letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 },
|
|
26
|
+
extraSmall: { fontFamily: "Arial", fontWeight: 400, fontSize: 12, fontStyle: "normal", letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },
|
|
27
|
+
small: { fontFamily: "Arial", fontWeight: 400, fontSize: 14, fontStyle: "normal", letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },
|
|
28
|
+
medium: { fontFamily: "Arial", fontWeight: 400, fontSize: 16, fontStyle: "normal", letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },
|
|
29
|
+
large: { fontFamily: "Arial", fontWeight: 400, fontSize: 18, fontStyle: "normal", letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 }
|
|
30
|
+
},
|
|
31
|
+
strong: {
|
|
32
|
+
smallest: { fontFamily: "Arial", fontWeight: 700, fontSize: 10, fontStyle: "normal", letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 },
|
|
33
|
+
extraSmall: { fontFamily: "Arial", fontWeight: 700, fontSize: 12, fontStyle: "normal", letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },
|
|
34
|
+
small: { fontFamily: "Arial", fontWeight: 700, fontSize: 14, fontStyle: "normal", letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },
|
|
35
|
+
medium: { fontFamily: "Arial", fontWeight: 700, fontSize: 16, fontStyle: "normal", letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },
|
|
36
|
+
large: { fontFamily: "Arial", fontWeight: 700, fontSize: 18, fontStyle: "normal", letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 }
|
|
37
|
+
}
|
|
38
|
+
},
|
|
39
|
+
paragraph: {
|
|
40
|
+
regular: {
|
|
41
|
+
extraLarge: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 400, fontSize: 20, fontStyle: "normal", letterSpacing: 0, lineHeight: 32, paragraphSpacing: 32 },
|
|
42
|
+
large: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 400, fontSize: 18, fontStyle: "normal", letterSpacing: 0, lineHeight: 28, paragraphSpacing: 28 },
|
|
43
|
+
medium: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 400, fontSize: 16, fontStyle: "normal", letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },
|
|
44
|
+
small: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 400, fontSize: 14, fontStyle: "normal", letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },
|
|
45
|
+
extraSmall: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 400, fontSize: 12, fontStyle: "normal", letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }
|
|
46
|
+
},
|
|
47
|
+
strong: {
|
|
48
|
+
extraLarge: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 600, fontSize: 20, fontStyle: "normal", letterSpacing: 0, lineHeight: 32, paragraphSpacing: 32 },
|
|
49
|
+
large: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 600, fontSize: 18, fontStyle: "normal", letterSpacing: 0, lineHeight: 28, paragraphSpacing: 28 },
|
|
50
|
+
medium: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 600, fontSize: 16, fontStyle: "normal", letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },
|
|
51
|
+
small: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 600, fontSize: 14, fontStyle: "normal", letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },
|
|
52
|
+
extraSmall: { fontFamily: "Be Vietnam Pro, sans-serif", fontWeight: 600, fontSize: 12, fontStyle: "normal", letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }
|
|
53
|
+
}
|
|
54
|
+
}
|
|
55
|
+
}), f = (() => {
|
|
56
|
+
try {
|
|
57
|
+
return i || r();
|
|
58
|
+
} catch (a) {
|
|
59
|
+
return console.warn("Typography import failed, using fallback values", a), r();
|
|
60
|
+
}
|
|
61
|
+
})(), l = (a) => ({
|
|
4
62
|
...a,
|
|
5
63
|
fontWeight: `${a.fontWeight ?? "normal"}`,
|
|
6
64
|
fontSize: `${a.fontSize ?? 0}px`,
|
|
7
65
|
lineHeight: `${a.lineHeight ?? 0}px`,
|
|
8
66
|
paragraphSpacing: `${a.paragraphSpacing ?? 0}px`,
|
|
9
67
|
letterSpacing: `${a.letterSpacing ?? 0}px`
|
|
10
|
-
}),
|
|
68
|
+
}), p = () => ({
|
|
11
69
|
display: {
|
|
12
70
|
extraSmall: { fontFamily: "Arial, sans-serif", fontWeight: 600, fontSize: 32, fontStyle: "normal", letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },
|
|
13
71
|
large: { fontFamily: "Arial, sans-serif", fontWeight: 600, fontSize: 56, fontStyle: "normal", letterSpacing: 0, lineHeight: 68, paragraphSpacing: 84 },
|
|
@@ -54,7 +112,7 @@ const i = (a) => ({
|
|
|
54
112
|
smallest: { fontFamily: "Arial, sans-serif", fontWeight: 700, fontSize: 12, fontStyle: "normal", letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }
|
|
55
113
|
}
|
|
56
114
|
}
|
|
57
|
-
}), t =
|
|
115
|
+
}), t = f || p(), s = (a, n = "medium", e = "regular") => {
|
|
58
116
|
if (!t || !t[a])
|
|
59
117
|
return console.warn(`Typography object or kind "${a}" not available during SSR - using fallback values`), {
|
|
60
118
|
fontFamily: "Arial, sans-serif",
|
|
@@ -66,7 +124,7 @@ const i = (a) => ({
|
|
|
66
124
|
letterSpacing: "0px"
|
|
67
125
|
};
|
|
68
126
|
try {
|
|
69
|
-
return
|
|
127
|
+
return g(a) ? t[a][e] ? l(t[a][e][n]) : (console.warn(`Typography weight "${e}" not available for kind "${a}" - using fallback`), {
|
|
70
128
|
fontFamily: "Arial, sans-serif",
|
|
71
129
|
fontStyle: "normal",
|
|
72
130
|
fontWeight: "normal",
|
|
@@ -74,9 +132,9 @@ const i = (a) => ({
|
|
|
74
132
|
lineHeight: "24px",
|
|
75
133
|
paragraphSpacing: "0px",
|
|
76
134
|
letterSpacing: "0px"
|
|
77
|
-
}) :
|
|
78
|
-
} catch (
|
|
79
|
-
return console.warn(`Error accessing typography values for kind "${a}", size "${
|
|
135
|
+
}) : l(t[a][n]);
|
|
136
|
+
} catch (o) {
|
|
137
|
+
return console.warn(`Error accessing typography values for kind "${a}", size "${n}", weight "${e}" - using fallback`, o), {
|
|
80
138
|
fontFamily: "Arial, sans-serif",
|
|
81
139
|
fontStyle: "normal",
|
|
82
140
|
fontWeight: "normal",
|
|
@@ -88,6 +146,6 @@ const i = (a) => ({
|
|
|
88
146
|
}
|
|
89
147
|
};
|
|
90
148
|
export {
|
|
91
|
-
|
|
149
|
+
s as typography
|
|
92
150
|
};
|
|
93
151
|
//# sourceMappingURL=typography.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"typography.js","sources":["../../../../../../react-base/src/theme/typography.ts"],"sourcesContent":["import { Typography, type TypographyType } from 'acinguiux-ds-fabrics';\n\nimport {\n isTypographyWeighted,\n TypographyKind,\n TypographySize,\n TypographyWeights,\n type TypographyElement,\n type TypographyElementPx,\n type TypographyFn,\n} from './types/typography';\n\nconst transformValuesToPx = <T extends TypographyElement>(value: T): TypographyElementPx => ({\n ...value,\n fontWeight: `${value.fontWeight ?? 'normal'}`,\n fontSize: `${value.fontSize ?? 0}px`,\n lineHeight: `${value.lineHeight ?? 0}px`,\n paragraphSpacing: `${value.paragraphSpacing ?? 0}px`,\n letterSpacing: `${value.letterSpacing ?? 0}px`,\n});\n\n// Create a fallback Typography object for SSR when the actual Typography is not available\nconst createFallbackTypography = (): any => ({\n display: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 56, fontStyle: 'normal', letterSpacing: 0, lineHeight: 68, paragraphSpacing: 84 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 48, fontStyle: 'normal', letterSpacing: 0, lineHeight: 56, paragraphSpacing: 72 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 }\n },\n heading: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 },\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 24 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 24, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 36 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 32 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 20 }\n },\n label: {\n regular: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 }\n },\n strong: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 }\n }\n },\n paragraph: {\n regular: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 32 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 28 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }\n },\n strong: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 32 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 28 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }\n }\n }\n});\n\n// Ensure we have a safe Typography object to work with\nconst safeTypography = Typography || createFallbackTypography();\n\n/**\n * typography() is a function that returns a typography element with the specified values.\n *\n * @param kind the typography content type ('label', 'paragraph', 'heading' or 'display')\n * @param size the size of the typography content ('extraSmall', 'small', 'medium', 'large', 'extraLarge' or 'smallest')\n * @param weight the weight of the typography content ('regular' or 'strong')\n * @returns the typography element with the specified values\n *\n * @defaults typography('paragraph', 'medium', 'regular')\n */\nexport const typography: TypographyFn = <\n Kind extends TypographyKind,\n Size extends TypographySize<Kind>,\n Weight extends TypographyWeights<Kind>,\n>(\n kind: Kind,\n size = 'medium' as Size,\n weight = 'regular' as Weight,\n) => {\n // SSR-safe check for Typography object\n if (!safeTypography || !safeTypography[kind]) {\n console.warn(`Typography object or kind \"${kind}\" not available during SSR - using fallback values`);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n\n try {\n if (isTypographyWeighted(kind)) {\n // Additional safety check for weight\n if (!safeTypography[kind][weight]) {\n console.warn(`Typography weight \"${weight}\" not available for kind \"${kind}\" - using fallback`);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n return transformValuesToPx(safeTypography[kind][weight][size as keyof TypographyType[Kind][Weight]] as TypographyElement);\n } else {\n return transformValuesToPx(safeTypography[kind][size as keyof TypographyType[typeof kind]] as TypographyElement);\n }\n } catch (error) {\n console.warn(`Error accessing typography values for kind \"${kind}\", size \"${size}\", weight \"${weight}\" - using fallback`, error);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n};\n"],"names":["transformValuesToPx","value","createFallbackTypography","safeTypography","Typography","typography","kind","size","weight","isTypographyWeighted","error"],"mappings":";;AAYA,MAAMA,IAAsB,CAA8BC,OAAmC;AAAA,EAC3F,GAAGA;AAAA,EACH,YAAY,GAAGA,EAAM,cAAc,QAAQ;AAAA,EAC3C,UAAU,GAAGA,EAAM,YAAY,CAAC;AAAA,EAChC,YAAY,GAAGA,EAAM,cAAc,CAAC;AAAA,EACpC,kBAAkB,GAAGA,EAAM,oBAAoB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AAG,YAAY,IAAI,kBAAkB,GAAA;AAAA,IAAG;AAAA,EAC1J;AAEJ,IAGMC,IAAiBC,KAAcF,EAAA,GAYxBG,IAA2B,CAKtCC,GACAC,IAAO,UACPC,IAAS,cACN;AAEH,MAAI,CAACL,KAAkB,CAACA,EAAeG,CAAI;AACzC,mBAAQ,KAAK,8BAA8BA,CAAI,oDAAoD,GAC5F;AAAA,MACL,YAAY;AAAA,MACZ,WAAW;AAAA,MACX,YAAY;AAAA,MACZ,UAAU;AAAA,MACV,YAAY;AAAA,MACZ,kBAAkB;AAAA,MAClB,eAAe;AAAA,IAAA;AAInB,MAAI;AACF,WAAIG,EAAqBH,CAAI,IAEtBH,EAAeG,CAAI,EAAEE,CAAM,IAYzBR,EAAoBG,EAAeG,CAAI,EAAEE,CAAM,EAAED,CAA0C,CAAsB,KAXtH,QAAQ,KAAK,sBAAsBC,CAAM,6BAA6BF,CAAI,oBAAoB,GACvF;AAAA,MACL,YAAY;AAAA,MACZ,WAAW;AAAA,MACX,YAAY;AAAA,MACZ,UAAU;AAAA,MACV,YAAY;AAAA,MACZ,kBAAkB;AAAA,MAClB,eAAe;AAAA,IAAA,KAKZN,EAAoBG,EAAeG,CAAI,EAAEC,CAAyC,CAAsB;AAAA,EAEnH,SAASG,GAAO;AACd,mBAAQ,KAAK,+CAA+CJ,CAAI,YAAYC,CAAI,cAAcC,CAAM,sBAAsBE,CAAK,GACxH;AAAA,MACL,YAAY;AAAA,MACZ,WAAW;AAAA,MACX,YAAY;AAAA,MACZ,UAAU;AAAA,MACV,YAAY;AAAA,MACZ,kBAAkB;AAAA,MAClB,eAAe;AAAA,IAAA;AAAA,EAEnB;AACF;"}
|
|
1
|
+
{"version":3,"file":"typography.js","sources":["../../../../../../react-base/src/theme/typography.ts"],"sourcesContent":["// Import Typography with SSR-safe fallback handling\nlet OriginalTypography: any;\ntry {\n const fabricsModule = require('acinguiux-ds-fabrics');\n OriginalTypography = fabricsModule.Typography;\n} catch (error) {\n console.warn('Failed to import Typography from acinguiux-ds-fabrics during SSR/build', error);\n OriginalTypography = null;\n}\n\nimport type { TypographyType } from 'acinguiux-ds-fabrics';\n\nimport {\n isTypographyWeighted,\n TypographyKind,\n TypographySize,\n TypographyWeights,\n type TypographyElement,\n type TypographyElementPx,\n type TypographyFn,\n} from './types/typography';\n\n// SSR-safe Typography fallback\nconst createTypographyFallback = (): TypographyType => ({\n display: {\n extraSmall: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n small: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 },\n medium: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 48, fontStyle: 'normal', letterSpacing: 0, lineHeight: 56, paragraphSpacing: 72 },\n large: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 56, fontStyle: 'normal', letterSpacing: 0, lineHeight: 68, paragraphSpacing: 84 },\n },\n heading: {\n smallest: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 20 },\n extraSmall: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 24 },\n small: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 32 },\n medium: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 24, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 36 },\n large: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n extraLarge: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 500, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 },\n },\n label: {\n regular: {\n smallest: { fontFamily: 'Arial', fontWeight: 400, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 },\n extraSmall: { fontFamily: 'Arial', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n small: { fontFamily: 'Arial', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n medium: { fontFamily: 'Arial', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n large: { fontFamily: 'Arial', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n },\n strong: {\n smallest: { fontFamily: 'Arial', fontWeight: 700, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 },\n extraSmall: { fontFamily: 'Arial', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n small: { fontFamily: 'Arial', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n medium: { fontFamily: 'Arial', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n large: { fontFamily: 'Arial', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n },\n },\n paragraph: {\n regular: {\n extraLarge: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 32, paragraphSpacing: 32 },\n large: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 28 },\n medium: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n extraSmall: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n },\n strong: {\n extraLarge: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 32, paragraphSpacing: 32 },\n large: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 28 },\n medium: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n extraSmall: { fontFamily: 'Be Vietnam Pro, sans-serif', fontWeight: 600, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n },\n },\n} as any);\n\n// Create a safe Typography object that always has the required structure\nconst Typography = (() => {\n try {\n return OriginalTypography || createTypographyFallback();\n } catch (error) {\n console.warn('Typography import failed, using fallback values', error);\n return createTypographyFallback();\n }\n})();\n\nconst transformValuesToPx = <T extends TypographyElement>(value: T): TypographyElementPx => ({\n ...value,\n fontWeight: `${value.fontWeight ?? 'normal'}`,\n fontSize: `${value.fontSize ?? 0}px`,\n lineHeight: `${value.lineHeight ?? 0}px`,\n paragraphSpacing: `${value.paragraphSpacing ?? 0}px`,\n letterSpacing: `${value.letterSpacing ?? 0}px`,\n});\n\n// Create a fallback Typography object for SSR when the actual Typography is not available\nconst createFallbackTypography = (): any => ({\n display: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 56, fontStyle: 'normal', letterSpacing: 0, lineHeight: 68, paragraphSpacing: 84 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 48, fontStyle: 'normal', letterSpacing: 0, lineHeight: 56, paragraphSpacing: 72 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 600, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 }\n },\n heading: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 40, fontStyle: 'normal', letterSpacing: 0, lineHeight: 48, paragraphSpacing: 60 },\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 24 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 32, fontStyle: 'normal', letterSpacing: 0, lineHeight: 40, paragraphSpacing: 48 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 24, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 36 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 32 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 500, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 20 }\n },\n label: {\n regular: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 }\n },\n strong: {\n extraSmall: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 20 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 16 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 10, fontStyle: 'normal', letterSpacing: 0, lineHeight: 12, paragraphSpacing: 12 }\n }\n },\n paragraph: {\n regular: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 32 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 28 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 400, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }\n },\n strong: {\n extraLarge: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 20, fontStyle: 'normal', letterSpacing: 0, lineHeight: 28, paragraphSpacing: 32 },\n large: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 18, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 28 },\n medium: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 16, fontStyle: 'normal', letterSpacing: 0, lineHeight: 24, paragraphSpacing: 24 },\n small: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 14, fontStyle: 'normal', letterSpacing: 0, lineHeight: 20, paragraphSpacing: 20 },\n smallest: { fontFamily: 'Arial, sans-serif', fontWeight: 700, fontSize: 12, fontStyle: 'normal', letterSpacing: 0, lineHeight: 16, paragraphSpacing: 16 }\n }\n }\n});\n\n// Ensure we have a safe Typography object to work with\nconst safeTypography = Typography || createFallbackTypography();\n\n/**\n * typography() is a function that returns a typography element with the specified values.\n *\n * @param kind the typography content type ('label', 'paragraph', 'heading' or 'display')\n * @param size the size of the typography content ('extraSmall', 'small', 'medium', 'large', 'extraLarge' or 'smallest')\n * @param weight the weight of the typography content ('regular' or 'strong')\n * @returns the typography element with the specified values\n *\n * @defaults typography('paragraph', 'medium', 'regular')\n */\nexport const typography: TypographyFn = <\n Kind extends TypographyKind,\n Size extends TypographySize<Kind>,\n Weight extends TypographyWeights<Kind>,\n>(\n kind: Kind,\n size = 'medium' as Size,\n weight = 'regular' as Weight,\n) => {\n // SSR-safe check for Typography object\n if (!safeTypography || !safeTypography[kind]) {\n console.warn(`Typography object or kind \"${kind}\" not available during SSR - using fallback values`);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n\n try {\n if (isTypographyWeighted(kind)) {\n // Additional safety check for weight\n if (!safeTypography[kind][weight]) {\n console.warn(`Typography weight \"${weight}\" not available for kind \"${kind}\" - using fallback`);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n return transformValuesToPx(safeTypography[kind][weight][size as keyof TypographyType[Kind][Weight]] as TypographyElement);\n } else {\n return transformValuesToPx(safeTypography[kind][size as keyof TypographyType[typeof kind]] as TypographyElement);\n }\n } catch (error) {\n console.warn(`Error accessing typography values for kind \"${kind}\", size \"${size}\", weight \"${weight}\" - using fallback`, error);\n return {\n fontFamily: 'Arial, sans-serif',\n fontStyle: 'normal',\n fontWeight: 'normal',\n fontSize: '16px',\n lineHeight: '24px',\n paragraphSpacing: '0px',\n letterSpacing: '0px',\n } as TypographyElementPx;\n }\n};\n"],"names":["OriginalTypography","error","createTypographyFallback","Typography","transformValuesToPx","value","createFallbackTypography","safeTypography","typography","kind","size","weight","isTypographyWeighted"],"mappings":";AACA,IAAIA;AACJ,IAAI;AAEF,EAAAA,IADsB,QAAQ,sBAAsB,EACjB;AACrC,SAASC,GAAO;AACd,UAAQ,KAAK,0EAA0EA,CAAK,GAC5FD,IAAqB;AACvB;AAeA,MAAME,IAA2B,OAAuB;AAAA,EACtD,SAAS;AAAA,IACP,YAAY,EAAE,YAAY,8BAA8B,YAAY,KAAK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