@shopify/react-native-skia 0.1.150 → 0.1.151

Sign up to get free protection for your applications and to get access to all the features.
Files changed (698) hide show
  1. package/lib/commonjs/animation/decay/decay.js.map +1 -1
  2. package/lib/commonjs/animation/decay/index.js.map +1 -1
  3. package/lib/commonjs/animation/decay/runDecay.js.map +1 -1
  4. package/lib/commonjs/animation/decay/types.js.map +1 -1
  5. package/lib/commonjs/animation/functions/index.js.map +1 -1
  6. package/lib/commonjs/animation/functions/interpolate.js.map +1 -1
  7. package/lib/commonjs/animation/functions/interpolateColors.js.map +1 -1
  8. package/lib/commonjs/animation/functions/interpolatePaths.js.map +1 -1
  9. package/lib/commonjs/animation/functions/interpolateVector.js.map +1 -1
  10. package/lib/commonjs/animation/index.js.map +1 -1
  11. package/lib/commonjs/animation/spring/Spring.js.map +1 -1
  12. package/lib/commonjs/animation/spring/functions/index.js.map +1 -1
  13. package/lib/commonjs/animation/spring/functions/spring.js.map +1 -1
  14. package/lib/commonjs/animation/spring/index.js.map +1 -1
  15. package/lib/commonjs/animation/spring/runSpring.js +1 -1
  16. package/lib/commonjs/animation/spring/runSpring.js.map +1 -1
  17. package/lib/commonjs/animation/spring/types.js.map +1 -1
  18. package/lib/commonjs/animation/spring/useSpring.js +1 -1
  19. package/lib/commonjs/animation/spring/useSpring.js.map +1 -1
  20. package/lib/commonjs/animation/timing/Easing.js.map +1 -1
  21. package/lib/commonjs/animation/timing/createTiming.js +2 -6
  22. package/lib/commonjs/animation/timing/createTiming.js.map +1 -1
  23. package/lib/commonjs/animation/timing/functions/bezier.js.map +1 -1
  24. package/lib/commonjs/animation/timing/functions/getResolvedParams.js +6 -10
  25. package/lib/commonjs/animation/timing/functions/getResolvedParams.js.map +1 -1
  26. package/lib/commonjs/animation/timing/functions/index.js.map +1 -1
  27. package/lib/commonjs/animation/timing/functions/timing.js.map +1 -1
  28. package/lib/commonjs/animation/timing/functions/types.js.map +1 -1
  29. package/lib/commonjs/animation/timing/index.js.map +1 -1
  30. package/lib/commonjs/animation/timing/runTiming.js.map +1 -1
  31. package/lib/commonjs/animation/timing/useLoop.js.map +1 -1
  32. package/lib/commonjs/animation/timing/useTiming.js +1 -3
  33. package/lib/commonjs/animation/timing/useTiming.js.map +1 -1
  34. package/lib/commonjs/animation/types.js.map +1 -1
  35. package/lib/commonjs/dom/nodes/DrawingNode.js.map +1 -1
  36. package/lib/commonjs/dom/nodes/GroupNode.js.map +1 -1
  37. package/lib/commonjs/dom/nodes/JsiSkDOM.js +1 -1
  38. package/lib/commonjs/dom/nodes/JsiSkDOM.js.map +1 -1
  39. package/lib/commonjs/dom/nodes/Node.js.map +1 -1
  40. package/lib/commonjs/dom/nodes/PaintContext.js.map +1 -1
  41. package/lib/commonjs/dom/nodes/PaintNode.js.map +1 -1
  42. package/lib/commonjs/dom/nodes/RenderNode.js.map +1 -1
  43. package/lib/commonjs/dom/nodes/datatypes/Circle.js.map +1 -1
  44. package/lib/commonjs/dom/nodes/datatypes/Color.js.map +1 -1
  45. package/lib/commonjs/dom/nodes/datatypes/Enum.js.map +1 -1
  46. package/lib/commonjs/dom/nodes/datatypes/Fitting.js.map +1 -1
  47. package/lib/commonjs/dom/nodes/datatypes/Gradient.js +2 -2
  48. package/lib/commonjs/dom/nodes/datatypes/Gradient.js.map +1 -1
  49. package/lib/commonjs/dom/nodes/datatypes/Path.js.map +1 -1
  50. package/lib/commonjs/dom/nodes/datatypes/Radius.js.map +1 -1
  51. package/lib/commonjs/dom/nodes/datatypes/Rect.js.map +1 -1
  52. package/lib/commonjs/dom/nodes/datatypes/Transform.js.map +1 -1
  53. package/lib/commonjs/dom/nodes/datatypes/index.js.map +1 -1
  54. package/lib/commonjs/dom/nodes/drawings/BackdropFilterNode.js.map +1 -1
  55. package/lib/commonjs/dom/nodes/drawings/Box.js.map +1 -1
  56. package/lib/commonjs/dom/nodes/drawings/CircleNode.js.map +1 -1
  57. package/lib/commonjs/dom/nodes/drawings/CustomDrawingNode.js.map +1 -1
  58. package/lib/commonjs/dom/nodes/drawings/DiffRectNode.js.map +1 -1
  59. package/lib/commonjs/dom/nodes/drawings/FillNode.js.map +1 -1
  60. package/lib/commonjs/dom/nodes/drawings/ImageNode.js.map +1 -1
  61. package/lib/commonjs/dom/nodes/drawings/ImageSVG.js.map +1 -1
  62. package/lib/commonjs/dom/nodes/drawings/LineNode.js.map +1 -1
  63. package/lib/commonjs/dom/nodes/drawings/OvalNode.js.map +1 -1
  64. package/lib/commonjs/dom/nodes/drawings/PatchNode.js.map +1 -1
  65. package/lib/commonjs/dom/nodes/drawings/PathNode.js.map +1 -1
  66. package/lib/commonjs/dom/nodes/drawings/PictureNode.js.map +1 -1
  67. package/lib/commonjs/dom/nodes/drawings/PointsNode.js.map +1 -1
  68. package/lib/commonjs/dom/nodes/drawings/RRectNode.js.map +1 -1
  69. package/lib/commonjs/dom/nodes/drawings/RectNode.js.map +1 -1
  70. package/lib/commonjs/dom/nodes/drawings/Text.js.map +1 -1
  71. package/lib/commonjs/dom/nodes/drawings/VerticesNode.js.map +1 -1
  72. package/lib/commonjs/dom/nodes/drawings/index.js.map +1 -1
  73. package/lib/commonjs/dom/nodes/index.js.map +1 -1
  74. package/lib/commonjs/dom/nodes/paint/BlendNode.js.map +1 -1
  75. package/lib/commonjs/dom/nodes/paint/ColorFilters.js.map +1 -1
  76. package/lib/commonjs/dom/nodes/paint/ImageFilters.js.map +1 -1
  77. package/lib/commonjs/dom/nodes/paint/MaskFilters.js.map +1 -1
  78. package/lib/commonjs/dom/nodes/paint/PathEffects.js.map +1 -1
  79. package/lib/commonjs/dom/nodes/paint/Shaders.js +2 -4
  80. package/lib/commonjs/dom/nodes/paint/Shaders.js.map +1 -1
  81. package/lib/commonjs/dom/nodes/paint/index.js.map +1 -1
  82. package/lib/commonjs/dom/types/ColorFilters.js.map +1 -1
  83. package/lib/commonjs/dom/types/Common.js.map +1 -1
  84. package/lib/commonjs/dom/types/DrawingContext.js.map +1 -1
  85. package/lib/commonjs/dom/types/Drawings.js.map +1 -1
  86. package/lib/commonjs/dom/types/ImageFilters.js.map +1 -1
  87. package/lib/commonjs/dom/types/MaskFilters.js.map +1 -1
  88. package/lib/commonjs/dom/types/Node.js.map +1 -1
  89. package/lib/commonjs/dom/types/NodeType.js.map +1 -1
  90. package/lib/commonjs/dom/types/PathEffects.js.map +1 -1
  91. package/lib/commonjs/dom/types/Shaders.js.map +1 -1
  92. package/lib/commonjs/dom/types/SkDOM.js.map +1 -1
  93. package/lib/commonjs/dom/types/index.js.map +1 -1
  94. package/lib/commonjs/external/index.js.map +1 -1
  95. package/lib/commonjs/external/reanimated/index.js.map +1 -1
  96. package/lib/commonjs/external/reanimated/useSharedValueEffect.js.map +1 -1
  97. package/lib/commonjs/index.js.map +1 -1
  98. package/lib/commonjs/mock/index.js +6 -10
  99. package/lib/commonjs/mock/index.js.map +1 -1
  100. package/lib/commonjs/renderer/Canvas.js.map +1 -1
  101. package/lib/commonjs/renderer/Container.js.map +1 -1
  102. package/lib/commonjs/renderer/DependencyManager.js.map +1 -1
  103. package/lib/commonjs/renderer/DrawingContext.js.map +1 -1
  104. package/lib/commonjs/renderer/HostComponents.js.map +1 -1
  105. package/lib/commonjs/renderer/HostConfig.js +0 -2
  106. package/lib/commonjs/renderer/HostConfig.js.map +1 -1
  107. package/lib/commonjs/renderer/components/Blend.js.map +1 -1
  108. package/lib/commonjs/renderer/components/Drawing.js.map +1 -1
  109. package/lib/commonjs/renderer/components/Group.js.map +1 -1
  110. package/lib/commonjs/renderer/components/Mask.js.map +1 -1
  111. package/lib/commonjs/renderer/components/Paint.js +1 -1
  112. package/lib/commonjs/renderer/components/Paint.js.map +1 -1
  113. package/lib/commonjs/renderer/components/Picture.js.map +1 -1
  114. package/lib/commonjs/renderer/components/backdrop/BackdropBlur.js +1 -1
  115. package/lib/commonjs/renderer/components/backdrop/BackdropBlur.js.map +1 -1
  116. package/lib/commonjs/renderer/components/backdrop/BackdropFilter.js.map +1 -1
  117. package/lib/commonjs/renderer/components/backdrop/index.js.map +1 -1
  118. package/lib/commonjs/renderer/components/colorFilters/BlendColor.js.map +1 -1
  119. package/lib/commonjs/renderer/components/colorFilters/Lerp.js.map +1 -1
  120. package/lib/commonjs/renderer/components/colorFilters/LinearToSRGBGamma.js.map +1 -1
  121. package/lib/commonjs/renderer/components/colorFilters/LumaColorFilter.js.map +1 -1
  122. package/lib/commonjs/renderer/components/colorFilters/Matrix.js.map +1 -1
  123. package/lib/commonjs/renderer/components/colorFilters/SRGBToLinearGamma.js.map +1 -1
  124. package/lib/commonjs/renderer/components/colorFilters/index.js.map +1 -1
  125. package/lib/commonjs/renderer/components/image/Image.js.map +1 -1
  126. package/lib/commonjs/renderer/components/image/ImageSVG.js.map +1 -1
  127. package/lib/commonjs/renderer/components/image/ImageShader.js.map +1 -1
  128. package/lib/commonjs/renderer/components/image/index.js.map +1 -1
  129. package/lib/commonjs/renderer/components/imageFilters/Blur.js.map +1 -1
  130. package/lib/commonjs/renderer/components/imageFilters/DisplacementMap.js.map +1 -1
  131. package/lib/commonjs/renderer/components/imageFilters/Morphology.js.map +1 -1
  132. package/lib/commonjs/renderer/components/imageFilters/Offset.js.map +1 -1
  133. package/lib/commonjs/renderer/components/imageFilters/RuntimeShader.js.map +1 -1
  134. package/lib/commonjs/renderer/components/imageFilters/Shadow.js.map +1 -1
  135. package/lib/commonjs/renderer/components/imageFilters/index.js.map +1 -1
  136. package/lib/commonjs/renderer/components/index.js.map +1 -1
  137. package/lib/commonjs/renderer/components/maskFilters/Blur.js.map +1 -1
  138. package/lib/commonjs/renderer/components/maskFilters/index.js.map +1 -1
  139. package/lib/commonjs/renderer/components/pathEffects/Corner.js.map +1 -1
  140. package/lib/commonjs/renderer/components/pathEffects/Dash.js.map +1 -1
  141. package/lib/commonjs/renderer/components/pathEffects/Discrete.js.map +1 -1
  142. package/lib/commonjs/renderer/components/pathEffects/Line2D.js.map +1 -1
  143. package/lib/commonjs/renderer/components/pathEffects/Path1D.js.map +1 -1
  144. package/lib/commonjs/renderer/components/pathEffects/Path2D.js.map +1 -1
  145. package/lib/commonjs/renderer/components/pathEffects/Sum.js.map +1 -1
  146. package/lib/commonjs/renderer/components/pathEffects/index.js.map +1 -1
  147. package/lib/commonjs/renderer/components/shaders/Color.js.map +1 -1
  148. package/lib/commonjs/renderer/components/shaders/FractalNoise.js.map +1 -1
  149. package/lib/commonjs/renderer/components/shaders/LinearGradient.js.map +1 -1
  150. package/lib/commonjs/renderer/components/shaders/RadialGradient.js.map +1 -1
  151. package/lib/commonjs/renderer/components/shaders/Shader.js.map +1 -1
  152. package/lib/commonjs/renderer/components/shaders/ShaderLib.js.map +1 -1
  153. package/lib/commonjs/renderer/components/shaders/SweepGradient.js.map +1 -1
  154. package/lib/commonjs/renderer/components/shaders/Turbulence.js.map +1 -1
  155. package/lib/commonjs/renderer/components/shaders/TwoPointConicalGradient.js.map +1 -1
  156. package/lib/commonjs/renderer/components/shaders/index.js.map +1 -1
  157. package/lib/commonjs/renderer/components/shapes/Box.js.map +1 -1
  158. package/lib/commonjs/renderer/components/shapes/Circle.js.map +1 -1
  159. package/lib/commonjs/renderer/components/shapes/DiffRect.js.map +1 -1
  160. package/lib/commonjs/renderer/components/shapes/Fill.js.map +1 -1
  161. package/lib/commonjs/renderer/components/shapes/FitBox.js.map +1 -1
  162. package/lib/commonjs/renderer/components/shapes/Line.js.map +1 -1
  163. package/lib/commonjs/renderer/components/shapes/Oval.js.map +1 -1
  164. package/lib/commonjs/renderer/components/shapes/Patch.js.map +1 -1
  165. package/lib/commonjs/renderer/components/shapes/Path.js.map +1 -1
  166. package/lib/commonjs/renderer/components/shapes/Points.js.map +1 -1
  167. package/lib/commonjs/renderer/components/shapes/Rect.js.map +1 -1
  168. package/lib/commonjs/renderer/components/shapes/RoundedRect.js.map +1 -1
  169. package/lib/commonjs/renderer/components/shapes/Vertices.js.map +1 -1
  170. package/lib/commonjs/renderer/components/shapes/index.js.map +1 -1
  171. package/lib/commonjs/renderer/components/text/Glyphs.js.map +1 -1
  172. package/lib/commonjs/renderer/components/text/Text.js.map +1 -1
  173. package/lib/commonjs/renderer/components/text/TextBlob.js.map +1 -1
  174. package/lib/commonjs/renderer/components/text/TextPath.js.map +1 -1
  175. package/lib/commonjs/renderer/components/text/index.js.map +1 -1
  176. package/lib/commonjs/renderer/index.js.map +1 -1
  177. package/lib/commonjs/renderer/processors/Animations/Animations.js.map +1 -1
  178. package/lib/commonjs/renderer/processors/Animations/index.js.map +1 -1
  179. package/lib/commonjs/renderer/processors/index.js.map +1 -1
  180. package/lib/commonjs/renderer/processors/math/Coordinates.js.map +1 -1
  181. package/lib/commonjs/renderer/processors/math/Math.js.map +1 -1
  182. package/lib/commonjs/renderer/processors/math/Transforms.js.map +1 -1
  183. package/lib/commonjs/renderer/processors/math/index.js.map +1 -1
  184. package/lib/commonjs/renderer/typeddash.js.map +1 -1
  185. package/lib/commonjs/renderer/useCanvas.js.map +1 -1
  186. package/lib/commonjs/renderer/useContextBridge.js.map +1 -1
  187. package/lib/commonjs/skia/NativeSetup.js.map +1 -1
  188. package/lib/commonjs/skia/Skia.js.map +1 -1
  189. package/lib/commonjs/skia/Skia.web.js.map +1 -1
  190. package/lib/commonjs/skia/core/Data.js.map +1 -1
  191. package/lib/commonjs/skia/core/Font.js.map +1 -1
  192. package/lib/commonjs/skia/core/Image.js.map +1 -1
  193. package/lib/commonjs/skia/core/Matrix.js.map +1 -1
  194. package/lib/commonjs/skia/core/Picture.js.map +1 -1
  195. package/lib/commonjs/skia/core/RRect.js.map +1 -1
  196. package/lib/commonjs/skia/core/Rect.js.map +1 -1
  197. package/lib/commonjs/skia/core/SVG.js.map +1 -1
  198. package/lib/commonjs/skia/core/Typeface.js.map +1 -1
  199. package/lib/commonjs/skia/core/Vector.js +1 -1
  200. package/lib/commonjs/skia/core/Vector.js.map +1 -1
  201. package/lib/commonjs/skia/core/index.js.map +1 -1
  202. package/lib/commonjs/skia/index.js.map +1 -1
  203. package/lib/commonjs/skia/types/Canvas.js.map +1 -1
  204. package/lib/commonjs/skia/types/Color.js.map +1 -1
  205. package/lib/commonjs/skia/types/ColorFilter/ColorFilter.js.map +1 -1
  206. package/lib/commonjs/skia/types/ColorFilter/ColorFilterFactory.js.map +1 -1
  207. package/lib/commonjs/skia/types/ColorFilter/index.js.map +1 -1
  208. package/lib/commonjs/skia/types/ContourMeasure.js.map +1 -1
  209. package/lib/commonjs/skia/types/Data/Data.js.map +1 -1
  210. package/lib/commonjs/skia/types/Data/DataFactory.js.map +1 -1
  211. package/lib/commonjs/skia/types/Data/index.js.map +1 -1
  212. package/lib/commonjs/skia/types/Font/Font.js.map +1 -1
  213. package/lib/commonjs/skia/types/Font/index.js.map +1 -1
  214. package/lib/commonjs/skia/types/Image/Image.js.map +1 -1
  215. package/lib/commonjs/skia/types/Image/ImageFactory.js.map +1 -1
  216. package/lib/commonjs/skia/types/Image/index.js.map +1 -1
  217. package/lib/commonjs/skia/types/ImageFilter/ImageFilter.js.map +1 -1
  218. package/lib/commonjs/skia/types/ImageFilter/ImageFilterFactory.js.map +1 -1
  219. package/lib/commonjs/skia/types/ImageFilter/index.js.map +1 -1
  220. package/lib/commonjs/skia/types/JsiInstance.js.map +1 -1
  221. package/lib/commonjs/skia/types/MaskFilter.js.map +1 -1
  222. package/lib/commonjs/skia/types/Matrix.js.map +1 -1
  223. package/lib/commonjs/skia/types/Paint/BlendMode.js.map +1 -1
  224. package/lib/commonjs/skia/types/Paint/Paint.js.map +1 -1
  225. package/lib/commonjs/skia/types/Paint/index.js.map +1 -1
  226. package/lib/commonjs/skia/types/Path/Path.js.map +1 -1
  227. package/lib/commonjs/skia/types/Path/PathFactory.js.map +1 -1
  228. package/lib/commonjs/skia/types/Path/index.js.map +1 -1
  229. package/lib/commonjs/skia/types/PathEffect.js.map +1 -1
  230. package/lib/commonjs/skia/types/Picture/Picture.js.map +1 -1
  231. package/lib/commonjs/skia/types/Picture/PictureFactory.js.map +1 -1
  232. package/lib/commonjs/skia/types/Picture/PictureRecorder.js.map +1 -1
  233. package/lib/commonjs/skia/types/Picture/index.js.map +1 -1
  234. package/lib/commonjs/skia/types/Point.js.map +1 -1
  235. package/lib/commonjs/skia/types/RRect.js.map +1 -1
  236. package/lib/commonjs/skia/types/RSXform.js.map +1 -1
  237. package/lib/commonjs/skia/types/Rect.js.map +1 -1
  238. package/lib/commonjs/skia/types/RuntimeEffect/RuntimeEffect.js.map +1 -1
  239. package/lib/commonjs/skia/types/RuntimeEffect/RuntimeEffectFactory.js.map +1 -1
  240. package/lib/commonjs/skia/types/RuntimeEffect/index.js.map +1 -1
  241. package/lib/commonjs/skia/types/SVG/SVG.js.map +1 -1
  242. package/lib/commonjs/skia/types/SVG/SVGFactory.js.map +1 -1
  243. package/lib/commonjs/skia/types/SVG/index.js.map +1 -1
  244. package/lib/commonjs/skia/types/Shader/Shader.js.map +1 -1
  245. package/lib/commonjs/skia/types/Shader/ShaderFactory.js.map +1 -1
  246. package/lib/commonjs/skia/types/Shader/index.js.map +1 -1
  247. package/lib/commonjs/skia/types/Skia.js.map +1 -1
  248. package/lib/commonjs/skia/types/Surface/Surface.js.map +1 -1
  249. package/lib/commonjs/skia/types/Surface/SurfaceFactory.js.map +1 -1
  250. package/lib/commonjs/skia/types/Surface/index.js.map +1 -1
  251. package/lib/commonjs/skia/types/TextBlob.js.map +1 -1
  252. package/lib/commonjs/skia/types/Typeface/Typeface.js.map +1 -1
  253. package/lib/commonjs/skia/types/Typeface/TypefaceFactory.js.map +1 -1
  254. package/lib/commonjs/skia/types/Typeface/index.js.map +1 -1
  255. package/lib/commonjs/skia/types/Vertices/Vertices.js.map +1 -1
  256. package/lib/commonjs/skia/types/Vertices/index.js.map +1 -1
  257. package/lib/commonjs/skia/types/index.js.map +1 -1
  258. package/lib/commonjs/skia/web/Host.js +1 -1
  259. package/lib/commonjs/skia/web/Host.js.map +1 -1
  260. package/lib/commonjs/skia/web/JsiSkCanvas.js.map +1 -1
  261. package/lib/commonjs/skia/web/JsiSkColor.js.map +1 -1
  262. package/lib/commonjs/skia/web/JsiSkColorFilter.js.map +1 -1
  263. package/lib/commonjs/skia/web/JsiSkColorFilterFactory.js.map +1 -1
  264. package/lib/commonjs/skia/web/JsiSkContourMeasure.js.map +1 -1
  265. package/lib/commonjs/skia/web/JsiSkContourMeasureIter.js.map +1 -1
  266. package/lib/commonjs/skia/web/JsiSkData.js.map +1 -1
  267. package/lib/commonjs/skia/web/JsiSkDataFactory.js.map +1 -1
  268. package/lib/commonjs/skia/web/JsiSkFont.js.map +1 -1
  269. package/lib/commonjs/skia/web/JsiSkImage.js.map +1 -1
  270. package/lib/commonjs/skia/web/JsiSkImageFactory.js.map +1 -1
  271. package/lib/commonjs/skia/web/JsiSkImageFilter.js.map +1 -1
  272. package/lib/commonjs/skia/web/JsiSkImageFilterFactory.js.map +1 -1
  273. package/lib/commonjs/skia/web/JsiSkMaskFilter.js.map +1 -1
  274. package/lib/commonjs/skia/web/JsiSkMaskFilterFactory.js.map +1 -1
  275. package/lib/commonjs/skia/web/JsiSkMatrix.js +1 -1
  276. package/lib/commonjs/skia/web/JsiSkMatrix.js.map +1 -1
  277. package/lib/commonjs/skia/web/JsiSkPaint.js.map +1 -1
  278. package/lib/commonjs/skia/web/JsiSkPath.js.map +1 -1
  279. package/lib/commonjs/skia/web/JsiSkPathEffect.js.map +1 -1
  280. package/lib/commonjs/skia/web/JsiSkPathEffectFactory.js.map +1 -1
  281. package/lib/commonjs/skia/web/JsiSkPathFactory.js.map +1 -1
  282. package/lib/commonjs/skia/web/JsiSkPicture.js.map +1 -1
  283. package/lib/commonjs/skia/web/JsiSkPictureFactory.js.map +1 -1
  284. package/lib/commonjs/skia/web/JsiSkPictureRecorder.js.map +1 -1
  285. package/lib/commonjs/skia/web/JsiSkPoint.js.map +1 -1
  286. package/lib/commonjs/skia/web/JsiSkRRect.js.map +1 -1
  287. package/lib/commonjs/skia/web/JsiSkRSXform.js.map +1 -1
  288. package/lib/commonjs/skia/web/JsiSkRect.js.map +1 -1
  289. package/lib/commonjs/skia/web/JsiSkRuntimeEffect.js.map +1 -1
  290. package/lib/commonjs/skia/web/JsiSkRuntimeEffectFactory.js.map +1 -1
  291. package/lib/commonjs/skia/web/JsiSkSVGFactory.js.map +1 -1
  292. package/lib/commonjs/skia/web/JsiSkShader.js.map +1 -1
  293. package/lib/commonjs/skia/web/JsiSkShaderFactory.js.map +1 -1
  294. package/lib/commonjs/skia/web/JsiSkSurface.js.map +1 -1
  295. package/lib/commonjs/skia/web/JsiSkSurfaceFactory.js.map +1 -1
  296. package/lib/commonjs/skia/web/JsiSkTextBlob.js.map +1 -1
  297. package/lib/commonjs/skia/web/JsiSkTextBlobFactory.js.map +1 -1
  298. package/lib/commonjs/skia/web/JsiSkTypeface.js.map +1 -1
  299. package/lib/commonjs/skia/web/JsiSkTypefaceFactory.js.map +1 -1
  300. package/lib/commonjs/skia/web/JsiSkVertices.js.map +1 -1
  301. package/lib/commonjs/skia/web/JsiSkVerticesFactory.js.map +1 -1
  302. package/lib/commonjs/skia/web/JsiSkia.js.map +1 -1
  303. package/lib/commonjs/skia/web/index.js.map +1 -1
  304. package/lib/commonjs/values/api.js.map +1 -1
  305. package/lib/commonjs/values/api.web.js.map +1 -1
  306. package/lib/commonjs/values/hooks/index.js.map +1 -1
  307. package/lib/commonjs/values/hooks/useClockValue.js.map +1 -1
  308. package/lib/commonjs/values/hooks/useComputedValue.js.map +1 -1
  309. package/lib/commonjs/values/hooks/useValue.js.map +1 -1
  310. package/lib/commonjs/values/hooks/useValueEffect.js.map +1 -1
  311. package/lib/commonjs/values/index.js.map +1 -1
  312. package/lib/commonjs/values/selector.js.map +1 -1
  313. package/lib/commonjs/values/types.js.map +1 -1
  314. package/lib/commonjs/values/web/RNSkAnimation.js +2 -2
  315. package/lib/commonjs/values/web/RNSkAnimation.js.map +1 -1
  316. package/lib/commonjs/values/web/RNSkClockValue.js.map +1 -1
  317. package/lib/commonjs/values/web/RNSkComputedValue.js +1 -1
  318. package/lib/commonjs/values/web/RNSkComputedValue.js.map +1 -1
  319. package/lib/commonjs/values/web/RNSkReadonlyValue.js.map +1 -1
  320. package/lib/commonjs/values/web/RNSkValue.js.map +1 -1
  321. package/lib/commonjs/values/web/api.js.map +1 -1
  322. package/lib/commonjs/values/web/index.js.map +1 -1
  323. package/lib/commonjs/views/SkiaView.js +1 -1
  324. package/lib/commonjs/views/SkiaView.js.map +1 -1
  325. package/lib/commonjs/views/SkiaView.web.js +2 -4
  326. package/lib/commonjs/views/SkiaView.web.js.map +1 -1
  327. package/lib/commonjs/views/api.js.map +1 -1
  328. package/lib/commonjs/views/index.js.map +1 -1
  329. package/lib/commonjs/views/types.js.map +1 -1
  330. package/lib/commonjs/views/useDrawCallback.js.map +1 -1
  331. package/lib/commonjs/views/useTouchHandler.js +6 -6
  332. package/lib/commonjs/views/useTouchHandler.js.map +1 -1
  333. package/lib/commonjs/web/LoadSkiaWeb.js.map +1 -1
  334. package/lib/commonjs/web/WithSkiaWeb.js +1 -1
  335. package/lib/commonjs/web/WithSkiaWeb.js.map +1 -1
  336. package/lib/commonjs/web/index.js.map +1 -1
  337. package/lib/module/animation/decay/decay.js.map +1 -1
  338. package/lib/module/animation/decay/index.js.map +1 -1
  339. package/lib/module/animation/decay/runDecay.js.map +1 -1
  340. package/lib/module/animation/decay/types.js.map +1 -1
  341. package/lib/module/animation/functions/index.js.map +1 -1
  342. package/lib/module/animation/functions/interpolate.js.map +1 -1
  343. package/lib/module/animation/functions/interpolateColors.js.map +1 -1
  344. package/lib/module/animation/functions/interpolatePaths.js.map +1 -1
  345. package/lib/module/animation/functions/interpolateVector.js.map +1 -1
  346. package/lib/module/animation/index.js.map +1 -1
  347. package/lib/module/animation/spring/Spring.js.map +1 -1
  348. package/lib/module/animation/spring/functions/index.js.map +1 -1
  349. package/lib/module/animation/spring/functions/spring.js.map +1 -1
  350. package/lib/module/animation/spring/index.js.map +1 -1
  351. package/lib/module/animation/spring/runSpring.js +1 -1
  352. package/lib/module/animation/spring/runSpring.js.map +1 -1
  353. package/lib/module/animation/spring/types.js.map +1 -1
  354. package/lib/module/animation/spring/useSpring.js +1 -1
  355. package/lib/module/animation/spring/useSpring.js.map +1 -1
  356. package/lib/module/animation/timing/Easing.js.map +1 -1
  357. package/lib/module/animation/timing/createTiming.js +2 -6
  358. package/lib/module/animation/timing/createTiming.js.map +1 -1
  359. package/lib/module/animation/timing/functions/bezier.js.map +1 -1
  360. package/lib/module/animation/timing/functions/getResolvedParams.js +6 -10
  361. package/lib/module/animation/timing/functions/getResolvedParams.js.map +1 -1
  362. package/lib/module/animation/timing/functions/index.js.map +1 -1
  363. package/lib/module/animation/timing/functions/timing.js.map +1 -1
  364. package/lib/module/animation/timing/functions/types.js.map +1 -1
  365. package/lib/module/animation/timing/index.js.map +1 -1
  366. package/lib/module/animation/timing/runTiming.js.map +1 -1
  367. package/lib/module/animation/timing/useLoop.js.map +1 -1
  368. package/lib/module/animation/timing/useTiming.js +1 -3
  369. package/lib/module/animation/timing/useTiming.js.map +1 -1
  370. package/lib/module/animation/types.js.map +1 -1
  371. package/lib/module/dom/nodes/DrawingNode.js.map +1 -1
  372. package/lib/module/dom/nodes/GroupNode.js.map +1 -1
  373. package/lib/module/dom/nodes/JsiSkDOM.js +1 -1
  374. package/lib/module/dom/nodes/JsiSkDOM.js.map +1 -1
  375. package/lib/module/dom/nodes/Node.js.map +1 -1
  376. package/lib/module/dom/nodes/PaintContext.js.map +1 -1
  377. package/lib/module/dom/nodes/PaintNode.js.map +1 -1
  378. package/lib/module/dom/nodes/RenderNode.js.map +1 -1
  379. package/lib/module/dom/nodes/datatypes/Circle.js.map +1 -1
  380. package/lib/module/dom/nodes/datatypes/Color.js.map +1 -1
  381. package/lib/module/dom/nodes/datatypes/Enum.js.map +1 -1
  382. package/lib/module/dom/nodes/datatypes/Fitting.js.map +1 -1
  383. package/lib/module/dom/nodes/datatypes/Gradient.js +2 -2
  384. package/lib/module/dom/nodes/datatypes/Gradient.js.map +1 -1
  385. package/lib/module/dom/nodes/datatypes/Path.js.map +1 -1
  386. package/lib/module/dom/nodes/datatypes/Radius.js.map +1 -1
  387. package/lib/module/dom/nodes/datatypes/Rect.js.map +1 -1
  388. package/lib/module/dom/nodes/datatypes/Transform.js.map +1 -1
  389. package/lib/module/dom/nodes/datatypes/index.js.map +1 -1
  390. package/lib/module/dom/nodes/drawings/BackdropFilterNode.js.map +1 -1
  391. package/lib/module/dom/nodes/drawings/Box.js.map +1 -1
  392. package/lib/module/dom/nodes/drawings/CircleNode.js.map +1 -1
  393. package/lib/module/dom/nodes/drawings/CustomDrawingNode.js.map +1 -1
  394. package/lib/module/dom/nodes/drawings/DiffRectNode.js.map +1 -1
  395. package/lib/module/dom/nodes/drawings/FillNode.js.map +1 -1
  396. package/lib/module/dom/nodes/drawings/ImageNode.js.map +1 -1
  397. package/lib/module/dom/nodes/drawings/ImageSVG.js.map +1 -1
  398. package/lib/module/dom/nodes/drawings/LineNode.js.map +1 -1
  399. package/lib/module/dom/nodes/drawings/OvalNode.js.map +1 -1
  400. package/lib/module/dom/nodes/drawings/PatchNode.js.map +1 -1
  401. package/lib/module/dom/nodes/drawings/PathNode.js.map +1 -1
  402. package/lib/module/dom/nodes/drawings/PictureNode.js.map +1 -1
  403. package/lib/module/dom/nodes/drawings/PointsNode.js.map +1 -1
  404. package/lib/module/dom/nodes/drawings/RRectNode.js.map +1 -1
  405. package/lib/module/dom/nodes/drawings/RectNode.js.map +1 -1
  406. package/lib/module/dom/nodes/drawings/Text.js.map +1 -1
  407. package/lib/module/dom/nodes/drawings/VerticesNode.js.map +1 -1
  408. package/lib/module/dom/nodes/drawings/index.js.map +1 -1
  409. package/lib/module/dom/nodes/index.js.map +1 -1
  410. package/lib/module/dom/nodes/paint/BlendNode.js.map +1 -1
  411. package/lib/module/dom/nodes/paint/ColorFilters.js.map +1 -1
  412. package/lib/module/dom/nodes/paint/ImageFilters.js.map +1 -1
  413. package/lib/module/dom/nodes/paint/MaskFilters.js.map +1 -1
  414. package/lib/module/dom/nodes/paint/PathEffects.js.map +1 -1
  415. package/lib/module/dom/nodes/paint/Shaders.js +2 -4
  416. package/lib/module/dom/nodes/paint/Shaders.js.map +1 -1
  417. package/lib/module/dom/nodes/paint/index.js.map +1 -1
  418. package/lib/module/dom/types/ColorFilters.js.map +1 -1
  419. package/lib/module/dom/types/Common.js.map +1 -1
  420. package/lib/module/dom/types/DrawingContext.js.map +1 -1
  421. package/lib/module/dom/types/Drawings.js.map +1 -1
  422. package/lib/module/dom/types/ImageFilters.js.map +1 -1
  423. package/lib/module/dom/types/MaskFilters.js.map +1 -1
  424. package/lib/module/dom/types/Node.js.map +1 -1
  425. package/lib/module/dom/types/NodeType.js.map +1 -1
  426. package/lib/module/dom/types/PathEffects.js.map +1 -1
  427. package/lib/module/dom/types/Shaders.js.map +1 -1
  428. package/lib/module/dom/types/SkDOM.js.map +1 -1
  429. package/lib/module/dom/types/index.js.map +1 -1
  430. package/lib/module/external/index.js.map +1 -1
  431. package/lib/module/external/reanimated/index.js.map +1 -1
  432. package/lib/module/external/reanimated/useSharedValueEffect.js.map +1 -1
  433. package/lib/module/index.js.map +1 -1
  434. package/lib/module/mock/index.js +6 -10
  435. package/lib/module/mock/index.js.map +1 -1
  436. package/lib/module/renderer/Canvas.js.map +1 -1
  437. package/lib/module/renderer/Container.js.map +1 -1
  438. package/lib/module/renderer/DependencyManager.js.map +1 -1
  439. package/lib/module/renderer/DrawingContext.js.map +1 -1
  440. package/lib/module/renderer/HostComponents.js.map +1 -1
  441. package/lib/module/renderer/HostConfig.js +0 -2
  442. package/lib/module/renderer/HostConfig.js.map +1 -1
  443. package/lib/module/renderer/components/Blend.js.map +1 -1
  444. package/lib/module/renderer/components/Drawing.js.map +1 -1
  445. package/lib/module/renderer/components/Group.js.map +1 -1
  446. package/lib/module/renderer/components/Mask.js.map +1 -1
  447. package/lib/module/renderer/components/Paint.js +1 -1
  448. package/lib/module/renderer/components/Paint.js.map +1 -1
  449. package/lib/module/renderer/components/Picture.js.map +1 -1
  450. package/lib/module/renderer/components/backdrop/BackdropBlur.js +1 -1
  451. package/lib/module/renderer/components/backdrop/BackdropBlur.js.map +1 -1
  452. package/lib/module/renderer/components/backdrop/BackdropFilter.js.map +1 -1
  453. package/lib/module/renderer/components/backdrop/index.js.map +1 -1
  454. package/lib/module/renderer/components/colorFilters/BlendColor.js.map +1 -1
  455. package/lib/module/renderer/components/colorFilters/Lerp.js.map +1 -1
  456. package/lib/module/renderer/components/colorFilters/LinearToSRGBGamma.js.map +1 -1
  457. package/lib/module/renderer/components/colorFilters/LumaColorFilter.js.map +1 -1
  458. package/lib/module/renderer/components/colorFilters/Matrix.js.map +1 -1
  459. package/lib/module/renderer/components/colorFilters/SRGBToLinearGamma.js.map +1 -1
  460. package/lib/module/renderer/components/colorFilters/index.js.map +1 -1
  461. package/lib/module/renderer/components/image/Image.js.map +1 -1
  462. package/lib/module/renderer/components/image/ImageSVG.js.map +1 -1
  463. package/lib/module/renderer/components/image/ImageShader.js.map +1 -1
  464. package/lib/module/renderer/components/image/index.js.map +1 -1
  465. package/lib/module/renderer/components/imageFilters/Blur.js.map +1 -1
  466. package/lib/module/renderer/components/imageFilters/DisplacementMap.js.map +1 -1
  467. package/lib/module/renderer/components/imageFilters/Morphology.js.map +1 -1
  468. package/lib/module/renderer/components/imageFilters/Offset.js.map +1 -1
  469. package/lib/module/renderer/components/imageFilters/RuntimeShader.js.map +1 -1
  470. package/lib/module/renderer/components/imageFilters/Shadow.js.map +1 -1
  471. package/lib/module/renderer/components/imageFilters/index.js.map +1 -1
  472. package/lib/module/renderer/components/index.js.map +1 -1
  473. package/lib/module/renderer/components/maskFilters/Blur.js.map +1 -1
  474. package/lib/module/renderer/components/maskFilters/index.js.map +1 -1
  475. package/lib/module/renderer/components/pathEffects/Corner.js.map +1 -1
  476. package/lib/module/renderer/components/pathEffects/Dash.js.map +1 -1
  477. package/lib/module/renderer/components/pathEffects/Discrete.js.map +1 -1
  478. package/lib/module/renderer/components/pathEffects/Line2D.js.map +1 -1
  479. package/lib/module/renderer/components/pathEffects/Path1D.js.map +1 -1
  480. package/lib/module/renderer/components/pathEffects/Path2D.js.map +1 -1
  481. package/lib/module/renderer/components/pathEffects/Sum.js.map +1 -1
  482. package/lib/module/renderer/components/pathEffects/index.js.map +1 -1
  483. package/lib/module/renderer/components/shaders/Color.js.map +1 -1
  484. package/lib/module/renderer/components/shaders/FractalNoise.js.map +1 -1
  485. package/lib/module/renderer/components/shaders/LinearGradient.js.map +1 -1
  486. package/lib/module/renderer/components/shaders/RadialGradient.js.map +1 -1
  487. package/lib/module/renderer/components/shaders/Shader.js.map +1 -1
  488. package/lib/module/renderer/components/shaders/ShaderLib.js.map +1 -1
  489. package/lib/module/renderer/components/shaders/SweepGradient.js.map +1 -1
  490. package/lib/module/renderer/components/shaders/Turbulence.js.map +1 -1
  491. package/lib/module/renderer/components/shaders/TwoPointConicalGradient.js.map +1 -1
  492. package/lib/module/renderer/components/shaders/index.js.map +1 -1
  493. package/lib/module/renderer/components/shapes/Box.js.map +1 -1
  494. package/lib/module/renderer/components/shapes/Circle.js.map +1 -1
  495. package/lib/module/renderer/components/shapes/DiffRect.js.map +1 -1
  496. package/lib/module/renderer/components/shapes/Fill.js.map +1 -1
  497. package/lib/module/renderer/components/shapes/FitBox.js.map +1 -1
  498. package/lib/module/renderer/components/shapes/Line.js.map +1 -1
  499. package/lib/module/renderer/components/shapes/Oval.js.map +1 -1
  500. package/lib/module/renderer/components/shapes/Patch.js.map +1 -1
  501. package/lib/module/renderer/components/shapes/Path.js.map +1 -1
  502. package/lib/module/renderer/components/shapes/Points.js.map +1 -1
  503. package/lib/module/renderer/components/shapes/Rect.js.map +1 -1
  504. package/lib/module/renderer/components/shapes/RoundedRect.js.map +1 -1
  505. package/lib/module/renderer/components/shapes/Vertices.js.map +1 -1
  506. package/lib/module/renderer/components/shapes/index.js.map +1 -1
  507. package/lib/module/renderer/components/text/Glyphs.js.map +1 -1
  508. package/lib/module/renderer/components/text/Text.js.map +1 -1
  509. package/lib/module/renderer/components/text/TextBlob.js.map +1 -1
  510. package/lib/module/renderer/components/text/TextPath.js.map +1 -1
  511. package/lib/module/renderer/components/text/index.js.map +1 -1
  512. package/lib/module/renderer/index.js.map +1 -1
  513. package/lib/module/renderer/processors/Animations/Animations.js.map +1 -1
  514. package/lib/module/renderer/processors/Animations/index.js.map +1 -1
  515. package/lib/module/renderer/processors/index.js.map +1 -1
  516. package/lib/module/renderer/processors/math/Coordinates.js.map +1 -1
  517. package/lib/module/renderer/processors/math/Math.js.map +1 -1
  518. package/lib/module/renderer/processors/math/Transforms.js.map +1 -1
  519. package/lib/module/renderer/processors/math/index.js.map +1 -1
  520. package/lib/module/renderer/typeddash.js.map +1 -1
  521. package/lib/module/renderer/useCanvas.js.map +1 -1
  522. package/lib/module/renderer/useContextBridge.js.map +1 -1
  523. package/lib/module/skia/NativeSetup.js.map +1 -1
  524. package/lib/module/skia/Skia.js.map +1 -1
  525. package/lib/module/skia/Skia.web.js.map +1 -1
  526. package/lib/module/skia/core/Data.js.map +1 -1
  527. package/lib/module/skia/core/Font.js.map +1 -1
  528. package/lib/module/skia/core/Image.js.map +1 -1
  529. package/lib/module/skia/core/Matrix.js.map +1 -1
  530. package/lib/module/skia/core/Picture.js.map +1 -1
  531. package/lib/module/skia/core/RRect.js.map +1 -1
  532. package/lib/module/skia/core/Rect.js.map +1 -1
  533. package/lib/module/skia/core/SVG.js.map +1 -1
  534. package/lib/module/skia/core/Typeface.js.map +1 -1
  535. package/lib/module/skia/core/Vector.js +1 -1
  536. package/lib/module/skia/core/Vector.js.map +1 -1
  537. package/lib/module/skia/core/index.js.map +1 -1
  538. package/lib/module/skia/index.js.map +1 -1
  539. package/lib/module/skia/types/Canvas.js.map +1 -1
  540. package/lib/module/skia/types/Color.js.map +1 -1
  541. package/lib/module/skia/types/ColorFilter/ColorFilter.js.map +1 -1
  542. package/lib/module/skia/types/ColorFilter/ColorFilterFactory.js.map +1 -1
  543. package/lib/module/skia/types/ColorFilter/index.js.map +1 -1
  544. package/lib/module/skia/types/ContourMeasure.js.map +1 -1
  545. package/lib/module/skia/types/Data/Data.js.map +1 -1
  546. package/lib/module/skia/types/Data/DataFactory.js.map +1 -1
  547. package/lib/module/skia/types/Data/index.js.map +1 -1
  548. package/lib/module/skia/types/Font/Font.js.map +1 -1
  549. package/lib/module/skia/types/Font/index.js.map +1 -1
  550. package/lib/module/skia/types/Image/Image.js.map +1 -1
  551. package/lib/module/skia/types/Image/ImageFactory.js.map +1 -1
  552. package/lib/module/skia/types/Image/index.js.map +1 -1
  553. package/lib/module/skia/types/ImageFilter/ImageFilter.js.map +1 -1
  554. package/lib/module/skia/types/ImageFilter/ImageFilterFactory.js.map +1 -1
  555. package/lib/module/skia/types/ImageFilter/index.js.map +1 -1
  556. package/lib/module/skia/types/JsiInstance.js.map +1 -1
  557. package/lib/module/skia/types/MaskFilter.js.map +1 -1
  558. package/lib/module/skia/types/Matrix.js.map +1 -1
  559. package/lib/module/skia/types/Paint/BlendMode.js.map +1 -1
  560. package/lib/module/skia/types/Paint/Paint.js.map +1 -1
  561. package/lib/module/skia/types/Paint/index.js.map +1 -1
  562. package/lib/module/skia/types/Path/Path.js.map +1 -1
  563. package/lib/module/skia/types/Path/PathFactory.js.map +1 -1
  564. package/lib/module/skia/types/Path/index.js.map +1 -1
  565. package/lib/module/skia/types/PathEffect.js.map +1 -1
  566. package/lib/module/skia/types/Picture/Picture.js.map +1 -1
  567. package/lib/module/skia/types/Picture/PictureFactory.js.map +1 -1
  568. package/lib/module/skia/types/Picture/PictureRecorder.js.map +1 -1
  569. package/lib/module/skia/types/Picture/index.js.map +1 -1
  570. package/lib/module/skia/types/Point.js.map +1 -1
  571. package/lib/module/skia/types/RRect.js.map +1 -1
  572. package/lib/module/skia/types/RSXform.js.map +1 -1
  573. package/lib/module/skia/types/Rect.js.map +1 -1
  574. package/lib/module/skia/types/RuntimeEffect/RuntimeEffect.js.map +1 -1
  575. package/lib/module/skia/types/RuntimeEffect/RuntimeEffectFactory.js.map +1 -1
  576. package/lib/module/skia/types/RuntimeEffect/index.js.map +1 -1
  577. package/lib/module/skia/types/SVG/SVG.js.map +1 -1
  578. package/lib/module/skia/types/SVG/SVGFactory.js.map +1 -1
  579. package/lib/module/skia/types/SVG/index.js.map +1 -1
  580. package/lib/module/skia/types/Shader/Shader.js.map +1 -1
  581. package/lib/module/skia/types/Shader/ShaderFactory.js.map +1 -1
  582. package/lib/module/skia/types/Shader/index.js.map +1 -1
  583. package/lib/module/skia/types/Skia.js.map +1 -1
  584. package/lib/module/skia/types/Surface/Surface.js.map +1 -1
  585. package/lib/module/skia/types/Surface/SurfaceFactory.js.map +1 -1
  586. package/lib/module/skia/types/Surface/index.js.map +1 -1
  587. package/lib/module/skia/types/TextBlob.js.map +1 -1
  588. package/lib/module/skia/types/Typeface/Typeface.js.map +1 -1
  589. package/lib/module/skia/types/Typeface/TypefaceFactory.js.map +1 -1
  590. package/lib/module/skia/types/Typeface/index.js.map +1 -1
  591. package/lib/module/skia/types/Vertices/Vertices.js.map +1 -1
  592. package/lib/module/skia/types/Vertices/index.js.map +1 -1
  593. package/lib/module/skia/types/index.js.map +1 -1
  594. package/lib/module/skia/web/Host.js +1 -1
  595. package/lib/module/skia/web/Host.js.map +1 -1
  596. package/lib/module/skia/web/JsiSkCanvas.js.map +1 -1
  597. package/lib/module/skia/web/JsiSkColor.js.map +1 -1
  598. package/lib/module/skia/web/JsiSkColorFilter.js.map +1 -1
  599. package/lib/module/skia/web/JsiSkColorFilterFactory.js.map +1 -1
  600. package/lib/module/skia/web/JsiSkContourMeasure.js.map +1 -1
  601. package/lib/module/skia/web/JsiSkContourMeasureIter.js.map +1 -1
  602. package/lib/module/skia/web/JsiSkData.js.map +1 -1
  603. package/lib/module/skia/web/JsiSkDataFactory.js.map +1 -1
  604. package/lib/module/skia/web/JsiSkFont.js.map +1 -1
  605. package/lib/module/skia/web/JsiSkImage.js.map +1 -1
  606. package/lib/module/skia/web/JsiSkImageFactory.js.map +1 -1
  607. package/lib/module/skia/web/JsiSkImageFilter.js.map +1 -1
  608. package/lib/module/skia/web/JsiSkImageFilterFactory.js.map +1 -1
  609. package/lib/module/skia/web/JsiSkMaskFilter.js.map +1 -1
  610. package/lib/module/skia/web/JsiSkMaskFilterFactory.js.map +1 -1
  611. package/lib/module/skia/web/JsiSkMatrix.js +1 -1
  612. package/lib/module/skia/web/JsiSkMatrix.js.map +1 -1
  613. package/lib/module/skia/web/JsiSkPaint.js.map +1 -1
  614. package/lib/module/skia/web/JsiSkPath.js.map +1 -1
  615. package/lib/module/skia/web/JsiSkPathEffect.js.map +1 -1
  616. package/lib/module/skia/web/JsiSkPathEffectFactory.js.map +1 -1
  617. package/lib/module/skia/web/JsiSkPathFactory.js.map +1 -1
  618. package/lib/module/skia/web/JsiSkPicture.js.map +1 -1
  619. package/lib/module/skia/web/JsiSkPictureFactory.js.map +1 -1
  620. package/lib/module/skia/web/JsiSkPictureRecorder.js.map +1 -1
  621. package/lib/module/skia/web/JsiSkPoint.js.map +1 -1
  622. package/lib/module/skia/web/JsiSkRRect.js.map +1 -1
  623. package/lib/module/skia/web/JsiSkRSXform.js.map +1 -1
  624. package/lib/module/skia/web/JsiSkRect.js.map +1 -1
  625. package/lib/module/skia/web/JsiSkRuntimeEffect.js.map +1 -1
  626. package/lib/module/skia/web/JsiSkRuntimeEffectFactory.js.map +1 -1
  627. package/lib/module/skia/web/JsiSkSVGFactory.js.map +1 -1
  628. package/lib/module/skia/web/JsiSkShader.js.map +1 -1
  629. package/lib/module/skia/web/JsiSkShaderFactory.js.map +1 -1
  630. package/lib/module/skia/web/JsiSkSurface.js.map +1 -1
  631. package/lib/module/skia/web/JsiSkSurfaceFactory.js.map +1 -1
  632. package/lib/module/skia/web/JsiSkTextBlob.js.map +1 -1
  633. package/lib/module/skia/web/JsiSkTextBlobFactory.js.map +1 -1
  634. package/lib/module/skia/web/JsiSkTypeface.js.map +1 -1
  635. package/lib/module/skia/web/JsiSkTypefaceFactory.js.map +1 -1
  636. package/lib/module/skia/web/JsiSkVertices.js.map +1 -1
  637. package/lib/module/skia/web/JsiSkVerticesFactory.js.map +1 -1
  638. package/lib/module/skia/web/JsiSkia.js.map +1 -1
  639. package/lib/module/skia/web/index.js.map +1 -1
  640. package/lib/module/values/api.js.map +1 -1
  641. package/lib/module/values/api.web.js.map +1 -1
  642. package/lib/module/values/hooks/index.js.map +1 -1
  643. package/lib/module/values/hooks/useClockValue.js.map +1 -1
  644. package/lib/module/values/hooks/useComputedValue.js.map +1 -1
  645. package/lib/module/values/hooks/useValue.js.map +1 -1
  646. package/lib/module/values/hooks/useValueEffect.js.map +1 -1
  647. package/lib/module/values/index.js.map +1 -1
  648. package/lib/module/values/selector.js.map +1 -1
  649. package/lib/module/values/types.js.map +1 -1
  650. package/lib/module/values/web/RNSkAnimation.js +2 -2
  651. package/lib/module/values/web/RNSkAnimation.js.map +1 -1
  652. package/lib/module/values/web/RNSkClockValue.js.map +1 -1
  653. package/lib/module/values/web/RNSkComputedValue.js +1 -1
  654. package/lib/module/values/web/RNSkComputedValue.js.map +1 -1
  655. package/lib/module/values/web/RNSkReadonlyValue.js.map +1 -1
  656. package/lib/module/values/web/RNSkValue.js.map +1 -1
  657. package/lib/module/values/web/api.js.map +1 -1
  658. package/lib/module/values/web/index.js.map +1 -1
  659. package/lib/module/views/SkiaView.js +1 -1
  660. package/lib/module/views/SkiaView.js.map +1 -1
  661. package/lib/module/views/SkiaView.web.js +2 -4
  662. package/lib/module/views/SkiaView.web.js.map +1 -1
  663. package/lib/module/views/api.js.map +1 -1
  664. package/lib/module/views/index.js.map +1 -1
  665. package/lib/module/views/types.js.map +1 -1
  666. package/lib/module/views/useDrawCallback.js.map +1 -1
  667. package/lib/module/views/useTouchHandler.js +6 -6
  668. package/lib/module/views/useTouchHandler.js.map +1 -1
  669. package/lib/module/web/LoadSkiaWeb.js.map +1 -1
  670. package/lib/module/web/WithSkiaWeb.js +1 -1
  671. package/lib/module/web/WithSkiaWeb.js.map +1 -1
  672. package/lib/module/web/index.js.map +1 -1
  673. package/lib/typescript/src/animation/decay/runDecay.d.ts +1 -1
  674. package/lib/typescript/src/animation/spring/runSpring.d.ts +1 -1
  675. package/lib/typescript/src/animation/spring/useSpring.d.ts +1 -1
  676. package/lib/typescript/src/animation/timing/createTiming.d.ts +1 -1
  677. package/lib/typescript/src/animation/timing/functions/getResolvedParams.d.ts +1 -1
  678. package/lib/typescript/src/animation/timing/runTiming.d.ts +1 -1
  679. package/lib/typescript/src/animation/timing/useLoop.d.ts +1 -1
  680. package/lib/typescript/src/animation/timing/useTiming.d.ts +1 -1
  681. package/lib/typescript/src/mock/index.d.ts +1 -1
  682. package/lib/typescript/src/renderer/Canvas.d.ts +1 -1
  683. package/lib/typescript/src/renderer/HostConfig.d.ts +1 -1
  684. package/lib/typescript/src/renderer/components/Paint.d.ts +1 -1
  685. package/lib/typescript/src/renderer/components/backdrop/BackdropFilter.d.ts +1 -1
  686. package/lib/typescript/src/renderer/processors/Animations/Animations.d.ts +4 -4
  687. package/lib/typescript/src/renderer/typeddash.d.ts +2 -2
  688. package/lib/typescript/src/skia/core/Font.d.ts +1 -1
  689. package/lib/typescript/src/skia/core/Vector.d.ts +2 -2
  690. package/lib/typescript/src/skia/types/Shader/Shader.d.ts +1 -1
  691. package/lib/typescript/src/skia/web/JsiSkVerticesFactory.d.ts +2 -2
  692. package/lib/typescript/src/web/LoadSkiaWeb.d.ts +2 -2
  693. package/package.json +6 -6
  694. package/src/renderer/HostConfig.ts +3 -4
  695. package/src/renderer/components/backdrop/BackdropFilter.tsx +1 -1
  696. package/src/renderer/processors/Animations/Animations.ts +11 -4
  697. package/src/renderer/typeddash.ts +3 -2
  698. package/src/values/web/RNSkComputedValue.ts +6 -1
