@multiplatform.one/theme 7.83.1 → 7.83.2

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 (810) hide show
  1. package/dist/cjs/audit/constraintAudit.cjs +567 -0
  2. package/dist/cjs/audit/constraintAudit.native.js +948 -0
  3. package/dist/cjs/audit/constraintAudit.native.js.map +1 -0
  4. package/dist/cjs/audit/designTokens.cjs +53 -0
  5. package/dist/cjs/audit/designTokens.native.js +80 -0
  6. package/dist/cjs/audit/designTokens.native.js.map +1 -0
  7. package/dist/cjs/audit/diffReport.cjs +255 -0
  8. package/dist/cjs/audit/diffReport.native.js +519 -0
  9. package/dist/cjs/audit/diffReport.native.js.map +1 -0
  10. package/dist/cjs/audit/index.cjs +41 -0
  11. package/dist/cjs/audit/index.native.js +44 -0
  12. package/dist/cjs/audit/index.native.js.map +1 -0
  13. package/dist/cjs/audit/themeMatrix.cjs +924 -0
  14. package/dist/cjs/audit/themeMatrix.native.js +1552 -0
  15. package/dist/cjs/audit/themeMatrix.native.js.map +1 -0
  16. package/dist/cjs/dates.cjs +261 -0
  17. package/dist/cjs/dates.native.js +289 -0
  18. package/dist/cjs/dates.native.js.map +1 -0
  19. package/dist/cjs/devWarn.cjs +163 -0
  20. package/dist/cjs/devWarn.native.js +191 -0
  21. package/dist/cjs/devWarn.native.js.map +1 -0
  22. package/dist/cjs/expo.cjs +82 -0
  23. package/dist/cjs/expo.native.js +87 -0
  24. package/dist/cjs/expo.native.js.map +1 -0
  25. package/dist/cjs/figma/figmaTokens.cjs +350 -0
  26. package/dist/cjs/figma/figmaTokens.native.js +637 -0
  27. package/dist/cjs/figma/figmaTokens.native.js.map +1 -0
  28. package/dist/cjs/font.cjs +65 -0
  29. package/dist/cjs/font.native.js +74 -0
  30. package/dist/cjs/font.native.js.map +1 -0
  31. package/dist/cjs/fonts/createFontLoader.cjs +32 -0
  32. package/dist/cjs/fonts/createFontLoader.native.js +69 -0
  33. package/dist/cjs/fonts/createFontLoader.native.js.map +1 -0
  34. package/dist/cjs/fonts/index.cjs +21 -0
  35. package/dist/cjs/fonts/index.native.js +24 -0
  36. package/dist/cjs/fonts/index.native.js.map +1 -0
  37. package/dist/cjs/fonts/types.cjs +18 -0
  38. package/dist/cjs/fonts/types.native.js +21 -0
  39. package/dist/cjs/fonts/types.native.js.map +1 -0
  40. package/dist/cjs/index.cjs +39 -0
  41. package/dist/cjs/index.native.js +42 -0
  42. package/dist/cjs/index.native.js.map +1 -0
  43. package/dist/cjs/keyboardFocusRing.cjs +111 -0
  44. package/dist/cjs/keyboardFocusRing.native.js +116 -0
  45. package/dist/cjs/keyboardFocusRing.native.js.map +1 -0
  46. package/dist/cjs/menuRow.cjs +80 -0
  47. package/dist/cjs/menuRow.native.js +86 -0
  48. package/dist/cjs/menuRow.native.js.map +1 -0
  49. package/dist/cjs/numbers.cjs +161 -0
  50. package/dist/cjs/numbers.native.js +173 -0
  51. package/dist/cjs/numbers.native.js.map +1 -0
  52. package/dist/cjs/theme/FontKnobStyles.cjs +161 -0
  53. package/dist/cjs/theme/FontKnobStyles.native.js +41 -0
  54. package/dist/cjs/theme/FontKnobStyles.native.js.map +1 -0
  55. package/dist/cjs/theme/Heading.cjs +174 -0
  56. package/dist/cjs/theme/Heading.native.js +186 -0
  57. package/dist/cjs/theme/Heading.native.js.map +1 -0
  58. package/dist/cjs/theme/IconSlot.cjs +67 -0
  59. package/dist/cjs/theme/IconSlot.native.js +78 -0
  60. package/dist/cjs/theme/IconSlot.native.js.map +1 -0
  61. package/dist/cjs/theme/Intent.cjs +44 -0
  62. package/dist/cjs/theme/Intent.native.js +48 -0
  63. package/dist/cjs/theme/Intent.native.js.map +1 -0
  64. package/dist/cjs/theme/Preset.cjs +150 -0
  65. package/dist/cjs/theme/Preset.native.js +156 -0
  66. package/dist/cjs/theme/Preset.native.js.map +1 -0
  67. package/dist/cjs/theme/PresetContext.cjs +38 -0
  68. package/dist/cjs/theme/PresetContext.native.js +42 -0
  69. package/dist/cjs/theme/PresetContext.native.js.map +1 -0
  70. package/dist/cjs/theme/Surface.cjs +115 -0
  71. package/dist/cjs/theme/Surface.native.js +126 -0
  72. package/dist/cjs/theme/Surface.native.js.map +1 -0
  73. package/dist/cjs/theme/Text.cjs +147 -0
  74. package/dist/cjs/theme/Text.native.js +155 -0
  75. package/dist/cjs/theme/Text.native.js.map +1 -0
  76. package/dist/cjs/theme/Tint.cjs +55 -0
  77. package/dist/cjs/theme/Tint.native.js +59 -0
  78. package/dist/cjs/theme/Tint.native.js.map +1 -0
  79. package/dist/cjs/theme/activateThemeConfig.cjs +42 -0
  80. package/dist/cjs/theme/activateThemeConfig.native.js +45 -0
  81. package/dist/cjs/theme/activateThemeConfig.native.js.map +1 -0
  82. package/dist/cjs/theme/animations/css.cjs +36 -0
  83. package/dist/cjs/theme/animations/css.native.js +39 -0
  84. package/dist/cjs/theme/animations/css.native.js.map +1 -0
  85. package/dist/cjs/theme/animations/index.cjs +20 -0
  86. package/dist/cjs/theme/animations/index.native.js +23 -0
  87. package/dist/cjs/theme/animations/index.native.js.map +1 -0
  88. package/dist/cjs/theme/animations/reactNative.cjs +158 -0
  89. package/dist/cjs/theme/animations/reactNative.native.js +161 -0
  90. package/dist/cjs/theme/animations/reactNative.native.js.map +1 -0
  91. package/dist/cjs/theme/chartPalette.cjs +229 -0
  92. package/dist/cjs/theme/chartPalette.native.js +297 -0
  93. package/dist/cjs/theme/chartPalette.native.js.map +1 -0
  94. package/dist/cjs/theme/colorRules.cjs +300 -0
  95. package/dist/cjs/theme/colorRules.native.js +330 -0
  96. package/dist/cjs/theme/colorRules.native.js.map +1 -0
  97. package/dist/cjs/theme/controlTiers.cjs +67 -0
  98. package/dist/cjs/theme/controlTiers.native.js +72 -0
  99. package/dist/cjs/theme/controlTiers.native.js.map +1 -0
  100. package/dist/cjs/theme/cookies.cjs +183 -0
  101. package/dist/cjs/theme/cookies.native.js +309 -0
  102. package/dist/cjs/theme/cookies.native.js.map +1 -0
  103. package/dist/cjs/theme/cornerSmoothing.cjs +111 -0
  104. package/dist/cjs/theme/cornerSmoothing.native.js +71 -0
  105. package/dist/cjs/theme/cornerSmoothing.native.js.map +1 -0
  106. package/dist/cjs/theme/createDefaultThemeConfig.cjs +130 -0
  107. package/dist/cjs/theme/createDefaultThemeConfig.native.js +176 -0
  108. package/dist/cjs/theme/createDefaultThemeConfig.native.js.map +1 -0
  109. package/dist/cjs/theme/createThemes.cjs +737 -0
  110. package/dist/cjs/theme/createThemes.native.js +1183 -0
  111. package/dist/cjs/theme/createThemes.native.js.map +1 -0
  112. package/dist/cjs/theme/dedupeInherited.cjs +83 -0
  113. package/dist/cjs/theme/dedupeInherited.native.js +194 -0
  114. package/dist/cjs/theme/dedupeInherited.native.js.map +1 -0
  115. package/dist/cjs/theme/defaults/accent.cjs +32 -0
  116. package/dist/cjs/theme/defaults/accent.native.js +35 -0
  117. package/dist/cjs/theme/defaults/accent.native.js.map +1 -0
  118. package/dist/cjs/theme/defaults/base.cjs +48 -0
  119. package/dist/cjs/theme/defaults/base.native.js +51 -0
  120. package/dist/cjs/theme/defaults/base.native.js.map +1 -0
  121. package/dist/cjs/theme/defaults/builderOptions.cjs +192 -0
  122. package/dist/cjs/theme/defaults/builderOptions.native.js +263 -0
  123. package/dist/cjs/theme/defaults/builderOptions.native.js.map +1 -0
  124. package/dist/cjs/theme/defaults/categoryFonts.cjs +50 -0
  125. package/dist/cjs/theme/defaults/categoryFonts.native.js +53 -0
  126. package/dist/cjs/theme/defaults/categoryFonts.native.js.map +1 -0
  127. package/dist/cjs/theme/defaults/fonts.cjs +301 -0
  128. package/dist/cjs/theme/defaults/fonts.native.js +390 -0
  129. package/dist/cjs/theme/defaults/fonts.native.js.map +1 -0
  130. package/dist/cjs/theme/defaults/house.cjs +39 -0
  131. package/dist/cjs/theme/defaults/house.native.js +46 -0
  132. package/dist/cjs/theme/defaults/house.native.js.map +1 -0
  133. package/dist/cjs/theme/defaults/index.cjs +25 -0
  134. package/dist/cjs/theme/defaults/index.native.js +28 -0
  135. package/dist/cjs/theme/defaults/index.native.js.map +1 -0
  136. package/dist/cjs/theme/devtools/ColorLineVisualizer.cjs +243 -0
  137. package/dist/cjs/theme/devtools/ColorLineVisualizer.native.js +269 -0
  138. package/dist/cjs/theme/devtools/ColorLineVisualizer.native.js.map +1 -0
  139. package/dist/cjs/theme/devtools/ThemeDevtoolsPanel.cjs +1350 -0
  140. package/dist/cjs/theme/devtools/ThemeDevtoolsPanel.native.js +1814 -0
  141. package/dist/cjs/theme/devtools/ThemeDevtoolsPanel.native.js.map +1 -0
  142. package/dist/cjs/theme/devtools/animationOptions.cjs +36 -0
  143. package/dist/cjs/theme/devtools/animationOptions.native.js +46 -0
  144. package/dist/cjs/theme/devtools/animationOptions.native.js.map +1 -0
  145. package/dist/cjs/theme/devtools/buildSnapshot.cjs +92 -0
  146. package/dist/cjs/theme/devtools/buildSnapshot.native.js +174 -0
  147. package/dist/cjs/theme/devtools/buildSnapshot.native.js.map +1 -0
  148. package/dist/cjs/theme/devtools/knobIcons.cjs +498 -0
  149. package/dist/cjs/theme/devtools/knobIcons.native.js +520 -0
  150. package/dist/cjs/theme/devtools/knobIcons.native.js.map +1 -0
  151. package/dist/cjs/theme/devtools/vizConstants.cjs +54 -0
  152. package/dist/cjs/theme/devtools/vizConstants.native.js +57 -0
  153. package/dist/cjs/theme/devtools/vizConstants.native.js.map +1 -0
  154. package/dist/cjs/theme/dynamicType.cjs +52 -0
  155. package/dist/cjs/theme/dynamicType.native.js +55 -0
  156. package/dist/cjs/theme/dynamicType.native.js.map +1 -0
  157. package/dist/cjs/theme/fieldFocus.cjs +56 -0
  158. package/dist/cjs/theme/fieldFocus.native.js +62 -0
  159. package/dist/cjs/theme/fieldFocus.native.js.map +1 -0
  160. package/dist/cjs/theme/fillContrast.cjs +130 -0
  161. package/dist/cjs/theme/fillContrast.native.js +163 -0
  162. package/dist/cjs/theme/fillContrast.native.js.map +1 -0
  163. package/dist/cjs/theme/focusState.cjs +120 -0
  164. package/dist/cjs/theme/focusState.native.js +123 -0
  165. package/dist/cjs/theme/focusState.native.js.map +1 -0
  166. package/dist/cjs/theme/fontCategoryMetrics.cjs +91 -0
  167. package/dist/cjs/theme/fontCategoryMetrics.native.js +94 -0
  168. package/dist/cjs/theme/fontCategoryMetrics.native.js.map +1 -0
  169. package/dist/cjs/theme/fontCategoryStacks.cjs +40 -0
  170. package/dist/cjs/theme/fontCategoryStacks.native.js +43 -0
  171. package/dist/cjs/theme/fontCategoryStacks.native.js.map +1 -0
  172. package/dist/cjs/theme/glyphPaint.cjs +55 -0
  173. package/dist/cjs/theme/glyphPaint.native.js +81 -0
  174. package/dist/cjs/theme/glyphPaint.native.js.map +1 -0
  175. package/dist/cjs/theme/glyphTint.cjs +113 -0
  176. package/dist/cjs/theme/glyphTint.native.js +125 -0
  177. package/dist/cjs/theme/glyphTint.native.js.map +1 -0
  178. package/dist/cjs/theme/groupGeometry.cjs +67 -0
  179. package/dist/cjs/theme/groupGeometry.native.js +72 -0
  180. package/dist/cjs/theme/groupGeometry.native.js.map +1 -0
  181. package/dist/cjs/theme/hairline.cjs +102 -0
  182. package/dist/cjs/theme/hairline.native.js +73 -0
  183. package/dist/cjs/theme/hairline.native.js.map +1 -0
  184. package/dist/cjs/theme/index.cjs +95 -0
  185. package/dist/cjs/theme/index.native.js +98 -0
  186. package/dist/cjs/theme/index.native.js.map +1 -0
  187. package/dist/cjs/theme/intents.cjs +62 -0
  188. package/dist/cjs/theme/intents.native.js +65 -0
  189. package/dist/cjs/theme/intents.native.js.map +1 -0
  190. package/dist/cjs/theme/knobs.cjs +172 -0
  191. package/dist/cjs/theme/knobs.native.js +175 -0
  192. package/dist/cjs/theme/knobs.native.js.map +1 -0
  193. package/dist/cjs/theme/layoutTokens.cjs +172 -0
  194. package/dist/cjs/theme/layoutTokens.native.js +222 -0
  195. package/dist/cjs/theme/layoutTokens.native.js.map +1 -0
  196. package/dist/cjs/theme/listRows.cjs +44 -0
  197. package/dist/cjs/theme/listRows.native.js +49 -0
  198. package/dist/cjs/theme/listRows.native.js.map +1 -0
  199. package/dist/cjs/theme/mergedTokens.cjs +39 -0
  200. package/dist/cjs/theme/mergedTokens.native.js +61 -0
  201. package/dist/cjs/theme/mergedTokens.native.js.map +1 -0
  202. package/dist/cjs/theme/motion.cjs +72 -0
  203. package/dist/cjs/theme/motion.native.js +82 -0
  204. package/dist/cjs/theme/motion.native.js.map +1 -0
  205. package/dist/cjs/theme/motionStops.cjs +28 -0
  206. package/dist/cjs/theme/motionStops.native.js +31 -0
  207. package/dist/cjs/theme/motionStops.native.js.map +1 -0
  208. package/dist/cjs/theme/motionTiming.cjs +79 -0
  209. package/dist/cjs/theme/motionTiming.native.js +85 -0
  210. package/dist/cjs/theme/motionTiming.native.js.map +1 -0
  211. package/dist/cjs/theme/nativeFontFamily.cjs +30 -0
  212. package/dist/cjs/theme/nativeFontFamily.native.js +37 -0
  213. package/dist/cjs/theme/nativeFontFamily.native.js.map +1 -0
  214. package/dist/cjs/theme/nativeMonoFamily.cjs +44 -0
  215. package/dist/cjs/theme/nativeMonoFamily.native.js +47 -0
  216. package/dist/cjs/theme/nativeMonoFamily.native.js.map +1 -0
  217. package/dist/cjs/theme/overlaySurfaces.cjs +327 -0
  218. package/dist/cjs/theme/overlaySurfaces.native.js +351 -0
  219. package/dist/cjs/theme/overlaySurfaces.native.js.map +1 -0
  220. package/dist/cjs/theme/pageGutter.cjs +85 -0
  221. package/dist/cjs/theme/pageGutter.native.js +92 -0
  222. package/dist/cjs/theme/pageGutter.native.js.map +1 -0
  223. package/dist/cjs/theme/preset.types.cjs +18 -0
  224. package/dist/cjs/theme/preset.types.native.js +21 -0
  225. package/dist/cjs/theme/preset.types.native.js.map +1 -0
  226. package/dist/cjs/theme/presetPreview.cjs +42 -0
  227. package/dist/cjs/theme/presetPreview.native.js +46 -0
  228. package/dist/cjs/theme/presetPreview.native.js.map +1 -0
  229. package/dist/cjs/theme/presetStore.cjs +288 -0
  230. package/dist/cjs/theme/presetStore.native.js +344 -0
  231. package/dist/cjs/theme/presetStore.native.js.map +1 -0
  232. package/dist/cjs/theme/presetUserSync.cjs +70 -0
  233. package/dist/cjs/theme/presetUserSync.native.js +75 -0
  234. package/dist/cjs/theme/presetUserSync.native.js.map +1 -0
  235. package/dist/cjs/theme/presets.cjs +128 -0
  236. package/dist/cjs/theme/presets.native.js +131 -0
  237. package/dist/cjs/theme/presets.native.js.map +1 -0
  238. package/dist/cjs/theme/radiusClass.cjs +128 -0
  239. package/dist/cjs/theme/radiusClass.native.js +137 -0
  240. package/dist/cjs/theme/radiusClass.native.js.map +1 -0
  241. package/dist/cjs/theme/radiusClassTable.generated.cjs +164 -0
  242. package/dist/cjs/theme/radiusClassTable.generated.native.js +167 -0
  243. package/dist/cjs/theme/radiusClassTable.generated.native.js.map +1 -0
  244. package/dist/cjs/theme/ramps.cjs +75 -0
  245. package/dist/cjs/theme/ramps.native.js +79 -0
  246. package/dist/cjs/theme/ramps.native.js.map +1 -0
  247. package/dist/cjs/theme/readableColor.cjs +248 -0
  248. package/dist/cjs/theme/readableColor.native.js +354 -0
  249. package/dist/cjs/theme/readableColor.native.js.map +1 -0
  250. package/dist/cjs/theme/recipeInputs.cjs +352 -0
  251. package/dist/cjs/theme/recipeInputs.native.js +470 -0
  252. package/dist/cjs/theme/recipeInputs.native.js.map +1 -0
  253. package/dist/cjs/theme/recipes.cjs +18 -0
  254. package/dist/cjs/theme/recipes.native.js +21 -0
  255. package/dist/cjs/theme/recipes.native.js.map +1 -0
  256. package/dist/cjs/theme/resolveKnobs.cjs +778 -0
  257. package/dist/cjs/theme/resolveKnobs.native.js +795 -0
  258. package/dist/cjs/theme/resolveKnobs.native.js.map +1 -0
  259. package/dist/cjs/theme/scale/ScaleStyles.cjs +57 -0
  260. package/dist/cjs/theme/scale/ScaleStyles.native.js +41 -0
  261. package/dist/cjs/theme/scale/ScaleStyles.native.js.map +1 -0
  262. package/dist/cjs/theme/scale/activeScale.cjs +56 -0
  263. package/dist/cjs/theme/scale/activeScale.native.js +84 -0
  264. package/dist/cjs/theme/scale/activeScale.native.js.map +1 -0
  265. package/dist/cjs/theme/scale/deriveRecipeInputs.cjs +111 -0
  266. package/dist/cjs/theme/scale/deriveRecipeInputs.native.js +154 -0
  267. package/dist/cjs/theme/scale/deriveRecipeInputs.native.js.map +1 -0
  268. package/dist/cjs/theme/scale/generateScale.cjs +114 -0
  269. package/dist/cjs/theme/scale/generateScale.native.js +200 -0
  270. package/dist/cjs/theme/scale/generateScale.native.js.map +1 -0
  271. package/dist/cjs/theme/scale/index.cjs +78 -0
  272. package/dist/cjs/theme/scale/index.native.js +81 -0
  273. package/dist/cjs/theme/scale/index.native.js.map +1 -0
  274. package/dist/cjs/theme/scale/installScaleConfig.cjs +31 -0
  275. package/dist/cjs/theme/scale/installScaleConfig.native.js +65 -0
  276. package/dist/cjs/theme/scale/installScaleConfig.native.js.map +1 -0
  277. package/dist/cjs/theme/scale/scaleAttribute.cjs +39 -0
  278. package/dist/cjs/theme/scale/scaleAttribute.native.js +42 -0
  279. package/dist/cjs/theme/scale/scaleAttribute.native.js.map +1 -0
  280. package/dist/cjs/theme/scale/scaleCss.cjs +89 -0
  281. package/dist/cjs/theme/scale/scaleCss.native.js +201 -0
  282. package/dist/cjs/theme/scale/scaleCss.native.js.map +1 -0
  283. package/dist/cjs/theme/scale/scaleFonts.cjs +86 -0
  284. package/dist/cjs/theme/scale/scaleFonts.native.js +155 -0
  285. package/dist/cjs/theme/scale/scaleFonts.native.js.map +1 -0
  286. package/dist/cjs/theme/scale/scaleInputs.cjs +232 -0
  287. package/dist/cjs/theme/scale/scaleInputs.native.js +237 -0
  288. package/dist/cjs/theme/scale/scaleInputs.native.js.map +1 -0
  289. package/dist/cjs/theme/scale/themeScales.cjs +136 -0
  290. package/dist/cjs/theme/scale/themeScales.native.js +185 -0
  291. package/dist/cjs/theme/scale/themeScales.native.js.map +1 -0
  292. package/dist/cjs/theme/scale/useActiveScale.cjs +78 -0
  293. package/dist/cjs/theme/scale/useActiveScale.native.js +87 -0
  294. package/dist/cjs/theme/scale/useActiveScale.native.js.map +1 -0
  295. package/dist/cjs/theme/schemeStore.cjs +87 -0
  296. package/dist/cjs/theme/schemeStore.native.js +104 -0
  297. package/dist/cjs/theme/schemeStore.native.js.map +1 -0
  298. package/dist/cjs/theme/shared.cjs +125 -0
  299. package/dist/cjs/theme/shared.native.js +168 -0
  300. package/dist/cjs/theme/shared.native.js.map +1 -0
  301. package/dist/cjs/theme/sizeRecipes.cjs +176 -0
  302. package/dist/cjs/theme/sizeRecipes.native.js +251 -0
  303. package/dist/cjs/theme/sizeRecipes.native.js.map +1 -0
  304. package/dist/cjs/theme/subsetThemes.cjs +46 -0
  305. package/dist/cjs/theme/subsetThemes.native.js +76 -0
  306. package/dist/cjs/theme/subsetThemes.native.js.map +1 -0
  307. package/dist/cjs/theme/theme.cjs +189 -0
  308. package/dist/cjs/theme/theme.native.js +115 -0
  309. package/dist/cjs/theme/theme.native.js.map +1 -0
  310. package/dist/cjs/theme/themeValue.cjs +51 -0
  311. package/dist/cjs/theme/themeValue.native.js +73 -0
  312. package/dist/cjs/theme/themeValue.native.js.map +1 -0
  313. package/dist/cjs/theme/tileSizes.cjs +202 -0
  314. package/dist/cjs/theme/tileSizes.native.js +230 -0
  315. package/dist/cjs/theme/tileSizes.native.js.map +1 -0
  316. package/dist/cjs/theme/touchManipulation.cjs +33 -0
  317. package/dist/cjs/theme/touchManipulation.native.js +36 -0
  318. package/dist/cjs/theme/touchManipulation.native.js.map +1 -0
  319. package/dist/cjs/theme/transitionProps.cjs +50 -0
  320. package/dist/cjs/theme/transitionProps.native.js +81 -0
  321. package/dist/cjs/theme/transitionProps.native.js.map +1 -0
  322. package/dist/cjs/theme/useColorScale.cjs +47 -0
  323. package/dist/cjs/theme/useColorScale.native.js +33 -0
  324. package/dist/cjs/theme/useColorScale.native.js.map +1 -0
  325. package/dist/cjs/theme/usePresetSwitch.cjs +70 -0
  326. package/dist/cjs/theme/usePresetSwitch.native.js +50 -0
  327. package/dist/cjs/theme/usePresetSwitch.native.js.map +1 -0
  328. package/dist/cjs/theme/useResolvedKnobs.cjs +140 -0
  329. package/dist/cjs/theme/useResolvedKnobs.native.js +177 -0
  330. package/dist/cjs/theme/useResolvedKnobs.native.js.map +1 -0
  331. package/dist/cjs/theme/useSchemePreference.cjs +49 -0
  332. package/dist/cjs/theme/useSchemePreference.native.js +80 -0
  333. package/dist/cjs/theme/useSchemePreference.native.js.map +1 -0
  334. package/dist/cjs/theme/useTheme.cjs +152 -0
  335. package/dist/cjs/theme/useTheme.native.js +94 -0
  336. package/dist/cjs/theme/useTheme.native.js.map +1 -0
  337. package/dist/cjs/theme/useTouchSurface.cjs +33 -0
  338. package/dist/cjs/theme/useTouchSurface.native.js +36 -0
  339. package/dist/cjs/theme/useTouchSurface.native.js.map +1 -0
  340. package/dist/cjs/theme/v3TokenRoles.cjs +64 -0
  341. package/dist/cjs/theme/v3TokenRoles.native.js +67 -0
  342. package/dist/cjs/theme/v3TokenRoles.native.js.map +1 -0
  343. package/dist/esm/audit/constraintAudit.mjs +540 -0
  344. package/dist/esm/audit/constraintAudit.mjs.map +1 -0
  345. package/dist/esm/audit/constraintAudit.native.js +918 -0
  346. package/dist/esm/audit/constraintAudit.native.js.map +1 -0
  347. package/dist/esm/audit/designTokens.mjs +28 -0
  348. package/dist/esm/audit/designTokens.mjs.map +1 -0
  349. package/dist/esm/audit/designTokens.native.js +52 -0
  350. package/dist/esm/audit/designTokens.native.js.map +1 -0
  351. package/dist/esm/audit/diffReport.mjs +229 -0
  352. package/dist/esm/audit/diffReport.mjs.map +1 -0
  353. package/dist/esm/audit/diffReport.native.js +490 -0
  354. package/dist/esm/audit/diffReport.native.js.map +1 -0
  355. package/dist/esm/audit/index.mjs +5 -0
  356. package/dist/esm/audit/index.mjs.map +1 -0
  357. package/dist/esm/audit/index.native.js +5 -0
  358. package/dist/esm/audit/index.native.js.map +1 -0
  359. package/dist/esm/audit/themeMatrix.mjs +890 -0
  360. package/dist/esm/audit/themeMatrix.mjs.map +1 -0
  361. package/dist/esm/audit/themeMatrix.native.js +1515 -0
  362. package/dist/esm/audit/themeMatrix.native.js.map +1 -0
  363. package/dist/esm/dates.mjs +224 -0
  364. package/dist/esm/dates.mjs.map +1 -0
  365. package/dist/esm/dates.native.js +249 -0
  366. package/dist/esm/dates.native.js.map +1 -0
  367. package/dist/esm/devWarn.mjs +123 -0
  368. package/dist/esm/devWarn.mjs.map +1 -0
  369. package/dist/esm/devWarn.native.js +148 -0
  370. package/dist/esm/devWarn.native.js.map +1 -0
  371. package/dist/esm/expo.mjs +53 -0
  372. package/dist/esm/expo.mjs.map +1 -0
  373. package/dist/esm/expo.native.js +55 -0
  374. package/dist/esm/expo.native.js.map +1 -0
  375. package/dist/esm/figma/figmaTokens.mjs +322 -0
  376. package/dist/esm/figma/figmaTokens.mjs.map +1 -0
  377. package/dist/esm/figma/figmaTokens.native.js +606 -0
  378. package/dist/esm/figma/figmaTokens.native.js.map +1 -0
  379. package/dist/esm/font.mjs +40 -0
  380. package/dist/esm/font.mjs.map +1 -0
  381. package/dist/esm/font.native.js +46 -0
  382. package/dist/esm/font.native.js.map +1 -0
  383. package/dist/esm/fonts/createFontLoader.mjs +7 -0
  384. package/dist/esm/fonts/createFontLoader.mjs.map +1 -0
  385. package/dist/esm/fonts/createFontLoader.native.js +41 -0
  386. package/dist/esm/fonts/createFontLoader.native.js.map +1 -0
  387. package/dist/esm/fonts/index.mjs +3 -0
  388. package/dist/esm/fonts/index.mjs.map +1 -0
  389. package/dist/esm/fonts/index.native.js +3 -0
  390. package/dist/esm/fonts/index.native.js.map +1 -0
  391. package/dist/esm/fonts/types.mjs +2 -0
  392. package/dist/esm/fonts/types.mjs.map +1 -0
  393. package/dist/esm/fonts/types.native.js +2 -0
  394. package/dist/esm/fonts/types.native.js.map +1 -0
  395. package/dist/esm/index.mjs +11 -0
  396. package/dist/esm/index.mjs.map +1 -0
  397. package/dist/esm/index.native.js +11 -0
  398. package/dist/esm/index.native.js.map +1 -0
  399. package/dist/esm/keyboardFocusRing.mjs +81 -0
  400. package/dist/esm/keyboardFocusRing.mjs.map +1 -0
  401. package/dist/esm/keyboardFocusRing.native.js +83 -0
  402. package/dist/esm/keyboardFocusRing.native.js.map +1 -0
  403. package/dist/esm/menuRow.mjs +49 -0
  404. package/dist/esm/menuRow.mjs.map +1 -0
  405. package/dist/esm/menuRow.native.js +52 -0
  406. package/dist/esm/menuRow.native.js.map +1 -0
  407. package/dist/esm/numbers.mjs +132 -0
  408. package/dist/esm/numbers.mjs.map +1 -0
  409. package/dist/esm/numbers.native.js +141 -0
  410. package/dist/esm/numbers.native.js.map +1 -0
  411. package/dist/esm/theme/FontKnobStyles.mjs +131 -0
  412. package/dist/esm/theme/FontKnobStyles.mjs.map +1 -0
  413. package/dist/esm/theme/FontKnobStyles.native.js +11 -0
  414. package/dist/esm/theme/FontKnobStyles.native.js.map +1 -0
  415. package/dist/esm/theme/Heading.mjs +143 -0
  416. package/dist/esm/theme/Heading.mjs.map +1 -0
  417. package/dist/esm/theme/Heading.native.js +152 -0
  418. package/dist/esm/theme/Heading.native.js.map +1 -0
  419. package/dist/esm/theme/IconSlot.mjs +42 -0
  420. package/dist/esm/theme/IconSlot.mjs.map +1 -0
  421. package/dist/esm/theme/IconSlot.native.js +50 -0
  422. package/dist/esm/theme/IconSlot.native.js.map +1 -0
  423. package/dist/esm/theme/Intent.mjs +19 -0
  424. package/dist/esm/theme/Intent.mjs.map +1 -0
  425. package/dist/esm/theme/Intent.native.js +20 -0
  426. package/dist/esm/theme/Intent.native.js.map +1 -0
  427. package/dist/esm/theme/Preset.mjs +124 -0
  428. package/dist/esm/theme/Preset.mjs.map +1 -0
  429. package/dist/esm/theme/Preset.native.js +127 -0
  430. package/dist/esm/theme/Preset.native.js.map +1 -0
  431. package/dist/esm/theme/PresetContext.mjs +11 -0
  432. package/dist/esm/theme/PresetContext.mjs.map +1 -0
  433. package/dist/esm/theme/PresetContext.native.js +12 -0
  434. package/dist/esm/theme/PresetContext.native.js.map +1 -0
  435. package/dist/esm/theme/Surface.mjs +80 -0
  436. package/dist/esm/theme/Surface.mjs.map +1 -0
  437. package/dist/esm/theme/Surface.native.js +88 -0
  438. package/dist/esm/theme/Surface.native.js.map +1 -0
  439. package/dist/esm/theme/Text.mjs +119 -0
  440. package/dist/esm/theme/Text.mjs.map +1 -0
  441. package/dist/esm/theme/Text.native.js +124 -0
  442. package/dist/esm/theme/Text.native.js.map +1 -0
  443. package/dist/esm/theme/Tint.mjs +29 -0
  444. package/dist/esm/theme/Tint.mjs.map +1 -0
  445. package/dist/esm/theme/Tint.native.js +30 -0
  446. package/dist/esm/theme/Tint.native.js.map +1 -0
  447. package/dist/esm/theme/activateThemeConfig.mjs +17 -0
  448. package/dist/esm/theme/activateThemeConfig.mjs.map +1 -0
  449. package/dist/esm/theme/activateThemeConfig.native.js +17 -0
  450. package/dist/esm/theme/activateThemeConfig.native.js.map +1 -0
  451. package/dist/esm/theme/animations/css.mjs +7 -0
  452. package/dist/esm/theme/animations/css.mjs.map +1 -0
  453. package/dist/esm/theme/animations/css.native.js +7 -0
  454. package/dist/esm/theme/animations/css.native.js.map +1 -0
  455. package/dist/esm/theme/animations/index.mjs +2 -0
  456. package/dist/esm/theme/animations/index.mjs.map +1 -0
  457. package/dist/esm/theme/animations/index.native.js +2 -0
  458. package/dist/esm/theme/animations/index.native.js.map +1 -0
  459. package/dist/esm/theme/animations/reactNative.mjs +131 -0
  460. package/dist/esm/theme/animations/reactNative.mjs.map +1 -0
  461. package/dist/esm/theme/animations/reactNative.native.js +131 -0
  462. package/dist/esm/theme/animations/reactNative.native.js.map +1 -0
  463. package/dist/esm/theme/chartPalette.mjs +191 -0
  464. package/dist/esm/theme/chartPalette.mjs.map +1 -0
  465. package/dist/esm/theme/chartPalette.native.js +256 -0
  466. package/dist/esm/theme/chartPalette.native.js.map +1 -0
  467. package/dist/esm/theme/colorRules.mjs +251 -0
  468. package/dist/esm/theme/colorRules.mjs.map +1 -0
  469. package/dist/esm/theme/colorRules.native.js +278 -0
  470. package/dist/esm/theme/colorRules.native.js.map +1 -0
  471. package/dist/esm/theme/controlTiers.mjs +39 -0
  472. package/dist/esm/theme/controlTiers.mjs.map +1 -0
  473. package/dist/esm/theme/controlTiers.native.js +41 -0
  474. package/dist/esm/theme/controlTiers.native.js.map +1 -0
  475. package/dist/esm/theme/cookies.mjs +145 -0
  476. package/dist/esm/theme/cookies.mjs.map +1 -0
  477. package/dist/esm/theme/cookies.native.js +268 -0
  478. package/dist/esm/theme/cookies.native.js.map +1 -0
  479. package/dist/esm/theme/cornerSmoothing.mjs +71 -0
  480. package/dist/esm/theme/cornerSmoothing.mjs.map +1 -0
  481. package/dist/esm/theme/cornerSmoothing.native.js +28 -0
  482. package/dist/esm/theme/cornerSmoothing.native.js.map +1 -0
  483. package/dist/esm/theme/createDefaultThemeConfig.mjs +102 -0
  484. package/dist/esm/theme/createDefaultThemeConfig.mjs.map +1 -0
  485. package/dist/esm/theme/createDefaultThemeConfig.native.js +145 -0
  486. package/dist/esm/theme/createDefaultThemeConfig.native.js.map +1 -0
  487. package/dist/esm/theme/createThemes.mjs +697 -0
  488. package/dist/esm/theme/createThemes.mjs.map +1 -0
  489. package/dist/esm/theme/createThemes.native.js +1140 -0
  490. package/dist/esm/theme/createThemes.native.js.map +1 -0
  491. package/dist/esm/theme/dedupeInherited.mjs +55 -0
  492. package/dist/esm/theme/dedupeInherited.mjs.map +1 -0
  493. package/dist/esm/theme/dedupeInherited.native.js +163 -0
  494. package/dist/esm/theme/dedupeInherited.native.js.map +1 -0
  495. package/dist/esm/theme/defaults/accent.mjs +7 -0
  496. package/dist/esm/theme/defaults/accent.mjs.map +1 -0
  497. package/dist/esm/theme/defaults/accent.native.js +7 -0
  498. package/dist/esm/theme/defaults/accent.native.js.map +1 -0
  499. package/dist/esm/theme/defaults/base.mjs +23 -0
  500. package/dist/esm/theme/defaults/base.mjs.map +1 -0
  501. package/dist/esm/theme/defaults/base.native.js +23 -0
  502. package/dist/esm/theme/defaults/base.native.js.map +1 -0
  503. package/dist/esm/theme/defaults/builderOptions.mjs +165 -0
  504. package/dist/esm/theme/defaults/builderOptions.mjs.map +1 -0
  505. package/dist/esm/theme/defaults/builderOptions.native.js +233 -0
  506. package/dist/esm/theme/defaults/builderOptions.native.js.map +1 -0
  507. package/dist/esm/theme/defaults/categoryFonts.mjs +25 -0
  508. package/dist/esm/theme/defaults/categoryFonts.mjs.map +1 -0
  509. package/dist/esm/theme/defaults/categoryFonts.native.js +25 -0
  510. package/dist/esm/theme/defaults/categoryFonts.native.js.map +1 -0
  511. package/dist/esm/theme/defaults/fonts.mjs +240 -0
  512. package/dist/esm/theme/defaults/fonts.mjs.map +1 -0
  513. package/dist/esm/theme/defaults/fonts.native.js +326 -0
  514. package/dist/esm/theme/defaults/fonts.native.js.map +1 -0
  515. package/dist/esm/theme/defaults/house.mjs +13 -0
  516. package/dist/esm/theme/defaults/house.mjs.map +1 -0
  517. package/dist/esm/theme/defaults/house.native.js +17 -0
  518. package/dist/esm/theme/defaults/house.native.js.map +1 -0
  519. package/dist/esm/theme/defaults/index.mjs +7 -0
  520. package/dist/esm/theme/defaults/index.mjs.map +1 -0
  521. package/dist/esm/theme/defaults/index.native.js +7 -0
  522. package/dist/esm/theme/defaults/index.native.js.map +1 -0
  523. package/dist/esm/theme/devtools/ColorLineVisualizer.mjs +218 -0
  524. package/dist/esm/theme/devtools/ColorLineVisualizer.mjs.map +1 -0
  525. package/dist/esm/theme/devtools/ColorLineVisualizer.native.js +230 -0
  526. package/dist/esm/theme/devtools/ColorLineVisualizer.native.js.map +1 -0
  527. package/dist/esm/theme/devtools/ThemeDevtoolsPanel.mjs +1325 -0
  528. package/dist/esm/theme/devtools/ThemeDevtoolsPanel.mjs.map +1 -0
  529. package/dist/esm/theme/devtools/ThemeDevtoolsPanel.native.js +1786 -0
  530. package/dist/esm/theme/devtools/ThemeDevtoolsPanel.native.js.map +1 -0
  531. package/dist/esm/theme/devtools/animationOptions.mjs +11 -0
  532. package/dist/esm/theme/devtools/animationOptions.mjs.map +1 -0
  533. package/dist/esm/theme/devtools/animationOptions.native.js +18 -0
  534. package/dist/esm/theme/devtools/animationOptions.native.js.map +1 -0
  535. package/dist/esm/theme/devtools/buildSnapshot.mjs +67 -0
  536. package/dist/esm/theme/devtools/buildSnapshot.mjs.map +1 -0
  537. package/dist/esm/theme/devtools/buildSnapshot.native.js +146 -0
  538. package/dist/esm/theme/devtools/buildSnapshot.native.js.map +1 -0
  539. package/dist/esm/theme/devtools/knobIcons.mjs +456 -0
  540. package/dist/esm/theme/devtools/knobIcons.mjs.map +1 -0
  541. package/dist/esm/theme/devtools/knobIcons.native.js +464 -0
  542. package/dist/esm/theme/devtools/knobIcons.native.js.map +1 -0
  543. package/dist/esm/theme/devtools/vizConstants.mjs +26 -0
  544. package/dist/esm/theme/devtools/vizConstants.mjs.map +1 -0
  545. package/dist/esm/theme/devtools/vizConstants.native.js +26 -0
  546. package/dist/esm/theme/devtools/vizConstants.native.js.map +1 -0
  547. package/dist/esm/theme/dynamicType.mjs +24 -0
  548. package/dist/esm/theme/dynamicType.mjs.map +1 -0
  549. package/dist/esm/theme/dynamicType.native.js +24 -0
  550. package/dist/esm/theme/dynamicType.native.js.map +1 -0
  551. package/dist/esm/theme/fieldFocus.mjs +27 -0
  552. package/dist/esm/theme/fieldFocus.mjs.map +1 -0
  553. package/dist/esm/theme/fieldFocus.native.js +30 -0
  554. package/dist/esm/theme/fieldFocus.native.js.map +1 -0
  555. package/dist/esm/theme/fillContrast.mjs +98 -0
  556. package/dist/esm/theme/fillContrast.mjs.map +1 -0
  557. package/dist/esm/theme/fillContrast.native.js +128 -0
  558. package/dist/esm/theme/fillContrast.native.js.map +1 -0
  559. package/dist/esm/theme/focusState.mjs +81 -0
  560. package/dist/esm/theme/focusState.mjs.map +1 -0
  561. package/dist/esm/theme/focusState.native.js +81 -0
  562. package/dist/esm/theme/focusState.native.js.map +1 -0
  563. package/dist/esm/theme/fontCategoryMetrics.mjs +65 -0
  564. package/dist/esm/theme/fontCategoryMetrics.mjs.map +1 -0
  565. package/dist/esm/theme/fontCategoryMetrics.native.js +65 -0
  566. package/dist/esm/theme/fontCategoryMetrics.native.js.map +1 -0
  567. package/dist/esm/theme/fontCategoryStacks.mjs +15 -0
  568. package/dist/esm/theme/fontCategoryStacks.mjs.map +1 -0
  569. package/dist/esm/theme/fontCategoryStacks.native.js +15 -0
  570. package/dist/esm/theme/fontCategoryStacks.native.js.map +1 -0
  571. package/dist/esm/theme/glyphPaint.mjs +29 -0
  572. package/dist/esm/theme/glyphPaint.mjs.map +1 -0
  573. package/dist/esm/theme/glyphPaint.native.js +52 -0
  574. package/dist/esm/theme/glyphPaint.native.js.map +1 -0
  575. package/dist/esm/theme/glyphTint.mjs +82 -0
  576. package/dist/esm/theme/glyphTint.mjs.map +1 -0
  577. package/dist/esm/theme/glyphTint.native.js +91 -0
  578. package/dist/esm/theme/glyphTint.native.js.map +1 -0
  579. package/dist/esm/theme/groupGeometry.mjs +38 -0
  580. package/dist/esm/theme/groupGeometry.mjs.map +1 -0
  581. package/dist/esm/theme/groupGeometry.native.js +40 -0
  582. package/dist/esm/theme/groupGeometry.native.js.map +1 -0
  583. package/dist/esm/theme/hairline.mjs +73 -0
  584. package/dist/esm/theme/hairline.mjs.map +1 -0
  585. package/dist/esm/theme/hairline.native.js +41 -0
  586. package/dist/esm/theme/hairline.native.js.map +1 -0
  587. package/dist/esm/theme/index.mjs +66 -0
  588. package/dist/esm/theme/index.mjs.map +1 -0
  589. package/dist/esm/theme/index.native.js +66 -0
  590. package/dist/esm/theme/index.native.js.map +1 -0
  591. package/dist/esm/theme/intents.mjs +37 -0
  592. package/dist/esm/theme/intents.mjs.map +1 -0
  593. package/dist/esm/theme/intents.native.js +37 -0
  594. package/dist/esm/theme/intents.native.js.map +1 -0
  595. package/dist/esm/theme/knobs.mjs +125 -0
  596. package/dist/esm/theme/knobs.mjs.map +1 -0
  597. package/dist/esm/theme/knobs.native.js +125 -0
  598. package/dist/esm/theme/knobs.native.js.map +1 -0
  599. package/dist/esm/theme/layoutTokens.mjs +124 -0
  600. package/dist/esm/theme/layoutTokens.mjs.map +1 -0
  601. package/dist/esm/theme/layoutTokens.native.js +171 -0
  602. package/dist/esm/theme/layoutTokens.native.js.map +1 -0
  603. package/dist/esm/theme/listRows.mjs +17 -0
  604. package/dist/esm/theme/listRows.mjs.map +1 -0
  605. package/dist/esm/theme/listRows.native.js +19 -0
  606. package/dist/esm/theme/listRows.native.js.map +1 -0
  607. package/dist/esm/theme/mergedTokens.mjs +14 -0
  608. package/dist/esm/theme/mergedTokens.mjs.map +1 -0
  609. package/dist/esm/theme/mergedTokens.native.js +33 -0
  610. package/dist/esm/theme/mergedTokens.native.js.map +1 -0
  611. package/dist/esm/theme/motion.mjs +41 -0
  612. package/dist/esm/theme/motion.mjs.map +1 -0
  613. package/dist/esm/theme/motion.native.js +48 -0
  614. package/dist/esm/theme/motion.native.js.map +1 -0
  615. package/dist/esm/theme/motionStops.mjs +3 -0
  616. package/dist/esm/theme/motionStops.mjs.map +1 -0
  617. package/dist/esm/theme/motionStops.native.js +3 -0
  618. package/dist/esm/theme/motionStops.native.js.map +1 -0
  619. package/dist/esm/theme/motionTiming.mjs +48 -0
  620. package/dist/esm/theme/motionTiming.mjs.map +1 -0
  621. package/dist/esm/theme/motionTiming.native.js +51 -0
  622. package/dist/esm/theme/motionTiming.native.js.map +1 -0
  623. package/dist/esm/theme/nativeFontFamily.mjs +5 -0
  624. package/dist/esm/theme/nativeFontFamily.mjs.map +1 -0
  625. package/dist/esm/theme/nativeFontFamily.native.js +9 -0
  626. package/dist/esm/theme/nativeFontFamily.native.js.map +1 -0
  627. package/dist/esm/theme/nativeMonoFamily.mjs +18 -0
  628. package/dist/esm/theme/nativeMonoFamily.mjs.map +1 -0
  629. package/dist/esm/theme/nativeMonoFamily.native.js +18 -0
  630. package/dist/esm/theme/nativeMonoFamily.native.js.map +1 -0
  631. package/dist/esm/theme/overlaySurfaces.mjs +290 -0
  632. package/dist/esm/theme/overlaySurfaces.mjs.map +1 -0
  633. package/dist/esm/theme/overlaySurfaces.native.js +311 -0
  634. package/dist/esm/theme/overlaySurfaces.native.js.map +1 -0
  635. package/dist/esm/theme/pageGutter.mjs +55 -0
  636. package/dist/esm/theme/pageGutter.mjs.map +1 -0
  637. package/dist/esm/theme/pageGutter.native.js +59 -0
  638. package/dist/esm/theme/pageGutter.native.js.map +1 -0
  639. package/dist/esm/theme/preset.types.mjs +2 -0
  640. package/dist/esm/theme/preset.types.mjs.map +1 -0
  641. package/dist/esm/theme/preset.types.native.js +2 -0
  642. package/dist/esm/theme/preset.types.native.js.map +1 -0
  643. package/dist/esm/theme/presetPreview.mjs +17 -0
  644. package/dist/esm/theme/presetPreview.mjs.map +1 -0
  645. package/dist/esm/theme/presetPreview.native.js +18 -0
  646. package/dist/esm/theme/presetPreview.native.js.map +1 -0
  647. package/dist/esm/theme/presetStore.mjs +251 -0
  648. package/dist/esm/theme/presetStore.mjs.map +1 -0
  649. package/dist/esm/theme/presetStore.native.js +304 -0
  650. package/dist/esm/theme/presetStore.native.js.map +1 -0
  651. package/dist/esm/theme/presetUserSync.mjs +44 -0
  652. package/dist/esm/theme/presetUserSync.mjs.map +1 -0
  653. package/dist/esm/theme/presetUserSync.native.js +46 -0
  654. package/dist/esm/theme/presetUserSync.native.js.map +1 -0
  655. package/dist/esm/theme/presets.mjs +97 -0
  656. package/dist/esm/theme/presets.mjs.map +1 -0
  657. package/dist/esm/theme/presets.native.js +97 -0
  658. package/dist/esm/theme/presets.native.js.map +1 -0
  659. package/dist/esm/theme/radiusClass.mjs +99 -0
  660. package/dist/esm/theme/radiusClass.mjs.map +1 -0
  661. package/dist/esm/theme/radiusClass.native.js +105 -0
  662. package/dist/esm/theme/radiusClass.native.js.map +1 -0
  663. package/dist/esm/theme/radiusClassTable.generated.mjs +135 -0
  664. package/dist/esm/theme/radiusClassTable.generated.mjs.map +1 -0
  665. package/dist/esm/theme/radiusClassTable.generated.native.js +135 -0
  666. package/dist/esm/theme/radiusClassTable.generated.native.js.map +1 -0
  667. package/dist/esm/theme/ramps.mjs +48 -0
  668. package/dist/esm/theme/ramps.mjs.map +1 -0
  669. package/dist/esm/theme/ramps.native.js +49 -0
  670. package/dist/esm/theme/ramps.native.js.map +1 -0
  671. package/dist/esm/theme/readableColor.mjs +214 -0
  672. package/dist/esm/theme/readableColor.mjs.map +1 -0
  673. package/dist/esm/theme/readableColor.native.js +317 -0
  674. package/dist/esm/theme/readableColor.native.js.map +1 -0
  675. package/dist/esm/theme/recipeInputs.mjs +309 -0
  676. package/dist/esm/theme/recipeInputs.mjs.map +1 -0
  677. package/dist/esm/theme/recipeInputs.native.js +424 -0
  678. package/dist/esm/theme/recipeInputs.native.js.map +1 -0
  679. package/dist/esm/theme/recipes.mjs +2 -0
  680. package/dist/esm/theme/recipes.mjs.map +1 -0
  681. package/dist/esm/theme/recipes.native.js +2 -0
  682. package/dist/esm/theme/recipes.native.js.map +1 -0
  683. package/dist/esm/theme/resolveKnobs.mjs +730 -0
  684. package/dist/esm/theme/resolveKnobs.mjs.map +1 -0
  685. package/dist/esm/theme/resolveKnobs.native.js +744 -0
  686. package/dist/esm/theme/resolveKnobs.native.js.map +1 -0
  687. package/dist/esm/theme/scale/ScaleStyles.mjs +30 -0
  688. package/dist/esm/theme/scale/ScaleStyles.mjs.map +1 -0
  689. package/dist/esm/theme/scale/ScaleStyles.native.js +11 -0
  690. package/dist/esm/theme/scale/ScaleStyles.native.js.map +1 -0
  691. package/dist/esm/theme/scale/activeScale.mjs +28 -0
  692. package/dist/esm/theme/scale/activeScale.mjs.map +1 -0
  693. package/dist/esm/theme/scale/activeScale.native.js +53 -0
  694. package/dist/esm/theme/scale/activeScale.native.js.map +1 -0
  695. package/dist/esm/theme/scale/deriveRecipeInputs.mjs +86 -0
  696. package/dist/esm/theme/scale/deriveRecipeInputs.mjs.map +1 -0
  697. package/dist/esm/theme/scale/deriveRecipeInputs.native.js +126 -0
  698. package/dist/esm/theme/scale/deriveRecipeInputs.native.js.map +1 -0
  699. package/dist/esm/theme/scale/generateScale.mjs +85 -0
  700. package/dist/esm/theme/scale/generateScale.mjs.map +1 -0
  701. package/dist/esm/theme/scale/generateScale.native.js +168 -0
  702. package/dist/esm/theme/scale/generateScale.native.js.map +1 -0
  703. package/dist/esm/theme/scale/index.mjs +12 -0
  704. package/dist/esm/theme/scale/index.mjs.map +1 -0
  705. package/dist/esm/theme/scale/index.native.js +12 -0
  706. package/dist/esm/theme/scale/index.native.js.map +1 -0
  707. package/dist/esm/theme/scale/installScaleConfig.mjs +6 -0
  708. package/dist/esm/theme/scale/installScaleConfig.mjs.map +1 -0
  709. package/dist/esm/theme/scale/installScaleConfig.native.js +36 -0
  710. package/dist/esm/theme/scale/installScaleConfig.native.js.map +1 -0
  711. package/dist/esm/theme/scale/scaleAttribute.mjs +11 -0
  712. package/dist/esm/theme/scale/scaleAttribute.mjs.map +1 -0
  713. package/dist/esm/theme/scale/scaleAttribute.native.js +11 -0
  714. package/dist/esm/theme/scale/scaleAttribute.native.js.map +1 -0
  715. package/dist/esm/theme/scale/scaleCss.mjs +62 -0
  716. package/dist/esm/theme/scale/scaleCss.mjs.map +1 -0
  717. package/dist/esm/theme/scale/scaleCss.native.js +171 -0
  718. package/dist/esm/theme/scale/scaleCss.native.js.map +1 -0
  719. package/dist/esm/theme/scale/scaleFonts.mjs +60 -0
  720. package/dist/esm/theme/scale/scaleFonts.mjs.map +1 -0
  721. package/dist/esm/theme/scale/scaleFonts.native.js +126 -0
  722. package/dist/esm/theme/scale/scaleFonts.native.js.map +1 -0
  723. package/dist/esm/theme/scale/scaleInputs.mjs +189 -0
  724. package/dist/esm/theme/scale/scaleInputs.mjs.map +1 -0
  725. package/dist/esm/theme/scale/scaleInputs.native.js +191 -0
  726. package/dist/esm/theme/scale/scaleInputs.native.js.map +1 -0
  727. package/dist/esm/theme/scale/themeScales.mjs +109 -0
  728. package/dist/esm/theme/scale/themeScales.mjs.map +1 -0
  729. package/dist/esm/theme/scale/themeScales.native.js +155 -0
  730. package/dist/esm/theme/scale/themeScales.native.js.map +1 -0
  731. package/dist/esm/theme/scale/useActiveScale.mjs +51 -0
  732. package/dist/esm/theme/scale/useActiveScale.mjs.map +1 -0
  733. package/dist/esm/theme/scale/useActiveScale.native.js +57 -0
  734. package/dist/esm/theme/scale/useActiveScale.native.js.map +1 -0
  735. package/dist/esm/theme/schemeStore.mjs +59 -0
  736. package/dist/esm/theme/schemeStore.mjs.map +1 -0
  737. package/dist/esm/theme/schemeStore.native.js +73 -0
  738. package/dist/esm/theme/schemeStore.native.js.map +1 -0
  739. package/dist/esm/theme/shared.mjs +95 -0
  740. package/dist/esm/theme/shared.mjs.map +1 -0
  741. package/dist/esm/theme/shared.native.js +135 -0
  742. package/dist/esm/theme/shared.native.js.map +1 -0
  743. package/dist/esm/theme/sizeRecipes.mjs +112 -0
  744. package/dist/esm/theme/sizeRecipes.mjs.map +1 -0
  745. package/dist/esm/theme/sizeRecipes.native.js +184 -0
  746. package/dist/esm/theme/sizeRecipes.native.js.map +1 -0
  747. package/dist/esm/theme/subsetThemes.mjs +21 -0
  748. package/dist/esm/theme/subsetThemes.mjs.map +1 -0
  749. package/dist/esm/theme/subsetThemes.native.js +48 -0
  750. package/dist/esm/theme/subsetThemes.native.js.map +1 -0
  751. package/dist/esm/theme/theme.mjs +163 -0
  752. package/dist/esm/theme/theme.mjs.map +1 -0
  753. package/dist/esm/theme/theme.native.js +87 -0
  754. package/dist/esm/theme/theme.native.js.map +1 -0
  755. package/dist/esm/theme/themeValue.mjs +25 -0
  756. package/dist/esm/theme/themeValue.mjs.map +1 -0
  757. package/dist/esm/theme/themeValue.native.js +44 -0
  758. package/dist/esm/theme/themeValue.native.js.map +1 -0
  759. package/dist/esm/theme/tileSizes.mjs +167 -0
  760. package/dist/esm/theme/tileSizes.mjs.map +1 -0
  761. package/dist/esm/theme/tileSizes.native.js +192 -0
  762. package/dist/esm/theme/tileSizes.native.js.map +1 -0
  763. package/dist/esm/theme/touchManipulation.mjs +7 -0
  764. package/dist/esm/theme/touchManipulation.mjs.map +1 -0
  765. package/dist/esm/theme/touchManipulation.native.js +7 -0
  766. package/dist/esm/theme/touchManipulation.native.js.map +1 -0
  767. package/dist/esm/theme/transitionProps.mjs +25 -0
  768. package/dist/esm/theme/transitionProps.mjs.map +1 -0
  769. package/dist/esm/theme/transitionProps.native.js +53 -0
  770. package/dist/esm/theme/transitionProps.native.js.map +1 -0
  771. package/dist/esm/theme/useColorScale.mjs +22 -0
  772. package/dist/esm/theme/useColorScale.mjs.map +1 -0
  773. package/dist/esm/theme/useColorScale.native.js +5 -0
  774. package/dist/esm/theme/useColorScale.native.js.map +1 -0
  775. package/dist/esm/theme/usePresetSwitch.mjs +45 -0
  776. package/dist/esm/theme/usePresetSwitch.mjs.map +1 -0
  777. package/dist/esm/theme/usePresetSwitch.native.js +22 -0
  778. package/dist/esm/theme/usePresetSwitch.native.js.map +1 -0
  779. package/dist/esm/theme/useResolvedKnobs.mjs +111 -0
  780. package/dist/esm/theme/useResolvedKnobs.mjs.map +1 -0
  781. package/dist/esm/theme/useResolvedKnobs.native.js +145 -0
  782. package/dist/esm/theme/useResolvedKnobs.native.js.map +1 -0
  783. package/dist/esm/theme/useSchemePreference.mjs +24 -0
  784. package/dist/esm/theme/useSchemePreference.mjs.map +1 -0
  785. package/dist/esm/theme/useSchemePreference.native.js +52 -0
  786. package/dist/esm/theme/useSchemePreference.native.js.map +1 -0
  787. package/dist/esm/theme/useTheme.mjs +127 -0
  788. package/dist/esm/theme/useTheme.mjs.map +1 -0
  789. package/dist/esm/theme/useTheme.native.js +66 -0
  790. package/dist/esm/theme/useTheme.native.js.map +1 -0
  791. package/dist/esm/theme/useTouchSurface.mjs +8 -0
  792. package/dist/esm/theme/useTouchSurface.mjs.map +1 -0
  793. package/dist/esm/theme/useTouchSurface.native.js +8 -0
  794. package/dist/esm/theme/useTouchSurface.native.js.map +1 -0
  795. package/dist/esm/theme/v3TokenRoles.mjs +39 -0
  796. package/dist/esm/theme/v3TokenRoles.mjs.map +1 -0
  797. package/dist/esm/theme/v3TokenRoles.native.js +39 -0
  798. package/dist/esm/theme/v3TokenRoles.native.js.map +1 -0
  799. package/package.json +56 -12
  800. package/src/theme/scale/activeScale.spec.ts +33 -0
  801. package/src/theme/scale/activeScale.ts +19 -0
  802. package/src/theme/scale/index.ts +6 -1
  803. package/src/theme/subsetThemes.spec.ts +81 -0
  804. package/src/theme/subsetThemes.ts +13 -1
  805. package/types/theme/scale/activeScale.d.ts +8 -0
  806. package/types/theme/scale/activeScale.d.ts.map +1 -1
  807. package/types/theme/scale/index.d.ts +1 -1
  808. package/types/theme/scale/index.d.ts.map +1 -1
  809. package/types/theme/subsetThemes.d.ts +10 -1
  810. package/types/theme/subsetThemes.d.ts.map +1 -1
