@hanzogui/text 3.0.2 → 7.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (89) hide show
  1. package/package.json +10 -10
  2. package/src/Headings.tsx +6 -6
  3. package/src/SizableText.tsx +1 -1
  4. package/types/Emphasis.d.ts +3 -3
  5. package/types/Headings.d.ts +22 -22
  6. package/types/Paragraph.d.ts +4 -4
  7. package/types/SizableText.d.ts +4 -4
  8. package/types/wrapChildrenInText.d.ts +1 -1
  9. package/dist/cjs/Emphasis.cjs +0 -39
  10. package/dist/cjs/Emphasis.native.js +0 -42
  11. package/dist/cjs/Emphasis.native.js.map +0 -1
  12. package/dist/cjs/Headings.cjs +0 -125
  13. package/dist/cjs/Headings.native.js +0 -128
  14. package/dist/cjs/Headings.native.js.map +0 -1
  15. package/dist/cjs/Paragraph.cjs +0 -35
  16. package/dist/cjs/Paragraph.native.js +0 -38
  17. package/dist/cjs/Paragraph.native.js.map +0 -1
  18. package/dist/cjs/SizableText.cjs +0 -54
  19. package/dist/cjs/SizableText.native.js +0 -57
  20. package/dist/cjs/SizableText.native.js.map +0 -1
  21. package/dist/cjs/index.cjs +0 -23
  22. package/dist/cjs/index.native.js +0 -26
  23. package/dist/cjs/index.native.js.map +0 -1
  24. package/dist/cjs/types.cjs +0 -16
  25. package/dist/cjs/types.native.js +0 -19
  26. package/dist/cjs/types.native.js.map +0 -1
  27. package/dist/cjs/wrapChildrenInText.cjs +0 -65
  28. package/dist/cjs/wrapChildrenInText.native.js +0 -71
  29. package/dist/cjs/wrapChildrenInText.native.js.map +0 -1
  30. package/dist/esm/Emphasis.mjs +0 -14
  31. package/dist/esm/Emphasis.mjs.map +0 -1
  32. package/dist/esm/Emphasis.native.js +0 -14
  33. package/dist/esm/Emphasis.native.js.map +0 -1
  34. package/dist/esm/Headings.mjs +0 -96
  35. package/dist/esm/Headings.mjs.map +0 -1
  36. package/dist/esm/Headings.native.js +0 -96
  37. package/dist/esm/Headings.native.js.map +0 -1
  38. package/dist/esm/Paragraph.mjs +0 -12
  39. package/dist/esm/Paragraph.mjs.map +0 -1
  40. package/dist/esm/Paragraph.native.js +0 -12
  41. package/dist/esm/Paragraph.native.js.map +0 -1
  42. package/dist/esm/SizableText.mjs +0 -31
  43. package/dist/esm/SizableText.mjs.map +0 -1
  44. package/dist/esm/SizableText.native.js +0 -31
  45. package/dist/esm/SizableText.native.js.map +0 -1
  46. package/dist/esm/index.js +0 -7
  47. package/dist/esm/index.js.map +0 -1
  48. package/dist/esm/index.mjs +0 -7
  49. package/dist/esm/index.mjs.map +0 -1
  50. package/dist/esm/index.native.js +0 -7
  51. package/dist/esm/index.native.js.map +0 -1
  52. package/dist/esm/types.mjs +0 -2
  53. package/dist/esm/types.mjs.map +0 -1
  54. package/dist/esm/types.native.js +0 -2
  55. package/dist/esm/types.native.js.map +0 -1
  56. package/dist/esm/wrapChildrenInText.mjs +0 -32
  57. package/dist/esm/wrapChildrenInText.mjs.map +0 -1
  58. package/dist/esm/wrapChildrenInText.native.js +0 -34
  59. package/dist/esm/wrapChildrenInText.native.js.map +0 -1
  60. package/dist/jsx/Emphasis.mjs +0 -14
  61. package/dist/jsx/Emphasis.mjs.map +0 -1
  62. package/dist/jsx/Emphasis.native.js +0 -42
  63. package/dist/jsx/Emphasis.native.js.map +0 -1
  64. package/dist/jsx/Headings.mjs +0 -96
  65. package/dist/jsx/Headings.mjs.map +0 -1
  66. package/dist/jsx/Headings.native.js +0 -128
  67. package/dist/jsx/Headings.native.js.map +0 -1
  68. package/dist/jsx/Paragraph.mjs +0 -12
  69. package/dist/jsx/Paragraph.mjs.map +0 -1
  70. package/dist/jsx/Paragraph.native.js +0 -38
  71. package/dist/jsx/Paragraph.native.js.map +0 -1
  72. package/dist/jsx/SizableText.mjs +0 -31
  73. package/dist/jsx/SizableText.mjs.map +0 -1
  74. package/dist/jsx/SizableText.native.js +0 -57
  75. package/dist/jsx/SizableText.native.js.map +0 -1
  76. package/dist/jsx/index.js +0 -7
  77. package/dist/jsx/index.js.map +0 -1
  78. package/dist/jsx/index.mjs +0 -7
  79. package/dist/jsx/index.mjs.map +0 -1
  80. package/dist/jsx/index.native.js +0 -26
  81. package/dist/jsx/index.native.js.map +0 -1
  82. package/dist/jsx/types.mjs +0 -2
  83. package/dist/jsx/types.mjs.map +0 -1
  84. package/dist/jsx/types.native.js +0 -19
  85. package/dist/jsx/types.native.js.map +0 -1
  86. package/dist/jsx/wrapChildrenInText.mjs +0 -32
  87. package/dist/jsx/wrapChildrenInText.mjs.map +0 -1
  88. package/dist/jsx/wrapChildrenInText.native.js +0 -71
  89. package/dist/jsx/wrapChildrenInText.native.js.map +0 -1