@@ -1 +1 @@
1
- {"version":3,"sources":["JsiSkia.ts"],"names":["JsiSkPoint","JsiSkPaint","JsiSkRect","Color","JsiSkSurfaceFactory","JsiSkRRect","JsiSkRSXform","JsiSkContourMeasureIter","JsiSkPictureRecorder","JsiSkPictureFactory","JsiSkPathFactory","JsiSkMatrix","JsiSkColorFilterFactory","JsiSkTypefaceFactory","JsiSkMaskFilterFactory","JsiSkRuntimeEffectFactory","JsiSkImageFilterFactory","JsiSkShaderFactory","JsiSkPathEffectFactory","JsiSkDataFactory","JsiSkImageFactory","JsiSkSVGFactory","JsiSkTextBlobFactory","JsiSkFont","MakeVertices","JsiSkPath","JsiSkTypeface","JsiSkApi","CanvasKit","Point","x","y","Float32Array","of","RuntimeShaderBuilder","_","Error","RRectXY","rect","rx","ry","fromValue","RSXform","scos","ssin","tx","ty","ContourMeasureIter","path","forceClosed","resScale","Paint","paint","setAntiAlias","PictureRecorder","Picture","Path","Matrix","matrix","identity","ColorFilter","Font","typeface","size","undefined","Typeface","MaskFilter","RuntimeEffect","ImageFilter","Shader","PathEffect","bind","Data","Image","SVG","TextBlob","XYWHRect","width","height","Surface"],"mappings":"AAYA,SAASA,UAAT,QAA2B,cAA3B;AACA,SAASC,UAAT,QAA2B,cAA3B;AACA,SAASC,SAAT,QAA0B,aAA1B;AACA,SAASC,KAAT,QAAsB,cAAtB;AACA,SAASC,mBAAT,QAAoC,uBAApC;AACA,SAASC,UAAT,QAA2B,cAA3B;AACA,SAASC,YAAT,QAA6B,gBAA7B;AACA,SAASC,uBAAT,QAAwC,2BAAxC;AACA,SAASC,oBAAT,QAAqC,wBAArC;AACA,SAASC,mBAAT,QAAoC,uBAApC;AACA,SAASC,gBAAT,QAAiC,oBAAjC;AACA,SAASC,WAAT,QAA4B,eAA5B;AACA,SAASC,uBAAT,QAAwC,2BAAxC;AACA,SAASC,oBAAT,QAAqC,wBAArC;AACA,SAASC,sBAAT,QAAuC,0BAAvC;AACA,SAASC,yBAAT,QAA0C,6BAA1C;AACA,SAASC,uBAAT,QAAwC,2BAAxC;AACA,SAASC,kBAAT,QAAmC,sBAAnC;AACA,SAASC,sBAAT,QAAuC,0BAAvC;AACA,SAASC,gBAAT,QAAiC,oBAAjC;AACA,SAASC,iBAAT,QAAkC,qBAAlC;AACA,SAASC,eAAT,QAAgC,mBAAhC;AACA,SAASC,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,CAvD0C;AAwDvDyC,EAAAA,MAAM,EAAE,IAAIpD,kBAAJ,CAAuBW,SAAvB,CAxD+C;AAyDvD0C,EAAAA,UAAU,EAAE,IAAIpD,sBAAJ,CAA2BU,SAA3B,CAzD2C;AA0DvDJ,EAAAA,YAAY,EAAEA,YAAY,CAAC+C,IAAb,CAAkB,IAAlB,EAAwB3C,SAAxB,CA1DyC;AA2DvD4C,EAAAA,IAAI,EAAE,IAAIrD,gBAAJ,CAAqBS,SAArB,CA3DiD;AA4DvD6C,EAAAA,KAAK,EAAE,IAAIrD,iBAAJ,CAAsBQ,SAAtB,CA5DgD;AA6DvD8C,EAAAA,GAAG,EAAE,IAAIrD,eAAJ,CAAoBO,SAApB,CA7DkD;AA8DvD+C,EAAAA,QAAQ,EAAE,IAAIrD,oBAAJ,CAAyBM,SAAzB,CA9D6C;AA+DvDgD,EAAAA,QAAQ,EAAE,CAAC9C,CAAD,EAAYC,CAAZ,EAAuB8C,KAAvB,EAAsCC,MAAtC,KAAyD;AACjE,WAAO,IAAI5E,SAAJ,CAAc0B,SAAd,EAAyBA,SAAS,CAACgD,QAAV,CAAmB9C,CAAnB,EAAsBC,CAAtB,EAAyB8C,KAAzB,EAAgCC,MAAhC,CAAzB,CAAP;AACD,GAjEsD;AAkEvDC,EAAAA,OAAO,EAAE,IAAI3E,mBAAJ,CAAwBwB,SAAxB;AAlE8C,CAAjC,CAAjB","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type {\n SkContourMeasureIter,\n Skia,\n SkPath,\n SkRect,\n SkRuntimeEffect,\n SkRuntimeShaderBuilder,\n SkTypeface,\n} from \"../types\";\n\nimport { JsiSkPoint } from \"./JsiSkPoint\";\nimport { JsiSkPaint } from \"./JsiSkPaint\";\nimport { JsiSkRect } from \"./JsiSkRect\";\nimport { Color } from \"./JsiSkColor\";\nimport { JsiSkSurfaceFactory } from \"./JsiSkSurfaceFactory\";\nimport { JsiSkRRect } from \"./JsiSkRRect\";\nimport { JsiSkRSXform } from \"./JsiSkRSXform\";\nimport { JsiSkContourMeasureIter } from \"./JsiSkContourMeasureIter\";\nimport { JsiSkPictureRecorder } from \"./JsiSkPictureRecorder\";\nimport { JsiSkPictureFactory } from \"./JsiSkPictureFactory\";\nimport { JsiSkPathFactory } from \"./JsiSkPathFactory\";\nimport { JsiSkMatrix } from \"./JsiSkMatrix\";\nimport { JsiSkColorFilterFactory } from \"./JsiSkColorFilterFactory\";\nimport { JsiSkTypefaceFactory } from \"./JsiSkTypefaceFactory\";\nimport { JsiSkMaskFilterFactory } from \"./JsiSkMaskFilterFactory\";\nimport { JsiSkRuntimeEffectFactory } from \"./JsiSkRuntimeEffectFactory\";\nimport { JsiSkImageFilterFactory } from \"./JsiSkImageFilterFactory\";\nimport { JsiSkShaderFactory } from \"./JsiSkShaderFactory\";\nimport { JsiSkPathEffectFactory } from \"./JsiSkPathEffectFactory\";\nimport { JsiSkDataFactory } from \"./JsiSkDataFactory\";\nimport { JsiSkImageFactory } from \"./JsiSkImageFactory\";\nimport { JsiSkSVGFactory } from \"./JsiSkSVGFactory\";\nimport { JsiSkTextBlobFactory } from \"./JsiSkTextBlobFactory\";\nimport { JsiSkFont } from \"./JsiSkFont\";\nimport { MakeVertices } from \"./JsiSkVerticesFactory\";\nimport { JsiSkPath } from \"./JsiSkPath\";\nimport { JsiSkTypeface } from \"./JsiSkTypeface\";\n\nexport const JsiSkApi = (CanvasKit: CanvasKit): Skia => ({\n Point: (x: number, y: number) =>\n new JsiSkPoint(CanvasKit, Float32Array.of(x, y)),\n RuntimeShaderBuilder: (_: SkRuntimeEffect): SkRuntimeShaderBuilder => {\n throw new Error(\"Not implemented on React Native Web\");\n },\n RRectXY: (rect: SkRect, rx: number, ry: number) =>\n new JsiSkRRect(\n CanvasKit,\n CanvasKit.RRectXY(JsiSkRect.fromValue(CanvasKit, rect), rx, ry)\n ),\n RSXform: (scos: number, ssin: number, tx: number, ty: number) =>\n new JsiSkRSXform(CanvasKit, Float32Array.of(scos, ssin, tx, ty)),\n Color,\n ContourMeasureIter: (\n path: SkPath,\n forceClosed: boolean,\n resScale: number\n ): SkContourMeasureIter =>\n new JsiSkContourMeasureIter(\n CanvasKit,\n new CanvasKit.ContourMeasureIter(\n JsiSkPath.fromValue(path),\n forceClosed,\n resScale\n )\n ),\n Paint: () => {\n const paint = new JsiSkPaint(CanvasKit, new CanvasKit.Paint());\n paint.setAntiAlias(true);\n return paint;\n },\n PictureRecorder: () =>\n new JsiSkPictureRecorder(CanvasKit, new CanvasKit.PictureRecorder()),\n Picture: new JsiSkPictureFactory(CanvasKit),\n Path: new JsiSkPathFactory(CanvasKit),\n Matrix: (matrix?: readonly number[]) =>\n new JsiSkMatrix(\n CanvasKit,\n matrix\n ? Float32Array.of(...matrix)\n : Float32Array.of(...CanvasKit.Matrix.identity())\n ),\n ColorFilter: new JsiSkColorFilterFactory(CanvasKit),\n Font: (typeface?: SkTypeface, size?: number) =>\n new JsiSkFont(\n CanvasKit,\n new CanvasKit.Font(\n typeface === undefined ? null : JsiSkTypeface.fromValue(typeface),\n size\n )\n ),\n Typeface: new JsiSkTypefaceFactory(CanvasKit),\n MaskFilter: new JsiSkMaskFilterFactory(CanvasKit),\n RuntimeEffect: new JsiSkRuntimeEffectFactory(CanvasKit),\n ImageFilter: new JsiSkImageFilterFactory(CanvasKit),\n Shader: new JsiSkShaderFactory(CanvasKit),\n PathEffect: new JsiSkPathEffectFactory(CanvasKit),\n MakeVertices: MakeVertices.bind(null, CanvasKit),\n Data: new JsiSkDataFactory(CanvasKit),\n Image: new JsiSkImageFactory(CanvasKit),\n SVG: new JsiSkSVGFactory(CanvasKit),\n TextBlob: new JsiSkTextBlobFactory(CanvasKit),\n XYWHRect: (x: number, y: number, width: number, height: number) => {\n return new JsiSkRect(CanvasKit, CanvasKit.XYWHRect(x, y, width, height));\n },\n Surface: new JsiSkSurfaceFactory(CanvasKit),\n});\n"]}
1
+ {"version":3,"names":["JsiSkPoint","JsiSkPaint","JsiSkRect","Color","JsiSkSurfaceFactory","JsiSkRRect","JsiSkRSXform","JsiSkContourMeasureIter","JsiSkPictureRecorder","JsiSkPictureFactory","JsiSkPathFactory","JsiSkMatrix","JsiSkColorFilterFactory","JsiSkTypefaceFactory","JsiSkMaskFilterFactory","JsiSkRuntimeEffectFactory","JsiSkImageFilterFactory","JsiSkShaderFactory","JsiSkPathEffectFactory","JsiSkDataFactory","JsiSkImageFactory","JsiSkSVGFactory","JsiSkTextBlobFactory","JsiSkFont","MakeVertices","JsiSkPath","JsiSkTypeface","JsiSkApi","CanvasKit","Point","x","y","Float32Array","of","RuntimeShaderBuilder","_","Error","RRectXY","rect","rx","ry","fromValue","RSXform","scos","ssin","tx","ty","ContourMeasureIter","path","forceClosed","resScale","Paint","paint","setAntiAlias","PictureRecorder","Picture","Path","Matrix","matrix","identity","ColorFilter","Font","typeface","size","undefined","Typeface","MaskFilter","RuntimeEffect","ImageFilter","Shader","PathEffect","bind","Data","Image","SVG","TextBlob","XYWHRect","width","height","Surface"],"sources":["JsiSkia.ts"],"sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type {\n SkContourMeasureIter,\n Skia,\n SkPath,\n SkRect,\n SkRuntimeEffect,\n SkRuntimeShaderBuilder,\n SkTypeface,\n} from \"../types\";\n\nimport { JsiSkPoint } from \"./JsiSkPoint\";\nimport { JsiSkPaint } from \"./JsiSkPaint\";\nimport { JsiSkRect } from \"./JsiSkRect\";\nimport { Color } from \"./JsiSkColor\";\nimport { JsiSkSurfaceFactory } from \"./JsiSkSurfaceFactory\";\nimport { JsiSkRRect } from \"./JsiSkRRect\";\nimport { JsiSkRSXform } from \"./JsiSkRSXform\";\nimport { JsiSkContourMeasureIter } from \"./JsiSkContourMeasureIter\";\nimport { JsiSkPictureRecorder } from \"./JsiSkPictureRecorder\";\nimport { JsiSkPictureFactory } from \"./JsiSkPictureFactory\";\nimport { JsiSkPathFactory } from \"./JsiSkPathFactory\";\nimport { JsiSkMatrix } from \"./JsiSkMatrix\";\nimport { JsiSkColorFilterFactory } from \"./JsiSkColorFilterFactory\";\nimport { JsiSkTypefaceFactory } from \"./JsiSkTypefaceFactory\";\nimport { JsiSkMaskFilterFactory } from \"./JsiSkMaskFilterFactory\";\nimport { JsiSkRuntimeEffectFactory } from \"./JsiSkRuntimeEffectFactory\";\nimport { JsiSkImageFilterFactory } from \"./JsiSkImageFilterFactory\";\nimport { JsiSkShaderFactory } from \"./JsiSkShaderFactory\";\nimport { JsiSkPathEffectFactory } from \"./JsiSkPathEffectFactory\";\nimport { JsiSkDataFactory } from \"./JsiSkDataFactory\";\nimport { JsiSkImageFactory } from \"./JsiSkImageFactory\";\nimport { JsiSkSVGFactory } from \"./JsiSkSVGFactory\";\nimport { JsiSkTextBlobFactory } from \"./JsiSkTextBlobFactory\";\nimport { JsiSkFont } from \"./JsiSkFont\";\nimport { MakeVertices } from \"./JsiSkVerticesFactory\";\nimport { JsiSkPath } from \"./JsiSkPath\";\nimport { JsiSkTypeface } from \"./JsiSkTypeface\";\n\nexport const JsiSkApi = (CanvasKit: CanvasKit): Skia => ({\n Point: (x: number, y: number) =>\n new JsiSkPoint(CanvasKit, Float32Array.of(x, y)),\n RuntimeShaderBuilder: (_: SkRuntimeEffect): SkRuntimeShaderBuilder => {\n throw new Error(\"Not implemented on React Native Web\");\n },\n RRectXY: (rect: SkRect, rx: number, ry: number) =>\n new JsiSkRRect(\n CanvasKit,\n CanvasKit.RRectXY(JsiSkRect.fromValue(CanvasKit, rect), rx, ry)\n ),\n RSXform: (scos: number, ssin: number, tx: number, ty: number) =>\n new JsiSkRSXform(CanvasKit, Float32Array.of(scos, ssin, tx, ty)),\n Color,\n ContourMeasureIter: (\n path: SkPath,\n forceClosed: boolean,\n resScale: number\n ): SkContourMeasureIter =>\n new JsiSkContourMeasureIter(\n CanvasKit,\n new CanvasKit.ContourMeasureIter(\n JsiSkPath.fromValue(path),\n forceClosed,\n resScale\n )\n ),\n Paint: () => {\n const paint = new JsiSkPaint(CanvasKit, new CanvasKit.Paint());\n paint.setAntiAlias(true);\n return paint;\n },\n PictureRecorder: () =>\n new JsiSkPictureRecorder(CanvasKit, new CanvasKit.PictureRecorder()),\n Picture: new JsiSkPictureFactory(CanvasKit),\n Path: new JsiSkPathFactory(CanvasKit),\n Matrix: (matrix?: readonly number[]) =>\n new JsiSkMatrix(\n CanvasKit,\n matrix\n ? Float32Array.of(...matrix)\n : Float32Array.of(...CanvasKit.Matrix.identity())\n ),\n ColorFilter: new JsiSkColorFilterFactory(CanvasKit),\n Font: (typeface?: SkTypeface, size?: number) =>\n new JsiSkFont(\n CanvasKit,\n new CanvasKit.Font(\n typeface === undefined ? null : JsiSkTypeface.fromValue(typeface),\n size\n )\n ),\n Typeface: new JsiSkTypefaceFactory(CanvasKit),\n MaskFilter: new JsiSkMaskFilterFactory(CanvasKit),\n RuntimeEffect: new JsiSkRuntimeEffectFactory(CanvasKit),\n ImageFilter: new JsiSkImageFilterFactory(CanvasKit),\n Shader: new JsiSkShaderFactory(CanvasKit),\n PathEffect: new JsiSkPathEffectFactory(CanvasKit),\n MakeVertices: MakeVertices.bind(null, CanvasKit),\n Data: new JsiSkDataFactory(CanvasKit),\n Image: new JsiSkImageFactory(CanvasKit),\n SVG: new JsiSkSVGFactory(CanvasKit),\n TextBlob: new JsiSkTextBlobFactory(CanvasKit),\n XYWHRect: (x: number, y: number, width: number, height: number) => {\n return new JsiSkRect(CanvasKit, CanvasKit.XYWHRect(x, y, width, height));\n },\n Surface: new JsiSkSurfaceFactory(CanvasKit),\n});\n"],"mappings":"AAYA,SAASA,UAAT,QAA2B,cAA3B;AACA,SAASC,UAAT,QAA2B,cAA3B;AACA,SAASC,SAAT,QAA0B,aAA1B;AACA,SAASC,KAAT,QAAsB,cAAtB;AACA,SAASC,mBAAT,QAAoC,uBAApC;AACA,SAASC,UAAT,QAA2B,cAA3B;AACA,SAASC,YAAT,QAA6B,gBAA7B;AACA,SAASC,uBAAT,QAAwC,2BAAxC;AACA,SAASC,oBAA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ia\";\n"]}
1
+ {"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./JsiSkia\";\n"],"mappings":"AAAA,cAAc,WAAd"}
@@ -1 +1 @@
1
- {"version":3,"sources":["api.ts"],"names":["SkiaValueApi","global","ValueApi"],"mappings":"AAMA,MAAM;AAAEA,EAAAA;AAAF,IAAmBC,MAAzB;AACA,OAAO,MAAMC,QAAQ,GAAGF,YAAjB","sourcesContent":["import type { ISkiaValueApi } from \"./types\";\n\ndeclare global {\n var SkiaValueApi: ISkiaValueApi;\n}\n\nconst { SkiaValueApi } = global;\nexport const ValueApi = SkiaValueApi;\n"]}
1
+ {"version":3,"names":["SkiaValueApi","global","ValueApi"],"sources":["api.ts"],"sourcesContent":["import type { ISkiaValueApi } from \"./types\";\n\ndeclare global {\n var SkiaValueApi: ISkiaValueApi;\n}\n\nconst { SkiaValueApi } = global;\nexport const ValueApi = SkiaValueApi;\n"],"mappings":"AAMA,MAAM;EAAEA;AAAF,IAAmBC,MAAzB;AACA,OAAO,MAAMC,QAAQ,GAAGF,YAAjB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["api.web.ts"],"names":["ValueApi","ValueApiWeb","createValue","createComputedValue"],"mappings":"AAAA,SAASA,QAAQ,IAAIC,WAArB,QAAwC,OAAxC;AAEA,OAAO,MAAMD,QAAQ,GAAGC,WAAjB;AAEP,OAAO,MAAM;AAAEC,EAAAA,WAAF;AAAeC,EAAAA;AAAf,IAAuCH,QAA7C","sourcesContent":["import { ValueApi as ValueApiWeb } from \"./web\";\n\nexport const ValueApi = ValueApiWeb;\n\nexport const { createValue, createComputedValue } = ValueApi;\n"]}
1
+ {"version":3,"names":["ValueApi","ValueApiWeb","createValue","createComputedValue"],"sources":["api.web.ts"],"sourcesContent":["import { ValueApi as ValueApiWeb } from \"./web\";\n\nexport const ValueApi = ValueApiWeb;\n\nexport const { createValue, createComputedValue } = ValueApi;\n"],"mappings":"AAAA,SAASA,QAAQ,IAAIC,WAArB,QAAwC,OAAxC;AAEA,OAAO,MAAMD,QAAQ,GAAGC,WAAjB;AAEP,OAAO,MAAM;EAAEC,WAAF;EAAeC;AAAf,IAAuCH,QAA7C"}
@@ -1 +1 @@
1
- {"version":3,"sources":["index.ts"],"names":[],"mappings":"AAAA,cAAc,iBAAd;AACA,cAAc,oBAAd;AACA,cAAc,YAAd;AACA,cAAc,kBAAd","sourcesContent":["export * from \"./useClockValue\";\nexport * from \"./useComputedValue\";\nexport * from \"./useValue\";\nexport * from \"./useValueEffect\";\n"]}
1
+ {"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./useClockValue\";\nexport * from \"./useComputedValue\";\nexport * from \"./useValue\";\nexport * from \"./useValueEffect\";\n"],"mappings":"AAAA,cAAc,iBAAd;AACA,cAAc,oBAAd;AACA,cAAc,YAAd;AACA,cAAc,kBAAd"}
@@ -1 +1 @@
1
- {"version":3,"sources":["useClockValue.ts"],"names":["useEffect","useMemo","ValueApi","useClockValue","clock","createClockValue","start","stop"],"mappings":"AAAA,SAASA,SAAT,EAAoBC,OAApB,QAAmC,OAAnC;AAEA,SAASC,QAAT,QAAyB,QAAzB;AAEA;AACA;AACA;AACA;AACA;;AAEA,OAAO,MAAMC,aAAa,GAAG,MAAM;AACjC,QAAMC,KAAK,GAAGH,OAAO,CAAC,MAAMC,QAAQ,CAACG,gBAAT,EAAP,EAAoC,EAApC,CAArB;AACAL,EAAAA,SAAS,CAAC,MAAM;AACdI,IAAAA,KAAK,CAACE,KAAN;AACA,WAAOF,KAAK,CAACG,IAAb;AACD,GAHQ,EAGN,CAACH,KAAD,CAHM,CAAT;AAIA,SAAOA,KAAP;AACD,CAPM","sourcesContent":["import { useEffect, useMemo } from \"react\";\n\nimport { ValueApi } from \"../api\";\n\n/**\n * @returns A new value that will be updated on every frame redraw with the\n * number of milliseconds elapsed since the value was started.\n * The clock is created in the stopped state.\n */\n\nexport const useClockValue = () => {\n const clock = useMemo(() => ValueApi.createClockValue(), []);\n useEffect(() => {\n clock.start();\n return clock.stop;\n }, [clock]);\n return clock;\n};\n"]}
1
+ {"version":3,"names":["useEffect","useMemo","ValueApi","useClockValue","clock","createClockValue","start","stop"],"sources":["useClockValue.ts"],"sourcesContent":["import { useEffect, useMemo } from \"react\";\n\nimport { ValueApi } from \"../api\";\n\n/**\n * @returns A new value that will be updated on every frame redraw with the\n * number of milliseconds elapsed since the value was started.\n * The clock is created in the stopped state.\n */\n\nexport const useClockValue = () => {\n const clock = useMemo(() => ValueApi.createClockValue(), []);\n useEffect(() => {\n clock.start();\n return clock.stop;\n }, [clock]);\n return clock;\n};\n"],"mappings":"AAAA,SAASA,SAAT,EAAoBC,OAApB,QAAmC,OAAnC;AAEA,SAASC,QAAT,QAAyB,QAAzB;AAEA;AACA;AACA;AACA;AACA;;AAEA,OAAO,MAAMC,aAAa,GAAG,MAAM;EACjC,MAAMC,KAAK,GAAGH,OAAO,CAAC,MAAMC,QAAQ,CAACG,gBAAT,EAAP,EAAoC,EAApC,CAArB;EACAL,SAAS,CAAC,MAAM;IACdI,KAAK,CAACE,KAAN;IACA,OAAOF,KAAK,CAACG,IAAb;EACD,CAHQ,EAGN,CAACH,KAAD,CAHM,CAAT;EAIA,OAAOA,KAAP;AACD,CAPM"}
@@ -1 +1 @@
1
- {"version":3,"sources":["useComputedValue.ts"],"names":["useEffect","useMemo","ValueApi","isValue","useComputedValue","cb","values","value","createComputedValue","filter","__invalidate"],"mappings":"AAAA,SAASA,SAAT,EAAoBC,OAApB,QAAmC,OAAnC;AAEA,SAASC,QAAT,QAAyB,QAAzB;AACA,SAASC,OAAT,QAAwB,sCAAxB;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,MAAMC,gBAAgB,GAAG,CAAIC,EAAJ,EAAiBC,MAAjB,KAAuC;AACrE,QAAMC,KAAK,GAAGN,OAAO,CACnB,MAAMC,QAAQ,CAACM,mBAAT,CAAgCH,EAAhC,EAAoCC,MAAM,CAACG,MAAP,CAAcN,OAAd,CAApC,CADa,EAEnB;AACAG,EAAAA,MAHmB,CAArB;AAKAN,EAAAA,SAAS,CAAC,MAAM,MAAMO,KAAK,CAACG,YAAN,EAAb,EAAmC,CAACH,KAAD,CAAnC,CAAT;AACA,SAAOA,KAAP;AACD,CARM","sourcesContent":["import { useEffect, useMemo } from \"react\";\n\nimport { ValueApi } from \"../api\";\nimport { isValue } from \"../../renderer/processors/Animations\";\n\n/**\n * Creates a new computed value - a value that will calculate its value depending\n * on other values.\n * @param cb Callback to calculate new value\n * @param values Dependant values\n * @returns A readonly value\n */\nexport const useComputedValue = <R>(cb: () => R, values: unknown[]) => {\n const value = useMemo(\n () => ValueApi.createComputedValue<R>(cb, values.filter(isValue)),\n // eslint-disable-next-line react-hooks/exhaustive-deps\n values\n );\n useEffect(() => () => value.__invalidate(), [value]);\n return value;\n};\n"]}
1
+ {"version":3,"names":["useEffect","useMemo","ValueApi","isValue","useComputedValue","cb","values","value","createComputedValue","filter","__invalidate"],"sources":["useComputedValue.ts"],"sourcesContent":["import { useEffect, useMemo } from \"react\";\n\nimport { ValueApi } from \"../api\";\nimport { isValue } from \"../../renderer/processors/Animations\";\n\n/**\n * Creates a new computed value - a value that will calculate its value depending\n * on other values.\n * @param cb Callback to calculate new value\n * @param values Dependant values\n * @returns A readonly value\n */\nexport const useComputedValue = <R>(cb: () => R, values: unknown[]) => {\n const value = useMemo(\n () => ValueApi.createComputedValue<R>(cb, values.filter(isValue)),\n // eslint-disable-next-line react-hooks/exhaustive-deps\n values\n );\n useEffect(() => () => value.__invalidate(), [value]);\n return value;\n};\n"],"mappings":"AAAA,SAASA,SAAT,EAAoBC,OAApB,QAAmC,OAAnC;AAEA,SAASC,QAAT,QAAyB,QAAzB;AACA,SAASC,OAAT,QAAwB,sCAAxB;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,MAAMC,gBAAgB,GAAG,CAAIC,EAAJ,EAAiBC,MAAjB,KAAuC;EACrE,MAAMC,KAAK,GAAGN,OAAO,CACnB,MAAMC,QAAQ,CAACM,mBAAT,CAAgCH,EAAhC,EAAoCC,MAAM,CAACG,MAAP,CAAcN,OAAd,CAApC,CADa,EAEnB;EACAG,MAHmB,CAArB;EAKAN,SAAS,CAAC,MAAM,MAAMO,KAAK,CAACG,YAAN,EAAb,EAAmC,CAACH,KAAD,CAAnC,CAAT;EACA,OAAOA,KAAP;AACD,CARM"}
@@ -1 +1 @@
1
- {"version":3,"sources":["useValue.ts"],"names":["useMemo","ValueApi","useValue","v","createValue"],"mappings":"AAAA,SAASA,OAAT,QAAwB,OAAxB;AAEA,SAASC,QAAT,QAAyB,QAAzB;;AAGA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,QAAQ,GAAOC,CAAJ,IAAkC;AACxD;AACA,SAAOH,OAAO,CAAC,MAAMC,QAAQ,CAACG,WAAT,CAAqBD,CAArB,CAAP,EAAgC,EAAhC,CAAd;AACD,CAHM","sourcesContent":["import { useMemo } from \"react\";\n\nimport { ValueApi } from \"../api\";\nimport type { SkiaMutableValue } from \"../types\";\n\n/**\n * Creates a new value that holds some data.\n * @param v Value to hold\n * @returns A Value of type of v\n */\nexport const useValue = <T>(v: T): SkiaMutableValue<T> => {\n // eslint-disable-next-line react-hooks/exhaustive-deps\n return useMemo(() => ValueApi.createValue(v), []);\n};\n"]}
1
+ {"version":3,"names":["useMemo","ValueApi","useValue","v","createValue"],"sources":["useValue.ts"],"sourcesContent":["import { useMemo } from \"react\";\n\nimport { ValueApi } from \"../api\";\nimport type { SkiaMutableValue } from \"../types\";\n\n/**\n * Creates a new value that holds some data.\n * @param v Value to hold\n * @returns A Value of type of v\n */\nexport const useValue = <T>(v: T): SkiaMutableValue<T> => {\n // eslint-disable-next-line react-hooks/exhaustive-deps\n return useMemo(() => ValueApi.createValue(v), []);\n};\n"],"mappings":"AAAA,SAASA,OAAT,QAAwB,OAAxB;AAEA,SAASC,QAAT,QAAyB,QAAzB;;AAGA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,QAAQ,GAAOC,CAAJ,IAAkC;EACxD;EACA,OAAOH,OAAO,CAAC,MAAMC,QAAQ,CAACG,WAAT,CAAqBD,CAArB,CAAP,EAAgC,EAAhC,CAAd;AACD,CAHM"}
@@ -1 +1 @@
1
- {"version":3,"sources":["useValueEffect.ts"],"names":["useEffect","useValueEffect","value","cb","addListener"],"mappings":"AAAA,SAASA,SAAT,QAA0B,OAA1B;;AAIA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,cAAc,GAAG,CAAIC,KAAJ,EAAyBC,EAAzB,KAAgD;AAC5EH,EAAAA,SAAS,CAAC,MAAM;AACd,WAAOE,KAAK,CAACE,WAAN,CAAkBD,EAAlB,CAAP,CADc,CAEd;AACD,GAHQ,EAGN,CAACD,KAAD,CAHM,CAAT;AAID,CALM","sourcesContent":["import { useEffect } from \"react\";\n\nimport type { SkiaValue } from \"../types\";\n\n/**\n * Sets up an effect that will be run whenever the value changes\n * @param value Value to subscribe to changes on\n * @param cb Callback to run when value changes\n */\nexport const useValueEffect = <T>(value: SkiaValue<T>, cb: (v: T) => void) => {\n useEffect(() => {\n return value.addListener(cb);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [value]);\n};\n"]}
1
+ {"version":3,"names":["useEffect","useValueEffect","value","cb","addListener"],"sources":["useValueEffect.ts"],"sourcesContent":["import { useEffect } from \"react\";\n\nimport type { SkiaValue } from \"../types\";\n\n/**\n * Sets up an effect that will be run whenever the value changes\n * @param value Value to subscribe to changes on\n * @param cb Callback to run when value changes\n */\nexport const useValueEffect = <T>(value: SkiaValue<T>, cb: (v: T) => void) => {\n useEffect(() => {\n return value.addListener(cb);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [value]);\n};\n"],"mappings":"AAAA,SAASA,SAAT,QAA0B,OAA1B;;AAIA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,cAAc,GAAG,CAAIC,KAAJ,EAAyBC,EAAzB,KAAgD;EAC5EH,SAAS,CAAC,MAAM;IACd,OAAOE,KAAK,CAACE,WAAN,CAAkBD,EAAlB,CAAP,CADc,CAEd;EACD,CAHQ,EAGN,CAACD,KAAD,CAHM,CAAT;AAID,CALM"}
@@ -1 +1 @@
1
- {"version":3,"sources":["index.ts"],"names":[],"mappings":"AAAA,cAAc,SAAd;AACA,cAAc,SAAd;AACA,cAAc,OAAd;AACA,cAAc,YAAd","sourcesContent":["export * from \"./types\";\nexport * from \"./hooks\";\nexport * from \"./api\";\nexport * from \"./selector\";\n"]}
1
+ {"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./types\";\nexport * from \"./hooks\";\nexport * from \"./api\";\nexport * from \"./selector\";\n"],"mappings":"AAAA,cAAc,SAAd;AACA,cAAc,SAAd;AACA,cAAc,OAAd;AACA,cAAc,YAAd"}
@@ -1 +1 @@
1
- {"version":3,"sources":["selector.ts"],"names":["Selector","value","selector"],"mappings":"AAOA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMA,QAAQ,GAAG,CACtBC,KADsB,EAEtBC,QAFsB,KAGY;AAClC,SAAO;AACLA,IAAAA,QADK;AAELD,IAAAA;AAFK,GAAP;AAID,CARM","sourcesContent":["import type { SkiaValue } from \"./types\";\n\nexport type SkiaSelector<TReturn, TInput = unknown> = {\n value: SkiaValue<TInput>;\n selector: (v: TInput) => TReturn;\n};\n\n/**\n * Wraps a Skia Value with a selector function. The selector function can access the\n * inner values of the Skia Value so that we can dynamically ready array values and\n * object values when doing animations in Skia.\n * @param value Dependant value\n * @param selector Selector function to calculate new value from the Skia Value's value\n * @returns A descriptor that will be used by the reconciler to calculate the value\n */\nexport const Selector = <TInput, TReturn>(\n value: SkiaValue<TInput>,\n selector: (v: TInput) => TReturn\n): SkiaSelector<TReturn, TInput> => {\n return {\n selector,\n value,\n };\n};\n"]}
1
+ {"version":3,"names":["Selector","value","selector"],"sources":["selector.ts"],"sourcesContent":["import type { SkiaValue } from \"./types\";\n\nexport type SkiaSelector<TReturn, TInput = unknown> = {\n value: SkiaValue<TInput>;\n selector: (v: TInput) => TReturn;\n};\n\n/**\n * Wraps a Skia Value with a selector function. The selector function can access the\n * inner values of the Skia Value so that we can dynamically ready array values and\n * object values when doing animations in Skia.\n * @param value Dependant value\n * @param selector Selector function to calculate new value from the Skia Value's value\n * @returns A descriptor that will be used by the reconciler to calculate the value\n */\nexport const Selector = <TInput, TReturn>(\n value: SkiaValue<TInput>,\n selector: (v: TInput) => TReturn\n): SkiaSelector<TReturn, TInput> => {\n return {\n selector,\n value,\n };\n};\n"],"mappings":"AAOA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMA,QAAQ,GAAG,CACtBC,KADsB,EAEtBC,QAFsB,KAGY;EAClC,OAAO;IACLA,QADK;IAELD;EAFK,CAAP;AAID,CARM"}
@@ -1 +1 @@
1
- {"version":3,"sources":[],"names":[],"mappings":"","sourcesContent":[]}
1
+ {"version":3,"names":[],"sources":["types.ts"],"sourcesContent":["export interface SkiaValue<T = number> {\n /**\n * Gets the value hold by the Value object\n */\n readonly current: T;\n /**\n * Adds a listener that is called when value changes.\n * Returns unsubscribe method.\n */\n addListener: (cb: (value: T) => void) => () => void;\n /**\n * Invalidates the value. Has different meaning depending on the type of the value.\n */\n __invalidate: () => void;\n /**\n * Field to make typechecking easier\n */\n __typename__: \"RNSkValue\";\n}\n\nexport interface SkiaMutableValue<T = number> extends SkiaValue<T> {\n /**\n * Get/sets the value hold by the Value object\n */\n current: T;\n /**\n * Get/sets the animation controlling the value\n * */\n animation: SkiaAnimation | undefined;\n}\n\nexport interface SkiaClockValue extends SkiaValue<number> {\n start: () => void;\n stop: () => void;\n}\n\nexport interface SkiaAnimation extends SkiaClockValue {\n cancel: () => void;\n}\n\nexport interface AnimationState {\n current: number;\n finished: boolean;\n}\n\nexport interface ISkiaValueApi {\n /**\n * Creates a new value that holds the initial value and that\n * can be changed.\n */\n createValue: <T>(initialValue: T) => SkiaMutableValue<T>;\n /**\n * Creates a computed value. This is a calculated value that returns the result of\n * a function that is called with the values of the dependencies.\n */\n createComputedValue: <R>(\n cb: () => R,\n values: Array<SkiaValue<unknown>>\n ) => SkiaValue<R>;\n /**\n * Creates a clock value where the value is the number of milliseconds elapsed\n * since the clock was created\n */\n createClockValue: () => SkiaClockValue;\n /**\n * Creates an animation that is driven from a clock and updated every frame.\n * @param cb Callback to calculate next value from time.\n * @returns An animation object that can control a value.\n */\n createAnimation: <S extends AnimationState = AnimationState>(\n cb: (t: number, state: S | undefined) => S\n ) => SkiaAnimation;\n}\n"],"mappings":""}
@@ -17,7 +17,7 @@ export class RNSkAnimation extends RNSkClockValue {
17
17
  }