@@ -0,0 +1,1140 @@
1
+ import * as Colors from "@tamagui/colors";
2
+ import { PALETTE_BACKGROUND_OFFSET, createThemes as tamaguiCreateThemes } from "@tamagui/theme-builder";
3
+ import { defaultChildrenThemes, v5Templates } from "@tamagui/themes/v5";
4
+ import { aaTextContrastRatio, apcaContrast, contrastRatio, fillLabelLc, holdInkFloor, inSwitchOffBand, isLightGround, minContrastRatio, normalizeToHex, pickReadableForeground, plateContrastRatio, relativeLuminance, switchOffFillAlpha, systemFillHex, systemFillLuminance } from "./colorRules.native.js";
5
+ import { pickSecondaryInk } from "./defaults/builderOptions.native.js";
6
+ import { themeRampHues } from "./ramps.native.js";
7
+ var intentInkFloor = {
8
+ /** Stored hsla(41, 99%, 30%, 1); 4.54:1 on $color2, dE76 2.54. */
9
+ warning: "#986801",
10
+ /** Stored hsla(154, 63%, 31%, 1); 4.53:1 on $color2, dE76 0.82. */
11
+ success: "#1d8156"
12
+ };
13
+ function withIntentInkFloor(palette, ink) {
14
+ if (palette.length !== 12) return palette;
15
+ var stepped = [...palette];
16
+ stepped[10] = ink;
17
+ return stepped;
18
+ }
19
+ var lightSurfaceGrouped = {
20
+ ...v5Templates.light_surface1,
21
+ background: PALETTE_BACKGROUND_OFFSET,
22
+ backgroundHover: PALETTE_BACKGROUND_OFFSET + 1,
23
+ backgroundPress: PALETTE_BACKGROUND_OFFSET + 2,
24
+ backgroundFocus: PALETTE_BACKGROUND_OFFSET,
25
+ backgroundActive: PALETTE_BACKGROUND_OFFSET
26
+ };
27
+ var houseTemplates = {
28
+ ...v5Templates,
29
+ light_surface1: lightSurfaceGrouped
30
+ };
31
+ var houseComponentThemes = {
32
+ Button: {
33
+ template: "surface2"
34
+ },
35
+ Input: {
36
+ template: "surface1"
37
+ },
38
+ TextArea: {
39
+ template: "surface1"
40
+ },
41
+ Progress: {
42
+ template: "surface2"
43
+ },
44
+ ProgressIndicator: {
45
+ template: "surface3"
46
+ },
47
+ Slider: {
48
+ template: "surface2"
49
+ },
50
+ SliderActive: {
51
+ template: "surface3"
52
+ },
53
+ SliderThumb: {
54
+ template: "surface1"
55
+ },
56
+ Switch: {
57
+ template: "surface2"
58
+ },
59
+ Card: {
60
+ template: "surface1"
61
+ },
62
+ ListItem: {
63
+ template: "surface1"
64
+ },
65
+ SelectTrigger: {
66
+ template: "surface1"
67
+ },
68
+ SelectItem: {
69
+ template: "surface1"
70
+ },
71
+ InputContainerFrame: {
72
+ template: "surface1"
73
+ }
74
+ };
75
+ var houseGrandChildrenThemes = {
76
+ active: {
77
+ template: "surface3"
78
+ },
79
+ alt1: {
80
+ template: "surface1"
81
+ },
82
+ alt2: {
83
+ template: "surface2"
84
+ }
85
+ };
86
+ function sanitizeGetTheme(getTheme) {
87
+ return function (props) {
88
+ var out = {};
89
+ var _iteratorNormalCompletion = true,
90
+ _didIteratorError = false,
91
+ _iteratorError = void 0;
92
+ try {
93
+ for (var _iterator = Object.entries(getTheme(props))[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
94
+ var [key, value] = _step.value;
95
+ if (value != null) out[key] = value;
96
+ }
97
+ } catch (err) {
98
+ _didIteratorError = true;
99
+ _iteratorError = err;
100
+ } finally {
101
+ try {
102
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
103
+ _iterator.return();
104
+ }
105
+ } finally {
106
+ if (_didIteratorError) {
107
+ throw _iteratorError;
108
+ }
109
+ }
110
+ }
111
+ return out;
112
+ };
113
+ }
114
+ var tintHueNames = /* @__PURE__ */new Set(["amber", "blue", "bronze", "brown", "crimson", "cyan", "gold", "grass", "gray", "green", "indigo", "lime", "mauve", "mint", "olive", "orange", "pink", "plum", "purple", "red", "sage", "sand", "sky", "slate", "teal", "tomato", "violet", "yellow"]);
115
+ var tintNeutralTextKeys = ["color", "colorHover", "colorPress", "colorFocus", "color11", "color12", "placeholderColor"];
116
+ function neutralizeTintText(themes) {
117
+ var out = {
118
+ ...themes
119
+ };
120
+ var _iteratorNormalCompletion = true,
121
+ _didIteratorError = false,
122
+ _iteratorError = void 0;
123
+ try {
124
+ for (var _iterator = Object.entries(themes)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
125
+ var [name, theme] = _step.value;
126
+ var parts = name.split("_");
127
+ if (parts.length < 2) continue;
128
+ var scheme = parts[0];
129
+ if (scheme !== "light" && scheme !== "dark") continue;
130
+ if (!tintHueNames.has(parts[1])) continue;
131
+ var base = themes[scheme];
132
+ if (!base) continue;
133
+ var patched = {
134
+ ...theme
135
+ };
136
+ var _iteratorNormalCompletion1 = true,
137
+ _didIteratorError1 = false,
138
+ _iteratorError1 = void 0;
139
+ try {
140
+ for (var _iterator1 = tintNeutralTextKeys[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = true) {
141
+ var key = _step1.value;
142
+ if (key in patched && base[key] != null) patched[key] = base[key];
143
+ }
144
+ } catch (err) {
145
+ _didIteratorError1 = true;
146
+ _iteratorError1 = err;
147
+ } finally {
148
+ try {
149
+ if (!_iteratorNormalCompletion1 && _iterator1.return != null) {
150
+ _iterator1.return();
151
+ }
152
+ } finally {
153
+ if (_didIteratorError1) {
154
+ throw _iteratorError1;
155
+ }
156
+ }
157
+ }
158
+ if ("textMuted" in patched) patched.textMuted = pickSecondaryInk(patched, base);
159
+ out[name] = patched;
160
+ }
161
+ } catch (err) {
162
+ _didIteratorError = true;
163
+ _iteratorError = err;
164
+ } finally {
165
+ try {
166
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
167
+ _iterator.return();
168
+ }
169
+ } finally {
170
+ if (_didIteratorError) {
171
+ throw _iteratorError;
172
+ }
173
+ }
174
+ }
175
+ return out;
176
+ }
177
+ var semanticIntentNames = /* @__PURE__ */new Set(["error", "warning", "success"]);
178
+ var entryControlNames = /* @__PURE__ */new Set(["Input", "TextArea"]);
179
+ function neutralizeSemanticEntryText(themes) {
180
+ var out = {
181
+ ...themes
182
+ };
183
+ var _iteratorNormalCompletion = true,
184
+ _didIteratorError = false,
185
+ _iteratorError = void 0;
186
+ try {
187
+ for (var _iterator = Object.entries(themes)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
188
+ var [name, theme] = _step.value;
189
+ var [scheme, intent, component, ...rest] = name.split("_");
190
+ if (rest.length > 0 || scheme !== "light" && scheme !== "dark") continue;
191
+ if (!intent || !semanticIntentNames.has(intent)) continue;
192
+ var base = themes[scheme];
193
+ if (!base) continue;
194
+ if (component === void 0) {
195
+ if (base.placeholderColor != null) out[name] = {
196
+ ...theme,
197
+ placeholderColor: base.placeholderColor
198
+ };
199
+ continue;
200
+ }
201
+ if (!entryControlNames.has(component)) continue;
202
+ var neutral = {
203
+ ...base,
204
+ ...themes[`${scheme}_${component}`]
205
+ };
206
+ var patched = {
207
+ ...theme
208
+ };
209
+ var _iteratorNormalCompletion1 = true,
210
+ _didIteratorError1 = false,
211
+ _iteratorError1 = void 0;
212
+ try {
213
+ for (var _iterator1 = tintNeutralTextKeys[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = true) {
214
+ var key = _step1.value;
215
+ if (neutral[key] != null) patched[key] = neutral[key];
216
+ }
217
+ } catch (err) {
218
+ _didIteratorError1 = true;
219
+ _iteratorError1 = err;
220
+ } finally {
221
+ try {
222
+ if (!_iteratorNormalCompletion1 && _iterator1.return != null) {
223
+ _iterator1.return();
224
+ }
225
+ } finally {
226
+ if (_didIteratorError1) {
227
+ throw _iteratorError1;
228
+ }
229
+ }
230
+ }
231
+ out[name] = patched;
232
+ }
233
+ } catch (err) {
234
+ _didIteratorError = true;
235
+ _iteratorError = err;
236
+ } finally {
237
+ try {
238
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
239
+ _iterator.return();
240
+ }
241
+ } finally {
242
+ if (_didIteratorError) {
243
+ throw _iteratorError;
244
+ }
245
+ }
246
+ }
247
+ return out;
248
+ }
249
+ function luminanceOf(color) {
250
+ var hex = color ? normalizeToHex(color) : null;
251
+ return hex ? relativeLuminance(hex) : null;
252
+ }
253
+ function nearestHoldingStep(preferred, steps, holds) {
254
+ var preferredLum = luminanceOf(preferred);
255
+ if (preferredLum === null || holds(preferredLum)) return preferred;
256
+ var best = preferred;
257
+ var bestDistance = Number.POSITIVE_INFINITY;
258
+ var _iteratorNormalCompletion = true,
259
+ _didIteratorError = false,
260
+ _iteratorError = void 0;
261
+ try {
262
+ for (var _iterator = steps[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
263
+ var step = _step.value;
264
+ var lum = luminanceOf(step);
265
+ if (step === void 0 || lum === null || !holds(lum)) continue;
266
+ var distance = Math.abs(lum - preferredLum);
267
+ if (distance < bestDistance) {
268
+ bestDistance = distance;
269
+ best = step;
270
+ }
271
+ }
272
+ } catch (err) {
273
+ _didIteratorError = true;
274
+ _iteratorError = err;
275
+ } finally {
276
+ try {
277
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
278
+ _iterator.return();
279
+ }
280
+ } finally {
281
+ if (_didIteratorError) {
282
+ throw _iteratorError;
283
+ }
284
+ }
285
+ }
286
+ return best;
287
+ }
288
+ function holdAccentFloor(themes) {
289
+ var _loop = function (_i2, _iter2) {
290
+ var scheme = _iter2[_i2];
291
+ var base = themes[scheme];
292
+ if (!(base === null || base === void 0 ? void 0 : base.accentBackground) || !base.accentColor) return "continue";
293
+ var paper = luminanceOf(base.color1);
294
+ var ink = luminanceOf(base.color12);
295
+ var surfaces = [base.color1, base.color2, base.color3, base.color4].map(luminanceOf);
296
+ if (paper === null || ink === null || surfaces.some(function (lum) {
297
+ return lum === null;
298
+ })) return "continue";
299
+ var steps = Array.from({
300
+ length: 12
301
+ }, function (_, index) {
302
+ return base[`accent${index + 1}`];
303
+ });
304
+ var fill = nearestHoldingStep(base.accentBackground, steps.slice(0, 10), function (lum) {
305
+ return Math.max(contrastRatio(lum, paper), contrastRatio(lum, ink)) >= aaTextContrastRatio && contrastRatio(lum, paper) >= minContrastRatio;
306
+ });
307
+ var accentInk = nearestHoldingStep(base.accentColor, steps, function (lum) {
308
+ return surfaces.every(function (surface) {
309
+ return contrastRatio(lum, surface) >= aaTextContrastRatio;
310
+ });
311
+ });
312
+ if (fill === base.accentBackground && accentInk === base.accentColor) return "continue";
313
+ var _iteratorNormalCompletion = true,
314
+ _didIteratorError = false,
315
+ _iteratorError = void 0;
316
+ try {
317
+ for (var _iterator = Object.entries(themes)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
318
+ var [name, theme] = _step.value;
319
+ if (name !== scheme && !name.startsWith(`${scheme}_`)) continue;
320
+ var inheritsFill = theme.accentBackground === base.accentBackground;
321
+ var inheritsInk = theme.accentColor === base.accentColor;
322
+ if (!inheritsFill && !inheritsInk) continue;
323
+ out[name] = {
324
+ ...theme,
325
+ ...(inheritsFill ? {
326
+ accentBackground: fill
327
+ } : null),
328
+ ...(inheritsInk ? {
329
+ accentColor: accentInk
330
+ } : null)
331
+ };
332
+ }
333
+ } catch (err) {
334
+ _didIteratorError = true;
335
+ _iteratorError = err;
336
+ } finally {
337
+ try {
338
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
339
+ _iterator.return();
340
+ }
341
+ } finally {
342
+ if (_didIteratorError) {
343
+ throw _iteratorError;
344
+ }
345
+ }
346
+ }
347
+ };
348
+ var out = {
349
+ ...themes
350
+ };
351
+ for (var _i = 0, _iter = ["light", "dark"]; _i < _iter.length; _i++) _loop(_i, _iter);
352
+ return out;
353
+ }
354
+ var selectionSurfaceContrastRatio = 1.16;
355
+ var selectionSurfaceScope = /^(light|dark)(_[a-z]+)?$/;
356
+ function holdSelectionSurface(themes) {
357
+ var out = {
358
+ ...themes
359
+ };
360
+ var _iteratorNormalCompletion = true,
361
+ _didIteratorError = false,
362
+ _iteratorError = void 0;
363
+ try {
364
+ var _loop = function () {
365
+ var [scopeName, scope] = _step.value;
366
+ if (!selectionSurfaceScope.test(scopeName) || /_(accent|active)$/.test(scopeName)) return "continue";
367
+ var page = luminanceOf(scope.background);
368
+ var [surface, next, last] = [scope.color4, scope.color5, scope.color6].map(function (color) {
369
+ return color ? normalizeToHex(color) : null;
370
+ });
371
+ if (page === null || !surface || !next || !last) return "continue";
372
+ if (contrastRatio(relativeLuminance(surface), page) >= selectionSurfaceContrastRatio) return "continue";
373
+ var candidates = [...Array.from({
374
+ length: 20
375
+ }, function (_, index) {
376
+ return mixHex(surface, next, (index + 1) / 20);
377
+ }), ...Array.from({
378
+ length: 20
379
+ }, function (_, index) {
380
+ return mixHex(next, last, (index + 1) / 20);
381
+ })];
382
+ var held = candidates.find(function (candidate) {
383
+ return contrastRatio(relativeLuminance(candidate), page) >= selectionSurfaceContrastRatio;
384
+ });
385
+ if (!held) return "continue";
386
+ var _iteratorNormalCompletion2 = true,
387
+ _didIteratorError2 = false,
388
+ _iteratorError2 = void 0;
389
+ try {
390
+ for (var _iterator2 = Object.entries(themes)[Symbol.iterator](), _step1; !(_iteratorNormalCompletion2 = (_step1 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) {
391
+ var [name, theme] = _step1.value;
392
+ if (name !== scopeName && !name.startsWith(`${scopeName}_`)) continue;
393
+ if (theme.color4 !== scope.color4) continue;
394
+ out[name] = {
395
+ ...out[name],
396
+ color4: held,
397
+ ...(theme.borderColor === scope.color4 ? {
398
+ borderColor: held
399
+ } : null)
400
+ };
401
+ }
402
+ } catch (err) {
403
+ _didIteratorError2 = true;
404
+ _iteratorError2 = err;
405
+ } finally {
406
+ try {
407
+ if (!_iteratorNormalCompletion2 && _iterator2.return != null) {
408
+ _iterator2.return();
409
+ }
410
+ } finally {
411
+ if (_didIteratorError2) {
412
+ throw _iteratorError2;
413
+ }
414
+ }
415
+ }
416
+ };
417
+ for (var _iterator = Object.entries(themes)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) _loop();
418
+ } catch (err) {
419
+ _didIteratorError = true;
420
+ _iteratorError = err;
421
+ } finally {
422
+ try {
423
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
424
+ _iterator.return();
425
+ }
426
+ } finally {
427
+ if (_didIteratorError) {
428
+ throw _iteratorError;
429
+ }
430
+ }
431
+ }
432
+ return out;
433
+ }
434
+ var selectedTintContrastRatio = 1.1;
435
+ var neutralSelectedTintContrastRatio = 1.25;
436
+ var achromaticChannelSpread = 8;
437
+ function isAchromaticRamp(steps) {
438
+ return steps.every(function (step) {
439
+ var hex = step ? normalizeToHex(step) : null;
440
+ if (!hex) return false;
441
+ var channels = [1, 3, 5].map(function (offset) {
442
+ return Number.parseInt(hex.slice(offset, offset + 2), 16);
443
+ });
444
+ return Math.max(...channels) - Math.min(...channels) <= achromaticChannelSpread;
445
+ });
446
+ }
447
+ function holdSelectedState(themes) {
448
+ var _loop = function (_i2, _iter2) {
449
+ var scheme = _iter2[_i2];
450
+ var base = themes[scheme];
451
+ if (!(base === null || base === void 0 ? void 0 : base.accentColor)) return "continue";
452
+ var steps = Array.from({
453
+ length: 12
454
+ }, function (_, index) {
455
+ return base[`accent${index + 1}`];
456
+ });
457
+ var paint = selectedPaint(base, steps, base.accentColor);
458
+ if (paint) out[scheme] = {
459
+ ...base,
460
+ ...paint
461
+ };
462
+ };
463
+ var out = {
464
+ ...themes
465
+ };
466
+ for (var _i = 0, _iter = ["light", "dark"]; _i < _iter.length; _i++) _loop(_i, _iter);
467
+ return out;
468
+ }
469
+ function selectedPaint(scope, steps, accentColor) {
470
+ var page = luminanceOf(scope.color1);
471
+ var neutral = luminanceOf(scope.color4);
472
+ if (page === null || neutral === null) return void 0;
473
+ var grey = isAchromaticRamp(steps);
474
+ var offNeutral = grey ? neutralSelectedTintContrastRatio : selectedTintContrastRatio;
475
+ var tint = nearestHoldingStep(scope.color4, steps, function (lum2) {
476
+ return contrastRatio(lum2, page) >= selectedTintContrastRatio && contrastRatio(lum2, neutral) >= offNeutral;
477
+ });
478
+ var tintLum = luminanceOf(tint);
479
+ if (tint === scope.color4 || tintLum === null) return void 0;
480
+ if (grey) {
481
+ var strongest = tint;
482
+ var strongestRatio = 0;
483
+ var _iteratorNormalCompletion = true,
484
+ _didIteratorError = false,
485
+ _iteratorError = void 0;
486
+ try {
487
+ for (var _iterator = steps[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
488
+ var step = _step.value;
489
+ var lum = luminanceOf(step);
490
+ if (step === void 0 || lum === null) continue;
491
+ var ratio = contrastRatio(lum, tintLum);
492
+ if (ratio > strongestRatio) {
493
+ strongest = step;
494
+ strongestRatio = ratio;
495
+ }
496
+ }
497
+ } catch (err) {
498
+ _didIteratorError = true;
499
+ _iteratorError = err;
500
+ } finally {
501
+ try {
502
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
503
+ _iterator.return();
504
+ }
505
+ } finally {
506
+ if (_didIteratorError) {
507
+ throw _iteratorError;
508
+ }
509
+ }
510
+ }
511
+ if (strongestRatio >= aaTextContrastRatio) return {
512
+ selectedBackground: tint,
513
+ selectedColor: strongest
514
+ };
515
+ }
516
+ var ink = nearestHoldingStep(accentColor, steps, function (lum2) {
517
+ return contrastRatio(lum2, tintLum) >= aaTextContrastRatio;
518
+ });
519
+ return {
520
+ selectedBackground: tint,
521
+ selectedColor: ink
522
+ };
523
+ }
524
+ var switchStateContrastRatio = 1.5;
525
+ var switchRaisedAlphas = [0.16, 0.2, 0.24, 0.28, 0.32, 0.36, 0.4];
526
+ var switchRaisedAlphaStep = 0.04;
527
+ function raisedGrounds(themes, scheme) {
528
+ var _themes_scheme;
529
+ if (scheme === "light") return [];
530
+ var hues = Object.entries(themes).filter(function (param) {
531
+ var [name] = param;
532
+ return new RegExp(`^${scheme}_[a-z]+$`).test(name);
533
+ }).filter(function (param) {
534
+ var [name] = param;
535
+ return !/_(accent|active)$/.test(name);
536
+ });
537
+ return [(_themes_scheme = themes[scheme]) === null || _themes_scheme === void 0 ? void 0 : _themes_scheme.color4, ...hues.map(function (param) {
538
+ var [, theme] = param;
539
+ return theme.color4;
540
+ })].filter(function (color) {
541
+ return typeof color === "string";
542
+ });
543
+ }
544
+ function holdSwitchTrack(themes) {
545
+ var out = {
546
+ ...themes
547
+ };
548
+ for (var _i = 0, _iter = ["light", "dark"]; _i < _iter.length; _i++) {
549
+ var scheme = _iter[_i];
550
+ var base = themes[scheme];
551
+ if (!base) continue;
552
+ var paint = switchTrackPaint(base, base.accentBackground, base.background, raisedGrounds(themes, scheme));
553
+ if (paint) out[scheme] = {
554
+ ...base,
555
+ ...paint
556
+ };
557
+ }
558
+ return out;
559
+ }
560
+ function switchTrackPaint(base, onFill, ground) {
561
+ var raised = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : [];
562
+ var _ref, _inBand_find;
563
+ var on = luminanceOf(onFill);
564
+ if (!ground || on === null) return void 0;
565
+ var alpha = switchOffFillAlpha[isLightGround(ground) ? "light" : "dark"];
566
+ var target = systemFillLuminance(ground, alpha);
567
+ if (target === null) return void 0;
568
+ var raisedLums = raised.map(function (color) {
569
+ return luminanceOf(color);
570
+ }).filter(function (lum) {
571
+ return lum !== null;
572
+ });
573
+ var greys = Array.from({
574
+ length: 12
575
+ }, function (_, index) {
576
+ return index + 1;
577
+ }).map(function (step) {
578
+ return {
579
+ color: base[`gray${step}`],
580
+ lum: luminanceOf(base[`gray${step}`]),
581
+ hover: base[`gray${Math.max(step - 1, 1)}`],
582
+ press: base[`gray${Math.min(step + 1, 12)}`]
583
+ };
584
+ }).filter(function (entry) {
585
+ return entry.lum !== null;
586
+ });
587
+ var fills = raised[0] ? switchRaisedAlphas.flatMap(function (fillAlpha) {
588
+ var color = systemFillHex(raised[0], fillAlpha);
589
+ var hover = systemFillHex(raised[0], fillAlpha - switchRaisedAlphaStep);
590
+ var press = systemFillHex(raised[0], fillAlpha + switchRaisedAlphaStep);
591
+ var lum = luminanceOf(color !== null && color !== void 0 ? color : void 0);
592
+ return color && hover && press && lum !== null ? [{
593
+ color,
594
+ lum,
595
+ hover,
596
+ press
597
+ }] : [];
598
+ }) : [];
599
+ var byTarget = function byTarget2(a, b) {
600
+ return Math.abs(a.lum - target) - Math.abs(b.lum - target);
601
+ };
602
+ var steps = [...greys].sort(byTarget);
603
+ var inBand = [...greys, ...fills].filter(function (entry) {
604
+ return inSwitchOffBand(entry.color, ground);
605
+ }).filter(function (entry) {
606
+ return raisedLums.every(function (lum) {
607
+ return contrastRatio(entry.lum, lum) >= plateContrastRatio;
608
+ });
609
+ }).sort(byTarget);
610
+ var pick = (_ref = (_inBand_find = inBand.find(function (entry) {
611
+ return contrastRatio(entry.lum, on) >= switchStateContrastRatio;
612
+ })) !== null && _inBand_find !== void 0 ? _inBand_find : inBand[0]) !== null && _ref !== void 0 ? _ref : steps[0];
613
+ if (!pick) return void 0;
614
+ return {
615
+ switchTrackOff: pick.color,
616
+ switchTrackOffHover: pick.hover,
617
+ switchTrackOffPress: pick.press
618
+ };
619
+ }
620
+ var syntaxInkHues = ["purple", "green", "blue", "orange", "red"];
621
+ function mixHex(from, to, share) {
622
+ var channel = function channel2(offset) {
623
+ return Math.round(Number.parseInt(from.slice(offset, offset + 2), 16) * (1 - share) + Number.parseInt(to.slice(offset, offset + 2), 16) * share).toString(16).padStart(2, "0");
624
+ };
625
+ return `#${channel(1)}${channel(3)}${channel(5)}`;
626
+ }
627
+ function holdSyntaxFloor(themes) {
628
+ var out = {
629
+ ...themes
630
+ };
631
+ var _iteratorNormalCompletion = true,
632
+ _didIteratorError = false,
633
+ _iteratorError = void 0;
634
+ try {
635
+ for (var _iterator = Object.entries(themes)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
636
+ var [name, theme] = _step.value;
637
+ var surface = luminanceOf(theme.color3);
638
+ if (surface === null) continue;
639
+ var ink = {};
640
+ var _iteratorNormalCompletion1 = true,
641
+ _didIteratorError1 = false,
642
+ _iteratorError1 = void 0;
643
+ try {
644
+ for (var _iterator1 = syntaxInkHues[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = true) {
645
+ var hue = _step1.value;
646
+ var from = theme[`${hue}11`] ? normalizeToHex(theme[`${hue}11`]) : null;
647
+ var to = theme[`${hue}12`] ? normalizeToHex(theme[`${hue}12`]) : null;
648
+ var wash = luminanceOf(theme[`${hue}3`]);
649
+ if (!from || !to || wash === null) continue;
650
+ for (var step = 0; step <= 20; step++) {
651
+ var candidate = mixHex(from, to, step / 20);
652
+ var lum = relativeLuminance(candidate);
653
+ if (contrastRatio(lum, surface) >= aaTextContrastRatio && contrastRatio(lum, wash) >= aaTextContrastRatio) {
654
+ ink[`syntax${hue[0].toUpperCase()}${hue.slice(1)}`] = candidate;
655
+ break;
656
+ }
657
+ }
658
+ }
659
+ } catch (err) {
660
+ _didIteratorError1 = true;
661
+ _iteratorError1 = err;
662
+ } finally {
663
+ try {
664
+ if (!_iteratorNormalCompletion1 && _iterator1.return != null) {
665
+ _iterator1.return();
666
+ }
667
+ } finally {
668
+ if (_didIteratorError1) {
669
+ throw _iteratorError1;
670
+ }
671
+ }
672
+ }
673
+ if (Object.keys(ink).length > 0) out[name] = {
674
+ ...theme,
675
+ ...ink
676
+ };
677
+ }
678
+ } catch (err) {
679
+ _didIteratorError = true;
680
+ _iteratorError = err;
681
+ } finally {
682
+ try {
683
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
684
+ _iterator.return();
685
+ }
686
+ } finally {
687
+ if (_didIteratorError) {
688
+ throw _iteratorError;
689
+ }
690
+ }
691
+ }
692
+ return out;
693
+ }
694
+ var namedInkHues = themeRampHues;
695
+ function holdNamedInkFloor(themes) {
696
+ var out = {
697
+ ...themes
698
+ };
699
+ var _iteratorNormalCompletion = true,
700
+ _didIteratorError = false,
701
+ _iteratorError = void 0;
702
+ try {
703
+ for (var _iterator = Object.entries(themes)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
704
+ var [name, theme] = _step.value;
705
+ var surfaces = [luminanceOf(theme.background), luminanceOf(theme.color3)];
706
+ if (surfaces.some(function (surface) {
707
+ return surface === null;
708
+ })) continue;
709
+ var ink = {};
710
+ var _iteratorNormalCompletion1 = true,
711
+ _didIteratorError1 = false,
712
+ _iteratorError1 = void 0;
713
+ try {
714
+ for (var _iterator1 = namedInkHues[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = true) {
715
+ var _loop = function (step2) {
716
+ var candidate = mixHex(from, to, step2 / 20);
717
+ var lum = relativeLuminance(candidate);
718
+ if (surfaces.every(function (surface) {
719
+ return contrastRatio(lum, surface) >= aaTextContrastRatio;
720
+ })) {
721
+ if (step2 > 0) ink[`${hue}11`] = candidate;
722
+ return "break";
723
+ }
724
+ };
725
+ var hue = _step1.value;
726
+ var from = theme[`${hue}11`] ? normalizeToHex(theme[`${hue}11`]) : null;
727
+ var to = theme[`${hue}12`] ? normalizeToHex(theme[`${hue}12`]) : null;
728
+ if (!from || !to) continue;
729
+ for (var step = 0; step <= 20; step++) {
730
+ var _ret = _loop(step);
731
+ if (_ret === "break") break;
732
+ }
733
+ }
734
+ } catch (err) {
735
+ _didIteratorError1 = true;
736
+ _iteratorError1 = err;
737
+ } finally {
738
+ try {
739
+ if (!_iteratorNormalCompletion1 && _iterator1.return != null) {
740
+ _iterator1.return();
741
+ }
742
+ } finally {
743
+ if (_didIteratorError1) {
744
+ throw _iteratorError1;
745
+ }
746
+ }
747
+ }
748
+ if (Object.keys(ink).length > 0) out[name] = {
749
+ ...theme,
750
+ ...ink
751
+ };
752
+ }
753
+ } catch (err) {
754
+ _didIteratorError = true;
755
+ _iteratorError = err;
756
+ } finally {
757
+ try {
758
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
759
+ _iterator.return();
760
+ }
761
+ } finally {
762
+ if (_didIteratorError) {
763
+ throw _iteratorError;
764
+ }
765
+ }
766
+ }
767
+ return out;
768
+ }
769
+ function walkToHoldingInk(step11, step12, holds) {
770
+ var from = normalizeToHex(step11);
771
+ var to = normalizeToHex(step12);
772
+ if (!from || !to) return null;
773
+ if (holds(relativeLuminance(from))) return step11;
774
+ for (var step = 1; step <= 20; step++) {
775
+ var candidate = mixHex(from, to, step / 20);
776
+ if (holds(relativeLuminance(candidate))) return candidate;
777
+ }
778
+ return null;
779
+ }
780
+ function holdFillLabel(preferred, steps, labels, paper) {
781
+ var preferredLum = luminanceOf(preferred);
782
+ if (preferredLum === null) return void 0;
783
+ var labelOn = function labelOn2(step2) {
784
+ return labels.find(function (label2) {
785
+ var lum2 = luminanceOf(label2);
786
+ var stepLum = luminanceOf(step2);
787
+ return lum2 !== null && stepLum !== null && contrastRatio(lum2, stepLum) >= aaTextContrastRatio && Math.abs(apcaContrast(label2, step2)) >= fillLabelLc;
788
+ });
789
+ };
790
+ var best;
791
+ var bestDistance = Number.POSITIVE_INFINITY;
792
+ for (var _i = 0, _iter = [preferred, ...steps]; _i < _iter.length; _i++) {
793
+ var step = _iter[_i];
794
+ var lum = luminanceOf(step);
795
+ if (step === void 0 || lum === null || contrastRatio(lum, paper) < minContrastRatio) continue;
796
+ var label = labelOn(step);
797
+ var distance = Math.abs(lum - preferredLum);
798
+ if (label && distance < bestDistance) {
799
+ bestDistance = distance;
800
+ best = {
801
+ fill: step,
802
+ label
803
+ };
804
+ }
805
+ }
806
+ return best;
807
+ }
808
+ function holdColorThemeAccent(themes) {
809
+ var _loop = function (_i2, _iter2) {
810
+ var scheme = _iter2[_i2];
811
+ var base = themes[scheme];
812
+ if (!base) return "continue";
813
+ var _iteratorNormalCompletion = true,
814
+ _didIteratorError = false,
815
+ _iteratorError = void 0;
816
+ try {
817
+ var _loop2 = function () {
818
+ var hue = _step.value;
819
+ var _ref, _walkToHoldingInk, _ref1;
820
+ var scopeName = `${scheme}_${hue}`;
821
+ var scope = themes[scopeName];
822
+ var ramp = Array.from({
823
+ length: 12
824
+ }, function (_, index) {
825
+ return base[`${hue}${index + 1}`];
826
+ });
827
+ if (!scope || ramp.some(function (step) {
828
+ return !step;
829
+ })) return "continue";
830
+ var paper = luminanceOf(scope.color1);
831
+ var ink = luminanceOf(scope.color12);
832
+ var surfaces = [scope.color1, scope.color2, scope.color3, scope.color4].map(luminanceOf);
833
+ if (paper === null || ink === null || surfaces.some(function (lum) {
834
+ return lum === null;
835
+ })) return "continue";
836
+ var labels = [scope.color1, scope.color12].sort(function (a, b) {
837
+ return luminanceOf(b) - luminanceOf(a);
838
+ });
839
+ var solid = holdFillLabel(ramp[8], ramp.slice(0, 11), labels, paper);
840
+ var holdsInk = function holdsInk2(lum) {
841
+ return surfaces.every(function (surface) {
842
+ return contrastRatio(lum, surface) >= aaTextContrastRatio;
843
+ });
844
+ };
845
+ var fill = (_ref = solid === null || solid === void 0 ? void 0 : solid.fill) !== null && _ref !== void 0 ? _ref : nearestHoldingStep(ramp[8], ramp.slice(0, 11), function (lum) {
846
+ return Math.max(contrastRatio(lum, paper), contrastRatio(lum, ink)) >= aaTextContrastRatio && contrastRatio(lum, paper) >= minContrastRatio;
847
+ });
848
+ var accentInk = (_walkToHoldingInk = walkToHoldingInk(ramp[10], ramp[11], holdsInk)) !== null && _walkToHoldingInk !== void 0 ? _walkToHoldingInk : nearestHoldingStep(ramp[10], ramp, holdsInk);
849
+ var fillStep = ramp.indexOf(fill);
850
+ var fillHover = ramp[Math.min(fillStep + 1, ramp.length - 1)];
851
+ var onFill = (_ref1 = solid === null || solid === void 0 ? void 0 : solid.label) !== null && _ref1 !== void 0 ? _ref1 : holdInkFloor(fill, pickReadableForeground(fill, scope.color1, scope.color12));
852
+ var accent = {
853
+ accentBackground: fill,
854
+ accentColor: accentInk,
855
+ ...selectedPaint(scope, ramp, accentInk)
856
+ };
857
+ var rootOn = luminanceOf(base.switchTrackOff);
858
+ var fillLum = luminanceOf(fill);
859
+ var rootHolds = rootOn === null || fillLum === null || contrastRatio(rootOn, fillLum) >= switchStateContrastRatio;
860
+ var track = rootHolds ? void 0 : switchTrackPaint(base, fill, scope.background, isLightGround(scope.background) ? [] : [scope.color4]);
861
+ var _iteratorNormalCompletion2 = true,
862
+ _didIteratorError2 = false,
863
+ _iteratorError2 = void 0;
864
+ try {
865
+ var _loop3 = function () {
866
+ var [name, theme] = _step1.value;
867
+ if (name === scopeName) {
868
+ out[name] = {
869
+ ...theme,
870
+ ...accent,
871
+ ...track
872
+ };
873
+ } else if (name.startsWith(`${scopeName}_`)) {
874
+ var owned = Object.keys(accent).filter(function (key) {
875
+ return key in theme;
876
+ });
877
+ if (owned.length > 0) {
878
+ out[name] = {
879
+ ...theme,
880
+ ...Object.fromEntries(owned.map(function (key) {
881
+ return [key, accent[key]];
882
+ }))
883
+ };
884
+ }
885
+ }
886
+ };
887
+ for (var _iterator2 = Object.entries(themes)[Symbol.iterator](), _step1; !(_iteratorNormalCompletion2 = (_step1 = _iterator2.next()).done); _iteratorNormalCompletion2 = true) _loop3();
888
+ } catch (err) {
889
+ _didIteratorError2 = true;
890
+ _iteratorError2 = err;
891
+ } finally {
892
+ try {
893
+ if (!_iteratorNormalCompletion2 && _iterator2.return != null) {
894
+ _iterator2.return();
895
+ }
896
+ } finally {
897
+ if (_didIteratorError2) {
898
+ throw _iteratorError2;
899
+ }
900
+ }
901
+ }
902
+ out[`${scopeName}_accent`] = {
903
+ background: fill,
904
+ backgroundHover: fillHover,
905
+ backgroundPress: fillHover,
906
+ backgroundFocus: fillHover,
907
+ backgroundActive: fill,
908
+ borderColor: fill,
909
+ borderColorHover: fillHover,
910
+ borderColorFocus: fillHover,
911
+ borderColorPress: fillHover,
912
+ color: onFill,
913
+ colorHover: onFill,
914
+ colorPress: onFill,
915
+ colorFocus: onFill,
916
+ placeholderColor: onFill,
917
+ boundaryColor: onFill,
918
+ outlineColor: onFill,
919
+ color10: onFill,
920
+ color11: onFill,
921
+ color12: onFill,
922
+ textMuted: onFill,
923
+ accentBackground: onFill,
924
+ accentColor: onFill
925
+ };
926
+ };
927
+ for (var _iterator = childrenHues[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) _loop2();
928
+ } catch (err) {
929
+ _didIteratorError = true;
930
+ _iteratorError = err;
931
+ } finally {
932
+ try {
933
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
934
+ _iterator.return();
935
+ }
936
+ } finally {
937
+ if (_didIteratorError) {
938
+ throw _iteratorError;
939
+ }
940
+ }
941
+ }
942
+ };
943
+ var out = {
944
+ ...themes
945
+ };
946
+ for (var _i = 0, _iter = ["light", "dark"]; _i < _iter.length; _i++) _loop(_i, _iter);
947
+ return out;
948
+ }
949
+ var defaultLightShadows = {
950
+ shadow1: "rgba(0,0,0,0.04)",
951
+ shadow2: "rgba(0,0,0,0.08)",
952
+ shadow3: "rgba(0,0,0,0.12)",
953
+ shadow4: "rgba(0,0,0,0.22)",
954
+ shadow5: "rgba(0,0,0,0.33)",
955
+ shadow6: "rgba(0,0,0,0.44)"
956
+ };
957
+ var defaultDarkShadows = {
958
+ shadow1: "rgba(0,0,0,0.15)",
959
+ shadow2: "rgba(0,0,0,0.23)",
960
+ shadow3: "rgba(0,0,0,0.33)",
961
+ shadow4: "rgba(0,0,0,0.45)",
962
+ shadow5: "rgba(0,0,0,0.65)",
963
+ shadow6: "rgba(0,0,0,0.8)"
964
+ };
965
+ var childrenHues = ["blue", "red", "green", "yellow", "orange", "pink", "purple", "gray"];
966
+ function holdFocusRingAccent(themes) {
967
+ var _loop = function (_i2, _iter2) {
968
+ var scheme = _iter2[_i2];
969
+ var _themes_;
970
+ var base = themes[scheme];
971
+ if (!base) return "continue";
972
+ var grounds = [base.color1, base.color2].map(luminanceOf);
973
+ if (grounds.some(function (lum) {
974
+ return lum === null;
975
+ })) return "continue";
976
+ var holds = function holds2(color) {
977
+ var lum = luminanceOf(color);
978
+ return lum !== null && isChromatic(color) && grounds.every(function (ground) {
979
+ return contrastRatio(lum, ground) >= minContrastRatio;
980
+ });
981
+ };
982
+ var rootRing = [base.accentColor, (_themes_ = themes[`${scheme}_blue`]) === null || _themes_ === void 0 ? void 0 : _themes_.accentColor].find(holds);
983
+ var _iteratorNormalCompletion = true,
984
+ _didIteratorError = false,
985
+ _iteratorError = void 0;
986
+ try {
987
+ for (var _iterator = Object.entries(themes)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
988
+ var [name, theme] = _step.value;
989
+ var _parts_;
990
+ var _themes_1;
991
+ if (name !== scheme && !name.startsWith(`${scheme}_`)) continue;
992
+ if (theme.outlineColor === void 0) continue;
993
+ var parts = name.split("_");
994
+ if (parts.includes("accent")) continue;
995
+ var hue = childrenHues.includes((_parts_ = parts[1]) !== null && _parts_ !== void 0 ? _parts_ : "") ? parts[1] : void 0;
996
+ var scopeInk = hue ? (_themes_1 = themes[`${scheme}_${hue}`]) === null || _themes_1 === void 0 ? void 0 : _themes_1.accentColor : void 0;
997
+ var ring = holds(scopeInk) ? scopeInk : rootRing;
998
+ if (!ring || ring === theme.outlineColor) continue;
999
+ out[name] = {
1000
+ ...theme,
1001
+ outlineColor: ring
1002
+ };
1003
+ }
1004
+ } catch (err) {
1005
+ _didIteratorError = true;
1006
+ _iteratorError = err;
1007
+ } finally {
1008
+ try {
1009
+ if (!_iteratorNormalCompletion && _iterator.return != null) {
1010
+ _iterator.return();
1011
+ }
1012
+ } finally {
1013
+ if (_didIteratorError) {
1014
+ throw _iteratorError;
1015
+ }
1016
+ }
1017
+ }
1018
+ };
1019
+ var out = {
1020
+ ...themes
1021
+ };
1022
+ for (var _i = 0, _iter = ["light", "dark"]; _i < _iter.length; _i++) _loop(_i, _iter);
1023
+ return out;
1024
+ }
1025
+ function isChromatic(color) {
1026
+ var hex = color ? normalizeToHex(color) : null;
1027
+ if (!hex) return false;
1028
+ var channels = [1, 3, 5].map(function (index) {
1029
+ return Number.parseInt(hex.slice(index, index + 2), 16);
1030
+ });
1031
+ return Math.max(...channels) - Math.min(...channels) >= 24;
1032
+ }
1033
+ function createThemesBuilder(baseTheme, accentTheme, options) {
1034
+ var _ref, _ref1;
1035
+ var _baseTheme_lightShadows, _baseTheme_darkShadows;
1036
+ var getTheme = (options === null || options === void 0 ? void 0 : options.getTheme) ? sanitizeGetTheme(options.getTheme) : void 0;
1037
+ var base = {
1038
+ palette: {
1039
+ dark: baseTheme.darkPalette,
1040
+ light: baseTheme.lightPalette
1041
+ },
1042
+ extra: {
1043
+ light: {
1044
+ ...Object.assign({}, ...Object.values(defaultChildrenThemes).map(function (theme) {
1045
+ return theme.light;
1046
+ })),
1047
+ ...baseTheme.lightShadows,
1048
+ shadowColor: ((_baseTheme_lightShadows = baseTheme.lightShadows) === null || _baseTheme_lightShadows === void 0 ? void 0 : _baseTheme_lightShadows.shadow3) || defaultLightShadows.shadow3
1049
+ },
1050
+ dark: {
1051
+ ...Object.assign({}, ...Object.values(defaultChildrenThemes).map(function (theme) {
1052
+ return theme.dark;
1053
+ })),
1054
+ ...baseTheme.darkShadows,
1055
+ shadowColor: ((_baseTheme_darkShadows = baseTheme.darkShadows) === null || _baseTheme_darkShadows === void 0 ? void 0 : _baseTheme_darkShadows.shadow3) || defaultDarkShadows.shadow3
1056
+ }
1057
+ }
1058
+ };
1059
+ var childrenThemes = {
1060
+ ...Object.fromEntries(childrenHues.map(function (name) {
1061
+ var {
1062
+ light,
1063
+ dark
1064
+ } = defaultChildrenThemes[name];
1065
+ return [name, {
1066
+ palette: {
1067
+ light: Object.values(light),
1068
+ dark: Object.values(dark)
1069
+ }
1070
+ }];
1071
+ })),
1072
+ warning: {
1073
+ palette: {
1074
+ dark: Object.values(Colors.yellowDark),
1075
+ light: withIntentInkFloor(Object.values(Colors.yellow), intentInkFloor.warning)
1076
+ }
1077
+ },
1078
+ error: {
1079
+ palette: {
1080
+ dark: Object.values(Colors.redDark),
1081
+ light: Object.values(Colors.red)
1082
+ }
1083
+ },
1084
+ success: {
1085
+ palette: {
1086
+ dark: Object.values(Colors.greenDark),
1087
+ light: withIntentInkFloor(Object.values(Colors.green), intentInkFloor.success)
1088
+ }
1089
+ }
1090
+ };
1091
+ var createThemesProps = {
1092
+ templates: houseTemplates,
1093
+ componentThemes: (_ref = options === null || options === void 0 ? void 0 : options.componentThemes) !== null && _ref !== void 0 ? _ref : houseComponentThemes,
1094
+ grandChildrenThemes: (_ref1 = options === null || options === void 0 ? void 0 : options.grandChildrenThemes) !== null && _ref1 !== void 0 ? _ref1 : houseGrandChildrenThemes,
1095
+ base,
1096
+ childrenThemes,
1097
+ accent: {
1098
+ palette: {
1099
+ dark: accentTheme.darkPalette,
1100
+ light: accentTheme.lightPalette
1101
+ }
1102
+ }
1103
+ };
1104
+ if (getTheme) {
1105
+ createThemesProps.getTheme = getTheme;
1106
+ }
1107
+ var initialTheme = tamaguiCreateThemes(createThemesProps);
1108
+ var themes = holdFocusRingAccent(holdColorThemeAccent(holdSwitchTrack(holdSyntaxFloor(holdNamedInkFloor(holdSelectedState(holdAccentFloor(holdSelectionSurface(neutralizeSemanticEntryText(neutralizeTintText(initialTheme))))))))));
1109
+ return {
1110
+ themes() {
1111
+ return themes;
1112
+ },
1113
+ addTheme(name, theme) {
1114
+ var _ref2, _ref12;
1115
+ var addThemeProps = {
1116
+ templates: houseTemplates,
1117
+ componentThemes: (_ref2 = options === null || options === void 0 ? void 0 : options.componentThemes) !== null && _ref2 !== void 0 ? _ref2 : houseComponentThemes,
1118
+ grandChildrenThemes: (_ref12 = options === null || options === void 0 ? void 0 : options.grandChildrenThemes) !== null && _ref12 !== void 0 ? _ref12 : houseGrandChildrenThemes,
1119
+ base,
1120
+ childrenThemes,
1121
+ accent: {
1122
+ palette: {
1123
+ dark: theme.darkPalette,
1124
+ light: theme.lightPalette
1125
+ }
1126
+ }
1127
+ };
1128
+ if (getTheme) {
1129
+ addThemeProps.getTheme = getTheme;
1130
+ }
1131
+ var createdTheme = tamaguiCreateThemes(addThemeProps);
1132
+ return {
1133
+ [`dark_${name}`]: createdTheme.dark_accent,
1134
+ [`light_${name}`]: createdTheme.light_accent
1135
+ };
1136
+ }
1137
+ };
1138
+ }
1139
+ export { createThemesBuilder, houseComponentThemes, houseGrandChildrenThemes, houseTemplates, tintHueNames };
1140
+ //# sourceMappingURL=createThemes.native.js.map