@number10/phaserjsx 0.1.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 (326) hide show
  1. package/LICENSE +667 -0
  2. package/README.md +238 -0
  3. package/dist/TransformOriginView-BYPbRH8N.cjs +17045 -0
  4. package/dist/TransformOriginView-BYPbRH8N.cjs.map +1 -0
  5. package/dist/TransformOriginView-CO-tJCmV.js +17046 -0
  6. package/dist/TransformOriginView-CO-tJCmV.js.map +1 -0
  7. package/dist/animation/animated-signal.d.ts +35 -0
  8. package/dist/animation/animated-signal.d.ts.map +1 -0
  9. package/dist/animation/index.d.ts +7 -0
  10. package/dist/animation/index.d.ts.map +1 -0
  11. package/dist/animation/spring-physics.d.ts +120 -0
  12. package/dist/animation/spring-physics.d.ts.map +1 -0
  13. package/dist/animation/useSpring.d.ts +54 -0
  14. package/dist/animation/useSpring.d.ts.map +1 -0
  15. package/dist/colors/color-presets.d.ts +89 -0
  16. package/dist/colors/color-presets.d.ts.map +1 -0
  17. package/dist/colors/color-theme-helpers.d.ts +65 -0
  18. package/dist/colors/color-theme-helpers.d.ts.map +1 -0
  19. package/dist/colors/color-types.d.ts +100 -0
  20. package/dist/colors/color-types.d.ts.map +1 -0
  21. package/dist/colors/color-utils.d.ts +171 -0
  22. package/dist/colors/color-utils.d.ts.map +1 -0
  23. package/dist/colors/index.d.ts +17 -0
  24. package/dist/colors/index.d.ts.map +1 -0
  25. package/dist/colors/preset-manager.d.ts +35 -0
  26. package/dist/colors/preset-manager.d.ts.map +1 -0
  27. package/dist/colors/use-color-mode.d.ts +22 -0
  28. package/dist/colors/use-color-mode.d.ts.map +1 -0
  29. package/dist/colors/use-colors.d.ts +40 -0
  30. package/dist/colors/use-colors.d.ts.map +1 -0
  31. package/dist/components/appliers/applyBackground.d.ts +13 -0
  32. package/dist/components/appliers/applyBackground.d.ts.map +1 -0
  33. package/dist/components/appliers/applyGestures.d.ts +12 -0
  34. package/dist/components/appliers/applyGestures.d.ts.map +1 -0
  35. package/dist/components/appliers/applyGraphics.d.ts +10 -0
  36. package/dist/components/appliers/applyGraphics.d.ts.map +1 -0
  37. package/dist/components/appliers/applyGraphicsLayout.d.ts +10 -0
  38. package/dist/components/appliers/applyGraphicsLayout.d.ts.map +1 -0
  39. package/dist/components/appliers/applyImage.d.ts +10 -0
  40. package/dist/components/appliers/applyImage.d.ts.map +1 -0
  41. package/dist/components/appliers/applyImageLayout.d.ts +15 -0
  42. package/dist/components/appliers/applyImageLayout.d.ts.map +1 -0
  43. package/dist/components/appliers/applyLayout.d.ts +15 -0
  44. package/dist/components/appliers/applyLayout.d.ts.map +1 -0
  45. package/dist/components/appliers/applyNineSlice.d.ts +11 -0
  46. package/dist/components/appliers/applyNineSlice.d.ts.map +1 -0
  47. package/dist/components/appliers/applyNineSliceLayout.d.ts +15 -0
  48. package/dist/components/appliers/applyNineSliceLayout.d.ts.map +1 -0
  49. package/dist/components/appliers/applyPhaser.d.ts +22 -0
  50. package/dist/components/appliers/applyPhaser.d.ts.map +1 -0
  51. package/dist/components/appliers/applySprite.d.ts +10 -0
  52. package/dist/components/appliers/applySprite.d.ts.map +1 -0
  53. package/dist/components/appliers/applySpriteLayout.d.ts +14 -0
  54. package/dist/components/appliers/applySpriteLayout.d.ts.map +1 -0
  55. package/dist/components/appliers/applyText.d.ts +25 -0
  56. package/dist/components/appliers/applyText.d.ts.map +1 -0
  57. package/dist/components/appliers/applyTextLayout.d.ts +15 -0
  58. package/dist/components/appliers/applyTextLayout.d.ts.map +1 -0
  59. package/dist/components/appliers/applyTooltip.d.ts +12 -0
  60. package/dist/components/appliers/applyTooltip.d.ts.map +1 -0
  61. package/dist/components/appliers/applyTransform.d.ts +21 -0
  62. package/dist/components/appliers/applyTransform.d.ts.map +1 -0
  63. package/dist/components/creators/createBackground.d.ts +15 -0
  64. package/dist/components/creators/createBackground.d.ts.map +1 -0
  65. package/dist/components/creators/createGestures.d.ts +11 -0
  66. package/dist/components/creators/createGestures.d.ts.map +1 -0
  67. package/dist/components/creators/createGraphicsLayout.d.ts +9 -0
  68. package/dist/components/creators/createGraphicsLayout.d.ts.map +1 -0
  69. package/dist/components/creators/createImageLayout.d.ts +14 -0
  70. package/dist/components/creators/createImageLayout.d.ts.map +1 -0
  71. package/dist/components/creators/createLayout.d.ts +15 -0
  72. package/dist/components/creators/createLayout.d.ts.map +1 -0
  73. package/dist/components/creators/createNineSliceLayout.d.ts +14 -0
  74. package/dist/components/creators/createNineSliceLayout.d.ts.map +1 -0
  75. package/dist/components/creators/createPhaser.d.ts +14 -0
  76. package/dist/components/creators/createPhaser.d.ts.map +1 -0
  77. package/dist/components/creators/createSpriteLayout.d.ts +15 -0
  78. package/dist/components/creators/createSpriteLayout.d.ts.map +1 -0
  79. package/dist/components/creators/createTextLayout.d.ts +14 -0
  80. package/dist/components/creators/createTextLayout.d.ts.map +1 -0
  81. package/dist/components/creators/createTransform.d.ts +11 -0
  82. package/dist/components/creators/createTransform.d.ts.map +1 -0
  83. package/dist/components/custom/Accordion.d.ts +34 -0
  84. package/dist/components/custom/Accordion.d.ts.map +1 -0
  85. package/dist/components/custom/AlertDialog.d.ts +63 -0
  86. package/dist/components/custom/AlertDialog.d.ts.map +1 -0
  87. package/dist/components/custom/Button.d.ts +44 -0
  88. package/dist/components/custom/Button.d.ts.map +1 -0
  89. package/dist/components/custom/CharText/CharText.d.ts +8 -0
  90. package/dist/components/custom/CharText/CharText.d.ts.map +1 -0
  91. package/dist/components/custom/CharText/index.d.ts +3 -0
  92. package/dist/components/custom/CharText/index.d.ts.map +1 -0
  93. package/dist/components/custom/CharText/types.d.ts +117 -0
  94. package/dist/components/custom/CharText/types.d.ts.map +1 -0
  95. package/dist/components/custom/CharText/utils.d.ts +34 -0
  96. package/dist/components/custom/CharText/utils.d.ts.map +1 -0
  97. package/dist/components/custom/CharTextInput.d.ts +62 -0
  98. package/dist/components/custom/CharTextInput.d.ts.map +1 -0
  99. package/dist/components/custom/Dialog.d.ts +60 -0
  100. package/dist/components/custom/Dialog.d.ts.map +1 -0
  101. package/dist/components/custom/Divider.d.ts +21 -0
  102. package/dist/components/custom/Divider.d.ts.map +1 -0
  103. package/dist/components/custom/Dropdown.d.ts +91 -0
  104. package/dist/components/custom/Dropdown.d.ts.map +1 -0
  105. package/dist/components/custom/Icon.d.ts +75 -0
  106. package/dist/components/custom/Icon.d.ts.map +1 -0
  107. package/dist/components/custom/Image.d.ts +50 -0
  108. package/dist/components/custom/Image.d.ts.map +1 -0
  109. package/dist/components/custom/Modal.d.ts +37 -0
  110. package/dist/components/custom/Modal.d.ts.map +1 -0
  111. package/dist/components/custom/NineSlice.d.ts +81 -0
  112. package/dist/components/custom/NineSlice.d.ts.map +1 -0
  113. package/dist/components/custom/NineSliceButton.d.ts +128 -0
  114. package/dist/components/custom/NineSliceButton.d.ts.map +1 -0
  115. package/dist/components/custom/Portal.d.ts +43 -0
  116. package/dist/components/custom/Portal.d.ts.map +1 -0
  117. package/dist/components/custom/Portal.test.d.ts +2 -0
  118. package/dist/components/custom/Portal.test.d.ts.map +1 -0
  119. package/dist/components/custom/RadioButton.d.ts +20 -0
  120. package/dist/components/custom/RadioButton.d.ts.map +1 -0
  121. package/dist/components/custom/RadioGroup.d.ts +33 -0
  122. package/dist/components/custom/RadioGroup.d.ts.map +1 -0
  123. package/dist/components/custom/RefOriginView.d.ts +45 -0
  124. package/dist/components/custom/RefOriginView.d.ts.map +1 -0
  125. package/dist/components/custom/ScrollSlider.d.ts +36 -0
  126. package/dist/components/custom/ScrollSlider.d.ts.map +1 -0
  127. package/dist/components/custom/ScrollView.d.ts +48 -0
  128. package/dist/components/custom/ScrollView.d.ts.map +1 -0
  129. package/dist/components/custom/Sidebar.d.ts +50 -0
  130. package/dist/components/custom/Sidebar.d.ts.map +1 -0
  131. package/dist/components/custom/Slider.d.ts +131 -0
  132. package/dist/components/custom/Slider.d.ts.map +1 -0
  133. package/dist/components/custom/Text.d.ts +26 -0
  134. package/dist/components/custom/Text.d.ts.map +1 -0
  135. package/dist/components/custom/Toggle.d.ts +51 -0
  136. package/dist/components/custom/Toggle.d.ts.map +1 -0
  137. package/dist/components/custom/TransformOriginView.d.ts +34 -0
  138. package/dist/components/custom/TransformOriginView.d.ts.map +1 -0
  139. package/dist/components/custom/View.d.ts +33 -0
  140. package/dist/components/custom/View.d.ts.map +1 -0
  141. package/dist/components/custom/WrapText.d.ts +60 -0
  142. package/dist/components/custom/WrapText.d.ts.map +1 -0
  143. package/dist/components/custom/index.cjs +32 -0
  144. package/dist/components/custom/index.cjs.map +1 -0
  145. package/dist/components/custom/index.d.ts +29 -0
  146. package/dist/components/custom/index.d.ts.map +1 -0
  147. package/dist/components/custom/index.js +32 -0
  148. package/dist/components/custom/index.js.map +1 -0
  149. package/dist/components/index.d.ts +28 -0
  150. package/dist/components/index.d.ts.map +1 -0
  151. package/dist/components/internal/SceneWrapper.d.ts +20 -0
  152. package/dist/components/internal/SceneWrapper.d.ts.map +1 -0
  153. package/dist/components/primitives/graphics.d.ts +40 -0
  154. package/dist/components/primitives/graphics.d.ts.map +1 -0
  155. package/dist/components/primitives/image.d.ts +45 -0
  156. package/dist/components/primitives/image.d.ts.map +1 -0
  157. package/dist/components/primitives/nineslice.d.ts +111 -0
  158. package/dist/components/primitives/nineslice.d.ts.map +1 -0
  159. package/dist/components/primitives/sprite.d.ts +58 -0
  160. package/dist/components/primitives/sprite.d.ts.map +1 -0
  161. package/dist/components/primitives/text.d.ts +26 -0
  162. package/dist/components/primitives/text.d.ts.map +1 -0
  163. package/dist/components/primitives/tilesprite.d.ts +47 -0
  164. package/dist/components/primitives/tilesprite.d.ts.map +1 -0
  165. package/dist/components/primitives/view.d.ts +23 -0
  166. package/dist/components/primitives/view.d.ts.map +1 -0
  167. package/dist/core-props.d.ts +605 -0
  168. package/dist/core-props.d.ts.map +1 -0
  169. package/dist/core-types.d.ts +59 -0
  170. package/dist/core-types.d.ts.map +1 -0
  171. package/dist/design-tokens/design-token-presets.d.ts +26 -0
  172. package/dist/design-tokens/design-token-presets.d.ts.map +1 -0
  173. package/dist/design-tokens/design-token-types.d.ts +109 -0
  174. package/dist/design-tokens/design-token-types.d.ts.map +1 -0
  175. package/dist/design-tokens/index.d.ts +8 -0
  176. package/dist/design-tokens/index.d.ts.map +1 -0
  177. package/dist/design-tokens/use-theme-tokens.d.ts +28 -0
  178. package/dist/design-tokens/use-theme-tokens.d.ts.map +1 -0
  179. package/dist/dev-config.d.ts +238 -0
  180. package/dist/dev-config.d.ts.map +1 -0
  181. package/dist/effects/effect-registry.d.ts +54 -0
  182. package/dist/effects/effect-registry.d.ts.map +1 -0
  183. package/dist/effects/index.d.ts +56 -0
  184. package/dist/effects/index.d.ts.map +1 -0
  185. package/dist/effects/use-effect.d.ts +172 -0
  186. package/dist/effects/use-effect.d.ts.map +1 -0
  187. package/dist/fx/convenience-hooks/index.d.ts +7 -0
  188. package/dist/fx/convenience-hooks/index.d.ts.map +1 -0
  189. package/dist/fx/convenience-hooks/use-blur.d.ts +21 -0
  190. package/dist/fx/convenience-hooks/use-blur.d.ts.map +1 -0
  191. package/dist/fx/convenience-hooks/use-glow.d.ts +21 -0
  192. package/dist/fx/convenience-hooks/use-glow.d.ts.map +1 -0
  193. package/dist/fx/convenience-hooks/use-shadow.d.ts +21 -0
  194. package/dist/fx/convenience-hooks/use-shadow.d.ts.map +1 -0
  195. package/dist/fx/fx-creators/blur.d.ts +37 -0
  196. package/dist/fx/fx-creators/blur.d.ts.map +1 -0
  197. package/dist/fx/fx-creators/color-matrix.d.ts +31 -0
  198. package/dist/fx/fx-creators/color-matrix.d.ts.map +1 -0
  199. package/dist/fx/fx-creators/glow.d.ts +36 -0
  200. package/dist/fx/fx-creators/glow.d.ts.map +1 -0
  201. package/dist/fx/fx-creators/index.d.ts +10 -0
  202. package/dist/fx/fx-creators/index.d.ts.map +1 -0
  203. package/dist/fx/fx-creators/pixelate.d.ts +24 -0
  204. package/dist/fx/fx-creators/pixelate.d.ts.map +1 -0
  205. package/dist/fx/fx-creators/shadow.d.ts +43 -0
  206. package/dist/fx/fx-creators/shadow.d.ts.map +1 -0
  207. package/dist/fx/fx-creators/vignette.d.ts +33 -0
  208. package/dist/fx/fx-creators/vignette.d.ts.map +1 -0
  209. package/dist/fx/fx-registry.d.ts +59 -0
  210. package/dist/fx/fx-registry.d.ts.map +1 -0
  211. package/dist/fx/index.d.ts +51 -0
  212. package/dist/fx/index.d.ts.map +1 -0
  213. package/dist/fx/use-fx.d.ts +53 -0
  214. package/dist/fx/use-fx.d.ts.map +1 -0
  215. package/dist/gestures/gesture-manager.d.ts +149 -0
  216. package/dist/gestures/gesture-manager.d.ts.map +1 -0
  217. package/dist/gestures/gesture-types.d.ts +229 -0
  218. package/dist/gestures/gesture-types.d.ts.map +1 -0
  219. package/dist/hooks-svg.d.ts +104 -0
  220. package/dist/hooks-svg.d.ts.map +1 -0
  221. package/dist/hooks.d.ts +135 -0
  222. package/dist/hooks.d.ts.map +1 -0
  223. package/dist/host.d.ts +74 -0
  224. package/dist/host.d.ts.map +1 -0
  225. package/dist/index.cjs +584 -0
  226. package/dist/index.cjs.map +1 -0
  227. package/dist/index.d.ts +34 -0
  228. package/dist/index.d.ts.map +1 -0
  229. package/dist/index.js +582 -0
  230. package/dist/index.js.map +1 -0
  231. package/dist/jsx-dev-runtime.cjs +10 -0
  232. package/dist/jsx-dev-runtime.cjs.map +1 -0
  233. package/dist/jsx-dev-runtime.d.ts +5 -0
  234. package/dist/jsx-dev-runtime.d.ts.map +1 -0
  235. package/dist/jsx-dev-runtime.js +11 -0
  236. package/dist/jsx-dev-runtime.js.map +1 -0
  237. package/dist/jsx-runtime.cjs +43 -0
  238. package/dist/jsx-runtime.cjs.map +1 -0
  239. package/dist/jsx-runtime.d.ts +25 -0
  240. package/dist/jsx-runtime.d.ts.map +1 -0
  241. package/dist/jsx-runtime.js +43 -0
  242. package/dist/jsx-runtime.js.map +1 -0
  243. package/dist/jsx-types.d.ts +33 -0
  244. package/dist/jsx-types.d.ts.map +1 -0
  245. package/dist/layout/appliers/background-applier.d.ts +16 -0
  246. package/dist/layout/appliers/background-applier.d.ts.map +1 -0
  247. package/dist/layout/appliers/container-applier.d.ts +9 -0
  248. package/dist/layout/appliers/container-applier.d.ts.map +1 -0
  249. package/dist/layout/appliers/position-applier.d.ts +8 -0
  250. package/dist/layout/appliers/position-applier.d.ts.map +1 -0
  251. package/dist/layout/index.d.ts +22 -0
  252. package/dist/layout/index.d.ts.map +1 -0
  253. package/dist/layout/layout-engine-test-utils.d.ts +19 -0
  254. package/dist/layout/layout-engine-test-utils.d.ts.map +1 -0
  255. package/dist/layout/layout-engine.d.ts +98 -0
  256. package/dist/layout/layout-engine.d.ts.map +1 -0
  257. package/dist/layout/strategies/base-strategy.d.ts +59 -0
  258. package/dist/layout/strategies/base-strategy.d.ts.map +1 -0
  259. package/dist/layout/strategies/column-layout.d.ts +38 -0
  260. package/dist/layout/strategies/column-layout.d.ts.map +1 -0
  261. package/dist/layout/strategies/row-layout.d.ts +38 -0
  262. package/dist/layout/strategies/row-layout.d.ts.map +1 -0
  263. package/dist/layout/strategies/stack-layout.d.ts +30 -0
  264. package/dist/layout/strategies/stack-layout.d.ts.map +1 -0
  265. package/dist/layout/types.d.ts +137 -0
  266. package/dist/layout/types.d.ts.map +1 -0
  267. package/dist/layout/utils/child-utils.d.ts +74 -0
  268. package/dist/layout/utils/child-utils.d.ts.map +1 -0
  269. package/dist/layout/utils/dimension-calculator.d.ts +59 -0
  270. package/dist/layout/utils/dimension-calculator.d.ts.map +1 -0
  271. package/dist/layout/utils/flex-distributor.d.ts +18 -0
  272. package/dist/layout/utils/flex-distributor.d.ts.map +1 -0
  273. package/dist/layout/utils/size-resolver.d.ts +84 -0
  274. package/dist/layout/utils/size-resolver.d.ts.map +1 -0
  275. package/dist/layout/utils/spacing-calculator.d.ts +27 -0
  276. package/dist/layout/utils/spacing-calculator.d.ts.map +1 -0
  277. package/dist/memo.d.ts +29 -0
  278. package/dist/memo.d.ts.map +1 -0
  279. package/dist/portal/index.d.ts +6 -0
  280. package/dist/portal/index.d.ts.map +1 -0
  281. package/dist/portal/portal-registry.d.ts +97 -0
  282. package/dist/portal/portal-registry.d.ts.map +1 -0
  283. package/dist/portal/portal-types.d.ts +20 -0
  284. package/dist/portal/portal-types.d.ts.map +1 -0
  285. package/dist/render-context.d.ts +118 -0
  286. package/dist/render-context.d.ts.map +1 -0
  287. package/dist/scripts/generate-icon-loaders.d.ts +2 -0
  288. package/dist/scripts/generate-icon-loaders.d.ts.map +1 -0
  289. package/dist/scripts/generate-icon-loaders.js +195 -0
  290. package/dist/scripts/generate-icon-types.d.ts +2 -0
  291. package/dist/scripts/generate-icon-types.d.ts.map +1 -0
  292. package/dist/scripts/generate-icon-types.js +124 -0
  293. package/dist/scripts/generate-icons.d.ts +37 -0
  294. package/dist/scripts/generate-icons.d.ts.map +1 -0
  295. package/dist/scripts/generate-icons.js +494 -0
  296. package/dist/scripts/icon-generator-config.d.ts +87 -0
  297. package/dist/scripts/icon-generator-config.d.ts.map +1 -0
  298. package/dist/scripts/icon-generator-config.js +6 -0
  299. package/dist/theme-base.d.ts +116 -0
  300. package/dist/theme-base.d.ts.map +1 -0
  301. package/dist/theme-custom.d.ts +262 -0
  302. package/dist/theme-custom.d.ts.map +1 -0
  303. package/dist/theme-defaults.d.ts +6 -0
  304. package/dist/theme-defaults.d.ts.map +1 -0
  305. package/dist/theme.d.ts +132 -0
  306. package/dist/theme.d.ts.map +1 -0
  307. package/dist/tooltip/tooltip-types.d.ts +57 -0
  308. package/dist/tooltip/tooltip-types.d.ts.map +1 -0
  309. package/dist/types.d.ts +34 -0
  310. package/dist/types.d.ts.map +1 -0
  311. package/dist/utils/KeyboardInputManager.d.ts +48 -0
  312. package/dist/utils/KeyboardInputManager.d.ts.map +1 -0
  313. package/dist/utils/dom-input-manager.d.ts +109 -0
  314. package/dist/utils/dom-input-manager.d.ts.map +1 -0
  315. package/dist/utils/svg-texture.d.ts +30 -0
  316. package/dist/utils/svg-texture.d.ts.map +1 -0
  317. package/dist/utils/texture-registry.d.ts +49 -0
  318. package/dist/utils/texture-registry.d.ts.map +1 -0
  319. package/dist/vdom.d.ts +60 -0
  320. package/dist/vdom.d.ts.map +1 -0
  321. package/dist/viewport-context.d.ts +39 -0
  322. package/dist/viewport-context.d.ts.map +1 -0
  323. package/dist/vite-plugin-icons.d.ts +29 -0
  324. package/dist/vite-plugin-icons.d.ts.map +1 -0
  325. package/dist/vite-plugin-icons.js +95 -0
  326. package/package.json +117 -0