18
18
 
19
19
  update(nextValue) {
20
- var _this$_animationState2, _this$_animationState3;
20
+ var _this$_animationState2;
21
21
 
22
22
  if (this._callback) {
23
23
  var _this$_animationState;
@@ -29,7 +29,7 @@ export class RNSkAnimation extends RNSkClockValue {
29
29
  }
30
30
  }
31
31
 
32
- super.update((_this$_animationState2 = (_this$_animationState3 = this._animationState) === null || _this$_animationState3 === void 0 ? void 0 : _this$_animationState3.current) !== null && _this$_animationState2 !== void 0 ? _this$_animationState2 : nextValue);
32
+ super.update(((_this$_animationState2 = this._animationState) === null || _this$_animationState2 === void 0 ? void 0 : _this$_animationState2.current) ?? nextValue);
33
33
  }
34
34
 
35
35
  }
@@ -1 +1 @@
1
- {"version":3,"sources":["RNSkAnimation.ts"],"names":["RNSkClockValue","RNSkAnimation","constructor","callback","raf","undefined","_callback","cancel","stop","update","nextValue","_animationState","finished","current"],"mappings":";;AAEA,SAASA,cAAT,QAA+B,kBAA/B;AAEA,OAAO,MAAMC,aAAN,SACGD,cADH,CAGP;AACEE,EAAAA,WAAW,CACTC,QADS,EAETC,GAFS,EAGT;AACA,UAAMA,GAAN;;AADA;;AAAA,6CAMuCC,SANvC;;AAEA,SAAKC,SAAL,GAAiBH,QAAjB;AACD;;AAKMI,EAAAA,MAAM,GAAG;AACd,SAAKC,IAAL;AACD;;AAESC,EAAAA,MAAM,CAACC,SAAD,EAA0B;AAAA;;AACxC,QAAI,KAAKJ,SAAT,EAAoB;AAAA;;AAClB,WAAKK,eAAL,GAAuB,KAAKL,SAAL,CAAeI,SAAf,EAA0B,KAAKC,eAA/B,CAAvB;;AACA,mCAAI,KAAKA,eAAT,kDAAI,sBAAsBC,QAA1B,EAAoC;AAClC,aAAKJ,IAAL;AACD;AACF;;AACD,UAAMC,MAAN,qDAAa,KAAKE,eAAlB,2DAAa,uBAAsBE,OAAnC,2EAA8CH,SAA9C;AACD;;AAxBH","sourcesContent":["import type { AnimationState, SkiaAnimation } from \"../types\";\n\nimport { RNSkClockValue } from \"./RNSkClockValue\";\n\nexport class RNSkAnimation<S extends AnimationState = AnimationState>\n extends RNSkClockValue\n implements SkiaAnimation\n{\n constructor(\n callback: (t: number, state: S | undefined) => S,\n raf: (callback: (time: number) => void) => number\n ) {\n super(raf);\n this._callback = callback;\n }\n\n private _callback: (t: number, state: S | undefined) => S;\n private _animationState: S | undefined = undefined;\n\n public cancel() {\n this.stop();\n }\n\n protected update(nextValue: number): void {\n if (this._callback) {\n this._animationState = this._callback(nextValue, this._animationState);\n if (this._animationState?.finished) {\n this.stop();\n }\n }\n super.update(this._animationState?.current ?? nextValue);\n }\n}\n"]}
1
+ {"version":3,"names":["RNSkClockValue","RNSkAnimation","constructor","callback","raf","undefined","_callback","cancel","stop","update","nextValue","_animationState","finished","current"],"sources":["RNSkAnimation.ts"],"sourcesContent":["import type { AnimationState, SkiaAnimation } from \"../types\";\n\nimport { RNSkClockValue } from \"./RNSkClockValue\";\n\nexport class RNSkAnimation<S extends AnimationState = AnimationState>\n extends RNSkClockValue\n implements SkiaAnimation\n{\n constructor(\n callback: (t: number, state: S | undefined) => S,\n raf: (callback: (time: number) => void) => number\n ) {\n super(raf);\n this._callback = callback;\n }\n\n private _callback: (t: number, state: S | undefined) => S;\n private _animationState: S | undefined = undefined;\n\n public cancel() {\n this.stop();\n }\n\n protected update(nextValue: number): void {\n if (this._callback) {\n this._animationState = this._callback(nextValue, this._animationState);\n if (this._animationState?.finished) {\n this.stop();\n }\n }\n super.update(this._animationState?.current ?? nextValue);\n }\n}\n"],"mappings":";;AAEA,SAASA,cAAT,QAA+B,kBAA/B;AAEA,OAAO,MAAMC,aAAN,SACGD,cADH,CAGP;EACEE,WAAW,CACTC,QADS,EAETC,GAFS,EAGT;IACA,MAAMA,GAAN;;IADA;;IAAA,yCAMuCC,SANvC;;IAEA,KAAKC,SAAL,GAAiBH,QAAjB;EACD;;EAKMI,MAAM,GAAG;IACd,KAAKC,IAAL;EACD;;EAESC,MAAM,CAACC,SAAD,EAA0B;IAAA;;IACxC,IAAI,KAAKJ,SAAT,EAAoB;MAAA;;MAClB,KAAKK,eAAL,GAAuB,KAAKL,SAAL,CAAeI,SAAf,EAA0B,KAAKC,eAA/B,CAAvB;;MACA,6BAAI,KAAKA,eAAT,kDAAI,sBAAsBC,QAA1B,EAAoC;QAClC,KAAKJ,IAAL;MACD;IACF;;IACD,MAAMC,MAAN,CAAa,gCAAKE,eAAL,kFAAsBE,OAAtB,KAAiCH,SAA9C;EACD;;AAxBH"}
@@ -1 +1 @@
1
- {"version":3,"sources":["RNSkClockValue.ts"],"names":["RNSkReadonlyValue","RNSkClockState","RNSkClockValue","constructor","raf","NotStarted","_","_state","Running","now","Date","deltaFromStart","_start","tick","_raf","notifyUpdate","update","value","start","_stop","timeSinceStop","stop","Stopped"],"mappings":";;AAEA,SAASA,iBAAT,QAAkC,qBAAlC;IAEKC,c;;WAAAA,c;AAAAA,EAAAA,c,CAAAA,c;AAAAA,EAAAA,c,CAAAA,c;AAAAA,EAAAA,c,CAAAA,c;GAAAA,c,KAAAA,c;;AAML,OAAO,MAAMC,cAAN,SACGF,iBADH,CAGP;AACEG,EAAAA,WAAW,CAACC,GAAD,EAAoD;AAC7D,UAAM,CAAN;;AAD6D;;AAAA;;AAAA;;AAAA,oCAS9BH,cAAc,CAACI,UATe;;AAAA,0CAWvCC,CAAD,IAAe;AACpC,UAAI,KAAKC,MAAL,KAAgBN,cAAc,CAACO,OAAnC,EAA4C;AAC1C,cAAMC,GAAG,GAAGC,IAAI,CAACD,GAAL,EAAZ;AACA,cAAME,cAAc,GAAGF,GAAG,GAAG,KAAKG,MAAlC;AACA,aAAKC,IAAL,CAAUF,cAAV;;AACA,aAAKG,IAAL,CAAU,KAAKC,YAAf;AACD;AACF,KAlB8D;;AAE7D,SAAKD,IAAL,GAAYV,GAAZ;AACA,SAAKY,MAAL,CAAY,CAAZ;AACD;;AAgBSH,EAAAA,IAAI,CAACI,KAAD,EAAgB;AAC5B,SAAKD,MAAL,CAAYC,KAAZ;AACD;;AAEMC,EAAAA,KAAK,GAAG;AACb,QAAI,KAAKX,MAAL,KAAgBN,cAAc,CAACI,UAAnC,EAA+C;AAC7C,WAAKO,MAAL,GAAcF,IAAI,CAACD,GAAL,EAAd;AACA,WAAKU,KAAL,GAAa,KAAKP,MAAlB;AACD,KAJY,CAKb;;;AACA,UAAMQ,aAAa,GAAGV,IAAI,CAACD,GAAL,KAAa,KAAKU,KAAxC;;AACA,SAAKP,MAAL,IAAgBQ,aAAhB;AAEA,SAAKb,MAAL,GAAcN,cAAc,CAACO,OAA7B;;AACA,SAAKM,IAAL,CAAU,KAAKC,YAAf;AACD;;AAEMM,EAAAA,IAAI,GAAG;AACZ,QAAI,KAAKd,MAAL,KAAgBN,cAAc,CAACO,OAAnC,EAA4C;AAC1C,WAAKD,MAAL,GAAcN,cAAc,CAACqB,OAA7B;AACA,WAAKH,KAAL,GAAaT,IAAI,CAACD,GAAL,EAAb;AACD;AACF;;AA3CH","sourcesContent":["import type { SkiaClockValue } from \"../types\";\n\nimport { RNSkReadonlyValue } from \"./RNSkReadonlyValue\";\n\nenum RNSkClockState {\n NotStarted = 0,\n Running = 1,\n Stopped = 2,\n}\n\nexport class RNSkClockValue\n extends RNSkReadonlyValue<number>\n implements SkiaClockValue\n{\n constructor(raf: (callback: (time: number) => void) => number) {\n super(0);\n this._raf = raf;\n this.update(0);\n }\n\n private _raf: (callback: (time: number) => void) => number;\n private _start: number | undefined;\n private _stop: number | undefined;\n private _state: RNSkClockState = RNSkClockState.NotStarted;\n\n private notifyUpdate = (_: number) => {\n if (this._state === RNSkClockState.Running) {\n const now = Date.now();\n const deltaFromStart = now - this._start!;\n this.tick(deltaFromStart);\n this._raf(this.notifyUpdate);\n }\n };\n\n protected tick(value: number) {\n this.update(value);\n }\n\n public start() {\n if (this._state === RNSkClockState.NotStarted) {\n this._start = Date.now();\n this._stop = this._start;\n }\n // Subtract pause time from start\n const timeSinceStop = Date.now() - this._stop!;\n this._start! += timeSinceStop;\n\n this._state = RNSkClockState.Running;\n this._raf(this.notifyUpdate);\n }\n\n public stop() {\n if (this._state === RNSkClockState.Running) {\n this._state = RNSkClockState.Stopped;\n this._stop = Date.now();\n }\n }\n}\n"]}
1
+ {"version":3,"names":["RNSkReadonlyValue","RNSkClockState","RNSkClockValue","constructor","raf","NotStarted","_","_state","Running","now","Date","deltaFromStart","_start","tick","_raf","notifyUpdate","update","value","start","_stop","timeSinceStop","stop","Stopped"],"sources":["RNSkClockValue.ts"],"sourcesContent":["import type { SkiaClockValue } from \"../types\";\n\nimport { RNSkReadonlyValue } from \"./RNSkReadonlyValue\";\n\nenum RNSkClockState {\n NotStarted = 0,\n Running = 1,\n Stopped = 2,\n}\n\nexport class RNSkClockValue\n extends RNSkReadonlyValue<number>\n implements SkiaClockValue\n{\n constructor(raf: (callback: (time: number) => void) => number) {\n super(0);\n this._raf = raf;\n this.update(0);\n }\n\n private _raf: (callback: (time: number) => void) => number;\n private _start: number | undefined;\n private _stop: number | undefined;\n private _state: RNSkClockState = RNSkClockState.NotStarted;\n\n private notifyUpdate = (_: number) => {\n if (this._state === RNSkClockState.Running) {\n const now = Date.now();\n const deltaFromStart = now - this._start!;\n this.tick(deltaFromStart);\n this._raf(this.notifyUpdate);\n }\n };\n\n protected tick(value: number) {\n this.update(value);\n }\n\n public start() {\n if (this._state === RNSkClockState.NotStarted) {\n this._start = Date.now();\n this._stop = this._start;\n }\n // Subtract pause time from start\n const timeSinceStop = Date.now() - this._stop!;\n this._start! += timeSinceStop;\n\n this._state = RNSkClockState.Running;\n this._raf(this.notifyUpdate);\n }\n\n public stop() {\n if (this._state === RNSkClockState.Running) {\n this._state = RNSkClockState.Stopped;\n this._stop = Date.now();\n }\n }\n}\n"],"mappings":";;AAEA,SAASA,iBAAT,QAAkC,qBAAlC;IAEKC,c;;WAAAA,c;EAAAA,c,CAAAA,c;EAAAA,c,CAAAA,c;EAAAA,c,CAAAA,c;GAAAA,c,KAAAA,c;;AAML,OAAO,MAAMC,cAAN,SACGF,iBADH,CAGP;EACEG,WAAW,CAACC,GAAD,EAAoD;IAC7D,MAAM,CAAN;;IAD6D;;IAAA;;IAAA;;IAAA,gCAS9BH,cAAc,CAACI,UATe;;IAAA,sCAWvCC,CAAD,IAAe;MACpC,IAAI,KAAKC,MAAL,KAAgBN,cAAc,CAACO,OAAnC,EAA4C;QAC1C,MAAMC,GAAG,GAAGC,IAAI,CAACD,GAAL,EAAZ;QACA,MAAME,cAAc,GAAGF,GAAG,GAAG,KAAKG,MAAlC;QACA,KAAKC,IAAL,CAAUF,cAAV;;QACA,KAAKG,IAAL,CAAU,KAAKC,YAAf;MACD;IACF,CAlB8D;;IAE7D,KAAKD,IAAL,GAAYV,GAAZ;IACA,KAAKY,MAAL,CAAY,CAAZ;EACD;;EAgBSH,IAAI,CAACI,KAAD,EAAgB;IAC5B,KAAKD,MAAL,CAAYC,KAAZ;EACD;;EAEMC,KAAK,GAAG;IACb,IAAI,KAAKX,MAAL,KAAgBN,cAAc,CAACI,UAAnC,EAA+C;MAC7C,KAAKO,MAAL,GAAcF,IAAI,CAACD,GAAL,EAAd;MACA,KAAKU,KAAL,GAAa,KAAKP,MAAlB;IACD,CAJY,CAKb;;;IACA,MAAMQ,aAAa,GAAGV,IAAI,CAACD,GAAL,KAAa,KAAKU,KAAxC;;IACA,KAAKP,MAAL,IAAgBQ,aAAhB;IAEA,KAAKb,MAAL,GAAcN,cAAc,CAACO,OAA7B;;IACA,KAAKM,IAAL,CAAU,KAAKC,YAAf;EACD;;EAEMM,IAAI,GAAG;IACZ,IAAI,KAAKd,MAAL,KAAgBN,cAAc,CAACO,OAAnC,EAA4C;MAC1C,KAAKD,MAAL,GAAcN,cAAc,CAACqB,OAA7B;MACA,KAAKH,KAAL,GAAaT,IAAI,CAACD,GAAL,EAAb;IACD;EACF;;AA3CH"}
@@ -10,7 +10,7 @@ export class RNSkComputedValue extends RNSkReadonlyValue {
10
10
  current: undefined
11
11
  };