@@ -1,54 +0,0 @@
1
- var __defProp = Object.defineProperty;
2
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
- var __getOwnPropNames = Object.getOwnPropertyNames;
4
- var __hasOwnProp = Object.prototype.hasOwnProperty;
5
- var __export = (target, all) => {
6
- for (var name in all) __defProp(target, name, {
7
- get: all[name],
8
- enumerable: !0
9
- });
10
- },
11
- __copyProps = (to, from, except, desc) => {
12
- if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
13
- get: () => from[key],
14
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
15
- });
16
- return to;
17
- };
18
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
19
- value: !0
20
- }), mod);
21
- var SizableText_exports = {};
22
- __export(SizableText_exports, {
23
- SizableText: () => SizableText
24
- });
25
- module.exports = __toCommonJS(SizableText_exports);
26
- var import_gui_get_font_sized = require("@hanzogui/get-font-sized"),
27
- import_gui_web = require("@hanzogui/web");
28
- const SizableText = (0, import_gui_web.styled)(import_gui_web.Text, {
29
- name: "SizableText",
30
- fontFamily: "$body",
31
- variants: {
32
- unstyled: {
33
- false: {
34
- size: "$true",
35
- color: "$color"
36
- }
37
- },
38
- size: import_gui_get_font_sized.getFontSized
39
- },
40
- defaultVariants: {
41
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
42
- }
43
- });
44
- SizableText.staticConfig.variants.fontFamily = {
45
- "...": (val, extras) => {
46
- if (val === "inherit") return {
47
- fontFamily: "inherit"
48
- };
49
- const sizeProp = extras.props.size,
50
- fontSizeProp = extras.props.fontSize,
51
- size = sizeProp === "$true" && fontSizeProp ? fontSizeProp : extras.props.size || "$true";
52
- return (0, import_gui_get_font_sized.getFontSized)(size, extras);
53
- }
54
- };
@@ -1,57 +0,0 @@
1
- "use strict";
2
-
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __export = (target, all) => {
8
- for (var name in all) __defProp(target, name, {
9
- get: all[name],
10
- enumerable: !0
11
- });
12
- },
13
- __copyProps = (to, from, except, desc) => {
14
- if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
15
- get: () => from[key],
16
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
17
- });
18
- return to;
19
- };
20
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
21
- value: !0
22
- }), mod);
23
- var SizableText_exports = {};
24
- __export(SizableText_exports, {
25
- SizableText: () => SizableText
26
- });
27
- module.exports = __toCommonJS(SizableText_exports);
28
- var import_gui_get_font_sized = require("@hanzogui/get-font-sized"),
29
- import_gui_web = require("@hanzogui/web"),
30
- SizableText = (0, import_gui_web.styled)(import_gui_web.Text, {
31
- name: "SizableText",
32
- fontFamily: "$body",
33
- variants: {
34
- unstyled: {
35
- false: {
36
- size: "$true",
37
- color: "$color"
38
- }
39
- },
40
- size: import_gui_get_font_sized.getFontSized
41
- },
42
- defaultVariants: {
43
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
44
- }
45
- });
46
- SizableText.staticConfig.variants.fontFamily = {
47
- "...": function (val, extras) {
48
- if (val === "inherit") return {
49
- fontFamily: "inherit"
50
- };
51
- var sizeProp = extras.props.size,
52
- fontSizeProp = extras.props.fontSize,
53
- size = sizeProp === "$true" && fontSizeProp ? fontSizeProp : extras.props.size || "$true";
54
- return (0, import_gui_get_font_sized.getFontSized)(size, extras);
55
- }
56
- };
57
- //# sourceMappingURL=SizableText.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","SizableText_exports","__export","SizableText","module","exports","import_gui_get_font_sized","require","import_gui_web","styled","Text","name","fontFamily","variants","unstyled","false","size","color","getFontSized","defaultVariants","process","env","HANZO_GUI_HEADLESS","staticConfig","...","val","extras","sizeProp","props","fontSizeProp","fontSize"],"sources":["../../src/SizableText.tsx"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;EAAAC,KAAA;AAAA,IAAAH,GAAA;AAAA,IAAAI,mBAAA;AAAAC,QAAA,CAAAD,mBAAA;EAAAE,WAAA,EAAAA,CAAA,KAAAA;AAAA;AAAAC,MAAA,CAAAC,OAAA,GAAAT,YAAA,CAAAK,mBAA6B;AAItB,IAAAK,yBAAoB,GAAAC,OAAA,4BAAO,CAAM;EAAAC,cAAA,GAAAD,OAAA;EAAAJ,WAAA,OAAAK,cAAA,CAAAC,MAAA,EAAAD,cAAA,CAAAE,IAAA;IACtCC,IAAA,EAAM;IACNC,UAAA,EAAY;IAEZC,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLC,IAAA,EAAM;UACNC,KAAA,EAAO;QACT;MACF;MAEAD,IAAA,EAAMV,yBAAA,CAAAY;IACR;IAEAC,eAAA,EAAiB;MACfL,QAAA,EAAUM,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;AAIDnB,WAAA,CAAYoB,YAAA,CAAaV,QAAA,CAAUD,UAAA,GAAa;EAC9C,OAAO,SAAAY,CAAMC,GAAA,EAAAC,MAAW;IAEtB,IAAID,GAAA,KAAQ,WACV,OAAO;MAGTb,UAAM;IAMN;IACF,IAAAe,QAAA,GAAAD,MAAA,CAAAE,KAAA,CAAAZ,IAAA;MAAAa,YAAA,GAAAH,MAAA,CAAAE,KAAA,CAAAE,QAAA;MAAAd,IAAA,GAAAW,QAAA,gBAAAE,YAAA,GAAAA,YAAA,GAAAH,MAAA,CAAAE,KAAA,CAAAZ,IAAA;IACF,WAAAV,yBAAA,CAAAY,YAAA,EAAAF,IAAA,EAAAU,MAAA","ignoreList":[]}
@@ -1,23 +0,0 @@
1
- var __defProp = Object.defineProperty;
2
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
- var __getOwnPropNames = Object.getOwnPropertyNames;
4
- var __hasOwnProp = Object.prototype.hasOwnProperty;
5
- var __copyProps = (to, from, except, desc) => {
6
- if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
7
- get: () => from[key],
8
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
9
- });
10
- return to;
11
- },
12
- __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
13
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
14
- value: !0
15
- }), mod);
16
- var index_exports = {};
17
- module.exports = __toCommonJS(index_exports);
18
- __reExport(index_exports, require("./Emphasis.cjs"), module.exports);
19
- __reExport(index_exports, require("./SizableText.cjs"), module.exports);
20
- __reExport(index_exports, require("./Paragraph.cjs"), module.exports);
21
- __reExport(index_exports, require("./Headings.cjs"), module.exports);
22
- __reExport(index_exports, require("./wrapChildrenInText.cjs"), module.exports);
23
- __reExport(index_exports, require("./types.cjs"), module.exports);
@@ -1,26 +0,0 @@
1
- "use strict";
2
-
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __copyProps = (to, from, except, desc) => {
8
- if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
9
- get: () => from[key],
10
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
11
- });
12
- return to;
13
- },
14
- __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
15
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
16
- value: !0
17
- }), mod);
18
- var index_exports = {};
19
- module.exports = __toCommonJS(index_exports);
20
- __reExport(index_exports, require("./Emphasis.native.js"), module.exports);
21
- __reExport(index_exports, require("./SizableText.native.js"), module.exports);
22
- __reExport(index_exports, require("./Paragraph.native.js"), module.exports);
23
- __reExport(index_exports, require("./Headings.native.js"), module.exports);
24
- __reExport(index_exports, require("./wrapChildrenInText.native.js"), module.exports);
25
- __reExport(index_exports, require("./types.native.js"), module.exports);
26
- //# sourceMappingURL=index.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","index_exports","module","exports","__reExport","require"],"sources":["../../src/index.tsx"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;EAAAC,KAAA;AAAA,IAAAH,GAAA;AAAA,IAAAI,aAAA;AAAAC,MAAA,CAAAC,OAAA,GAAAP,YAAc,CAAAK,aAAA;AACdG,UAAA,CAAAH,aAAA,EAAcI,OAAA,0BAAAH,MADd,CAAAC,OAAA;AAEAC,UAAA,CAAAH,aAAA,EAAcI,OAAA,2BAFd,EAAAH,MAAA,CAAAC,OAAA;AAGAC,UAAA,CAAAH,aAAA,EAAcI,OAAA,2BAHdH,MAAA,CAAAC,OAAA;AAIAC,UAAA,CAAAH,aAAA,EAAcI,OAAA,0BAAAH,MAAA,CAAAC,OAJd;AAKAC,UAAA,CAAAH,aAAA,EAAcI,OAAA,iCALd,GAAAH,MAAA,CAAAC,OAAA","ignoreList":[]}
@@ -1,16 +0,0 @@
1
- var __defProp = Object.defineProperty;
2
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
- var __getOwnPropNames = Object.getOwnPropertyNames;
4
- var __hasOwnProp = Object.prototype.hasOwnProperty;
5
- var __copyProps = (to, from, except, desc) => {
6
- if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
7
- get: () => from[key],
8
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
9
- });
10
- return to;
11
- };
12
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
13
- value: !0
14
- }), mod);
15
- var types_exports = {};
16
- module.exports = __toCommonJS(types_exports);
@@ -1,19 +0,0 @@
1
- "use strict";
2
-
3
- var __defProp = Object.defineProperty;
4
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
5
- var __getOwnPropNames = Object.getOwnPropertyNames;
6
- var __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __copyProps = (to, from, except, desc) => {
8
- if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
9
- get: () => from[key],
10
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
11
- });
12
- return to;
13
- };
14
- var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
15
- value: !0
16
- }), mod);
17
- var types_exports = {};
18
- module.exports = __toCommonJS(types_exports);
19
- //# sourceMappingURL=types.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","types_exports"],"sources":["../../src/types.ts"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;EAAAC,KAAA;AAAA,IAAAH,GAAA;AAAA,IAAAI,aAAA","ignoreList":[]}
@@ -1,65 +0,0 @@
1
- var __create = Object.create;
2
- var __defProp = Object.defineProperty;
3
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
- var __getOwnPropNames = Object.getOwnPropertyNames;
5
- var __getProtoOf = Object.getPrototypeOf,
6
- __hasOwnProp = Object.prototype.hasOwnProperty;
7
- var __export = (target, all) => {
8
- for (var name in all) __defProp(target, name, {
9
- get: all[name],
10
- enumerable: !0
11
- });
12
- },
13
- __copyProps = (to, from, except, desc) => {
14
- if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
15
- get: () => from[key],
16
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
17
- });
18
- return to;
19
- };
20
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
21
- // If the importer is in node compatibility mode or this is not an ESM
22
- // file that has been converted to a CommonJS file using a Babel-
23
- // compatible transform (i.e. "__esModule" has not been set), then set
24
- // "default" to the CommonJS "module.exports" for node compatibility.
25
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
26
- value: mod,
27
- enumerable: !0
28
- }) : target, mod)),
29
- __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
30
- value: !0
31
- }), mod);
32
- var wrapChildrenInText_exports = {};
33
- __export(wrapChildrenInText_exports, {
34
- wrapChildrenInText: () => wrapChildrenInText
35
- });
36
- module.exports = __toCommonJS(wrapChildrenInText_exports);
37
- var import_react = __toESM(require("react"), 1),
38
- import_jsx_runtime =
39
- // so "data-disable-theme" is a hack to fix themeInverse, don't ask me why
40
- require("react/jsx-runtime");
41
- function wrapChildrenInText(TextComponent, propsIn, extraProps) {
42
- const {
43
- children,
44
- textProps,
45
- size,
46
- noTextWrap,
47
- color,
48
- fontFamily,
49
- fontSize,
50
- fontWeight,
51
- letterSpacing,
52
- textAlign,
53
- fontStyle,
54
- maxFontSizeMultiplier
55
- } = propsIn;
56
- if (noTextWrap || !children) return [children];
57
- const props = {
58
- ...extraProps
59
- };
60
- return color && (props.color = color), fontFamily && (props.fontFamily = fontFamily), fontSize && (props.fontSize = fontSize), fontWeight && (props.fontWeight = fontWeight), letterSpacing && (props.letterSpacing = letterSpacing), textAlign && (props.textAlign = textAlign), size && (props.size = size), fontStyle && (props.fontStyle = fontStyle), maxFontSizeMultiplier && (props.maxFontSizeMultiplier = maxFontSizeMultiplier), import_react.default.Children.toArray(children).map((child, index) => typeof child == "string" ? /* @__PURE__ */(0, import_jsx_runtime.jsx)(TextComponent, {
61
- ...props,
62
- ...textProps,
63
- children: child
64
- }, index) : child);
65
- }
@@ -1,71 +0,0 @@
1
- "use strict";
2
-
3
- var __create = Object.create;
4
- var __defProp = Object.defineProperty;
5
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
6
- var __getOwnPropNames = Object.getOwnPropertyNames;
7
- var __getProtoOf = Object.getPrototypeOf,
8
- __hasOwnProp = Object.prototype.hasOwnProperty;
9
- var __export = (target, all) => {
10
- for (var name in all) __defProp(target, name, {
11
- get: all[name],
12
- enumerable: !0
13
- });
14
- },
15
- __copyProps = (to, from, except, desc) => {
16
- if (from && typeof from == "object" || typeof from == "function") for (let key of __getOwnPropNames(from)) !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, {
17
- get: () => from[key],
18
- enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
19
- });
20
- return to;
21
- };
22
- var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
23
- // If the importer is in node compatibility mode or this is not an ESM
24
- // file that has been converted to a CommonJS file using a Babel-
25
- // compatible transform (i.e. "__esModule" has not been set), then set
26
- // "default" to the CommonJS "module.exports" for node compatibility.
27
- isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
28
- value: mod,
29
- enumerable: !0
30
- }) : target, mod)),
31
- __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
32
- value: !0
33
- }), mod);
34
- var wrapChildrenInText_exports = {};
35
- __export(wrapChildrenInText_exports, {
36
- wrapChildrenInText: () => wrapChildrenInText
37
- });
38
- module.exports = __toCommonJS(wrapChildrenInText_exports);
39
- var import_jsx_runtime = require("react/jsx-runtime"),
40
- import_react = __toESM(require("react"), 1);
41
- function wrapChildrenInText(TextComponent, propsIn, extraProps) {
42
- var {
43
- children,
44
- textProps,
45
- size,
46
- noTextWrap,
47
- color,
48
- fontFamily,
49
- fontSize,
50
- fontWeight,
51
- letterSpacing,
52
- textAlign,
53
- fontStyle,
54
- maxFontSizeMultiplier
55
- } = propsIn;
56
- if (noTextWrap || !children) return [children];
57
- var props = {
58
- ...extraProps
59
- };
60
- return color && (props.color = color), fontFamily && (props.fontFamily = fontFamily), fontSize && (props.fontSize = fontSize), fontWeight && (props.fontWeight = fontWeight), letterSpacing && (props.letterSpacing = letterSpacing), textAlign && (props.textAlign = textAlign), size && (props.size = size), fontStyle && (props.fontStyle = fontStyle), maxFontSizeMultiplier && (props.maxFontSizeMultiplier = maxFontSizeMultiplier), import_react.default.Children.toArray(children).map(function (child, index) {
61
- return typeof child == "string" ?
62
- // so "data-disable-theme" is a hack to fix themeInverse, don't ask me why
63
- /* @__PURE__ */
64
- (0, import_jsx_runtime.jsx)(TextComponent, {
65
- ...props,
66
- ...textProps,
67
- children: child
68
- }, index) : child;
69
- });
70
- }
71
- //# sourceMappingURL=wrapChildrenInText.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","wrapChildrenInText_exports","__export","wrapChildrenInText","module","exports","import_jsx_runtime","require","import_react","__toESM","TextComponent","propsIn","extraProps","children","textProps","size","noTextWrap","color","fontFamily","fontSize","fontWeight","letterSpacing","textAlign","fontStyle","maxFontSizeMultiplier","props","default","Children","toArray","map","child","index","jsx"],"sources":["../../src/wrapChildrenInText.tsx"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAAA;EAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;IAAAC,KAAA;EAAA,IAAAH,GAAA;AAAA,IAAAI,0BAAA;AAAAC,QAAA,CAAAD,0BAAA;EAAAE,kBAAA,EAAAA,CAAA,KAAAA;AAAA;AACAC,MAAA,CAAAC,OAAA,GAAAT,YAAkB,CAAAK,0BAqDZ;AAAA,IAAAK,kBAAA,GAAAC,OAAA;EAAAC,YAAA,GAAAC,OAAA,CAAAF,OAAA;AAAA,SAAAJ,mBAAAO,aAAA,EAAAC,OAAA,EAAAC,UAAA;EAAA;IAAAC,QAAA;IAAAC,SAAA;IAAAC,IAAA;IAAAC,UAAA;IAAAC,KAAA;IAAAC,UAAA;IAAAC,QAAA;IAAAC,UAAA;IAAAC,aAAA;IAAAC,SAAA;IAAAC,SAAA;IAAAC;EAAA,IAAAb,OAAA;EA5CC,IAAAK,UAAS,KAAAH,QACd,EAMA,OAAM,CACJA,QAAA,CACA;EAAA,IACAY,KAAA;IACA,GAAAb;EAAA;EACA,OACAK,KAAA,KAAAQ,KAAA,CAAAR,KAAA,GAAAA,KAAA,GAAAC,UAAA,KAAAO,KAAA,CAAAP,UAAA,GAAAA,UAAA,GAAAC,QAAA,KAAAM,KAAA,CAAAN,QAAA,GAAAA,QAAA,GAAAC,UAAA,KAAAK,KAAA,CAAAL,UAAA,GAAAA,UAAA,GAAAC,aAAA,KAAAI,KAAA,CAAAJ,aAAA,GAAAA,aAAA,GAAAC,SAAA,KAAAG,KAAA,CAAAH,SAAA,GAAAA,SAAA,GAAAP,IAAA,KAAAU,KAAA,CAAAV,IAAA,GAAAA,IAAA,GAAAQ,SAAA,KAAAE,KAAA,CAAAF,SAAA,GAAAA,SAAA,GAAAC,qBAAA,KAAAC,KAAA,CAAAD,qBAAA,GAAAA,qBAAA,GAAAhB,YAAA,CAAAkB,OAAA,CAAAC,QAAA,CAAAC,OAAA,CAAAf,QAAA,EAAAgB,GAAA,WAAAC,KAAA,EAAAC,KAAA;IACA,cAAAD,KAAA;IACA;IACA;IAAA,IAAAxB,kBAAA,CAAA0B,GAAA,EAAAtB,aAAA;MACA,GAAAe,KAAA;MACA,GAAAX,SAAA;MACAD,QAAA,EAAAiB;IACE,GAAAC,KAAA,IAEAD,KAAA;EACF;AAGF","ignoreList":[]}
@@ -1,14 +0,0 @@
1
- import { styled, Text } from "@hanzogui/web";
2
- const Strong = styled(Text, {
3
- render: "strong",
4
- fontWeight: "bold"
5
- }),
6
- Span = styled(Text, {
7
- render: "span"
8
- }),
9
- Em = styled(Text, {
10
- render: "em",
11
- fontStyle: "italic"
12
- });
13
- export { Em, Span, Strong };
14
- //# sourceMappingURL=Emphasis.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["styled","Text","Strong","render","fontWeight","Span","Em","fontStyle"],"sources":["../../src/Emphasis.tsx"],"sourcesContent":[null],"mappings":"AAAA,SAASA,MAAA,EAAQC,IAAA,QAAY;AAEtB,MAAMC,MAAA,GAASF,MAAA,CAAOC,IAAA,EAAM;IACjCE,MAAA,EAAQ;IACRC,UAAA,EAAY;EACd,CAAC;EAEYC,IAAA,GAAOL,MAAA,CAAOC,IAAA,EAAM;IAC/BE,MAAA,EAAQ;EACV,CAAC;EAEYG,EAAA,GAAKN,MAAA,CAAOC,IAAA,EAAM;IAC7BE,MAAA,EAAQ;IACRI,SAAA,EAAW;EACb,CAAC","ignoreList":[]}
@@ -1,14 +0,0 @@
1
- import { styled, Text } from "@hanzogui/web";
2
- var Strong = styled(Text, {
3
- render: "strong",
4
- fontWeight: "bold"
5
- }),
6
- Span = styled(Text, {
7
- render: "span"
8
- }),
9
- Em = styled(Text, {
10
- render: "em",
11
- fontStyle: "italic"
12
- });
13
- export { Em, Span, Strong };
14
- //# sourceMappingURL=Emphasis.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["styled","Text","Strong","render","fontWeight","Span","Em","fontStyle"],"sources":["../../src/Emphasis.tsx"],"sourcesContent":[null],"mappings":"AAAA,SAASA,MAAA,EAAQC,IAAA,QAAY;AAEtB,IAAAC,MAAM,GAAAF,MAAS,CAAAC,IAAO;IAC3BE,MAAA,EAAQ;IACRC,UAAA,EAAY;EACd,CAAC;EAEYC,IAAA,GAAOL,MAAA,CAAOC,IAAA,EAAM;IAC/BE,MAAA,EAAQ;EACV,CAAC;EAEYG,EAAA,GAAKN,MAAA,CAAOC,IAAA,EAAM;IAC7BE,MAAA,EAAQ;IACRI,SAAA,EAAW;EACb,CAAC","ignoreList":[]}
@@ -1,96 +0,0 @@
1
- import { styled } from "@hanzogui/web";
2
- import { Paragraph } from "./Paragraph.mjs";
3
- const Heading = styled(Paragraph, {
4
- render: "span",
5
- name: "Heading",
6
- role: "heading",
7
- fontFamily: "$heading",
8
- size: "$8",
9
- margin: 0
10
- }),
11
- H1 = styled(Heading, {
12
- name: "H1",
13
- render: "h1",
14
- variants: {
15
- unstyled: {
16
- false: {
17
- size: "$10"
18
- }
19
- }
20
- },
21
- defaultVariants: {
22
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
23
- }
24
- }),
25
- H2 = styled(Heading, {
26
- name: "H2",
27
- render: "h2",
28
- variants: {
29
- unstyled: {
30
- false: {
31
- size: "$9"
32
- }
33
- }
34
- },
35
- defaultVariants: {
36
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
37
- }
38
- }),
39
- H3 = styled(Heading, {
40
- name: "H3",
41
- render: "h3",
42
- variants: {
43
- unstyled: {
44
- false: {
45
- size: "$8"
46
- }
47
- }
48
- },
49
- defaultVariants: {
50
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
51
- }
52
- }),
53
- H4 = styled(Heading, {
54
- name: "H4",
55
- render: "h4",
56
- variants: {
57
- unstyled: {
58
- false: {
59
- size: "$7"
60
- }
61
- }
62
- },
63
- defaultVariants: {
64
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
65
- }
66
- }),
67
- H5 = styled(Heading, {
68
- name: "H5",
69
- render: "h5",
70
- variants: {
71
- unstyled: {
72
- false: {
73
- size: "$6"
74
- }
75
- }
76
- },
77
- defaultVariants: {
78
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
79
- }
80
- }),
81
- H6 = styled(Heading, {
82
- name: "H6",
83
- render: "h6",
84
- variants: {
85
- unstyled: {
86
- false: {
87
- size: "$5"
88
- }
89
- }
90
- },
91
- defaultVariants: {
92
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
93
- }
94
- });
95
- export { H1, H2, H3, H4, H5, H6, Heading };
96
- //# sourceMappingURL=Headings.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["styled","Paragraph","Heading","render","name","role","fontFamily","size","margin","H1","variants","unstyled","false","defaultVariants","process","env","HANZO_GUI_HEADLESS","H2","H3","H4","H5","H6"],"sources":["../../src/Headings.tsx"],"sourcesContent":[null],"mappings":"AACA,SAASA,MAAA,QAAc;AAEvB,SAASC,SAAA,QAAiB;AAEnB,MAAMC,OAAA,GAAUF,MAAA,CAAOC,SAAA,EAAW;IACvCE,MAAA,EAAQ;IACRC,IAAA,EAAM;IACNC,IAAA,EAAM;IACNC,UAAA,EAAY;IACZC,IAAA,EAAM;IACNC,MAAA,EAAQ;EACV,CAAC;EAIYC,EAAA,GAAKT,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYC,EAAA,GAAKjB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYE,EAAA,GAAKlB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYG,EAAA,GAAKnB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYI,EAAA,GAAKpB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYK,EAAA,GAAKrB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC","ignoreList":[]}
@@ -1,96 +0,0 @@
1
- import { styled } from "@hanzogui/web";
2
- import { Paragraph } from "./Paragraph.native.js";
3
- var Heading = styled(Paragraph, {
4
- render: "span",
5
- name: "Heading",
6
- role: "heading",
7
- fontFamily: "$heading",
8
- size: "$8",
9
- margin: 0
10
- }),
11
- H1 = styled(Heading, {
12
- name: "H1",
13
- render: "h1",
14
- variants: {
15
- unstyled: {
16
- false: {
17
- size: "$10"
18
- }
19
- }
20
- },
21
- defaultVariants: {
22
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
23
- }
24
- }),
25
- H2 = styled(Heading, {
26
- name: "H2",
27
- render: "h2",
28
- variants: {
29
- unstyled: {
30
- false: {
31
- size: "$9"
32
- }
33
- }
34
- },
35
- defaultVariants: {
36
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
37
- }
38
- }),
39
- H3 = styled(Heading, {
40
- name: "H3",
41
- render: "h3",
42
- variants: {
43
- unstyled: {
44
- false: {
45
- size: "$8"
46
- }
47
- }
48
- },
49
- defaultVariants: {
50
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
51
- }
52
- }),
53
- H4 = styled(Heading, {
54
- name: "H4",
55
- render: "h4",
56
- variants: {
57
- unstyled: {
58
- false: {
59
- size: "$7"
60
- }
61
- }
62
- },
63
- defaultVariants: {
64
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
65
- }
66
- }),
67
- H5 = styled(Heading, {
68
- name: "H5",
69
- render: "h5",
70
- variants: {
71
- unstyled: {
72
- false: {
73
- size: "$6"
74
- }
75
- }
76
- },
77
- defaultVariants: {
78
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
79
- }
80
- }),
81
- H6 = styled(Heading, {
82
- name: "H6",
83
- render: "h6",
84
- variants: {
85
- unstyled: {
86
- false: {
87
- size: "$5"
88
- }
89
- }
90
- },
91
- defaultVariants: {
92
- unstyled: process.env.HANZO_GUI_HEADLESS === "1"
93
- }
94
- });
95
- export { H1, H2, H3, H4, H5, H6, Heading };
96
- //# sourceMappingURL=Headings.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["styled","Paragraph","Heading","render","name","role","fontFamily","size","margin","H1","variants","unstyled","false","defaultVariants","process","env","HANZO_GUI_HEADLESS","H2","H3","H4","H5","H6"],"sources":["../../src/Headings.tsx"],"sourcesContent":[null],"mappings":"AACA,SAASA,MAAA,QAAc;AAEvB,SAASC,SAAA,QAAiB;AAEnB,IAAAC,OAAM,GAAAF,MAAU,CAAAC,SAAO;IAC5BE,MAAA,EAAQ;IACRC,IAAA,EAAM;IACNC,IAAA,EAAM;IACNC,UAAA,EAAY;IACZC,IAAA,EAAM;IACNC,MAAA,EAAQ;EACV,CAAC;EAIYC,EAAA,GAAKT,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYC,EAAA,GAAKjB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYE,EAAA,GAAKlB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYG,EAAA,GAAKnB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYI,EAAA,GAAKpB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC;EAEYK,EAAA,GAAKrB,MAAA,CAAOE,OAAA,EAAS;IAChCE,IAAA,EAAM;IACND,MAAA,EAAQ;IAERO,QAAA,EAAU;MACRC,QAAA,EAAU;QACRC,KAAA,EAAO;UACLL,IAAA,EAAM;QACR;MACF;IACF;IAEAM,eAAA,EAAiB;MACfF,QAAA,EAAUG,OAAA,CAAQC,GAAA,CAAIC,kBAAA,KAAuB;IAC/C;EACF,CAAC","ignoreList":[]}
@@ -1,12 +0,0 @@
1
- import { styled } from "@hanzogui/web";
2
- import { SizableText } from "./SizableText.mjs";
3
- const Paragraph = styled(SizableText, {
4
- name: "Paragraph",
5
- render: "p",
6
- userSelect: "auto",
7
- color: "$color",
8
- size: "$true",
9
- whiteSpace: "normal"
10
- });
11
- export { Paragraph };
12
- //# sourceMappingURL=Paragraph.mjs.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["styled","SizableText","Paragraph","name","render","userSelect","color","size","whiteSpace"],"sources":["../../src/Paragraph.tsx"],"sourcesContent":[null],"mappings":"AACA,SAASA,MAAA,QAAc;AAEvB,SAASC,WAAA,QAAmB;AAErB,MAAMC,SAAA,GAAYF,MAAA,CAAOC,WAAA,EAAa;EAC3CE,IAAA,EAAM;EACNC,MAAA,EAAQ;EACRC,UAAA,EAAY;EACZC,KAAA,EAAO;EACPC,IAAA,EAAM;EACNC,UAAA,EAAY;AACd,CAAC","ignoreList":[]}
@@ -1,12 +0,0 @@
1
- import { styled } from "@hanzogui/web";
2
- import { SizableText } from "./SizableText.native.js";
3
- var Paragraph = styled(SizableText, {
4
- name: "Paragraph",
5
- render: "p",
6
- userSelect: "auto",
7
- color: "$color",
8
- size: "$true",
9
- whiteSpace: "normal"
10
- });
11
- export { Paragraph };
12
- //# sourceMappingURL=Paragraph.native.js.map
@@ -1 +0,0 @@
1
- {"version":3,"names":["styled","SizableText","Paragraph","name","render","userSelect","color","size","whiteSpace"],"sources":["../../src/Paragraph.tsx"],"sourcesContent":[null],"mappings":"AACA,SAASA,MAAA,QAAc;AAEvB,SAASC,WAAA,QAAmB;AAErB,IAAAC,SAAM,GAAAF,MAAY,CAAAC,WAAO;EAC9BE,IAAA,EAAM;EACNC,MAAA,EAAQ;EACRC,UAAA,EAAY;EACZC,KAAA,EAAO;EACPC,IAAA,EAAM;EACNC,UAAA,EAAY;AACd,CAAC","ignoreList":[]}