@@ -0,0 +1,26 @@
1
+ import { RadiusTokens, SizeTokens, SpacingTokens, TextStyleTokens } from './design-token-types';
2
+ /**
3
+ * Default spacing scale
4
+ * Based on 4px base unit
5
+ */
6
+ export declare const defaultSpacingTokens: SpacingTokens;
7
+ /**
8
+ * Default size scale
9
+ * For width, height, icon sizes, etc.
10
+ */
11
+ export declare const defaultSizeTokens: SizeTokens;
12
+ /**
13
+ * Default border radius scale
14
+ */
15
+ export declare const defaultRadiusTokens: RadiusTokens;
16
+ /**
17
+ * Create text style tokens with the given base text color
18
+ * @param textColor - Base text color (hex string)
19
+ * @returns TextStyleTokens with color applied
20
+ */
21
+ export declare function createTextStyleTokens(textColor: string): TextStyleTokens;
22
+ /**
23
+ * Default text style tokens (white text)
24
+ */
25
+ export declare const defaultTextStyleTokens: TextStyleTokens;
26
+ //# sourceMappingURL=design-token-presets.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"design-token-presets.d.ts","sourceRoot":"","sources":["../../src/design-tokens/design-token-presets.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,KAAK,EAAE,YAAY,EAAE,UAAU,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAA;AAEpG;;;GAGG;AACH,eAAO,MAAM,oBAAoB,EAAE,aAOlC,CAAA;AAED;;;GAGG;AACH,eAAO,MAAM,iBAAiB,EAAE,UAO/B,CAAA;AAED;;GAEG;AACH,eAAO,MAAM,mBAAmB,EAAE,YAOjC,CAAA;AAED;;;;GAIG;AACH,wBAAgB,qBAAqB,CAAC,SAAS,EAAE,MAAM,GAAG,eAAe,CA+CxE;AAED;;GAEG;AACH,eAAO,MAAM,sBAAsB,EAAE,eAAkD,CAAA"}
@@ -0,0 +1,109 @@
1
+ import { default as Phaser } from 'phaser';
2
+ import { ColorTokens } from '../colors';
3
+ /**
4
+ * Text style preset token
5
+ * Complete style object ready for Text component
6
+ */
7
+ export interface TextStyleToken {
8
+ fontSize: string | number;
9
+ color: string;
10
+ fontFamily?: string;
11
+ fontStyle?: string;
12
+ align?: 'left' | 'center' | 'right' | 'justify';
13
+ }
14
+ /**
15
+ * Text style tokens for different use cases
16
+ * Provides semantic presets for common text styles
17
+ */
18
+ export interface TextStyleTokens {
19
+ /** Default text style - base body text (16px) */
20
+ DEFAULT: TextStyleToken;
21
+ /** Small text - captions, labels (12px) */
22
+ small: TextStyleToken;
23
+ /** Medium text - body, paragraphs (16px) */
24
+ medium: TextStyleToken;
25
+ /** Large text - subheadings, emphasis (20px) */
26
+ large: TextStyleToken;
27
+ /** Title text - section titles (28px) */
28
+ title: TextStyleToken;
29
+ /** Heading text - page headings (36px) */
30
+ heading: TextStyleToken;
31
+ /** Caption text - footnotes, metadata (10px, reduced opacity) */
32
+ caption: TextStyleToken;
33
+ }
34
+ /**
35
+ * Spacing scale tokens
36
+ * Consistent spacing values for padding, margin, gaps
37
+ */
38
+ export interface SpacingTokens {
39
+ /** Extra small - 4px */
40
+ xs: number;
41
+ /** Small - 8px */
42
+ sm: number;
43
+ /** Medium - 16px */
44
+ md: number;
45
+ /** Large - 24px */
46
+ lg: number;
47
+ /** Extra large - 32px */
48
+ xl: number;
49
+ /** Extra extra large - 48px */
50
+ xxl: number;
51
+ }
52
+ /**
53
+ * Size scale tokens
54
+ * For width, height, icon sizes, etc.
55
+ */
56
+ export interface SizeTokens {
57
+ /** Extra small - 16px */
58
+ xs: number;
59
+ /** Small - 24px */
60
+ sm: number;
61
+ /** Medium - 32px */
62
+ md: number;
63
+ /** Large - 48px */
64
+ lg: number;
65
+ /** Extra large - 64px */
66
+ xl: number;
67
+ /** Extra extra large - 96px */
68
+ xxl: number;
69
+ }
70
+ /**
71
+ * Border radius tokens
72
+ * Consistent corner radius values
73
+ */
74
+ export interface RadiusTokens {
75
+ /** None - 0px */
76
+ none: number;
77
+ /** Small - 4px */
78
+ sm: number;
79
+ /** Medium - 8px */
80
+ md: number;
81
+ /** Large - 16px */
82
+ lg: number;
83
+ /** Extra large - 24px */
84
+ xl: number;
85
+ /** Full - 9999px (pill shape) */
86
+ xxl: number;
87
+ }
88
+ /**
89
+ * Complete design token system
90
+ * Combines colors with semantic style tokens
91
+ */
92
+ export interface DesignTokens {
93
+ /** Color tokens - semantic color scales */
94
+ colors: ColorTokens;
95
+ /** Text style presets - ready-to-use text styles */
96
+ textStyles: TextStyleTokens;
97
+ /** Spacing scale - padding, margin, gaps */
98
+ spacing: SpacingTokens;
99
+ /** Size scale - width, height, icon sizes */
100
+ sizes: SizeTokens;
101
+ /** Border radius scale - corner radius values */
102
+ radius: RadiusTokens;
103
+ }
104
+ /**
105
+ * Helper type to convert TextStyleToken to Phaser TextStyle
106
+ * @internal
107
+ */
108
+ export type PhaserTextStyle = Phaser.Types.GameObjects.Text.TextStyle;
109
+ //# sourceMappingURL=design-token-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"design-token-types.d.ts","sourceRoot":"","sources":["../../src/design-tokens/design-token-types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,KAAK,MAAM,MAAM,QAAQ,CAAA;AAChC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,WAAW,CAAA;AAE5C;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,QAAQ,EAAE,MAAM,GAAG,MAAM,CAAA;IACzB,KAAK,EAAE,MAAM,CAAA;IACb,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,SAAS,CAAA;CAChD;AAED;;;GAGG;AACH,MAAM,WAAW,eAAe;IAC9B,iDAAiD;IACjD,OAAO,EAAE,cAAc,CAAA;IACvB,2CAA2C;IAC3C,KAAK,EAAE,cAAc,CAAA;IACrB,4CAA4C;IAC5C,MAAM,EAAE,cAAc,CAAA;IACtB,gDAAgD;IAChD,KAAK,EAAE,cAAc,CAAA;IACrB,yCAAyC;IACzC,KAAK,EAAE,cAAc,CAAA;IACrB,0CAA0C;IAC1C,OAAO,EAAE,cAAc,CAAA;IACvB,iEAAiE;IACjE,OAAO,EAAE,cAAc,CAAA;CACxB;AAED;;;GAGG;AACH,MAAM,WAAW,aAAa;IAC5B,wBAAwB;IACxB,EAAE,EAAE,MAAM,CAAA;IACV,kBAAkB;IAClB,EAAE,EAAE,MAAM,CAAA;IACV,oBAAoB;IACpB,EAAE,EAAE,MAAM,CAAA;IACV,mBAAmB;IACnB,EAAE,EAAE,MAAM,CAAA;IACV,yBAAyB;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,+BAA+B;IAC/B,GAAG,EAAE,MAAM,CAAA;CACZ;AAED;;;GAGG;AACH,MAAM,WAAW,UAAU;IACzB,yBAAyB;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,mBAAmB;IACnB,EAAE,EAAE,MAAM,CAAA;IACV,oBAAoB;IACpB,EAAE,EAAE,MAAM,CAAA;IACV,mBAAmB;IACnB,EAAE,EAAE,MAAM,CAAA;IACV,yBAAyB;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,+BAA+B;IAC/B,GAAG,EAAE,MAAM,CAAA;CACZ;AAED;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B,iBAAiB;IACjB,IAAI,EAAE,MAAM,CAAA;IACZ,kBAAkB;IAClB,EAAE,EAAE,MAAM,CAAA;IACV,mBAAmB;IACnB,EAAE,EAAE,MAAM,CAAA;IACV,mBAAmB;IACnB,EAAE,EAAE,MAAM,CAAA;IACV,yBAAyB;IACzB,EAAE,EAAE,MAAM,CAAA;IACV,iCAAiC;IACjC,GAAG,EAAE,MAAM,CAAA;CACZ;AAED;;;GAGG;AACH,MAAM,WAAW,YAAY;IAC3B,2CAA2C;IAC3C,MAAM,EAAE,WAAW,CAAA;IACnB,oDAAoD;IACpD,UAAU,EAAE,eAAe,CAAA;IAC3B,4CAA4C;IAC5C,OAAO,EAAE,aAAa,CAAA;IACtB,6CAA6C;IAC7C,KAAK,EAAE,UAAU,CAAA;IACjB,iDAAiD;IACjD,MAAM,EAAE,YAAY,CAAA;CACrB;AAED;;;GAGG;AACH,MAAM,MAAM,eAAe,GAAG,MAAM,CAAC,KAAK,CAAC,WAAW,CAAC,IAAI,CAAC,SAAS,CAAA"}
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Design token system exports
3
+ * Provides semantic tokens for colors, text styles, spacing, sizes, and radius
4
+ */
5
+ export { createTextStyleTokens, defaultRadiusTokens, defaultSizeTokens, defaultSpacingTokens, defaultTextStyleTokens, } from './design-token-presets';
6
+ export type { DesignTokens, PhaserTextStyle, RadiusTokens, SizeTokens, SpacingTokens, TextStyleToken, TextStyleTokens, } from './design-token-types';
7
+ export { useThemeTokens } from './use-theme-tokens';
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/design-tokens/index.ts"],"names":[],"mappings":"AAAA;;;GAGG;AACH,OAAO,EACL,qBAAqB,EACrB,mBAAmB,EACnB,iBAAiB,EACjB,oBAAoB,EACpB,sBAAsB,GACvB,MAAM,wBAAwB,CAAA;AAC/B,YAAY,EACV,YAAY,EACZ,eAAe,EACf,YAAY,EACZ,UAAU,EACV,aAAa,EACb,cAAc,EACd,eAAe,GAChB,MAAM,sBAAsB,CAAA;AAC7B,OAAO,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAA"}
@@ -0,0 +1,28 @@
1
+ import { DesignTokens } from './design-token-types';
2
+ /**
3
+ * Hook to access complete design token system from theme context
4
+ * Provides colors, text styles, spacing, sizes, and radius tokens
5
+ * Automatically updates when color mode or preset changes
6
+ * @returns Current DesignTokens or undefined
7
+ * @example
8
+ * ```typescript
9
+ * function MyComponent() {
10
+ * const tokens = useThemeTokens()
11
+ *
12
+ * if (!tokens) return null
13
+ *
14
+ * return (
15
+ * <View
16
+ * backgroundColor={tokens.colors.surface.DEFAULT}
17
+ * padding={tokens.spacing.lg}
18
+ * cornerRadius={tokens.radius.md}
19
+ * >
20
+ * <Text text="Title" style={tokens.textStyles.title} />
21
+ * <Text text="Body text" style={tokens.textStyles.DEFAULT} />
22
+ * </View>
23
+ * )
24
+ * }
25
+ * ```
26
+ */
27
+ export declare function useThemeTokens(): DesignTokens | undefined;
28
+ //# sourceMappingURL=use-theme-tokens.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"use-theme-tokens.d.ts","sourceRoot":"","sources":["../../src/design-tokens/use-theme-tokens.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAA;AAExD;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AACH,wBAAgB,cAAc,IAAI,YAAY,GAAG,SAAS,CA0EzD"}
@@ -0,0 +1,238 @@
1
+ /**
2
+ * Development and debugging configuration
3
+ * Runtime-configurable settings for debugging and development
4
+ */
5
+ /**
6
+ * Development configuration object
7
+ * Can be modified at runtime from user code for debugging
8
+ *
9
+ * @example
10
+ * ```typescript
11
+ * import { DevConfig } from '@number10/phaserjsx'
12
+ *
13
+ * // Enable specific debug categories
14
+ * DevConfig.debug.enabled = true
15
+ * DevConfig.debug.layout = true
16
+ *
17
+ * // Customize visual debugging
18
+ * DevConfig.visual.maskFillColor = 0xff00ff // Pink
19
+ * DevConfig.visual.maskAlpha = 0.3 // Semi-transparent
20
+ * ```
21
+ */
22
+ export declare const DevConfig: {
23
+ /**
24
+ * Debug logging configuration
25
+ * Controls console output for different subsystems
26
+ */
27
+ debug: {
28
+ /**
29
+ * Master switch - disables all debug output when false
30
+ * @default false
31
+ */
32
+ enabled: boolean;
33
+ /**
34
+ * Detailed layout calculation logs
35
+ * Shows container sizing, positioning, and flex distribution
36
+ * @default false
37
+ */
38
+ layout: boolean;
39
+ /**
40
+ * Overflow mask positioning logs
41
+ * Shows world coordinate calculations and mask updates
42
+ * @default false
43
+ */
44
+ overflowMask: boolean;
45
+ /**
46
+ * Flex distribution calculations
47
+ * Shows flex space allocation across children
48
+ * @default false
49
+ */
50
+ flex: boolean;
51
+ /**
52
+ * Child sizing and positioning
53
+ * Shows individual child dimension calculations
54
+ * @default false
55
+ */
56
+ positioning: boolean;
57
+ /**
58
+ * VDOM mount/patch/unmount operations
59
+ * Shows virtual DOM updates and reconciliation
60
+ * @default false
61
+ */
62
+ vdom: boolean;
63
+ /**
64
+ * Performance timing measurements
65
+ * Shows execution time for layout operations
66
+ * @default false
67
+ */
68
+ performance: boolean;
69
+ /**
70
+ * Theme system logs
71
+ * Shows theme registry updates and prop merging
72
+ * @default false
73
+ */
74
+ theme: boolean;
75
+ };
76
+ /**
77
+ * VDOM warnings and development checks
78
+ * These help catch common mistakes that lead to performance issues
79
+ */
80
+ warnings: {
81
+ /**
82
+ * Warn when list items (siblings) don't have key props
83
+ * Similar to React's "Each child in a list should have a unique key prop" warning
84
+ * @default true (in development)
85
+ */
86
+ missingKeys: boolean;
87
+ /**
88
+ * Warn when props change causes full remount instead of update
89
+ * Detects JSX/callback recreation that prevents VDOM optimization
90
+ * @default true (in development)
91
+ */
92
+ unnecessaryRemounts: boolean;
93
+ /**
94
+ * Warn when VNodes are frozen/sealed and need copying
95
+ * Happens in production builds or with certain bundler optimizations
96
+ * @default false (usually only relevant in production)
97
+ */
98
+ frozenVNodes: boolean;
99
+ };
100
+ /**
101
+ * Visual debugging aids
102
+ * Runtime-configurable visual settings
103
+ */
104
+ visual: {
105
+ /**
106
+ * Show overflow mask areas
107
+ * When true, masks are visible (alpha > 0) for debugging
108
+ * @default false
109
+ */
110
+ showOverflowMasks: boolean;
111
+ /**
112
+ * Mask fill color
113
+ * @default 0xffffff (white, invisible with alpha=0)
114
+ * @example 0xff00ff (pink for debugging)
115
+ */
116
+ maskFillColor: number;
117
+ /**
118
+ * Mask alpha transparency
119
+ * @default 0.0 (invisible)
120
+ * @example 0.3 (semi-transparent for debugging)
121
+ */
122
+ maskAlpha: number;
123
+ };
124
+ /**
125
+ * Performance tuning
126
+ */
127
+ performance: {
128
+ /**
129
+ * Enable deferred layout queue batching
130
+ * When false, deferred updates execute immediately (not batched)
131
+ * @default true
132
+ */
133
+ useDeferredQueue: boolean;
134
+ /**
135
+ * Log deferred queue statistics
136
+ * Shows number of batched callbacks per frame
137
+ * @default false
138
+ */
139
+ logQueueStats: boolean;
140
+ };
141
+ };
142
+ /**
143
+ * Debug logger with category support
144
+ * Only logs when global debug is enabled AND category is enabled
145
+ *
146
+ * @example
147
+ * ```typescript
148
+ * DebugLogger.log('layout', 'Container size:', { width: 100, height: 200 })
149
+ * // Only logs if DevConfig.debug.enabled && DevConfig.debug.layout
150
+ * ```
151
+ */
152
+ export declare class DebugLogger {
153
+ /**
154
+ * Debounced console.log instances per category-message combination
155
+ */
156
+ private static debouncedLoggers;
157
+ /**
158
+ * Log a message with category filtering and debouncing
159
+ * @param category - Debug category to check
160
+ * @param message - Message to log
161
+ * @param args - Additional arguments to log (only first element is used)
162
+ */
163
+ static log(category: keyof typeof DevConfig.debug, message: string, ...args: unknown[]): void;
164
+ /**
165
+ * Log a warning message (always shown, even if debug disabled)
166
+ * @param category - Category for context
167
+ * @param message - Warning message
168
+ * @param args - Additional arguments
169
+ */
170
+ static warn(category: string, message: string, ...args: unknown[]): void;
171
+ /**
172
+ * Log an error message (always shown, even if debug disabled)
173
+ * @param category - Category for context
174
+ * @param message - Error message
175
+ * @param args - Additional arguments
176
+ */
177
+ static error(category: string, message: string, ...args: unknown[]): void;
178
+ /**
179
+ * Start a performance timer
180
+ * @param category - Debug category to check
181
+ * @param label - Timer label
182
+ */
183
+ static time(category: keyof typeof DevConfig.debug, label: string): void;
184
+ /**
185
+ * End a performance timer
186
+ * @param category - Debug category to check
187
+ * @param label - Timer label
188
+ */
189
+ static timeEnd(category: keyof typeof DevConfig.debug, label: string): void;
190
+ }
191
+ /**
192
+ * Predefined configuration presets for common debugging scenarios
193
+ *
194
+ * @example
195
+ * ```typescript
196
+ * import { DevPresets } from '@number10/phaserjsx'
197
+ *
198
+ * // Quick activation of overflow debugging
199
+ * DevPresets.debugOverflow()
200
+ *
201
+ * // Revert to production settings
202
+ * DevPresets.production()
203
+ * ```
204
+ */
205
+ export declare const DevPresets: {
206
+ /**
207
+ * Production configuration
208
+ * All debugging disabled, optimal performance
209
+ */
210
+ production: () => void;
211
+ /**
212
+ * Debug layout issues
213
+ * Enables layout, positioning, and flex logs
214
+ */
215
+ debugLayout: () => void;
216
+ /**
217
+ * Debug overflow masking
218
+ * Enables overflow logs and makes masks visible
219
+ */
220
+ debugOverflow: () => void;
221
+ /**
222
+ * Performance profiling
223
+ * Enables performance timing and queue statistics
224
+ */
225
+ profilePerformance: () => void;
226
+ /**
227
+ * Debug VDOM operations
228
+ * Enables virtual DOM mount/patch/unmount logs
229
+ */
230
+ debugVDOM: () => void;
231
+ debugTheme: () => void;
232
+ /**
233
+ * Enable all debug categories (verbose!)
234
+ * Use with caution - produces lots of console output
235
+ */
236
+ debugAll: () => void;
237
+ };
238
+ //# sourceMappingURL=dev-config.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"dev-config.d.ts","sourceRoot":"","sources":["../src/dev-config.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAIH;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,SAAS;IACpB;;;OAGG;;QAED;;;WAGG;;QAGH;;;;WAIG;;QAGH;;;;WAIG;;QAGH;;;;WAIG;;QAGH;;;;WAIG;;QAGH;;;;WAIG;;QAGH;;;;WAIG;;QAGH;;;;WAIG;;;IAIL;;;OAGG;;QAED;;;;WAIG;;QAGH;;;;WAIG;;QAGH;;;;WAIG;;;IAIL;;;OAGG;;QAED;;;;WAIG;;QAGH;;;;WAIG;;QAGH;;;;WAIG;;;IAIL;;OAEG;;QAED;;;;WAIG;;QAGH;;;;WAIG;;;CAGN,CAAA;AAED;;;;;;;;;GASG;AACH,qBAAa,WAAW;IACtB;;OAEG;IACH,OAAO,CAAC,MAAM,CAAC,gBAAgB,CAAkD;IAEjF;;;;;OAKG;IACH,MAAM,CAAC,GAAG,CAAC,QAAQ,EAAE,MAAM,OAAO,SAAS,CAAC,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,OAAO,EAAE,GAAG,IAAI;IAmB7F;;;;;OAKG;IACH,MAAM,CAAC,IAAI,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,OAAO,EAAE,GAAG,IAAI;IAIxE;;;;;OAKG;IACH,MAAM,CAAC,KAAK,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,GAAG,IAAI,EAAE,OAAO,EAAE,GAAG,IAAI;IAIzE;;;;OAIG;IACH,MAAM,CAAC,IAAI,CAAC,QAAQ,EAAE,MAAM,OAAO,SAAS,CAAC,KAAK,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI;IAOxE;;;;OAIG;IACH,MAAM,CAAC,OAAO,CAAC,QAAQ,EAAE,MAAM,OAAO,SAAS,CAAC,KAAK,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI;CAM5E;AAED;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,UAAU;IACrB;;;OAGG;sBACa,IAAI;IAQpB;;;OAGG;uBACc,IAAI;IAWrB;;;OAGG;yBACgB,IAAI;IAcvB;;;OAGG;8BACqB,IAAI;IAY5B;;;OAGG;qBACY,IAAI;sBAWH,IAAI;IAYpB;;;OAGG;oBACW,IAAI;CAanB,CAAA"}
@@ -0,0 +1,54 @@
1
+ import { EffectConfig, EffectFn } from './use-effect';
2
+ /**
3
+ * Built-in effect names
4
+ */
5
+ export type BuiltInEffectName = 'none' | 'pulse' | 'shake' | 'bounce' | 'press' | 'flash' | 'jello' | 'fade' | 'fadeIn' | 'fadeOut' | 'wobble' | 'tada' | 'swing' | 'wiggle' | 'slideIn' | 'slideOut' | 'zoomIn' | 'zoomOut' | 'flipIn' | 'flipOut' | 'float' | 'breathe' | 'spin';
6
+ /**
7
+ * Extension point for custom effect names
8
+ * Use declaration merging to add custom effects:
9
+ * @example
10
+ * ```typescript
11
+ * declare module '@number10/phaserjsx' {
12
+ * interface EffectNameExtensions {
13
+ * myCustom: 'myCustom'
14
+ * }
15
+ * }
16
+ * ```
17
+ */
18
+ export interface EffectNameExtensions {
19
+ }
20
+ /**
21
+ * Available effect names (built-in + extensions)
22
+ */
23
+ export type EffectName = BuiltInEffectName | (keyof EffectNameExtensions extends never ? never : keyof EffectNameExtensions);
24
+ /**
25
+ * Effect configuration with name and config
26
+ */
27
+ export interface EffectDefinition {
28
+ effect?: EffectName;
29
+ effectConfig?: EffectConfig;
30
+ }
31
+ /**
32
+ * Map of effect names to effect functions
33
+ */
34
+ export declare const EFFECT_REGISTRY: Record<BuiltInEffectName, EffectFn | null>;
35
+ /**
36
+ * Default effect configuration
37
+ */
38
+ export declare const DEFAULT_EFFECT: Required<EffectDefinition>;
39
+ /**
40
+ * Apply an effect by name with configuration
41
+ * @param applyEffect - The applyEffect function from useGameObjectEffect hook
42
+ * @param effectName - Name of the effect to apply
43
+ * @param effectConfig - Optional configuration for the effect
44
+ * @returns true if effect was applied, false otherwise
45
+ */
46
+ export declare function applyEffectByName(applyEffect: (effect: EffectFn, config?: EffectConfig) => void, effectName?: EffectName, effectConfig?: EffectConfig): boolean;
47
+ /**
48
+ * Resolve effect definition with priority: props > theme > default
49
+ * @param props - Props-level effect definition
50
+ * @param theme - Theme-level effect definition
51
+ * @returns Resolved effect definition
52
+ */
53
+ export declare function resolveEffect(props?: EffectDefinition, theme?: EffectDefinition): Required<EffectDefinition>;
54
+ //# sourceMappingURL=effect-registry.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"effect-registry.d.ts","sourceRoot":"","sources":["../../src/effects/effect-registry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AACH,OAAO,EAwBL,KAAK,YAAY,EACjB,KAAK,QAAQ,EACd,MAAM,cAAc,CAAA;AAErB;;GAEG;AACH,MAAM,MAAM,iBAAiB,GACzB,MAAM,GACN,OAAO,GACP,OAAO,GACP,QAAQ,GACR,OAAO,GACP,OAAO,GACP,OAAO,GACP,MAAM,GACN,QAAQ,GACR,SAAS,GACT,QAAQ,GACR,MAAM,GACN,OAAO,GACP,QAAQ,GACR,SAAS,GACT,UAAU,GACV,QAAQ,GACR,SAAS,GACT,QAAQ,GACR,SAAS,GACT,OAAO,GACP,SAAS,GACT,MAAM,CAAA;AAEV;;;;;;;;;;;GAWG;AAEH,MAAM,WAAW,oBAAoB;CAAG;AAExC;;GAEG;AACH,MAAM,MAAM,UAAU,GAClB,iBAAiB,GACjB,CAAC,MAAM,oBAAoB,SAAS,KAAK,GAAG,KAAK,GAAG,MAAM,oBAAoB,CAAC,CAAA;AAEnF;;GAEG;AACH,MAAM,WAAW,gBAAgB;IAC/B,MAAM,CAAC,EAAE,UAAU,CAAA;IACnB,YAAY,CAAC,EAAE,YAAY,CAAA;CAC5B;AAED;;GAEG;AACH,eAAO,MAAM,eAAe,EAAE,MAAM,CAAC,iBAAiB,EAAE,QAAQ,GAAG,IAAI,CAwBtE,CAAA;AAED;;GAEG;AACH,eAAO,MAAM,cAAc,EAAE,QAAQ,CAAC,gBAAgB,CAGrD,CAAA;AAED;;;;;;GAMG;AACH,wBAAgB,iBAAiB,CAC/B,WAAW,EAAE,CAAC,MAAM,EAAE,QAAQ,EAAE,MAAM,CAAC,EAAE,YAAY,KAAK,IAAI,EAC9D,UAAU,CAAC,EAAE,UAAU,EACvB,YAAY,CAAC,EAAE,YAAY,GAC1B,OAAO,CAWT;AAED;;;;;GAKG;AACH,wBAAgB,aAAa,CAC3B,KAAK,CAAC,EAAE,gBAAgB,EACxB,KAAK,CAAC,EAAE,gBAAgB,GACvB,QAAQ,CAAC,gBAAgB,CAAC,CAK5B"}
@@ -0,0 +1,56 @@
1
+ /**
2
+ * Effect System for PhaserJSX
3
+ * Provides reusable animation effects for game objects
4
+ *
5
+ * @example Basic usage:
6
+ * ```tsx
7
+ * import { useGameObjectEffect, createPulseEffect } from '@number10/phaserjsx/effects'
8
+ *
9
+ * function MyButton() {
10
+ * const ref = useRef(null)
11
+ * const { applyEffect } = useGameObjectEffect(ref)
12
+ *
13
+ * const handleClick = () => {
14
+ * applyEffect(createPulseEffect, { intensity: 1.2, time: 300 })
15
+ * }
16
+ *
17
+ * return <View ref={ref} onClick={handleClick}>Click me</View>
18
+ * }
19
+ * ```
20
+ *
21
+ * @example Using effect registry:
22
+ * ```tsx
23
+ * import { useGameObjectEffect, applyEffectByName } from '@number10/phaserjsx/effects'
24
+ *
25
+ * function MyComponent() {
26
+ * const ref = useRef(null)
27
+ * const { applyEffect } = useGameObjectEffect(ref)
28
+ *
29
+ * const handleClick = () => {
30
+ * applyEffectByName(applyEffect, 'pulse', { intensity: 1.2 })
31
+ * }
32
+ * }
33
+ * ```
34
+ *
35
+ * @example Custom effects:
36
+ * ```tsx
37
+ * import { useGameObjectEffect, type EffectFn } from '@number10/phaserjsx/effects'
38
+ *
39
+ * const myCustomEffect: EffectFn = (obj, config) => {
40
+ * obj.scene.tweens.add({
41
+ * targets: obj,
42
+ * alpha: 0,
43
+ * duration: config.time ?? 300
44
+ * })
45
+ * }
46
+ *
47
+ * function MyComponent() {
48
+ * const { applyEffect } = useGameObjectEffect(ref)
49
+ * applyEffect(myCustomEffect, { time: 500 })
50
+ * }
51
+ * ```
52
+ */
53
+ export { useGameObjectEffect, type EffectConfig, type EffectFn } from './use-effect';
54
+ export { DEFAULT_EFFECT, EFFECT_REGISTRY, applyEffectByName, resolveEffect, type BuiltInEffectName, type EffectDefinition, type EffectName, type EffectNameExtensions, } from './effect-registry';
55
+ export { createBounceEffect, createBreatheEffect, createFadeEffect, createFlashEffect, createFlipInEffect, createFlipOutEffect, createFloatEffect, createJelloEffect, createNoneEffect, createPressEffect, createPulseEffect, createShakeEffect, createSlideInEffect, createSlideOutEffect, createSpinEffect, createSwingEffect, createTadaEffect, createWiggleEffect, createWobbleEffect, createZoomInEffect, createZoomOutEffect, } from './use-effect';
56
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/effects/index.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmDG;AAGH,OAAO,EAAE,mBAAmB,EAAE,KAAK,YAAY,EAAE,KAAK,QAAQ,EAAE,MAAM,cAAc,CAAA;AAGpF,OAAO,EACL,cAAc,EACd,eAAe,EACf,iBAAiB,EACjB,aAAa,EACb,KAAK,iBAAiB,EACtB,KAAK,gBAAgB,EACrB,KAAK,UAAU,EACf,KAAK,oBAAoB,GAC1B,MAAM,mBAAmB,CAAA;AAG1B,OAAO,EACL,kBAAkB,EAClB,mBAAmB,EACnB,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACnB,iBAAiB,EACjB,iBAAiB,EACjB,gBAAgB,EAChB,iBAAiB,EACjB,iBAAiB,EACjB,iBAAiB,EACjB,mBAAmB,EACnB,oBAAoB,EACpB,gBAAgB,EAChB,iBAAiB,EACjB,gBAAgB,EAChB,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,mBAAmB,GACpB,MAAM,cAAc,CAAA"}