12
12
  dependencies.forEach(dep => {
13
- if ("__typename__" in dep && "addListener" in dep) {
13
+ if (dep && typeof dep === "object" && "__typename__" in dep && "addListener" in dep) {
14
14
  unsubscribers.push(dep.addListener(() => {
15
15
  var _notifyUpdateRef$curr;
16
16
 
@@ -1 +1 @@
1
- {"version":3,"sources":["RNSkComputedValue.ts"],"names":["RNSkReadonlyValue","RNSkComputedValue","constructor","callback","dependencies","unsubscribers","notifyUpdateRef","current","undefined","forEach","dep","push","addListener","_unsubscribers","dependecyUpdated","bind","_callback","update","unsubscribe","__invalidate"],"mappings":";;AAEA,SAASA,iBAAT,QAAkC,qBAAlC;AAEA,OAAO,MAAMC,iBAAN,SAAmCD,iBAAnC,CAAwD;AAC7DE,EAAAA,WAAW,CAACC,QAAD,EAAoBC,YAApB,EAAkD;AAC3D;AACA;AACA,UAAMC,aAAgC,GAAG,EAAzC;AACA,UAAMC,eAAsD,GAAG;AAC7DC,MAAAA,OAAO,EAAEC;AADoD,KAA/D;AAGAJ,IAAAA,YAAY,CAACK,OAAb,CAAsBC,GAAD,IAAS;AAC5B,UAAI,kBAAkBA,GAAlB,IAAyB,iBAAiBA,GAA9C,EAAmD;AACjDL,QAAAA,aAAa,CAACM,IAAd,CACGD,GAAD,CAAoCE,WAApC,CAAgD;AAAA;;AAAA,0CAC9CN,eAAe,CAACC,OAD8B,0DAC9C,2BAAAD,eAAe,CAD+B;AAAA,SAAhD,CADF;AAKD;AACF,KARD;AASA,UAAMH,QAAQ,EAAd;;AAhB2D;;AAAA;;AAiB3D,SAAKU,cAAL,GAAsBR,aAAtB;AACAC,IAAAA,eAAe,CAACC,OAAhB,GAA0B,KAAKO,gBAAL,CAAsBC,IAAtB,CAA2B,IAA3B,CAA1B;AACA,SAAKC,SAAL,GAAiBb,QAAjB;AACD;;AAEOW,EAAAA,gBAAgB,GAAG;AACzB,SAAKG,MAAL,CAAY,KAAKD,SAAL,EAAZ;AACD;;AAKME,EAAAA,WAAW,GAAG;AACnB,SAAKL,cAAL,CAAoBJ,OAApB,CAA6BS,WAAD,IAAiBA,WAAW,EAAxD;;AACA,SAAKL,cAAL,GAAsB,EAAtB;AACD;;AAEMM,EAAAA,YAAY,GAAS;AAC1B,SAAKN,cAAL,CAAoBJ,OAApB,CAA6BS,WAAD,IAAiBA,WAAW,EAAxD;;AACA,SAAKL,cAAL,GAAsB,EAAtB;AACD;;AAtC4D","sourcesContent":["import type { DependencyList } from \"react\";\n\nimport { RNSkReadonlyValue } from \"./RNSkReadonlyValue\";\n\nexport class RNSkComputedValue<T> extends RNSkReadonlyValue<T> {\n constructor(callback: () => T, dependencies: DependencyList) {\n // Initialize dependencies - we can't call this yet, since\n // super if not called and it requires a start value to be set.\n const unsubscribers: Array<() => void> = [];\n const notifyUpdateRef: { current: (() => void) | undefined } = {\n current: undefined,\n };\n dependencies.forEach((dep) => {\n if (\"__typename__\" in dep && \"addListener\" in dep) {\n unsubscribers.push(\n (dep as RNSkReadonlyValue<unknown>).addListener(() =>\n notifyUpdateRef.current?.()\n )\n );\n }\n });\n super(callback());\n this._unsubscribers = unsubscribers;\n notifyUpdateRef.current = this.dependecyUpdated.bind(this);\n this._callback = callback;\n }\n\n private dependecyUpdated() {\n this.update(this._callback());\n }\n\n private _callback: () => T;\n private _unsubscribers: Array<() => void>;\n\n public unsubscribe() {\n this._unsubscribers.forEach((unsubscribe) => unsubscribe());\n this._unsubscribers = [];\n }\n\n public __invalidate(): void {\n this._unsubscribers.forEach((unsubscribe) => unsubscribe());\n this._unsubscribers = [];\n }\n}\n"]}
1
+ {"version":3,"names":["RNSkReadonlyValue","RNSkComputedValue","constructor","callback","dependencies","unsubscribers","notifyUpdateRef","current","undefined","forEach","dep","push","addListener","_unsubscribers","dependecyUpdated","bind","_callback","update","unsubscribe","__invalidate"],"sources":["RNSkComputedValue.ts"],"sourcesContent":["import type { DependencyList } from \"react\";\n\nimport { RNSkReadonlyValue } from \"./RNSkReadonlyValue\";\n\nexport class RNSkComputedValue<T> extends RNSkReadonlyValue<T> {\n constructor(callback: () => T, dependencies: DependencyList) {\n // Initialize dependencies - we can't call this yet, since\n // super if not called and it requires a start value to be set.\n const unsubscribers: Array<() => void> = [];\n const notifyUpdateRef: { current: (() => void) | undefined } = {\n current: undefined,\n };\n dependencies.forEach((dep) => {\n if (\n dep &&\n typeof dep === \"object\" &&\n \"__typename__\" in dep &&\n \"addListener\" in dep\n ) {\n unsubscribers.push(\n (dep as RNSkReadonlyValue<unknown>).addListener(() =>\n notifyUpdateRef.current?.()\n )\n );\n }\n });\n super(callback());\n this._unsubscribers = unsubscribers;\n notifyUpdateRef.current = this.dependecyUpdated.bind(this);\n this._callback = callback;\n }\n\n private dependecyUpdated() {\n this.update(this._callback());\n }\n\n private _callback: () => T;\n private _unsubscribers: Array<() => void>;\n\n public unsubscribe() {\n this._unsubscribers.forEach((unsubscribe) => unsubscribe());\n this._unsubscribers = [];\n }\n\n public __invalidate(): void {\n this._unsubscribers.forEach((unsubscribe) => unsubscribe());\n this._unsubscribers = [];\n }\n}\n"],"mappings":";;AAEA,SAASA,iBAAT,QAAkC,qBAAlC;AAEA,OAAO,MAAMC,iBAAN,SAAmCD,iBAAnC,CAAwD;EAC7DE,WAAW,CAACC,QAAD,EAAoBC,YAApB,EAAkD;IAC3D;IACA;IACA,MAAMC,aAAgC,GAAG,EAAzC;IACA,MAAMC,eAAsD,GAAG;MAC7DC,OAAO,EAAEC;IADoD,CAA/D;IAGAJ,YAAY,CAACK,OAAb,CAAsBC,GAAD,IAAS;MAC5B,IACEA,GAAG,IACH,OAAOA,GAAP,KAAe,QADf,IAEA,kBAAkBA,GAFlB,IAGA,iBAAiBA,GAJnB,EAKE;QACAL,aAAa,CAACM,IAAd,CACGD,GAAD,CAAoCE,WAApC,CAAgD;UAAA;;UAAA,gCAC9CN,eAAe,CAACC,OAD8B,0DAC9C,2BAAAD,eAAe,CAD+B;QAAA,CAAhD,CADF;MAKD;IACF,CAbD;IAcA,MAAMH,QAAQ,EAAd;;IArB2D;;IAAA;;IAsB3D,KAAKU,cAAL,GAAsBR,aAAtB;IACAC,eAAe,CAACC,OAAhB,GAA0B,KAAKO,gBAAL,CAAsBC,IAAtB,CAA2B,IAA3B,CAA1B;IACA,KAAKC,SAAL,GAAiBb,QAAjB;EACD;;EAEOW,gBAAgB,GAAG;IACzB,KAAKG,MAAL,CAAY,KAAKD,SAAL,EAAZ;EACD;;EAKME,WAAW,GAAG;IACnB,KAAKL,cAAL,CAAoBJ,OAApB,CAA6BS,WAAD,IAAiBA,WAAW,EAAxD;;IACA,KAAKL,cAAL,GAAsB,EAAtB;EACD;;EAEMM,YAAY,GAAS;IAC1B,KAAKN,cAAL,CAAoBJ,OAApB,CAA6BS,WAAD,IAAiBA,WAAW,EAAxD;;IACA,KAAKL,cAAL,GAAsB,EAAtB;EACD;;AA3C4D"}
@@ -1 +1 @@
1
- {"version":3,"sources":["RNSkReadonlyValue.ts"],"names":["RNSkReadonlyValue","constructor","value","_current","notifyListeners","_listeners","forEach","cb","update","nextValue","current","addListener","push","splice","indexOf","__invalidate"],"mappings":";;AAEA,OAAO,MAAMA,iBAAN,CAAmD;AACxDC,EAAAA,WAAW,CAACC,KAAD,EAAW;AAAA;;AAAA,wCAK0B,EAL1B;;AAAA,0CAgBS,WAhBT;;AACpB,SAAKC,QAAL,GAAgBD,KAAhB;AACD;;AAKOE,EAAAA,eAAe,GAAS;AAC9B,SAAKC,UAAL,CAAgBC,OAAhB,CAAyBC,EAAD,IAAQA,EAAE,CAAC,KAAKJ,QAAN,CAAlC;AACD;;AAESK,EAAAA,MAAM,CAACC,SAAD,EAAqB;AACnC,SAAKN,QAAL,GAAgBM,SAAhB;AACA,SAAKL,eAAL;AACD;;AAIiB,MAAPM,OAAO,GAAM;AACtB,WAAO,KAAKP,QAAZ;AACD;;AAEMQ,EAAAA,WAAW,CAACJ,EAAD,EAAyB;AACzC,SAAKF,UAAL,CAAgBO,IAAhB,CAAqBL,EAArB;;AACA,WAAO,MAAM;AACX,WAAKF,UAAL,CAAgBQ,MAAhB,CAAuB,KAAKR,UAAL,CAAgBS,OAAhB,CAAwBP,EAAxB,CAAvB,EAAoD,CAApD;AACD,KAFD;AAGD;;AAEMQ,EAAAA,YAAY,GAAS;AAC1B,SAAKV,UAAL,GAAkB,EAAlB;AACD;;AAhCuD","sourcesContent":["import type { SkiaValue } from \"../types\";\n\nexport class RNSkReadonlyValue<T> implements SkiaValue<T> {\n constructor(value: T) {\n this._current = value;\n }\n\n private _current: T;\n private _listeners: Array<(value: T) => void> = [];\n\n private notifyListeners(): void {\n this._listeners.forEach((cb) => cb(this._current));\n }\n\n protected update(nextValue: T): void {\n this._current = nextValue;\n this.notifyListeners();\n }\n\n public readonly __typename__ = \"RNSkValue\";\n\n public get current(): T {\n return this._current;\n }\n\n public addListener(cb: (value: T) => void) {\n this._listeners.push(cb);\n return () => {\n this._listeners.splice(this._listeners.indexOf(cb), 1);\n };\n }\n\n public __invalidate(): void {\n this._listeners = [];\n }\n}\n"]}
1
+ {"version":3,"names":["RNSkReadonlyValue","constructor","value","_current","notifyListeners","_listeners","forEach","cb","update","nextValue","current","addListener","push","splice","indexOf","__invalidate"],"sources":["RNSkReadonlyValue.ts"],"sourcesContent":["import type { SkiaValue } from \"../types\";\n\nexport class RNSkReadonlyValue<T> implements SkiaValue<T> {\n constructor(value: T) {\n this._current = value;\n }\n\n private _current: T;\n private _listeners: Array<(value: T) => void> = [];\n\n private notifyListeners(): void {\n this._listeners.forEach((cb) => cb(this._current));\n }\n\n protected update(nextValue: T): void {\n this._current = nextValue;\n this.notifyListeners();\n }\n\n public readonly __typename__ = \"RNSkValue\";\n\n public get current(): T {\n return this._current;\n }\n\n public addListener(cb: (value: T) => void) {\n this._listeners.push(cb);\n return () => {\n this._listeners.splice(this._listeners.indexOf(cb), 1);\n };\n }\n\n public __invalidate(): void {\n this._listeners = [];\n }\n}\n"],"mappings":";;AAEA,OAAO,MAAMA,iBAAN,CAAmD;EACxDC,WAAW,CAACC,KAAD,EAAW;IAAA;;IAAA,oCAK0B,EAL1B;;IAAA,sCAgBS,WAhBT;;IACpB,KAAKC,QAAL,GAAgBD,KAAhB;EACD;;EAKOE,eAAe,GAAS;IAC9B,KAAKC,UAAL,CAAgBC,OAAhB,CAAyBC,EAAD,IAAQA,EAAE,CAAC,KAAKJ,QAAN,CAAlC;EACD;;EAESK,MAAM,CAACC,SAAD,EAAqB;IACnC,KAAKN,QAAL,GAAgBM,SAAhB;IACA,KAAKL,eAAL;EACD;;EAIiB,IAAPM,OAAO,GAAM;IACtB,OAAO,KAAKP,QAAZ;EACD;;EAEMQ,WAAW,CAACJ,EAAD,EAAyB;IACzC,KAAKF,UAAL,CAAgBO,IAAhB,CAAqBL,EAArB;;IACA,OAAO,MAAM;MACX,KAAKF,UAAL,CAAgBQ,MAAhB,CAAuB,KAAKR,UAAL,CAAgBS,OAAhB,CAAwBP,EAAxB,CAAvB,EAAoD,CAApD;IACD,CAFD;EAGD;;EAEMQ,YAAY,GAAS;IAC1B,KAAKV,UAAL,GAAkB,EAAlB;EACD;;AAhCuD"}
@@ -1 +1 @@
1
- {"version":3,"sources":["RNSkValue.ts"],"names":["RNSkReadonlyValue","RNSkValue","constructor","value","_unsubscribe","undefined","current","update","unsubscribe","_animation","cancel","subscribe","animation","addListener","animationDidUpdate","bind","start","v"],"mappings":";;AAEA,SAASA,iBAAT,QAAkC,qBAAlC;AAEA,OAAO,MAAMC,SAAN,SAA2BD,iBAA3B,CAAwE;AAC7EE,EAAAA,WAAW,CAACC,KAAD,EAAW;AACpB,UAAMA,KAAN;;AADoB;;AAAA;;AAEpB,SAAKC,YAAL,GAAoBC,SAApB;AACD;;AAEiB,MAAPC,OAAO,CAACH,KAAD,EAAW;AAC3B,SAAKI,MAAL,CAAYJ,KAAZ;AACD;;AAEiB,MAAPG,OAAO,GAAM;AACtB,WAAO,MAAMA,OAAb;AACD;;AAIOE,EAAAA,WAAW,GAAG;AACpB,QAAI,KAAKJ,YAAT,EAAuB;AACrB,WAAKA,YAAL;;AACA,WAAKA,YAAL,GAAoBC,SAApB;AACD;;AACD,QAAI,KAAKI,UAAT,EAAqB;AACnB,WAAKA,UAAL,CAAgBC,MAAhB;;AACA,WAAKD,UAAL,GAAkBJ,SAAlB;AACD;AACF;;AAEOM,EAAAA,SAAS,CAACC,SAAD,EAAuC;AACtD,SAAKJ,WAAL;;AACA,QAAII,SAAJ,EAAe;AACb,WAAKH,UAAL,GAAkBG,SAAlB;AACA,WAAKR,YAAL,GAAoBQ,SAAS,CAACC,WAAV,EAClB;AACA;AACA,WAAKC,kBAAL,CAAwBC,IAAxB,CAA6B,IAA7B,CAHkB,CAApB;;AAKA,WAAKN,UAAL,CAAgBO,KAAhB;AACD;AACF;;AAEOF,EAAAA,kBAAkB,CAACX,KAAD,EAAW;AACnC,SAAKI,MAAL,CAAYJ,KAAZ;AACD;;AAGmB,MAATS,SAAS,GAA8B;AAChD,WAAO,KAAKH,UAAZ;AACD;;AAEmB,MAATG,SAAS,CAACK,CAAD,EAA+B;AACjD,SAAKN,SAAL,CAAeM,CAAf;AACD;;AAnD4E","sourcesContent":["import type { SkiaAnimation, SkiaValue } from \"../types\";\n\nimport { RNSkReadonlyValue } from \"./RNSkReadonlyValue\";\n\nexport class RNSkValue<T> extends RNSkReadonlyValue<T> implements SkiaValue<T> {\n constructor(value: T) {\n super(value);\n this._unsubscribe = undefined;\n }\n\n public set current(value: T) {\n this.update(value);\n }\n\n public get current(): T {\n return super.current;\n }\n\n private _unsubscribe: (() => void) | undefined;\n\n private unsubscribe() {\n if (this._unsubscribe) {\n this._unsubscribe();\n this._unsubscribe = undefined;\n }\n if (this._animation) {\n this._animation.cancel();\n this._animation = undefined;\n }\n }\n\n private subscribe(animation: SkiaAnimation | undefined) {\n this.unsubscribe();\n if (animation) {\n this._animation = animation;\n this._unsubscribe = animation.addListener(\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this.animationDidUpdate.bind(this)\n );\n this._animation.start();\n }\n }\n\n private animationDidUpdate(value: T) {\n this.update(value);\n }\n\n private _animation: SkiaAnimation | undefined;\n public get animation(): SkiaAnimation | undefined {\n return this._animation;\n }\n\n public set animation(v: SkiaAnimation | undefined) {\n this.subscribe(v);\n }\n}\n"]}
1
+ {"version":3,"names":["RNSkReadonlyValue","RNSkValue","constructor","value","_unsubscribe","undefined","current","update","unsubscribe","_animation","cancel","subscribe","animation","addListener","animationDidUpdate","bind","start","v"],"sources":["RNSkValue.ts"],"sourcesContent":["import type { SkiaAnimation, SkiaValue } from \"../types\";\n\nimport { RNSkReadonlyValue } from \"./RNSkReadonlyValue\";\n\nexport class RNSkValue<T> extends RNSkReadonlyValue<T> implements SkiaValue<T> {\n constructor(value: T) {\n super(value);\n this._unsubscribe = undefined;\n }\n\n public set current(value: T) {\n this.update(value);\n }\n\n public get current(): T {\n return super.current;\n }\n\n private _unsubscribe: (() => void) | undefined;\n\n private unsubscribe() {\n if (this._unsubscribe) {\n this._unsubscribe();\n this._unsubscribe = undefined;\n }\n if (this._animation) {\n this._animation.cancel();\n this._animation = undefined;\n }\n }\n\n private subscribe(animation: SkiaAnimation | undefined) {\n this.unsubscribe();\n if (animation) {\n this._animation = animation;\n this._unsubscribe = animation.addListener(\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-ignore\n this.animationDidUpdate.bind(this)\n );\n this._animation.start();\n }\n }\n\n private animationDidUpdate(value: T) {\n this.update(value);\n }\n\n private _animation: SkiaAnimation | undefined;\n public get animation(): SkiaAnimation | undefined {\n return this._animation;\n }\n\n public set animation(v: SkiaAnimation | undefined) {\n this.subscribe(v);\n }\n}\n"],"mappings":";;AAEA,SAASA,iBAAT,QAAkC,qBAAlC;AAEA,OAAO,MAAMC,SAAN,SAA2BD,iBAA3B,CAAwE;EAC7EE,WAAW,CAACC,KAAD,EAAW;IACpB,MAAMA,KAAN;;IADoB;;IAAA;;IAEpB,KAAKC,YAAL,GAAoBC,SAApB;EACD;;EAEiB,IAAPC,OAAO,CAACH,KAAD,EAAW;IAC3B,KAAKI,MAAL,CAAYJ,KAAZ;EACD;;EAEiB,IAAPG,OAAO,GAAM;IACtB,OAAO,MAAMA,OAAb;EACD;;EAIOE,WAAW,GAAG;IACpB,IAAI,KAAKJ,YAAT,EAAuB;MACrB,KAAKA,YAAL;;MACA,KAAKA,YAAL,GAAoBC,SAApB;IACD;;IACD,IAAI,KAAKI,UAAT,EAAqB;MACnB,KAAKA,UAAL,CAAgBC,MAAhB;;MACA,KAAKD,UAAL,GAAkBJ,SAAlB;IACD;EACF;;EAEOM,SAAS,CAACC,SAAD,EAAuC;IACtD,KAAKJ,WAAL;;IACA,IAAII,SAAJ,EAAe;MACb,KAAKH,UAAL,GAAkBG,SAAlB;MACA,KAAKR,YAAL,GAAoBQ,SAAS,CAACC,WAAV,EAClB;MACA;MACA,KAAKC,kBAAL,CAAwBC,IAAxB,CAA6B,IAA7B,CAHkB,CAApB;;MAKA,KAAKN,UAAL,CAAgBO,KAAhB;IACD;EACF;;EAEOF,kBAAkB,CAACX,KAAD,EAAW;IACnC,KAAKI,MAAL,CAAYJ,KAAZ;EACD;;EAGmB,IAATS,SAAS,GAA8B;IAChD,OAAO,KAAKH,UAAZ;EACD;;EAEmB,IAATG,SAAS,CAACK,CAAD,EAA+B;IACjD,KAAKN,SAAL,CAAeM,CAAf;EACD;;AAnD4E"}
@@ -1 +1 @@
1
- {"version":3,"sources":["api.ts"],"names":["RNSkAnimation","RNSkClockValue","RNSkComputedValue","RNSkValue","ValueApi","createValue","initialValue","createComputedValue","cb","values","createClockValue","requestAnimationFrame","bind","window","createAnimation"],"mappings":"AASA,SAASA,aAAT,QAA8B,iBAA9B;AACA,SAASC,cAAT,QAA+B,kBAA/B;AACA,SAASC,iBAAT,QAAkC,qBAAlC;AACA,SAASC,SAAT,QAA0B,aAA1B;AAEA,OAAO,MAAMC,QAAuB,GAAG;AACrCC,EAAAA,WAAW,EAAE,UAAaC,YAAb,EAAmD;AAC9D,WAAO,IAAIH,SAAJ,CAAcG,YAAd,CAAP;AACD,GAHoC;AAIrCC,EAAAA,mBAAmB,EAAE,UACnBC,EADmB,EAEnBC,MAFmB,EAGL;AACd,WAAO,IAAIP,iBAAJ,CAAsBM,EAAtB,EAA0BC,MAA1B,CAAP;AACD,GAToC;AAUrCC,EAAAA,gBAAgB,EAAE,YAA4B;AAC5C,WAAO,IAAIT,cAAJ,CAAmBU,qBAAqB,CAACC,IAAtB,CAA2BC,MAA3B,CAAnB,CAAP;AACD,GAZoC;AAarCC,EAAAA,eAAe,EAAE,UACfN,EADe,EAEA;AACf,WAAO,IAAIR,aAAJ,CAAkBQ,EAAlB,EAAsBG,qBAAqB,CAACC,IAAtB,CAA2BC,MAA3B,CAAtB,CAAP;AACD;AAjBoC,CAAhC","sourcesContent":["import type {\n ISkiaValueApi,\n SkiaMutableValue,\n SkiaValue,\n SkiaClockValue,\n AnimationState,\n SkiaAnimation,\n} from \"../types\";\n\nimport { RNSkAnimation } from \"./RNSkAnimation\";\nimport { RNSkClockValue } from \"./RNSkClockValue\";\nimport { RNSkComputedValue } from \"./RNSkComputedValue\";\nimport { RNSkValue } from \"./RNSkValue\";\n\nexport const ValueApi: ISkiaValueApi = {\n createValue: function <T>(initialValue: T): SkiaMutableValue<T> {\n return new RNSkValue(initialValue);\n },\n createComputedValue: function <R>(\n cb: () => R,\n values: SkiaValue<unknown>[]\n ): SkiaValue<R> {\n return new RNSkComputedValue(cb, values);\n },\n createClockValue: function (): SkiaClockValue {\n return new RNSkClockValue(requestAnimationFrame.bind(window));\n },\n createAnimation: function <S extends AnimationState = AnimationState>(\n cb: (t: number, state: S | undefined) => S\n ): SkiaAnimation {\n return new RNSkAnimation(cb, requestAnimationFrame.bind(window));\n },\n};\n"]}
1
+ {"version":3,"names":["RNSkAnimation","RNSkClockValue","RNSkComputedValue","RNSkValue","ValueApi","createValue","initialValue","createComputedValue","cb","values","createClockValue","requestAnimationFrame","bind","window","createAnimation"],"sources":["api.ts"],"sourcesContent":["import type {\n ISkiaValueApi,\n SkiaMutableValue,\n SkiaValue,\n SkiaClockValue,\n AnimationState,\n SkiaAnimation,\n} from \"../types\";\n\nimport { RNSkAnimation } from \"./RNSkAnimation\";\nimport { RNSkClockValue } from \"./RNSkClockValue\";\nimport { RNSkComputedValue } from \"./RNSkComputedValue\";\nimport { RNSkValue } from \"./RNSkValue\";\n\nexport const ValueApi: ISkiaValueApi = {\n createValue: function <T>(initialValue: T): SkiaMutableValue<T> {\n return new RNSkValue(initialValue);\n },\n createComputedValue: function <R>(\n cb: () => R,\n values: SkiaValue<unknown>[]\n ): SkiaValue<R> {\n return new RNSkComputedValue(cb, values);\n },\n createClockValue: function (): SkiaClockValue {\n return new RNSkClockValue(requestAnimationFrame.bind(window));\n },\n createAnimation: function <S extends AnimationState = AnimationState>(\n cb: (t: number, state: S | undefined) => S\n ): SkiaAnimation {\n return new RNSkAnimation(cb, requestAnimationFrame.bind(window));\n },\n};\n"],"mappings":"AASA,SAASA,aAAT,QAA8B,iBAA9B;AACA,SAASC,cAAT,QAA+B,kBAA/B;AACA,SAASC,iBAAT,QAAkC,qBAAlC;AACA,SAASC,SAAT,QAA0B,aAA1B;AAEA,OAAO,MAAMC,QAAuB,GAAG;EACrCC,WAAW,EAAE,UAAaC,YAAb,EAAmD;IAC9D,OAAO,IAAIH,SAAJ,CAAcG,YAAd,CAAP;EACD,CAHoC;EAIrCC,mBAAmB,EAAE,UACnBC,EADmB,EAEnBC,MAFmB,EAGL;IACd,OAAO,IAAIP,iBAAJ,CAAsBM,EAAtB,EAA0BC,MAA1B,CAAP;EACD,CAToC;EAUrCC,gBAAgB,EAAE,YAA4B;IAC5C,OAAO,IAAIT,cAAJ,CAAmBU,qBAAqB,CAACC,IAAtB,CAA2BC,MAA3B,CAAnB,CAAP;EACD,CAZoC;EAarCC,eAAe,EAAE,UACfN,EADe,EAEA;IACf,OAAO,IAAIR,aAAJ,CAAkBQ,EAAlB,EAAsBG,qBAAqB,CAACC,IAAtB,CAA2BC,MAA3B,CAAtB,CAAP;EACD;AAjBoC,CAAhC"}
@@ -1 +1 @@
1
- {"version":3,"sources":["index.ts"],"names":[],"mappings":"AAAA,cAAc,OAAd","sourcesContent":["export * from \"./api\";\n"]}
1
+ {"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./api\";\n"],"mappings":"AAAA,cAAc,OAAd"}
@@ -1,4 +1,4 @@
1
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
2
 
3
3
  function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
4
4
 
@@ -1 +1 @@
1
- {"version":3,"sources":["SkiaView.tsx"],"names":["React","requireNativeComponent","SkiaViewApi","SkiaViewNativeId","NativeSkiaView","SkiaView","Component","constructor","props","_nativeId","onDraw","assertSkiaViewApi","setJsiProperty","nativeId","componentDidUpdate","prevProps","makeImageSnapshot","rect","redraw","requestRedraw","registerValues","values","registerValuesInView","render","mode","debug","viewProps","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;AACSW,EAAAA,cAAc,CAACC,MAAD,EAA2C;AAC9DV,IAAAA,iBAAiB;AACjB,WAAOT,WAAW,CAACoB,oBAAZ,CAAiC,KAAKb,SAAtC,EAAiDY,MAAjD,CAAP;AACD;;AAEDE,EAAAA,MAAM,GAAG;AACP,UAAM;AAAEC,MAAAA,IAAF;AAAQC,MAAAA,KAAK,GAAG,KAAhB;AAAuB,SAAGC;AAA1B,QAAwC,KAAKlB,KAAnD;AACA,wBACE,oBAAC,cAAD;AACE,MAAA,WAAW,EAAE,KADf;AAEE,MAAA,QAAQ,EAAG,GAAE,KAAKC,SAAU,EAF9B;AAGE,MAAA,IAAI,EAAEe,IAHR;AAIE,MAAA,KAAK,EAAEC;AAJT,OAKMC,SALN,EADF;AASD;;AAhE0D;;AAmE7D,MAAMf,iBAAiB,GAAG,MAAM;AAC9B,MACET,WAAW,KAAK,IAAhB,IACAA,WAAW,CAACU,cAAZ,KAA+B,IAD/B,IAEAV,WAAW,CAACyB,aAAZ,KAA8B,IAF9B,IAGAzB,WAAW,CAACoB,oBAAZ,KAAqC,IAHrC,IAIApB,WAAW,CAACiB,aAAZ,KAA8B,IAJ9B,IAKAjB,WAAW,CAACc,iBAAZ,KAAkC,IANpC,EAOE;AACA,UAAMY,KAAK,CAAC,8BAAD,CAAX;AACD;AACF,CAXD","sourcesContent":["import React from \"react\";\nimport { requireNativeComponent } from \"react-native\";\n\nimport type { SkRect } from \"../skia/types\";\nimport type { SkiaValue } from \"../values\";\n\nimport { SkiaViewApi } from \"./api\";\nimport type { NativeSkiaViewProps, SkiaViewProps } from \"./types\";\n\nlet SkiaViewNativeId = 1000;\n\nconst NativeSkiaView = requireNativeComponent<NativeSkiaViewProps>(\n \"ReactNativeSkiaView\"\n);\n\nexport class SkiaView extends React.Component<SkiaViewProps> {\n constructor(props: SkiaViewProps) {\n super(props);\n this._nativeId = SkiaViewNativeId++;\n const { onDraw } = props;\n if (onDraw) {\n assertSkiaViewApi();\n SkiaViewApi.setJsiProperty(this._nativeId, \"drawCallback\", onDraw);\n }\n }\n\n private _nativeId: number;\n\n public get nativeId() {\n return this._nativeId;\n }\n\n componentDidUpdate(prevProps: SkiaViewProps) {\n const { onDraw } = this.props;\n if (onDraw !== prevProps.onDraw) {\n assertSkiaViewApi();\n SkiaViewApi.setJsiProperty(this._nativeId, \"drawCallback\", onDraw);\n }\n }\n\n /**\n * Creates a snapshot from the canvas in the surface\n * @param rect Rect to use as bounds. Optional.\n * @returns An Image object.\n */\n public makeImageSnapshot(rect?: SkRect) {\n assertSkiaViewApi();\n return SkiaViewApi.makeImageSnapshot(this._nativeId, rect);\n }\n\n /**\n * Sends a redraw request to the native SkiaView.\n */\n public redraw() {\n assertSkiaViewApi();\n SkiaViewApi.requestRedraw(this._nativeId);\n }\n\n /**\n * Registers one or move values as a dependant value of the Skia View. The view will\n * The view will redraw itself when any of the values change.\n * @param values Values to register\n */\n public registerValues(values: SkiaValue<unknown>[]): () => void {\n assertSkiaViewApi();\n return SkiaViewApi.registerValuesInView(this._nativeId, values);\n }\n\n render() {\n const { mode, debug = false, ...viewProps } = this.props;\n return (\n <NativeSkiaView\n collapsable={false}\n nativeID={`${this._nativeId}`}\n mode={mode}\n debug={debug}\n {...viewProps}\n />\n );\n }\n}\n\nconst assertSkiaViewApi = () => {\n if (\n SkiaViewApi === null ||\n SkiaViewApi.setJsiProperty === null ||\n SkiaViewApi.callJsiMethod === null ||\n SkiaViewApi.registerValuesInView === null ||\n SkiaViewApi.requestRedraw === null ||\n SkiaViewApi.makeImageSnapshot === null\n ) {\n throw Error(\"Skia View Api was not found.\");\n }\n};\n"]}
1
+ {"version":3,"names":["React","requireNativeComponent","SkiaViewApi","SkiaViewNativeId","NativeSkiaView","SkiaView","Component","constructor","props","_nativeId","onDraw","assertSkiaViewApi","setJsiProperty","nativeId","componentDidUpdate","prevProps","makeImageSnapshot","rect","redraw","requestRedraw","registerValues","values","registerValuesInView","render","mode","debug","viewProps","callJsiMethod","Error"],"sources":["SkiaView.tsx"],"sourcesContent":["import React from \"react\";\nimport { requireNativeComponent } from \"react-native\";\n\nimport type { SkRect } from \"../skia/types\";\nimport type { SkiaValue } from \"../values\";\n\nimport { SkiaViewApi } from \"./api\";\nimport type { NativeSkiaViewProps, SkiaViewProps } from \"./types\";\n\nlet SkiaViewNativeId = 1000;\n\nconst NativeSkiaView = requireNativeComponent<NativeSkiaViewProps>(\n \"ReactNativeSkiaView\"\n);\n\nexport class SkiaView extends React.Component<SkiaViewProps> {\n constructor(props: SkiaViewProps) {\n super(props);\n this._nativeId = SkiaViewNativeId++;\n const { onDraw } = props;\n if (onDraw) {\n assertSkiaViewApi();\n SkiaViewApi.setJsiProperty(this._nativeId, \"drawCallback\", onDraw);\n }\n }\n\n private _nativeId: number;\n\n public get nativeId() {\n return this._nativeId;\n }\n\n componentDidUpdate(prevProps: SkiaViewProps) {\n const { onDraw } = this.props;\n if (onDraw !== prevProps.onDraw) {\n assertSkiaViewApi();\n SkiaViewApi.setJsiProperty(this._nativeId, \"drawCallback\", onDraw);\n }\n }\n\n /**\n * Creates a snapshot from the canvas in the surface\n * @param rect Rect to use as bounds. Optional.\n * @returns An Image object.\n */\n public makeImageSnapshot(rect?: SkRect) {\n assertSkiaViewApi();\n return SkiaViewApi.makeImageSnapshot(this._nativeId, rect);\n }\n\n /**\n * Sends a redraw request to the native SkiaView.\n */\n public redraw() {\n assertSkiaViewApi();\n SkiaViewApi.requestRedraw(this._nativeId);\n }\n\n /**\n * Registers one or move values as a dependant value of the Skia View. The view will\n * The view will redraw itself when any of the values change.\n * @param values Values to register\n */\n public registerValues(values: SkiaValue<unknown>[]): () => void {\n assertSkiaViewApi();\n return SkiaViewApi.registerValuesInView(this._nativeId, values);\n }\n\n render() {\n const { mode, debug = false, ...viewProps } = this.props;\n return (\n <NativeSkiaView\n collapsable={false}\n nativeID={`${this._nativeId}`}\n mode={mode}\n debug={debug}\n {...viewProps}\n />\n );\n }\n}\n\nconst assertSkiaViewApi = () => {\n if (\n SkiaViewApi === null ||\n SkiaViewApi.setJsiProperty === null ||\n SkiaViewApi.callJsiMethod === null ||\n SkiaViewApi.registerValuesInView === null ||\n SkiaViewApi.requestRedraw === null ||\n SkiaViewApi.makeImageSnapshot === null\n ) {\n throw Error(\"Skia View Api was not found.\");\n }\n};\n"],"mappings":";;;;AAAA,OAAOA,KAAP,MAAkB,OAAlB;AACA,SAASC,sBAAT,QAAuC,cAAvC;AAKA,SAASC,WAAT,QAA4B,OAA5B;AAGA,IAAIC,gBAAgB,GAAG,IAAvB;AAEA,MAAMC,cAAc,GAAGH,sBAAsB,CAC3C,qBAD2C,CAA7C;AAIA,OAAO,MAAMI,QAAN,SAAuBL,KAAK,CAACM,SAA7B,CAAsD;EAC3DC,WAAW,CAACC,KAAD,EAAuB;IAChC,MAAMA,KAAN;;IADgC;;IAEhC,KAAKC,SAAL,GAAiBN,gBAAgB,EAAjC;IACA,MAAM;MAAEO;IAAF,IAAaF,KAAnB;;IACA,IAAIE,MAAJ,EAAY;MACVC,iBAAiB;MACjBT,WAAW,CAACU,cAAZ,CAA2B,KAAKH,SAAhC,EAA2C,cAA3C,EAA2DC,MAA3D;IACD;EACF;;EAIkB,IAARG,QAAQ,GAAG;IACpB,OAAO,KAAKJ,SAAZ;EACD;;EAEDK,kBAAkB,CAACC,SAAD,EAA2B;IAC3C,MAAM;MAAEL;IAAF,IAAa,KAAKF,KAAxB;;IACA,IAAIE,MAAM,KAAKK,SAAS,CAACL,MAAzB,EAAiC;MAC/BC,iBAAiB;MACjBT,WAAW,CAACU,cAAZ,CAA2B,KAAKH,SAAhC,EAA2C,cAA3C,EAA2DC,MAA3D;IACD;EACF;EAED;AACF;AACA;AACA;AACA;;;EACSM,iBAAiB,CAACC,IAAD,EAAgB;IACtCN,iBAAiB;IACjB,OAAOT,WAAW,CAACc,iBAAZ,CAA8B,KAAKP,SAAnC,EAA8CQ,IAA9C,CAAP;EACD;EAED;AACF;AACA;;;EACSC,MAAM,GAAG;IACdP,iBAAiB;IACjBT,WAAW,CAACiB,aAAZ,CAA0B,KAAKV,SAA/B;EACD;EAED;AACF;AACA;AACA;AACA;;;EACSW,cAAc,CAACC,MAAD,EAA2C;IAC9DV,iBAAiB;IACjB,OAAOT,WAAW,CAACoB,oBAAZ,CAAiC,KAAKb,SAAtC,EAAiDY,MAAjD,CAAP;EACD;;EAEDE,MAAM,GAAG;IACP,MAAM;MAAEC,IAAF;MAAQC,KAAK,GAAG,KAAhB;MAAuB,GAAGC;IAA1B,IAAwC,KAAKlB,KAAnD;IACA,oBACE,oBAAC,cAAD;MACE,WAAW,EAAE,KADf;MAEE,QAAQ,EAAG,GAAE,KAAKC,SAAU,EAF9B;MAGE,IAAI,EAAEe,IAHR;MAIE,KAAK,EAAEC;IAJT,GAKMC,SALN,EADF;EASD;;AAhE0D;;AAmE7D,MAAMf,iBAAiB,GAAG,MAAM;EAC9B,IACET,WAAW,KAAK,IAAhB,IACAA,WAAW,CAACU,cAAZ,KAA+B,IAD/B,IAEAV,WAAW,CAACyB,aAAZ,KAA8B,IAF9B,IAGAzB,WAAW,CAACoB,oBAAZ,KAAqC,IAHrC,IAIApB,WAAW,CAACiB,aAAZ,KAA8B,IAJ9B,IAKAjB,WAAW,CAACc,iBAAZ,KAAkC,IANpC,EAOE;IACA,MAAMY,KAAK,CAAC,8BAAD,CAAX;EACD;AACF,CAXD"}
@@ -1,4 +1,4 @@
1
- function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
2
 
3
3
  function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
4
4
 
@@ -10,8 +10,6 @@ import { TouchType } from "./types";
10
10
  const pd = PixelRatio.get();
11
11
  export class SkiaView extends React.Component {
12
12
  constructor(props) {
13
- var _props$mode;
14
-
15
13
  super(props);
16
14
 
17
15
  _defineProperty(this, "_surface", null);
@@ -34,7 +32,7 @@ export class SkiaView extends React.Component {
34
32
 
35
33
  _defineProperty(this, "requestId", 0);
36
34
 
37
- this._mode = (_props$mode = props.mode) !== null && _props$mode !== void 0 ? _props$mode : "default";
35
+ this._mode = props.mode ?? "default";
38
36
  }
39
37
 
40
38
  unsubscribeAll() {
@@ -1 +1 @@
1
- {"version":3,"sources":["SkiaView.web.tsx"],"names":["React","PixelRatio","View","JsiSkSurface","TouchType","pd","get","SkiaView","Component","constructor","props","createRef","_mode","mode","unsubscribeAll","_unsubscriptions","forEach","u","onLayout","evt","CanvasKit","global","width","height","nativeEvent","layout","_canvasRef","current","canvas","clientWidth","clientHeight","surface","MakeWebGLCanvasSurface","Error","_surface","_canvas","getCanvas","redraw","componentDidMount","tick","componentDidUpdate","componentWillUnmount","cancelAnimationFrame","requestId","makeImageSnapshot","rect","_redrawRequests","onDraw","touches","_touches","info","timestamp","Date","now","map","t","save","scale","restore","ref","flush","requestAnimationFrame","bind","setDrawMode","registerValues","_values","v","push","addListener","handleTouchEvent","touchType","id","pointerId","x","clientX","currentTarget","getClientRects","left","y","clientY","top","force","pressure","type","createTouchHandler","render","debug","viewProps","display","flex","Start","Active","End","Cancelled"],"mappings":";;;;AAAA;AACA,OAAOA,KAAP,MAAkB,OAAlB;AAGA,SAASC,UAAT,EAAqBC,IAArB,QAAiC,cAAjC;AAIA,SAASC,YAAT,QAA6B,0BAA7B;AAGA,SAASC,SAAT,QAA0B,SAA1B;AAEA,MAAMC,EAAE,GAAGJ,UAAU,CAACK,GAAX,EAAX;AAEA,OAAO,MAAMC,QAAN,SAAuBP,KAAK,CAACQ,SAA7B,CAAsD;AAC3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AAEb,SALW;AAMjBnB,MAAAA,SAAS,EAAEC,IAAI,CAACC,GAAL;AANM,KAAnB;;AAQA,SAAKhB,MAAL;AACD;;AAED+C,EAAAA,kBAAkB,CAACd,SAAD,EAAuB;AACvC,WAAQnD,GAAD,IAAuB,KAAKkD,gBAAL,CAAsBlD,GAAtB,EAA2BmD,SAA3B,CAA9B;AACD;;AAEDe,EAAAA,MAAM,GAAG;AACP,UAAM;AAAExE,MAAAA,IAAF;AAAQyE,MAAAA,KAAK,GAAG,KAAhB;AAAuB,SAAGC;AAA1B,QAAwC,KAAK7E,KAAnD;AACA,wBACE,oBAAC,IAAD,eAAU6E,SAAV;AAAqB,MAAA,QAAQ,EAAE,KAAKrE,QAAL,CAAc4C,IAAd,CAAmB,IAAnB;AAA/B,qBACE;AACE,MAAA,GAAG,EAAE,KAAKpC,UADZ;AAEE,MAAA,KAAK,EAAE;AAAE8D,QAAAA,OAAO,EAAE,MAAX;AAAmBC,QAAAA,IAAI,EAAE;AAAzB,OAFT;AAGE,MAAA,aAAa,EAAE,KAAKL,kBAAL,CAAwBhF,SAAS,CAACsF,KAAlC,CAHjB;AAIE,MAAA,aAAa,EAAE,KAAKN,kBAAL,CAAwBhF,SAAS,CAACuF,MAAlC,CAJjB;AAKE,MAAA,WAAW,EAAE,KAAKP,kBAAL,CAAwBhF,SAAS,CAACwF,GAAlC,CALf;AAME,MAAA,eAAe,EAAE,KAAKR,kBAAL,CAAwBhF,SAAS,CAACyF,SAAlC,CANnB;AAOE,MAAA,cAAc,EAAE,KAAKT,kBAAL,CAAwBhF,SAAS,CAACwF,GAAlC,CAPlB;AAQE,MAAA,YAAY,EAAE,KAAKR,kBAAL,CAAwBhF,SAAS,CAACwF,GAAlC;AARhB,MADF,CADF;AAcD;;AAjK0D","sourcesContent":["/* global HTMLCanvasElement */\nimport React from \"react\";\nimport type { PointerEvent } from \"react\";\nimport type { LayoutChangeEvent } from \"react-native\";\nimport { PixelRatio, View } from \"react-native\";\n\nimport type { SkRect, SkCanvas } from \"../skia/types\";\nimport type { SkiaValue } from \"../values\";\nimport { JsiSkSurface } from \"../skia/web/JsiSkSurface\";\n\nimport type { DrawingInfo, DrawMode, SkiaViewProps, TouchInfo } from \"./types\";\nimport { TouchType } from \"./types\";\n\nconst pd = PixelRatio.get();\n\nexport class SkiaView extends React.Component<SkiaViewProps> {\n constructor(props: SkiaViewProps) {\n super(props);\n this._mode = props.mode ?? \"default\";\n }\n\n private _surface: JsiSkSurface | null = null;\n private _unsubscriptions: Array<() => void> = [];\n private _touches: Array<TouchInfo> = [];\n private _canvas: SkCanvas | null = null;\n private _canvasRef = React.createRef<HTMLCanvasElement>();\n private _mode: DrawMode;\n private _redrawRequests = 0;\n private width = 0;\n private height = 0;\n private requestId = 0;\n\n private unsubscribeAll() {\n this._unsubscriptions.forEach((u) => u());\n this._unsubscriptions = [];\n }\n\n private onLayout(evt: LayoutChangeEvent) {\n const { CanvasKit } = global;\n const { width, height } = evt.nativeEvent.layout;\n this.width = width;\n this.height = height;\n // Reset canvas / surface on layout change\n if (this._canvasRef.current) {\n const canvas = this._canvasRef.current;\n canvas.width = canvas.clientWidth * pd;\n canvas.height = canvas.clientHeight * pd;\n const surface = CanvasKit.MakeWebGLCanvasSurface(this._canvasRef.current);\n if (!surface) {\n throw new Error(\"Could not create surface\");\n }\n this._surface = new JsiSkSurface(CanvasKit, surface);\n this._canvas = this._surface.getCanvas();\n this.redraw();\n }\n }\n\n componentDidMount() {\n // Start render loop\n this.tick();\n }\n\n componentDidUpdate() {\n this.redraw();\n }\n\n componentWillUnmount() {\n this.unsubscribeAll();\n cancelAnimationFrame(this.requestId);\n }\n\n /**\n * Creates a snapshot from the canvas in the surface\n * @param rect Rect to use as bounds. Optional.\n * @returns An Image object.\n */\n public makeImageSnapshot(rect?: SkRect) {\n return this._surface?.makeImageSnapshot(rect);\n }\n\n /**\n * Sends a redraw request to the native SkiaView.\n */\n private tick() {\n if (this._mode === \"continuous\" || this._redrawRequests > 0) {\n this._redrawRequests = 0;\n if (this._canvas && this.props.onDraw) {\n const touches = [...this._touches];\n this._touches = [];\n const info: DrawingInfo = {\n height: this.height,\n width: this.width,\n timestamp: Date.now(),\n touches: touches.map((t) => [t]),\n };\n if (this.props.onDraw) {\n const canvas = this._canvas!;\n canvas.save();\n canvas.scale(pd, pd);\n this.props.onDraw(canvas, info);\n canvas.restore();\n }\n this._surface?.ref.flush();\n }\n }\n this.requestId = requestAnimationFrame(this.tick.bind(this));\n }\n\n public redraw() {\n this._redrawRequests++;\n }\n\n /**\n * Updates the drawing mode for the skia view. This is the same\n * as declaratively setting the mode property on the SkiaView.\n * There are two drawing modes, \"continuous\" and \"default\",\n * where the continuous mode will continuously redraw the view and\n * the default mode will only redraw when any of the regular react\n * properties are changed like size and margins.\n * @param mode Drawing mode to use.\n */\n public setDrawMode(mode: DrawMode) {\n this._mode = mode;\n this.tick();\n }\n\n /**\n * Registers one or move values as a dependant value of the Skia View. The view will\n * The view will redraw itself when any of the values change.\n * @param values Values to register\n */\n public registerValues(_values: SkiaValue<unknown>[]) {\n // Unsubscribe from dependency values\n this.unsubscribeAll();\n // Register redraw dependencies on values\n _values.forEach((v) => {\n this._unsubscriptions.push(\n v.addListener(() => {\n this.redraw();\n })\n );\n });\n }\n\n private handleTouchEvent(evt: PointerEvent, touchType: TouchType) {\n this._touches.push({\n id: evt.pointerId,\n x: evt.clientX - evt.currentTarget.getClientRects()[0].left,\n y: evt.clientY - evt.currentTarget.getClientRects()[0].top,\n force: evt.pressure,\n type: touchType,\n timestamp: Date.now(),\n });\n this.redraw();\n }\n\n createTouchHandler(touchType: TouchType) {\n return (evt: PointerEvent) => this.handleTouchEvent(evt, touchType);\n }\n\n render() {\n const { mode, debug = false, ...viewProps } = this.props;\n return (\n <View {...viewProps} onLayout={this.onLayout.bind(this)}>\n <canvas\n ref={this._canvasRef}\n style={{ display: \"flex\", flex: 1 }}\n onPointerDown={this.createTouchHandler(TouchType.Start)}\n onPointerMove={this.createTouchHandler(TouchType.Active)}\n onPointerUp={this.createTouchHandler(TouchType.End)}\n onPointerCancel={this.createTouchHandler(TouchType.Cancelled)}\n onPointerLeave={this.createTouchHandler(TouchType.End)}\n onPointerOut={this.createTouchHandler(TouchType.End)}\n />\n </View>\n );\n }\n}\n"]}
1
+ {"version":3,"names":["React","PixelRatio","View","JsiSkSurface","TouchType","pd","get","SkiaView","Component","constructor","props","createRef","_mode","mode","unsubscribeAll","_unsubscriptions","forEach","u","onLayout","evt","CanvasKit","global","width","height","nativeEvent","layout","_canvasRef","current","canvas","clientWidth","clientHeight","surface","MakeWebGLCanvasSurface","Error","_surface","_canvas","getCanvas","redraw","componentDidMount","tick","componentDidUpdate","componentWillUnmount","cancelAnimationFrame","requestId","makeImageSnapshot","rect","_redrawRequests","onDraw","touches","_touches","info","timestamp","Date","now","map","t","save","scale","restore","ref","flush","requestAnimationFrame","bind","setDrawMode","registerValues","_values","v","push","addListener","handleTouchEvent","touchType","id","pointerId","x","clientX","currentTarget","getClientRects","left","y","clientY","top","force","pressure","type","createTouchHandler","render","debug","viewProps","display","flex","Start","Active","End","Cancelled"],"sources":["SkiaView.web.tsx"],"sourcesContent":["/* global HTMLCanvasElement */\nimport React from \"react\";\nimport type { PointerEvent } from \"react\";\nimport type { LayoutChangeEvent } from \"react-native\";\nimport { PixelRatio, View } from \"react-native\";\n\nimport type { SkRect, SkCanvas } from \"../skia/types\";\nimport type { SkiaValue } from \"../values\";\nimport { JsiSkSurface } from \"../skia/web/JsiSkSurface\";\n\nimport type { DrawingInfo, DrawMode, SkiaViewProps, TouchInfo } from \"./types\";\nimport { TouchType } from \"./types\";\n\nconst pd = PixelRatio.get();\n\nexport class SkiaView extends React.Component<SkiaViewProps> {\n constructor(props: SkiaViewProps) {\n super(props);\n this._mode = props.mode ?? \"default\";\n }\n\n private _surface: JsiSkSurface | null = null;\n private _unsubscriptions: Array<() => void> = [];\n private _touches: Array<TouchInfo> = [];\n private _canvas: SkCanvas | null = null;\n private _canvasRef = React.createRef<HTMLCanvasElement>();\n private _mode: DrawMode;\n private _redrawRequests = 0;\n private width = 0;\n private height = 0;\n private requestId = 0;\n\n private unsubscribeAll() {\n this._unsubscriptions.forEach((u) => u());\n this._unsubscriptions = [];\n }\n\n private onLayout(evt: LayoutChangeEvent) {\n const { CanvasKit } = global;\n const { width, height } = evt.nativeEvent.layout;\n this.width = width;\n this.height = height;\n // Reset canvas / surface on layout change\n if (this._canvasRef.current) {\n const canvas = this._canvasRef.current;\n canvas.width = canvas.clientWidth * pd;\n canvas.height = canvas.clientHeight * pd;\n const surface = CanvasKit.MakeWebGLCanvasSurface(this._canvasRef.current);\n if (!surface) {\n throw new Error(\"Could not create surface\");\n }\n this._surface = new JsiSkSurface(CanvasKit, surface);\n this._canvas = this._surface.getCanvas();\n this.redraw();\n }\n }\n\n componentDidMount() {\n // Start render loop\n this.tick();\n }\n\n componentDidUpdate() {\n this.redraw();\n }\n\n componentWillUnmount() {\n this.unsubscribeAll();\n cancelAnimationFrame(this.requestId);\n }\n\n /**\n * Creates a snapshot from the canvas in the surface\n * @param rect Rect to use as bounds. Optional.\n * @returns An Image object.\n */\n public makeImageSnapshot(rect?: SkRect) {\n return this._surface?.makeImageSnapshot(rect);\n }\n\n /**\n * Sends a redraw request to the native SkiaView.\n */\n private tick() {\n if (this._mode === \"continuous\" || this._redrawRequests > 0) {\n this._redrawRequests = 0;\n if (this._canvas && this.props.onDraw) {\n const touches = [...this._touches];\n this._touches = [];\n const info: DrawingInfo = {\n height: this.height,\n width: this.width,\n timestamp: Date.now(),\n touches: touches.map((t) => [t]),\n };\n if (this.props.onDraw) {\n const canvas = this._canvas!;\n canvas.save();\n canvas.scale(pd, pd);\n this.props.onDraw(canvas, info);\n canvas.restore();\n }\n this._surface?.ref.flush();\n }\n }\n this.requestId = requestAnimationFrame(this.tick.bind(this));\n }\n\n public redraw() {\n this._redrawRequests++;\n }\n\n /**\n * Updates the drawing mode for the skia view. This is the same\n * as declaratively setting the mode property on the SkiaView.\n * There are two drawing modes, \"continuous\" and \"default\",\n * where the continuous mode will continuously redraw the view and\n * the default mode will only redraw when any of the regular react\n * properties are changed like size and margins.\n * @param mode Drawing mode to use.\n */\n public setDrawMode(mode: DrawMode) {\n this._mode = mode;\n this.tick();\n }\n\n /**\n * Registers one or move values as a dependant value of the Skia View. The view will\n * The view will redraw itself when any of the values change.\n * @param values Values to register\n */\n public registerValues(_values: SkiaValue<unknown>[]) {\n // Unsubscribe from dependency values\n this.unsubscribeAll();\n // Register redraw dependencies on values\n _values.forEach((v) => {\n this._unsubscriptions.push(\n v.addListener(() => {\n this.redraw();\n })\n );\n });\n }\n\n private handleTouchEvent(evt: PointerEvent, touchType: TouchType) {\n this._touches.push({\n id: evt.pointerId,\n x: evt.clientX - evt.currentTarget.getClientRects()[0].left,\n y: evt.clientY - evt.currentTarget.getClientRects()[0].top,\n force: evt.pressure,\n type: touchType,\n timestamp: Date.now(),\n });\n this.redraw();\n }\n\n createTouchHandler(touchType: TouchType) {\n return (evt: PointerEvent) => this.handleTouchEvent(evt, touchType);\n }\n\n render() {\n const { mode, debug = false, ...viewProps } = this.props;\n return (\n <View {...viewProps} onLayout={this.onLayout.bind(this)}>\n <canvas\n ref={this._canvasRef}\n style={{ display: \"flex\", flex: 1 }}\n onPointerDown={this.createTouchHandler(TouchType.Start)}\n onPointerMove={this.createTouchHandler(TouchType.Active)}\n onPointerUp={this.createTouchHandler(TouchType.End)}\n onPointerCancel={this.createTouchHandler(TouchType.Cancelled)}\n onPointerLeave={this.createTouchHandler(TouchType.End)}\n onPointerOut={this.createTouchHandler(TouchType.End)}\n />\n </View>\n );\n }\n}\n"],"mappings":";;;;AAAA;AACA,OAAOA,KAAP,MAAkB,OAAlB;AAGA,SAASC,UAAT,EAAqBC,IAArB,QAAiC,cAAjC;AAIA,SAASC,YAAT,QAA6B,0BAA7B;AAGA,SAASC,SAAT,QAA0B,SAA1B;AAEA,MAAMC,EAAE,GAAGJ,UAAU,CAACK,GAAX,EAAX;AAEA,OAAO,M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B,EAA2BmD,SAA3B,CAA9B;EACD;;EAEDe,MAAM,GAAG;IACP,MAAM;MAAExE,IAAF;MAAQyE,KAAK,GAAG,KAAhB;MAAuB,GAAGC;IAA1B,IAAwC,KAAK7E,KAAnD;IACA,oBACE,oBAAC,IAAD,eAAU6E,SAAV;MAAqB,QAAQ,EAAE,KAAKrE,QAAL,CAAc4C,IAAd,CAAmB,IAAnB;IAA/B,iBACE;MACE,GAAG,EAAE,KAAKpC,UADZ;MAEE,KAAK,EAAE;QAAE8D,OAAO,EAAE,MAAX;QAAmBC,IAAI,EAAE;MAAzB,CAFT;MAGE,aAAa,EAAE,KAAKL,kBAAL,CAAwBhF,SAAS,CAACsF,KAAlC,CAHjB;MAIE,aAAa,EAAE,KAAKN,kBAAL,CAAwBhF,SAAS,CAACuF,MAAlC,CAJjB;MAKE,WAAW,EAAE,KAAKP,kBAAL,CAAwBhF,SAAS,CAACwF,GAAlC,CALf;MAME,eAAe,EAAE,KAAKR,kBAAL,CAAwBhF,SAAS,CAACyF,SAAlC,CANnB;MAOE,cAAc,EAAE,KAAKT,kBAAL,CAAwBhF,SAAS,CAACwF,GAAlC,CAPlB;MAQE,YAAY,EAAE,KAAKR,kBAAL,CAAwBhF,SAAS,CAACwF,GAAlC;IARhB,EADF,CADF;EAcD;;AAjK0D"}
@@ -1 +1 @@
1
- {"version":3,"sources":["api.ts"],"names":["SkiaViewApi","global"],"mappings":"AAMA,OAAO,MAAM;AAAEA,EAAAA;AAAF,IAAkBC,MAAxB","sourcesContent":["import type { ISkiaViewApi } from \"./types\";\n\ndeclare global {\n var SkiaViewApi: ISkiaViewApi;\n}\n\nexport const { SkiaViewApi } = global;\n"]}
1
+ {"version":3,"names":["SkiaViewApi","global"],"sources":["api.ts"],"sourcesContent":["import type { ISkiaViewApi } from \"./types\";\n\ndeclare global {\n var SkiaViewApi: ISkiaViewApi;\n}\n\nexport const { SkiaViewApi } = global;\n"],"mappings":"AAMA,OAAO,MAAM;EAAEA;AAAF,IAAkBC,MAAxB"}
@@ -1 +1 @@
1
- {"version":3,"sources":["index.ts"],"names":[],"mappings":"AAAA,cAAc,YAAd;AACA,cAAc,SAAd;AACA,cAAc,mBAAd;AACA,cAAc,mBAAd","sourcesContent":["export * from \"./SkiaView\";\nexport * from \"./types\";\nexport * from \"./useDrawCallback\";\nexport * from \"./useTouchHandler\";\n"]}
1
+ {"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./SkiaView\";\nexport * from \"./types\";\nexport * from \"./useDrawCallback\";\nexport * from \"./useTouchHandler\";\n"],"mappings":"AAAA,cAAc,YAAd;AACA,cAAc,SAAd;AACA,cAAc,mBAAd;AACA,cAAc,mBAAd"}
@@ -1 +1 @@
1
- {"version":3,"sources":["types.ts"],"names":["TouchType"],"mappings":"AAYA,WAAYA,SAAZ;;WAAYA,S;AAAAA,EAAAA,S,CAAAA,S;AAAAA,EAAAA,S,CAAAA,S;AAAAA,EAAAA,S,CAAAA,S;AAAAA,EAAAA,S,CAAAA,S;GAAAA,S,KAAAA,S","sourcesContent":["import type { ViewProps } from \"react-native\";\n\nimport type { SkCanvas, SkImage, SkRect } from \"../skia/types\";\nimport type { SkiaValue } from \"../values\";\n\nexport type DrawMode = \"continuous\" | \"default\";\n\nexport type NativeSkiaViewProps = ViewProps & {\n mode?: DrawMode;\n debug?: boolean;\n};\n\nexport enum TouchType {\n Start,\n Active,\n End,\n Cancelled,\n}\n\nexport interface TouchInfo {\n x: number;\n y: number;\n force: number;\n type: TouchType;\n id: number;\n timestamp: number;\n}\n\nexport interface DrawingInfo {\n width: number;\n height: number;\n timestamp: number;\n touches: Array<Array<TouchInfo>>;\n}\n\nexport type ExtendedTouchInfo = TouchInfo & {\n // points per second\n velocityX: number;\n velocityY: number;\n};\n\nexport type TouchHandlers = {\n onStart?: (touchInfo: TouchInfo) => void;\n onActive?: (touchInfo: ExtendedTouchInfo) => void;\n onEnd?: (touchInfo: ExtendedTouchInfo) => void;\n};\n\nexport type TouchHandler = (touchInfo: Array<Array<TouchInfo>>) => void;\n\nexport type RNSkiaDrawCallback = (canvas: SkCanvas, info: DrawingInfo) => void;\n\n/**\n * Listener interface for value changes\n */\nexport interface ValueListener {\n addListener: (callback: () => void) => number;\n removeListener: (id: number) => void;\n}\n\nexport interface ISkiaViewApi {\n setJsiProperty: <T>(nativeId: number, name: string, value: T) => void;\n callJsiMethod: <T extends Array<unknown>>(\n nativeId: number,\n name: string,\n ...args: T\n ) => void;\n registerValuesInView: (\n nativeId: number,\n values: SkiaValue<unknown>[]\n ) => () => void;\n requestRedraw: (nativeId: number) => void;\n makeImageSnapshot: (nativeId: number, rect?: SkRect) => SkImage;\n}\n\nexport interface SkiaViewProps extends ViewProps {\n /**\n * Sets the drawing mode for the skia view. There are two drawing\n * modes, \"continuous\" and \"default\", where the continuous mode will\n * continuously redraw the view, and the default mode will only\n * redraw when any of the regular react properties are changed like\n * sizes and margins.\n */\n mode?: DrawMode;\n /**\n * When set to true the view will display information about the\n * average time it takes to render.\n */\n debug?: boolean;\n /**\n * Draw callback. Will be called whenever the view is invalidated and\n * needs to redraw. This is either caused by a change in a react\n * property, a touch event, or a call to redraw. If the view is in\n * continuous mode the callback will be called 60 frames per second\n * by the native view.\n */\n onDraw?: RNSkiaDrawCallback;\n}\n"]}
1
+ {"version":3,"names":["TouchType"],"sources":["types.ts"],"sourcesContent":["import type { ViewProps } from \"react-native\";\n\nimport type { SkCanvas, SkImage, SkRect } from \"../skia/types\";\nimport type { SkiaValue } from \"../values\";\n\nexport type DrawMode = \"continuous\" | \"default\";\n\nexport type NativeSkiaViewProps = ViewProps & {\n mode?: DrawMode;\n debug?: boolean;\n};\n\nexport enum TouchType {\n Start,\n Active,\n End,\n Cancelled,\n}\n\nexport interface TouchInfo {\n x: number;\n y: number;\n force: number;\n type: TouchType;\n id: number;\n timestamp: number;\n}\n\nexport interface DrawingInfo {\n width: number;\n height: number;\n timestamp: number;\n touches: Array<Array<TouchInfo>>;\n}\n\nexport type ExtendedTouchInfo = TouchInfo & {\n // points per second\n velocityX: number;\n velocityY: number;\n};\n\nexport type TouchHandlers = {\n onStart?: (touchInfo: TouchInfo) => void;\n onActive?: (touchInfo: ExtendedTouchInfo) => void;\n onEnd?: (touchInfo: ExtendedTouchInfo) => void;\n};\n\nexport type TouchHandler = (touchInfo: Array<Array<TouchInfo>>) => void;\n\nexport type RNSkiaDrawCallback = (canvas: SkCanvas, info: DrawingInfo) => void;\n\n/**\n * Listener interface for value changes\n */\nexport interface ValueListener {\n addListener: (callback: () => void) => number;\n removeListener: (id: number) => void;\n}\n\nexport interface ISkiaViewApi {\n setJsiProperty: <T>(nativeId: number, name: string, value: T) => void;\n callJsiMethod: <T extends Array<unknown>>(\n nativeId: number,\n name: string,\n ...args: T\n ) => void;\n registerValuesInView: (\n nativeId: number,\n values: SkiaValue<unknown>[]\n ) => () => void;\n requestRedraw: (nativeId: number) => void;\n makeImageSnapshot: (nativeId: number, rect?: SkRect) => SkImage;\n}\n\nexport interface SkiaViewProps extends ViewProps {\n /**\n * Sets the drawing mode for the skia view. There are two drawing\n * modes, \"continuous\" and \"default\", where the continuous mode will\n * continuously redraw the view, and the default mode will only\n * redraw when any of the regular react properties are changed like\n * sizes and margins.\n */\n mode?: DrawMode;\n /**\n * When set to true the view will display information about the\n * average time it takes to render.\n */\n debug?: boolean;\n /**\n * Draw callback. Will be called whenever the view is invalidated and\n * needs to redraw. This is either caused by a change in a react\n * property, a touch event, or a call to redraw. If the view is in\n * continuous mode the callback will be called 60 frames per second\n * by the native view.\n */\n onDraw?: RNSkiaDrawCallback;\n}\n"],"mappings":"AAYA,WAAYA,SAAZ;;WAAYA,S;EAAAA,S,CAAAA,S;EAAAA,S,CAAAA,S;EAAAA,S,CAAAA,S;EAAAA,S,CAAAA,S;GAAAA,S,KAAAA,S"}
@@ -1 +1 @@
1
- {"version":3,"sources":["useDrawCallback.ts"],"names":["useMemo","useDrawCallback","callback","deps"],"mappings":"AACA,SAASA,OAAT,QAAwB,OAAxB;;AAIA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,eAAe,GAAG,UAC7BC,QAD6B,EAG1B;AAAA,MADHC,IACG,uEADoB,EACpB;AACH,SAAOH,OAAO,CAAC,MAAM;AACnB,WAAOE,QAAP,CADmB,CAEnB;AACD,GAHa,EAGXC,IAHW,CAAd;AAID,CARM","sourcesContent":["import type { DependencyList } from \"react\";\nimport { useMemo } from \"react\";\n\nimport type { RNSkiaDrawCallback } from \"./types\";\n\n/**\n * Creates a memoized callback for the onDraw handler of a Skia component.\n * @param callback The callback to memoize.\n * @param deps Dependencies for the callback.\n * */\nexport const useDrawCallback = (\n callback: RNSkiaDrawCallback,\n deps: DependencyList = []\n) => {\n return useMemo(() => {\n return callback;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, deps);\n};\n"]}
1
+ {"version":3,"names":["useMemo","useDrawCallback","callback","deps"],"sources":["useDrawCallback.ts"],"sourcesContent":["import type { DependencyList } from \"react\";\nimport { useMemo } from \"react\";\n\nimport type { RNSkiaDrawCallback } from \"./types\";\n\n/**\n * Creates a memoized callback for the onDraw handler of a Skia component.\n * @param callback The callback to memoize.\n * @param deps Dependencies for the callback.\n * */\nexport const useDrawCallback = (\n callback: RNSkiaDrawCallback,\n deps: DependencyList = []\n) => {\n return useMemo(() => {\n return callback;\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, deps);\n};\n"],"mappings":"AACA,SAASA,OAAT,QAAwB,OAAxB;;AAIA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMC,eAAe,GAAG,UAC7BC,QAD6B,EAG1B;EAAA,IADHC,IACG,uEADoB,EACpB;EACH,OAAOH,OAAO,CAAC,MAAM;IACnB,OAAOE,QAAP,CADmB,CAEnB;EACD,CAHa,EAGXC,IAHW,CAAd;AAID,CARM"}
@@ -12,7 +12,7 @@ const useInternalTouchHandler = function (handlers) {
12
12
  history.forEach(touches => {
13
13
  // Enumerate touches
14
14
  for (let i = 0; i < touches.length; i++) {
15
- var _prevTouchInfoRef$cur, _prevTouchInfoRef$cur2, _prevTouch$x, _prevTouch$y, _prevVelocityRef$curr, _prevVelocityRef$curr2, _prevVelocityRef$curr3, _prevVelocityRef$curr4;
15
+ var _prevTouchInfoRef$cur, _prevVelocityRef$curr, _prevVelocityRef$curr2;
16
16
 
17
17
  if (!multiTouch && i > 0) {
18
18
  break;
@@ -21,9 +21,9 @@ const useInternalTouchHandler = function (handlers) {
21
21
  const touch = touches[i];
22
22
  const prevTouch = prevTouchInfoRef.current[touch.id]; // Calculate the velocity from the previous touch.
23
23
 
24
- const timeDiffseconds = touch.timestamp - ((_prevTouchInfoRef$cur = (_prevTouchInfoRef$cur2 = prevTouchInfoRef.current[touch.id]) === null || _prevTouchInfoRef$cur2 === void 0 ? void 0 : _prevTouchInfoRef$cur2.timestamp) !== null && _prevTouchInfoRef$cur !== void 0 ? _prevTouchInfoRef$cur : touch.timestamp);
25
- const distX = touch.x - ((_prevTouch$x = prevTouch === null || prevTouch === void 0 ? void 0 : prevTouch.x) !== null && _prevTouch$x !== void 0 ? _prevTouch$x : touch.x);
26
- const distY = touch.y - ((_prevTouch$y = prevTouch === null || prevTouch === void 0 ? void 0 : prevTouch.y) !== null && _prevTouch$y !== void 0 ? _prevTouch$y : touch.y);
24
+ const timeDiffseconds = touch.timestamp - (((_prevTouchInfoRef$cur = prevTouchInfoRef.current[touch.id]) === null || _prevTouchInfoRef$cur === void 0 ? void 0 : _prevTouchInfoRef$cur.timestamp) ?? touch.timestamp);
25
+ const distX = touch.x - ((prevTouch === null || prevTouch === void 0 ? void 0 : prevTouch.x) ?? touch.x);
26
+ const distY = touch.y - ((prevTouch === null || prevTouch === void 0 ? void 0 : prevTouch.y) ?? touch.y);
27
27
 
28
28
  if (touch.type !== TouchType.Start && touch.type !== TouchType.End && touch.type !== TouchType.Cancelled && timeDiffseconds > 0) {
29
29
  prevVelocityRef.current[touch.id] = {
@@ -33,8 +33,8 @@ const useInternalTouchHandler = function (handlers) {
33
33
  }
34
34
 
35
35
  const extendedTouchInfo = { ...touch,
36
- velocityX: (_prevVelocityRef$curr = (_prevVelocityRef$curr2 = prevVelocityRef.current[touch.id]) === null || _prevVelocityRef$curr2 === void 0 ? void 0 : _prevVelocityRef$curr2.x) !== null && _prevVelocityRef$curr !== void 0 ? _prevVelocityRef$curr : 0,
37
- velocityY: (_prevVelocityRef$curr3 = (_prevVelocityRef$curr4 = prevVelocityRef.current[touch.id]) === null || _prevVelocityRef$curr4 === void 0 ? void 0 : _prevVelocityRef$curr4.y) !== null && _prevVelocityRef$curr3 !== void 0 ? _prevVelocityRef$curr3 : 0
36
+ velocityX: ((_prevVelocityRef$curr = prevVelocityRef.current[touch.id]) === null || _prevVelocityRef$curr === void 0 ? void 0 : _prevVelocityRef$curr.x) ?? 0,
37
+ velocityY: ((_prevVelocityRef$curr2 = prevVelocityRef.current[touch.id]) === null || _prevVelocityRef$curr2 === void 0 ? void 0 : _prevVelocityRef$curr2.y) ?? 0
38
38
  }; // Save previous touch
39
39
 
40
40
  prevTouchInfoRef.current[touch.id] = touch;
@@ -1 +1 @@
1
- {"version":3,"sources":["useTouchHandler.ts"],"names":["useCallback","useRef","PixelRatio","TouchType","useInternalTouchHandler","handlers","deps","multiTouch","prevTouchInfoRef","prevVelocityRef","history","forEach","touches","i","length","touch","prevTouch","current","id","timeDiffseconds","timestamp","distX","x","distY","y","type","Start","End","Cancelled","get","extendedTouchInfo","velocityX","velocityY","onStart","Active","onActive","onEnd","useTouchHandler","useMultiTouchHandler"],"mappings":"AACA,SAASA,WAAT,EAAsBC,MAAtB,QAAoC,OAApC;AACA,SAASC,UAAT,QAA2B,cAA3B;AAUA,SAASC,SAAT,QAA0B,SAA1B;;AAEA,MAAMC,uBAAuB,GAAG,UAC9BC,QAD8B,EAIb;AAAA,MAFjBC,IAEiB,uEAFM,EAEN;AAAA,MADjBC,UACiB,uEADJ,KACI;AACjB,QAAMC,gBAAgB,GAAGP,MAAM,CAA2C,EAA3C,CAA/B;AACA,QAAMQ,eAAe,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,SAAOF,uBAAuB,CAACC,QAAD,EAAWC,IAAX,EAAiB,KAAjB,CAA9B;AACD,CALM;AAOP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,MAAMgC,oBAAoB,GAAG,UAClCjC,QADkC,EAGjB;AAAA,MADjBC,IACiB,uEADM,EACN;AACjB,SAAOF,uBAAuB,CAACC,QAAD,EAAWC,IAAX,EAAiB,IAAjB,CAA9B;AACD,CALM","sourcesContent":["import type { DependencyList } from \"react\";\nimport { useCallback, useRef } from \"react\";\nimport { PixelRatio } from \"react-native\";\n\nimport type { Vector } from \"../skia/types\";\n\nimport type {\n ExtendedTouchInfo,\n TouchHandlers,\n TouchHandler,\n TouchInfo,\n} from \"./types\";\nimport { TouchType } from \"./types\";\n\nconst useInternalTouchHandler = (\n handlers: TouchHandlers,\n deps: DependencyList = [],\n multiTouch = false\n): TouchHandler => {\n const prevTouchInfoRef = useRef<{ [key: number]: TouchInfo | undefined }>({});\n const prevVelocityRef = useRef<{ [key: number]: Vector | undefined }>({});\n\n return useCallback((history: Array<Array<TouchInfo>>) => {\n // Process all items in the current touch history\n history.forEach((touches) => {\n // Enumerate touches\n for (let i = 0; i < touches.length; i++) {\n if (!multiTouch && i > 0) {\n break;\n }\n\n const touch = touches[i];\n const prevTouch = prevTouchInfoRef.current[touch.id];\n // Calculate the velocity from the previous touch.\n const timeDiffseconds =\n touch.timestamp -\n (prevTouchInfoRef.current[touch.id]?.timestamp ?? touch.timestamp);\n\n const distX = touch.x - (prevTouch?.x ?? touch.x);\n const distY = touch.y - (prevTouch?.y ?? touch.y);\n\n if (\n touch.type !== TouchType.Start &&\n touch.type !== TouchType.End &&\n touch.type !== TouchType.Cancelled &&\n timeDiffseconds > 0\n ) {\n prevVelocityRef.current[touch.id] = {\n x: distX / timeDiffseconds / PixelRatio.get(),\n y: distY / timeDiffseconds / PixelRatio.get(),\n };\n }\n\n const extendedTouchInfo: ExtendedTouchInfo = {\n ...touch,\n velocityX: prevVelocityRef.current[touch.id]?.x ?? 0,\n velocityY: prevVelocityRef.current[touch.id]?.y ?? 0,\n };\n\n // Save previous touch\n prevTouchInfoRef.current[touch.id] = touch;\n\n if (touch.type === TouchType.Start) {\n delete prevVelocityRef.current[touch.id];\n handlers.onStart && handlers.onStart(touch);\n } else if (touch.type === TouchType.Active) {\n handlers.onActive && handlers.onActive(extendedTouchInfo);\n } else {\n handlers.onEnd && handlers.onEnd(extendedTouchInfo);\n }\n }\n });\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, deps);\n};\n\n/**\n * Provides a callback for handling touch events in the Skia View.\n * This touch handler only handles single touches.\n * @param handlers Callbacks for the different touch states\n * @param deps optional Dependency array to update the handlers\n * @returns A function that can be used from within the onDraw callback to\n * update and handle touch events. Call it with the touches property from\n * the info object.\n */\nexport const useTouchHandler = (\n handlers: TouchHandlers,\n deps: DependencyList = []\n): TouchHandler => {\n return useInternalTouchHandler(handlers, deps, false);\n};\n\n/**\n * Provides a callback for handling touch events in the Skia View.\n * This touch handler handles multiple touches.\n * @param handlers Callbacks for the different touch states\n * @param deps optional Dependency array to update the handlers\n * @returns A function that can be used from within the onDraw callback to\n * update and handle touch events. Call it with the touches property from\n * the info object.\n */\nexport const useMultiTouchHandler = (\n handlers: TouchHandlers,\n deps: DependencyList = []\n): TouchHandler => {\n return useInternalTouchHandler(handlers, deps, true);\n};\n"]}
1
+ {"version":3,"names":["useCallback","useRef","PixelRatio","TouchType","useInternalTouchHandler","handlers","deps","multiTouch","prevTouchInfoRef","prevVelocityRef","history","forEach","touches","i","length","touch","prevTouch","current","id","timeDiffseconds","timestamp","distX","x","distY","y","type","Start","End","Cancelled","get","extendedTouchInfo","velocityX","velocityY","onStart","Active","onActive","onEnd","useTouchHandler","useMultiTouchHandler"],"sources":["useTouchHandler.ts"],"sourcesContent":["import type { DependencyList } from \"react\";\nimport { useCallback, useRef } from \"react\";\nimport { PixelRatio } from \"react-native\";\n\nimport type { Vector } from \"../skia/types\";\n\nimport type {\n ExtendedTouchInfo,\n TouchHandlers,\n TouchHandler,\n TouchInfo,\n} from \"./types\";\nimport { TouchType } from \"./types\";\n\nconst useInternalTouchHandler = (\n handlers: TouchHandlers,\n deps: DependencyList = [],\n multiTouch = false\n): TouchHandler => {\n const prevTouchInfoRef = useRef<{ [key: number]: TouchInfo | undefined }>({});\n const prevVelocityRef = useRef<{ [key: number]: Vector | undefined }>({});\n\n return useCallback((history: Array<Array<TouchInfo>>) => {\n // Process all items in the current touch history\n history.forEach((touches) => {\n // Enumerate touches\n for (let i = 0; i < touches.length; i++) {\n if (!multiTouch && i > 0) {\n break;\n }\n\n const touch = touches[i];\n const prevTouch = prevTouchInfoRef.current[touch.id];\n // Calculate the velocity from the previous touch.\n const timeDiffseconds =\n touch.timestamp -\n (prevTouchInfoRef.current[touch.id]?.timestamp ?? touch.timestamp);\n\n const distX = touch.x - (prevTouch?.x ?? touch.x);\n const distY = touch.y - (prevTouch?.y ?? touch.y);\n\n if (\n touch.type !== TouchType.Start &&\n touch.type !== TouchType.End &&\n touch.type !== TouchType.Cancelled &&\n timeDiffseconds > 0\n ) {\n prevVelocityRef.current[touch.id] = {\n x: distX / timeDiffseconds / PixelRatio.get(),\n y: distY / timeDiffseconds / PixelRatio.get(),\n };\n }\n\n const extendedTouchInfo: ExtendedTouchInfo = {\n ...touch,\n velocityX: prevVelocityRef.current[touch.id]?.x ?? 0,\n velocityY: prevVelocityRef.current[touch.id]?.y ?? 0,\n };\n\n // Save previous touch\n prevTouchInfoRef.current[touch.id] = touch;\n\n if (touch.type === TouchType.Start) {\n delete prevVelocityRef.current[touch.id];\n handlers.onStart && handlers.onStart(touch);\n } else if (touch.type === TouchType.Active) {\n handlers.onActive && handlers.onActive(extendedTouchInfo);\n } else {\n handlers.onEnd && handlers.onEnd(extendedTouchInfo);\n }\n }\n });\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, deps);\n};\n\n/**\n * Provides a callback for handling touch events in the Skia View.\n * This touch handler only handles single touches.\n * @param handlers Callbacks for the different touch states\n * @param deps optional Dependency array to update the handlers\n * @returns A function that can be used from within the onDraw callback to\n * update and handle touch events. Call it with the touches property from\n * the info object.\n */\nexport const useTouchHandler = (\n handlers: TouchHandlers,\n deps: DependencyList = []\n): TouchHandler => {\n return useInternalTouchHandler(handlers, deps, false);\n};\n\n/**\n * Provides a callback for handling touch events in the Skia View.\n * This touch handler handles multiple touches.\n * @param handlers Callbacks for the different touch states\n * @param deps optional Dependency array to update the handlers\n * @returns A function that can be used from within the onDraw callback to\n * update and handle touch events. Call it with the touches property from\n * the info object.\n */\nexport const useMultiTouchHandler = (\n handlers: TouchHandlers,\n deps: DependencyList = []\n): TouchHandler => {\n return useInternalTouchHandler(handlers, deps, true);\n};\n"],"mappings":"AACA,SAASA,WAAT,EAAsBC,MAAtB,QAAoC,OAApC;AACA,SAASC,UAAT,QAA2B,cAA3B;AAUA,SAASC,SAAT,QAA0B,SAA1B;;AAEA,MAAMC,uBAAuB,GAAG,UAC9BC,QAD8B,EAIb;EAAA,IAFjBC,IAEiB,uEAFM,EAEN;EAAA,IADjBC,UACiB,uEADJ,KACI;EACjB,MAAMC,gBAAgB,GAAGP,MAAM,CAA2C,EAA3C,CAA/B;EACA,MAAMQ,eAAe,GAAGR,MAAM,CAAwC,EAAxC,CAA9B;EAEA,OAAOD,WAAW,CAAEU,OAAD,IAAsC;IACvD;IACAA,OAAO,CAACC,OAAR,CAAiBC,OAAD,IAAa;MAC3B;MACA,KAAK,IAAIC,CAAC,GAAG,CAAb,EAAgBA,CAAC,GAAGD,OAAO,CAACE,MAA5B,EAAoCD,CAAC,EAArC,EAAyC;QAAA;;QACvC,IAAI,CAACN,UAAD,IAAeM,CAAC,GAAG,CAAvB,EAA0B;UACxB;QACD;;QAED,MAAME,KAAK,GAAGH,OAAO,CAACC,CAAD,CAArB;QACA,MAAMG,SAAS,GAAGR,gBAAgB,CAACS,OAAjB,CAAyBF,KAAK,CAACG,EAA/B,CAAlB,CANuC,CAOvC;;QACA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EA,IAAIA,KAAK,CAACU,IAAN,KAAetB,SAAS,CAACuB,KAA7B,EAAoC;UAClC,OAAOjB,eAAe,CAACQ,OAAhB,CAAwBF,KAAK,CAACG,EAA9B,CAAP;UACAb,QAAQ,CAAC4B,OAAT,IAAoB5B,QAAQ,CAAC4B,OAAT,CAAiBlB,KAAjB,CAApB;QACD,CAHD,MAGO,IAAIA,KAAK,CAACU,IAAN,KAAetB,SAAS,CAAC+B,MAA7B,EAAqC;UAC1C7B,QAAQ,CAAC8B,QAAT,IAAqB9B,QAAQ,CAAC8B,QAAT,CAAkBL,iBAAlB,CAArB;QACD,CAFM,MAEA;UACLzB,QAAQ,CAAC+B,KAAT,IAAkB/B,QAAQ,CAAC+B,KAAT,CAAeN,iBAAf,CAAlB;QACD;MACF;IACF,CA/CD,EAFuD,CAkDvD;EACD,CAnDiB,EAmDfxB,IAnDe,CAAlB;AAoDD,CA5DD;AA8DA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;;AACA,OAAO,MAAM+B,eAAe,GAAG,UAC7BhC,QAD6B,EAGZ;EAAA,IADjBC,IACiB,uEADM,EACN;EACjB,OAAOF,uBAAuB,CAACC,QAAD,EAAWC,IAAX,EAAiB,KAAjB,CAA9B;AACD,CALM;AAOP;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AACA,OAAO,MAAMgC,oBAAoB,GAAG,UAClCjC,QADkC,EAGjB;EAAA,IADjBC,IACiB,uEADM,EACN;EACjB,OAAOF,uBAAuB,CAACC,QAAD,EAAWC,IAAX,EAAiB,IAAjB,CAA9B;AACD,CALM"}
@@ -1 +1 @@
1
- {"version":3,"sources":["LoadSkiaWeb.tsx"],"names":["CanvasKitInit","LoadSkiaWeb","opts","global","CanvasKit","undefined","LoadSkia"],"mappings":"AAAA;AACA;AACA,OAAOA,aAAP,MAA0B,mCAA1B;AAUA,OAAO,MAAMC,WAAW,GAAG,MAAOC,IAAP,IAAuC;AAChE,MAAIC,MAAM,CAACC,SAAP,KAAqBC,SAAzB,EAAoC;AAClC;AACD;;AACD,QAAMD,SAAS,GAAG,MAAMJ,aAAa,CAACE,IAAD,CAArC,CAJgE,CAKhE;AACA;;AACAC,EAAAA,MAAM,CAACC,SAAP,GAAmBA,SAAnB;AACD,CARM,C,CAUP;;AACA,OAAO,MAAME,QAAQ,GAAGL,WAAjB","sourcesContent":["// eslint-disable-next-line @typescript-eslint/ban-ts-comment\n// @ts-expect-error\nimport CanvasKitInit from \"canvaskit-wasm/bin/full/canvaskit\";\nimport type {\n CanvasKit as CanvasKitType,\n CanvasKitInitOptions,\n} from \"canvaskit-wasm\";\n\ndeclare global {\n var CanvasKit: CanvasKitType;\n}\n\nexport const LoadSkiaWeb = async (opts?: CanvasKitInitOptions) => {\n if (global.CanvasKit !== undefined) {\n return;\n }\n const CanvasKit = await CanvasKitInit(opts);\n // The CanvasKit API is stored on the global object and used\n // to create the JsiSKApi in the Skia.web.ts file.\n global.CanvasKit = CanvasKit;\n};\n\n// We keep this function for backward compatibility\nexport const LoadSkia = LoadSkiaWeb;\n"]}
1
+ {"version":3,"names":["CanvasKitInit","LoadSkiaWeb","opts","global","CanvasKit","undefined","LoadSkia"],"sources":["LoadSkiaWeb.tsx"],"sourcesContent":["// eslint-disable-next-line @typescript-eslint/ban-ts-comment\n// @ts-expect-error\nimport CanvasKitInit from \"canvaskit-wasm/bin/full/canvaskit\";\nimport type {\n CanvasKit as CanvasKitType,\n CanvasKitInitOptions,\n} from \"canvaskit-wasm\";\n\ndeclare global {\n var CanvasKit: CanvasKitType;\n}\n\nexport const LoadSkiaWeb = async (opts?: CanvasKitInitOptions) => {\n if (global.CanvasKit !== undefined) {\n return;\n }\n const CanvasKit = await CanvasKitInit(opts);\n // The CanvasKit API is stored on the global object and used\n // to create the JsiSKApi in the Skia.web.ts file.\n global.CanvasKit = CanvasKit;\n};\n\n// We keep this function for backward compatibility\nexport const LoadSkia = LoadSkiaWeb;\n"],"mappings":"AAAA;AACA;AACA,OAAOA,aAAP,MAA0B,mCAA1B;AAUA,OAAO,MAAMC,WAAW,GAAG,MAAOC,IAAP,IAAuC;EAChE,IAAIC,MAAM,CAACC,SAAP,KAAqBC,SAAzB,EAAoC;IAClC;EACD;;EACD,MAAMD,SAAS,GAAG,MAAMJ,aAAa,CAACE,IAAD,CAArC,CAJgE,CAKhE;EACA;;EACAC,MAAM,CAACC,SAAP,GAAmBA,SAAnB;AACD,CARM,C,CAUP;;AACA,OAAO,MAAME,QAAQ,GAAGL,WAAjB"}
@@ -19,7 +19,7 @@ export const WithSkiaWeb = _ref => {
19
19
  return getComponent();
20
20
  }), [getComponent, opts]);
21
21
  return /*#__PURE__*/React.createElement(Suspense, {
22
- fallback: fallback !== null && fallback !== void 0 ? fallback : null
22
+ fallback: fallback ?? null
23
23
  }, /*#__PURE__*/React.createElement(Inner, null));
24
24
  };
25
25
  //# sourceMappingURL=WithSkiaWeb.js.map
@@ -1 +1 @@
1
- {"version":3,"sources":["WithSkiaWeb.tsx"],"names":["React","useMemo","lazy","Suspense","Platform","LoadSkiaWeb","WithSkiaWeb","getComponent","fallback","opts","Inner","OS","console","warn"],"mappings":"AACA,OAAOA,KAAP,IAAgBC,OAAhB,EAAyBC,IAAzB,EAA+BC,QAA/B,QAA+C,OAA/C;AACA,SAASC,QAAT,QAAyB,cAAzB;AAEA,SAASC,WAAT,QAA4B,eAA5B;AAQA,OAAO,MAAMC,WAAW,GAAG,QAIN;AAAA,MAJO;AAC1BC,IAAAA,YAD0B;AAE1BC,IAAAA,QAF0B;AAG1BC,IAAAA;AAH0B,GAIP;AACnB,QAAMC,KAAK,GAAGT,OAAO,EACnB;AACA;AACA,qBACEC,IAAI,CAAC,YAAY;AACf,QAAIE,QAAQ,CAACO,EAAT,KAAgB,KAApB,EAA2B;AACzB,YAAMN,WAAW,CAACI,IAAD,CAAjB;AACD,KAFD,MAEO;AACLG,MAAAA,OAAO,CAACC,IAAR,CACE,yEADF;AAGD;;AACD,WAAON,YAAY,EAAnB;AACD,GATG,CAJa,EAcnB,CAACA,YAAD,EAAeE,IAAf,CAdmB,CAArB;AAgBA,sBACE,oBAAC,QAAD;AAAU,IAAA,QAAQ,EAAED,QAAF,aAAEA,QAAF,cAAEA,QAAF,GAAc;AAAhC,kBACE,oBAAC,KAAD,OADF,CADF;AAKD,CA1BM","sourcesContent":["import type { ComponentProps, ComponentType } from \"react\";\nimport React, { useMemo, lazy, Suspense } from \"react\";\nimport { Platform } from \"react-native\";\n\nimport { LoadSkiaWeb } from \"./LoadSkiaWeb\";\n\ninterface WithSkiaProps {\n fallback?: ComponentProps<typeof Suspense>[\"fallback\"];\n getComponent: () => Promise<{ default: ComponentType }>;\n opts?: Parameters<typeof LoadSkiaWeb>[0];\n}\n\nexport const WithSkiaWeb = ({\n getComponent,\n fallback,\n opts,\n}: WithSkiaProps) => {\n const Inner = useMemo(\n // TODO: investigate\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (): any =>\n lazy(async () => {\n if (Platform.OS === \"web\") {\n await LoadSkiaWeb(opts);\n } else {\n console.warn(\n \"<WithSkiaWeb /> is only necessary on web. Consider not using on native.\"\n );\n }\n return getComponent();\n }),\n [getComponent, opts]\n );\n return (\n <Suspense fallback={fallback ?? null}>\n <Inner />\n </Suspense>\n );\n};\n"]}
1
+ {"version":3,"names":["React","useMemo","lazy","Suspense","Platform","LoadSkiaWeb","WithSkiaWeb","getComponent","fallback","opts","Inner","OS","console","warn"],"sources":["WithSkiaWeb.tsx"],"sourcesContent":["import type { ComponentProps, ComponentType } from \"react\";\nimport React, { useMemo, lazy, Suspense } from \"react\";\nimport { Platform } from \"react-native\";\n\nimport { LoadSkiaWeb } from \"./LoadSkiaWeb\";\n\ninterface WithSkiaProps {\n fallback?: ComponentProps<typeof Suspense>[\"fallback\"];\n getComponent: () => Promise<{ default: ComponentType }>;\n opts?: Parameters<typeof LoadSkiaWeb>[0];\n}\n\nexport const WithSkiaWeb = ({\n getComponent,\n fallback,\n opts,\n}: WithSkiaProps) => {\n const Inner = useMemo(\n // TODO: investigate\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n (): any =>\n lazy(async () => {\n if (Platform.OS === \"web\") {\n await LoadSkiaWeb(opts);\n } else {\n console.warn(\n \"<WithSkiaWeb /> is only necessary on web. Consider not using on native.\"\n );\n }\n return getComponent();\n }),\n [getComponent, opts]\n );\n return (\n <Suspense fallback={fallback ?? null}>\n <Inner />\n </Suspense>\n );\n};\n"],"mappings":"AACA,OAAOA,KAAP,IAAgBC,OAAhB,EAAyBC,IAAzB,EAA+BC,QAA/B,QAA+C,OAA/C;AACA,SAASC,QAAT,QAAyB,cAAzB;AAEA,SAASC,WAAT,QAA4B,eAA5B;AAQA,OAAO,MAAMC,WAAW,GAAG,QAIN;EAAA,IAJO;IAC1BC,YAD0B;IAE1BC,QAF0B;IAG1BC;EAH0B,CAIP;EACnB,MAAMC,KAAK,GAAGT,OAAO,EACnB;EACA;EACA,mBACEC,IAAI,CAAC,YAAY;IACf,IAAIE,QAAQ,CAACO,EAAT,KAAgB,KAApB,EAA2B;MACzB,MAAMN,WAAW,CAACI,IAAD,CAAjB;IACD,CAFD,MAEO;MACLG,OAAO,CAACC,IAAR,CACE,yEADF;IAGD;;IACD,OAAON,YAAY,EAAnB;EACD,CATG,CAJa,EAcnB,CAACA,YAAD,EAAeE,IAAf,CAdmB,CAArB;EAgBA,oBACE,oBAAC,QAAD;IAAU,QAAQ,EAAED,QAAQ,IAAI;EAAhC,gBACE,oBAAC,KAAD,OADF,CADF;AAKD,CA1BM"}
@@ -1 +1 @@
1
- {"version":3,"sources":["index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAd;AACA,cAAc,eAAd","sourcesContent":["export * from \"./LoadSkiaWeb\";\nexport * from \"./WithSkiaWeb\";\n"]}
1
+ {"version":3,"names":[],"sources":["index.ts"],"sourcesContent":["export * from \"./LoadSkiaWeb\";\nexport * from \"./WithSkiaWeb\";\n"],"mappings":"AAAA,cAAc,eAAd;AACA,cAAc,eAAd"}
@@ -7,4 +7,4 @@ import type { DecayConfig } from "./types";
7
7
  * @param config Configuration or default configuration
8
8
  * @returns Animation
9
9
  */
10
- export declare const runDecay: (value: SkiaMutableValue<number>, config?: DecayConfig | undefined) => import("../../values/types").SkiaAnimation;
10
+ export declare const runDecay: (value: SkiaMutableValue<number>, config?: DecayConfig) => import("../../values/types").SkiaAnimation;
@@ -13,4 +13,4 @@ import type { AnimationParams, SpringConfig, AnimationCallback } from "../types"
13
13
  * @returns an animation value that can be used to start/stop
14
14
  * the animation.
15
15
  */
16
- export declare const runSpring: (value: SkiaMutableValue<number>, toOrParams: number | AnimationParams, config?: SpringConfig | undefined, callback?: AnimationCallback | undefined) => SkiaAnimation;
16
+ export declare const runSpring: (value: SkiaMutableValue<number>, toOrParams: number | AnimationParams, config?: SpringConfig, callback?: AnimationCallback) => SkiaAnimation;
@@ -7,4 +7,4 @@ import type { SpringConfig, AnimationParams, AnimationCallback } from "../types"
7
7
  * @param config
8
8
  * @returns
9
9
  */
10
- export declare const useSpring: (toOrParams: number | AnimationParams, config?: SpringConfig | undefined, callback?: AnimationCallback | undefined) => SkiaValue<number>;
10
+ export declare const useSpring: (toOrParams: number | AnimationParams, config?: SpringConfig, callback?: AnimationCallback) => SkiaValue<number>;
@@ -14,4 +14,4 @@ import type { SkiaMutableValue } from "../../values/types";
14
14
  * @params an animation value that can be used to start/stop
15
15
  * the animation.
16
16
  */
17
- export declare const createTiming: (params: RequiredAnimationParams & Required<TimingConfig>, value?: SkiaMutableValue<number> | undefined, callback?: AnimationCallback | undefined) => import("../../values/types").SkiaAnimation;
17
+ export declare const createTiming: (params: RequiredAnimationParams & Required<TimingConfig>, value?: SkiaMutableValue<number>, callback?: AnimationCallback) => import("../../values/types").SkiaAnimation;
@@ -4,4 +4,4 @@ import type { RequiredAnimationParams, AnimationParams, TimingConfig } from "../
4
4
  * @param toOrParams Params or to value
5
5
  * @param config timing/spring configuration
6
6
  */
7
- export declare const getResolvedParams: (toOrParams: number | AnimationParams, config?: TimingConfig | undefined) => RequiredAnimationParams & Required<TimingConfig>;
7
+ export declare const getResolvedParams: (toOrParams: number | AnimationParams, config?: TimingConfig) => RequiredAnimationParams & Required<TimingConfig>;