@hanzogui/themes 2.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 (324) hide show
  1. package/LICENSE +21 -0
  2. package/dist/cjs/componentThemeDefinitions.cjs +124 -0
  3. package/dist/cjs/componentThemeDefinitions.native.js +127 -0
  4. package/dist/cjs/componentThemeDefinitions.native.js.map +1 -0
  5. package/dist/cjs/generated-new.cjs +2021 -0
  6. package/dist/cjs/generated-new.native.js +2040 -0
  7. package/dist/cjs/generated-new.native.js.map +1 -0
  8. package/dist/cjs/generated-v3.cjs +1099 -0
  9. package/dist/cjs/generated-v3.native.js +1118 -0
  10. package/dist/cjs/generated-v3.native.js.map +1 -0
  11. package/dist/cjs/generated-v4-gui.cjs +933 -0
  12. package/dist/cjs/generated-v4-gui.native.js +952 -0
  13. package/dist/cjs/generated-v4-gui.native.js.map +1 -0
  14. package/dist/cjs/generated-v4.cjs +391 -0
  15. package/dist/cjs/generated-v4.native.js +410 -0
  16. package/dist/cjs/generated-v4.native.js.map +1 -0
  17. package/dist/cjs/generated-v5-subtle.cjs +549 -0
  18. package/dist/cjs/generated-v5-subtle.native.js +568 -0
  19. package/dist/cjs/generated-v5-subtle.native.js.map +1 -0
  20. package/dist/cjs/generated-v5.cjs +549 -0
  21. package/dist/cjs/generated-v5.native.js +568 -0
  22. package/dist/cjs/generated-v5.native.js.map +1 -0
  23. package/dist/cjs/helpers.cjs +34 -0
  24. package/dist/cjs/helpers.native.js +39 -0
  25. package/dist/cjs/helpers.native.js.map +1 -0
  26. package/dist/cjs/index.cjs +25 -0
  27. package/dist/cjs/index.native.js +28 -0
  28. package/dist/cjs/index.native.js.map +1 -0
  29. package/dist/cjs/opacify.cjs +96 -0
  30. package/dist/cjs/opacify.native.js +106 -0
  31. package/dist/cjs/opacify.native.js.map +1 -0
  32. package/dist/cjs/palettes.cjs +52 -0
  33. package/dist/cjs/palettes.native.js +63 -0
  34. package/dist/cjs/palettes.native.js.map +1 -0
  35. package/dist/cjs/shadows.cjs +43 -0
  36. package/dist/cjs/shadows.native.js +46 -0
  37. package/dist/cjs/shadows.native.js.map +1 -0
  38. package/dist/cjs/subtleChildrenThemes.cjs +65 -0
  39. package/dist/cjs/subtleChildrenThemes.native.js +74 -0
  40. package/dist/cjs/subtleChildrenThemes.native.js.map +1 -0
  41. package/dist/cjs/templates.cjs +118 -0
  42. package/dist/cjs/templates.native.js +121 -0
  43. package/dist/cjs/templates.native.js.map +1 -0
  44. package/dist/cjs/themes-new.cjs +86 -0
  45. package/dist/cjs/themes-new.native.js +88 -0
  46. package/dist/cjs/themes-new.native.js.map +1 -0
  47. package/dist/cjs/themes-old.cjs +284 -0
  48. package/dist/cjs/themes-old.native.js +303 -0
  49. package/dist/cjs/themes-old.native.js.map +1 -0
  50. package/dist/cjs/themes.cjs +26 -0
  51. package/dist/cjs/themes.native.js +29 -0
  52. package/dist/cjs/themes.native.js.map +1 -0
  53. package/dist/cjs/tokens.cjs +155 -0
  54. package/dist/cjs/tokens.native.js +167 -0
  55. package/dist/cjs/tokens.native.js.map +1 -0
  56. package/dist/cjs/utils.cjs +40 -0
  57. package/dist/cjs/utils.native.js +46 -0
  58. package/dist/cjs/utils.native.js.map +1 -0
  59. package/dist/cjs/v3-themes.cjs +472 -0
  60. package/dist/cjs/v3-themes.native.js +487 -0
  61. package/dist/cjs/v3-themes.native.js.map +1 -0
  62. package/dist/cjs/v3-tokens.cjs +99 -0
  63. package/dist/cjs/v3-tokens.native.js +108 -0
  64. package/dist/cjs/v3-tokens.native.js.map +1 -0
  65. package/dist/cjs/v3.cjs +52 -0
  66. package/dist/cjs/v3.native.js +55 -0
  67. package/dist/cjs/v3.native.js.map +1 -0
  68. package/dist/cjs/v4-default.cjs +167 -0
  69. package/dist/cjs/v4-default.native.js +170 -0
  70. package/dist/cjs/v4-default.native.js.map +1 -0
  71. package/dist/cjs/v4-gui.cjs +235 -0
  72. package/dist/cjs/v4-gui.native.js +243 -0
  73. package/dist/cjs/v4-gui.native.js.map +1 -0
  74. package/dist/cjs/v4-tokens.cjs +99 -0
  75. package/dist/cjs/v4-tokens.native.js +108 -0
  76. package/dist/cjs/v4-tokens.native.js.map +1 -0
  77. package/dist/cjs/v4.cjs +32 -0
  78. package/dist/cjs/v4.native.js +35 -0
  79. package/dist/cjs/v4.native.js.map +1 -0
  80. package/dist/cjs/v5-subtle.cjs +34 -0
  81. package/dist/cjs/v5-subtle.native.js +37 -0
  82. package/dist/cjs/v5-subtle.native.js.map +1 -0
  83. package/dist/cjs/v5-templates.cjs +110 -0
  84. package/dist/cjs/v5-templates.native.js +126 -0
  85. package/dist/cjs/v5-templates.native.js.map +1 -0
  86. package/dist/cjs/v5-themes-subtle.cjs +37 -0
  87. package/dist/cjs/v5-themes-subtle.native.js +40 -0
  88. package/dist/cjs/v5-themes-subtle.native.js.map +1 -0
  89. package/dist/cjs/v5-themes.cjs +400 -0
  90. package/dist/cjs/v5-themes.native.js +445 -0
  91. package/dist/cjs/v5-themes.native.js.map +1 -0
  92. package/dist/cjs/v5-tokens.cjs +99 -0
  93. package/dist/cjs/v5-tokens.native.js +108 -0
  94. package/dist/cjs/v5-tokens.native.js.map +1 -0
  95. package/dist/cjs/v5.cjs +34 -0
  96. package/dist/cjs/v5.native.js +37 -0
  97. package/dist/cjs/v5.native.js.map +1 -0
  98. package/dist/esm/componentThemeDefinitions.mjs +100 -0
  99. package/dist/esm/componentThemeDefinitions.mjs.map +1 -0
  100. package/dist/esm/componentThemeDefinitions.native.js +100 -0
  101. package/dist/esm/componentThemeDefinitions.native.js.map +1 -0
  102. package/dist/esm/generated-new.mjs +1997 -0
  103. package/dist/esm/generated-new.mjs.map +1 -0
  104. package/dist/esm/generated-new.native.js +2013 -0
  105. package/dist/esm/generated-new.native.js.map +1 -0
  106. package/dist/esm/generated-v3.mjs +1075 -0
  107. package/dist/esm/generated-v3.mjs.map +1 -0
  108. package/dist/esm/generated-v3.native.js +1091 -0
  109. package/dist/esm/generated-v3.native.js.map +1 -0
  110. package/dist/esm/generated-v4-gui.mjs +909 -0
  111. package/dist/esm/generated-v4-gui.mjs.map +1 -0
  112. package/dist/esm/generated-v4-gui.native.js +925 -0
  113. package/dist/esm/generated-v4-gui.native.js.map +1 -0
  114. package/dist/esm/generated-v4.mjs +367 -0
  115. package/dist/esm/generated-v4.mjs.map +1 -0
  116. package/dist/esm/generated-v4.native.js +383 -0
  117. package/dist/esm/generated-v4.native.js.map +1 -0
  118. package/dist/esm/generated-v5-subtle.mjs +525 -0
  119. package/dist/esm/generated-v5-subtle.mjs.map +1 -0
  120. package/dist/esm/generated-v5-subtle.native.js +541 -0
  121. package/dist/esm/generated-v5-subtle.native.js.map +1 -0
  122. package/dist/esm/generated-v5.mjs +525 -0
  123. package/dist/esm/generated-v5.mjs.map +1 -0
  124. package/dist/esm/generated-v5.native.js +541 -0
  125. package/dist/esm/generated-v5.native.js.map +1 -0
  126. package/dist/esm/helpers.mjs +9 -0
  127. package/dist/esm/helpers.mjs.map +1 -0
  128. package/dist/esm/helpers.native.js +11 -0
  129. package/dist/esm/helpers.native.js.map +1 -0
  130. package/dist/esm/index.js +9 -0
  131. package/dist/esm/index.js.map +1 -0
  132. package/dist/esm/index.mjs +9 -0
  133. package/dist/esm/index.mjs.map +1 -0
  134. package/dist/esm/index.native.js +9 -0
  135. package/dist/esm/index.native.js.map +1 -0
  136. package/dist/esm/opacify.mjs +72 -0
  137. package/dist/esm/opacify.mjs.map +1 -0
  138. package/dist/esm/opacify.native.js +79 -0
  139. package/dist/esm/opacify.native.js.map +1 -0
  140. package/dist/esm/palettes.mjs +29 -0
  141. package/dist/esm/palettes.mjs.map +1 -0
  142. package/dist/esm/palettes.native.js +37 -0
  143. package/dist/esm/palettes.native.js.map +1 -0
  144. package/dist/esm/shadows.mjs +20 -0
  145. package/dist/esm/shadows.mjs.map +1 -0
  146. package/dist/esm/shadows.native.js +20 -0
  147. package/dist/esm/shadows.native.js.map +1 -0
  148. package/dist/esm/subtleChildrenThemes.mjs +41 -0
  149. package/dist/esm/subtleChildrenThemes.mjs.map +1 -0
  150. package/dist/esm/subtleChildrenThemes.native.js +47 -0
  151. package/dist/esm/subtleChildrenThemes.native.js.map +1 -0
  152. package/dist/esm/templates.mjs +94 -0
  153. package/dist/esm/templates.mjs.map +1 -0
  154. package/dist/esm/templates.native.js +94 -0
  155. package/dist/esm/templates.native.js.map +1 -0
  156. package/dist/esm/themes-new.mjs +63 -0
  157. package/dist/esm/themes-new.mjs.map +1 -0
  158. package/dist/esm/themes-new.native.js +62 -0
  159. package/dist/esm/themes-new.native.js.map +1 -0
  160. package/dist/esm/themes-old.mjs +261 -0
  161. package/dist/esm/themes-old.mjs.map +1 -0
  162. package/dist/esm/themes-old.native.js +277 -0
  163. package/dist/esm/themes-old.native.js.map +1 -0
  164. package/dist/esm/themes.mjs +3 -0
  165. package/dist/esm/themes.mjs.map +1 -0
  166. package/dist/esm/themes.native.js +3 -0
  167. package/dist/esm/themes.native.js.map +1 -0
  168. package/dist/esm/tokens.mjs +124 -0
  169. package/dist/esm/tokens.mjs.map +1 -0
  170. package/dist/esm/tokens.native.js +133 -0
  171. package/dist/esm/tokens.native.js.map +1 -0
  172. package/dist/esm/utils.mjs +14 -0
  173. package/dist/esm/utils.mjs.map +1 -0
  174. package/dist/esm/utils.native.js +17 -0
  175. package/dist/esm/utils.native.js.map +1 -0
  176. package/dist/esm/v3-themes.mjs +444 -0
  177. package/dist/esm/v3-themes.mjs.map +1 -0
  178. package/dist/esm/v3-themes.native.js +456 -0
  179. package/dist/esm/v3-themes.native.js.map +1 -0
  180. package/dist/esm/v3-tokens.mjs +70 -0
  181. package/dist/esm/v3-tokens.mjs.map +1 -0
  182. package/dist/esm/v3-tokens.native.js +76 -0
  183. package/dist/esm/v3-tokens.native.js.map +1 -0
  184. package/dist/esm/v3.mjs +12 -0
  185. package/dist/esm/v3.mjs.map +1 -0
  186. package/dist/esm/v3.native.js +12 -0
  187. package/dist/esm/v3.native.js.map +1 -0
  188. package/dist/esm/v4-default.mjs +133 -0
  189. package/dist/esm/v4-default.mjs.map +1 -0
  190. package/dist/esm/v4-default.native.js +133 -0
  191. package/dist/esm/v4-default.native.js.map +1 -0
  192. package/dist/esm/v4-gui.mjs +201 -0
  193. package/dist/esm/v4-gui.mjs.map +1 -0
  194. package/dist/esm/v4-gui.native.js +206 -0
  195. package/dist/esm/v4-gui.native.js.map +1 -0
  196. package/dist/esm/v4-tokens.mjs +70 -0
  197. package/dist/esm/v4-tokens.mjs.map +1 -0
  198. package/dist/esm/v4-tokens.native.js +76 -0
  199. package/dist/esm/v4-tokens.native.js.map +1 -0
  200. package/dist/esm/v4.mjs +6 -0
  201. package/dist/esm/v4.mjs.map +1 -0
  202. package/dist/esm/v4.native.js +6 -0
  203. package/dist/esm/v4.native.js.map +1 -0
  204. package/dist/esm/v5-subtle.mjs +7 -0
  205. package/dist/esm/v5-subtle.mjs.map +1 -0
  206. package/dist/esm/v5-subtle.native.js +7 -0
  207. package/dist/esm/v5-subtle.native.js.map +1 -0
  208. package/dist/esm/v5-templates.mjs +87 -0
  209. package/dist/esm/v5-templates.mjs.map +1 -0
  210. package/dist/esm/v5-templates.native.js +100 -0
  211. package/dist/esm/v5-templates.native.js.map +1 -0
  212. package/dist/esm/v5-themes-subtle.mjs +13 -0
  213. package/dist/esm/v5-themes-subtle.mjs.map +1 -0
  214. package/dist/esm/v5-themes-subtle.native.js +13 -0
  215. package/dist/esm/v5-themes-subtle.native.js.map +1 -0
  216. package/dist/esm/v5-themes.mjs +361 -0
  217. package/dist/esm/v5-themes.mjs.map +1 -0
  218. package/dist/esm/v5-themes.native.js +403 -0
  219. package/dist/esm/v5-themes.native.js.map +1 -0
  220. package/dist/esm/v5-tokens.mjs +70 -0
  221. package/dist/esm/v5-tokens.mjs.map +1 -0
  222. package/dist/esm/v5-tokens.native.js +76 -0
  223. package/dist/esm/v5-tokens.native.js.map +1 -0
  224. package/dist/esm/v5.mjs +7 -0
  225. package/dist/esm/v5.mjs.map +1 -0
  226. package/dist/esm/v5.native.js +7 -0
  227. package/dist/esm/v5.native.js.map +1 -0
  228. package/package.json +95 -0
  229. package/src/componentThemeDefinitions.tsx +129 -0
  230. package/src/generated-new.ts +2571 -0
  231. package/src/generated-v3.ts +1826 -0
  232. package/src/generated-v4-gui.ts +2200 -0
  233. package/src/generated-v4.ts +1004 -0
  234. package/src/generated-v5-subtle.ts +2170 -0
  235. package/src/generated-v5.ts +2188 -0
  236. package/src/helpers.ts +44 -0
  237. package/src/index.tsx +8 -0
  238. package/src/opacify.ts +125 -0
  239. package/src/palettes.tsx +91 -0
  240. package/src/shadows.tsx +19 -0
  241. package/src/subtleChildrenThemes.ts +54 -0
  242. package/src/templates.tsx +104 -0
  243. package/src/themes-new.ts +74 -0
  244. package/src/themes-old.tsx +378 -0
  245. package/src/themes.tsx +1 -0
  246. package/src/tokens.tsx +199 -0
  247. package/src/utils.ts +51 -0
  248. package/src/v3-themes.ts +650 -0
  249. package/src/v3-tokens.ts +103 -0
  250. package/src/v3.tsx +12 -0
  251. package/src/v4-default.ts +191 -0
  252. package/src/v4-gui.ts +287 -0
  253. package/src/v4-tokens.ts +105 -0
  254. package/src/v4.tsx +4 -0
  255. package/src/v5-subtle.tsx +11 -0
  256. package/src/v5-templates.ts +126 -0
  257. package/src/v5-themes-subtle.ts +18 -0
  258. package/src/v5-themes.ts +626 -0
  259. package/src/v5-tokens.ts +107 -0
  260. package/src/v5.tsx +11 -0
  261. package/tests/v5-themes.test.ts +215 -0
  262. package/tsconfig.json +43 -0
  263. package/types/componentThemeDefinitions.d.ts +771 -0
  264. package/types/generated-new.d.ts +135 -0
  265. package/types/generated-v3.d.ts +144 -0
  266. package/types/generated-v4-gui.d.ts +190 -0
  267. package/types/generated-v4.d.ts +137 -0
  268. package/types/generated-v5-subtle.d.ts +244 -0
  269. package/types/generated-v5.d.ts +244 -0
  270. package/types/helpers.d.ts +24 -0
  271. package/types/index.d.ts +9 -0
  272. package/types/opacify.d.ts +9 -0
  273. package/types/palettes.d.ts +21 -0
  274. package/types/shadows.d.ts +15 -0
  275. package/types/subtleChildrenThemes.d.ts +305 -0
  276. package/types/templates.d.ts +155 -0
  277. package/types/themes-new.d.ts +42243 -0
  278. package/types/themes-old.d.ts +51411 -0
  279. package/types/themes.d.ts +2 -0
  280. package/types/tokens.d.ts +1308 -0
  281. package/types/utils.d.ts +21 -0
  282. package/types/v3-themes.d.ts +16304 -0
  283. package/types/v3-tokens.d.ts +184 -0
  284. package/types/v3.d.ts +11 -0
  285. package/types/v4-default.d.ts +274 -0
  286. package/types/v4-gui.d.ts +195 -0
  287. package/types/v4-tokens.d.ts +184 -0
  288. package/types/v4.d.ts +5 -0
  289. package/types/v5-subtle.d.ts +8 -0
  290. package/types/v5-templates.d.ts +42 -0
  291. package/types/v5-themes-subtle.d.ts +250 -0
  292. package/types/v5-themes.d.ts +752 -0
  293. package/types/v5-tokens.d.ts +185 -0
  294. package/types/v5.d.ts +8 -0
  295. package/v3/index.cjs +2 -0
  296. package/v3/index.js +2 -0
  297. package/v3/index.native.cjs +2 -0
  298. package/v3/index.native.js +2 -0
  299. package/v3-themes/index.cjs +2 -0
  300. package/v3-themes/index.js +2 -0
  301. package/v3-themes/index.native.cjs +2 -0
  302. package/v3-themes/index.native.js +2 -0
  303. package/v3-themes.cjs +1 -0
  304. package/v3-themes.d.ts +1 -0
  305. package/v3.cjs +1 -0
  306. package/v3.d.ts +1 -0
  307. package/v4/index.cjs +2 -0
  308. package/v4/index.js +2 -0
  309. package/v4/index.native.cjs +2 -0
  310. package/v4/index.native.js +2 -0
  311. package/v4.cjs +1 -0
  312. package/v4.d.ts +1 -0
  313. package/v5/index.cjs +2 -0
  314. package/v5/index.js +2 -0
  315. package/v5/index.native.cjs +2 -0
  316. package/v5/index.native.js +2 -0
  317. package/v5-subtle/index.cjs +2 -0
  318. package/v5-subtle/index.js +2 -0
  319. package/v5-subtle/index.native.cjs +2 -0
  320. package/v5-subtle/index.native.js +2 -0
  321. package/v5-subtle.cjs +1 -0
  322. package/v5-subtle.d.ts +1 -0
  323. package/v5.cjs +1 -0
  324. package/v5.d.ts +1 -0
