@shopify/react-native-skia 0.1.130 → 0.1.131
Sign up to get free protection for your applications and to get access to all the features.
- package/README.md +8 -0
- package/android/cpp/jni/JniSkiaDrawView.cpp +3 -2
- package/android/src/main/java/com/shopify/reactnative/skia/SkiaDrawView.java +2 -1
- package/cpp/api/JsiSkCanvas.h +2 -2
- package/cpp/api/JsiSkMatrix.h +40 -27
- package/cpp/api/JsiSkPaint.h +3 -1
- package/cpp/api/JsiSkPath.h +67 -61
- package/cpp/api/JsiSkPathFactory.h +14 -1
- package/cpp/api/JsiSkRuntimeShaderBuilder.h +18 -0
- package/cpp/api/JsiSkTypeface.h +11 -2
- package/cpp/api/JsiSkTypefaceFactory.h +5 -1
- package/cpp/rnskia/RNSkInfoParameter.h +2 -0
- package/cpp/utils/RNSkLog.h +22 -0
- package/ios/RNSkia-iOS/SkiaDrawView.mm +2 -1
- package/lib/commonjs/animation/functions/index.js +47 -17
- package/lib/commonjs/animation/functions/index.js.map +1 -1
- package/lib/commonjs/animation/functions/interpolatePaths.js +45 -0
- package/lib/commonjs/animation/functions/interpolatePaths.js.map +1 -0
- package/lib/commonjs/animation/functions/interpolateVector.js +20 -0
- package/lib/commonjs/animation/functions/interpolateVector.js.map +1 -0
- package/lib/commonjs/index.js +13 -0
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/renderer/Canvas.js +19 -35
- package/lib/commonjs/renderer/Canvas.js.map +1 -1
- package/lib/commonjs/renderer/HostConfig.js +2 -2
- package/lib/commonjs/renderer/HostConfig.js.map +1 -1
- package/lib/commonjs/renderer/components/Blend.js +10 -7
- package/lib/commonjs/renderer/components/Blend.js.map +1 -1
- package/lib/commonjs/renderer/components/Compose.js +9 -6
- package/lib/commonjs/renderer/components/Compose.js.map +1 -1
- package/lib/commonjs/renderer/components/Group.js +7 -6
- package/lib/commonjs/renderer/components/Group.js.map +1 -1
- package/lib/commonjs/renderer/components/Mask.js +13 -10
- package/lib/commonjs/renderer/components/Mask.js.map +1 -1
- package/lib/commonjs/renderer/components/Paint.js +7 -4
- package/lib/commonjs/renderer/components/Paint.js.map +1 -1
- package/lib/commonjs/renderer/components/Picture.js.map +1 -1
- package/lib/commonjs/renderer/components/backdrop/BackdropFilter.js +1 -1
- package/lib/commonjs/renderer/components/backdrop/BackdropFilter.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/BlendColor.js +7 -6
- package/lib/commonjs/renderer/components/colorFilters/BlendColor.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/Compose.js +6 -6
- package/lib/commonjs/renderer/components/colorFilters/Compose.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/Lerp.js +8 -7
- package/lib/commonjs/renderer/components/colorFilters/Lerp.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/LinearToSRGBGamma.js +6 -6
- package/lib/commonjs/renderer/components/colorFilters/LinearToSRGBGamma.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/LumaColorFilter.js +6 -6
- package/lib/commonjs/renderer/components/colorFilters/LumaColorFilter.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/Matrix.js +6 -7
- package/lib/commonjs/renderer/components/colorFilters/Matrix.js.map +1 -1
- package/lib/commonjs/renderer/components/colorFilters/SRGBToLinearGamma.js +6 -6
- package/lib/commonjs/renderer/components/colorFilters/SRGBToLinearGamma.js.map +1 -1
- package/lib/commonjs/renderer/components/image/BoxFit.js +7 -9
- package/lib/commonjs/renderer/components/image/BoxFit.js.map +1 -1
- package/lib/commonjs/renderer/components/image/Image.js +3 -2
- package/lib/commonjs/renderer/components/image/Image.js.map +1 -1
- package/lib/commonjs/renderer/components/image/ImageSVG.js +3 -2
- package/lib/commonjs/renderer/components/image/ImageSVG.js.map +1 -1
- package/lib/commonjs/renderer/components/image/ImageShader.js +9 -6
- package/lib/commonjs/renderer/components/image/ImageShader.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/Blur.js +7 -4
- package/lib/commonjs/renderer/components/imageFilters/Blur.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/DisplacementMap.js +10 -7
- package/lib/commonjs/renderer/components/imageFilters/DisplacementMap.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/InnerShadow.js +10 -15
- package/lib/commonjs/renderer/components/imageFilters/InnerShadow.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/Morphology.js +7 -6
- package/lib/commonjs/renderer/components/imageFilters/Morphology.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/Offset.js +5 -4
- package/lib/commonjs/renderer/components/imageFilters/Offset.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/RuntimeShader.js +13 -6
- package/lib/commonjs/renderer/components/imageFilters/RuntimeShader.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/Shadow.js +8 -7
- package/lib/commonjs/renderer/components/imageFilters/Shadow.js.map +1 -1
- package/lib/commonjs/renderer/components/imageFilters/getInput.js +7 -7
- package/lib/commonjs/renderer/components/imageFilters/getInput.js.map +1 -1
- package/lib/commonjs/renderer/components/maskFilters/Blur.js +6 -3
- package/lib/commonjs/renderer/components/maskFilters/Blur.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Corner.js +8 -6
- package/lib/commonjs/renderer/components/pathEffects/Corner.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Dash.js +8 -6
- package/lib/commonjs/renderer/components/pathEffects/Dash.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Discrete.js +8 -6
- package/lib/commonjs/renderer/components/pathEffects/Discrete.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Line2D.js +8 -6
- package/lib/commonjs/renderer/components/pathEffects/Line2D.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Path1D.js +8 -6
- package/lib/commonjs/renderer/components/pathEffects/Path1D.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Path2D.js +8 -6
- package/lib/commonjs/renderer/components/pathEffects/Path2D.js.map +1 -1
- package/lib/commonjs/renderer/components/pathEffects/Sum.js +7 -4
- package/lib/commonjs/renderer/components/pathEffects/Sum.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/Color.js +7 -4
- package/lib/commonjs/renderer/components/shaders/Color.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/FractalNoise.js +5 -4
- package/lib/commonjs/renderer/components/shaders/FractalNoise.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/Gradient.js +5 -5
- package/lib/commonjs/renderer/components/shaders/Gradient.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/LinearGradient.js +6 -5
- package/lib/commonjs/renderer/components/shaders/LinearGradient.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/RadialGradient.js +6 -5
- package/lib/commonjs/renderer/components/shaders/RadialGradient.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/Shader.js +6 -43
- package/lib/commonjs/renderer/components/shaders/Shader.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/SweepGradient.js +6 -5
- package/lib/commonjs/renderer/components/shaders/SweepGradient.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/Turbulence.js +5 -4
- package/lib/commonjs/renderer/components/shaders/Turbulence.js.map +1 -1
- package/lib/commonjs/renderer/components/shaders/TwoPointConicalGradient.js +6 -5
- package/lib/commonjs/renderer/components/shaders/TwoPointConicalGradient.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Box.js +26 -29
- package/lib/commonjs/renderer/components/shapes/Box.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Circle.js +7 -5
- package/lib/commonjs/renderer/components/shapes/Circle.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/DiffRect.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/FitBox.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Line.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Oval.js +3 -2
- package/lib/commonjs/renderer/components/shapes/Oval.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Patch.js +8 -5
- package/lib/commonjs/renderer/components/shapes/Patch.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Path.js +5 -4
- package/lib/commonjs/renderer/components/shapes/Path.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Points.js +2 -2
- package/lib/commonjs/renderer/components/shapes/Points.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Rect.js +3 -2
- package/lib/commonjs/renderer/components/shapes/Rect.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/RoundedRect.js +3 -2
- package/lib/commonjs/renderer/components/shapes/RoundedRect.js.map +1 -1
- package/lib/commonjs/renderer/components/shapes/Vertices.js +9 -8
- package/lib/commonjs/renderer/components/shapes/Vertices.js.map +1 -1
- package/lib/commonjs/renderer/components/text/Glyphs.js +3 -2
- package/lib/commonjs/renderer/components/text/Glyphs.js.map +1 -1
- package/lib/commonjs/renderer/components/text/Text.js +3 -2
- package/lib/commonjs/renderer/components/text/Text.js.map +1 -1
- package/lib/commonjs/renderer/components/text/TextBlob.js.map +1 -1
- package/lib/commonjs/renderer/components/text/TextPath.js +7 -11
- package/lib/commonjs/renderer/components/text/TextPath.js.map +1 -1
- package/lib/commonjs/renderer/index.js +13 -13
- package/lib/commonjs/renderer/index.js.map +1 -1
- package/lib/commonjs/renderer/nodes/Declaration.js.map +1 -1
- package/lib/commonjs/renderer/nodes/Drawing.js +5 -5
- package/lib/commonjs/renderer/nodes/Drawing.js.map +1 -1
- package/lib/commonjs/renderer/nodes/Node.js.map +1 -1
- package/lib/commonjs/renderer/processors/Animations/Animations.js.map +1 -1
- package/lib/commonjs/renderer/processors/Circles.js +2 -4
- package/lib/commonjs/renderer/processors/Circles.js.map +1 -1
- package/lib/commonjs/renderer/processors/Clips.js +5 -5
- package/lib/commonjs/renderer/processors/Clips.js.map +1 -1
- package/lib/commonjs/{skia/core → renderer/processors}/Color.js +2 -6
- package/lib/commonjs/renderer/processors/Color.js.map +1 -0
- package/lib/commonjs/renderer/processors/Font.js +4 -4
- package/lib/commonjs/renderer/processors/Font.js.map +1 -1
- package/lib/commonjs/renderer/processors/Paint.js +18 -14
- package/lib/commonjs/renderer/processors/Paint.js.map +1 -1
- package/lib/commonjs/renderer/processors/Paths.js +4 -4
- package/lib/commonjs/renderer/processors/Paths.js.map +1 -1
- package/lib/commonjs/renderer/processors/Radius.js +2 -4
- package/lib/commonjs/renderer/processors/Radius.js.map +1 -1
- package/lib/commonjs/renderer/processors/Rects.js +8 -59
- package/lib/commonjs/renderer/processors/Rects.js.map +1 -1
- package/lib/commonjs/renderer/processors/Transform.js +26 -17
- package/lib/commonjs/renderer/processors/Transform.js.map +1 -1
- package/lib/commonjs/renderer/processors/index.js +26 -13
- package/lib/commonjs/renderer/processors/index.js.map +1 -1
- package/lib/commonjs/renderer/processors/math/Coordinates.js.map +1 -1
- package/lib/commonjs/renderer/processors/math/Transforms.js.map +1 -1
- package/lib/commonjs/renderer/processors/math/index.js +0 -26
- package/lib/commonjs/renderer/processors/math/index.js.map +1 -1
- package/lib/commonjs/renderer/useCanvas.js +30 -0
- package/lib/commonjs/renderer/useCanvas.js.map +1 -0
- package/lib/commonjs/skia/NativeSetup.js +1 -1
- package/lib/commonjs/skia/NativeSetup.js.map +1 -1
- package/lib/commonjs/skia/Skia.web.js +12 -0
- package/lib/commonjs/skia/Skia.web.js.map +1 -0
- package/lib/commonjs/skia/core/Data.js +9 -4
- package/lib/commonjs/skia/core/Data.js.map +1 -1
- package/lib/commonjs/skia/core/Font.js +2 -4
- package/lib/commonjs/skia/core/Font.js.map +1 -1
- package/lib/commonjs/skia/core/Matrix.js +15 -0
- package/lib/commonjs/skia/core/Matrix.js.map +1 -0
- package/lib/commonjs/skia/core/Paint.js +4 -12
- package/lib/commonjs/skia/core/Paint.js.map +1 -1
- package/lib/commonjs/skia/core/Path.js +14 -2
- package/lib/commonjs/skia/core/Path.js.map +1 -1
- package/lib/commonjs/skia/core/RRect.js +13 -0
- package/lib/commonjs/skia/core/RRect.js.map +1 -0
- package/lib/commonjs/skia/core/Rect.js +47 -0
- package/lib/commonjs/skia/core/Rect.js.map +1 -0
- package/lib/commonjs/skia/core/Vector.js +49 -0
- package/lib/commonjs/skia/core/Vector.js.map +1 -0
- package/lib/commonjs/skia/core/index.js +51 -25
- package/lib/commonjs/skia/core/index.js.map +1 -1
- package/lib/commonjs/skia/types/Image/ImageFactory.js.map +1 -1
- package/lib/commonjs/skia/types/Matrix.js +58 -1
- package/lib/commonjs/skia/types/Matrix.js.map +1 -1
- package/lib/commonjs/skia/types/Path/Path.js +1 -0
- package/lib/commonjs/skia/types/Path/Path.js.map +1 -1
- package/lib/commonjs/skia/types/Point.js.map +1 -1
- package/lib/commonjs/skia/types/RRect.js +7 -0
- package/lib/commonjs/skia/types/RRect.js.map +1 -1
- package/lib/commonjs/skia/types/Shader/Shader.js +51 -1
- package/lib/commonjs/skia/types/Shader/Shader.js.map +1 -1
- package/lib/commonjs/skia/web/{api/Host.js → Host.js} +10 -1
- package/lib/commonjs/skia/web/Host.js.map +1 -0
- package/lib/commonjs/skia/web/JsiImageFilterFactory.js +68 -0
- package/lib/commonjs/skia/web/JsiImageFilterFactory.js.map +1 -0
- package/lib/commonjs/skia/web/{api/JsiSkCanvas.js → JsiSkCanvas.js} +20 -6
- package/lib/commonjs/skia/web/JsiSkCanvas.js.map +1 -0
- package/lib/commonjs/skia/web/{api/JsiSkColor.js → JsiSkColor.js} +163 -4
- package/lib/commonjs/skia/web/JsiSkColor.js.map +1 -0
- package/lib/commonjs/skia/web/{api/JsiSkColorFilter.js → JsiSkColorFilter.js} +0 -0
- package/lib/commonjs/skia/web/{api/JsiSkColorFilter.js.map → JsiSkColorFilter.js.map} +1 -1
- package/lib/commonjs/skia/web/JsiSkColorFilterFactory.js +48 -0
- package/lib/commonjs/skia/web/JsiSkColorFilterFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkContourMeasure.js +42 -0
- package/lib/commonjs/skia/web/JsiSkContourMeasure.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkContourMeasureIter.js +30 -0
- package/lib/commonjs/skia/web/JsiSkContourMeasureIter.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkData.js +18 -0
- package/lib/commonjs/skia/web/JsiSkData.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkDataFactory.js +44 -0
- package/lib/commonjs/skia/web/JsiSkDataFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkFont.js +111 -0
- package/lib/commonjs/skia/web/JsiSkFont.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkFontMgr.js +35 -0
- package/lib/commonjs/skia/web/JsiSkFontMgr.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkFontMgrFactory.js +25 -0
- package/lib/commonjs/skia/web/JsiSkFontMgrFactory.js.map +1 -0
- package/lib/commonjs/skia/web/{api/JsiSkImage.js → JsiSkImage.js} +0 -0
- package/lib/commonjs/skia/web/{api/JsiSkImage.js.map → JsiSkImage.js.map} +1 -1
- package/lib/commonjs/skia/web/JsiSkImageFactory.js +47 -0
- package/lib/commonjs/skia/web/JsiSkImageFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkImageFilter.js +18 -0
- package/lib/commonjs/skia/web/JsiSkImageFilter.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkMaskFilter.js +18 -0
- package/lib/commonjs/skia/web/JsiSkMaskFilter.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkMaskFilterFactory.js +24 -0
- package/lib/commonjs/skia/web/JsiSkMaskFilterFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkMatrix.js +38 -0
- package/lib/commonjs/skia/web/JsiSkMatrix.js.map +1 -0
- package/lib/commonjs/skia/web/{api/JsiSkPaint.js → JsiSkPaint.js} +4 -9
- package/lib/commonjs/skia/web/JsiSkPaint.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkPath.js +324 -0
- package/lib/commonjs/skia/web/JsiSkPath.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkPathEffect.js +18 -0
- package/lib/commonjs/skia/web/JsiSkPathEffect.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkPathEffectFactory.js +78 -0
- package/lib/commonjs/skia/web/JsiSkPathEffectFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkPathFactory.js +58 -0
- package/lib/commonjs/skia/web/JsiSkPathFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkPicture.js +29 -0
- package/lib/commonjs/skia/web/JsiSkPicture.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkPictureFactory.js +30 -0
- package/lib/commonjs/skia/web/JsiSkPictureFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkPictureRecorder.js +30 -0
- package/lib/commonjs/skia/web/JsiSkPictureRecorder.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkPoint.js +26 -0
- package/lib/commonjs/skia/web/JsiSkPoint.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkRRect.js +32 -0
- package/lib/commonjs/skia/web/JsiSkRRect.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkRSXform.js +18 -0
- package/lib/commonjs/skia/web/JsiSkRSXform.js.map +1 -0
- package/lib/commonjs/skia/web/{api/JsiSkRect.js → JsiSkRect.js} +8 -0
- package/lib/commonjs/skia/web/JsiSkRect.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkRuntimeEffect.js +44 -0
- package/lib/commonjs/skia/web/JsiSkRuntimeEffect.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkRuntimeEffectFactory.js +30 -0
- package/lib/commonjs/skia/web/JsiSkRuntimeEffectFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkSVGFactory.js +26 -0
- package/lib/commonjs/skia/web/JsiSkSVGFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkShader.js +18 -0
- package/lib/commonjs/skia/web/JsiSkShader.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkShaderFactory.js +52 -0
- package/lib/commonjs/skia/web/JsiSkShaderFactory.js.map +1 -0
- package/lib/commonjs/skia/web/{api/JsiSkSurface.js → JsiSkSurface.js} +0 -0
- package/lib/commonjs/skia/web/{api/JsiSkSurface.js.map → JsiSkSurface.js.map} +1 -1
- package/lib/commonjs/skia/web/{api/JsiSkSurfaceFactory.js → JsiSkSurfaceFactory.js} +0 -0
- package/lib/commonjs/skia/web/{api/JsiSkSurfaceFactory.js.map → JsiSkSurfaceFactory.js.map} +1 -1
- package/lib/commonjs/skia/web/JsiSkTextBlob.js +18 -0
- package/lib/commonjs/skia/web/JsiSkTextBlob.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkTextBlobFactory.js +36 -0
- package/lib/commonjs/skia/web/JsiSkTextBlobFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkTypeface.js +28 -0
- package/lib/commonjs/skia/web/JsiSkTypeface.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkTypefaceFactory.js +30 -0
- package/lib/commonjs/skia/web/JsiSkTypefaceFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkVertices.js +28 -0
- package/lib/commonjs/skia/web/JsiSkVertices.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkVerticesFactory.js +27 -0
- package/lib/commonjs/skia/web/JsiSkVerticesFactory.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkia.js +97 -0
- package/lib/commonjs/skia/web/JsiSkia.js.map +1 -0
- package/lib/commonjs/skia/web/index.js +4 -4
- package/lib/commonjs/skia/web/index.js.map +1 -1
- package/lib/commonjs/values/web/api.js +2 -2
- package/lib/commonjs/values/web/api.js.map +1 -1
- package/lib/commonjs/views/SkiaView.web.js +216 -0
- package/lib/commonjs/views/SkiaView.web.js.map +1 -0
- package/lib/commonjs/views/types.js.map +1 -1
- package/lib/commonjs/views/useTouchHandler.js +70 -46
- package/lib/commonjs/views/useTouchHandler.js.map +1 -1
- package/lib/commonjs/web/index.js +20 -0
- package/lib/commonjs/web/index.js.map +1 -0
- package/lib/module/animation/functions/index.js +4 -2
- package/lib/module/animation/functions/index.js.map +1 -1
- package/lib/module/animation/functions/interpolatePaths.js +36 -0
- package/lib/module/animation/functions/interpolatePaths.js.map +1 -0
- package/lib/module/animation/functions/interpolateVector.js +7 -0
- package/lib/module/animation/functions/interpolateVector.js.map +1 -0
- package/lib/module/index.js +1 -0
- package/lib/module/index.js.map +1 -1
- package/lib/module/renderer/Canvas.js +15 -26
- package/lib/module/renderer/Canvas.js.map +1 -1
- package/lib/module/renderer/HostConfig.js +2 -2
- package/lib/module/renderer/HostConfig.js.map +1 -1
- package/lib/module/renderer/components/Blend.js +5 -2
- package/lib/module/renderer/components/Blend.js.map +1 -1
- package/lib/module/renderer/components/Compose.js +5 -2
- package/lib/module/renderer/components/Compose.js.map +1 -1
- package/lib/module/renderer/components/Group.js +7 -6
- package/lib/module/renderer/components/Group.js.map +1 -1
- package/lib/module/renderer/components/Mask.js +7 -3
- package/lib/module/renderer/components/Mask.js.map +1 -1
- package/lib/module/renderer/components/Paint.js +6 -3
- 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/BackdropFilter.js +1 -1
- package/lib/module/renderer/components/backdrop/BackdropFilter.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/BlendColor.js +6 -3
- package/lib/module/renderer/components/colorFilters/BlendColor.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/Compose.js +2 -2
- package/lib/module/renderer/components/colorFilters/Compose.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/Lerp.js +6 -3
- package/lib/module/renderer/components/colorFilters/Lerp.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/LinearToSRGBGamma.js +5 -3
- package/lib/module/renderer/components/colorFilters/LinearToSRGBGamma.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/LumaColorFilter.js +5 -3
- package/lib/module/renderer/components/colorFilters/LumaColorFilter.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/Matrix.js +5 -3
- package/lib/module/renderer/components/colorFilters/Matrix.js.map +1 -1
- package/lib/module/renderer/components/colorFilters/SRGBToLinearGamma.js +5 -3
- package/lib/module/renderer/components/colorFilters/SRGBToLinearGamma.js.map +1 -1
- package/lib/module/renderer/components/image/BoxFit.js +7 -8
- package/lib/module/renderer/components/image/BoxFit.js.map +1 -1
- package/lib/module/renderer/components/image/Image.js +3 -2
- package/lib/module/renderer/components/image/Image.js.map +1 -1
- package/lib/module/renderer/components/image/ImageSVG.js +3 -2
- package/lib/module/renderer/components/image/ImageSVG.js.map +1 -1
- package/lib/module/renderer/components/image/ImageShader.js +10 -7
- package/lib/module/renderer/components/image/ImageShader.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/Blur.js +7 -4
- package/lib/module/renderer/components/imageFilters/Blur.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/DisplacementMap.js +7 -4
- package/lib/module/renderer/components/imageFilters/DisplacementMap.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/InnerShadow.js +3 -3
- package/lib/module/renderer/components/imageFilters/InnerShadow.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/Morphology.js +6 -4
- package/lib/module/renderer/components/imageFilters/Morphology.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/Offset.js +5 -3
- package/lib/module/renderer/components/imageFilters/Offset.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/RuntimeShader.js +13 -4
- package/lib/module/renderer/components/imageFilters/RuntimeShader.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/Shadow.js +6 -5
- package/lib/module/renderer/components/imageFilters/Shadow.js.map +1 -1
- package/lib/module/renderer/components/imageFilters/getInput.js +2 -2
- package/lib/module/renderer/components/imageFilters/getInput.js.map +1 -1
- package/lib/module/renderer/components/maskFilters/Blur.js +5 -2
- package/lib/module/renderer/components/maskFilters/Blur.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Corner.js +5 -2
- package/lib/module/renderer/components/pathEffects/Corner.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Dash.js +5 -2
- package/lib/module/renderer/components/pathEffects/Dash.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Discrete.js +5 -2
- package/lib/module/renderer/components/pathEffects/Discrete.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Line2D.js +5 -2
- package/lib/module/renderer/components/pathEffects/Line2D.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Path1D.js +6 -3
- package/lib/module/renderer/components/pathEffects/Path1D.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Path2D.js +6 -3
- package/lib/module/renderer/components/pathEffects/Path2D.js.map +1 -1
- package/lib/module/renderer/components/pathEffects/Sum.js +5 -2
- package/lib/module/renderer/components/pathEffects/Sum.js.map +1 -1
- package/lib/module/renderer/components/shaders/Color.js +6 -3
- package/lib/module/renderer/components/shaders/Color.js.map +1 -1
- package/lib/module/renderer/components/shaders/FractalNoise.js +4 -2
- package/lib/module/renderer/components/shaders/FractalNoise.js.map +1 -1
- package/lib/module/renderer/components/shaders/Gradient.js +3 -3
- package/lib/module/renderer/components/shaders/Gradient.js.map +1 -1
- package/lib/module/renderer/components/shaders/LinearGradient.js +5 -3
- package/lib/module/renderer/components/shaders/LinearGradient.js.map +1 -1
- package/lib/module/renderer/components/shaders/RadialGradient.js +5 -3
- package/lib/module/renderer/components/shaders/RadialGradient.js.map +1 -1
- package/lib/module/renderer/components/shaders/Shader.js +6 -44
- package/lib/module/renderer/components/shaders/Shader.js.map +1 -1
- package/lib/module/renderer/components/shaders/SweepGradient.js +5 -3
- package/lib/module/renderer/components/shaders/SweepGradient.js.map +1 -1
- package/lib/module/renderer/components/shaders/Turbulence.js +4 -2
- package/lib/module/renderer/components/shaders/Turbulence.js.map +1 -1
- package/lib/module/renderer/components/shaders/TwoPointConicalGradient.js +5 -3
- package/lib/module/renderer/components/shaders/TwoPointConicalGradient.js.map +1 -1
- package/lib/module/renderer/components/shapes/Box.js +20 -19
- package/lib/module/renderer/components/shapes/Box.js.map +1 -1
- package/lib/module/renderer/components/shapes/Circle.js +7 -4
- 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/FitBox.js.map +1 -1
- package/lib/module/renderer/components/shapes/Line.js.map +1 -1
- package/lib/module/renderer/components/shapes/Oval.js +3 -2
- package/lib/module/renderer/components/shapes/Oval.js.map +1 -1
- package/lib/module/renderer/components/shapes/Patch.js +5 -3
- package/lib/module/renderer/components/shapes/Patch.js.map +1 -1
- package/lib/module/renderer/components/shapes/Path.js +4 -3
- package/lib/module/renderer/components/shapes/Path.js.map +1 -1
- package/lib/module/renderer/components/shapes/Points.js +1 -1
- package/lib/module/renderer/components/shapes/Points.js.map +1 -1
- package/lib/module/renderer/components/shapes/Rect.js +3 -2
- package/lib/module/renderer/components/shapes/Rect.js.map +1 -1
- package/lib/module/renderer/components/shapes/RoundedRect.js +3 -2
- package/lib/module/renderer/components/shapes/RoundedRect.js.map +1 -1
- package/lib/module/renderer/components/shapes/Vertices.js +5 -3
- package/lib/module/renderer/components/shapes/Vertices.js.map +1 -1
- package/lib/module/renderer/components/text/Glyphs.js +3 -2
- package/lib/module/renderer/components/text/Glyphs.js.map +1 -1
- package/lib/module/renderer/components/text/Text.js +3 -2
- package/lib/module/renderer/components/text/Text.js.map +1 -1
- package/lib/module/renderer/components/text/TextBlob.js.map +1 -1
- package/lib/module/renderer/components/text/TextPath.js +3 -3
- package/lib/module/renderer/components/text/TextPath.js.map +1 -1
- package/lib/module/renderer/index.js +1 -1
- package/lib/module/renderer/index.js.map +1 -1
- package/lib/module/renderer/nodes/Declaration.js.map +1 -1
- package/lib/module/renderer/nodes/Drawing.js +3 -3
- package/lib/module/renderer/nodes/Drawing.js.map +1 -1
- package/lib/module/renderer/nodes/Node.js.map +1 -1
- package/lib/module/renderer/processors/Animations/Animations.js.map +1 -1
- package/lib/module/renderer/processors/Circles.js +2 -4
- package/lib/module/renderer/processors/Circles.js.map +1 -1
- package/lib/module/renderer/processors/Clips.js +3 -3
- package/lib/module/renderer/processors/Clips.js.map +1 -1
- package/lib/module/{skia/core → renderer/processors}/Color.js +1 -2
- package/lib/module/renderer/processors/Color.js.map +1 -0
- package/lib/module/renderer/processors/Font.js +3 -2
- package/lib/module/renderer/processors/Font.js.map +1 -1
- package/lib/module/renderer/processors/Paint.js +8 -5
- package/lib/module/renderer/processors/Paint.js.map +1 -1
- package/lib/module/renderer/processors/Paths.js +2 -2
- package/lib/module/renderer/processors/Paths.js.map +1 -1
- package/lib/module/renderer/processors/Radius.js +2 -3
- package/lib/module/renderer/processors/Radius.js.map +1 -1
- package/lib/module/renderer/processors/Rects.js +7 -26
- package/lib/module/renderer/processors/Rects.js.map +1 -1
- package/lib/module/renderer/processors/Transform.js +24 -16
- package/lib/module/renderer/processors/Transform.js.map +1 -1
- package/lib/module/renderer/processors/index.js +2 -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/Transforms.js.map +1 -1
- package/lib/module/renderer/processors/math/index.js +0 -2
- package/lib/module/renderer/processors/math/index.js.map +1 -1
- package/lib/module/renderer/useCanvas.js +13 -0
- package/lib/module/renderer/useCanvas.js.map +1 -0
- package/lib/module/skia/NativeSetup.js +2 -2
- package/lib/module/skia/NativeSetup.js.map +1 -1
- package/lib/module/skia/Skia.web.js +3 -0
- package/lib/module/skia/Skia.web.js.map +1 -0
- package/lib/module/skia/core/Data.js +11 -5
- package/lib/module/skia/core/Data.js.map +1 -1
- package/lib/module/skia/core/Font.js +2 -4
- package/lib/module/skia/core/Font.js.map +1 -1
- package/lib/module/skia/core/Matrix.js +4 -0
- package/lib/module/skia/core/Matrix.js.map +1 -0
- package/lib/module/skia/core/Paint.js +3 -7
- package/lib/module/skia/core/Paint.js.map +1 -1
- package/lib/module/skia/core/Path.js +11 -2
- package/lib/module/skia/core/Path.js.map +1 -1
- package/lib/module/skia/core/RRect.js +3 -0
- package/lib/module/skia/core/RRect.js.map +1 -0
- package/lib/module/skia/core/Rect.js +17 -0
- package/lib/module/skia/core/Rect.js.map +1 -0
- package/lib/module/{renderer/processors/math → skia/core}/Vector.js +2 -7
- package/lib/module/skia/core/Vector.js.map +1 -0
- package/lib/module/skia/core/index.js +5 -3
- package/lib/module/skia/core/index.js.map +1 -1
- package/lib/module/skia/types/Image/ImageFactory.js.map +1 -1
- package/lib/module/skia/types/Matrix.js +55 -0
- package/lib/module/skia/types/Matrix.js.map +1 -1
- package/lib/module/skia/types/Path/Path.js +1 -0
- package/lib/module/skia/types/Path/Path.js.map +1 -1
- package/lib/module/skia/types/Point.js.map +1 -1
- package/lib/module/skia/types/RRect.js +3 -1
- package/lib/module/skia/types/RRect.js.map +1 -1
- package/lib/module/skia/types/Shader/Shader.js +48 -0
- package/lib/module/skia/types/Shader/Shader.js.map +1 -1
- package/lib/module/skia/web/{api/Host.js → Host.js} +6 -0
- package/lib/module/skia/web/Host.js.map +1 -0
- package/lib/module/skia/web/JsiImageFilterFactory.js +57 -0
- package/lib/module/skia/web/JsiImageFilterFactory.js.map +1 -0
- package/lib/module/skia/web/{api/JsiSkCanvas.js → JsiSkCanvas.js} +19 -6
- package/lib/module/skia/web/JsiSkCanvas.js.map +1 -0
- package/lib/module/skia/web/{api/JsiSkColor.js → JsiSkColor.js} +164 -4
- package/lib/module/skia/web/JsiSkColor.js.map +1 -0
- package/lib/module/skia/web/{api/JsiSkColorFilter.js → JsiSkColorFilter.js} +0 -0
- package/lib/module/skia/web/{api/JsiSkColorFilter.js.map → JsiSkColorFilter.js.map} +1 -1
- package/lib/module/skia/web/JsiSkColorFilterFactory.js +37 -0
- package/lib/module/skia/web/JsiSkColorFilterFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkContourMeasure.js +31 -0
- package/lib/module/skia/web/JsiSkContourMeasure.js.map +1 -0
- package/lib/module/skia/web/JsiSkContourMeasureIter.js +19 -0
- package/lib/module/skia/web/JsiSkContourMeasureIter.js.map +1 -0
- package/lib/module/skia/web/JsiSkData.js +8 -0
- package/lib/module/skia/web/JsiSkData.js.map +1 -0
- package/lib/module/skia/web/JsiSkDataFactory.js +33 -0
- package/lib/module/skia/web/JsiSkDataFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkFont.js +99 -0
- package/lib/module/skia/web/JsiSkFont.js.map +1 -0
- package/lib/module/skia/web/JsiSkFontMgr.js +25 -0
- package/lib/module/skia/web/JsiSkFontMgr.js.map +1 -0
- package/lib/module/skia/web/JsiSkFontMgrFactory.js +14 -0
- package/lib/module/skia/web/JsiSkFontMgrFactory.js.map +1 -0
- package/lib/module/skia/web/{api/JsiSkImage.js → JsiSkImage.js} +0 -0
- package/lib/module/skia/web/{api/JsiSkImage.js.map → JsiSkImage.js.map} +1 -1
- package/lib/module/skia/web/JsiSkImageFactory.js +36 -0
- package/lib/module/skia/web/JsiSkImageFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkImageFilter.js +8 -0
- package/lib/module/skia/web/JsiSkImageFilter.js.map +1 -0
- package/lib/module/skia/web/JsiSkMaskFilter.js +8 -0
- package/lib/module/skia/web/JsiSkMaskFilter.js.map +1 -0
- package/lib/module/skia/web/JsiSkMaskFilterFactory.js +13 -0
- package/lib/module/skia/web/JsiSkMaskFilterFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkMatrix.js +28 -0
- package/lib/module/skia/web/JsiSkMatrix.js.map +1 -0
- package/lib/module/skia/web/{api/JsiSkPaint.js → JsiSkPaint.js} +5 -10
- package/lib/module/skia/web/JsiSkPaint.js.map +1 -0
- package/lib/module/skia/web/JsiSkPath.js +311 -0
- package/lib/module/skia/web/JsiSkPath.js.map +1 -0
- package/lib/module/skia/web/JsiSkPathEffect.js +8 -0
- package/lib/module/skia/web/JsiSkPathEffect.js.map +1 -0
- package/lib/module/skia/web/JsiSkPathEffectFactory.js +67 -0
- package/lib/module/skia/web/JsiSkPathEffectFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkPathFactory.js +47 -0
- package/lib/module/skia/web/JsiSkPathFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkPicture.js +18 -0
- package/lib/module/skia/web/JsiSkPicture.js.map +1 -0
- package/lib/module/skia/web/JsiSkPictureFactory.js +19 -0
- package/lib/module/skia/web/JsiSkPictureFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkPictureRecorder.js +18 -0
- package/lib/module/skia/web/JsiSkPictureRecorder.js.map +1 -0
- package/lib/module/skia/web/JsiSkPoint.js +16 -0
- package/lib/module/skia/web/JsiSkPoint.js.map +1 -0
- package/lib/module/skia/web/JsiSkRRect.js +21 -0
- package/lib/module/skia/web/JsiSkRRect.js.map +1 -0
- package/lib/module/skia/web/JsiSkRSXform.js +8 -0
- package/lib/module/skia/web/JsiSkRSXform.js.map +1 -0
- package/lib/module/skia/web/{api/JsiSkRect.js → JsiSkRect.js} +8 -0
- package/lib/module/skia/web/JsiSkRect.js.map +1 -0
- package/lib/module/skia/web/JsiSkRuntimeEffect.js +33 -0
- package/lib/module/skia/web/JsiSkRuntimeEffect.js.map +1 -0
- package/lib/module/skia/web/JsiSkRuntimeEffectFactory.js +19 -0
- package/lib/module/skia/web/JsiSkRuntimeEffectFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkSVGFactory.js +16 -0
- package/lib/module/skia/web/JsiSkSVGFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkShader.js +8 -0
- package/lib/module/skia/web/JsiSkShader.js.map +1 -0
- package/lib/module/skia/web/JsiSkShaderFactory.js +41 -0
- package/lib/module/skia/web/JsiSkShaderFactory.js.map +1 -0
- package/lib/module/skia/web/{api/JsiSkSurface.js → JsiSkSurface.js} +0 -0
- package/lib/module/skia/web/{api/JsiSkSurface.js.map → JsiSkSurface.js.map} +1 -1
- package/lib/module/skia/web/{api/JsiSkSurfaceFactory.js → JsiSkSurfaceFactory.js} +0 -0
- package/lib/module/skia/web/{api/JsiSkSurfaceFactory.js.map → JsiSkSurfaceFactory.js.map} +1 -1
- package/lib/module/skia/web/JsiSkTextBlob.js +8 -0
- package/lib/module/skia/web/JsiSkTextBlob.js.map +1 -0
- package/lib/module/skia/web/JsiSkTextBlobFactory.js +25 -0
- package/lib/module/skia/web/JsiSkTextBlobFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkTypeface.js +18 -0
- package/lib/module/skia/web/JsiSkTypeface.js.map +1 -0
- package/lib/module/skia/web/JsiSkTypefaceFactory.js +19 -0
- package/lib/module/skia/web/JsiSkTypefaceFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkVertices.js +17 -0
- package/lib/module/skia/web/JsiSkVertices.js.map +1 -0
- package/lib/module/skia/web/JsiSkVerticesFactory.js +16 -0
- package/lib/module/skia/web/JsiSkVerticesFactory.js.map +1 -0
- package/lib/module/skia/web/JsiSkia.js +61 -0
- package/lib/module/skia/web/JsiSkia.js.map +1 -0
- package/lib/module/skia/web/index.js +1 -1
- package/lib/module/skia/web/index.js.map +1 -1
- package/lib/module/values/web/api.js +2 -2
- package/lib/module/values/web/api.js.map +1 -1
- package/lib/module/views/SkiaView.web.js +202 -0
- package/lib/module/views/SkiaView.web.js.map +1 -0
- package/lib/module/views/types.js.map +1 -1
- package/lib/module/views/useTouchHandler.js +64 -43
- package/lib/module/views/useTouchHandler.js.map +1 -1
- package/lib/module/web/index.js +8 -0
- package/lib/module/web/index.js.map +1 -0
- package/lib/typescript/src/animation/functions/index.d.ts +4 -2
- package/lib/typescript/src/animation/functions/interpolatePaths.d.ts +17 -0
- package/lib/typescript/src/animation/functions/interpolateVector.d.ts +10 -0
- package/lib/typescript/src/index.d.ts +1 -0
- package/lib/typescript/src/renderer/Canvas.d.ts +3 -14
- package/lib/typescript/src/renderer/DrawingContext.d.ts +3 -3
- package/lib/typescript/src/renderer/components/Blend.d.ts +1 -1
- package/lib/typescript/src/renderer/components/Group.d.ts +1 -1
- package/lib/typescript/src/renderer/components/Paint.d.ts +1 -1
- package/lib/typescript/src/renderer/components/Picture.d.ts +1 -1
- package/lib/typescript/src/renderer/components/colorFilters/BlendColor.d.ts +2 -2
- package/lib/typescript/src/renderer/components/colorFilters/Compose.d.ts +2 -2
- package/lib/typescript/src/renderer/components/image/BoxFit.d.ts +13 -3
- package/lib/typescript/src/renderer/components/image/Image.d.ts +1 -1
- package/lib/typescript/src/renderer/components/image/ImageSVG.d.ts +1 -1
- package/lib/typescript/src/renderer/components/image/ImageShader.d.ts +2 -2
- package/lib/typescript/src/renderer/components/imageFilters/Blur.d.ts +1 -1
- package/lib/typescript/src/renderer/components/imageFilters/DisplacementMap.d.ts +1 -1
- package/lib/typescript/src/renderer/components/imageFilters/InnerShadow.d.ts +2 -2
- package/lib/typescript/src/renderer/components/imageFilters/RuntimeShader.d.ts +2 -1
- package/lib/typescript/src/renderer/components/imageFilters/Shadow.d.ts +1 -1
- package/lib/typescript/src/renderer/components/imageFilters/getInput.d.ts +2 -1
- package/lib/typescript/src/renderer/components/maskFilters/Blur.d.ts +1 -1
- package/lib/typescript/src/renderer/components/pathEffects/Line2D.d.ts +1 -1
- package/lib/typescript/src/renderer/components/pathEffects/Path1D.d.ts +1 -1
- package/lib/typescript/src/renderer/components/pathEffects/Path2D.d.ts +1 -1
- package/lib/typescript/src/renderer/components/shaders/Color.d.ts +1 -1
- package/lib/typescript/src/renderer/components/shaders/Gradient.d.ts +4 -4
- package/lib/typescript/src/renderer/components/shaders/LinearGradient.d.ts +2 -1
- package/lib/typescript/src/renderer/components/shaders/RadialGradient.d.ts +2 -1
- package/lib/typescript/src/renderer/components/shaders/Shader.d.ts +2 -8
- package/lib/typescript/src/renderer/components/shaders/SweepGradient.d.ts +2 -1
- package/lib/typescript/src/renderer/components/shaders/TwoPointConicalGradient.d.ts +2 -1
- package/lib/typescript/src/renderer/components/shapes/Box.d.ts +1 -1
- package/lib/typescript/src/renderer/components/shapes/Circle.d.ts +4 -1
- package/lib/typescript/src/renderer/components/shapes/DiffRect.d.ts +1 -1
- package/lib/typescript/src/renderer/components/shapes/FitBox.d.ts +1 -1
- package/lib/typescript/src/renderer/components/shapes/Line.d.ts +2 -1
- package/lib/typescript/src/renderer/components/shapes/Patch.d.ts +3 -3
- package/lib/typescript/src/renderer/components/shapes/Path.d.ts +1 -1
- package/lib/typescript/src/renderer/components/shapes/Points.d.ts +2 -2
- package/lib/typescript/src/renderer/components/shapes/Vertices.d.ts +2 -2
- package/lib/typescript/src/renderer/components/text/Glyphs.d.ts +1 -1
- package/lib/typescript/src/renderer/components/text/TextBlob.d.ts +1 -1
- package/lib/typescript/src/renderer/components/text/TextPath.d.ts +1 -1
- package/lib/typescript/src/renderer/index.d.ts +1 -1
- package/lib/typescript/src/renderer/nodes/Declaration.d.ts +1 -1
- package/lib/typescript/src/renderer/nodes/Node.d.ts +1 -1
- package/lib/typescript/src/renderer/processors/Animations/Animations.d.ts +0 -2
- package/lib/typescript/src/renderer/processors/Circles.d.ts +2 -2
- package/lib/typescript/src/renderer/processors/Clips.d.ts +2 -2
- package/lib/typescript/src/{skia/core → renderer/processors}/Color.d.ts +2 -2
- package/lib/typescript/src/renderer/processors/Font.d.ts +2 -2
- package/lib/typescript/src/renderer/processors/Paint.d.ts +3 -3
- package/lib/typescript/src/renderer/processors/Paths.d.ts +2 -2
- package/lib/typescript/src/renderer/processors/Radius.d.ts +2 -2
- package/lib/typescript/src/renderer/processors/Rects.d.ts +3 -14
- package/lib/typescript/src/renderer/processors/Transform.d.ts +3 -4
- package/lib/typescript/src/renderer/processors/index.d.ts +2 -1
- package/lib/typescript/src/renderer/processors/math/Coordinates.d.ts +1 -1
- package/lib/typescript/src/renderer/processors/math/Transforms.d.ts +1 -1
- package/lib/typescript/src/renderer/processors/math/index.d.ts +0 -2
- package/lib/typescript/src/renderer/useCanvas.d.ts +14 -0
- package/lib/typescript/src/skia/Skia.web.d.ts +1 -0
- package/lib/typescript/src/skia/core/Data.d.ts +4 -4
- package/lib/typescript/src/skia/core/Matrix.d.ts +2 -0
- package/lib/typescript/src/skia/core/Paint.d.ts +0 -1
- package/lib/typescript/src/skia/core/RRect.d.ts +2 -0
- package/lib/typescript/src/skia/core/Rect.d.ts +8 -0
- package/lib/typescript/src/skia/core/Vector.d.ts +12 -0
- package/lib/typescript/src/skia/core/index.d.ts +5 -3
- package/lib/typescript/src/skia/types/ContourMeasure.d.ts +2 -4
- package/lib/typescript/src/skia/types/Data/Data.d.ts +1 -1
- package/lib/typescript/src/skia/types/Data/DataFactory.d.ts +4 -4
- package/lib/typescript/src/skia/types/FontMgr/FontMgr.d.ts +1 -1
- package/lib/typescript/src/skia/types/FontMgr/FontMgrFactory.d.ts +2 -2
- package/lib/typescript/src/skia/types/Image/ImageFactory.d.ts +3 -3
- package/lib/typescript/src/skia/types/Matrix.d.ts +15 -14
- package/lib/typescript/src/skia/types/Path/Path.d.ts +29 -23
- package/lib/typescript/src/skia/types/Path/PathFactory.d.ts +5 -0
- package/lib/typescript/src/skia/types/Picture/Picture.d.ts +2 -2
- package/lib/typescript/src/skia/types/Point.d.ts +1 -0
- package/lib/typescript/src/skia/types/RRect.d.ts +1 -0
- package/lib/typescript/src/skia/types/RuntimeEffect/RuntimeEffect.d.ts +3 -2
- package/lib/typescript/src/skia/types/SVG/SVGFactory.d.ts +2 -2
- package/lib/typescript/src/skia/types/Shader/Shader.d.ts +8 -0
- package/lib/typescript/src/skia/types/Skia.d.ts +1 -1
- package/lib/typescript/src/skia/types/Typeface/TypefaceFactory.d.ts +2 -2
- package/lib/typescript/src/skia/web/{api/Host.d.ts → Host.d.ts} +4 -1
- package/lib/typescript/src/skia/web/JsiImageFilterFactory.d.ts +19 -0
- package/lib/typescript/src/skia/web/{api/JsiSkCanvas.d.ts → JsiSkCanvas.d.ts} +1 -1
- package/lib/typescript/src/skia/web/JsiSkColor.d.ts +2 -0
- package/lib/typescript/src/skia/web/{api/JsiSkColorFilter.d.ts → JsiSkColorFilter.d.ts} +1 -1
- package/lib/typescript/src/skia/web/JsiSkColorFilterFactory.d.ts +14 -0
- package/lib/typescript/src/skia/web/JsiSkContourMeasure.d.ts +16 -0
- package/lib/typescript/src/skia/web/JsiSkContourMeasureIter.d.ts +8 -0
- package/lib/typescript/src/skia/web/JsiSkData.d.ts +8 -0
- package/lib/typescript/src/skia/web/JsiSkDataFactory.d.ts +19 -0
- package/lib/typescript/src/skia/web/JsiSkFont.d.ts +33 -0
- package/lib/typescript/src/skia/web/JsiSkFontMgr.d.ts +9 -0
- package/lib/typescript/src/skia/web/JsiSkFontMgrFactory.d.ts +8 -0
- package/lib/typescript/src/skia/web/{api/JsiSkImage.d.ts → JsiSkImage.d.ts} +1 -1
- package/lib/typescript/src/skia/web/JsiSkImageFactory.d.ts +10 -0
- package/lib/typescript/src/skia/web/JsiSkImageFilter.d.ts +6 -0
- package/lib/typescript/src/skia/web/JsiSkMaskFilter.d.ts +6 -0
- package/lib/typescript/src/skia/web/JsiSkMaskFilterFactory.d.ts +9 -0
- package/lib/typescript/src/skia/web/JsiSkMatrix.d.ts +11 -0
- package/lib/typescript/src/skia/web/{api/JsiSkPaint.d.ts → JsiSkPaint.d.ts} +1 -1
- package/lib/typescript/src/skia/web/JsiSkPath.d.ts +56 -0
- package/lib/typescript/src/skia/web/JsiSkPathEffect.d.ts +6 -0
- package/lib/typescript/src/skia/web/JsiSkPathEffectFactory.d.ts +15 -0
- package/lib/typescript/src/skia/web/JsiSkPathFactory.d.ts +13 -0
- package/lib/typescript/src/skia/web/JsiSkPicture.d.ts +9 -0
- package/lib/typescript/src/skia/web/JsiSkPictureFactory.d.ts +8 -0
- package/lib/typescript/src/skia/web/JsiSkPictureRecorder.d.ts +11 -0
- package/lib/typescript/src/skia/web/JsiSkPoint.d.ts +8 -0
- package/lib/typescript/src/skia/web/JsiSkRRect.d.ts +10 -0
- package/lib/typescript/src/skia/web/JsiSkRSXform.d.ts +8 -0
- package/lib/typescript/src/skia/web/{api/JsiSkRect.d.ts → JsiSkRect.d.ts} +2 -1
- package/lib/typescript/src/skia/web/JsiSkRuntimeEffect.d.ts +14 -0
- package/lib/typescript/src/skia/web/JsiSkRuntimeEffectFactory.d.ts +8 -0
- package/lib/typescript/src/skia/web/JsiSkSVGFactory.d.ts +9 -0
- package/lib/typescript/src/skia/web/JsiSkShader.d.ts +6 -0
- package/lib/typescript/src/skia/web/JsiSkShaderFactory.d.ts +16 -0
- package/lib/typescript/src/skia/web/{api/JsiSkSurface.d.ts → JsiSkSurface.d.ts} +1 -1
- package/lib/typescript/src/skia/web/{api/JsiSkSurfaceFactory.d.ts → JsiSkSurfaceFactory.d.ts} +1 -1
- package/lib/typescript/src/skia/web/JsiSkTextBlob.d.ts +6 -0
- package/lib/typescript/src/skia/web/JsiSkTextBlobFactory.d.ts +12 -0
- package/lib/typescript/src/skia/web/JsiSkTypeface.d.ts +8 -0
- package/lib/typescript/src/skia/web/JsiSkTypefaceFactory.d.ts +8 -0
- package/lib/typescript/src/skia/web/JsiSkVertices.d.ts +9 -0
- package/lib/typescript/src/skia/web/JsiSkVerticesFactory.d.ts +4 -0
- package/lib/typescript/src/skia/web/JsiSkia.d.ts +3 -0
- package/lib/typescript/src/skia/web/index.d.ts +1 -1
- package/lib/typescript/src/views/SkiaView.web.d.ts +56 -0
- package/lib/typescript/src/views/types.d.ts +1 -0
- package/lib/typescript/src/views/useTouchHandler.d.ts +11 -1
- package/lib/typescript/src/web/index.d.ts +5 -0
- package/package.json +4 -5
- package/src/animation/functions/index.ts +4 -2
- package/src/animation/functions/interpolatePaths.ts +38 -0
- package/src/animation/functions/interpolateVector.ts +26 -0
- package/src/index.ts +1 -0
- package/src/renderer/Canvas.tsx +13 -35
- package/src/renderer/DrawingContext.ts +3 -4
- package/src/renderer/HostConfig.ts +2 -2
- package/src/renderer/components/Blend.tsx +12 -10
- package/src/renderer/components/Compose.tsx +2 -2
- package/src/renderer/components/Group.tsx +11 -6
- package/src/renderer/components/Mask.tsx +5 -3
- package/src/renderer/components/Paint.tsx +5 -4
- package/src/renderer/components/Picture.tsx +1 -1
- package/src/renderer/components/backdrop/BackdropFilter.tsx +1 -1
- package/src/renderer/components/colorFilters/BlendColor.tsx +4 -4
- package/src/renderer/components/colorFilters/Compose.ts +3 -2
- package/src/renderer/components/colorFilters/Lerp.tsx +3 -2
- package/src/renderer/components/colorFilters/LinearToSRGBGamma.tsx +2 -3
- package/src/renderer/components/colorFilters/LumaColorFilter.tsx +2 -3
- package/src/renderer/components/colorFilters/Matrix.tsx +2 -3
- package/src/renderer/components/colorFilters/SRGBToLinearGamma.tsx +2 -3
- package/src/renderer/components/image/BoxFit.ts +7 -13
- package/src/renderer/components/image/Image.tsx +3 -3
- package/src/renderer/components/image/ImageSVG.tsx +3 -3
- package/src/renderer/components/image/ImageShader.tsx +8 -7
- package/src/renderer/components/imageFilters/Blur.tsx +12 -10
- package/src/renderer/components/imageFilters/DisplacementMap.tsx +4 -4
- package/src/renderer/components/imageFilters/InnerShadow.tsx +4 -3
- package/src/renderer/components/imageFilters/Morphology.tsx +3 -4
- package/src/renderer/components/imageFilters/Offset.tsx +5 -4
- package/src/renderer/components/imageFilters/RuntimeShader.tsx +12 -4
- package/src/renderer/components/imageFilters/Shadow.tsx +10 -6
- package/src/renderer/components/imageFilters/getInput.ts +3 -2
- package/src/renderer/components/maskFilters/Blur.tsx +2 -2
- package/src/renderer/components/pathEffects/Corner.tsx +2 -2
- package/src/renderer/components/pathEffects/Dash.tsx +2 -2
- package/src/renderer/components/pathEffects/Discrete.tsx +2 -2
- package/src/renderer/components/pathEffects/Line2D.tsx +3 -3
- package/src/renderer/components/pathEffects/Path1D.tsx +3 -3
- package/src/renderer/components/pathEffects/Path2D.tsx +4 -4
- package/src/renderer/components/pathEffects/Sum.tsx +7 -5
- package/src/renderer/components/shaders/Color.tsx +7 -5
- package/src/renderer/components/shaders/FractalNoise.tsx +1 -2
- package/src/renderer/components/shaders/Gradient.ts +7 -10
- package/src/renderer/components/shaders/LinearGradient.tsx +4 -4
- package/src/renderer/components/shaders/RadialGradient.tsx +4 -4
- package/src/renderer/components/shaders/Shader.tsx +6 -56
- package/src/renderer/components/shaders/SweepGradient.tsx +4 -4
- package/src/renderer/components/shaders/Turbulence.tsx +1 -2
- package/src/renderer/components/shaders/TwoPointConicalGradient.tsx +4 -4
- package/src/renderer/components/shapes/Box.tsx +36 -17
- package/src/renderer/components/shapes/Circle.tsx +3 -4
- package/src/renderer/components/shapes/DiffRect.tsx +1 -1
- package/src/renderer/components/shapes/FitBox.tsx +1 -1
- package/src/renderer/components/shapes/Line.tsx +2 -1
- package/src/renderer/components/shapes/Oval.tsx +6 -4
- package/src/renderer/components/shapes/Patch.tsx +6 -10
- package/src/renderer/components/shapes/Path.tsx +3 -3
- package/src/renderer/components/shapes/Points.tsx +2 -2
- package/src/renderer/components/shapes/Rect.tsx +6 -4
- package/src/renderer/components/shapes/RoundedRect.tsx +2 -2
- package/src/renderer/components/shapes/Vertices.tsx +5 -4
- package/src/renderer/components/text/Glyphs.tsx +6 -3
- package/src/renderer/components/text/Text.tsx +2 -2
- package/src/renderer/components/text/TextBlob.tsx +1 -1
- package/src/renderer/components/text/TextPath.tsx +3 -4
- package/src/renderer/index.ts +1 -1
- package/src/renderer/nodes/Declaration.tsx +1 -1
- package/src/renderer/nodes/Drawing.tsx +3 -2
- package/src/renderer/nodes/Node.ts +1 -1
- package/src/renderer/processors/Animations/Animations.ts +0 -3
- package/src/renderer/processors/Circles.ts +4 -4
- package/src/renderer/processors/Clips.ts +9 -4
- package/src/{skia/core → renderer/processors}/Color.ts +2 -3
- package/src/renderer/processors/Font.ts +10 -3
- package/src/renderer/processors/Paint.ts +12 -7
- package/src/renderer/processors/Paths.ts +3 -3
- package/src/renderer/processors/Radius.ts +3 -4
- package/src/renderer/processors/Rects.ts +10 -45
- package/src/renderer/processors/Transform.ts +28 -19
- package/src/renderer/processors/index.ts +2 -1
- package/src/renderer/processors/math/Coordinates.ts +1 -1
- package/src/renderer/processors/math/Transforms.ts +2 -1
- package/src/renderer/processors/math/index.ts +0 -2
- package/src/renderer/useCanvas.ts +21 -0
- package/src/skia/NativeSetup.ts +2 -2
- package/src/skia/Skia.web.ts +3 -0
- package/src/skia/core/Data.ts +17 -14
- package/src/skia/core/Font.ts +2 -4
- package/src/skia/core/Matrix.ts +6 -0
- package/src/skia/core/Paint.ts +2 -6
- package/src/skia/core/Path.ts +14 -6
- package/src/skia/core/RRect.tsx +5 -0
- package/src/skia/core/Rect.ts +33 -0
- package/src/skia/core/Vector.ts +11 -0
- package/src/skia/core/index.ts +5 -3
- package/src/skia/types/ContourMeasure.tsx +2 -4
- package/src/skia/types/Data/Data.ts +1 -1
- package/src/skia/types/Data/DataFactory.ts +4 -4
- package/src/skia/types/FontMgr/FontMgr.ts +1 -1
- package/src/skia/types/FontMgr/FontMgrFactory.ts +2 -2
- package/src/skia/types/Image/ImageFactory.ts +3 -3
- package/src/skia/types/Matrix.ts +79 -14
- package/src/skia/types/Path/Path.ts +34 -23
- package/src/skia/types/Path/PathFactory.ts +7 -0
- package/src/skia/types/Picture/Picture.ts +2 -2
- package/src/skia/types/Point.ts +2 -0
- package/src/skia/types/RRect.ts +5 -0
- package/src/skia/types/RuntimeEffect/RuntimeEffect.ts +4 -2
- package/src/skia/types/SVG/SVGFactory.ts +2 -2
- package/src/skia/types/Shader/Shader.ts +61 -0
- package/src/skia/types/Skia.ts +1 -1
- package/src/skia/types/Typeface/TypefaceFactory.ts +2 -2
- package/src/skia/web/{api/Host.ts → Host.ts} +7 -1
- package/src/skia/web/JsiImageFilterFactory.ts +144 -0
- package/src/skia/web/{api/JsiSkCanvas.ts → JsiSkCanvas.ts} +19 -11
- package/src/skia/web/{api/JsiSkColor.ts → JsiSkColor.ts} +152 -6
- package/src/skia/web/{api/JsiSkColorFilter.ts → JsiSkColorFilter.ts} +1 -1
- package/src/skia/web/JsiSkColorFilterFactory.ts +67 -0
- package/src/skia/web/JsiSkContourMeasure.ts +35 -0
- package/src/skia/web/JsiSkContourMeasureIter.ts +23 -0
- package/src/skia/web/JsiSkData.ts +13 -0
- package/src/skia/web/JsiSkDataFactory.ts +35 -0
- package/src/skia/web/JsiSkFont.ts +124 -0
- package/src/skia/web/JsiSkFontMgr.ts +42 -0
- package/src/skia/web/JsiSkFontMgrFactory.ts +18 -0
- package/src/skia/web/{api/JsiSkImage.ts → JsiSkImage.ts} +1 -1
- package/src/skia/web/JsiSkImageFactory.ts +40 -0
- package/src/skia/web/JsiSkImageFilter.ts +14 -0
- package/src/skia/web/JsiSkMaskFilter.ts +14 -0
- package/src/skia/web/JsiSkMaskFilterFactory.ts +20 -0
- package/src/skia/web/JsiSkMatrix.ts +54 -0
- package/src/skia/web/{api/JsiSkPaint.ts → JsiSkPaint.ts} +6 -5
- package/src/skia/web/JsiSkPath.ts +369 -0
- package/src/skia/web/JsiSkPathEffect.ts +14 -0
- package/src/skia/web/JsiSkPathEffectFactory.ts +85 -0
- package/src/skia/web/JsiSkPathFactory.ts +54 -0
- package/src/skia/web/JsiSkPicture.ts +45 -0
- package/src/skia/web/JsiSkPictureFactory.ts +20 -0
- package/src/skia/web/JsiSkPictureRecorder.ts +31 -0
- package/src/skia/web/JsiSkPoint.ts +19 -0
- package/src/skia/web/JsiSkRRect.ts +27 -0
- package/src/skia/web/JsiSkRSXform.ts +16 -0
- package/src/skia/web/{api/JsiSkRect.ts → JsiSkRect.ts} +11 -1
- package/src/skia/web/JsiSkRuntimeEffect.ts +57 -0
- package/src/skia/web/JsiSkRuntimeEffectFactory.ts +23 -0
- package/src/skia/web/JsiSkSVGFactory.ts +20 -0
- package/src/skia/web/JsiSkShader.ts +14 -0
- package/src/skia/web/JsiSkShaderFactory.ts +178 -0
- package/src/skia/web/{api/JsiSkSurface.ts → JsiSkSurface.ts} +1 -1
- package/src/skia/web/{api/JsiSkSurfaceFactory.ts → JsiSkSurfaceFactory.ts} +1 -1
- package/src/skia/web/JsiSkTextBlob.ts +14 -0
- package/src/skia/web/JsiSkTextBlobFactory.ts +49 -0
- package/src/skia/web/JsiSkTypeface.ts +28 -0
- package/src/skia/web/JsiSkTypefaceFactory.tsx +20 -0
- package/src/skia/web/JsiSkVertices.ts +23 -0
- package/src/skia/web/JsiSkVerticesFactory.ts +27 -0
- package/src/skia/web/JsiSkia.ts +98 -0
- package/src/skia/web/index.ts +1 -1
- package/src/values/web/api.ts +2 -2
- package/src/views/SkiaView.web.tsx +192 -0
- package/src/views/types.ts +1 -0
- package/src/views/useTouchHandler.ts +82 -51
- package/src/web/index.ts +13 -0
- package/lib/commonjs/renderer/processors/math/Matrix3.js +0 -66
- package/lib/commonjs/renderer/processors/math/Matrix3.js.map +0 -1
- package/lib/commonjs/renderer/processors/math/Vector.js +0 -60
- package/lib/commonjs/renderer/processors/math/Vector.js.map +0 -1
- package/lib/commonjs/skia/core/Color.js.map +0 -1
- package/lib/commonjs/skia/core/Shader.js +0 -18
- package/lib/commonjs/skia/core/Shader.js.map +0 -1
- package/lib/commonjs/skia/web/api/Host.js.map +0 -1
- package/lib/commonjs/skia/web/api/JsiSkCanvas.js.map +0 -1
- package/lib/commonjs/skia/web/api/JsiSkColor.js.map +0 -1
- package/lib/commonjs/skia/web/api/JsiSkPaint.js.map +0 -1
- package/lib/commonjs/skia/web/api/JsiSkRect.js.map +0 -1
- package/lib/commonjs/skia/web/api/index.js +0 -26
- package/lib/commonjs/skia/web/api/index.js.map +0 -1
- package/lib/module/renderer/processors/math/Matrix3.js +0 -55
- package/lib/module/renderer/processors/math/Matrix3.js.map +0 -1
- package/lib/module/renderer/processors/math/Vector.js.map +0 -1
- package/lib/module/skia/core/Color.js.map +0 -1
- package/lib/module/skia/core/Shader.js +0 -7
- package/lib/module/skia/core/Shader.js.map +0 -1
- package/lib/module/skia/web/api/Host.js.map +0 -1
- package/lib/module/skia/web/api/JsiSkCanvas.js.map +0 -1
- package/lib/module/skia/web/api/JsiSkColor.js.map +0 -1
- package/lib/module/skia/web/api/JsiSkPaint.js.map +0 -1
- package/lib/module/skia/web/api/JsiSkRect.js.map +0 -1
- package/lib/module/skia/web/api/index.js +0 -13
- package/lib/module/skia/web/api/index.js.map +0 -1
- package/lib/typescript/src/renderer/processors/math/Matrix3.d.ts +0 -10
- package/lib/typescript/src/renderer/processors/math/Vector.d.ts +0 -23
- package/lib/typescript/src/skia/core/Shader.d.ts +0 -1
- package/lib/typescript/src/skia/web/api/JsiSkColor.d.ts +0 -3
- package/lib/typescript/src/skia/web/api/index.d.ts +0 -10
- package/src/animation/timing/functions/__tests__/timing.spec.ts +0 -29
- package/src/renderer/processors/math/Matrix3.ts +0 -73
- package/src/renderer/processors/math/Vector.ts +0 -38
- package/src/skia/__tests__/Rects.spec.ts +0 -40
- package/src/skia/__tests__/snapshots/lightblue-rect.png +0 -0
- package/src/skia/core/Shader.ts +0 -9
- package/src/skia/web/api/index.ts +0 -15
- package/src/values/web/__tests__/RNSkAnimation.spec.ts +0 -21
- package/src/values/web/__tests__/RNSkDerivedValue.spec.ts +0 -15
- package/src/values/web/__tests__/RNSkReadonlyValue.spec.ts +0 -8
- package/src/values/web/__tests__/RNSkValue.spec.ts +0 -11
@@ -7,7 +7,7 @@ exports.DashPathEffect = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var
|
10
|
+
var _types = require("../../../skia/types");
|
11
11
|
|
12
12
|
var _Declaration = require("../../nodes/Declaration");
|
13
13
|
|
@@ -15,17 +15,19 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
15
15
|
|
16
16
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
17
17
|
|
18
|
-
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children) => {
|
18
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children, _ref2) => {
|
19
19
|
let {
|
20
20
|
intervals,
|
21
21
|
phase
|
22
22
|
} = _ref;
|
23
|
-
|
24
|
-
|
25
|
-
|
23
|
+
let {
|
24
|
+
Skia
|
25
|
+
} = _ref2;
|
26
|
+
const [child] = children.filter(_types.isPathEffect);
|
27
|
+
const pe = Skia.PathEffect.MakeDash(intervals, phase);
|
26
28
|
|
27
29
|
if (child) {
|
28
|
-
return
|
30
|
+
return Skia.PathEffect.MakeCompose(pe, child);
|
29
31
|
}
|
30
32
|
|
31
33
|
return pe;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["Dash.tsx"],"names":["onDeclare","children","intervals","phase","child","filter","isPathEffect","pe","
|
1
|
+
{"version":3,"sources":["Dash.tsx"],"names":["onDeclare","children","intervals","phase","Skia","child","filter","isPathEffect","pe","PathEffect","MakeDash","MakeCompose","DashPathEffect","props"],"mappings":";;;;;;;AAAA;;AAGA;;AACA;;;;;;AASA,MAAMA,SAAS,GAAG,oCAChB,OAAuBC,QAAvB,YAA8C;AAAA,MAA7C;AAAEC,IAAAA,SAAF;AAAaC,IAAAA;AAAb,GAA6C;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AAC5C,QAAM,CAACC,KAAD,IAAUJ,QAAQ,CAACK,MAAT,CAAgBC,mBAAhB,CAAhB;AACA,QAAMC,EAAE,GAAGJ,IAAI,CAACK,UAAL,CAAgBC,QAAhB,CAAyBR,SAAzB,EAAoCC,KAApC,CAAX;;AACA,MAAIE,KAAJ,EAAW;AACT,WAAOD,IAAI,CAACK,UAAL,CAAgBE,WAAhB,CAA4BH,EAA5B,EAAgCH,KAAhC,CAAP;AACD;;AACD,SAAOG,EAAP;AACD,CARe,CAAlB;;AAWO,MAAMI,cAAc,GAAIC,KAAD,IAA+C;AAC3E,sBAAO;AAAe,IAAA,SAAS,EAAEb;AAA1B,KAAyCa,KAAzC,EAAP;AACD,CAFM","sourcesContent":["import React from \"react\";\nimport type { ReactNode } from \"react\";\n\nimport { isPathEffect } from \"../../../skia/types\";\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport type { AnimatedProps } from \"../../processors/Animations/Animations\";\n\nexport interface DashPathEffectProps {\n intervals: number[];\n phase?: number;\n children?: ReactNode | ReactNode[];\n}\n\nconst onDeclare = createDeclaration<DashPathEffectProps>(\n ({ intervals, phase }, children, { Skia }) => {\n const [child] = children.filter(isPathEffect);\n const pe = Skia.PathEffect.MakeDash(intervals, phase);\n if (child) {\n return Skia.PathEffect.MakeCompose(pe, child);\n }\n return pe;\n }\n);\n\nexport const DashPathEffect = (props: AnimatedProps<DashPathEffectProps>) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n"]}
|
@@ -7,7 +7,7 @@ exports.DiscretePathEffect = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var
|
10
|
+
var _types = require("../../../skia/types");
|
11
11
|
|
12
12
|
var _Declaration = require("../../nodes/Declaration");
|
13
13
|
|
@@ -15,18 +15,20 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
15
15
|
|
16
16
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
17
17
|
|
18
|
-
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children) => {
|
18
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children, _ref2) => {
|
19
19
|
let {
|
20
20
|
length,
|
21
21
|
deviation,
|
22
22
|
seed
|
23
23
|
} = _ref;
|
24
|
-
|
25
|
-
|
26
|
-
|
24
|
+
let {
|
25
|
+
Skia
|
26
|
+
} = _ref2;
|
27
|
+
const [child] = children.filter(_types.isPathEffect);
|
28
|
+
const pe = Skia.PathEffect.MakeDiscrete(length, deviation, seed);
|
27
29
|
|
28
30
|
if (child) {
|
29
|
-
return
|
31
|
+
return Skia.PathEffect.MakeCompose(pe, child);
|
30
32
|
}
|
31
33
|
|
32
34
|
return pe;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["Discrete.tsx"],"names":["onDeclare","children","length","deviation","seed","child","filter","isPathEffect","pe","
|
1
|
+
{"version":3,"sources":["Discrete.tsx"],"names":["onDeclare","children","length","deviation","seed","Skia","child","filter","isPathEffect","pe","PathEffect","MakeDiscrete","MakeCompose","DiscretePathEffect","props","defaultProps"],"mappings":";;;;;;;AAAA;;AAGA;;AACA;;;;;;AAUA,MAAMA,SAAS,GAAG,oCAChB,OAA8BC,QAA9B,YAAqD;AAAA,MAApD;AAAEC,IAAAA,MAAF;AAAUC,IAAAA,SAAV;AAAqBC,IAAAA;AAArB,GAAoD;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AACnD,QAAM,CAACC,KAAD,IAAUL,QAAQ,CAACM,MAAT,CAAgBC,mBAAhB,CAAhB;AACA,QAAMC,EAAE,GAAGJ,IAAI,CAACK,UAAL,CAAgBC,YAAhB,CAA6BT,MAA7B,EAAqCC,SAArC,EAAgDC,IAAhD,CAAX;;AACA,MAAIE,KAAJ,EAAW;AACT,WAAOD,IAAI,CAACK,UAAL,CAAgBE,WAAhB,CAA4BH,EAA5B,EAAgCH,KAAhC,CAAP;AACD;;AACD,SAAOG,EAAP;AACD,CARe,CAAlB;;AAWO,MAAMI,kBAAkB,GAC7BC,KADgC,IAE7B;AACH,sBAAO;AAAe,IAAA,SAAS,EAAEd;AAA1B,KAAyCc,KAAzC,EAAP;AACD,CAJM;;;AAMPD,kBAAkB,CAACE,YAAnB,GAAkC;AAChCX,EAAAA,IAAI,EAAE;AAD0B,CAAlC","sourcesContent":["import React from \"react\";\nimport type { ReactNode } from \"react\";\n\nimport { isPathEffect } from \"../../../skia/types\";\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport type { AnimatedProps } from \"../../processors/Animations/Animations\";\n\nexport interface DiscretePathEffectProps {\n length: number;\n deviation: number;\n seed: number;\n children?: ReactNode | ReactNode[];\n}\n\nconst onDeclare = createDeclaration<DiscretePathEffectProps>(\n ({ length, deviation, seed }, children, { Skia }) => {\n const [child] = children.filter(isPathEffect);\n const pe = Skia.PathEffect.MakeDiscrete(length, deviation, seed);\n if (child) {\n return Skia.PathEffect.MakeCompose(pe, child);\n }\n return pe;\n }\n);\n\nexport const DiscretePathEffect = (\n props: AnimatedProps<DiscretePathEffectProps>\n) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n\nDiscretePathEffect.defaultProps = {\n seed: 0,\n};\n"]}
|
@@ -7,7 +7,7 @@ exports.Line2DPathEffect = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var
|
10
|
+
var _types = require("../../../skia/types");
|
11
11
|
|
12
12
|
var _Declaration = require("../../nodes/Declaration");
|
13
13
|
|
@@ -15,21 +15,23 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
15
15
|
|
16
16
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
17
17
|
|
18
|
-
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children) => {
|
18
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children, _ref2) => {
|
19
19
|
let {
|
20
20
|
width,
|
21
21
|
matrix
|
22
22
|
} = _ref;
|
23
|
-
|
24
|
-
|
25
|
-
|
23
|
+
let {
|
24
|
+
Skia
|
25
|
+
} = _ref2;
|
26
|
+
const [child] = children.filter(_types.isPathEffect);
|
27
|
+
const pe = Skia.PathEffect.MakeLine2D(width, matrix);
|
26
28
|
|
27
29
|
if (child) {
|
28
30
|
if (!pe) {
|
29
31
|
return child;
|
30
32
|
}
|
31
33
|
|
32
|
-
return
|
34
|
+
return Skia.PathEffect.MakeCompose(pe, child);
|
33
35
|
}
|
34
36
|
|
35
37
|
return pe;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["Line2D.tsx"],"names":["onDeclare","children","width","matrix","child","filter","isPathEffect","pe","
|
1
|
+
{"version":3,"sources":["Line2D.tsx"],"names":["onDeclare","children","width","matrix","Skia","child","filter","isPathEffect","pe","PathEffect","MakeLine2D","MakeCompose","Line2DPathEffect","props"],"mappings":";;;;;;;AAAA;;AAGA;;AACA;;;;;;AAUA,MAAMA,SAAS,GAAG,oCAChB,OAAoBC,QAApB,YAA2C;AAAA,MAA1C;AAAEC,IAAAA,KAAF;AAASC,IAAAA;AAAT,GAA0C;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AACzC,QAAM,CAACC,KAAD,IAAUJ,QAAQ,CAACK,MAAT,CAAgBC,mBAAhB,CAAhB;AACA,QAAMC,EAAE,GAAGJ,IAAI,CAACK,UAAL,CAAgBC,UAAhB,CAA2BR,KAA3B,EAAkCC,MAAlC,CAAX;;AACA,MAAIE,KAAJ,EAAW;AACT,QAAI,CAACG,EAAL,EAAS;AACP,aAAOH,KAAP;AACD;;AACD,WAAOD,IAAI,CAACK,UAAL,CAAgBE,WAAhB,CAA4BH,EAA5B,EAAgCH,KAAhC,CAAP;AACD;;AACD,SAAOG,EAAP;AACD,CAXe,CAAlB;;AAcO,MAAMI,gBAAgB,GAC3BC,KAD8B,IAE3B;AACH,sBAAO;AAAe,IAAA,SAAS,EAAEb;AAA1B,KAAyCa,KAAzC,EAAP;AACD,CAJM","sourcesContent":["import React from \"react\";\nimport type { ReactNode } from \"react\";\n\nimport { isPathEffect } from \"../../../skia/types\";\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport type { AnimatedProps } from \"../../processors/Animations/Animations\";\nimport type { SkMatrix } from \"../../../skia/types\";\n\nexport interface Line2DPathEffectProps {\n children?: ReactNode | ReactNode[];\n width: number;\n matrix: SkMatrix;\n}\n\nconst onDeclare = createDeclaration<Line2DPathEffectProps>(\n ({ width, matrix }, children, { Skia }) => {\n const [child] = children.filter(isPathEffect);\n const pe = Skia.PathEffect.MakeLine2D(width, matrix);\n if (child) {\n if (!pe) {\n return child;\n }\n return Skia.PathEffect.MakeCompose(pe, child);\n }\n return pe;\n }\n);\n\nexport const Line2DPathEffect = (\n props: AnimatedProps<Line2DPathEffectProps>\n) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n"]}
|
@@ -7,7 +7,7 @@ exports.Path1DPathEffect = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var
|
10
|
+
var _types = require("../../../skia/types");
|
11
11
|
|
12
12
|
var _Declaration = require("../../nodes/Declaration");
|
13
13
|
|
@@ -19,23 +19,25 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
19
19
|
|
20
20
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
21
21
|
|
22
|
-
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children) => {
|
22
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children, _ref2) => {
|
23
23
|
let {
|
24
24
|
path,
|
25
25
|
advance,
|
26
26
|
phase,
|
27
27
|
style
|
28
28
|
} = _ref;
|
29
|
-
|
30
|
-
|
31
|
-
|
29
|
+
let {
|
30
|
+
Skia
|
31
|
+
} = _ref2;
|
32
|
+
const [child] = children.filter(_types.isPathEffect);
|
33
|
+
const pe = Skia.PathEffect.MakePath1D((0, _Paths.processPath)(Skia, path), advance, phase, _types.Path1DEffectStyle[(0, _Paint.enumKey)(style)]);
|
32
34
|
|
33
35
|
if (child) {
|
34
36
|
if (!pe) {
|
35
37
|
return child;
|
36
38
|
}
|
37
39
|
|
38
|
-
return
|
40
|
+
return Skia.PathEffect.MakeCompose(pe, child);
|
39
41
|
}
|
40
42
|
|
41
43
|
return pe;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["Path1D.tsx"],"names":["onDeclare","children","path","advance","phase","style","child","filter","isPathEffect","pe","
|
1
|
+
{"version":3,"sources":["Path1D.tsx"],"names":["onDeclare","children","path","advance","phase","style","Skia","child","filter","isPathEffect","pe","PathEffect","MakePath1D","Path1DEffectStyle","MakeCompose","Path1DPathEffect","props"],"mappings":";;;;;;;AAAA;;AAGA;;AACA;;AAGA;;AAEA;;;;;;AAUA,MAAMA,SAAS,GAAG,oCAChB,OAAkCC,QAAlC,YAAyD;AAAA,MAAxD;AAAEC,IAAAA,IAAF;AAAQC,IAAAA,OAAR;AAAiBC,IAAAA,KAAjB;AAAwBC,IAAAA;AAAxB,GAAwD;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AACvD,QAAM,CAACC,KAAD,IAAUN,QAAQ,CAACO,MAAT,CAAgBC,mBAAhB,CAAhB;AACA,QAAMC,EAAE,GAAGJ,IAAI,CAACK,UAAL,CAAgBC,UAAhB,CACT,wBAAYN,IAAZ,EAAkBJ,IAAlB,CADS,EAETC,OAFS,EAGTC,KAHS,EAITS,yBAAkB,oBAAQR,KAAR,CAAlB,CAJS,CAAX;;AAMA,MAAIE,KAAJ,EAAW;AACT,QAAI,CAACG,EAAL,EAAS;AACP,aAAOH,KAAP;AACD;;AACD,WAAOD,IAAI,CAACK,UAAL,CAAgBG,WAAhB,CAA4BJ,EAA5B,EAAgCH,KAAhC,CAAP;AACD;;AACD,SAAOG,EAAP;AACD,CAhBe,CAAlB;;AAmBO,MAAMK,gBAAgB,GAC3BC,KAD8B,IAE3B;AACH,sBAAO;AAAe,IAAA,SAAS,EAAEhB;AAA1B,KAAyCgB,KAAzC,EAAP;AACD,CAJM","sourcesContent":["import React from \"react\";\nimport type { ReactNode } from \"react\";\n\nimport { Path1DEffectStyle, isPathEffect } from \"../../../skia/types\";\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport type { AnimatedProps } from \"../../processors/Animations/Animations\";\nimport type { SkEnum } from \"../../processors/Paint\";\nimport { enumKey } from \"../../processors/Paint\";\nimport type { PathDef } from \"../../processors/Paths\";\nimport { processPath } from \"../../processors/Paths\";\n\nexport interface Path1DPathEffectProps {\n path: PathDef;\n children?: ReactNode | ReactNode[];\n advance: number;\n phase: number;\n style: SkEnum<typeof Path1DEffectStyle>;\n}\n\nconst onDeclare = createDeclaration<Path1DPathEffectProps>(\n ({ path, advance, phase, style }, children, { Skia }) => {\n const [child] = children.filter(isPathEffect);\n const pe = Skia.PathEffect.MakePath1D(\n processPath(Skia, path),\n advance,\n phase,\n Path1DEffectStyle[enumKey(style)]\n );\n if (child) {\n if (!pe) {\n return child;\n }\n return Skia.PathEffect.MakeCompose(pe, child);\n }\n return pe;\n }\n);\n\nexport const Path1DPathEffect = (\n props: AnimatedProps<Path1DPathEffectProps>\n) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n"]}
|
@@ -7,7 +7,7 @@ exports.Path2DPathEffect = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var
|
10
|
+
var _types = require("../../../skia/types");
|
11
11
|
|
12
12
|
var _Declaration = require("../../nodes/Declaration");
|
13
13
|
|
@@ -17,21 +17,23 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
17
17
|
|
18
18
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
19
19
|
|
20
|
-
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children) => {
|
20
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children, _ref2) => {
|
21
21
|
let {
|
22
22
|
path,
|
23
23
|
matrix
|
24
24
|
} = _ref;
|
25
|
-
|
26
|
-
|
27
|
-
|
25
|
+
let {
|
26
|
+
Skia
|
27
|
+
} = _ref2;
|
28
|
+
const [child] = children.filter(_types.isPathEffect);
|
29
|
+
const pe = Skia.PathEffect.MakePath2D(matrix, (0, _Paths.processPath)(Skia, path));
|
28
30
|
|
29
31
|
if (child) {
|
30
32
|
if (!pe) {
|
31
33
|
return child;
|
32
34
|
}
|
33
35
|
|
34
|
-
return
|
36
|
+
return Skia.PathEffect.MakeCompose(pe, child);
|
35
37
|
}
|
36
38
|
|
37
39
|
return pe;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["Path2D.tsx"],"names":["onDeclare","children","path","matrix","child","filter","isPathEffect","pe","
|
1
|
+
{"version":3,"sources":["Path2D.tsx"],"names":["onDeclare","children","path","matrix","Skia","child","filter","isPathEffect","pe","PathEffect","MakePath2D","MakeCompose","Path2DPathEffect","props"],"mappings":";;;;;;;AAAA;;AAGA;;AACA;;AAIA;;;;;;AAQA,MAAMA,SAAS,GAAG,oCAChB,OAAmBC,QAAnB,YAA0C;AAAA,MAAzC;AAAEC,IAAAA,IAAF;AAAQC,IAAAA;AAAR,GAAyC;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AACxC,QAAM,CAACC,KAAD,IAAUJ,QAAQ,CAACK,MAAT,CAAgBC,mBAAhB,CAAhB;AACA,QAAMC,EAAE,GAAGJ,IAAI,CAACK,UAAL,CAAgBC,UAAhB,CAA2BP,MAA3B,EAAmC,wBAAYC,IAAZ,EAAkBF,IAAlB,CAAnC,CAAX;;AACA,MAAIG,KAAJ,EAAW;AACT,QAAI,CAACG,EAAL,EAAS;AACP,aAAOH,KAAP;AACD;;AACD,WAAOD,IAAI,CAACK,UAAL,CAAgBE,WAAhB,CAA4BH,EAA5B,EAAgCH,KAAhC,CAAP;AACD;;AACD,SAAOG,EAAP;AACD,CAXe,CAAlB;;AAcO,MAAMI,gBAAgB,GAC3BC,KAD8B,IAE3B;AACH,sBAAO;AAAe,IAAA,SAAS,EAAEb;AAA1B,KAAyCa,KAAzC,EAAP;AACD,CAJM","sourcesContent":["import React from \"react\";\nimport type { ReactNode } from \"react\";\n\nimport { isPathEffect } from \"../../../skia/types\";\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport type { AnimatedProps } from \"../../processors/Animations/Animations\";\nimport type { SkMatrix } from \"../../../skia/types\";\nimport type { PathDef } from \"../../processors/Paths\";\nimport { processPath } from \"../../processors/Paths\";\n\nexport interface Path2DPathEffectProps {\n children?: ReactNode | ReactNode[];\n matrix: SkMatrix;\n path: PathDef;\n}\n\nconst onDeclare = createDeclaration<Path2DPathEffectProps>(\n ({ path, matrix }, children, { Skia }) => {\n const [child] = children.filter(isPathEffect);\n const pe = Skia.PathEffect.MakePath2D(matrix, processPath(Skia, path));\n if (child) {\n if (!pe) {\n return child;\n }\n return Skia.PathEffect.MakeCompose(pe, child);\n }\n return pe;\n }\n);\n\nexport const Path2DPathEffect = (\n props: AnimatedProps<Path2DPathEffectProps>\n) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n"]}
|
@@ -7,7 +7,7 @@ exports.SumPathEffect = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var
|
10
|
+
var _types = require("../../../skia/types");
|
11
11
|
|
12
12
|
var _Declaration = require("../../nodes/Declaration");
|
13
13
|
|
@@ -15,9 +15,12 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
15
15
|
|
16
16
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
17
17
|
|
18
|
-
const onDeclare = (0, _Declaration.createDeclaration)((_, children) => {
|
19
|
-
|
20
|
-
|
18
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_, children, _ref) => {
|
19
|
+
let {
|
20
|
+
Skia
|
21
|
+
} = _ref;
|
22
|
+
const [outer, inner] = children.filter(_types.isPathEffect);
|
23
|
+
return Skia.PathEffect.MakeCompose(outer, inner);
|
21
24
|
});
|
22
25
|
|
23
26
|
const SumPathEffect = props => {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["Sum.tsx"],"names":["onDeclare","_","children","outer","inner","filter","isPathEffect","
|
1
|
+
{"version":3,"sources":["Sum.tsx"],"names":["onDeclare","_","children","Skia","outer","inner","filter","isPathEffect","PathEffect","MakeCompose","SumPathEffect","props"],"mappings":";;;;;;;AAAA;;AAGA;;AACA;;;;;;AAOA,MAAMA,SAAS,GAAG,oCAChB,CAACC,CAAD,EAAIC,QAAJ,WAA2B;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AACzB,QAAM,CAACC,KAAD,EAAQC,KAAR,IAAiBH,QAAQ,CAACI,MAAT,CAAgBC,mBAAhB,CAAvB;AACA,SAAOJ,IAAI,CAACK,UAAL,CAAgBC,WAAhB,CAA4BL,KAA5B,EAAmCC,KAAnC,CAAP;AACD,CAJe,CAAlB;;AAOO,MAAMK,aAAa,GAAIC,KAAD,IAA8C;AACzE,sBAAO;AAAe,IAAA,SAAS,EAAEX;AAA1B,KAAyCW,KAAzC,EAAP;AACD,CAFM","sourcesContent":["import React from \"react\";\nimport type { ReactNode } from \"react\";\n\nimport { isPathEffect } from \"../../../skia/types\";\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport type { AnimatedProps } from \"../../processors/Animations/Animations\";\n\nexport interface SumPathEffectProps {\n children?: ReactNode | ReactNode[];\n}\n\nconst onDeclare = createDeclaration<SumPathEffectProps>(\n (_, children, { Skia }) => {\n const [outer, inner] = children.filter(isPathEffect);\n return Skia.PathEffect.MakeCompose(outer, inner);\n }\n);\n\nexport const SumPathEffect = (props: AnimatedProps<SumPathEffectProps>) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n"]}
|
@@ -7,19 +7,22 @@ exports.ColorShader = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var _skia = require("../../../skia");
|
11
|
-
|
12
10
|
var _nodes = require("../../nodes");
|
13
11
|
|
12
|
+
var _Color = require("../../processors/Color");
|
13
|
+
|
14
14
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
15
15
|
|
16
16
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
17
17
|
|
18
|
-
const onDeclare = (0, _nodes.createDeclaration)(_ref => {
|
18
|
+
const onDeclare = (0, _nodes.createDeclaration)((_ref, _, _ref2) => {
|
19
19
|
let {
|
20
20
|
color
|
21
21
|
} = _ref;
|
22
|
-
|
22
|
+
let {
|
23
|
+
Skia
|
24
|
+
} = _ref2;
|
25
|
+
return Skia.Shader.MakeColor((0, _Color.processColor)(Skia, color, 1));
|
23
26
|
});
|
24
27
|
|
25
28
|
const ColorShader = props => {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["Color.tsx"],"names":["onDeclare","color","Skia","Shader","MakeColor","ColorShader","props"],"mappings":";;;;;;;AAAA;;AAEA;;
|
1
|
+
{"version":3,"sources":["Color.tsx"],"names":["onDeclare","_","color","Skia","Shader","MakeColor","ColorShader","props"],"mappings":";;;;;;;AAAA;;AAEA;;AAGA;;;;;;AAMA,MAAMA,SAAS,GAAG,8BAChB,OAAYC,CAAZ,YAA4B;AAAA,MAA3B;AAAEC,IAAAA;AAAF,GAA2B;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AAC1B,SAAOA,IAAI,CAACC,MAAL,CAAYC,SAAZ,CAAsB,yBAAaF,IAAb,EAAmBD,KAAnB,EAA0B,CAA1B,CAAtB,CAAP;AACD,CAHe,CAAlB;;AAMO,MAAMI,WAAW,GAAIC,KAAD,IAA4C;AACrE,sBAAO;AAAe,IAAA,SAAS,EAAEP;AAA1B,KAAyCO,KAAzC,EAAP;AACD,CAFM","sourcesContent":["import React from \"react\";\n\nimport { createDeclaration } from \"../../nodes\";\nimport type { AnimatedProps } from \"../../processors\";\nimport type { Color } from \"../../../skia/types\";\nimport { processColor } from \"../../processors/Color\";\n\nexport interface ColorShaderProps {\n color: Color;\n}\n\nconst onDeclare = createDeclaration<ColorShaderProps>(\n ({ color }, _, { Skia }) => {\n return Skia.Shader.MakeColor(processColor(Skia, color, 1));\n }\n);\n\nexport const ColorShader = (props: AnimatedProps<ColorShaderProps>) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n"]}
|
@@ -7,15 +7,13 @@ exports.FractalNoise = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var _skia = require("../../../skia");
|
11
|
-
|
12
10
|
var _Declaration = require("../../nodes/Declaration");
|
13
11
|
|
14
12
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
15
13
|
|
16
14
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
17
15
|
|
18
|
-
const onDeclare = (0, _Declaration.createDeclaration)(_ref => {
|
16
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_ref, _, _ref2) => {
|
19
17
|
let {
|
20
18
|
freqX,
|
21
19
|
freqY,
|
@@ -24,7 +22,10 @@ const onDeclare = (0, _Declaration.createDeclaration)(_ref => {
|
|
24
22
|
tileWidth,
|
25
23
|
tileHeight
|
26
24
|
} = _ref;
|
27
|
-
|
25
|
+
let {
|
26
|
+
Skia
|
27
|
+
} = _ref2;
|
28
|
+
return Skia.Shader.MakeFractalNoise(freqX, freqY, octaves, seed, tileWidth, tileHeight);
|
28
29
|
});
|
29
30
|
|
30
31
|
const FractalNoise = props => {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["FractalNoise.tsx"],"names":["onDeclare","freqX","freqY","octaves","seed","tileWidth","tileHeight","Skia","Shader","MakeFractalNoise","FractalNoise","props","defaultProps"],"mappings":";;;;;;;AAAA;;AAEA
|
1
|
+
{"version":3,"sources":["FractalNoise.tsx"],"names":["onDeclare","_","freqX","freqY","octaves","seed","tileWidth","tileHeight","Skia","Shader","MakeFractalNoise","FractalNoise","props","defaultProps"],"mappings":";;;;;;;AAAA;;AAEA;;;;;;AAYA,MAAMA,SAAS,GAAG,oCAChB,OAAyDC,CAAzD,YAAyE;AAAA,MAAxE;AAAEC,IAAAA,KAAF;AAASC,IAAAA,KAAT;AAAgBC,IAAAA,OAAhB;AAAyBC,IAAAA,IAAzB;AAA+BC,IAAAA,SAA/B;AAA0CC,IAAAA;AAA1C,GAAwE;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AACvE,SAAOA,IAAI,CAACC,MAAL,CAAYC,gBAAZ,CACLR,KADK,EAELC,KAFK,EAGLC,OAHK,EAILC,IAJK,EAKLC,SALK,EAMLC,UANK,CAAP;AAQD,CAVe,CAAlB;;AAaO,MAAMI,YAAY,GAAIC,KAAD,IAA6C;AACvE,sBAAO;AAAe,IAAA,SAAS,EAAEZ;AAA1B,KAAyCY,KAAzC,EAAP;AACD,CAFM;;;AAIPD,YAAY,CAACE,YAAb,GAA4B;AAC1BR,EAAAA,IAAI,EAAE,CADoB;AAE1BC,EAAAA,SAAS,EAAE,CAFe;AAG1BC,EAAAA,UAAU,EAAE;AAHc,CAA5B","sourcesContent":["import React from \"react\";\n\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport type { AnimatedProps } from \"../../processors/Animations/Animations\";\n\nexport interface FractalNoiseProps {\n freqX: number;\n freqY: number;\n octaves: number;\n seed: number;\n tileWidth: number;\n tileHeight: number;\n}\n\nconst onDeclare = createDeclaration<FractalNoiseProps>(\n ({ freqX, freqY, octaves, seed, tileWidth, tileHeight }, _, { Skia }) => {\n return Skia.Shader.MakeFractalNoise(\n freqX,\n freqY,\n octaves,\n seed,\n tileWidth,\n tileHeight\n );\n }\n);\n\nexport const FractalNoise = (props: AnimatedProps<FractalNoiseProps>) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n\nFractalNoise.defaultProps = {\n seed: 0,\n tileWidth: 0,\n tileHeight: 0,\n};\n"]}
|
@@ -5,13 +5,13 @@ Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
});
|
6
6
|
exports.processGradientProps = void 0;
|
7
7
|
|
8
|
-
var
|
8
|
+
var _types = require("../../../skia/types");
|
9
9
|
|
10
10
|
var _Paint = require("../../processors/Paint");
|
11
11
|
|
12
12
|
var _Transform = require("../../processors/Transform");
|
13
13
|
|
14
|
-
const processGradientProps = _ref => {
|
14
|
+
const processGradientProps = (Skia, _ref) => {
|
15
15
|
let {
|
16
16
|
colors,
|
17
17
|
positions,
|
@@ -20,11 +20,11 @@ const processGradientProps = _ref => {
|
|
20
20
|
...transform
|
21
21
|
} = _ref;
|
22
22
|
return {
|
23
|
-
colors: colors.map(color =>
|
23
|
+
colors: colors.map(color => Skia.Color(color)),
|
24
24
|
positions: positions !== null && positions !== void 0 ? positions : null,
|
25
|
-
mode:
|
25
|
+
mode: _types.TileMode[(0, _Paint.enumKey)(mode !== null && mode !== void 0 ? mode : "clamp")],
|
26
26
|
flags,
|
27
|
-
localMatrix: (0, _Transform.localMatrix)(transform)
|
27
|
+
localMatrix: (0, _Transform.localMatrix)(Skia.Matrix(), transform)
|
28
28
|
};
|
29
29
|
};
|
30
30
|
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["Gradient.ts"],"names":["processGradientProps","colors","positions","mode","flags","transform","map","color","
|
1
|
+
{"version":3,"sources":["Gradient.ts"],"names":["processGradientProps","Skia","colors","positions","mode","flags","transform","map","color","Color","TileMode","localMatrix","Matrix"],"mappings":";;;;;;;AAAA;;AAGA;;AACA;;AAUO,MAAMA,oBAAoB,GAAG,CAClCC,IADkC;AAAA,MAElC;AAAEC,IAAAA,MAAF;AAAUC,IAAAA,SAAV;AAAqBC,IAAAA,IAArB;AAA2BC,IAAAA,KAA3B;AAAkC,OAAGC;AAArC,GAFkC;AAAA,SAG9B;AACJJ,IAAAA,MAAM,EAAEA,MAAM,CAACK,GAAP,CAAYC,KAAD,IAAWP,IAAI,CAACQ,KAAL,CAAWD,KAAX,CAAtB,CADJ;AAEJL,IAAAA,SAAS,EAAEA,SAAF,aAAEA,SAAF,cAAEA,SAAF,GAAe,IAFpB;AAGJC,IAAAA,IAAI,EAAEM,gBAAS,oBAAQN,IAAR,aAAQA,IAAR,cAAQA,IAAR,GAAgB,OAAhB,CAAT,CAHF;AAIJC,IAAAA,KAJI;AAKJM,IAAAA,WAAW,EAAE,4BAAYV,IAAI,CAACW,MAAL,EAAZ,EAA2BN,SAA3B;AALT,GAH8B;AAAA,CAA7B","sourcesContent":["import { TileMode } from \"../../../skia/types\";\nimport type { SkEnum } from \"../../processors/Paint\";\nimport type { TransformProps } from \"../../processors/Transform\";\nimport { enumKey } from \"../../processors/Paint\";\nimport { localMatrix } from \"../../processors/Transform\";\nimport type { Color, Skia } from \"../../../skia/types\";\n\nexport interface GradientProps extends TransformProps {\n colors: Color[];\n positions?: number[];\n mode?: SkEnum<typeof TileMode>;\n flags?: number;\n}\n\nexport const processGradientProps = (\n Skia: Skia,\n { colors, positions, mode, flags, ...transform }: GradientProps\n) => ({\n colors: colors.map((color) => Skia.Color(color)),\n positions: positions ?? null,\n mode: TileMode[enumKey(mode ?? \"clamp\")],\n flags,\n localMatrix: localMatrix(Skia.Matrix(), transform),\n});\n"]}
|
@@ -7,8 +7,6 @@ exports.LinearGradient = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var _skia = require("../../../skia");
|
11
|
-
|
12
10
|
var _Declaration = require("../../nodes/Declaration");
|
13
11
|
|
14
12
|
var _Gradient = require("./Gradient");
|
@@ -17,20 +15,23 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
17
15
|
|
18
16
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
19
17
|
|
20
|
-
const onDeclare = (0, _Declaration.createDeclaration)(_ref => {
|
18
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_ref, _, _ref2) => {
|
21
19
|
let {
|
22
20
|
start,
|
23
21
|
end,
|
24
22
|
...gradientProps
|
25
23
|
} = _ref;
|
24
|
+
let {
|
25
|
+
Skia
|
26
|
+
} = _ref2;
|
26
27
|
const {
|
27
28
|
colors,
|
28
29
|
positions,
|
29
30
|
mode,
|
30
31
|
localMatrix,
|
31
32
|
flags
|
32
|
-
} = (0, _Gradient.processGradientProps)(gradientProps);
|
33
|
-
return
|
33
|
+
} = (0, _Gradient.processGradientProps)(Skia, gradientProps);
|
34
|
+
return Skia.Shader.MakeLinearGradient(start, end, colors, positions, mode, localMatrix, flags);
|
34
35
|
});
|
35
36
|
|
36
37
|
const LinearGradient = props => {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["LinearGradient.tsx"],"names":["onDeclare","start","end","gradientProps","colors","positions","mode","localMatrix","flags","
|
1
|
+
{"version":3,"sources":["LinearGradient.tsx"],"names":["onDeclare","_","start","end","gradientProps","Skia","colors","positions","mode","localMatrix","flags","Shader","MakeLinearGradient","LinearGradient","props"],"mappings":";;;;;;;AAAA;;AAGA;;AAIA;;;;;;AAOA,MAAMA,SAAS,GAAG,oCAChB,OAAmCC,CAAnC,YAAmD;AAAA,MAAlD;AAAEC,IAAAA,KAAF;AAASC,IAAAA,GAAT;AAAc,OAAGC;AAAjB,GAAkD;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AACjD,QAAM;AAAEC,IAAAA,MAAF;AAAUC,IAAAA,SAAV;AAAqBC,IAAAA,IAArB;AAA2BC,IAAAA,WAA3B;AAAwCC,IAAAA;AAAxC,MACJ,oCAAqBL,IAArB,EAA2BD,aAA3B,CADF;AAEA,SAAOC,IAAI,CAACM,MAAL,CAAYC,kBAAZ,CACLV,KADK,EAELC,GAFK,EAGLG,MAHK,EAILC,SAJK,EAKLC,IALK,EAMLC,WANK,EAOLC,KAPK,CAAP;AASD,CAbe,CAAlB;;AAgBO,MAAMG,cAAc,GAAIC,KAAD,IAA+C;AAC3E,sBAAO;AAAe,IAAA,SAAS,EAAEd;AAA1B,KAAyCc,KAAzC,EAAP;AACD,CAFM","sourcesContent":["import React from \"react\";\n\nimport type { AnimatedProps } from \"../../processors\";\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport type { Vector } from \"../../../skia/types\";\n\nimport type { GradientProps } from \"./Gradient\";\nimport { processGradientProps } from \"./Gradient\";\n\nexport interface LinearGradientProps extends GradientProps {\n start: Vector;\n end: Vector;\n}\n\nconst onDeclare = createDeclaration<LinearGradientProps>(\n ({ start, end, ...gradientProps }, _, { Skia }) => {\n const { colors, positions, mode, localMatrix, flags } =\n processGradientProps(Skia, gradientProps);\n return Skia.Shader.MakeLinearGradient(\n start,\n end,\n colors,\n positions,\n mode,\n localMatrix,\n flags\n );\n }\n);\n\nexport const LinearGradient = (props: AnimatedProps<LinearGradientProps>) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n"]}
|
@@ -7,8 +7,6 @@ exports.RadialGradient = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var _skia = require("../../../skia");
|
11
|
-
|
12
10
|
var _Declaration = require("../../nodes/Declaration");
|
13
11
|
|
14
12
|
var _Gradient = require("./Gradient");
|
@@ -17,20 +15,23 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
17
15
|
|
18
16
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
19
17
|
|
20
|
-
const onDeclare = (0, _Declaration.createDeclaration)(_ref => {
|
18
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_ref, _, _ref2) => {
|
21
19
|
let {
|
22
20
|
c,
|
23
21
|
r,
|
24
22
|
...gradientProps
|
25
23
|
} = _ref;
|
24
|
+
let {
|
25
|
+
Skia
|
26
|
+
} = _ref2;
|
26
27
|
const {
|
27
28
|
colors,
|
28
29
|
positions,
|
29
30
|
mode,
|
30
31
|
localMatrix,
|
31
32
|
flags
|
32
|
-
} = (0, _Gradient.processGradientProps)(gradientProps);
|
33
|
-
return
|
33
|
+
} = (0, _Gradient.processGradientProps)(Skia, gradientProps);
|
34
|
+
return Skia.Shader.MakeRadialGradient(c, r, colors, positions, mode, localMatrix, flags);
|
34
35
|
});
|
35
36
|
|
36
37
|
const RadialGradient = props => {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["RadialGradient.tsx"],"names":["onDeclare","c","r","gradientProps","colors","positions","mode","localMatrix","flags","
|
1
|
+
{"version":3,"sources":["RadialGradient.tsx"],"names":["onDeclare","_","c","r","gradientProps","Skia","colors","positions","mode","localMatrix","flags","Shader","MakeRadialGradient","RadialGradient","props"],"mappings":";;;;;;;AAAA;;AAGA;;AAIA;;;;;;AAOA,MAAMA,SAAS,GAAG,oCAChB,OAA6BC,CAA7B,YAA6C;AAAA,MAA5C;AAAEC,IAAAA,CAAF;AAAKC,IAAAA,CAAL;AAAQ,OAAGC;AAAX,GAA4C;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AAC3C,QAAM;AAAEC,IAAAA,MAAF;AAAUC,IAAAA,SAAV;AAAqBC,IAAAA,IAArB;AAA2BC,IAAAA,WAA3B;AAAwCC,IAAAA;AAAxC,MACJ,oCAAqBL,IAArB,EAA2BD,aAA3B,CADF;AAEA,SAAOC,IAAI,CAACM,MAAL,CAAYC,kBAAZ,CACLV,CADK,EAELC,CAFK,EAGLG,MAHK,EAILC,SAJK,EAKLC,IALK,EAMLC,WANK,EAOLC,KAPK,CAAP;AASD,CAbe,CAAlB;;AAgBO,MAAMG,cAAc,GAAIC,KAAD,IAA+C;AAC3E,sBAAO;AAAe,IAAA,SAAS,EAAEd;AAA1B,KAAyCc,KAAzC,EAAP;AACD,CAFM","sourcesContent":["import React from \"react\";\n\nimport type { AnimatedProps } from \"../../processors\";\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport type { Vector } from \"../../../skia/types\";\n\nimport type { GradientProps } from \"./Gradient\";\nimport { processGradientProps } from \"./Gradient\";\n\nexport interface RadialGradientProps extends GradientProps {\n c: Vector;\n r: number;\n}\n\nconst onDeclare = createDeclaration<RadialGradientProps>(\n ({ c, r, ...gradientProps }, _, { Skia }) => {\n const { colors, positions, mode, localMatrix, flags } =\n processGradientProps(Skia, gradientProps);\n return Skia.Shader.MakeRadialGradient(\n c,\n r,\n colors,\n positions,\n mode,\n localMatrix,\n flags\n );\n }\n);\n\nexport const RadialGradient = (props: AnimatedProps<RadialGradientProps>) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n"]}
|
@@ -7,7 +7,7 @@ exports.Shader = void 0;
|
|
7
7
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
9
9
|
|
10
|
-
var
|
10
|
+
var _types = require("../../../skia/types");
|
11
11
|
|
12
12
|
var _Declaration = require("../../nodes/Declaration");
|
13
13
|
|
@@ -17,53 +17,16 @@ function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { de
|
|
17
17
|
|
18
18
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
19
19
|
|
20
|
-
const
|
21
|
-
// eslint-disable-next-line @typescript-eslint/no-explicit-any
|
22
|
-
obj.x !== undefined && obj.y !== undefined;
|
23
|
-
|
24
|
-
const processValue = value => {
|
25
|
-
if (isVector(value)) {
|
26
|
-
return [value.x, value.y];
|
27
|
-
}
|
28
|
-
|
29
|
-
return value;
|
30
|
-
};
|
31
|
-
|
32
|
-
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children) => {
|
20
|
+
const onDeclare = (0, _Declaration.createDeclaration)((_ref, children, _ref2) => {
|
33
21
|
let {
|
34
22
|
uniforms,
|
35
23
|
source,
|
36
24
|
...transform
|
37
25
|
} = _ref;
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
if (value === undefined) {
|
43
|
-
throw new Error(`No value specified for uniform ${name}`);
|
44
|
-
}
|
45
|
-
|
46
|
-
if (Array.isArray(value)) {
|
47
|
-
return value.flatMap(processValue);
|
48
|
-
}
|
49
|
-
|
50
|
-
return processValue(value);
|
51
|
-
});
|
52
|
-
const names = Object.keys(uniforms);
|
53
|
-
|
54
|
-
if (names.length > source.getUniformCount()) {
|
55
|
-
const usedUniforms = new Array(source.getUniformCount()).fill(0).map((_, i) => source.getUniformName(i));
|
56
|
-
const unusedUniform = names.map(name => {
|
57
|
-
if (usedUniforms.indexOf(name) === -1) {
|
58
|
-
return name;
|
59
|
-
}
|
60
|
-
|
61
|
-
return null;
|
62
|
-
}).filter(n => n !== null);
|
63
|
-
console.warn("Unused uniforms were provided: " + unusedUniform.join(", "));
|
64
|
-
}
|
65
|
-
|
66
|
-
return source.makeShaderWithChildren(processedUniforms, children.filter(_skia.isShader), (0, _processors.localMatrix)(transform));
|
26
|
+
let {
|
27
|
+
Skia
|
28
|
+
} = _ref2;
|
29
|
+
return source.makeShaderWithChildren((0, _types.processUniforms)(source, uniforms), children.filter(_types.isShader), (0, _processors.localMatrix)(Skia.Matrix(), transform));
|
67
30
|
});
|
68
31
|
|
69
32
|
const Shader = props => {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["Shader.tsx"],"names":["
|
1
|
+
{"version":3,"sources":["Shader.tsx"],"names":["onDeclare","children","uniforms","source","transform","Skia","makeShaderWithChildren","filter","isShader","Matrix","Shader","props","defaultProps"],"mappings":";;;;;;;AAAA;;AAIA;;AAEA;;AACA;;;;;;AAQA,MAAMA,SAAS,GAAG,oCAChB,OAAqCC,QAArC,YAA4D;AAAA,MAA3D;AAAEC,IAAAA,QAAF;AAAYC,IAAAA,MAAZ;AAAoB,OAAGC;AAAvB,GAA2D;AAAA,MAAb;AAAEC,IAAAA;AAAF,GAAa;AAC1D,SAAOF,MAAM,CAACG,sBAAP,CACL,4BAAgBH,MAAhB,EAAwBD,QAAxB,CADK,EAELD,QAAQ,CAACM,MAAT,CAAgBC,eAAhB,CAFK,EAGL,6BAAYH,IAAI,CAACI,MAAL,EAAZ,EAA2BL,SAA3B,CAHK,CAAP;AAKD,CAPe,CAAlB;;AAUO,MAAMM,MAAM,GAAIC,KAAD,IAAuC;AAC3D,sBAAO;AAAe,IAAA,SAAS,EAAEX;AAA1B,KAAyCW,KAAzC,EAAP;AACD,CAFM;;;AAIPD,MAAM,CAACE,YAAP,GAAsB;AACpBV,EAAAA,QAAQ,EAAE;AADU,CAAtB","sourcesContent":["import React from \"react\";\nimport type { ReactNode } from \"react\";\n\nimport type { SkRuntimeEffect, Uniforms } from \"../../../skia/types\";\nimport { isShader, processUniforms } from \"../../../skia/types\";\nimport type { AnimatedProps, TransformProps } from \"../../processors\";\nimport { createDeclaration } from \"../../nodes/Declaration\";\nimport { localMatrix } from \"../../processors\";\n\nexport interface ShaderProps extends TransformProps {\n source: SkRuntimeEffect;\n uniforms: Uniforms;\n children?: ReactNode | ReactNode[];\n}\n\nconst onDeclare = createDeclaration<ShaderProps>(\n ({ uniforms, source, ...transform }, children, { Skia }) => {\n return source.makeShaderWithChildren(\n processUniforms(source, uniforms),\n children.filter(isShader),\n localMatrix(Skia.Matrix(), transform)\n );\n }\n);\n\nexport const Shader = (props: AnimatedProps<ShaderProps>) => {\n return <skDeclaration onDeclare={onDeclare} {...props} />;\n};\n\nShader.defaultProps = {\n uniforms: [],\n};\n"]}
|