@shopify/react-native-skia 0.1.130 → 0.1.133
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/cpp/rnskia-android/RNSkDrawViewImpl.cpp +5 -0
- package/android/src/main/java/com/shopify/reactnative/skia/SkiaDrawView.java +2 -1
- package/cpp/api/JsiSkCanvas.h +2 -2
- package/cpp/api/JsiSkFont.h +6 -2
- package/cpp/api/JsiSkImage.h +2 -19
- package/cpp/api/JsiSkMatrix.h +40 -27
- package/cpp/api/JsiSkPaint.h +8 -33
- package/cpp/api/JsiSkPath.h +71 -65
- 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 +27 -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/Font/Font.js.map +1 -1
- package/lib/commonjs/skia/types/Image/Image.js +5 -5
- package/lib/commonjs/skia/types/Image/Image.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/Paint/Paint.js +3 -3
- package/lib/commonjs/skia/types/Paint/Paint.js.map +1 -1
- 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 +45 -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/{api/JsiSkCanvas.js → JsiSkCanvas.js} +21 -7
- 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 +113 -0
- package/lib/commonjs/skia/web/JsiSkFont.js.map +1 -0
- package/lib/commonjs/skia/web/JsiSkFontMgr.js +33 -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} +10 -6
- package/lib/commonjs/skia/web/JsiSkImage.js.map +1 -0
- 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/JsiSkImageFilterFactory.js +68 -0
- package/lib/commonjs/skia/web/JsiSkImageFilterFactory.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 +337 -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 +49 -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 +22 -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/Font/Font.js.map +1 -1
- package/lib/module/skia/types/Image/Image.js +5 -5
- package/lib/module/skia/types/Image/Image.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/Paint/Paint.js +3 -3
- package/lib/module/skia/types/Paint/Paint.js.map +1 -1
- 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 +42 -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/{api/JsiSkCanvas.js → JsiSkCanvas.js} +20 -7
- 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 +101 -0
- package/lib/module/skia/web/JsiSkFont.js.map +1 -0
- package/lib/module/skia/web/JsiSkFontMgr.js +23 -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/JsiSkImage.js +49 -0
- package/lib/module/skia/web/JsiSkImage.js.map +1 -0
- 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/JsiSkImageFilterFactory.js +57 -0
- package/lib/module/skia/web/JsiSkImageFilterFactory.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 +324 -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 +39 -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 +10 -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/Font/Font.d.ts +8 -9
- 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/Image.d.ts +5 -5
- 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/Paint/Paint.d.ts +3 -3
- package/lib/typescript/src/skia/types/Path/Path.d.ts +27 -22
- 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 -1
- 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/{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} +4 -4
- 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/JsiSkImageFilterFactory.d.ts +19 -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/Font/Font.ts +9 -14
- package/src/skia/types/FontMgr/FontMgr.ts +1 -1
- package/src/skia/types/FontMgr/FontMgrFactory.ts +2 -2
- package/src/skia/types/Image/Image.ts +4 -4
- package/src/skia/types/Image/ImageFactory.ts +3 -3
- package/src/skia/types/Matrix.ts +79 -14
- package/src/skia/types/Paint/Paint.ts +1 -1
- package/src/skia/types/Path/Path.ts +33 -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 -1
- package/src/skia/types/SVG/SVGFactory.ts +2 -2
- package/src/skia/types/Shader/Shader.ts +59 -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/{api/JsiSkCanvas.ts → JsiSkCanvas.ts} +20 -12
- 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 +128 -0
- package/src/skia/web/JsiSkFontMgr.ts +38 -0
- package/src/skia/web/JsiSkFontMgrFactory.ts +18 -0
- package/src/skia/web/JsiSkImage.ts +87 -0
- package/src/skia/web/JsiSkImageFactory.ts +40 -0
- package/src/skia/web/JsiSkImageFilter.ts +14 -0
- package/src/skia/web/JsiSkImageFilterFactory.ts +144 -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} +7 -6
- package/src/skia/web/JsiSkPath.ts +386 -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 +181 -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 +41 -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 +190 -0
- package/src/views/types.ts +1 -0
- package/src/views/useTouchHandler.ts +82 -51
- package/src/web/index.ts +15 -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/JsiSkImage.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/JsiSkImage.js +0 -46
- package/lib/module/skia/web/api/JsiSkImage.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/JsiSkImage.ts +0 -66
- 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
@@ -0,0 +1,26 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkPoint = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
class JsiSkPoint extends _Host.HostObject {
|
11
|
+
constructor(CanvasKit, ref) {
|
12
|
+
super(CanvasKit, ref, "Point");
|
13
|
+
}
|
14
|
+
|
15
|
+
get x() {
|
16
|
+
return this.ref[0];
|
17
|
+
}
|
18
|
+
|
19
|
+
get y() {
|
20
|
+
return this.ref[1];
|
21
|
+
}
|
22
|
+
|
23
|
+
}
|
24
|
+
|
25
|
+
exports.JsiSkPoint = JsiSkPoint;
|
26
|
+
//# sourceMappingURL=JsiSkPoint.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkPoint.ts"],"names":["JsiSkPoint","HostObject","constructor","CanvasKit","ref","x","y"],"mappings":";;;;;;;AAIA;;AAEO,MAAMA,UAAN,SAAyBC,gBAAzB,CAAuE;AAC5EC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAAmC;AAC5C,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,OAAtB;AACD;;AAEI,MAADC,CAAC,GAAG;AACN,WAAO,KAAKD,GAAL,CAAS,CAAT,CAAP;AACD;;AAEI,MAADE,CAAC,GAAG;AACN,WAAO,KAAKF,GAAL,CAAS,CAAT,CAAP;AACD;;AAX2E","sourcesContent":["import type { CanvasKit, Point } from \"canvaskit-wasm\";\n\nimport type { SkPoint } from \"../types\";\n\nimport { HostObject } from \"./Host\";\n\nexport class JsiSkPoint extends HostObject<Point, \"Point\"> implements SkPoint {\n constructor(CanvasKit: CanvasKit, ref: Point) {\n super(CanvasKit, ref, \"Point\");\n }\n\n get x() {\n return this.ref[0];\n }\n\n get y() {\n return this.ref[1];\n }\n}\n"]}
|
@@ -0,0 +1,32 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkRRect = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
var _JsiSkRect = require("./JsiSkRect");
|
11
|
+
|
12
|
+
class JsiSkRRect extends _Host.HostObject {
|
13
|
+
constructor(CanvasKit, ref) {
|
14
|
+
super(CanvasKit, ref, "RRect");
|
15
|
+
}
|
16
|
+
|
17
|
+
get rx() {
|
18
|
+
return this.ref[4];
|
19
|
+
}
|
20
|
+
|
21
|
+
get ry() {
|
22
|
+
return this.ref[5];
|
23
|
+
}
|
24
|
+
|
25
|
+
get rect() {
|
26
|
+
return new _JsiSkRect.JsiSkRect(this.CanvasKit, Float32Array.of(this.ref[0], this.ref[1], this.ref[2], this.ref[3]));
|
27
|
+
}
|
28
|
+
|
29
|
+
}
|
30
|
+
|
31
|
+
exports.JsiSkRRect = JsiSkRRect;
|
32
|
+
//# sourceMappingURL=JsiSkRRect.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkRRect.ts"],"names":["JsiSkRRect","HostObject","constructor","CanvasKit","ref","rx","ry","rect","JsiSkRect","Float32Array","of"],"mappings":";;;;;;;AAIA;;AACA;;AAEO,MAAMA,UAAN,SAAyBC,gBAAzB,CAAuE;AAC5EC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAAmC;AAC5C,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,OAAtB;AACD;;AAEK,MAAFC,EAAE,GAAG;AACP,WAAO,KAAKD,GAAL,CAAS,CAAT,CAAP;AACD;;AAEK,MAAFE,EAAE,GAAG;AACP,WAAO,KAAKF,GAAL,CAAS,CAAT,CAAP;AACD;;AAEO,MAAJG,IAAI,GAAG;AACT,WAAO,IAAIC,oBAAJ,CACL,KAAKL,SADA,EAELM,YAAY,CAACC,EAAb,CAAgB,KAAKN,GAAL,CAAS,CAAT,CAAhB,EAA6B,KAAKA,GAAL,CAAS,CAAT,CAA7B,EAA0C,KAAKA,GAAL,CAAS,CAAT,CAA1C,EAAuD,KAAKA,GAAL,CAAS,CAAT,CAAvD,CAFK,CAAP;AAID;;AAlB2E","sourcesContent":["import type { CanvasKit, RRect } from \"canvaskit-wasm\";\n\nimport type { SkRRect } from \"../types\";\n\nimport { HostObject } from \"./Host\";\nimport { JsiSkRect } from \"./JsiSkRect\";\n\nexport class JsiSkRRect extends HostObject<RRect, \"RRect\"> implements SkRRect {\n constructor(CanvasKit: CanvasKit, ref: RRect) {\n super(CanvasKit, ref, \"RRect\");\n }\n\n get rx() {\n return this.ref[4];\n }\n\n get ry() {\n return this.ref[5];\n }\n\n get rect() {\n return new JsiSkRect(\n this.CanvasKit,\n Float32Array.of(this.ref[0], this.ref[1], this.ref[2], this.ref[3])\n );\n }\n}\n"]}
|
@@ -0,0 +1,18 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkRSXform = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
class JsiSkRSXform extends _Host.HostObject {
|
11
|
+
constructor(CanvasKit, ref) {
|
12
|
+
super(CanvasKit, ref, "RSXform");
|
13
|
+
}
|
14
|
+
|
15
|
+
}
|
16
|
+
|
17
|
+
exports.JsiSkRSXform = JsiSkRSXform;
|
18
|
+
//# sourceMappingURL=JsiSkRSXform.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkRSXform.ts"],"names":["JsiSkRSXform","HostObject","constructor","CanvasKit","ref"],"mappings":";;;;;;;AAIA;;AAIO,MAAMA,YAAN,SACGC,gBADH,CAGP;AACEC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAAqC;AAC9C,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,SAAtB;AACD;;AAHH","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type { SkRSXform } from \"../types\";\n\nimport { HostObject } from \"./Host\";\n\ntype RSXform = Float32Array;\n\nexport class JsiSkRSXform\n extends HostObject<RSXform, \"RSXform\">\n implements SkRSXform\n{\n constructor(CanvasKit: CanvasKit, ref: RSXform) {\n super(CanvasKit, ref, \"RSXform\");\n }\n}\n"]}
|
@@ -8,6 +8,14 @@ exports.JsiSkRect = void 0;
|
|
8
8
|
var _Host = require("./Host");
|
9
9
|
|
10
10
|
class JsiSkRect extends _Host.HostObject {
|
11
|
+
static fromValue(CanvasKit, rect) {
|
12
|
+
if (rect instanceof JsiSkRect) {
|
13
|
+
return rect;
|
14
|
+
}
|
15
|
+
|
16
|
+
return new JsiSkRect(CanvasKit, CanvasKit.XYWHRect(rect.x, rect.y, rect.width, rect.height));
|
17
|
+
}
|
18
|
+
|
11
19
|
constructor(CanvasKit, ref) {
|
12
20
|
super(CanvasKit, ref, "Rect");
|
13
21
|
}
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkRect.ts"],"names":["JsiSkRect","HostObject","fromValue","CanvasKit","rect","XYWHRect","x","y","width","height","constructor","ref"],"mappings":";;;;;;;AAIA;;AAEO,MAAMA,SAAN,SAAwBC,gBAAxB,CAAmE;AACxD,SAATC,SAAS,CAACC,SAAD,EAAuBC,IAAvB,EAAqC;AACnD,QAAIA,IAAI,YAAYJ,SAApB,EAA+B;AAC7B,aAAOI,IAAP;AACD;;AACD,WAAO,IAAIJ,SAAJ,CACLG,SADK,EAELA,SAAS,CAACE,QAAV,CAAmBD,IAAI,CAACE,CAAxB,EAA2BF,IAAI,CAACG,CAAhC,EAAmCH,IAAI,CAACI,KAAxC,EAA+CJ,IAAI,CAACK,MAApD,CAFK,CAAP;AAID;;AAEDC,EAAAA,WAAW,CAACP,SAAD,EAAuBQ,GAAvB,EAAkC;AAC3C,UAAMR,SAAN,EAAiBQ,GAAjB,EAAsB,MAAtB;AACD;;AAEI,MAADL,CAAC,GAAG;AACN,WAAO,KAAKK,GAAL,CAAS,CAAT,CAAP;AACD;;AAEI,MAADJ,CAAC,GAAG;AACN,WAAO,KAAKI,GAAL,CAAS,CAAT,CAAP;AACD;;AAEQ,MAALH,KAAK,GAAG;AACV,WAAO,KAAKG,GAAL,CAAS,CAAT,IAAc,KAAKA,GAAL,CAAS,CAAT,CAArB;AACD;;AAES,MAANF,MAAM,GAAG;AACX,WAAO,KAAKE,GAAL,CAAS,CAAT,IAAc,KAAKA,GAAL,CAAS,CAAT,CAArB;AACD;;AA7BuE","sourcesContent":["import type { CanvasKit, Rect } from \"canvaskit-wasm\";\n\nimport type { SkRect } from \"../types\";\n\nimport { HostObject } from \"./Host\";\n\nexport class JsiSkRect extends HostObject<Rect, \"Rect\"> implements SkRect {\n static fromValue(CanvasKit: CanvasKit, rect: SkRect) {\n if (rect instanceof JsiSkRect) {\n return rect;\n }\n return new JsiSkRect(\n CanvasKit,\n CanvasKit.XYWHRect(rect.x, rect.y, rect.width, rect.height)\n );\n }\n\n constructor(CanvasKit: CanvasKit, ref: Rect) {\n super(CanvasKit, ref, \"Rect\");\n }\n\n get x() {\n return this.ref[0];\n }\n\n get y() {\n return this.ref[1];\n }\n\n get width() {\n return this.ref[2] - this.ref[0];\n }\n\n get height() {\n return this.ref[3] - this.ref[1];\n }\n}\n"]}
|
@@ -0,0 +1,44 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkRuntimeEffect = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
var _JsiSkShader = require("./JsiSkShader");
|
11
|
+
|
12
|
+
class JsiSkRuntimeEffect extends _Host.HostObject {
|
13
|
+
constructor(CanvasKit, ref) {
|
14
|
+
super(CanvasKit, ref, "RuntimeEffect");
|
15
|
+
}
|
16
|
+
|
17
|
+
makeShader(uniforms, localMatrix) {
|
18
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.ref.makeShader(uniforms, localMatrix !== undefined ? (0, _Host.toValue)(localMatrix) : localMatrix));
|
19
|
+
}
|
20
|
+
|
21
|
+
makeShaderWithChildren(uniforms, children, localMatrix) {
|
22
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.ref.makeShaderWithChildren(uniforms, children === null || children === void 0 ? void 0 : children.map(child => (0, _Host.toValue)(child)), localMatrix !== undefined ? (0, _Host.toValue)(localMatrix) : localMatrix));
|
23
|
+
}
|
24
|
+
|
25
|
+
getUniform(index) {
|
26
|
+
return this.ref.getUniform(index);
|
27
|
+
}
|
28
|
+
|
29
|
+
getUniformCount() {
|
30
|
+
return this.ref.getUniformCount();
|
31
|
+
}
|
32
|
+
|
33
|
+
getUniformFloatCount() {
|
34
|
+
return this.ref.getUniformFloatCount();
|
35
|
+
}
|
36
|
+
|
37
|
+
getUniformName(index) {
|
38
|
+
return this.ref.getUniformName(index);
|
39
|
+
}
|
40
|
+
|
41
|
+
}
|
42
|
+
|
43
|
+
exports.JsiSkRuntimeEffect = JsiSkRuntimeEffect;
|
44
|
+
//# sourceMappingURL=JsiSkRuntimeEffect.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkRuntimeEffect.ts"],"names":["JsiSkRuntimeEffect","HostObject","constructor","CanvasKit","ref","makeShader","uniforms","localMatrix","JsiSkShader","undefined","makeShaderWithChildren","children","map","child","getUniform","index","getUniformCount","getUniformFloatCount","getUniformName"],"mappings":";;;;;;;AAKA;;AACA;;AAEO,MAAMA,kBAAN,SACGC,gBADH,CAGP;AACEC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAA2C;AACpD,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,eAAtB;AACD;;AAEDC,EAAAA,UAAU,CAACC,QAAD,EAAqBC,WAArB,EAA6C;AACrD,WAAO,IAAIC,wBAAJ,CACL,KAAKL,SADA,EAEL,KAAKC,GAAL,CAASC,UAAT,CACEC,QADF,EAEEC,WAAW,KAAKE,SAAhB,GAA4B,mBAAQF,WAAR,CAA5B,GAAmDA,WAFrD,CAFK,CAAP;AAOD;;AAEDG,EAAAA,sBAAsB,CACpBJ,QADoB,EAEpBK,QAFoB,EAGpBJ,WAHoB,EAIpB;AACA,WAAO,IAAIC,wBAAJ,CACL,KAAKL,SADA,EAEL,KAAKC,GAAL,CAASM,sBAAT,CACEJ,QADF,EAEEK,QAFF,aAEEA,QAFF,uBAEEA,QAAQ,CAAEC,GAAV,CAAeC,KAAD,IAAW,mBAAQA,KAAR,CAAzB,CAFF,EAGEN,WAAW,KAAKE,SAAhB,GAA4B,mBAAQF,WAAR,CAA5B,GAAmDA,WAHrD,CAFK,CAAP;AAQD;;AAEDO,EAAAA,UAAU,CAACC,KAAD,EAAgB;AACxB,WAAO,KAAKX,GAAL,CAASU,UAAT,CAAoBC,KAApB,CAAP;AACD;;AAEDC,EAAAA,eAAe,GAAG;AAChB,WAAO,KAAKZ,GAAL,CAASY,eAAT,EAAP;AACD;;AAEDC,EAAAA,oBAAoB,GAAG;AACrB,WAAO,KAAKb,GAAL,CAASa,oBAAT,EAAP;AACD;;AAEDC,EAAAA,cAAc,CAACH,KAAD,EAAgB;AAC5B,WAAO,KAAKX,GAAL,CAASc,cAAT,CAAwBH,KAAxB,CAAP;AACD;;AA5CH","sourcesContent":["import type { CanvasKit, RuntimeEffect } from \"canvaskit-wasm\";\n\nimport type { SkMatrix, SkShader } from \"../types\";\nimport type { SkRuntimeEffect } from \"../types/RuntimeEffect/RuntimeEffect\";\n\nimport { HostObject, toValue } from \"./Host\";\nimport { JsiSkShader } from \"./JsiSkShader\";\n\nexport class JsiSkRuntimeEffect\n extends HostObject<RuntimeEffect, \"RuntimeEffect\">\n implements SkRuntimeEffect\n{\n constructor(CanvasKit: CanvasKit, ref: RuntimeEffect) {\n super(CanvasKit, ref, \"RuntimeEffect\");\n }\n\n makeShader(uniforms: number[], localMatrix?: SkMatrix) {\n return new JsiSkShader(\n this.CanvasKit,\n this.ref.makeShader(\n uniforms,\n localMatrix !== undefined ? toValue(localMatrix) : localMatrix\n )\n );\n }\n\n makeShaderWithChildren(\n uniforms: number[],\n children?: SkShader[],\n localMatrix?: SkMatrix\n ) {\n return new JsiSkShader(\n this.CanvasKit,\n this.ref.makeShaderWithChildren(\n uniforms,\n children?.map((child) => toValue(child)),\n localMatrix !== undefined ? toValue(localMatrix) : localMatrix\n )\n );\n }\n\n getUniform(index: number) {\n return this.ref.getUniform(index);\n }\n\n getUniformCount() {\n return this.ref.getUniformCount();\n }\n\n getUniformFloatCount() {\n return this.ref.getUniformFloatCount();\n }\n\n getUniformName(index: number) {\n return this.ref.getUniformName(index);\n }\n}\n"]}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkRuntimeEffectFactory = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
var _JsiSkRuntimeEffect = require("./JsiSkRuntimeEffect");
|
11
|
+
|
12
|
+
class JsiSkRuntimeEffectFactory extends _Host.Host {
|
13
|
+
constructor(CanvasKit) {
|
14
|
+
super(CanvasKit);
|
15
|
+
}
|
16
|
+
|
17
|
+
Make(sksl) {
|
18
|
+
const re = this.CanvasKit.RuntimeEffect.Make(sksl);
|
19
|
+
|
20
|
+
if (re === null) {
|
21
|
+
return null;
|
22
|
+
}
|
23
|
+
|
24
|
+
return new _JsiSkRuntimeEffect.JsiSkRuntimeEffect(this.CanvasKit, re);
|
25
|
+
}
|
26
|
+
|
27
|
+
}
|
28
|
+
|
29
|
+
exports.JsiSkRuntimeEffectFactory = JsiSkRuntimeEffectFactory;
|
30
|
+
//# sourceMappingURL=JsiSkRuntimeEffectFactory.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkRuntimeEffectFactory.ts"],"names":["JsiSkRuntimeEffectFactory","Host","constructor","CanvasKit","Make","sksl","re","RuntimeEffect","JsiSkRuntimeEffect"],"mappings":";;;;;;;AAIA;;AACA;;AAEO,MAAMA,yBAAN,SACGC,UADH,CAGP;AACEC,EAAAA,WAAW,CAACC,SAAD,EAAuB;AAChC,UAAMA,SAAN;AACD;;AAEDC,EAAAA,IAAI,CAACC,IAAD,EAAe;AACjB,UAAMC,EAAE,GAAG,KAAKH,SAAL,CAAeI,aAAf,CAA6BH,IAA7B,CAAkCC,IAAlC,CAAX;;AACA,QAAIC,EAAE,KAAK,IAAX,EAAiB;AACf,aAAO,IAAP;AACD;;AACD,WAAO,IAAIE,sCAAJ,CAAuB,KAAKL,SAA5B,EAAuCG,EAAvC,CAAP;AACD;;AAXH","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type { RuntimeEffectFactory } from \"../types/RuntimeEffect/RuntimeEffectFactory\";\n\nimport { Host } from \"./Host\";\nimport { JsiSkRuntimeEffect } from \"./JsiSkRuntimeEffect\";\n\nexport class JsiSkRuntimeEffectFactory\n extends Host\n implements RuntimeEffectFactory\n{\n constructor(CanvasKit: CanvasKit) {\n super(CanvasKit);\n }\n\n Make(sksl: string) {\n const re = this.CanvasKit.RuntimeEffect.Make(sksl);\n if (re === null) {\n return null;\n }\n return new JsiSkRuntimeEffect(this.CanvasKit, re);\n }\n}\n"]}
|
@@ -0,0 +1,26 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkSVGFactory = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
class JsiSkSVGFactory extends _Host.Host {
|
11
|
+
constructor(CanvasKit) {
|
12
|
+
super(CanvasKit);
|
13
|
+
}
|
14
|
+
|
15
|
+
MakeFromData(_data) {
|
16
|
+
throw new _Host.NotImplementedOnRNWeb();
|
17
|
+
}
|
18
|
+
|
19
|
+
MakeFromString(_str) {
|
20
|
+
throw new _Host.NotImplementedOnRNWeb();
|
21
|
+
}
|
22
|
+
|
23
|
+
}
|
24
|
+
|
25
|
+
exports.JsiSkSVGFactory = JsiSkSVGFactory;
|
26
|
+
//# sourceMappingURL=JsiSkSVGFactory.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkSVGFactory.ts"],"names":["JsiSkSVGFactory","Host","constructor","CanvasKit","MakeFromData","_data","NotImplementedOnRNWeb","MakeFromString","_str"],"mappings":";;;;;;;AAKA;;AAEO,MAAMA,eAAN,SAA8BC,UAA9B,CAAyD;AAC9DC,EAAAA,WAAW,CAACC,SAAD,EAAuB;AAChC,UAAMA,SAAN;AACD;;AAEDC,EAAAA,YAAY,CAACC,KAAD,EAA8B;AACxC,UAAM,IAAIC,2BAAJ,EAAN;AACD;;AAEDC,EAAAA,cAAc,CAACC,IAAD,EAA6B;AACzC,UAAM,IAAIF,2BAAJ,EAAN;AACD;;AAX6D","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type { SkData, SkSVG } from \"../types\";\nimport type { SVGFactory } from \"../types/SVG/SVGFactory\";\n\nimport { Host, NotImplementedOnRNWeb } from \"./Host\";\n\nexport class JsiSkSVGFactory extends Host implements SVGFactory {\n constructor(CanvasKit: CanvasKit) {\n super(CanvasKit);\n }\n\n MakeFromData(_data: SkData): SkSVG | null {\n throw new NotImplementedOnRNWeb();\n }\n\n MakeFromString(_str: string): SkSVG | null {\n throw new NotImplementedOnRNWeb();\n }\n}\n"]}
|
@@ -0,0 +1,18 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkShader = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
class JsiSkShader extends _Host.HostObject {
|
11
|
+
constructor(CanvasKit, ref) {
|
12
|
+
super(CanvasKit, ref, "Shader");
|
13
|
+
}
|
14
|
+
|
15
|
+
}
|
16
|
+
|
17
|
+
exports.JsiSkShader = JsiSkShader;
|
18
|
+
//# sourceMappingURL=JsiSkShader.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkShader.ts"],"names":["JsiSkShader","HostObject","constructor","CanvasKit","ref"],"mappings":";;;;;;;AAIA;;AAEO,MAAMA,WAAN,SACGC,gBADH,CAGP;AACEC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAAoC;AAC7C,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,QAAtB;AACD;;AAHH","sourcesContent":["import type { CanvasKit, Shader } from \"canvaskit-wasm\";\n\nimport type { SkShader } from \"../types\";\n\nimport { HostObject } from \"./Host\";\n\nexport class JsiSkShader\n extends HostObject<Shader, \"Shader\">\n implements SkShader\n{\n constructor(CanvasKit: CanvasKit, ref: Shader) {\n super(CanvasKit, ref, \"Shader\");\n }\n}\n"]}
|
@@ -0,0 +1,52 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkShaderFactory = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
var _JsiSkShader = require("./JsiSkShader");
|
11
|
+
|
12
|
+
class JsiSkShaderFactory extends _Host.Host {
|
13
|
+
constructor(CanvasKit) {
|
14
|
+
super(CanvasKit);
|
15
|
+
}
|
16
|
+
|
17
|
+
MakeLinearGradient(start, end, colors, pos, mode, localMatrix, flags) {
|
18
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.CanvasKit.Shader.MakeLinearGradient((0, _Host.toValue)(start), (0, _Host.toValue)(end), colors, pos, (0, _Host.ckEnum)(mode), localMatrix === undefined ? undefined : (0, _Host.toValue)(localMatrix), flags));
|
19
|
+
}
|
20
|
+
|
21
|
+
MakeRadialGradient(center, radius, colors, pos, mode, localMatrix, flags) {
|
22
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.CanvasKit.Shader.MakeRadialGradient((0, _Host.toValue)(center), radius, colors, pos, (0, _Host.ckEnum)(mode), localMatrix === undefined ? undefined : (0, _Host.toValue)(localMatrix), flags));
|
23
|
+
}
|
24
|
+
|
25
|
+
MakeTwoPointConicalGradient(start, startRadius, end, endRadius, colors, pos, mode, localMatrix, flags) {
|
26
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.CanvasKit.Shader.MakeTwoPointConicalGradient((0, _Host.toValue)(start), startRadius, (0, _Host.toValue)(end), endRadius, colors, pos, (0, _Host.ckEnum)(mode), localMatrix === undefined ? undefined : (0, _Host.toValue)(localMatrix), flags));
|
27
|
+
}
|
28
|
+
|
29
|
+
MakeSweepGradient(cx, cy, colors, pos, mode, localMatrix, flags, startAngleInDegrees, endAngleInDegrees) {
|
30
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.CanvasKit.Shader.MakeSweepGradient(cx, cy, colors, pos, (0, _Host.ckEnum)(mode), localMatrix === undefined || localMatrix === null ? undefined : (0, _Host.toValue)(localMatrix), flags, startAngleInDegrees, endAngleInDegrees));
|
31
|
+
}
|
32
|
+
|
33
|
+
MakeTurbulence(baseFreqX, baseFreqY, octaves, seed, tileW, tileH) {
|
34
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.CanvasKit.Shader.MakeTurbulence(baseFreqX, baseFreqY, octaves, seed, tileW, tileH));
|
35
|
+
}
|
36
|
+
|
37
|
+
MakeFractalNoise(baseFreqX, baseFreqY, octaves, seed, tileW, tileH) {
|
38
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.CanvasKit.Shader.MakeFractalNoise(baseFreqX, baseFreqY, octaves, seed, tileW, tileH));
|
39
|
+
}
|
40
|
+
|
41
|
+
MakeBlend(mode, one, two) {
|
42
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.CanvasKit.Shader.MakeBlend((0, _Host.ckEnum)(mode), (0, _Host.toValue)(one), (0, _Host.toValue)(two)));
|
43
|
+
}
|
44
|
+
|
45
|
+
MakeColor(color) {
|
46
|
+
return new _JsiSkShader.JsiSkShader(this.CanvasKit, this.CanvasKit.Shader.MakeColor((0, _Host.toValue)(color), this.CanvasKit.ColorSpace.SRGB));
|
47
|
+
}
|
48
|
+
|
49
|
+
}
|
50
|
+
|
51
|
+
exports.JsiSkShaderFactory = JsiSkShaderFactory;
|
52
|
+
//# sourceMappingURL=JsiSkShaderFactory.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkShaderFactory.ts"],"names":["JsiSkShaderFactory","Host","constructor","CanvasKit","MakeLinearGradient","start","end","colors","pos","mode","localMatrix","flags","JsiSkShader","Shader","undefined","MakeRadialGradient","center","radius","MakeTwoPointConicalGradient","startRadius","endRadius","MakeSweepGradient","cx","cy","startAngleInDegrees","endAngleInDegrees","MakeTurbulence","baseFreqX","baseFreqY","octaves","seed","tileW","tileH","MakeFractalNoise","MakeBlend","one","two","MakeColor","color","ColorSpace","SRGB"],"mappings":";;;;;;;AAYA;;AACA;;AAEO,MAAMA,kBAAN,SAAiCC,UAAjC,CAA+D;AACpEC,EAAAA,WAAW,CAACC,SAAD,EAAuB;AAChC,UAAMA,SAAN;AACD;;AAEDC,EAAAA,kBAAkB,CAChBC,KADgB,EAEhBC,GAFgB,EAGhBC,MAHgB,EAIhBC,GAJgB,EAKhBC,IALgB,EAMhBC,WANgB,EAOhBC,KAPgB,EAQhB;AACA,WAAO,IAAIC,wBAAJ,CACL,KAAKT,SADA,EAEL,KAAKA,SAAL,CAAeU,MAAf,CAAsBT,kBAAtB,CACE,mBAAQC,KAAR,CADF,EAEE,mBAAQC,GAAR,CAFF,EAGEC,MAHF,EAIEC,GAJF,EAKE,kBAAOC,IAAP,CALF,EAMEC,WAAW,KAAKI,SAAhB,GAA4BA,SAA5B,GAAwC,mBAAQJ,WAAR,CAN1C,EAOEC,KAPF,CAFK,CAAP;AAYD;;AAEDI,EAAAA,kBAAkB,CAChBC,MADgB,EAEhBC,MAFgB,EAGhBV,MAHgB,EAIhBC,GAJgB,EAKhBC,IALgB,EAMhBC,WANgB,EAOhBC,KAPgB,EAQhB;AACA,WAAO,IAAIC,wBAAJ,CACL,KAAKT,SADA,EAEL,KAAKA,SAAL,CAAeU,MAAf,CAAsBE,kBAAtB,CACE,mBAAQC,MAAR,CADF,EAEEC,MAFF,EAGEV,MAHF,EAIEC,GAJF,EAKE,kBAAOC,IAAP,CALF,EAMEC,WAAW,KAAKI,SAAhB,GAA4BA,SAA5B,GAAwC,mBAAQJ,WAAR,CAN1C,EAOEC,KAPF,CAFK,CAAP;AAYD;;AAEDO,EAAAA,2BAA2B,CACzBb,KADyB,EAEzBc,WAFyB,EAGzBb,GAHyB,EAIzBc,SAJyB,EAKzBb,MALyB,EAMzBC,GANyB,EAOzBC,IAPyB,EAQzBC,WARyB,EASzBC,KATyB,EAUzB;AACA,WAAO,IAAIC,wBAAJ,CACL,KAAKT,SADA,EAEL,KAAKA,SAAL,CAAeU,MAAf,CAAsBK,2BAAtB,CACE,mBAAQb,KAAR,CADF,EAEEc,WAFF,EAGE,mBAAQb,GAAR,CAHF,EAIEc,SAJF,EAKEb,MALF,EAMEC,GANF,EAOE,kBAAOC,IAAP,CAPF,EAQEC,WAAW,KAAKI,SAAhB,GAA4BA,SAA5B,GAAwC,mBAAQJ,WAAR,CAR1C,EASEC,KATF,CAFK,CAAP;AAcD;;AAEDU,EAAAA,iBAAiB,CACfC,EADe,EAEfC,EAFe,EAGfhB,MAHe,EAIfC,GAJe,EAKfC,IALe,EAMfC,WANe,EAOfC,KAPe,EAQfa,mBARe,EASfC,iBATe,EAUf;AACA,WAAO,IAAIb,wBAAJ,CACL,KAAKT,SADA,EAEL,KAAKA,SAAL,CAAeU,MAAf,CAAsBQ,iBAAtB,CACEC,EADF,EAEEC,EAFF,EAGEhB,MAHF,EAIEC,GAJF,EAKE,kBAAOC,IAAP,CALF,EAMEC,WAAW,KAAKI,SAAhB,IAA6BJ,WAAW,KAAK,IAA7C,GACII,SADJ,GAEI,mBAAQJ,WAAR,CARN,EASEC,KATF,EAUEa,mBAVF,EAWEC,iBAXF,CAFK,CAAP;AAgBD;;AAEDC,EAAAA,cAAc,CACZC,SADY,EAEZC,SAFY,EAGZC,OAHY,EAIZC,IAJY,EAKZC,KALY,EAMZC,KANY,EAOZ;AACA,WAAO,IAAIpB,wBAAJ,CACL,KAAKT,SADA,EAEL,KAAKA,SAAL,CAAeU,MAAf,CAAsBa,cAAtB,CACEC,SADF,EAEEC,SAFF,EAGEC,OAHF,EAIEC,IAJF,EAKEC,KALF,EAMEC,KANF,CAFK,CAAP;AAWD;;AAEDC,EAAAA,gBAAgB,CACdN,SADc,EAEdC,SAFc,EAGdC,OAHc,EAIdC,IAJc,EAKdC,KALc,EAMdC,KANc,EAOd;AACA,WAAO,IAAIpB,wBAAJ,CACL,KAAKT,SADA,EAEL,KAAKA,SAAL,CAAeU,MAAf,CAAsBoB,gBAAtB,CACEN,SADF,EAEEC,SAFF,EAGEC,OAHF,EAIEC,IAJF,EAKEC,KALF,EAMEC,KANF,CAFK,CAAP;AAWD;;AAEDE,EAAAA,SAAS,CAACzB,IAAD,EAAkB0B,GAAlB,EAAiCC,GAAjC,EAAgD;AACvD,WAAO,IAAIxB,wBAAJ,CACL,KAAKT,SADA,EAEL,KAAKA,SAAL,CAAeU,MAAf,CAAsBqB,SAAtB,CAAgC,kBAAOzB,IAAP,CAAhC,EAA8C,mBAAQ0B,GAAR,CAA9C,EAA4D,mBAAQC,GAAR,CAA5D,CAFK,CAAP;AAID;;AAEDC,EAAAA,SAAS,CAACC,KAAD,EAAiB;AACxB,WAAO,IAAI1B,wBAAJ,CACL,KAAKT,SADA,EAEL,KAAKA,SAAL,CAAeU,MAAf,CAAsBwB,SAAtB,CACE,mBAAQC,KAAR,CADF,EAEE,KAAKnC,SAAL,CAAeoC,UAAf,CAA0BC,IAF5B,CAFK,CAAP;AAOD;;AApKmE","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type {\n BlendMode,\n SkColor,\n SkMatrix,\n SkPoint,\n SkShader,\n TileMode,\n} from \"../types\";\nimport type { ShaderFactory } from \"../types/Shader/ShaderFactory\";\n\nimport { Host, toValue, ckEnum } from \"./Host\";\nimport { JsiSkShader } from \"./JsiSkShader\";\n\nexport class JsiSkShaderFactory extends Host implements ShaderFactory {\n constructor(CanvasKit: CanvasKit) {\n super(CanvasKit);\n }\n\n MakeLinearGradient(\n start: SkPoint,\n end: SkPoint,\n colors: SkColor[],\n pos: number[] | null,\n mode: TileMode,\n localMatrix?: SkMatrix,\n flags?: number\n ) {\n return new JsiSkShader(\n this.CanvasKit,\n this.CanvasKit.Shader.MakeLinearGradient(\n toValue(start),\n toValue(end),\n colors,\n pos,\n ckEnum(mode),\n localMatrix === undefined ? undefined : toValue(localMatrix),\n flags\n )\n );\n }\n\n MakeRadialGradient(\n center: SkPoint,\n radius: number,\n colors: SkColor[],\n pos: number[] | null,\n mode: TileMode,\n localMatrix?: SkMatrix,\n flags?: number\n ) {\n return new JsiSkShader(\n this.CanvasKit,\n this.CanvasKit.Shader.MakeRadialGradient(\n toValue(center),\n radius,\n colors,\n pos,\n ckEnum(mode),\n localMatrix === undefined ? undefined : toValue(localMatrix),\n flags\n )\n );\n }\n\n MakeTwoPointConicalGradient(\n start: SkPoint,\n startRadius: number,\n end: SkPoint,\n endRadius: number,\n colors: SkColor[],\n pos: number[] | null,\n mode: TileMode,\n localMatrix?: SkMatrix,\n flags?: number\n ) {\n return new JsiSkShader(\n this.CanvasKit,\n this.CanvasKit.Shader.MakeTwoPointConicalGradient(\n toValue(start),\n startRadius,\n toValue(end),\n endRadius,\n colors,\n pos,\n ckEnum(mode),\n localMatrix === undefined ? undefined : toValue(localMatrix),\n flags\n )\n );\n }\n\n MakeSweepGradient(\n cx: number,\n cy: number,\n colors: SkColor[],\n pos: number[] | null,\n mode: TileMode,\n localMatrix?: SkMatrix | null,\n flags?: number,\n startAngleInDegrees?: number,\n endAngleInDegrees?: number\n ) {\n return new JsiSkShader(\n this.CanvasKit,\n this.CanvasKit.Shader.MakeSweepGradient(\n cx,\n cy,\n colors,\n pos,\n ckEnum(mode),\n localMatrix === undefined || localMatrix === null\n ? undefined\n : toValue(localMatrix),\n flags,\n startAngleInDegrees,\n endAngleInDegrees\n )\n );\n }\n\n MakeTurbulence(\n baseFreqX: number,\n baseFreqY: number,\n octaves: number,\n seed: number,\n tileW: number,\n tileH: number\n ) {\n return new JsiSkShader(\n this.CanvasKit,\n this.CanvasKit.Shader.MakeTurbulence(\n baseFreqX,\n baseFreqY,\n octaves,\n seed,\n tileW,\n tileH\n )\n );\n }\n\n MakeFractalNoise(\n baseFreqX: number,\n baseFreqY: number,\n octaves: number,\n seed: number,\n tileW: number,\n tileH: number\n ) {\n return new JsiSkShader(\n this.CanvasKit,\n this.CanvasKit.Shader.MakeFractalNoise(\n baseFreqX,\n baseFreqY,\n octaves,\n seed,\n tileW,\n tileH\n )\n );\n }\n\n MakeBlend(mode: BlendMode, one: SkShader, two: SkShader) {\n return new JsiSkShader(\n this.CanvasKit,\n this.CanvasKit.Shader.MakeBlend(ckEnum(mode), toValue(one), toValue(two))\n );\n }\n\n MakeColor(color: SkColor) {\n return new JsiSkShader(\n this.CanvasKit,\n this.CanvasKit.Shader.MakeColor(\n toValue(color),\n this.CanvasKit.ColorSpace.SRGB\n )\n );\n }\n}\n"]}
|
File without changes
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["JsiSkSurface.ts"],"names":["JsiSkSurface","HostObject","constructor","CanvasKit","ref","getCanvas","JsiSkCanvas","makeImageSnapshot","bounds","image","JsiSkImage"],"mappings":";;;;;;;AAIA;;AACA;;AACA;;AAEO,MAAMA,YAAN,SACGC,gBADH,CAGP;AACEC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAAqC;AAC9C,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,SAAtB;AACD;;AAEDC,EAAAA,SAAS,GAAa;AACpB,WAAO,IAAIC,wBAAJ,CAAgB,KAAKH,SAArB,EAAgC,KAAKC,GAAL,CAASC,SAAT,EAAhC,CAAP;AACD;;AAEDE,EAAAA,iBAAiB,CAACC,MAAD,EAA2B;AAC1C,UAAMC,KAAK,GAAG,KAAKL,GAAL,CAASG,iBAAT,CAA2B,gCAAqBC,MAArB,CAA3B,CAAd;AACA,WAAO,IAAIE,sBAAJ,CAAe,KAAKP,SAApB,EAA+BM,KAA/B,CAAP;AACD;;AAZH","sourcesContent":["import type { CanvasKit, Surface } from \"canvaskit-wasm\";\n\nimport type { SkCanvas, SkImage, SkRect, SkSurface } from \"
|
1
|
+
{"version":3,"sources":["JsiSkSurface.ts"],"names":["JsiSkSurface","HostObject","constructor","CanvasKit","ref","getCanvas","JsiSkCanvas","makeImageSnapshot","bounds","image","JsiSkImage"],"mappings":";;;;;;;AAIA;;AACA;;AACA;;AAEO,MAAMA,YAAN,SACGC,gBADH,CAGP;AACEC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAAqC;AAC9C,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,SAAtB;AACD;;AAEDC,EAAAA,SAAS,GAAa;AACpB,WAAO,IAAIC,wBAAJ,CAAgB,KAAKH,SAArB,EAAgC,KAAKC,GAAL,CAASC,SAAT,EAAhC,CAAP;AACD;;AAEDE,EAAAA,iBAAiB,CAACC,MAAD,EAA2B;AAC1C,UAAMC,KAAK,GAAG,KAAKL,GAAL,CAASG,iBAAT,CAA2B,gCAAqBC,MAArB,CAA3B,CAAd;AACA,WAAO,IAAIE,sBAAJ,CAAe,KAAKP,SAApB,EAA+BM,KAA/B,CAAP;AACD;;AAZH","sourcesContent":["import type { CanvasKit, Surface } from \"canvaskit-wasm\";\n\nimport type { SkCanvas, SkImage, SkRect, SkSurface } from \"../types\";\n\nimport { HostObject, toUndefinedableValue } from \"./Host\";\nimport { JsiSkCanvas } from \"./JsiSkCanvas\";\nimport { JsiSkImage } from \"./JsiSkImage\";\n\nexport class JsiSkSurface\n extends HostObject<Surface, \"Surface\">\n implements SkSurface\n{\n constructor(CanvasKit: CanvasKit, ref: Surface) {\n super(CanvasKit, ref, \"Surface\");\n }\n\n getCanvas(): SkCanvas {\n return new JsiSkCanvas(this.CanvasKit, this.ref.getCanvas());\n }\n\n makeImageSnapshot(bounds?: SkRect): SkImage {\n const image = this.ref.makeImageSnapshot(toUndefinedableValue(bounds));\n return new JsiSkImage(this.CanvasKit, image);\n }\n}\n"]}
|
File without changes
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"sources":["JsiSkSurfaceFactory.ts"],"names":["JsiSkSurfaceFactory","Host","constructor","CanvasKit","Make","width","height","surface","MakeSurface","Error","JsiSkSurface"],"mappings":";;;;;;;AAIA;;AACA;;AAEO,MAAMA,mBAAN,SAAkCC,UAAlC,CAAiE;AACtEC,EAAAA,WAAW,CAACC,SAAD,EAAuB;AAChC,UAAMA,SAAN;AACD;;AAEDC,EAAAA,IAAI,CAACC,KAAD,EAAgBC,MAAhB,EAAgC;AAClC,UAAMC,OAAO,GAAG,KAAKJ,SAAL,CAAeK,WAAf,CAA2BH,KAA3B,EAAkCC,MAAlC,CAAhB;;AACA,QAAI,CAACC,OAAL,EAAc;AACZ,YAAM,IAAIE,KAAJ,CAAU,0BAAV,CAAN;AACD;;AACD,WAAO,IAAIC,0BAAJ,CAAiB,KAAKP,SAAtB,EAAiCI,OAAjC,CAAP;AACD;;AAXqE","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type { SurfaceFactory } from \"
|
1
|
+
{"version":3,"sources":["JsiSkSurfaceFactory.ts"],"names":["JsiSkSurfaceFactory","Host","constructor","CanvasKit","Make","width","height","surface","MakeSurface","Error","JsiSkSurface"],"mappings":";;;;;;;AAIA;;AACA;;AAEO,MAAMA,mBAAN,SAAkCC,UAAlC,CAAiE;AACtEC,EAAAA,WAAW,CAACC,SAAD,EAAuB;AAChC,UAAMA,SAAN;AACD;;AAEDC,EAAAA,IAAI,CAACC,KAAD,EAAgBC,MAAhB,EAAgC;AAClC,UAAMC,OAAO,GAAG,KAAKJ,SAAL,CAAeK,WAAf,CAA2BH,KAA3B,EAAkCC,MAAlC,CAAhB;;AACA,QAAI,CAACC,OAAL,EAAc;AACZ,YAAM,IAAIE,KAAJ,CAAU,0BAAV,CAAN;AACD;;AACD,WAAO,IAAIC,0BAAJ,CAAiB,KAAKP,SAAtB,EAAiCI,OAAjC,CAAP;AACD;;AAXqE","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type { SurfaceFactory } from \"../types\";\n\nimport { Host } from \"./Host\";\nimport { JsiSkSurface } from \"./JsiSkSurface\";\n\nexport class JsiSkSurfaceFactory extends Host implements SurfaceFactory {\n constructor(CanvasKit: CanvasKit) {\n super(CanvasKit);\n }\n\n Make(width: number, height: number) {\n const surface = this.CanvasKit.MakeSurface(width, height);\n if (!surface) {\n throw new Error(\"Could not create surface\");\n }\n return new JsiSkSurface(this.CanvasKit, surface);\n }\n}\n"]}
|
@@ -0,0 +1,18 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkTextBlob = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
class JsiSkTextBlob extends _Host.HostObject {
|
11
|
+
constructor(CanvasKit, ref) {
|
12
|
+
super(CanvasKit, ref, "TextBlob");
|
13
|
+
}
|
14
|
+
|
15
|
+
}
|
16
|
+
|
17
|
+
exports.JsiSkTextBlob = JsiSkTextBlob;
|
18
|
+
//# sourceMappingURL=JsiSkTextBlob.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkTextBlob.ts"],"names":["JsiSkTextBlob","HostObject","constructor","CanvasKit","ref"],"mappings":";;;;;;;AAIA;;AAEO,MAAMA,aAAN,SACGC,gBADH,CAGP;AACEC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAAsC;AAC/C,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,UAAtB;AACD;;AAHH","sourcesContent":["import type { CanvasKit, TextBlob } from \"canvaskit-wasm\";\n\nimport type { SkTextBlob } from \"../types\";\n\nimport { HostObject } from \"./Host\";\n\nexport class JsiSkTextBlob\n extends HostObject<TextBlob, \"TextBlob\">\n implements SkTextBlob\n{\n constructor(CanvasKit: CanvasKit, ref: TextBlob) {\n super(CanvasKit, ref, \"TextBlob\");\n }\n}\n"]}
|
@@ -0,0 +1,36 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkTextBlobFactory = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
var _JsiSkTextBlob = require("./JsiSkTextBlob");
|
11
|
+
|
12
|
+
class JsiSkTextBlobFactory extends _Host.Host {
|
13
|
+
constructor(CanvasKit) {
|
14
|
+
super(CanvasKit);
|
15
|
+
}
|
16
|
+
|
17
|
+
MakeFromText(str, font) {
|
18
|
+
return new _JsiSkTextBlob.JsiSkTextBlob(this.CanvasKit, this.CanvasKit.TextBlob.MakeFromText(str, (0, _Host.toValue)(font)));
|
19
|
+
}
|
20
|
+
|
21
|
+
MakeFromGlyphs(glyphs, font) {
|
22
|
+
return new _JsiSkTextBlob.JsiSkTextBlob(this.CanvasKit, this.CanvasKit.TextBlob.MakeFromGlyphs(glyphs, (0, _Host.toValue)(font)));
|
23
|
+
}
|
24
|
+
|
25
|
+
MakeFromRSXform(str, rsxforms, font) {
|
26
|
+
return new _JsiSkTextBlob.JsiSkTextBlob(this.CanvasKit, this.CanvasKit.TextBlob.MakeFromRSXform(str, rsxforms.map(f => (0, _Host.toValue)(f)), (0, _Host.toValue)(font)));
|
27
|
+
}
|
28
|
+
|
29
|
+
MakeFromRSXformGlyphs(glyphs, rsxforms, font) {
|
30
|
+
return new _JsiSkTextBlob.JsiSkTextBlob(this.CanvasKit, this.CanvasKit.TextBlob.MakeFromRSXformGlyphs(glyphs, rsxforms.map(f => (0, _Host.toValue)(f)), (0, _Host.toValue)(font)));
|
31
|
+
}
|
32
|
+
|
33
|
+
}
|
34
|
+
|
35
|
+
exports.JsiSkTextBlobFactory = JsiSkTextBlobFactory;
|
36
|
+
//# sourceMappingURL=JsiSkTextBlobFactory.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkTextBlobFactory.ts"],"names":["JsiSkTextBlobFactory","Host","constructor","CanvasKit","MakeFromText","str","font","JsiSkTextBlob","TextBlob","MakeFromGlyphs","glyphs","MakeFromRSXform","rsxforms","map","f","MakeFromRSXformGlyphs"],"mappings":";;;;;;;AAKA;;AACA;;AAEO,MAAMA,oBAAN,SAAmCC,UAAnC,CAAmE;AACxEC,EAAAA,WAAW,CAACC,SAAD,EAAuB;AAChC,UAAMA,SAAN;AACD;;AAEDC,EAAAA,YAAY,CAACC,GAAD,EAAcC,IAAd,EAA4B;AACtC,WAAO,IAAIC,4BAAJ,CACL,KAAKJ,SADA,EAEL,KAAKA,SAAL,CAAeK,QAAf,CAAwBJ,YAAxB,CAAqCC,GAArC,EAA0C,mBAAQC,IAAR,CAA1C,CAFK,CAAP;AAID;;AAEDG,EAAAA,cAAc,CAACC,MAAD,EAAmBJ,IAAnB,EAAiC;AAC7C,WAAO,IAAIC,4BAAJ,CACL,KAAKJ,SADA,EAEL,KAAKA,SAAL,CAAeK,QAAf,CAAwBC,cAAxB,CAAuCC,MAAvC,EAA+C,mBAAQJ,IAAR,CAA/C,CAFK,CAAP;AAID;;AAEDK,EAAAA,eAAe,CAACN,GAAD,EAAcO,QAAd,EAAqCN,IAArC,EAAmD;AAChE,WAAO,IAAIC,4BAAJ,CACL,KAAKJ,SADA,EAEL,KAAKA,SAAL,CAAeK,QAAf,CAAwBG,eAAxB,CACEN,GADF,EAEEO,QAAQ,CAACC,GAAT,CAAcC,CAAD,IAAO,mBAAQA,CAAR,CAApB,CAFF,EAGE,mBAAQR,IAAR,CAHF,CAFK,CAAP;AAQD;;AAEDS,EAAAA,qBAAqB,CAACL,MAAD,EAAmBE,QAAnB,EAA0CN,IAA1C,EAAwD;AAC3E,WAAO,IAAIC,4BAAJ,CACL,KAAKJ,SADA,EAEL,KAAKA,SAAL,CAAeK,QAAf,CAAwBO,qBAAxB,CACEL,MADF,EAEEE,QAAQ,CAACC,GAAT,CAAcC,CAAD,IAAO,mBAAQA,CAAR,CAApB,CAFF,EAGE,mBAAQR,IAAR,CAHF,CAFK,CAAP;AAQD;;AAvCuE","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type { SkFont, SkRSXform } from \"../types\";\nimport type { TextBlobFactory } from \"../types/TextBlob\";\n\nimport { Host, toValue } from \"./Host\";\nimport { JsiSkTextBlob } from \"./JsiSkTextBlob\";\n\nexport class JsiSkTextBlobFactory extends Host implements TextBlobFactory {\n constructor(CanvasKit: CanvasKit) {\n super(CanvasKit);\n }\n\n MakeFromText(str: string, font: SkFont) {\n return new JsiSkTextBlob(\n this.CanvasKit,\n this.CanvasKit.TextBlob.MakeFromText(str, toValue(font))\n );\n }\n\n MakeFromGlyphs(glyphs: number[], font: SkFont) {\n return new JsiSkTextBlob(\n this.CanvasKit,\n this.CanvasKit.TextBlob.MakeFromGlyphs(glyphs, toValue(font))\n );\n }\n\n MakeFromRSXform(str: string, rsxforms: SkRSXform[], font: SkFont) {\n return new JsiSkTextBlob(\n this.CanvasKit,\n this.CanvasKit.TextBlob.MakeFromRSXform(\n str,\n rsxforms.map((f) => toValue(f)),\n toValue(font)\n )\n );\n }\n\n MakeFromRSXformGlyphs(glyphs: number[], rsxforms: SkRSXform[], font: SkFont) {\n return new JsiSkTextBlob(\n this.CanvasKit,\n this.CanvasKit.TextBlob.MakeFromRSXformGlyphs(\n glyphs,\n rsxforms.map((f) => toValue(f)),\n toValue(font)\n )\n );\n }\n}\n"]}
|
@@ -0,0 +1,28 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkTypeface = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
class JsiSkTypeface extends _Host.HostObject {
|
11
|
+
constructor(CanvasKit, ref) {
|
12
|
+
super(CanvasKit, ref, "Typeface");
|
13
|
+
}
|
14
|
+
|
15
|
+
get bold() {
|
16
|
+
console.warn("Typeface.bold is deprecated and will be removed in a future release. The property will return false.");
|
17
|
+
return false;
|
18
|
+
}
|
19
|
+
|
20
|
+
get italic() {
|
21
|
+
console.warn("Typeface.italic is deprecated and will be removed in a future release. The property will return false.");
|
22
|
+
return false;
|
23
|
+
}
|
24
|
+
|
25
|
+
}
|
26
|
+
|
27
|
+
exports.JsiSkTypeface = JsiSkTypeface;
|
28
|
+
//# sourceMappingURL=JsiSkTypeface.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkTypeface.ts"],"names":["JsiSkTypeface","HostObject","constructor","CanvasKit","ref","bold","console","warn","italic"],"mappings":";;;;;;;AAIA;;AAEO,MAAMA,aAAN,SACGC,gBADH,CAGP;AACEC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAAsC;AAC/C,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,UAAtB;AACD;;AAEO,MAAJC,IAAI,GAAY;AAClBC,IAAAA,OAAO,CAACC,IAAR,CACE,sGADF;AAGA,WAAO,KAAP;AACD;;AAES,MAANC,MAAM,GAAY;AACpBF,IAAAA,OAAO,CAACC,IAAR,CACE,wGADF;AAGA,WAAO,KAAP;AACD;;AAjBH","sourcesContent":["import type { CanvasKit, Typeface } from \"canvaskit-wasm\";\n\nimport type { SkTypeface } from \"../types\";\n\nimport { HostObject } from \"./Host\";\n\nexport class JsiSkTypeface\n extends HostObject<Typeface, \"Typeface\">\n implements SkTypeface\n{\n constructor(CanvasKit: CanvasKit, ref: Typeface) {\n super(CanvasKit, ref, \"Typeface\");\n }\n\n get bold(): boolean {\n console.warn(\n \"Typeface.bold is deprecated and will be removed in a future release. The property will return false.\"\n );\n return false;\n }\n\n get italic(): boolean {\n console.warn(\n \"Typeface.italic is deprecated and will be removed in a future release. The property will return false.\"\n );\n return false;\n }\n}\n"]}
|
@@ -0,0 +1,30 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkTypefaceFactory = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
var _JsiSkTypeface = require("./JsiSkTypeface");
|
11
|
+
|
12
|
+
class JsiSkTypefaceFactory extends _Host.Host {
|
13
|
+
constructor(CanvasKit) {
|
14
|
+
super(CanvasKit);
|
15
|
+
}
|
16
|
+
|
17
|
+
MakeFreeTypeFaceFromData(data) {
|
18
|
+
const tf = this.CanvasKit.Typeface.MakeFreeTypeFaceFromData((0, _Host.toValue)(data));
|
19
|
+
|
20
|
+
if (tf === null) {
|
21
|
+
return null;
|
22
|
+
}
|
23
|
+
|
24
|
+
return new _JsiSkTypeface.JsiSkTypeface(this.CanvasKit, tf);
|
25
|
+
}
|
26
|
+
|
27
|
+
}
|
28
|
+
|
29
|
+
exports.JsiSkTypefaceFactory = JsiSkTypefaceFactory;
|
30
|
+
//# sourceMappingURL=JsiSkTypefaceFactory.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkTypefaceFactory.tsx"],"names":["JsiSkTypefaceFactory","Host","constructor","CanvasKit","MakeFreeTypeFaceFromData","data","tf","Typeface","JsiSkTypeface"],"mappings":";;;;;;;AAIA;;AACA;;AAEO,MAAMA,oBAAN,SAAmCC,UAAnC,CAAmE;AACxEC,EAAAA,WAAW,CAACC,SAAD,EAAuB;AAChC,UAAMA,SAAN;AACD;;AAEDC,EAAAA,wBAAwB,CAACC,IAAD,EAAe;AACrC,UAAMC,EAAE,GAAG,KAAKH,SAAL,CAAeI,QAAf,CAAwBH,wBAAxB,CAAiD,mBAAQC,IAAR,CAAjD,CAAX;;AACA,QAAIC,EAAE,KAAK,IAAX,EAAiB;AACf,aAAO,IAAP;AACD;;AACD,WAAO,IAAIE,4BAAJ,CAAkB,KAAKL,SAAvB,EAAkCG,EAAlC,CAAP;AACD;;AAXuE","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type { SkData, TypefaceFactory } from \"../types\";\n\nimport { Host, toValue } from \"./Host\";\nimport { JsiSkTypeface } from \"./JsiSkTypeface\";\n\nexport class JsiSkTypefaceFactory extends Host implements TypefaceFactory {\n constructor(CanvasKit: CanvasKit) {\n super(CanvasKit);\n }\n\n MakeFreeTypeFaceFromData(data: SkData) {\n const tf = this.CanvasKit.Typeface.MakeFreeTypeFaceFromData(toValue(data));\n if (tf === null) {\n return null;\n }\n return new JsiSkTypeface(this.CanvasKit, tf);\n }\n}\n"]}
|
@@ -0,0 +1,28 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.JsiSkVertices = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
var _JsiSkRect = require("./JsiSkRect");
|
11
|
+
|
12
|
+
class JsiSkVertices extends _Host.HostObject {
|
13
|
+
constructor(CanvasKit, ref) {
|
14
|
+
super(CanvasKit, ref, "Vertices");
|
15
|
+
}
|
16
|
+
|
17
|
+
bounds() {
|
18
|
+
return new _JsiSkRect.JsiSkRect(this.CanvasKit, this.ref.bounds());
|
19
|
+
}
|
20
|
+
|
21
|
+
uniqueID() {
|
22
|
+
return this.ref.uniqueID();
|
23
|
+
}
|
24
|
+
|
25
|
+
}
|
26
|
+
|
27
|
+
exports.JsiSkVertices = JsiSkVertices;
|
28
|
+
//# sourceMappingURL=JsiSkVertices.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkVertices.ts"],"names":["JsiSkVertices","HostObject","constructor","CanvasKit","ref","bounds","JsiSkRect","uniqueID"],"mappings":";;;;;;;AAIA;;AACA;;AAEO,MAAMA,aAAN,SACGC,gBADH,CAGP;AACEC,EAAAA,WAAW,CAACC,SAAD,EAAuBC,GAAvB,EAAsC;AAC/C,UAAMD,SAAN,EAAiBC,GAAjB,EAAsB,UAAtB;AACD;;AAEDC,EAAAA,MAAM,GAAG;AACP,WAAO,IAAIC,oBAAJ,CAAc,KAAKH,SAAnB,EAA8B,KAAKC,GAAL,CAASC,MAAT,EAA9B,CAAP;AACD;;AAEDE,EAAAA,QAAQ,GAAG;AACT,WAAO,KAAKH,GAAL,CAASG,QAAT,EAAP;AACD;;AAXH","sourcesContent":["import type { CanvasKit, Vertices } from \"canvaskit-wasm\";\n\nimport type { SkVertices } from \"../types\";\n\nimport { HostObject } from \"./Host\";\nimport { JsiSkRect } from \"./JsiSkRect\";\n\nexport class JsiSkVertices\n extends HostObject<Vertices, \"Vertices\">\n implements SkVertices\n{\n constructor(CanvasKit: CanvasKit, ref: Vertices) {\n super(CanvasKit, ref, \"Vertices\");\n }\n\n bounds() {\n return new JsiSkRect(this.CanvasKit, this.ref.bounds());\n }\n\n uniqueID() {\n return this.ref.uniqueID();\n }\n}\n"]}
|
@@ -0,0 +1,49 @@
|
|
1
|
+
"use strict";
|
2
|
+
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
4
|
+
value: true
|
5
|
+
});
|
6
|
+
exports.MakeVertices = void 0;
|
7
|
+
|
8
|
+
var _Host = require("./Host");
|
9
|
+
|
10
|
+
var _JsiSkVertices = require("./JsiSkVertices");
|
11
|
+
|
12
|
+
const concat = function () {
|
13
|
+
let totalLength = 0;
|
14
|
+
|
15
|
+
for (var _len = arguments.length, arrays = new Array(_len), _key = 0; _key < _len; _key++) {
|
16
|
+
arrays[_key] = arguments[_key];
|
17
|
+
}
|
18
|
+
|
19
|
+
for (const arr of arrays) {
|
20
|
+
totalLength += arr.length;
|
21
|
+
}
|
22
|
+
|
23
|
+
const result = new Float32Array(totalLength);
|
24
|
+
let offset = 0;
|
25
|
+
|
26
|
+
for (const arr of arrays) {
|
27
|
+
result.set(arr, offset);
|
28
|
+
offset += arr.length;
|
29
|
+
}
|
30
|
+
|
31
|
+
return result;
|
32
|
+
};
|
33
|
+
|
34
|
+
const MakeVertices = (CanvasKit, mode, positions, textureCoordinates, colors, indices, isVolatile) => new _JsiSkVertices.JsiSkVertices(CanvasKit, CanvasKit.MakeVertices((0, _Host.ckEnum)(mode), positions.map(_ref => {
|
35
|
+
let {
|
36
|
+
x,
|
37
|
+
y
|
38
|
+
} = _ref;
|
39
|
+
return [x, y];
|
40
|
+
}).flat(), (textureCoordinates || []).map(_ref2 => {
|
41
|
+
let {
|
42
|
+
x,
|
43
|
+
y
|
44
|
+
} = _ref2;
|
45
|
+
return [x, y];
|
46
|
+
}).flat(), !colors ? null : colors.reduce((a, c) => concat(a, c)), indices, isVolatile));
|
47
|
+
|
48
|
+
exports.MakeVertices = MakeVertices;
|
49
|
+
//# sourceMappingURL=JsiSkVerticesFactory.js.map
|
@@ -0,0 +1 @@
|
|
1
|
+
{"version":3,"sources":["JsiSkVerticesFactory.ts"],"names":["concat","totalLength","arrays","arr","length","result","Float32Array","offset","set","MakeVertices","CanvasKit","mode","positions","textureCoordinates","colors","indices","isVolatile","JsiSkVertices","map","x","y","flat","reduce","a","c"],"mappings":";;;;;;;AAIA;;AACA;;AAEA,MAAMA,MAAM,GAAG,YAA+B;AAC5C,MAAIC,WAAW,GAAG,CAAlB;;AAD4C,oCAA3BC,MAA2B;AAA3BA,IAAAA,MAA2B;AAAA;;AAE5C,OAAK,MAAMC,GAAX,IAAkBD,MAAlB,EAA0B;AACxBD,IAAAA,WAAW,IAAIE,GAAG,CAACC,MAAnB;AACD;;AACD,QAAMC,MAAM,GAAG,IAAIC,YAAJ,CAAiBL,WAAjB,CAAf;AACA,MAAIM,MAAM,GAAG,CAAb;;AACA,OAAK,MAAMJ,GAAX,IAAkBD,MAAlB,EAA0B;AACxBG,IAAAA,MAAM,CAACG,GAAP,CAAWL,GAAX,EAAgBI,MAAhB;AACAA,IAAAA,MAAM,IAAIJ,GAAG,CAACC,MAAd;AACD;;AACD,SAAOC,MAAP;AACD,CAZD;;AAcO,MAAMI,YAAY,GAAG,CAC1BC,SAD0B,EAE1BC,IAF0B,EAG1BC,SAH0B,EAI1BC,kBAJ0B,EAK1BC,MAL0B,EAM1BC,OAN0B,EAO1BC,UAP0B,KAS1B,IAAIC,4BAAJ,CACEP,SADF,EAEEA,SAAS,CAACD,YAAV,CACE,kBAAOE,IAAP,CADF,EAEEC,SAAS,CAACM,GAAV,CAAc;AAAA,MAAC;AAAEC,IAAAA,CAAF;AAAKC,IAAAA;AAAL,GAAD;AAAA,SAAc,CAACD,CAAD,EAAIC,CAAJ,CAAd;AAAA,CAAd,EAAoCC,IAApC,EAFF,EAGE,CAACR,kBAAkB,IAAI,EAAvB,EAA2BK,GAA3B,CAA+B;AAAA,MAAC;AAAEC,IAAAA,CAAF;AAAKC,IAAAA;AAAL,GAAD;AAAA,SAAc,CAACD,CAAD,EAAIC,CAAJ,CAAd;AAAA,CAA/B,EAAqDC,IAArD,EAHF,EAIE,CAACP,MAAD,GAAU,IAAV,GAAiBA,MAAM,CAACQ,MAAP,CAAc,CAACC,CAAD,EAAIC,CAAJ,KAAUxB,MAAM,CAACuB,CAAD,EAAIC,CAAJ,CAA9B,CAJnB,EAKET,OALF,EAMEC,UANF,CAFF,CATK","sourcesContent":["import type { CanvasKit } from \"canvaskit-wasm\";\n\nimport type { SkColor, SkPoint, VertexMode } from \"../types\";\n\nimport { ckEnum } from \"./Host\";\nimport { JsiSkVertices } from \"./JsiSkVertices\";\n\nconst concat = (...arrays: Float32Array[]) => {\n let totalLength = 0;\n for (const arr of arrays) {\n totalLength += arr.length;\n }\n const result = new Float32Array(totalLength);\n let offset = 0;\n for (const arr of arrays) {\n result.set(arr, offset);\n offset += arr.length;\n }\n return result;\n};\n\nexport const MakeVertices = (\n CanvasKit: CanvasKit,\n mode: VertexMode,\n positions: SkPoint[],\n textureCoordinates?: SkPoint[] | null,\n colors?: SkColor[],\n indices?: number[] | null,\n isVolatile?: boolean\n) =>\n new JsiSkVertices(\n CanvasKit,\n CanvasKit.MakeVertices(\n ckEnum(mode),\n positions.map(({ x, y }) => [x, y]).flat(),\n (textureCoordinates || []).map(({ x, y }) => [x, y]).flat(),\n !colors ? null : colors.reduce((a, c) => concat(a, c)),\n indices,\n isVolatile\n )\n );\n"]}
|