@@ -0,0 +1,472 @@
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 v3_themes_exports = {};
22
+ __export(v3_themes_exports, {
23
+ defaultComponentThemes: () => defaultComponentThemes,
24
+ defaultPalettes: () => defaultPalettes,
25
+ defaultSubThemes: () => defaultSubThemes,
26
+ defaultTemplates: () => defaultTemplates,
27
+ themes: () => themes,
28
+ tokens: () => tokens
29
+ });
30
+ module.exports = __toCommonJS(v3_themes_exports);
31
+ var import_legacy = require("@hanzogui/colors/legacy"),
32
+ import_theme_builder = require("@hanzogui/theme-builder"),
33
+ import_web = require("@hanzogui/web"),
34
+ import_utils = require("./utils.cjs"),
35
+ import_v3_tokens = require("./v3-tokens.cjs");
36
+ const colorTokens = {
37
+ light: {
38
+ blue: import_legacy.blue,
39
+ gray: import_legacy.gray,
40
+ green: import_legacy.green,
41
+ orange: import_legacy.orange,
42
+ pink: import_legacy.pink,
43
+ purple: import_legacy.purple,
44
+ red: import_legacy.red,
45
+ yellow: import_legacy.yellow
46
+ },
47
+ dark: {
48
+ blue: import_legacy.blueDark,
49
+ gray: import_legacy.grayDark,
50
+ green: import_legacy.greenDark,
51
+ orange: import_legacy.orangeDark,
52
+ pink: import_legacy.pinkDark,
53
+ purple: import_legacy.purpleDark,
54
+ red: import_legacy.redDark,
55
+ yellow: import_legacy.yellowDark
56
+ }
57
+ },
58
+ lightShadowColor = "rgba(0,0,0,0.04)",
59
+ lightShadowColorStrong = "rgba(0,0,0,0.085)",
60
+ darkShadowColor = "rgba(0,0,0,0.2)",
61
+ darkShadowColorStrong = "rgba(0,0,0,0.3)",
62
+ darkColors = {
63
+ ...colorTokens.dark.blue,
64
+ ...colorTokens.dark.gray,
65
+ ...colorTokens.dark.green,
66
+ ...colorTokens.dark.orange,
67
+ ...colorTokens.dark.pink,
68
+ ...colorTokens.dark.purple,
69
+ ...colorTokens.dark.red,
70
+ ...colorTokens.dark.yellow
71
+ },
72
+ lightColors = {
73
+ ...colorTokens.light.blue,
74
+ ...colorTokens.light.gray,
75
+ ...colorTokens.light.green,
76
+ ...colorTokens.light.orange,
77
+ ...colorTokens.light.pink,
78
+ ...colorTokens.light.purple,
79
+ ...colorTokens.light.red,
80
+ ...colorTokens.light.yellow
81
+ },
82
+ color = {
83
+ white0: "rgba(255,255,255,0)",
84
+ white075: "rgba(255,255,255,0.75)",
85
+ white05: "rgba(255,255,255,0.5)",
86
+ white025: "rgba(255,255,255,0.25)",
87
+ black0: "rgba(10,10,10,0)",
88
+ black075: "rgba(10,10,10,0.75)",
89
+ black05: "rgba(10,10,10,0.5)",
90
+ black025: "rgba(10,10,10,0.25)",
91
+ white1: "#fff",
92
+ white2: "#f8f8f8",
93
+ white3: "hsl(0, 0%, 96.3%)",
94
+ white4: "hsl(0, 0%, 94.1%)",
95
+ white5: "hsl(0, 0%, 92.0%)",
96
+ white6: "hsl(0, 0%, 90.0%)",
97
+ white7: "hsl(0, 0%, 88.5%)",
98
+ white8: "hsl(0, 0%, 81.0%)",
99
+ white9: "hsl(0, 0%, 56.1%)",
100
+ white10: "hsl(0, 0%, 50.3%)",
101
+ white11: "hsl(0, 0%, 42.5%)",
102
+ white12: "hsl(0, 0%, 9.0%)",
103
+ black1: "#050505",
104
+ black2: "#151515",
105
+ black3: "#191919",
106
+ black4: "#232323",
107
+ black5: "#282828",
108
+ black6: "#323232",
109
+ black7: "#424242",
110
+ black8: "#494949",
111
+ black9: "#545454",
112
+ black10: "#626262",
113
+ black11: "#a5a5a5",
114
+ black12: "#fff",
115
+ ...(0, import_utils.postfixObjKeys)(lightColors, "Light"),
116
+ ...(0, import_utils.postfixObjKeys)(darkColors, "Dark")
117
+ },
118
+ defaultPalettes = (() => {
119
+ const transparent = (hsl, opacity = 0) => hsl.replace("%)", `%, ${opacity})`).replace("hsl(", "hsla("),
120
+ getColorPalette = (colors, accentColors) => {
121
+ const colorPalette = Object.values(colors),
122
+ colorI = colorPalette.length - 4,
123
+ accentPalette = Object.values(accentColors),
124
+ accentBackground = accentPalette[0],
125
+ accentColor = accentPalette[accentPalette.length - 1];
126
+ return [accentBackground, transparent(colorPalette[0], 0), transparent(colorPalette[0], 0.25), transparent(colorPalette[0], 0.5), transparent(colorPalette[0], 0.75), ...colorPalette, transparent(colorPalette[colorI], 0.75), transparent(colorPalette[colorI], 0.5), transparent(colorPalette[colorI], 0.25), transparent(colorPalette[colorI], 0), accentColor];
127
+ },
128
+ brandColor = {
129
+ light: color.blue4Light,
130
+ dark: color.blue4Dark
131
+ },
132
+ lightPalette = [brandColor.light, color.white0, color.white025, color.white05, color.white075, color.white1, color.white2, color.white3, color.white4, color.white5, color.white6, color.white7, color.white8, color.white9, color.white10, color.white11, color.white12, color.black075, color.black05, color.black025, color.black0, brandColor.dark],
133
+ darkPalette = [brandColor.dark, color.black0, color.black025, color.black05, color.black075, color.black1, color.black2, color.black3, color.black4, color.black5, color.black6, color.black7, color.black8, color.black9, color.black10, color.black11, color.black12, color.white075, color.white05, color.white025, color.white0, brandColor.light],
134
+ lightColorNames = (0, import_utils.objectKeys)(colorTokens.light),
135
+ lightPalettes = (0, import_theme_builder.objectFromEntries)(lightColorNames.map((key, index) => [`light_${key}`, getColorPalette(colorTokens.light[key], colorTokens.light[lightColorNames[(index + 1) % lightColorNames.length]])])),
136
+ darkColorNames = (0, import_utils.objectKeys)(colorTokens.dark),
137
+ darkPalettes = (0, import_theme_builder.objectFromEntries)(darkColorNames.map((key, index) => [`dark_${key}`, getColorPalette(colorTokens.dark[key], colorTokens.dark[darkColorNames[(index + 1) % darkColorNames.length]])])),
138
+ colorPalettes = {
139
+ ...lightPalettes,
140
+ ...darkPalettes
141
+ };
142
+ return {
143
+ light: lightPalette,
144
+ dark: darkPalette,
145
+ ...colorPalettes
146
+ };
147
+ })(),
148
+ getTemplates = () => {
149
+ const getBaseTemplates = scheme => {
150
+ const isLight = scheme === "light",
151
+ bgIndex = 5,
152
+ lighten = isLight ? -1 : 1,
153
+ darken = -lighten,
154
+ borderColor = bgIndex + 3,
155
+ base = {
156
+ accentBackground: 0,
157
+ accentColor: -0,
158
+ background0: 1,
159
+ background025: 2,
160
+ background05: 3,
161
+ background075: 4,
162
+ color1: bgIndex,
163
+ color2: bgIndex + 1,
164
+ color3: bgIndex + 2,
165
+ color4: bgIndex + 3,
166
+ color5: bgIndex + 4,
167
+ color6: bgIndex + 5,
168
+ color7: bgIndex + 6,
169
+ color8: bgIndex + 7,
170
+ color9: bgIndex + 8,
171
+ color10: bgIndex + 9,
172
+ color11: bgIndex + 10,
173
+ color12: bgIndex + 11,
174
+ color0: -1,
175
+ color025: -2,
176
+ color05: -3,
177
+ color075: -4,
178
+ // the background, color, etc keys here work like generics - they make it so you
179
+ // can publish components for others to use without mandating a specific color scale
180
+ // the @hanzogui/button Button component looks for `$background`, so you set the
181
+ // dark_red_Button theme to have a stronger background than the dark_red theme.
182
+ background: bgIndex,
183
+ backgroundHover: bgIndex + lighten,
184
+ // always lighten on hover no matter the scheme
185
+ backgroundPress: bgIndex + darken,
186
+ // always darken on press no matter the theme
187
+ backgroundFocus: bgIndex + darken,
188
+ borderColor,
189
+ borderColorHover: borderColor + lighten,
190
+ borderColorPress: borderColor + darken,
191
+ borderColorFocus: borderColor,
192
+ color: -bgIndex,
193
+ colorHover: -bgIndex - 1,
194
+ colorPress: -bgIndex,
195
+ colorFocus: -bgIndex - 1,
196
+ colorTransparent: -1,
197
+ placeholderColor: -bgIndex - 3,
198
+ outlineColor: -2
199
+ },
200
+ surface12 = {
201
+ background: base.background + 1,
202
+ backgroundHover: base.backgroundHover + 1,
203
+ backgroundPress: base.backgroundPress + 1,
204
+ backgroundFocus: base.backgroundFocus + 1,
205
+ borderColor: base.borderColor + 1,
206
+ borderColorHover: base.borderColorHover + 1,
207
+ borderColorFocus: base.borderColorFocus + 1,
208
+ borderColorPress: base.borderColorPress + 1
209
+ },
210
+ surface22 = {
211
+ background: base.background + 2,
212
+ backgroundHover: base.backgroundHover + 2,
213
+ backgroundPress: base.backgroundPress + 2,
214
+ backgroundFocus: base.backgroundFocus + 2,
215
+ borderColor: base.borderColor + 2,
216
+ borderColorHover: base.borderColorHover + 2,
217
+ borderColorFocus: base.borderColorFocus + 2,
218
+ borderColorPress: base.borderColorPress + 2
219
+ },
220
+ surface32 = {
221
+ background: base.background + 3,
222
+ backgroundHover: base.backgroundHover + 3,
223
+ backgroundPress: base.backgroundPress + 3,
224
+ backgroundFocus: base.backgroundFocus + 3,
225
+ borderColor: base.borderColor + 3,
226
+ borderColorHover: base.borderColorHover + 3,
227
+ borderColorFocus: base.borderColorFocus + 3,
228
+ borderColorPress: base.borderColorPress + 3
229
+ },
230
+ surfaceActiveBg = {
231
+ background: base.background + 5,
232
+ backgroundHover: base.background + 5,
233
+ backgroundPress: base.backgroundPress + 5,
234
+ backgroundFocus: base.backgroundFocus + 5
235
+ },
236
+ surfaceActive = {
237
+ ...surfaceActiveBg,
238
+ // match border to background when active
239
+ borderColor: surfaceActiveBg.background,
240
+ borderColorHover: surfaceActiveBg.backgroundHover,
241
+ borderColorFocus: surfaceActiveBg.backgroundFocus,
242
+ borderColorPress: surfaceActiveBg.backgroundPress
243
+ },
244
+ inverseSurface12 = {
245
+ color: surface12.background,
246
+ colorHover: surface12.backgroundHover,
247
+ colorPress: surface12.backgroundPress,
248
+ colorFocus: surface12.backgroundFocus,
249
+ background: base.color,
250
+ backgroundHover: base.colorHover,
251
+ backgroundPress: base.colorPress,
252
+ backgroundFocus: base.colorFocus,
253
+ borderColor: base.color - 2,
254
+ borderColorHover: base.color - 3,
255
+ borderColorFocus: base.color - 4,
256
+ borderColorPress: base.color - 5
257
+ },
258
+ inverseActive = {
259
+ ...inverseSurface12,
260
+ background: base.color - 2,
261
+ backgroundHover: base.colorHover - 2,
262
+ backgroundPress: base.colorPress - 2,
263
+ backgroundFocus: base.colorFocus - 2,
264
+ borderColor: base.color - 2 - 2,
265
+ borderColorHover: base.color - 3 - 2,
266
+ borderColorFocus: base.color - 4 - 2,
267
+ borderColorPress: base.color - 5 - 2
268
+ },
269
+ alt1 = {
270
+ color: base.color - 1,
271
+ colorHover: base.colorHover - 1,
272
+ colorPress: base.colorPress - 1,
273
+ colorFocus: base.colorFocus - 1
274
+ },
275
+ alt2 = {
276
+ color: base.color - 2,
277
+ colorHover: base.colorHover - 2,
278
+ colorPress: base.colorPress - 2,
279
+ colorFocus: base.colorFocus - 2
280
+ };
281
+ return {
282
+ base,
283
+ alt1,
284
+ alt2,
285
+ surface1: surface12,
286
+ surface2: surface22,
287
+ surface3: surface32,
288
+ inverseSurface1: inverseSurface12,
289
+ inverseActive,
290
+ surfaceActive
291
+ };
292
+ },
293
+ lightTemplates = getBaseTemplates("light"),
294
+ darkTemplates = getBaseTemplates("dark");
295
+ return {
296
+ ...(0, import_theme_builder.objectFromEntries)((0, import_utils.objectKeys)(lightTemplates).map(name => [`light_${name}`, lightTemplates[name]])),
297
+ ...(0, import_theme_builder.objectFromEntries)((0, import_utils.objectKeys)(darkTemplates).map(name => [`dark_${name}`, darkTemplates[name]]))
298
+ };
299
+ },
300
+ defaultTemplates = getTemplates(),
301
+ shadows = {
302
+ light: {
303
+ shadowColor: lightShadowColorStrong,
304
+ shadowColorHover: lightShadowColorStrong,
305
+ shadowColorPress: lightShadowColor,
306
+ shadowColorFocus: lightShadowColor
307
+ },
308
+ dark: {
309
+ shadowColor: darkShadowColorStrong,
310
+ shadowColorHover: darkShadowColorStrong,
311
+ shadowColorPress: darkShadowColor,
312
+ shadowColorFocus: darkShadowColor
313
+ }
314
+ },
315
+ nonInherited = {
316
+ light: {
317
+ ...lightColors,
318
+ ...shadows.light
319
+ },
320
+ dark: {
321
+ ...darkColors,
322
+ ...shadows.dark
323
+ }
324
+ },
325
+ overlayThemeDefinitions = [{
326
+ parent: "light",
327
+ theme: {
328
+ background: "rgba(0,0,0,0.5)"
329
+ }
330
+ }, {
331
+ parent: "dark",
332
+ theme: {
333
+ background: "rgba(0,0,0,0.8)"
334
+ }
335
+ }],
336
+ inverseSurface1 = [{
337
+ parent: "active",
338
+ template: "inverseActive"
339
+ }, {
340
+ parent: "",
341
+ template: "inverseSurface1"
342
+ }],
343
+ surface1 = [{
344
+ parent: "active",
345
+ template: "surfaceActive"
346
+ }, {
347
+ parent: "",
348
+ template: "surface1"
349
+ }],
350
+ surface2 = [{
351
+ parent: "active",
352
+ template: "surfaceActive"
353
+ }, {
354
+ parent: "",
355
+ template: "surface2"
356
+ }],
357
+ surface3 = [{
358
+ parent: "active",
359
+ template: "surfaceActive"
360
+ }, {
361
+ parent: "",
362
+ template: "surface3"
363
+ }],
364
+ defaultComponentThemes = {
365
+ ListItem: {
366
+ template: "surface1"
367
+ },
368
+ SelectTrigger: surface1,
369
+ Card: surface1,
370
+ Button: surface3,
371
+ Checkbox: surface2,
372
+ Switch: surface2,
373
+ SwitchThumb: inverseSurface1,
374
+ TooltipContent: surface2,
375
+ Progress: {
376
+ template: "surface1"
377
+ },
378
+ RadioGroupItem: surface2,
379
+ TooltipArrow: {
380
+ template: "surface1"
381
+ },
382
+ SliderTrackActive: {
383
+ template: "surface3"
384
+ },
385
+ SliderTrack: {
386
+ template: "surface1"
387
+ },
388
+ SliderThumb: inverseSurface1,
389
+ Tooltip: inverseSurface1,
390
+ ProgressIndicator: inverseSurface1,
391
+ SheetOverlay: overlayThemeDefinitions,
392
+ DialogOverlay: overlayThemeDefinitions,
393
+ ModalOverlay: overlayThemeDefinitions,
394
+ Input: surface1,
395
+ TextArea: surface1
396
+ },
397
+ defaultSubThemes = {
398
+ alt1: {
399
+ template: "alt1"
400
+ },
401
+ alt2: {
402
+ template: "alt2"
403
+ },
404
+ active: {
405
+ template: "surface3"
406
+ },
407
+ surface1: {
408
+ template: "surface1"
409
+ },
410
+ surface2: {
411
+ template: "surface2"
412
+ },
413
+ surface3: {
414
+ template: "surface3"
415
+ },
416
+ surface4: {
417
+ template: "surfaceActive"
418
+ }
419
+ },
420
+ themeBuilder = (0, import_theme_builder.createThemeBuilder)().addPalettes(defaultPalettes).addTemplates(defaultTemplates).addThemes({
421
+ light: {
422
+ template: "base",
423
+ palette: "light",
424
+ nonInheritedValues: nonInherited.light
425
+ },
426
+ dark: {
427
+ template: "base",
428
+ palette: "dark",
429
+ nonInheritedValues: nonInherited.dark
430
+ }
431
+ }).addChildThemes({
432
+ orange: {
433
+ palette: "orange",
434
+ template: "base"
435
+ },
436
+ yellow: {
437
+ palette: "yellow",
438
+ template: "base"
439
+ },
440
+ green: {
441
+ palette: "green",
442
+ template: "base"
443
+ },
444
+ blue: {
445
+ palette: "blue",
446
+ template: "base"
447
+ },
448
+ purple: {
449
+ palette: "purple",
450
+ template: "base"
451
+ },
452
+ pink: {
453
+ palette: "pink",
454
+ template: "base"
455
+ },
456
+ red: {
457
+ palette: "red",
458
+ template: "base"
459
+ },
460
+ gray: {
461
+ palette: "gray",
462
+ template: "base"
463
+ }
464
+ }).addChildThemes(defaultSubThemes).addComponentThemes(defaultComponentThemes, {
465
+ avoidNestingWithin: ["alt1", "alt2", "surface1", "surface2", "surface3", "surface4"]
466
+ }),
467
+ themesIn = themeBuilder.build(),
468
+ themes = themesIn,
469
+ tokens = (0, import_web.createTokens)({
470
+ color,
471
+ ...import_v3_tokens.tokens
472
+ });