@shopify/react-native-skia 0.1.236 → 0.1.238
Sign up to get free protection for your applications and to get access to all the features.
- package/cpp/api/JsiSkApi.h +2 -0
- package/cpp/api/JsiSkCanvas.h +36 -0
- package/cpp/api/JsiSkRSXform.h +35 -7
- package/cpp/rnskia/dom/JsiDomApi.h +2 -0
- package/cpp/rnskia/dom/base/JsiDomNode.h +16 -0
- package/cpp/rnskia/dom/nodes/JsiAtlasNode.h +60 -0
- package/cpp/rnskia/dom/props/RSXformProp.h +52 -0
- package/cpp/rnskia/dom/props/RectProp.h +31 -0
- package/lib/commonjs/Platform/Platform.js +1 -5
- package/lib/commonjs/Platform/Platform.js.map +1 -1
- package/lib/commonjs/Platform/Platform.web.js +11 -33
- package/lib/commonjs/Platform/Platform.web.js.map +1 -1
- package/lib/commonjs/Platform/index.js +0 -2
- package/lib/commonjs/Platform/index.js.map +1 -1
- package/lib/commonjs/animation/functions/index.js +0 -8
- package/lib/commonjs/animation/functions/index.js.map +1 -1
- package/lib/commonjs/animation/functions/interpolate.js +12 -31
- package/lib/commonjs/animation/functions/interpolate.js.map +1 -1
- package/lib/commonjs/animation/functions/interpolateColors.js +2 -13
- package/lib/commonjs/animation/functions/interpolateColors.js.map +1 -1
- package/lib/commonjs/animation/functions/interpolatePaths.js +1 -16
- package/lib/commonjs/animation/functions/interpolatePaths.js.map +1 -1
- package/lib/commonjs/animation/functions/interpolateVector.js +0 -5
- package/lib/commonjs/animation/functions/interpolateVector.js.map +1 -1
- package/lib/commonjs/animation/index.js +0 -2
- package/lib/commonjs/animation/index.js.map +1 -1
- package/lib/commonjs/dom/nodes/DrawingNode.js +7 -22
- package/lib/commonjs/dom/nodes/DrawingNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/GroupNode.js +0 -6
- package/lib/commonjs/dom/nodes/GroupNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/JsiSkDOM.d.ts +2 -1
- package/lib/commonjs/dom/nodes/JsiSkDOM.js +28 -86
- package/lib/commonjs/dom/nodes/JsiSkDOM.js.map +1 -1
- package/lib/commonjs/dom/nodes/LayerNode.js +0 -11
- package/lib/commonjs/dom/nodes/LayerNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/Node.js +4 -36
- package/lib/commonjs/dom/nodes/Node.js.map +1 -1
- package/lib/commonjs/dom/nodes/PaintNode.js +1 -29
- package/lib/commonjs/dom/nodes/PaintNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/RenderNode.js +3 -35
- package/lib/commonjs/dom/nodes/RenderNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/datatypes/Circle.js +6 -8
- package/lib/commonjs/dom/nodes/datatypes/Circle.js.map +1 -1
- package/lib/commonjs/dom/nodes/datatypes/Enum.js +0 -2
- package/lib/commonjs/dom/nodes/datatypes/Enum.js.map +1 -1
- package/lib/commonjs/dom/nodes/datatypes/Fitting.js +15 -46
- package/lib/commonjs/dom/nodes/datatypes/Fitting.js.map +1 -1
- package/lib/commonjs/dom/nodes/datatypes/Gradient.js +9 -20
- package/lib/commonjs/dom/nodes/datatypes/Gradient.js.map +1 -1
- package/lib/commonjs/dom/nodes/datatypes/Path.js +2 -8
- package/lib/commonjs/dom/nodes/datatypes/Path.js.map +1 -1
- package/lib/commonjs/dom/nodes/datatypes/Radius.js +0 -3
- package/lib/commonjs/dom/nodes/datatypes/Radius.js.map +1 -1
- package/lib/commonjs/dom/nodes/datatypes/Rect.js +10 -15
- package/lib/commonjs/dom/nodes/datatypes/Rect.js.map +1 -1
- package/lib/commonjs/dom/nodes/datatypes/Transform.js +0 -6
- package/lib/commonjs/dom/nodes/datatypes/Transform.js.map +1 -1
- package/lib/commonjs/dom/nodes/datatypes/index.js +0 -16
- package/lib/commonjs/dom/nodes/datatypes/index.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/AtlasNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/AtlasNode.js +36 -0
- package/lib/commonjs/dom/nodes/drawings/AtlasNode.js.map +1 -0
- package/lib/commonjs/dom/nodes/drawings/BackdropFilterNode.js +4 -18
- package/lib/commonjs/dom/nodes/drawings/BackdropFilterNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/Box.js +8 -34
- package/lib/commonjs/dom/nodes/drawings/Box.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/CircleNode.js +4 -15
- package/lib/commonjs/dom/nodes/drawings/CircleNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/DiffRectNode.js +4 -12
- package/lib/commonjs/dom/nodes/drawings/DiffRectNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/FillNode.js +5 -14
- package/lib/commonjs/dom/nodes/drawings/FillNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/ImageNode.js +6 -19
- package/lib/commonjs/dom/nodes/drawings/ImageNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/ImageSVG.js +3 -18
- package/lib/commonjs/dom/nodes/drawings/ImageSVG.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/LineNode.js +4 -12
- package/lib/commonjs/dom/nodes/drawings/LineNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/OvalNode.js +4 -15
- package/lib/commonjs/dom/nodes/drawings/OvalNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/ParagraphNode.js +3 -12
- package/lib/commonjs/dom/nodes/drawings/ParagraphNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/PatchNode.js +6 -18
- package/lib/commonjs/dom/nodes/drawings/PatchNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/PathNode.js +4 -21
- package/lib/commonjs/dom/nodes/drawings/PathNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/PictureNode.js +3 -11
- package/lib/commonjs/dom/nodes/drawings/PictureNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/PointsNode.js +4 -14
- package/lib/commonjs/dom/nodes/drawings/PointsNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/RRectNode.js +7 -18
- package/lib/commonjs/dom/nodes/drawings/RRectNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/RectNode.js +4 -15
- package/lib/commonjs/dom/nodes/drawings/RectNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/Text.js +18 -62
- package/lib/commonjs/dom/nodes/drawings/Text.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/VerticesNode.js +4 -16
- package/lib/commonjs/dom/nodes/drawings/VerticesNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/drawings/index.d.ts +1 -0
- package/lib/commonjs/dom/nodes/drawings/index.js +11 -34
- package/lib/commonjs/dom/nodes/drawings/index.js.map +1 -1
- package/lib/commonjs/dom/nodes/index.js +0 -6
- package/lib/commonjs/dom/nodes/index.js.map +1 -1
- package/lib/commonjs/dom/nodes/paint/BlendNode.js +4 -18
- package/lib/commonjs/dom/nodes/paint/BlendNode.js.map +1 -1
- package/lib/commonjs/dom/nodes/paint/ColorFilters.js +0 -34
- package/lib/commonjs/dom/nodes/paint/ColorFilters.js.map +1 -1
- package/lib/commonjs/dom/nodes/paint/ImageFilters.js +7 -60
- package/lib/commonjs/dom/nodes/paint/ImageFilters.js.map +1 -1
- package/lib/commonjs/dom/nodes/paint/MaskFilters.js +0 -8
- package/lib/commonjs/dom/nodes/paint/MaskFilters.js.map +1 -1
- package/lib/commonjs/dom/nodes/paint/PathEffects.js +0 -45
- package/lib/commonjs/dom/nodes/paint/PathEffects.js.map +1 -1
- package/lib/commonjs/dom/nodes/paint/Shaders.js +1 -48
- package/lib/commonjs/dom/nodes/paint/Shaders.js.map +1 -1
- package/lib/commonjs/dom/nodes/paint/index.js +0 -12
- package/lib/commonjs/dom/nodes/paint/index.js.map +1 -1
- package/lib/commonjs/dom/types/DeclarationContext.js +3 -30
- package/lib/commonjs/dom/types/DeclarationContext.js.map +1 -1
- package/lib/commonjs/dom/types/DrawingContext.js +3 -91
- package/lib/commonjs/dom/types/DrawingContext.js.map +1 -1
- package/lib/commonjs/dom/types/Drawings.d.ts +7 -1
- package/lib/commonjs/dom/types/Drawings.js.map +1 -1
- package/lib/commonjs/dom/types/NodeType.d.ts +1 -0
- package/lib/commonjs/dom/types/NodeType.js +7 -11
- package/lib/commonjs/dom/types/NodeType.js.map +1 -1
- package/lib/commonjs/dom/types/SkDOM.d.ts +2 -1
- package/lib/commonjs/dom/types/SkDOM.js.map +1 -1
- package/lib/commonjs/dom/types/index.js +0 -26
- package/lib/commonjs/dom/types/index.js.map +1 -1
- package/lib/commonjs/external/index.js +0 -2
- package/lib/commonjs/external/index.js.map +1 -1
- package/lib/commonjs/external/reanimated/buffers.d.ts +5 -0
- package/lib/commonjs/external/reanimated/buffers.js +39 -0
- package/lib/commonjs/external/reanimated/buffers.js.map +1 -0
- package/lib/commonjs/external/reanimated/index.d.ts +1 -0
- package/lib/commonjs/external/reanimated/index.js +11 -10
- package/lib/commonjs/external/reanimated/index.js.map +1 -1
- package/lib/commonjs/external/reanimated/interpolators.d.ts +1 -1
- package/lib/commonjs/external/reanimated/interpolators.js +5 -20
- package/lib/commonjs/external/reanimated/interpolators.js.map +1 -1
- package/lib/commonjs/external/reanimated/moduleWrapper.js +12 -29
- package/lib/commonjs/external/reanimated/moduleWrapper.js.map +1 -1
- package/lib/commonjs/external/reanimated/renderHelpers.js +5 -31
- package/lib/commonjs/external/reanimated/renderHelpers.js.map +1 -1
- package/lib/commonjs/external/reanimated/textures.js +3 -25
- package/lib/commonjs/external/reanimated/textures.js.map +1 -1
- package/lib/commonjs/external/reanimated/useAnimatedImageValue.js +16 -14
- package/lib/commonjs/external/reanimated/useAnimatedImageValue.js.map +1 -1
- package/lib/commonjs/external/reanimated/useDerivedValueOnJS.js +0 -4
- package/lib/commonjs/external/reanimated/useDerivedValueOnJS.js.map +1 -1
- package/lib/commonjs/headless/index.js +1 -12
- package/lib/commonjs/headless/index.js.map +1 -1
- package/lib/commonjs/index.js +0 -20
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/mock/index.js +5 -6
- package/lib/commonjs/mock/index.js.map +1 -1
- package/lib/commonjs/renderer/Canvas.js +21 -46
- package/lib/commonjs/renderer/Canvas.js.map +1 -1
- package/lib/commonjs/renderer/Container.js +4 -15
- package/lib/commonjs/renderer/Container.js.map +1 -1
- package/lib/commonjs/renderer/HostComponents.d.ts +3 -1
- package/lib/commonjs/renderer/HostComponents.js +3 -64
- package/lib/commonjs/renderer/HostComponents.js.map +1 -1
- package/lib/commonjs/renderer/HostConfig.js +9 -38
- package/lib/commonjs/renderer/HostConfig.js.map +1 -1
- package/lib/commonjs/renderer/Offscreen.d.ts +4 -2
- package/lib/commonjs/renderer/Offscreen.js +19 -24
- package/lib/commonjs/renderer/Offscreen.js.map +1 -1
- package/lib/commonjs/renderer/Reconciler.js +4 -20
- package/lib/commonjs/renderer/Reconciler.js.map +1 -1
- package/lib/commonjs/renderer/components/Blend.js +0 -4
- package/lib/commonjs/renderer/components/Blend.js.map +1 -1
- package/lib/commonjs/renderer/components/Group.js +6 -15
- package/lib/commonjs/renderer/components/Group.js.map +1 -1
- package/lib/commonjs/renderer/components/Mask.js +6 -14
- package/lib/commonjs/renderer/components/Mask.js.map +1 -1
- package/lib/commonjs/renderer/components/Paint.js +0 -4
- package/lib/commonjs/renderer/components/Paint.js.map +1 -1
- package/lib/commonjs/renderer/components/Picture.js +0 -4
- package/lib/commonjs/renderer/components/Picture.js.map +1 -1
- package/lib/commonjs/renderer/components/backdrop/BackdropBlur.js +5 -13
- package/lib/commonjs/renderer/components/backdrop/BackdropBlur.js.map +1 -1
- package/lib/commonjs/renderer/components/backdrop/BackdropFilter.js +5 -11
- package/lib/commonjs/renderer/components/backdrop/BackdropFilter.js.map +1 -1
- package/lib/commonjs/renderer/components/backdrop/index.js +0 -4
- package/lib/commonjs/renderer/components/backdrop/index.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/BlendColor.js +0 -4
- package/lib/commonjs/renderer/components/colorFilters/BlendColor.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/Lerp.js +0 -4
- package/lib/commonjs/renderer/components/colorFilters/Lerp.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/LinearToSRGBGamma.js +0 -4
- package/lib/commonjs/renderer/components/colorFilters/LinearToSRGBGamma.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/LumaColorFilter.js +0 -4
- package/lib/commonjs/renderer/components/colorFilters/LumaColorFilter.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/Matrix.js +0 -6
- package/lib/commonjs/renderer/components/colorFilters/Matrix.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/SRGBToLinearGamma.js +0 -4
- package/lib/commonjs/renderer/components/colorFilters/SRGBToLinearGamma.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/index.js +0 -12
- package/lib/commonjs/renderer/components/colorFilters/index.js.map +1 -1
- package/lib/commonjs/renderer/components/image/Image.js +0 -4
- package/lib/commonjs/renderer/components/image/Image.js.map +1 -1
- package/lib/commonjs/renderer/components/image/ImageSVG.js +0 -4
- package/lib/commonjs/renderer/components/image/ImageSVG.js.map +1 -1
- package/lib/commonjs/renderer/components/image/ImageShader.js +9 -15
- package/lib/commonjs/renderer/components/image/ImageShader.js.map +1 -1
- package/lib/commonjs/renderer/components/image/index.js +0 -6
- package/lib/commonjs/renderer/components/image/index.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/Blur.js +4 -10
- package/lib/commonjs/renderer/components/imageFilters/Blur.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/DisplacementMap.js +0 -4
- package/lib/commonjs/renderer/components/imageFilters/DisplacementMap.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/Morphology.js +4 -10
- package/lib/commonjs/renderer/components/imageFilters/Morphology.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/Offset.js +5 -11
- package/lib/commonjs/renderer/components/imageFilters/Offset.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/RuntimeShader.js +0 -4
- package/lib/commonjs/renderer/components/imageFilters/RuntimeShader.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/Shadow.js +0 -4
- package/lib/commonjs/renderer/components/imageFilters/Shadow.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/index.js +0 -12
- package/lib/commonjs/renderer/components/imageFilters/index.js.map +1 -1
- package/lib/commonjs/renderer/components/index.js +0 -32
- package/lib/commonjs/renderer/components/index.js.map +1 -1
- package/lib/commonjs/renderer/components/maskFilters/Blur.js +5 -11
- package/lib/commonjs/renderer/components/maskFilters/Blur.js.map +1 -1
- package/lib/commonjs/renderer/components/maskFilters/index.js +0 -2
- package/lib/commonjs/renderer/components/maskFilters/index.js.map +1 -1
- package/lib/commonjs/renderer/components/paragraph/Paragraph.js +0 -4
- package/lib/commonjs/renderer/components/paragraph/Paragraph.js.map +1 -1
- package/lib/commonjs/renderer/components/paragraph/index.js +0 -2
- package/lib/commonjs/renderer/components/paragraph/index.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Corner.js +0 -4
- package/lib/commonjs/renderer/components/pathEffects/Corner.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Dash.js +0 -4
- package/lib/commonjs/renderer/components/pathEffects/Dash.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Discrete.js +4 -10
- package/lib/commonjs/renderer/components/pathEffects/Discrete.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Line2D.js +0 -4
- package/lib/commonjs/renderer/components/pathEffects/Line2D.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Path1D.js +0 -4
- package/lib/commonjs/renderer/components/pathEffects/Path1D.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Path2D.js +0 -4
- package/lib/commonjs/renderer/components/pathEffects/Path2D.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Sum.js +0 -4
- package/lib/commonjs/renderer/components/pathEffects/Sum.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/index.js +0 -14
- package/lib/commonjs/renderer/components/pathEffects/index.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/Color.js +0 -4
- package/lib/commonjs/renderer/components/shaders/Color.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/FractalNoise.js +6 -12
- package/lib/commonjs/renderer/components/shaders/FractalNoise.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/LinearGradient.js +0 -4
- package/lib/commonjs/renderer/components/shaders/LinearGradient.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/RadialGradient.js +0 -4
- package/lib/commonjs/renderer/components/shaders/RadialGradient.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/Shader.js +4 -10
- package/lib/commonjs/renderer/components/shaders/Shader.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/ShaderLib.js +1 -2
- package/lib/commonjs/renderer/components/shaders/ShaderLib.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/SweepGradient.js +0 -4
- package/lib/commonjs/renderer/components/shaders/SweepGradient.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/Turbulence.js +6 -12
- package/lib/commonjs/renderer/components/shaders/Turbulence.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/TwoPointConicalGradient.js +0 -4
- package/lib/commonjs/renderer/components/shaders/TwoPointConicalGradient.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/index.js +0 -18
- package/lib/commonjs/renderer/components/shaders/index.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Atlas.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/Atlas.js +13 -0
- package/lib/commonjs/renderer/components/shapes/Atlas.js.map +1 -0
- package/lib/commonjs/renderer/components/shapes/Box.js +0 -6
- package/lib/commonjs/renderer/components/shapes/Box.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Circle.js +0 -4
- package/lib/commonjs/renderer/components/shapes/Circle.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/DiffRect.js +0 -4
- package/lib/commonjs/renderer/components/shapes/DiffRect.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Fill.js +0 -4
- package/lib/commonjs/renderer/components/shapes/Fill.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/FitBox.js +8 -18
- package/lib/commonjs/renderer/components/shapes/FitBox.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Line.js +0 -4
- package/lib/commonjs/renderer/components/shapes/Line.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Oval.js +0 -4
- package/lib/commonjs/renderer/components/shapes/Oval.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Patch.js +0 -4
- package/lib/commonjs/renderer/components/shapes/Patch.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Path.js +5 -11
- package/lib/commonjs/renderer/components/shapes/Path.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Points.js +4 -10
- package/lib/commonjs/renderer/components/shapes/Points.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Rect.js +0 -4
- package/lib/commonjs/renderer/components/shapes/Rect.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/RoundedRect.js +0 -4
- package/lib/commonjs/renderer/components/shapes/RoundedRect.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Vertices.js +4 -10
- package/lib/commonjs/renderer/components/shapes/Vertices.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/index.d.ts +1 -0
- package/lib/commonjs/renderer/components/shapes/index.js +11 -26
- package/lib/commonjs/renderer/components/shapes/index.js.map +1 -1
- package/lib/commonjs/renderer/components/text/Glyphs.js +5 -11
- package/lib/commonjs/renderer/components/text/Glyphs.js.map +1 -1
- package/lib/commonjs/renderer/components/text/Text.js +5 -11
- package/lib/commonjs/renderer/components/text/Text.js.map +1 -1
- package/lib/commonjs/renderer/components/text/TextBlob.js +5 -11
- package/lib/commonjs/renderer/components/text/TextBlob.js.map +1 -1
- package/lib/commonjs/renderer/components/text/TextPath.js +4 -10
- package/lib/commonjs/renderer/components/text/TextPath.js.map +1 -1
- package/lib/commonjs/renderer/components/text/index.js +0 -8
- package/lib/commonjs/renderer/components/text/index.js.map +1 -1
- package/lib/commonjs/renderer/index.js +0 -2
- package/lib/commonjs/renderer/index.js.map +1 -1
- package/lib/commonjs/renderer/processors/Animations/index.js +0 -2
- package/lib/commonjs/renderer/processors/Animations/index.js.map +1 -1
- package/lib/commonjs/renderer/processors/index.js +0 -4
- package/lib/commonjs/renderer/processors/index.js.map +1 -1
- package/lib/commonjs/renderer/processors/math/Coordinates.js +0 -12
- package/lib/commonjs/renderer/processors/math/Coordinates.js.map +1 -1
- package/lib/commonjs/renderer/processors/math/Math.js +1 -7
- package/lib/commonjs/renderer/processors/math/Math.js.map +1 -1
- package/lib/commonjs/renderer/processors/math/Transforms.js +0 -3
- package/lib/commonjs/renderer/processors/math/Transforms.js.map +1 -1
- package/lib/commonjs/renderer/processors/math/index.js +0 -6
- package/lib/commonjs/renderer/processors/math/index.js.map +1 -1
- package/lib/commonjs/renderer/typeddash.js +2 -11
- package/lib/commonjs/renderer/typeddash.js.map +1 -1
- package/lib/commonjs/skia/NativeSetup.js +0 -6
- package/lib/commonjs/skia/NativeSetup.js.map +1 -1
- package/lib/commonjs/skia/Skia.js +2 -3
- package/lib/commonjs/skia/Skia.js.map +1 -1
- package/lib/commonjs/skia/Skia.web.js +1 -4
- package/lib/commonjs/skia/Skia.web.js.map +1 -1
- package/lib/commonjs/skia/core/AnimatedImage.d.ts +1 -1
- package/lib/commonjs/skia/core/AnimatedImage.js +2 -7
- package/lib/commonjs/skia/core/AnimatedImage.js.map +1 -1
- package/lib/commonjs/skia/core/Data.d.ts +1 -1
- package/lib/commonjs/skia/core/Data.js +12 -25
- package/lib/commonjs/skia/core/Data.js.map +1 -1
- package/lib/commonjs/skia/core/Font.js +10 -36
- package/lib/commonjs/skia/core/Font.js.map +1 -1
- package/lib/commonjs/skia/core/Image.js +3 -16
- package/lib/commonjs/skia/core/Image.js.map +1 -1
- package/lib/commonjs/skia/core/Matrix.js +0 -4
- package/lib/commonjs/skia/core/Matrix.js.map +1 -1
- package/lib/commonjs/skia/core/Picture.js +0 -7
- package/lib/commonjs/skia/core/Picture.js.map +1 -1
- package/lib/commonjs/skia/core/RRect.js +0 -3
- package/lib/commonjs/skia/core/RRect.js.map +1 -1
- package/lib/commonjs/skia/core/Rect.d.ts +2 -2
- package/lib/commonjs/skia/core/Rect.js +0 -17
- package/lib/commonjs/skia/core/Rect.js.map +1 -1
- package/lib/commonjs/skia/core/SVG.js +0 -5
- package/lib/commonjs/skia/core/SVG.js.map +1 -1
- package/lib/commonjs/skia/core/Typeface.js +1 -6
- package/lib/commonjs/skia/core/Typeface.js.map +1 -1
- package/lib/commonjs/skia/core/Vector.js +3 -17
- package/lib/commonjs/skia/core/Vector.js.map +1 -1
- package/lib/commonjs/skia/core/index.js +0 -22
- package/lib/commonjs/skia/core/index.js.map +1 -1
- package/lib/commonjs/skia/index.js +0 -5
- package/lib/commonjs/skia/index.js.map +1 -1
- package/lib/commonjs/skia/types/AnimatedImage/index.js +0 -4
- package/lib/commonjs/skia/types/AnimatedImage/index.js.map +1 -1
- package/lib/commonjs/skia/types/Canvas.d.ts +16 -1
- package/lib/commonjs/skia/types/Canvas.js +6 -11
- package/lib/commonjs/skia/types/Canvas.js.map +1 -1
- package/lib/commonjs/skia/types/ColorFilter/ColorFilter.js +0 -2
- package/lib/commonjs/skia/types/ColorFilter/ColorFilter.js.map +1 -1
- package/lib/commonjs/skia/types/ColorFilter/index.js +0 -4
- package/lib/commonjs/skia/types/ColorFilter/index.js.map +1 -1
- package/lib/commonjs/skia/types/Data/Data.js +0 -2
- package/lib/commonjs/skia/types/Data/Data.js.map +1 -1
- package/lib/commonjs/skia/types/Data/index.js +0 -4
- package/lib/commonjs/skia/types/Data/index.js.map +1 -1
- package/lib/commonjs/skia/types/Font/Font.js +16 -34
- package/lib/commonjs/skia/types/Font/Font.js.map +1 -1
- package/lib/commonjs/skia/types/Font/index.js +0 -6
- package/lib/commonjs/skia/types/Font/index.js.map +1 -1
- package/lib/commonjs/skia/types/Image/Image.d.ts +8 -0
- package/lib/commonjs/skia/types/Image/Image.js +9 -17
- package/lib/commonjs/skia/types/Image/Image.js.map +1 -1
- package/lib/commonjs/skia/types/Image/ImageFactory.js +6 -11
- package/lib/commonjs/skia/types/Image/ImageFactory.js.map +1 -1
- package/lib/commonjs/skia/types/Image/index.js +0 -4
- package/lib/commonjs/skia/types/Image/index.js.map +1 -1
- package/lib/commonjs/skia/types/ImageFilter/ImageFilter.js +3 -7
- package/lib/commonjs/skia/types/ImageFilter/ImageFilter.js.map +1 -1
- package/lib/commonjs/skia/types/ImageFilter/ImageFilterFactory.js +3 -5
- package/lib/commonjs/skia/types/ImageFilter/ImageFilterFactory.js.map +1 -1
- package/lib/commonjs/skia/types/ImageFilter/index.js +0 -4
- package/lib/commonjs/skia/types/ImageFilter/index.js.map +1 -1
- package/lib/commonjs/skia/types/MaskFilter.js +4 -8
- package/lib/commonjs/skia/types/MaskFilter.js.map +1 -1
- package/lib/commonjs/skia/types/Matrix.js +0 -7
- package/lib/commonjs/skia/types/Matrix.js.map +1 -1
- package/lib/commonjs/skia/types/Matrix4.js +22 -90
- package/lib/commonjs/skia/types/Matrix4.js.map +1 -1
- package/lib/commonjs/skia/types/Paint/BlendMode.js +3 -6
- package/lib/commonjs/skia/types/Paint/BlendMode.js.map +1 -1
- package/lib/commonjs/skia/types/Paint/Paint.js +9 -19
- package/lib/commonjs/skia/types/Paint/Paint.js.map +1 -1
- package/lib/commonjs/skia/types/Paint/index.js +0 -4
- package/lib/commonjs/skia/types/Paint/index.js.map +1 -1
- package/lib/commonjs/skia/types/Paragraph/ParagraphBuilder.js +3 -5
- package/lib/commonjs/skia/types/Paragraph/ParagraphBuilder.js.map +1 -1
- package/lib/commonjs/skia/types/Paragraph/ParagraphStyle.js +9 -17
- package/lib/commonjs/skia/types/Paragraph/ParagraphStyle.js.map +1 -1
- package/lib/commonjs/skia/types/Paragraph/TextStyle.js +9 -17
- package/lib/commonjs/skia/types/Paragraph/TextStyle.js.map +1 -1
- package/lib/commonjs/skia/types/Paragraph/index.js +0 -12
- package/lib/commonjs/skia/types/Paragraph/index.js.map +1 -1
- package/lib/commonjs/skia/types/Path/Path.js +9 -20
- package/lib/commonjs/skia/types/Path/Path.js.map +1 -1
- package/lib/commonjs/skia/types/Path/index.js +0 -4
- package/lib/commonjs/skia/types/Path/index.js.map +1 -1
- package/lib/commonjs/skia/types/PathEffect.js +3 -7
- package/lib/commonjs/skia/types/PathEffect.js.map +1 -1
- package/lib/commonjs/skia/types/Picture/index.js +0 -6
- package/lib/commonjs/skia/types/Picture/index.js.map +1 -1
- package/lib/commonjs/skia/types/Point.js +3 -5
- package/lib/commonjs/skia/types/Point.js.map +1 -1
- package/lib/commonjs/skia/types/RRect.js +2 -3
- package/lib/commonjs/skia/types/RRect.js.map +1 -1
- package/lib/commonjs/skia/types/RSXform.d.ts +7 -1
- package/lib/commonjs/skia/types/RSXform.js.map +1 -1
- package/lib/commonjs/skia/types/Rect.d.ts +4 -0
- package/lib/commonjs/skia/types/Rect.js +0 -3
- package/lib/commonjs/skia/types/Rect.js.map +1 -1
- package/lib/commonjs/skia/types/RuntimeEffect/index.js +0 -4
- package/lib/commonjs/skia/types/RuntimeEffect/index.js.map +1 -1
- package/lib/commonjs/skia/types/SVG/index.js +0 -4
- package/lib/commonjs/skia/types/SVG/index.js.map +1 -1
- package/lib/commonjs/skia/types/Shader/Shader.js +4 -12
- package/lib/commonjs/skia/types/Shader/Shader.js.map +1 -1
- package/lib/commonjs/skia/types/Shader/index.js +0 -4
- package/lib/commonjs/skia/types/Shader/index.js.map +1 -1
- package/lib/commonjs/skia/types/Skia.d.ts +3 -2
- package/lib/commonjs/skia/types/Skia.js.map +1 -1
- package/lib/commonjs/skia/types/Surface/index.js +0 -4
- package/lib/commonjs/skia/types/Surface/index.js.map +1 -1
- package/lib/commonjs/skia/types/Typeface/index.js +0 -4
- package/lib/commonjs/skia/types/Typeface/index.js.map +1 -1
- package/lib/commonjs/skia/types/Vertices/Vertices.js +3 -5
- package/lib/commonjs/skia/types/Vertices/Vertices.js.map +1 -1
- package/lib/commonjs/skia/types/Vertices/index.js +0 -2
- package/lib/commonjs/skia/types/Vertices/index.js.map +1 -1
- package/lib/commonjs/skia/types/index.js +0 -62
- package/lib/commonjs/skia/types/index.js.map +1 -1
- package/lib/commonjs/skia/web/Host.js +7 -29
- package/lib/commonjs/skia/web/Host.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkAnimatedImage.js +3 -13
- package/lib/commonjs/skia/web/JsiSkAnimatedImage.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkAnimatedImageFactory.js +0 -9
- package/lib/commonjs/skia/web/JsiSkAnimatedImageFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkCanvas.d.ts +2 -1
- package/lib/commonjs/skia/web/JsiSkCanvas.js +25 -72
- package/lib/commonjs/skia/web/JsiSkCanvas.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkColor.js +10 -54
- package/lib/commonjs/skia/web/JsiSkColor.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkColorFilter.js +3 -7
- package/lib/commonjs/skia/web/JsiSkColorFilter.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkColorFilterFactory.js +0 -12
- package/lib/commonjs/skia/web/JsiSkColorFilterFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkContourMeasure.js +3 -13
- package/lib/commonjs/skia/web/JsiSkContourMeasure.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkContourMeasureIter.js +3 -11
- package/lib/commonjs/skia/web/JsiSkContourMeasureIter.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkData.js +5 -8
- package/lib/commonjs/skia/web/JsiSkData.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkDataFactory.js +0 -10
- package/lib/commonjs/skia/web/JsiSkDataFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkFont.js +5 -33
- package/lib/commonjs/skia/web/JsiSkFont.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkFontMgr.js +0 -8
- package/lib/commonjs/skia/web/JsiSkFontMgr.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkFontMgrFactory.js +0 -8
- package/lib/commonjs/skia/web/JsiSkFontMgrFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkImage.js +11 -33
- package/lib/commonjs/skia/web/JsiSkImage.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkImageFactory.js +2 -15
- package/lib/commonjs/skia/web/JsiSkImageFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkImageFilter.js +3 -7
- package/lib/commonjs/skia/web/JsiSkImageFilter.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkImageFilterFactory.js +0 -28
- package/lib/commonjs/skia/web/JsiSkImageFilterFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkMaskFilter.js +3 -7
- package/lib/commonjs/skia/web/JsiSkMaskFilter.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkMaskFilterFactory.js +0 -6
- package/lib/commonjs/skia/web/JsiSkMaskFilterFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkMatrix.js +9 -26
- package/lib/commonjs/skia/web/JsiSkMatrix.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkPaint.js +3 -35
- package/lib/commonjs/skia/web/JsiSkPaint.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkParagraph.js +21 -47
- package/lib/commonjs/skia/web/JsiSkParagraph.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkParagraphBuilder.js +4 -26
- package/lib/commonjs/skia/web/JsiSkParagraphBuilder.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkParagraphBuilderFactory.js +1 -11
- package/lib/commonjs/skia/web/JsiSkParagraphBuilderFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkParagraphStyle.js +19 -24
- package/lib/commonjs/skia/web/JsiSkParagraphStyle.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkPath.js +4 -77
- package/lib/commonjs/skia/web/JsiSkPath.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkPathEffect.js +3 -7
- package/lib/commonjs/skia/web/JsiSkPathEffect.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkPathEffectFactory.js +0 -23
- package/lib/commonjs/skia/web/JsiSkPathEffectFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkPathFactory.js +0 -16
- package/lib/commonjs/skia/web/JsiSkPathFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkPicture.js +3 -13
- package/lib/commonjs/skia/web/JsiSkPicture.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkPictureFactory.js +0 -8
- package/lib/commonjs/skia/web/JsiSkPictureFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkPictureRecorder.js +4 -13
- package/lib/commonjs/skia/web/JsiSkPictureRecorder.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkPoint.js +5 -12
- package/lib/commonjs/skia/web/JsiSkPoint.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkRRect.js +5 -17
- package/lib/commonjs/skia/web/JsiSkRRect.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkRSXform.d.ts +8 -2
- package/lib/commonjs/skia/web/JsiSkRSXform.js +30 -9
- package/lib/commonjs/skia/web/JsiSkRSXform.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkRect.d.ts +3 -2
- package/lib/commonjs/skia/web/JsiSkRect.js +11 -14
- package/lib/commonjs/skia/web/JsiSkRect.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkRuntimeEffect.js +3 -16
- package/lib/commonjs/skia/web/JsiSkRuntimeEffect.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkRuntimeEffectFactory.js +0 -8
- package/lib/commonjs/skia/web/JsiSkRuntimeEffectFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkSVGFactory.js +0 -6
- package/lib/commonjs/skia/web/JsiSkSVGFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkShader.js +3 -7
- package/lib/commonjs/skia/web/JsiSkShader.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkShaderFactory.js +0 -15
- package/lib/commonjs/skia/web/JsiSkShaderFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkSurface.js +3 -13
- package/lib/commonjs/skia/web/JsiSkSurface.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkSurfaceFactory.js +0 -14
- package/lib/commonjs/skia/web/JsiSkSurfaceFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkTextBlob.js +3 -7
- package/lib/commonjs/skia/web/JsiSkTextBlob.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkTextBlobFactory.js +2 -12
- package/lib/commonjs/skia/web/JsiSkTextBlobFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkTextStyle.js +0 -3
- package/lib/commonjs/skia/web/JsiSkTextStyle.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkTypeface.js +3 -10
- package/lib/commonjs/skia/web/JsiSkTypeface.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkTypefaceFactory.js +0 -8
- package/lib/commonjs/skia/web/JsiSkTypefaceFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkTypefaceFontProvider.js +16 -26
- package/lib/commonjs/skia/web/JsiSkTypefaceFontProvider.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkTypefaceFontProviderFactory.js +0 -6
- package/lib/commonjs/skia/web/JsiSkTypefaceFontProviderFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkVertices.js +3 -10
- package/lib/commonjs/skia/web/JsiSkVertices.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkVerticesFactory.js +8 -27
- package/lib/commonjs/skia/web/JsiSkVerticesFactory.js.map +1 -1
- package/lib/commonjs/skia/web/JsiSkia.js +5 -33
- package/lib/commonjs/skia/web/JsiSkia.js.map +1 -1
- package/lib/commonjs/skia/web/index.js +0 -2
- package/lib/commonjs/skia/web/index.js.map +1 -1
- package/lib/commonjs/specs/NativeSkiaModule.js +1 -5
- package/lib/commonjs/specs/NativeSkiaModule.js.map +1 -1
- package/lib/commonjs/specs/NativeSkiaModule.web.js +1 -4
- package/lib/commonjs/specs/NativeSkiaModule.web.js.map +1 -1
- package/lib/commonjs/specs/SkiaDomViewNativeComponent.js +1 -6
- package/lib/commonjs/specs/SkiaDomViewNativeComponent.js.map +1 -1
- package/lib/commonjs/specs/SkiaPictureViewNativeComponent.js +1 -6
- package/lib/commonjs/specs/SkiaPictureViewNativeComponent.js.map +1 -1
- package/lib/commonjs/views/SkiaBaseWebView.js +18 -66
- package/lib/commonjs/views/SkiaBaseWebView.js.map +1 -1
- package/lib/commonjs/views/SkiaDomView.js +8 -40
- package/lib/commonjs/views/SkiaDomView.js.map +1 -1
- package/lib/commonjs/views/SkiaDomView.web.js +0 -9
- package/lib/commonjs/views/SkiaDomView.web.js.map +1 -1
- package/lib/commonjs/views/SkiaJSDomView.js +10 -43
- package/lib/commonjs/views/SkiaJSDomView.js.map +1 -1
- package/lib/commonjs/views/SkiaJSDomView.web.js +0 -1
- package/lib/commonjs/views/SkiaJSDomView.web.js.map +1 -1
- package/lib/commonjs/views/SkiaPictureView.js +6 -32
- package/lib/commonjs/views/SkiaPictureView.js.map +1 -1
- package/lib/commonjs/views/SkiaPictureView.web.js +0 -5
- package/lib/commonjs/views/SkiaPictureView.web.js.map +1 -1
- package/lib/commonjs/views/SkiaViewNativeId.js +1 -2
- package/lib/commonjs/views/SkiaViewNativeId.js.map +1 -1
- package/lib/commonjs/views/api.js.map +1 -1
- package/lib/commonjs/views/index.js +0 -8
- package/lib/commonjs/views/index.js.map +1 -1
- package/lib/commonjs/views/types.js +3 -5
- package/lib/commonjs/views/types.js.map +1 -1
- package/lib/commonjs/views/useTouchHandler.js +19 -33
- package/lib/commonjs/views/useTouchHandler.js.map +1 -1
- package/lib/commonjs/web/LoadSkiaWeb.js +8 -12
- package/lib/commonjs/web/LoadSkiaWeb.js.map +1 -1
- package/lib/commonjs/web/WithSkiaWeb.js +10 -18
- package/lib/commonjs/web/WithSkiaWeb.js.map +1 -1
- package/lib/commonjs/web/index.js +0 -4
- package/lib/commonjs/web/index.js.map +1 -1
- package/lib/module/Platform/Platform.js.map +1 -1
- package/lib/module/Platform/Platform.web.js +7 -23
- package/lib/module/Platform/Platform.web.js.map +1 -1
- package/lib/module/Platform/index.js.map +1 -1
- package/lib/module/animation/functions/index.js.map +1 -1
- package/lib/module/animation/functions/interpolate.js +12 -29
- package/lib/module/animation/functions/interpolate.js.map +1 -1
- package/lib/module/animation/functions/interpolateColors.js +2 -5
- package/lib/module/animation/functions/interpolateColors.js.map +1 -1
- package/lib/module/animation/functions/interpolatePaths.js +1 -13
- package/lib/module/animation/functions/interpolatePaths.js.map +1 -1
- package/lib/module/animation/functions/interpolateVector.js.map +1 -1
- package/lib/module/animation/index.js.map +1 -1
- package/lib/module/dom/nodes/DrawingNode.js +7 -17
- package/lib/module/dom/nodes/DrawingNode.js.map +1 -1
- package/lib/module/dom/nodes/GroupNode.js +0 -2
- package/lib/module/dom/nodes/GroupNode.js.map +1 -1
- package/lib/module/dom/nodes/JsiSkDOM.d.ts +2 -1
- package/lib/module/dom/nodes/JsiSkDOM.js +18 -65
- package/lib/module/dom/nodes/JsiSkDOM.js.map +1 -1
- package/lib/module/dom/nodes/LayerNode.js +0 -6
- package/lib/module/dom/nodes/LayerNode.js.map +1 -1
- package/lib/module/dom/nodes/Node.js +4 -32
- package/lib/module/dom/nodes/Node.js.map +1 -1
- package/lib/module/dom/nodes/PaintNode.js +1 -23
- package/lib/module/dom/nodes/PaintNode.js.map +1 -1
- package/lib/module/dom/nodes/RenderNode.js +3 -29
- package/lib/module/dom/nodes/RenderNode.js.map +1 -1
- package/lib/module/dom/nodes/datatypes/Circle.js +4 -4
- package/lib/module/dom/nodes/datatypes/Circle.js.map +1 -1
- package/lib/module/dom/nodes/datatypes/Enum.js.map +1 -1
- package/lib/module/dom/nodes/datatypes/Fitting.js +15 -39
- package/lib/module/dom/nodes/datatypes/Fitting.js.map +1 -1
- package/lib/module/dom/nodes/datatypes/Gradient.js +7 -9
- package/lib/module/dom/nodes/datatypes/Gradient.js.map +1 -1
- package/lib/module/dom/nodes/datatypes/Path.js +2 -3
- package/lib/module/dom/nodes/datatypes/Path.js.map +1 -1
- package/lib/module/dom/nodes/datatypes/Radius.js +0 -1
- package/lib/module/dom/nodes/datatypes/Radius.js.map +1 -1
- package/lib/module/dom/nodes/datatypes/Rect.js +5 -7
- package/lib/module/dom/nodes/datatypes/Rect.js.map +1 -1
- package/lib/module/dom/nodes/datatypes/Transform.js +0 -3
- package/lib/module/dom/nodes/datatypes/Transform.js.map +1 -1
- package/lib/module/dom/nodes/datatypes/index.js.map +1 -1
- package/lib/module/dom/nodes/drawings/AtlasNode.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/AtlasNode.js +29 -0
- package/lib/module/dom/nodes/drawings/AtlasNode.js.map +1 -0
- package/lib/module/dom/nodes/drawings/BackdropFilterNode.js +4 -13
- package/lib/module/dom/nodes/drawings/BackdropFilterNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/Box.js +8 -27
- package/lib/module/dom/nodes/drawings/Box.js.map +1 -1
- package/lib/module/dom/nodes/drawings/CircleNode.js +4 -10
- package/lib/module/dom/nodes/drawings/CircleNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/DiffRectNode.js +4 -8
- package/lib/module/dom/nodes/drawings/DiffRectNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/FillNode.js +5 -10
- package/lib/module/dom/nodes/drawings/FillNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/ImageNode.js +4 -14
- package/lib/module/dom/nodes/drawings/ImageNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/ImageSVG.js +3 -14
- package/lib/module/dom/nodes/drawings/ImageSVG.js.map +1 -1
- package/lib/module/dom/nodes/drawings/LineNode.js +4 -8
- package/lib/module/dom/nodes/drawings/LineNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/OvalNode.js +4 -10
- package/lib/module/dom/nodes/drawings/OvalNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/ParagraphNode.js +3 -8
- package/lib/module/dom/nodes/drawings/ParagraphNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/PatchNode.js +6 -12
- package/lib/module/dom/nodes/drawings/PatchNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/PathNode.js +4 -14
- package/lib/module/dom/nodes/drawings/PathNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/PictureNode.js +3 -7
- package/lib/module/dom/nodes/drawings/PictureNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/PointsNode.js +4 -8
- package/lib/module/dom/nodes/drawings/PointsNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/RRectNode.js +7 -13
- package/lib/module/dom/nodes/drawings/RRectNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/RectNode.js +4 -10
- package/lib/module/dom/nodes/drawings/RectNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/Text.js +18 -51
- package/lib/module/dom/nodes/drawings/Text.js.map +1 -1
- package/lib/module/dom/nodes/drawings/VerticesNode.js +4 -10
- package/lib/module/dom/nodes/drawings/VerticesNode.js.map +1 -1
- package/lib/module/dom/nodes/drawings/index.d.ts +1 -0
- package/lib/module/dom/nodes/drawings/index.js +1 -0
- package/lib/module/dom/nodes/drawings/index.js.map +1 -1
- package/lib/module/dom/nodes/index.js.map +1 -1
- package/lib/module/dom/nodes/paint/BlendNode.js +4 -9
- package/lib/module/dom/nodes/paint/BlendNode.js.map +1 -1
- package/lib/module/dom/nodes/paint/ColorFilters.js +0 -16
- package/lib/module/dom/nodes/paint/ColorFilters.js.map +1 -1
- package/lib/module/dom/nodes/paint/ImageFilters.js +3 -40
- package/lib/module/dom/nodes/paint/ImageFilters.js.map +1 -1
- package/lib/module/dom/nodes/paint/MaskFilters.js +0 -2
- package/lib/module/dom/nodes/paint/MaskFilters.js.map +1 -1
- package/lib/module/dom/nodes/paint/PathEffects.js +0 -26
- package/lib/module/dom/nodes/paint/PathEffects.js.map +1 -1
- package/lib/module/dom/nodes/paint/Shaders.js +0 -23
- package/lib/module/dom/nodes/paint/Shaders.js.map +1 -1
- package/lib/module/dom/nodes/paint/index.js.map +1 -1
- package/lib/module/dom/types/DeclarationContext.js +3 -27
- package/lib/module/dom/types/DeclarationContext.js.map +1 -1
- package/lib/module/dom/types/DrawingContext.js +3 -85
- package/lib/module/dom/types/DrawingContext.js.map +1 -1
- package/lib/module/dom/types/Drawings.d.ts +7 -1
- package/lib/module/dom/types/Drawings.js.map +1 -1
- package/lib/module/dom/types/NodeType.d.ts +1 -0
- package/lib/module/dom/types/NodeType.js +7 -9
- package/lib/module/dom/types/NodeType.js.map +1 -1
- package/lib/module/dom/types/SkDOM.d.ts +2 -1
- package/lib/module/dom/types/SkDOM.js.map +1 -1
- package/lib/module/dom/types/index.js.map +1 -1
- package/lib/module/external/index.js.map +1 -1
- package/lib/module/external/reanimated/buffers.d.ts +5 -0
- package/lib/module/external/reanimated/buffers.js +29 -0
- package/lib/module/external/reanimated/buffers.js.map +1 -0
- package/lib/module/external/reanimated/index.d.ts +1 -0
- package/lib/module/external/reanimated/index.js +1 -0
- package/lib/module/external/reanimated/index.js.map +1 -1
- package/lib/module/external/reanimated/interpolators.d.ts +1 -1
- package/lib/module/external/reanimated/interpolators.js +5 -4
- package/lib/module/external/reanimated/interpolators.js.map +1 -1
- package/lib/module/external/reanimated/moduleWrapper.js +2 -4
- package/lib/module/external/reanimated/moduleWrapper.js.map +1 -1
- package/lib/module/external/reanimated/renderHelpers.js +5 -28
- package/lib/module/external/reanimated/renderHelpers.js.map +1 -1
- package/lib/module/external/reanimated/textures.js +5 -18
- package/lib/module/external/reanimated/textures.js.map +1 -1
- package/lib/module/external/reanimated/useAnimatedImageValue.js +16 -9
- package/lib/module/external/reanimated/useAnimatedImageValue.js.map +1 -1
- package/lib/module/external/reanimated/useDerivedValueOnJS.js.map +1 -1
- package/lib/module/headless/index.js +3 -4
- package/lib/module/headless/index.js.map +1 -1
- package/lib/module/index.js.map +1 -1
- package/lib/module/mock/index.js +7 -4
- package/lib/module/mock/index.js.map +1 -1
- package/lib/module/renderer/Canvas.js +17 -28
- package/lib/module/renderer/Canvas.js.map +1 -1
- package/lib/module/renderer/Container.js +4 -12
- package/lib/module/renderer/Container.js.map +1 -1
- package/lib/module/renderer/HostComponents.d.ts +3 -1
- package/lib/module/renderer/HostComponents.js +2 -57
- package/lib/module/renderer/HostComponents.js.map +1 -1
- package/lib/module/renderer/HostConfig.js +8 -29
- package/lib/module/renderer/HostConfig.js.map +1 -1
- package/lib/module/renderer/Offscreen.d.ts +4 -2
- package/lib/module/renderer/Offscreen.js +16 -13
- package/lib/module/renderer/Offscreen.js.map +1 -1
- package/lib/module/renderer/Reconciler.js +4 -13
- package/lib/module/renderer/Reconciler.js.map +1 -1
- package/lib/module/renderer/components/Blend.js.map +1 -1
- package/lib/module/renderer/components/Group.js +4 -8
- package/lib/module/renderer/components/Group.js.map +1 -1
- package/lib/module/renderer/components/Mask.js +6 -7
- package/lib/module/renderer/components/Mask.js.map +1 -1
- package/lib/module/renderer/components/Paint.js.map +1 -1
- package/lib/module/renderer/components/Picture.js.map +1 -1
- package/lib/module/renderer/components/backdrop/BackdropBlur.js +5 -7
- package/lib/module/renderer/components/backdrop/BackdropBlur.js.map +1 -1
- package/lib/module/renderer/components/backdrop/BackdropFilter.js +5 -6
- package/lib/module/renderer/components/backdrop/BackdropFilter.js.map +1 -1
- package/lib/module/renderer/components/backdrop/index.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/BlendColor.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/Lerp.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/LinearToSRGBGamma.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/LumaColorFilter.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/Matrix.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/SRGBToLinearGamma.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/index.js.map +1 -1
- package/lib/module/renderer/components/image/Image.js.map +1 -1
- package/lib/module/renderer/components/image/ImageSVG.js.map +1 -1
- package/lib/module/renderer/components/image/ImageShader.js +9 -11
- package/lib/module/renderer/components/image/ImageShader.js.map +1 -1
- package/lib/module/renderer/components/image/index.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/Blur.js +4 -6
- package/lib/module/renderer/components/imageFilters/Blur.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/DisplacementMap.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/Morphology.js +4 -6
- package/lib/module/renderer/components/imageFilters/Morphology.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/Offset.js +5 -7
- package/lib/module/renderer/components/imageFilters/Offset.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/RuntimeShader.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/Shadow.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/index.js.map +1 -1
- package/lib/module/renderer/components/index.js.map +1 -1
- package/lib/module/renderer/components/maskFilters/Blur.js +5 -7
- package/lib/module/renderer/components/maskFilters/Blur.js.map +1 -1
- package/lib/module/renderer/components/maskFilters/index.js.map +1 -1
- package/lib/module/renderer/components/paragraph/Paragraph.js.map +1 -1
- package/lib/module/renderer/components/paragraph/index.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Corner.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Dash.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Discrete.js +4 -6
- package/lib/module/renderer/components/pathEffects/Discrete.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Line2D.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Path1D.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Path2D.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Sum.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/index.js.map +1 -1
- package/lib/module/renderer/components/shaders/Color.js.map +1 -1
- package/lib/module/renderer/components/shaders/FractalNoise.js +6 -8
- package/lib/module/renderer/components/shaders/FractalNoise.js.map +1 -1
- package/lib/module/renderer/components/shaders/LinearGradient.js.map +1 -1
- package/lib/module/renderer/components/shaders/RadialGradient.js.map +1 -1
- package/lib/module/renderer/components/shaders/Shader.js +4 -6
- package/lib/module/renderer/components/shaders/Shader.js.map +1 -1
- package/lib/module/renderer/components/shaders/ShaderLib.js.map +1 -1
- package/lib/module/renderer/components/shaders/SweepGradient.js.map +1 -1
- package/lib/module/renderer/components/shaders/Turbulence.js +6 -8
- package/lib/module/renderer/components/shaders/Turbulence.js.map +1 -1
- package/lib/module/renderer/components/shaders/TwoPointConicalGradient.js.map +1 -1
- package/lib/module/renderer/components/shaders/index.js.map +1 -1
- package/lib/module/renderer/components/shapes/Atlas.d.ts +4 -0
- package/lib/module/renderer/components/shapes/Atlas.js +5 -0
- package/lib/module/renderer/components/shapes/Atlas.js.map +1 -0
- package/lib/module/renderer/components/shapes/Box.js.map +1 -1
- package/lib/module/renderer/components/shapes/Circle.js.map +1 -1
- package/lib/module/renderer/components/shapes/DiffRect.js.map +1 -1
- package/lib/module/renderer/components/shapes/Fill.js.map +1 -1
- package/lib/module/renderer/components/shapes/FitBox.js +6 -7
- package/lib/module/renderer/components/shapes/FitBox.js.map +1 -1
- package/lib/module/renderer/components/shapes/Line.js.map +1 -1
- package/lib/module/renderer/components/shapes/Oval.js.map +1 -1
- package/lib/module/renderer/components/shapes/Patch.js.map +1 -1
- package/lib/module/renderer/components/shapes/Path.js +5 -7
- package/lib/module/renderer/components/shapes/Path.js.map +1 -1
- package/lib/module/renderer/components/shapes/Points.js +4 -6
- package/lib/module/renderer/components/shapes/Points.js.map +1 -1
- package/lib/module/renderer/components/shapes/Rect.js.map +1 -1
- package/lib/module/renderer/components/shapes/RoundedRect.js.map +1 -1
- package/lib/module/renderer/components/shapes/Vertices.js +4 -6
- package/lib/module/renderer/components/shapes/Vertices.js.map +1 -1
- package/lib/module/renderer/components/shapes/index.d.ts +1 -0
- package/lib/module/renderer/components/shapes/index.js +1 -0
- package/lib/module/renderer/components/shapes/index.js.map +1 -1
- package/lib/module/renderer/components/text/Glyphs.js +5 -7
- package/lib/module/renderer/components/text/Glyphs.js.map +1 -1
- package/lib/module/renderer/components/text/Text.js +5 -7
- package/lib/module/renderer/components/text/Text.js.map +1 -1
- package/lib/module/renderer/components/text/TextBlob.js +5 -7
- package/lib/module/renderer/components/text/TextBlob.js.map +1 -1
- package/lib/module/renderer/components/text/TextPath.js +4 -6
- package/lib/module/renderer/components/text/TextPath.js.map +1 -1
- package/lib/module/renderer/components/text/index.js.map +1 -1
- package/lib/module/renderer/index.js.map +1 -1
- package/lib/module/renderer/processors/Animations/index.js.map +1 -1
- package/lib/module/renderer/processors/index.js.map +1 -1
- package/lib/module/renderer/processors/math/Coordinates.js.map +1 -1
- package/lib/module/renderer/processors/math/Math.js +1 -1
- package/lib/module/renderer/processors/math/Math.js.map +1 -1
- package/lib/module/renderer/processors/math/Transforms.js.map +1 -1
- package/lib/module/renderer/processors/math/index.js.map +1 -1
- package/lib/module/renderer/typeddash.js +2 -5
- package/lib/module/renderer/typeddash.js.map +1 -1
- package/lib/module/skia/NativeSetup.js +0 -4
- package/lib/module/skia/NativeSetup.js.map +1 -1
- package/lib/module/skia/Skia.js +1 -0
- package/lib/module/skia/Skia.js.map +1 -1
- package/lib/module/skia/Skia.web.js.map +1 -1
- package/lib/module/skia/core/AnimatedImage.d.ts +1 -1
- package/lib/module/skia/core/AnimatedImage.js +2 -2
- package/lib/module/skia/core/AnimatedImage.js.map +1 -1
- package/lib/module/skia/core/Data.d.ts +1 -1
- package/lib/module/skia/core/Data.js +12 -17
- package/lib/module/skia/core/Data.js.map +1 -1
- package/lib/module/skia/core/Font.js +9 -24
- package/lib/module/skia/core/Font.js.map +1 -1
- package/lib/module/skia/core/Image.js +3 -8
- package/lib/module/skia/core/Image.js.map +1 -1
- package/lib/module/skia/core/Matrix.js.map +1 -1
- package/lib/module/skia/core/Picture.js +1 -3
- package/lib/module/skia/core/Picture.js.map +1 -1
- package/lib/module/skia/core/RRect.js.map +1 -1
- package/lib/module/skia/core/Rect.d.ts +2 -2
- package/lib/module/skia/core/Rect.js.map +1 -1
- package/lib/module/skia/core/SVG.js.map +1 -1
- package/lib/module/skia/core/Typeface.js +1 -1
- package/lib/module/skia/core/Typeface.js.map +1 -1
- package/lib/module/skia/core/Vector.js +1 -3
- package/lib/module/skia/core/Vector.js.map +1 -1
- package/lib/module/skia/core/index.js.map +1 -1
- package/lib/module/skia/index.js.map +1 -1
- package/lib/module/skia/types/AnimatedImage/index.js.map +1 -1
- package/lib/module/skia/types/Canvas.d.ts +16 -1
- package/lib/module/skia/types/Canvas.js +6 -9
- package/lib/module/skia/types/Canvas.js.map +1 -1
- package/lib/module/skia/types/ColorFilter/ColorFilter.js.map +1 -1
- package/lib/module/skia/types/ColorFilter/index.js.map +1 -1
- package/lib/module/skia/types/Data/Data.js.map +1 -1
- package/lib/module/skia/types/Data/index.js.map +1 -1
- package/lib/module/skia/types/Font/Font.js +15 -26
- package/lib/module/skia/types/Font/Font.js.map +1 -1
- package/lib/module/skia/types/Font/index.js.map +1 -1
- package/lib/module/skia/types/Image/Image.d.ts +8 -0
- package/lib/module/skia/types/Image/Image.js +9 -14
- package/lib/module/skia/types/Image/Image.js.map +1 -1
- package/lib/module/skia/types/Image/ImageFactory.js +6 -9
- package/lib/module/skia/types/Image/ImageFactory.js.map +1 -1
- package/lib/module/skia/types/Image/index.js.map +1 -1
- package/lib/module/skia/types/ImageFilter/ImageFilter.js +3 -5
- package/lib/module/skia/types/ImageFilter/ImageFilter.js.map +1 -1
- package/lib/module/skia/types/ImageFilter/ImageFilterFactory.js +3 -4
- package/lib/module/skia/types/ImageFilter/ImageFilterFactory.js.map +1 -1
- package/lib/module/skia/types/ImageFilter/index.js.map +1 -1
- package/lib/module/skia/types/MaskFilter.js +4 -5
- package/lib/module/skia/types/MaskFilter.js.map +1 -1
- package/lib/module/skia/types/Matrix.js.map +1 -1
- package/lib/module/skia/types/Matrix4.js +22 -64
- package/lib/module/skia/types/Matrix4.js.map +1 -1
- package/lib/module/skia/types/Paint/BlendMode.js +3 -4
- package/lib/module/skia/types/Paint/BlendMode.js.map +1 -1
- package/lib/module/skia/types/Paint/Paint.js +9 -15
- package/lib/module/skia/types/Paint/Paint.js.map +1 -1
- package/lib/module/skia/types/Paint/index.js.map +1 -1
- package/lib/module/skia/types/Paragraph/ParagraphBuilder.js +3 -4
- package/lib/module/skia/types/Paragraph/ParagraphBuilder.js.map +1 -1
- package/lib/module/skia/types/Paragraph/ParagraphStyle.js +9 -14
- package/lib/module/skia/types/Paragraph/ParagraphStyle.js.map +1 -1
- package/lib/module/skia/types/Paragraph/TextStyle.js +9 -14
- package/lib/module/skia/types/Paragraph/TextStyle.js.map +1 -1
- package/lib/module/skia/types/Paragraph/index.js.map +1 -1
- package/lib/module/skia/types/Path/Path.js +9 -14
- package/lib/module/skia/types/Path/Path.js.map +1 -1
- package/lib/module/skia/types/Path/index.js.map +1 -1
- package/lib/module/skia/types/PathEffect.js +3 -4
- package/lib/module/skia/types/PathEffect.js.map +1 -1
- package/lib/module/skia/types/Picture/index.js.map +1 -1
- package/lib/module/skia/types/Point.js +3 -4
- package/lib/module/skia/types/Point.js.map +1 -1
- package/lib/module/skia/types/RRect.js +2 -1
- package/lib/module/skia/types/RRect.js.map +1 -1
- package/lib/module/skia/types/RSXform.d.ts +7 -1
- package/lib/module/skia/types/RSXform.js.map +1 -1
- package/lib/module/skia/types/Rect.d.ts +4 -0
- package/lib/module/skia/types/Rect.js +0 -1
- package/lib/module/skia/types/Rect.js.map +1 -1
- package/lib/module/skia/types/RuntimeEffect/index.js.map +1 -1
- package/lib/module/skia/types/SVG/index.js.map +1 -1
- package/lib/module/skia/types/Shader/Shader.js +4 -9
- package/lib/module/skia/types/Shader/Shader.js.map +1 -1
- package/lib/module/skia/types/Shader/index.js.map +1 -1
- package/lib/module/skia/types/Skia.d.ts +3 -2
- package/lib/module/skia/types/Skia.js.map +1 -1
- package/lib/module/skia/types/Surface/index.js.map +1 -1
- package/lib/module/skia/types/Typeface/index.js.map +1 -1
- package/lib/module/skia/types/Vertices/Vertices.js +3 -4
- package/lib/module/skia/types/Vertices/Vertices.js.map +1 -1
- package/lib/module/skia/types/Vertices/index.js.map +1 -1
- package/lib/module/skia/types/index.js.map +1 -1
- package/lib/module/skia/web/Host.js +6 -16
- package/lib/module/skia/web/Host.js.map +1 -1
- package/lib/module/skia/web/JsiSkAnimatedImage.js +3 -9
- package/lib/module/skia/web/JsiSkAnimatedImage.js.map +1 -1
- package/lib/module/skia/web/JsiSkAnimatedImageFactory.js +0 -4
- package/lib/module/skia/web/JsiSkAnimatedImageFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkCanvas.d.ts +2 -1
- package/lib/module/skia/web/JsiSkCanvas.js +27 -59
- package/lib/module/skia/web/JsiSkCanvas.js.map +1 -1
- package/lib/module/skia/web/JsiSkColor.js +10 -52
- package/lib/module/skia/web/JsiSkColor.js.map +1 -1
- package/lib/module/skia/web/JsiSkColorFilter.js +3 -4
- package/lib/module/skia/web/JsiSkColorFilter.js.map +1 -1
- package/lib/module/skia/web/JsiSkColorFilterFactory.js +0 -8
- package/lib/module/skia/web/JsiSkColorFilterFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkContourMeasure.js +3 -8
- package/lib/module/skia/web/JsiSkContourMeasure.js.map +1 -1
- package/lib/module/skia/web/JsiSkContourMeasureIter.js +3 -7
- package/lib/module/skia/web/JsiSkContourMeasureIter.js.map +1 -1
- package/lib/module/skia/web/JsiSkData.js +5 -5
- package/lib/module/skia/web/JsiSkData.js.map +1 -1
- package/lib/module/skia/web/JsiSkDataFactory.js +0 -6
- package/lib/module/skia/web/JsiSkDataFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkFont.js +5 -26
- package/lib/module/skia/web/JsiSkFont.js.map +1 -1
- package/lib/module/skia/web/JsiSkFontMgr.js +0 -5
- package/lib/module/skia/web/JsiSkFontMgr.js.map +1 -1
- package/lib/module/skia/web/JsiSkFontMgrFactory.js +0 -4
- package/lib/module/skia/web/JsiSkFontMgrFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkImage.js +7 -23
- package/lib/module/skia/web/JsiSkImage.js.map +1 -1
- package/lib/module/skia/web/JsiSkImageFactory.js +2 -10
- package/lib/module/skia/web/JsiSkImageFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkImageFilter.js +3 -4
- package/lib/module/skia/web/JsiSkImageFilter.js.map +1 -1
- package/lib/module/skia/web/JsiSkImageFilterFactory.js +0 -23
- package/lib/module/skia/web/JsiSkImageFilterFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkMaskFilter.js +3 -4
- package/lib/module/skia/web/JsiSkMaskFilter.js.map +1 -1
- package/lib/module/skia/web/JsiSkMaskFilterFactory.js +0 -2
- package/lib/module/skia/web/JsiSkMaskFilterFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkMatrix.js +7 -21
- package/lib/module/skia/web/JsiSkMatrix.js.map +1 -1
- package/lib/module/skia/web/JsiSkPaint.js +3 -27
- package/lib/module/skia/web/JsiSkPaint.js.map +1 -1
- package/lib/module/skia/web/JsiSkParagraph.js +21 -44
- package/lib/module/skia/web/JsiSkParagraph.js.map +1 -1
- package/lib/module/skia/web/JsiSkParagraphBuilder.js +1 -18
- package/lib/module/skia/web/JsiSkParagraphBuilder.js.map +1 -1
- package/lib/module/skia/web/JsiSkParagraphBuilderFactory.js +0 -4
- package/lib/module/skia/web/JsiSkParagraphBuilderFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkParagraphStyle.js +4 -6
- package/lib/module/skia/web/JsiSkParagraphStyle.js.map +1 -1
- package/lib/module/skia/web/JsiSkPath.js +4 -69
- package/lib/module/skia/web/JsiSkPath.js.map +1 -1
- package/lib/module/skia/web/JsiSkPathEffect.js +3 -4
- package/lib/module/skia/web/JsiSkPathEffect.js.map +1 -1
- package/lib/module/skia/web/JsiSkPathEffectFactory.js +0 -17
- package/lib/module/skia/web/JsiSkPathEffectFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkPathFactory.js +0 -12
- package/lib/module/skia/web/JsiSkPathFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkPicture.js +4 -6
- package/lib/module/skia/web/JsiSkPicture.js.map +1 -1
- package/lib/module/skia/web/JsiSkPictureFactory.js +0 -4
- package/lib/module/skia/web/JsiSkPictureFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkPictureRecorder.js +3 -6
- package/lib/module/skia/web/JsiSkPictureRecorder.js.map +1 -1
- package/lib/module/skia/web/JsiSkPoint.js +5 -9
- package/lib/module/skia/web/JsiSkPoint.js.map +1 -1
- package/lib/module/skia/web/JsiSkRRect.js +5 -13
- package/lib/module/skia/web/JsiSkRRect.js.map +1 -1
- package/lib/module/skia/web/JsiSkRSXform.d.ts +8 -2
- package/lib/module/skia/web/JsiSkRSXform.js +31 -7
- package/lib/module/skia/web/JsiSkRSXform.js.map +1 -1
- package/lib/module/skia/web/JsiSkRect.d.ts +3 -2
- package/lib/module/skia/web/JsiSkRect.js +11 -11
- package/lib/module/skia/web/JsiSkRect.js.map +1 -1
- package/lib/module/skia/web/JsiSkRuntimeEffect.js +3 -11
- package/lib/module/skia/web/JsiSkRuntimeEffect.js.map +1 -1
- package/lib/module/skia/web/JsiSkRuntimeEffectFactory.js +0 -4
- package/lib/module/skia/web/JsiSkRuntimeEffectFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkSVGFactory.js +0 -3
- package/lib/module/skia/web/JsiSkSVGFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkShader.js +3 -4
- package/lib/module/skia/web/JsiSkShader.js.map +1 -1
- package/lib/module/skia/web/JsiSkShaderFactory.js +0 -9
- package/lib/module/skia/web/JsiSkShaderFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkSurface.js +3 -7
- package/lib/module/skia/web/JsiSkSurface.js.map +1 -1
- package/lib/module/skia/web/JsiSkSurfaceFactory.js +0 -10
- package/lib/module/skia/web/JsiSkSurfaceFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkTextBlob.js +3 -4
- package/lib/module/skia/web/JsiSkTextBlob.js.map +1 -1
- package/lib/module/skia/web/JsiSkTextBlobFactory.js +2 -6
- package/lib/module/skia/web/JsiSkTextBlobFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkTextStyle.js +0 -1
- package/lib/module/skia/web/JsiSkTextStyle.js.map +1 -1
- package/lib/module/skia/web/JsiSkTypeface.js +3 -7
- package/lib/module/skia/web/JsiSkTypeface.js.map +1 -1
- package/lib/module/skia/web/JsiSkTypefaceFactory.js +0 -4
- package/lib/module/skia/web/JsiSkTypefaceFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkTypefaceFontProvider.js +16 -23
- package/lib/module/skia/web/JsiSkTypefaceFontProvider.js.map +1 -1
- package/lib/module/skia/web/JsiSkTypefaceFontProviderFactory.js +0 -2
- package/lib/module/skia/web/JsiSkTypefaceFontProviderFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkVertices.js +3 -6
- package/lib/module/skia/web/JsiSkVertices.js.map +1 -1
- package/lib/module/skia/web/JsiSkVerticesFactory.js +8 -24
- package/lib/module/skia/web/JsiSkVerticesFactory.js.map +1 -1
- package/lib/module/skia/web/JsiSkia.js +5 -0
- package/lib/module/skia/web/JsiSkia.js.map +1 -1
- package/lib/module/skia/web/index.js.map +1 -1
- package/lib/module/specs/NativeSkiaModule.js.map +1 -1
- package/lib/module/specs/NativeSkiaModule.web.js +2 -1
- package/lib/module/specs/NativeSkiaModule.web.js.map +1 -1
- package/lib/module/specs/SkiaDomViewNativeComponent.js.map +1 -1
- package/lib/module/specs/SkiaPictureViewNativeComponent.js.map +1 -1
- package/lib/module/views/SkiaBaseWebView.js +16 -58
- package/lib/module/views/SkiaBaseWebView.js.map +1 -1
- package/lib/module/views/SkiaDomView.js +8 -23
- package/lib/module/views/SkiaDomView.js.map +1 -1
- package/lib/module/views/SkiaDomView.web.js +0 -4
- package/lib/module/views/SkiaDomView.web.js.map +1 -1
- package/lib/module/views/SkiaJSDomView.js +10 -26
- package/lib/module/views/SkiaJSDomView.js.map +1 -1
- package/lib/module/views/SkiaJSDomView.web.js.map +1 -1
- package/lib/module/views/SkiaPictureView.js +5 -18
- package/lib/module/views/SkiaPictureView.js.map +1 -1
- package/lib/module/views/SkiaPictureView.web.js +0 -2
- package/lib/module/views/SkiaPictureView.web.js.map +1 -1
- package/lib/module/views/SkiaViewNativeId.js.map +1 -1
- package/lib/module/views/api.js.map +1 -1
- package/lib/module/views/index.js.map +1 -1
- package/lib/module/views/types.js +4 -4
- package/lib/module/views/types.js.map +1 -1
- package/lib/module/views/useTouchHandler.js +13 -21
- package/lib/module/views/useTouchHandler.js.map +1 -1
- package/lib/module/web/LoadSkiaWeb.js +4 -5
- package/lib/module/web/LoadSkiaWeb.js.map +1 -1
- package/lib/module/web/WithSkiaWeb.js +7 -8
- package/lib/module/web/WithSkiaWeb.js.map +1 -1
- package/lib/module/web/index.js.map +1 -1
- package/lib/typescript/src/dom/nodes/JsiSkDOM.d.ts +2 -1
- package/lib/typescript/src/dom/nodes/drawings/AtlasNode.d.ts +8 -0
- package/lib/typescript/src/dom/nodes/drawings/index.d.ts +1 -0
- package/lib/typescript/src/dom/types/Drawings.d.ts +7 -1
- package/lib/typescript/src/dom/types/NodeType.d.ts +1 -0
- package/lib/typescript/src/dom/types/SkDOM.d.ts +2 -1
- package/lib/typescript/src/external/reanimated/buffers.d.ts +5 -0
- package/lib/typescript/src/external/reanimated/index.d.ts +1 -0
- package/lib/typescript/src/external/reanimated/interpolators.d.ts +1 -1
- package/lib/typescript/src/renderer/HostComponents.d.ts +3 -1
- package/lib/typescript/src/renderer/Offscreen.d.ts +4 -2
- package/lib/typescript/src/renderer/components/shapes/Atlas.d.ts +4 -0
- package/lib/typescript/src/renderer/components/shapes/index.d.ts +1 -0
- package/lib/typescript/src/skia/core/AnimatedImage.d.ts +1 -1
- package/lib/typescript/src/skia/core/Data.d.ts +1 -1
- package/lib/typescript/src/skia/core/Rect.d.ts +2 -2
- package/lib/typescript/src/skia/types/Canvas.d.ts +16 -1
- package/lib/typescript/src/skia/types/Image/Image.d.ts +8 -0
- package/lib/typescript/src/skia/types/RSXform.d.ts +7 -1
- package/lib/typescript/src/skia/types/Rect.d.ts +4 -0
- package/lib/typescript/src/skia/types/Skia.d.ts +3 -2
- package/lib/typescript/src/skia/web/JsiSkCanvas.d.ts +2 -1
- package/lib/typescript/src/skia/web/JsiSkRSXform.d.ts +8 -2
- package/lib/typescript/src/skia/web/JsiSkRect.d.ts +3 -2
- package/package.json +15 -15
- package/react-native-skia.podspec +1 -1
- package/src/dom/nodes/JsiSkDOM.ts +8 -0
- package/src/dom/nodes/Node.ts +1 -0
- package/src/dom/nodes/drawings/AtlasNode.ts +24 -0
- package/src/dom/nodes/drawings/index.ts +1 -0
- package/src/dom/types/Drawings.ts +9 -0
- package/src/dom/types/NodeType.ts +1 -0
- package/src/dom/types/SkDOM.ts +2 -0
- package/src/external/reanimated/buffers.ts +53 -0
- package/src/external/reanimated/index.ts +1 -0
- package/src/external/reanimated/interpolators.ts +4 -1
- package/src/external/reanimated/textures.tsx +7 -19
- package/src/external/reanimated/useAnimatedImageValue.ts +15 -4
- package/src/mock/index.ts +5 -0
- package/src/renderer/HostComponents.ts +6 -1
- package/src/renderer/Offscreen.tsx +20 -16
- package/src/renderer/components/shapes/Atlas.tsx +8 -0
- package/src/renderer/components/shapes/index.ts +1 -0
- package/src/skia/core/AnimatedImage.ts +3 -2
- package/src/skia/core/Data.ts +8 -4
- package/src/skia/types/Canvas.ts +32 -1
- package/src/skia/types/Image/Image.ts +10 -0
- package/src/skia/types/RSXform.ts +7 -1
- package/src/skia/types/Rect.ts +6 -0
- package/src/skia/types/Skia.ts +10 -2
- package/src/skia/web/JsiSkCanvas.ts +60 -23
- package/src/skia/web/JsiSkRSXform.ts +28 -4
- package/src/skia/web/JsiSkRect.ts +12 -2
- package/src/skia/web/JsiSkTextBlobFactory.ts +5 -5
- package/src/skia/web/JsiSkia.ts +15 -0
- package/lib/commonjs/animation/types.d.ts +0 -18
- package/lib/commonjs/animation/types.js +0 -2
- package/lib/commonjs/animation/types.js.map +0 -1
- package/lib/module/animation/types.d.ts +0 -18
- package/lib/module/animation/types.js +0 -2
- package/lib/module/animation/types.js.map +0 -1
- package/lib/typescript/src/animation/types.d.ts +0 -18
- package/src/animation/types.ts +0 -23
@@ -4,26 +4,19 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.useFonts = exports.useFont = exports.matchFont = exports.listFontFamilies = void 0;
|
7
|
-
|
8
7
|
var _react = require("react");
|
9
|
-
|
10
8
|
var _Skia = require("../Skia");
|
11
|
-
|
12
9
|
var _types = require("../types");
|
13
|
-
|
14
10
|
var _Platform = require("../../Platform");
|
15
|
-
|
16
11
|
var _Typeface = require("./Typeface");
|
17
|
-
|
18
12
|
/*global SkiaApi*/
|
13
|
+
|
19
14
|
const defaultFontSize = 14;
|
15
|
+
|
20
16
|
/**
|
21
17
|
* Returns a Skia Font object
|
22
18
|
* */
|
23
|
-
|
24
|
-
const useFont = function (font) {
|
25
|
-
let size = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : defaultFontSize;
|
26
|
-
let onError = arguments.length > 2 ? arguments[2] : undefined;
|
19
|
+
const useFont = (font, size = defaultFontSize, onError) => {
|
27
20
|
const typeface = (0, _Typeface.useTypeface)(font, onError);
|
28
21
|
return (0, _react.useMemo)(() => {
|
29
22
|
if (typeface) {
|
@@ -33,7 +26,6 @@ const useFont = function (font) {
|
|
33
26
|
}
|
34
27
|
}, [size, typeface]);
|
35
28
|
};
|
36
|
-
|
37
29
|
exports.useFont = useFont;
|
38
30
|
const defaultFontStyle = {
|
39
31
|
fontFamily: "System",
|
@@ -41,7 +33,6 @@ const defaultFontStyle = {
|
|
41
33
|
fontStyle: "normal",
|
42
34
|
fontWeight: "normal"
|
43
35
|
};
|
44
|
-
|
45
36
|
const slant = s => {
|
46
37
|
if (s === "italic") {
|
47
38
|
return _types.FontSlant.Italic;
|
@@ -51,24 +42,19 @@ const slant = s => {
|
|
51
42
|
return _types.FontSlant.Upright;
|
52
43
|
}
|
53
44
|
};
|
54
|
-
|
55
45
|
const weight = fontWeight => {
|
56
46
|
switch (fontWeight) {
|
57
47
|
case "normal":
|
58
48
|
return 400;
|
59
|
-
|
60
49
|
case "bold":
|
61
50
|
return 700;
|
62
|
-
|
63
51
|
default:
|
64
52
|
return parseInt(fontWeight, 10);
|
65
53
|
}
|
66
54
|
};
|
67
|
-
|
68
|
-
const
|
69
|
-
|
70
|
-
let fontMgr = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _Skia.Skia.FontMgr.System();
|
71
|
-
const fontStyle = { ...defaultFontStyle,
|
55
|
+
const matchFont = (inputStyle = {}, fontMgr = _Skia.Skia.FontMgr.System()) => {
|
56
|
+
const fontStyle = {
|
57
|
+
...defaultFontStyle,
|
72
58
|
...inputStyle
|
73
59
|
};
|
74
60
|
const style = {
|
@@ -79,48 +65,36 @@ const matchFont = function () {
|
|
79
65
|
const typeface = fontMgr.matchFamilyStyle(fontStyle.fontFamily, style);
|
80
66
|
return _Skia.Skia.Font(typeface, fontStyle.fontSize);
|
81
67
|
};
|
82
|
-
|
83
68
|
exports.matchFont = matchFont;
|
84
|
-
|
85
|
-
const listFontFamilies = function () {
|
86
|
-
let fontMgr = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : _Skia.Skia.FontMgr.System();
|
87
|
-
return new Array(fontMgr.countFamilies()).fill(0).map((_, i) => fontMgr.getFamilyName(i));
|
88
|
-
};
|
89
|
-
|
69
|
+
const listFontFamilies = (fontMgr = _Skia.Skia.FontMgr.System()) => new Array(fontMgr.countFamilies()).fill(0).map((_, i) => fontMgr.getFamilyName(i));
|
90
70
|
exports.listFontFamilies = listFontFamilies;
|
91
|
-
|
92
71
|
const loadTypefaces = typefacesToLoad => {
|
93
72
|
const promises = Object.keys(typefacesToLoad).flatMap(familyName => {
|
94
73
|
return typefacesToLoad[familyName].map(typefaceToLoad => {
|
95
74
|
return _Skia.Skia.Data.fromURI(_Platform.Platform.resolveAsset(typefaceToLoad)).then(data => {
|
96
75
|
const tf = _Skia.Skia.Typeface.MakeFreeTypeFaceFromData(data);
|
97
|
-
|
98
76
|
if (tf === null) {
|
99
77
|
throw new Error(`Couldn't create typeface for ${familyName}`);
|
100
78
|
}
|
101
|
-
|
102
79
|
return [familyName, tf];
|
103
80
|
});
|
104
81
|
});
|
105
82
|
});
|
106
83
|
return Promise.all(promises);
|
107
84
|
};
|
108
|
-
|
109
85
|
const useFonts = sources => {
|
110
86
|
const [fontMgr, setFontMgr] = (0, _react.useState)(null);
|
111
87
|
(0, _react.useEffect)(() => {
|
112
88
|
loadTypefaces(sources).then(result => {
|
113
89
|
const fMgr = _Skia.Skia.TypefaceFontProvider.Make();
|
114
|
-
|
115
|
-
result.forEach(_ref => {
|
116
|
-
let [familyName, typeface] = _ref;
|
90
|
+
result.forEach(([familyName, typeface]) => {
|
117
91
|
fMgr.registerFont(typeface, familyName);
|
118
92
|
});
|
119
93
|
setFontMgr(fMgr);
|
120
|
-
});
|
94
|
+
});
|
95
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
121
96
|
}, []);
|
122
97
|
return fontMgr;
|
123
98
|
};
|
124
|
-
|
125
99
|
exports.useFonts = useFonts;
|
126
100
|
//# sourceMappingURL=Font.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["defaultFontSize","useFont","font","size","onError","typeface","useTypeface","useMemo","Skia","Font","defaultFontStyle","fontFamily","fontSize","fontStyle","fontWeight","slant","s","FontSlant","Italic","Oblique","Upright","weight","parseInt","matchFont","inputStyle","fontMgr","FontMgr","System","style","width","matchFamilyStyle","listFontFamilies","Array","countFamilies","fill","map","_","i","getFamilyName","loadTypefaces","typefacesToLoad","promises","Object","keys","flatMap","familyName","typefaceToLoad","Data","fromURI","Platform","resolveAsset","then","data","tf","Typeface","MakeFreeTypeFaceFromData","Error","Promise","all","useFonts","sources","setFontMgr","useState","useEffect","result","fMgr","TypefaceFontProvider","Make","forEach","registerFont"],"sources":["Font.ts"],"sourcesContent":["/*global SkiaApi*/\nimport { useEffect, useMemo, useState } from \"react\";\n\nimport { Skia } from \"../Skia\";\nimport { FontSlant } from \"../types\";\nimport type { DataModule, DataSourceParam, SkFontMgr } from \"../types\";\nimport { Platform } from \"../../Platform\";\nimport type { SkTypefaceFontProvider } from \"../types/Paragraph/TypefaceFontProvider\";\n\nimport { useTypeface } from \"./Typeface\";\n\nconst defaultFontSize = 14;\n\n/**\n * Returns a Skia Font object\n * */\nexport const useFont = (\n font: DataSourceParam,\n size = defaultFontSize,\n onError?: (err: Error) => void\n) => {\n const typeface = useTypeface(font, onError);\n return useMemo(() => {\n if (typeface) {\n return Skia.Font(typeface, size);\n } else {\n return null;\n }\n }, [size, typeface]);\n};\n\ntype Slant = \"normal\" | \"italic\" | \"oblique\";\ntype Weight =\n | \"normal\"\n | \"bold\"\n | \"100\"\n | \"200\"\n | \"300\"\n | \"400\"\n | \"500\"\n | \"600\"\n | \"700\"\n | \"800\"\n | \"900\";\n\ninterface RNFontStyle {\n fontFamily: string;\n fontSize: number;\n fontStyle: Slant;\n fontWeight: Weight;\n}\n\nconst defaultFontStyle: RNFontStyle = {\n fontFamily: \"System\",\n fontSize: defaultFontSize,\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n};\n\nconst slant = (s: Slant) => {\n if (s === \"italic\") {\n return FontSlant.Italic;\n } else if (s === \"oblique\") {\n return FontSlant.Oblique;\n } else {\n return FontSlant.Upright;\n }\n};\n\nconst weight = (fontWeight: Weight) => {\n switch (fontWeight) {\n case \"normal\":\n return 400;\n case \"bold\":\n return 700;\n default:\n return parseInt(fontWeight, 10);\n }\n};\n\nexport const matchFont = (\n inputStyle: Partial<RNFontStyle> = {},\n fontMgr: SkFontMgr = Skia.FontMgr.System()\n) => {\n const fontStyle = {\n ...defaultFontStyle,\n ...inputStyle,\n };\n const style = {\n weight: weight(fontStyle.fontWeight),\n width: 5,\n slant: slant(fontStyle.fontStyle),\n };\n const typeface = fontMgr.matchFamilyStyle(fontStyle.fontFamily, style);\n return Skia.Font(typeface, fontStyle.fontSize);\n};\n\nexport const listFontFamilies = (fontMgr: SkFontMgr = Skia.FontMgr.System()) =>\n new Array(fontMgr.countFamilies())\n .fill(0)\n .map((_, i) => fontMgr.getFamilyName(i));\n\nconst loadTypefaces = (typefacesToLoad: Record<string, DataModule[]>) => {\n const promises = Object.keys(typefacesToLoad).flatMap((familyName) => {\n return typefacesToLoad[familyName].map((typefaceToLoad) => {\n return Skia.Data.fromURI(Platform.resolveAsset(typefaceToLoad)).then(\n (data) => {\n const tf = Skia.Typeface.MakeFreeTypeFaceFromData(data);\n if (tf === null) {\n throw new Error(`Couldn't create typeface for ${familyName}`);\n }\n return [familyName, tf] as const;\n }\n );\n });\n });\n return Promise.all(promises);\n};\n\nexport const useFonts = (sources: Record<string, DataModule[]>) => {\n const [fontMgr, setFontMgr] = useState<null | SkTypefaceFontProvider>(null);\n\n useEffect(() => {\n loadTypefaces(sources).then((result) => {\n const fMgr = Skia.TypefaceFontProvider.Make();\n result.forEach(([familyName, typeface]) => {\n fMgr.registerFont(typeface, familyName);\n });\n setFontMgr(fMgr);\n });\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n return fontMgr;\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["_react","require","_Skia","_types","_Platform","_Typeface","defaultFontSize","useFont","font","size","onError","typeface","useTypeface","useMemo","Skia","Font","exports","defaultFontStyle","fontFamily","fontSize","fontStyle","fontWeight","slant","s","FontSlant","Italic","Oblique","Upright","weight","parseInt","matchFont","inputStyle","fontMgr","FontMgr","System","style","width","matchFamilyStyle","listFontFamilies","Array","countFamilies","fill","map","_","i","getFamilyName","loadTypefaces","typefacesToLoad","promises","Object","keys","flatMap","familyName","typefaceToLoad","Data","fromURI","Platform","resolveAsset","then","data","tf","Typeface","MakeFreeTypeFaceFromData","Error","Promise","all","useFonts","sources","setFontMgr","useState","useEffect","result","fMgr","TypefaceFontProvider","Make","forEach","registerFont"],"sources":["Font.ts"],"sourcesContent":["/*global SkiaApi*/\nimport { useEffect, useMemo, useState } from \"react\";\n\nimport { Skia } from \"../Skia\";\nimport { FontSlant } from \"../types\";\nimport type { DataModule, DataSourceParam, SkFontMgr } from \"../types\";\nimport { Platform } from \"../../Platform\";\nimport type { SkTypefaceFontProvider } from \"../types/Paragraph/TypefaceFontProvider\";\n\nimport { useTypeface } from \"./Typeface\";\n\nconst defaultFontSize = 14;\n\n/**\n * Returns a Skia Font object\n * */\nexport const useFont = (\n font: DataSourceParam,\n size = defaultFontSize,\n onError?: (err: Error) => void\n) => {\n const typeface = useTypeface(font, onError);\n return useMemo(() => {\n if (typeface) {\n return Skia.Font(typeface, size);\n } else {\n return null;\n }\n }, [size, typeface]);\n};\n\ntype Slant = \"normal\" | \"italic\" | \"oblique\";\ntype Weight =\n | \"normal\"\n | \"bold\"\n | \"100\"\n | \"200\"\n | \"300\"\n | \"400\"\n | \"500\"\n | \"600\"\n | \"700\"\n | \"800\"\n | \"900\";\n\ninterface RNFontStyle {\n fontFamily: string;\n fontSize: number;\n fontStyle: Slant;\n fontWeight: Weight;\n}\n\nconst defaultFontStyle: RNFontStyle = {\n fontFamily: \"System\",\n fontSize: defaultFontSize,\n fontStyle: \"normal\",\n fontWeight: \"normal\",\n};\n\nconst slant = (s: Slant) => {\n if (s === \"italic\") {\n return FontSlant.Italic;\n } else if (s === \"oblique\") {\n return FontSlant.Oblique;\n } else {\n return FontSlant.Upright;\n }\n};\n\nconst weight = (fontWeight: Weight) => {\n switch (fontWeight) {\n case \"normal\":\n return 400;\n case \"bold\":\n return 700;\n default:\n return parseInt(fontWeight, 10);\n }\n};\n\nexport const matchFont = (\n inputStyle: Partial<RNFontStyle> = {},\n fontMgr: SkFontMgr = Skia.FontMgr.System()\n) => {\n const fontStyle = {\n ...defaultFontStyle,\n ...inputStyle,\n };\n const style = {\n weight: weight(fontStyle.fontWeight),\n width: 5,\n slant: slant(fontStyle.fontStyle),\n };\n const typeface = fontMgr.matchFamilyStyle(fontStyle.fontFamily, style);\n return Skia.Font(typeface, fontStyle.fontSize);\n};\n\nexport const listFontFamilies = (fontMgr: SkFontMgr = Skia.FontMgr.System()) =>\n new Array(fontMgr.countFamilies())\n .fill(0)\n .map((_, i) => fontMgr.getFamilyName(i));\n\nconst loadTypefaces = (typefacesToLoad: Record<string, DataModule[]>) => {\n const promises = Object.keys(typefacesToLoad).flatMap((familyName) => {\n return typefacesToLoad[familyName].map((typefaceToLoad) => {\n return Skia.Data.fromURI(Platform.resolveAsset(typefaceToLoad)).then(\n (data) => {\n const tf = Skia.Typeface.MakeFreeTypeFaceFromData(data);\n if (tf === null) {\n throw new Error(`Couldn't create typeface for ${familyName}`);\n }\n return [familyName, tf] as const;\n }\n );\n });\n });\n return Promise.all(promises);\n};\n\nexport const useFonts = (sources: Record<string, DataModule[]>) => {\n const [fontMgr, setFontMgr] = useState<null | SkTypefaceFontProvider>(null);\n\n useEffect(() => {\n loadTypefaces(sources).then((result) => {\n const fMgr = Skia.TypefaceFontProvider.Make();\n result.forEach(([familyName, typeface]) => {\n fMgr.registerFont(typeface, familyName);\n });\n setFontMgr(fMgr);\n });\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n return fontMgr;\n};\n"],"mappings":"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"}
|
@@ -4,20 +4,16 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.useImage = exports.makeImageFromView = void 0;
|
7
|
-
|
8
7
|
var _Platform = require("../../Platform");
|
9
|
-
|
10
8
|
var _Skia = require("../Skia");
|
11
|
-
|
12
9
|
var _Data = require("./Data");
|
13
|
-
|
14
10
|
const imgFactory = _Skia.Skia.Image.MakeImageFromEncoded.bind(_Skia.Skia.Image);
|
11
|
+
|
15
12
|
/**
|
16
13
|
* Returns a Skia Image object
|
17
14
|
* */
|
18
|
-
|
19
|
-
|
20
15
|
const useImage = (source, onError) => (0, _Data.useRawData)(source, imgFactory, onError);
|
16
|
+
|
21
17
|
/**
|
22
18
|
* Creates an image from a given view reference. NOTE: This method has different implementations
|
23
19
|
* on web/native. On web, the callback is called with the view ref and the callback is expected to
|
@@ -28,13 +24,8 @@ const useImage = (source, onError) => (0, _Data.useRawData)(source, imgFactory,
|
|
28
24
|
* @returns A promise that resolves to a Skia Image object or rejects
|
29
25
|
* with an error id the view tag is invalid.
|
30
26
|
*/
|
31
|
-
|
32
|
-
|
33
27
|
exports.useImage = useImage;
|
34
|
-
|
35
|
-
const makeImageFromView = function (viewRef) {
|
36
|
-
let callback = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
37
|
-
|
28
|
+
const makeImageFromView = (viewRef, callback = null) => {
|
38
29
|
// In web implementation we just delegate the work to the provided callback
|
39
30
|
if (_Platform.Platform.OS === "web") {
|
40
31
|
if (callback) {
|
@@ -43,15 +34,11 @@ const makeImageFromView = function (viewRef) {
|
|
43
34
|
Promise.reject(new Error("Callback is required on web in the makeImageFromView function."));
|
44
35
|
}
|
45
36
|
}
|
46
|
-
|
47
37
|
const viewTag = _Platform.Platform.findNodeHandle(viewRef.current);
|
48
|
-
|
49
38
|
if (viewTag !== null && viewTag !== 0) {
|
50
39
|
return _Skia.Skia.Image.MakeImageFromViewTag(viewTag);
|
51
40
|
}
|
52
|
-
|
53
41
|
return Promise.reject(new Error("Invalid view tag"));
|
54
42
|
};
|
55
|
-
|
56
43
|
exports.makeImageFromView = makeImageFromView;
|
57
44
|
//# sourceMappingURL=Image.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["imgFactory","Skia","Image","MakeImageFromEncoded","bind","useImage","source","onError","useRawData","makeImageFromView","viewRef","callback","Platform","OS","Promise","reject","Error","viewTag","findNodeHandle","current","MakeImageFromViewTag"],"sources":["Image.ts"],"sourcesContent":["import { Platform } from \"../../Platform\";\nimport { Skia } from \"../Skia\";\nimport type { DataSourceParam, SkImage } from \"../types\";\n\nimport { useRawData } from \"./Data\";\n\nconst imgFactory = Skia.Image.MakeImageFromEncoded.bind(Skia.Image);\n\n/**\n * Returns a Skia Image object\n * */\nexport const useImage = (\n source: DataSourceParam,\n onError?: (err: Error) => void\n) => useRawData(source, imgFactory, onError);\n\n/**\n * Creates an image from a given view reference. NOTE: This method has different implementations\n * on web/native. On web, the callback is called with the view ref and the callback is expected to\n * return a promise that resolves to a Skia Image object. On native, the view ref is used to\n * find the view tag and the Skia Image object is created from the view tag. This means that on web\n * you will need to implement the logic to create the image from the view ref yourself.\n * @param viewRef Ref to the view we're creating an image from\n * @returns A promise that resolves to a Skia Image object or rejects\n * with an error id the view tag is invalid.\n */\nexport const makeImageFromView = <\n T extends\n | number\n | React.Component<unknown, unknown>\n | React.ComponentClass<unknown>\n>(\n viewRef: React.RefObject<T>,\n callback:\n | null\n | ((viewRef: React.RefObject<T>) => Promise<SkImage | null>) = null\n) => {\n // In web implementation we just delegate the work to the provided callback\n if (Platform.OS === \"web\") {\n if (callback) {\n return callback(viewRef);\n } else {\n Promise.reject(\n new Error(\n \"Callback is required on web in the makeImageFromView function.\"\n )\n );\n }\n }\n const viewTag = Platform.findNodeHandle(viewRef.current);\n if (viewTag !== null && viewTag !== 0) {\n return Skia.Image.MakeImageFromViewTag(viewTag);\n }\n return Promise.reject(new Error(\"Invalid view tag\"));\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["_Platform","require","_Skia","_Data","imgFactory","Skia","Image","MakeImageFromEncoded","bind","useImage","source","onError","useRawData","exports","makeImageFromView","viewRef","callback","Platform","OS","Promise","reject","Error","viewTag","findNodeHandle","current","MakeImageFromViewTag"],"sources":["Image.ts"],"sourcesContent":["import { Platform } from \"../../Platform\";\nimport { Skia } from \"../Skia\";\nimport type { DataSourceParam, SkImage } from \"../types\";\n\nimport { useRawData } from \"./Data\";\n\nconst imgFactory = Skia.Image.MakeImageFromEncoded.bind(Skia.Image);\n\n/**\n * Returns a Skia Image object\n * */\nexport const useImage = (\n source: DataSourceParam,\n onError?: (err: Error) => void\n) => useRawData(source, imgFactory, onError);\n\n/**\n * Creates an image from a given view reference. NOTE: This method has different implementations\n * on web/native. On web, the callback is called with the view ref and the callback is expected to\n * return a promise that resolves to a Skia Image object. On native, the view ref is used to\n * find the view tag and the Skia Image object is created from the view tag. This means that on web\n * you will need to implement the logic to create the image from the view ref yourself.\n * @param viewRef Ref to the view we're creating an image from\n * @returns A promise that resolves to a Skia Image object or rejects\n * with an error id the view tag is invalid.\n */\nexport const makeImageFromView = <\n T extends\n | number\n | React.Component<unknown, unknown>\n | React.ComponentClass<unknown>\n>(\n viewRef: React.RefObject<T>,\n callback:\n | null\n | ((viewRef: React.RefObject<T>) => Promise<SkImage | null>) = null\n) => {\n // In web implementation we just delegate the work to the provided callback\n if (Platform.OS === \"web\") {\n if (callback) {\n return callback(viewRef);\n } else {\n Promise.reject(\n new Error(\n \"Callback is required on web in the makeImageFromView function.\"\n )\n );\n }\n }\n const viewTag = Platform.findNodeHandle(viewRef.current);\n if (viewTag !== null && viewTag !== 0) {\n return Skia.Image.MakeImageFromViewTag(viewTag);\n }\n return Promise.reject(new Error(\"Invalid view tag\"));\n};\n"],"mappings":";;;;;;AAAA,IAAAA,SAAA,GAAAC,OAAA;AACA,IAAAC,KAAA,GAAAD,OAAA;AAGA,IAAAE,KAAA,GAAAF,OAAA;AAEA,MAAMG,UAAU,GAAGC,UAAI,CAACC,KAAK,CAACC,oBAAoB,CAACC,IAAI,CAACH,UAAI,CAACC,KAAK,CAAC;;AAEnE;AACA;AACA;AACO,MAAMG,QAAQ,GAAGA,CACtBC,MAAuB,EACvBC,OAA8B,KAC3B,IAAAC,gBAAU,EAACF,MAAM,EAAEN,UAAU,EAAEO,OAAO,CAAC;;AAE5C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AATAE,OAAA,CAAAJ,QAAA,GAAAA,QAAA;AAUO,MAAMK,iBAAiB,GAAGA,CAM/BC,OAA2B,EAC3BC,QAE8D,GAAG,IAAI,KAClE;EACH;EACA,IAAIC,kBAAQ,CAACC,EAAE,KAAK,KAAK,EAAE;IACzB,IAAIF,QAAQ,EAAE;MACZ,OAAOA,QAAQ,CAACD,OAAO,CAAC;IAC1B,CAAC,MAAM;MACLI,OAAO,CAACC,MAAM,CACZ,IAAIC,KAAK,CACP,gEACF,CACF,CAAC;IACH;EACF;EACA,MAAMC,OAAO,GAAGL,kBAAQ,CAACM,cAAc,CAACR,OAAO,CAACS,OAAO,CAAC;EACxD,IAAIF,OAAO,KAAK,IAAI,IAAIA,OAAO,KAAK,CAAC,EAAE;IACrC,OAAOjB,UAAI,CAACC,KAAK,CAACmB,oBAAoB,CAACH,OAAO,CAAC;EACjD;EACA,OAAOH,OAAO,CAACC,MAAM,CAAC,IAAIC,KAAK,CAAC,kBAAkB,CAAC,CAAC;AACtD,CAAC;AAACR,OAAA,CAAAC,iBAAA,GAAAA,iBAAA"}
|
@@ -4,12 +4,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.processTransform2d = void 0;
|
7
|
-
|
8
7
|
var _Skia = require("../Skia");
|
9
|
-
|
10
8
|
var _types = require("../types");
|
11
|
-
|
12
9
|
const processTransform2d = transforms => (0, _types.processTransform)(_Skia.Skia.Matrix(), transforms);
|
13
|
-
|
14
10
|
exports.processTransform2d = processTransform2d;
|
15
11
|
//# sourceMappingURL=Matrix.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["processTransform2d","transforms","processTransform","Skia","Matrix"],"sources":["Matrix.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { Transforms3d } from \"../types\";\nimport { processTransform } from \"../types\";\n\nexport const processTransform2d = (transforms: Transforms3d) =>\n processTransform(Skia.Matrix(), transforms);\n"],"mappings":"
|
1
|
+
{"version":3,"names":["_Skia","require","_types","processTransform2d","transforms","processTransform","Skia","Matrix","exports"],"sources":["Matrix.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { Transforms3d } from \"../types\";\nimport { processTransform } from \"../types\";\n\nexport const processTransform2d = (transforms: Transforms3d) =>\n processTransform(Skia.Matrix(), transforms);\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAEA,IAAAC,MAAA,GAAAD,OAAA;AAEO,MAAME,kBAAkB,GAAIC,UAAwB,IACzD,IAAAC,uBAAgB,EAACC,UAAI,CAACC,MAAM,CAAC,CAAC,EAAEH,UAAU,CAAC;AAACI,OAAA,CAAAL,kBAAA,GAAAA,kBAAA"}
|
@@ -4,11 +4,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.createPicture = void 0;
|
7
|
-
|
8
7
|
var _Skia = require("../Skia");
|
9
|
-
|
10
8
|
var _types = require("../types");
|
11
|
-
|
12
9
|
/**
|
13
10
|
* Memoizes and returns an SkPicture that can be drawn to another canvas.
|
14
11
|
* @param rect Picture bounds
|
@@ -19,17 +16,13 @@ const createPicture = (cb, rect) => {
|
|
19
16
|
"worklet";
|
20
17
|
|
21
18
|
const recorder = _Skia.Skia.PictureRecorder();
|
22
|
-
|
23
19
|
let bounds;
|
24
|
-
|
25
20
|
if (rect) {
|
26
21
|
bounds = (0, _types.isRect)(rect) ? rect : _Skia.Skia.XYWHRect(0, 0, rect.width, rect.height);
|
27
22
|
}
|
28
|
-
|
29
23
|
const canvas = recorder.beginRecording(bounds);
|
30
24
|
cb(canvas);
|
31
25
|
return recorder.finishRecordingAsPicture();
|
32
26
|
};
|
33
|
-
|
34
27
|
exports.createPicture = createPicture;
|
35
28
|
//# sourceMappingURL=Picture.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["createPicture","cb","rect","recorder","Skia","PictureRecorder","bounds","isRect","XYWHRect","width","height","canvas","beginRecording","finishRecordingAsPicture"],"sources":["Picture.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport { isRect, type SkCanvas, type SkRect, type SkSize } from \"../types\";\n\n/**\n * Memoizes and returns an SkPicture that can be drawn to another canvas.\n * @param rect Picture bounds\n * @param cb Callback for drawing to the canvas\n * @returns SkPicture\n */\nexport const createPicture = (\n cb: (canvas: SkCanvas) => void,\n rect?: SkRect | SkSize\n) => {\n \"worklet\";\n const recorder = Skia.PictureRecorder();\n let bounds: undefined | SkRect;\n if (rect) {\n bounds = isRect(rect) ? rect : Skia.XYWHRect(0, 0, rect.width, rect.height);\n }\n const canvas = recorder.beginRecording(bounds);\n cb(canvas);\n return recorder.finishRecordingAsPicture();\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["_Skia","require","_types","createPicture","cb","rect","recorder","Skia","PictureRecorder","bounds","isRect","XYWHRect","width","height","canvas","beginRecording","finishRecordingAsPicture","exports"],"sources":["Picture.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport { isRect, type SkCanvas, type SkRect, type SkSize } from \"../types\";\n\n/**\n * Memoizes and returns an SkPicture that can be drawn to another canvas.\n * @param rect Picture bounds\n * @param cb Callback for drawing to the canvas\n * @returns SkPicture\n */\nexport const createPicture = (\n cb: (canvas: SkCanvas) => void,\n rect?: SkRect | SkSize\n) => {\n \"worklet\";\n const recorder = Skia.PictureRecorder();\n let bounds: undefined | SkRect;\n if (rect) {\n bounds = isRect(rect) ? rect : Skia.XYWHRect(0, 0, rect.width, rect.height);\n }\n const canvas = recorder.beginRecording(bounds);\n cb(canvas);\n return recorder.finishRecordingAsPicture();\n};\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AACA,IAAAC,MAAA,GAAAD,OAAA;AAEA;AACA;AACA;AACA;AACA;AACA;AACO,MAAME,aAAa,GAAGA,CAC3BC,EAA8B,EAC9BC,IAAsB,KACnB;EACH,SAAS;;EACT,MAAMC,QAAQ,GAAGC,UAAI,CAACC,eAAe,CAAC,CAAC;EACvC,IAAIC,MAA0B;EAC9B,IAAIJ,IAAI,EAAE;IACRI,MAAM,GAAG,IAAAC,aAAM,EAACL,IAAI,CAAC,GAAGA,IAAI,GAAGE,UAAI,CAACI,QAAQ,CAAC,CAAC,EAAE,CAAC,EAAEN,IAAI,CAACO,KAAK,EAAEP,IAAI,CAACQ,MAAM,CAAC;EAC7E;EACA,MAAMC,MAAM,GAAGR,QAAQ,CAACS,cAAc,CAACN,MAAM,CAAC;EAC9CL,EAAE,CAACU,MAAM,CAAC;EACV,OAAOR,QAAQ,CAACU,wBAAwB,CAAC,CAAC;AAC5C,CAAC;AAACC,OAAA,CAAAd,aAAA,GAAAA,aAAA"}
|
@@ -4,14 +4,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.rrect = void 0;
|
7
|
-
|
8
7
|
var _Skia = require("../Skia");
|
9
|
-
|
10
8
|
const rrect = (r, rx, ry) => {
|
11
9
|
"worklet";
|
12
10
|
|
13
11
|
return _Skia.Skia.RRectXY(r, rx, ry);
|
14
12
|
};
|
15
|
-
|
16
13
|
exports.rrect = rrect;
|
17
14
|
//# sourceMappingURL=RRect.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["rrect","r","rx","ry","Skia","RRectXY"],"sources":["RRect.tsx"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { SkRect } from \"../types\";\n\nexport const rrect = (r: SkRect, rx: number, ry: number) => {\n \"worklet\";\n return Skia.RRectXY(r, rx, ry);\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["_Skia","require","rrect","r","rx","ry","Skia","RRectXY","exports"],"sources":["RRect.tsx"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { SkRect } from \"../types\";\n\nexport const rrect = (r: SkRect, rx: number, ry: number) => {\n \"worklet\";\n return Skia.RRectXY(r, rx, ry);\n};\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAGO,MAAMC,KAAK,GAAGA,CAACC,CAAS,EAAEC,EAAU,EAAEC,EAAU,KAAK;EAC1D,SAAS;;EACT,OAAOC,UAAI,CAACC,OAAO,CAACJ,CAAC,EAAEC,EAAE,EAAEC,EAAE,CAAC;AAChC,CAAC;AAACG,OAAA,CAAAN,KAAA,GAAAA,KAAA"}
|
@@ -1,6 +1,6 @@
|
|
1
1
|
import type { SkRect, SkRRect } from "../types";
|
2
|
-
export declare const rect: (x: number, y: number, width: number, height: number) =>
|
3
|
-
export declare const bounds: (rects: SkRect[]) =>
|
2
|
+
export declare const rect: (x: number, y: number, width: number, height: number) => import("../types").SkHostRect;
|
3
|
+
export declare const bounds: (rects: SkRect[]) => import("../types").SkHostRect;
|
4
4
|
export declare const topLeft: (r: SkRect | SkRRect) => import("../types").SkPoint;
|
5
5
|
export declare const topRight: (r: SkRect | SkRRect) => import("../types").SkPoint;
|
6
6
|
export declare const bottomLeft: (r: SkRect | SkRRect) => import("../types").SkPoint;
|
@@ -4,21 +4,15 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.topRight = exports.topLeft = exports.rect = exports.center = exports.bounds = exports.bottomRight = exports.bottomLeft = void 0;
|
7
|
-
|
8
7
|
var _Skia = require("../Skia");
|
9
|
-
|
10
8
|
var _types = require("../types");
|
11
|
-
|
12
9
|
var _Vector = require("./Vector");
|
13
|
-
|
14
10
|
const rect = (x, y, width, height) => {
|
15
11
|
"worklet";
|
16
12
|
|
17
13
|
return _Skia.Skia.XYWHRect(x, y, width, height);
|
18
14
|
};
|
19
|
-
|
20
15
|
exports.rect = rect;
|
21
|
-
|
22
16
|
const bounds = rects => {
|
23
17
|
"worklet";
|
24
18
|
|
@@ -28,46 +22,35 @@ const bounds = rects => {
|
|
28
22
|
const height = Math.max(...rects.map(r => r.y + r.height));
|
29
23
|
return rect(x, y, width - x, height - y);
|
30
24
|
};
|
31
|
-
|
32
25
|
exports.bounds = bounds;
|
33
|
-
|
34
26
|
const topLeft = r => {
|
35
27
|
"worklet";
|
36
28
|
|
37
29
|
return (0, _types.isRRect)(r) ? (0, _Vector.vec)(r.rect.x, r.rect.y) : (0, _Vector.vec)(r.x, r.y);
|
38
30
|
};
|
39
|
-
|
40
31
|
exports.topLeft = topLeft;
|
41
|
-
|
42
32
|
const topRight = r => {
|
43
33
|
"worklet";
|
44
34
|
|
45
35
|
return (0, _types.isRRect)(r) ? (0, _Vector.vec)(r.rect.x + r.rect.width, r.rect.y) : (0, _Vector.vec)(r.x + r.width, r.y);
|
46
36
|
};
|
47
|
-
|
48
37
|
exports.topRight = topRight;
|
49
|
-
|
50
38
|
const bottomLeft = r => {
|
51
39
|
"worklet";
|
52
40
|
|
53
41
|
return (0, _types.isRRect)(r) ? (0, _Vector.vec)(r.rect.x, r.rect.y + r.rect.height) : (0, _Vector.vec)(r.x, r.y + r.height);
|
54
42
|
};
|
55
|
-
|
56
43
|
exports.bottomLeft = bottomLeft;
|
57
|
-
|
58
44
|
const bottomRight = r => {
|
59
45
|
"worklet";
|
60
46
|
|
61
47
|
return (0, _types.isRRect)(r) ? (0, _Vector.vec)(r.rect.x + r.rect.width, r.rect.y + r.rect.height) : (0, _Vector.vec)(r.x + r.width, r.y + r.height);
|
62
48
|
};
|
63
|
-
|
64
49
|
exports.bottomRight = bottomRight;
|
65
|
-
|
66
50
|
const center = r => {
|
67
51
|
"worklet";
|
68
52
|
|
69
53
|
return (0, _types.isRRect)(r) ? (0, _Vector.vec)(r.rect.x + r.rect.width / 2, r.rect.y + r.rect.height / 2) : (0, _Vector.vec)(r.x + r.width / 2, r.y + r.height / 2);
|
70
54
|
};
|
71
|
-
|
72
55
|
exports.center = center;
|
73
56
|
//# sourceMappingURL=Rect.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["rect","x","y","width","height","Skia","XYWHRect","bounds","rects","Math","min","map","r","max","topLeft","isRRect","vec","topRight","bottomLeft","bottomRight","center"],"sources":["Rect.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { SkRect, SkRRect } from \"../types\";\nimport { isRRect } from \"../types\";\n\nimport { vec } from \"./Vector\";\n\nexport const rect = (x: number, y: number, width: number, height: number) => {\n \"worklet\";\n return Skia.XYWHRect(x, y, width, height);\n};\n\nexport const bounds = (rects: SkRect[]) => {\n \"worklet\";\n const x = Math.min(...rects.map((r) => r.x));\n const y = Math.min(...rects.map((r) => r.y));\n const width = Math.max(...rects.map((r) => r.x + r.width));\n const height = Math.max(...rects.map((r) => r.y + r.height));\n return rect(x, y, width - x, height - y);\n};\n\nexport const topLeft = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r) ? vec(r.rect.x, r.rect.y) : vec(r.x, r.y);\n};\n\nexport const topRight = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r)\n ? vec(r.rect.x + r.rect.width, r.rect.y)\n : vec(r.x + r.width, r.y);\n};\n\nexport const bottomLeft = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r)\n ? vec(r.rect.x, r.rect.y + r.rect.height)\n : vec(r.x, r.y + r.height);\n};\nexport const bottomRight = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r)\n ? vec(r.rect.x + r.rect.width, r.rect.y + r.rect.height)\n : vec(r.x + r.width, r.y + r.height);\n};\nexport const center = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r)\n ? vec(r.rect.x + r.rect.width / 2, r.rect.y + r.rect.height / 2)\n : vec(r.x + r.width / 2, r.y + r.height / 2);\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["_Skia","require","_types","_Vector","rect","x","y","width","height","Skia","XYWHRect","exports","bounds","rects","Math","min","map","r","max","topLeft","isRRect","vec","topRight","bottomLeft","bottomRight","center"],"sources":["Rect.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { SkRect, SkRRect } from \"../types\";\nimport { isRRect } from \"../types\";\n\nimport { vec } from \"./Vector\";\n\nexport const rect = (x: number, y: number, width: number, height: number) => {\n \"worklet\";\n return Skia.XYWHRect(x, y, width, height);\n};\n\nexport const bounds = (rects: SkRect[]) => {\n \"worklet\";\n const x = Math.min(...rects.map((r) => r.x));\n const y = Math.min(...rects.map((r) => r.y));\n const width = Math.max(...rects.map((r) => r.x + r.width));\n const height = Math.max(...rects.map((r) => r.y + r.height));\n return rect(x, y, width - x, height - y);\n};\n\nexport const topLeft = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r) ? vec(r.rect.x, r.rect.y) : vec(r.x, r.y);\n};\n\nexport const topRight = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r)\n ? vec(r.rect.x + r.rect.width, r.rect.y)\n : vec(r.x + r.width, r.y);\n};\n\nexport const bottomLeft = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r)\n ? vec(r.rect.x, r.rect.y + r.rect.height)\n : vec(r.x, r.y + r.height);\n};\nexport const bottomRight = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r)\n ? vec(r.rect.x + r.rect.width, r.rect.y + r.rect.height)\n : vec(r.x + r.width, r.y + r.height);\n};\nexport const center = (r: SkRect | SkRRect) => {\n \"worklet\";\n return isRRect(r)\n ? vec(r.rect.x + r.rect.width / 2, r.rect.y + r.rect.height / 2)\n : vec(r.x + r.width / 2, r.y + r.height / 2);\n};\n"],"mappings":"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"}
|
@@ -4,14 +4,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.useSVG = void 0;
|
7
|
-
|
8
7
|
var _Skia = require("../Skia");
|
9
|
-
|
10
8
|
var _Data = require("./Data");
|
11
|
-
|
12
9
|
const svgFactory = _Skia.Skia.SVG.MakeFromData.bind(_Skia.Skia.SVG);
|
13
|
-
|
14
10
|
const useSVG = (source, onError) => (0, _Data.useRawData)(source, svgFactory, onError);
|
15
|
-
|
16
11
|
exports.useSVG = useSVG;
|
17
12
|
//# sourceMappingURL=SVG.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["svgFactory","Skia","SVG","MakeFromData","bind","useSVG","source","onError","useRawData"],"sources":["SVG.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { DataSourceParam } from \"../types\";\n\nimport { useRawData } from \"./Data\";\n\nconst svgFactory = Skia.SVG.MakeFromData.bind(Skia.SVG);\n\nexport const useSVG = (\n source: DataSourceParam,\n onError?: (err: Error) => void\n) => useRawData(source, svgFactory, onError);\n"],"mappings":"
|
1
|
+
{"version":3,"names":["_Skia","require","_Data","svgFactory","Skia","SVG","MakeFromData","bind","useSVG","source","onError","useRawData","exports"],"sources":["SVG.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { DataSourceParam } from \"../types\";\n\nimport { useRawData } from \"./Data\";\n\nconst svgFactory = Skia.SVG.MakeFromData.bind(Skia.SVG);\n\nexport const useSVG = (\n source: DataSourceParam,\n onError?: (err: Error) => void\n) => useRawData(source, svgFactory, onError);\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAGA,IAAAC,KAAA,GAAAD,OAAA;AAEA,MAAME,UAAU,GAAGC,UAAI,CAACC,GAAG,CAACC,YAAY,CAACC,IAAI,CAACH,UAAI,CAACC,GAAG,CAAC;AAEhD,MAAMG,MAAM,GAAGA,CACpBC,MAAuB,EACvBC,OAA8B,KAC3B,IAAAC,gBAAU,EAACF,MAAM,EAAEN,UAAU,EAAEO,OAAO,CAAC;AAACE,OAAA,CAAAJ,MAAA,GAAAA,MAAA"}
|
@@ -4,18 +4,13 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.useTypeface = void 0;
|
7
|
-
|
8
7
|
var _Skia = require("../Skia");
|
9
|
-
|
10
8
|
var _Data = require("./Data");
|
11
|
-
|
12
9
|
const tfFactory = _Skia.Skia.Typeface.MakeFreeTypeFaceFromData.bind(_Skia.Skia.Typeface);
|
10
|
+
|
13
11
|
/**
|
14
12
|
* Returns a Skia Typeface object
|
15
13
|
* */
|
16
|
-
|
17
|
-
|
18
14
|
const useTypeface = (source, onError) => (0, _Data.useRawData)(source, tfFactory, onError);
|
19
|
-
|
20
15
|
exports.useTypeface = useTypeface;
|
21
16
|
//# sourceMappingURL=Typeface.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["tfFactory","Skia","Typeface","MakeFreeTypeFaceFromData","bind","useTypeface","source","onError","useRawData"],"sources":["Typeface.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { DataSourceParam } from \"../types\";\n\nimport { useRawData } from \"./Data\";\n\nconst tfFactory = Skia.Typeface.MakeFreeTypeFaceFromData.bind(Skia.Typeface);\n\n/**\n * Returns a Skia Typeface object\n * */\nexport const useTypeface = (\n source: DataSourceParam,\n onError?: (err: Error) => void\n) => useRawData(source, tfFactory, onError);\n"],"mappings":"
|
1
|
+
{"version":3,"names":["_Skia","require","_Data","tfFactory","Skia","Typeface","MakeFreeTypeFaceFromData","bind","useTypeface","source","onError","useRawData","exports"],"sources":["Typeface.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { DataSourceParam } from \"../types\";\n\nimport { useRawData } from \"./Data\";\n\nconst tfFactory = Skia.Typeface.MakeFreeTypeFaceFromData.bind(Skia.Typeface);\n\n/**\n * Returns a Skia Typeface object\n * */\nexport const useTypeface = (\n source: DataSourceParam,\n onError?: (err: Error) => void\n) => useRawData(source, tfFactory, onError);\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAGA,IAAAC,KAAA,GAAAD,OAAA;AAEA,MAAME,SAAS,GAAGC,UAAI,CAACC,QAAQ,CAACC,wBAAwB,CAACC,IAAI,CAACH,UAAI,CAACC,QAAQ,CAAC;;AAE5E;AACA;AACA;AACO,MAAMG,WAAW,GAAGA,CACzBC,MAAuB,EACvBC,OAA8B,KAC3B,IAAAC,gBAAU,EAACF,MAAM,EAAEN,SAAS,EAAEO,OAAO,CAAC;AAACE,OAAA,CAAAJ,WAAA,GAAAA,WAAA"}
|
@@ -4,50 +4,36 @@ Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
5
5
|
});
|
6
6
|
exports.vec = exports.sub = exports.point = exports.neg = exports.dist = exports.add = void 0;
|
7
|
-
|
8
7
|
var _Skia = require("../Skia");
|
9
|
-
|
10
|
-
const vec = function () {
|
8
|
+
const vec = (x = 0, y) => {
|
11
9
|
"worklet";
|
12
10
|
|
13
|
-
|
14
|
-
let y = arguments.length > 1 ? arguments[1] : undefined;
|
15
|
-
return _Skia.Skia.Point(x, y ?? x);
|
11
|
+
return _Skia.Skia.Point(x, y !== null && y !== void 0 ? y : x);
|
16
12
|
};
|
17
|
-
|
18
13
|
exports.vec = vec;
|
19
|
-
const point = vec;
|
20
|
-
exports.point = point;
|
21
|
-
|
14
|
+
const point = exports.point = vec;
|
22
15
|
const neg = a => {
|
23
16
|
"worklet";
|
24
17
|
|
25
18
|
return vec(-a.x, -a.y);
|
26
19
|
};
|
27
|
-
|
28
20
|
exports.neg = neg;
|
29
|
-
|
30
21
|
const add = (a, b) => {
|
31
22
|
"worklet";
|
32
23
|
|
33
24
|
return vec(a.x + b.x, a.y + b.y);
|
34
25
|
};
|
35
|
-
|
36
26
|
exports.add = add;
|
37
|
-
|
38
27
|
const sub = (a, b) => {
|
39
28
|
"worklet";
|
40
29
|
|
41
30
|
return vec(a.x - b.x, a.y - b.y);
|
42
31
|
};
|
43
|
-
|
44
32
|
exports.sub = sub;
|
45
|
-
|
46
33
|
const dist = (a, b) => {
|
47
34
|
"worklet";
|
48
35
|
|
49
36
|
return Math.hypot(a.x - b.x, a.y - b.y);
|
50
37
|
};
|
51
|
-
|
52
38
|
exports.dist = dist;
|
53
39
|
//# sourceMappingURL=Vector.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["vec","x","y","Skia","Point","point","neg","a","add","b","sub","dist","Math","hypot"],"sources":["Vector.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { Vector } from \"../types\";\n\nexport const vec = (x = 0, y?: number) => {\n \"worklet\";\n return Skia.Point(x, y ?? x);\n};\nexport const point = vec;\nexport const neg = (a: Vector) => {\n \"worklet\";\n return vec(-a.x, -a.y);\n};\nexport const add = (a: Vector, b: Vector) => {\n \"worklet\";\n return vec(a.x + b.x, a.y + b.y);\n};\nexport const sub = (a: Vector, b: Vector) => {\n \"worklet\";\n return vec(a.x - b.x, a.y - b.y);\n};\nexport const dist = (a: Vector, b: Vector) => {\n \"worklet\";\n return Math.hypot(a.x - b.x, a.y - b.y);\n};\n"],"mappings":"
|
1
|
+
{"version":3,"names":["_Skia","require","vec","x","y","Skia","Point","exports","point","neg","a","add","b","sub","dist","Math","hypot"],"sources":["Vector.ts"],"sourcesContent":["import { Skia } from \"../Skia\";\nimport type { Vector } from \"../types\";\n\nexport const vec = (x = 0, y?: number) => {\n \"worklet\";\n return Skia.Point(x, y ?? x);\n};\nexport const point = vec;\nexport const neg = (a: Vector) => {\n \"worklet\";\n return vec(-a.x, -a.y);\n};\nexport const add = (a: Vector, b: Vector) => {\n \"worklet\";\n return vec(a.x + b.x, a.y + b.y);\n};\nexport const sub = (a: Vector, b: Vector) => {\n \"worklet\";\n return vec(a.x - b.x, a.y - b.y);\n};\nexport const dist = (a: Vector, b: Vector) => {\n \"worklet\";\n return Math.hypot(a.x - b.x, a.y - b.y);\n};\n"],"mappings":";;;;;;AAAA,IAAAA,KAAA,GAAAC,OAAA;AAGO,MAAMC,GAAG,GAAGA,CAACC,CAAC,GAAG,CAAC,EAAEC,CAAU,KAAK;EACxC,SAAS;;EACT,OAAOC,UAAI,CAACC,KAAK,CAACH,CAAC,EAAEC,CAAC,aAADA,CAAC,cAADA,CAAC,GAAID,CAAC,CAAC;AAC9B,CAAC;AAACI,OAAA,CAAAL,GAAA,GAAAA,GAAA;AACK,MAAMM,KAAK,GAAAD,OAAA,CAAAC,KAAA,GAAGN,GAAG;AACjB,MAAMO,GAAG,GAAIC,CAAS,IAAK;EAChC,SAAS;;EACT,OAAOR,GAAG,CAAC,CAACQ,CAAC,CAACP,CAAC,EAAE,CAACO,CAAC,CAACN,CAAC,CAAC;AACxB,CAAC;AAACG,OAAA,CAAAE,GAAA,GAAAA,GAAA;AACK,MAAME,GAAG,GAAGA,CAACD,CAAS,EAAEE,CAAS,KAAK;EAC3C,SAAS;;EACT,OAAOV,GAAG,CAACQ,CAAC,CAACP,CAAC,GAAGS,CAAC,CAACT,CAAC,EAAEO,CAAC,CAACN,CAAC,GAAGQ,CAAC,CAACR,CAAC,CAAC;AAClC,CAAC;AAACG,OAAA,CAAAI,GAAA,GAAAA,GAAA;AACK,MAAME,GAAG,GAAGA,CAACH,CAAS,EAAEE,CAAS,KAAK;EAC3C,SAAS;;EACT,OAAOV,GAAG,CAACQ,CAAC,CAACP,CAAC,GAAGS,CAAC,CAACT,CAAC,EAAEO,CAAC,CAACN,CAAC,GAAGQ,CAAC,CAACR,CAAC,CAAC;AAClC,CAAC;AAACG,OAAA,CAAAM,GAAA,GAAAA,GAAA;AACK,MAAMC,IAAI,GAAGA,CAACJ,CAAS,EAAEE,CAAS,KAAK;EAC5C,SAAS;;EACT,OAAOG,IAAI,CAACC,KAAK,CAACN,CAAC,CAACP,CAAC,GAAGS,CAAC,CAACT,CAAC,EAAEO,CAAC,CAACN,CAAC,GAAGQ,CAAC,CAACR,CAAC,CAAC;AACzC,CAAC;AAACG,OAAA,CAAAO,IAAA,GAAAA,IAAA"}
|