@shopify/react-native-skia 0.1.170 → 0.1.172
Sign up to get free protection for your applications and to get access to all the features.
- package/android/CMakeLists.txt +62 -34
- package/android/build.gradle +20 -10
- package/cpp/rnskia/RNSkJsiViewApi.h +2 -2
- package/cpp/rnskia/dom/nodes/JsiCustomDrawingNode.h +8 -1
- package/ios/RNSkia-iOS/RNSkMetalCanvasProvider.mm +5 -1
- package/lib/commonjs/animation/decay/decay.d.ts +2 -0
- package/lib/commonjs/animation/decay/index.d.ts +1 -0
- package/lib/commonjs/animation/decay/runDecay.d.ts +10 -0
- package/lib/commonjs/animation/decay/types.d.ts +21 -0
- package/lib/commonjs/animation/functions/index.d.ts +4 -0
- package/lib/commonjs/animation/functions/interpolate.d.ts +17 -0
- package/lib/commonjs/animation/functions/interpolateColors.d.ts +3 -0
- package/lib/commonjs/animation/functions/interpolatePaths.d.ts +19 -0
- package/lib/commonjs/animation/functions/interpolateVector.d.ts +10 -0
- package/lib/commonjs/animation/index.d.ts +4 -0
- package/lib/commonjs/animation/spring/Spring.d.ts +65 -0
- package/lib/commonjs/animation/spring/functions/index.d.ts +1 -0
- package/lib/commonjs/animation/spring/functions/spring.d.ts +10 -0
- package/lib/commonjs/animation/spring/index.d.ts +3 -0
- package/lib/commonjs/animation/spring/runSpring.d.ts +16 -0
- package/lib/commonjs/animation/spring/types.d.ts +6 -0
- package/lib/commonjs/animation/spring/useSpring.d.ts +10 -0
- package/lib/commonjs/animation/timing/Easing.d.ts +19 -0
- package/lib/commonjs/animation/timing/createTiming.d.ts +17 -0
- package/lib/commonjs/animation/timing/functions/bezier.d.ts +1 -0
- package/lib/commonjs/animation/timing/functions/getResolvedParams.d.ts +7 -0
- package/lib/commonjs/animation/timing/functions/index.d.ts +4 -0
- package/lib/commonjs/animation/timing/functions/timing.d.ts +17 -0
- package/lib/commonjs/animation/timing/functions/types.d.ts +7 -0
- package/lib/commonjs/animation/timing/index.d.ts +4 -0
- package/lib/commonjs/animation/timing/runTiming.d.ts +16 -0
- package/lib/commonjs/animation/timing/useLoop.d.ts +8 -0
- package/lib/commonjs/animation/timing/useTiming.d.ts +10 -0
- package/lib/commonjs/animation/types.d.ts +18 -0
- package/lib/commonjs/dom/nodes/DrawingNode.d.ts +14 -0
- package/lib/commonjs/dom/nodes/GroupNode.d.ts +7 -0
- package/lib/commonjs/dom/nodes/JsiSkDOM.d.ts +65 -0
- package/lib/commonjs/dom/nodes/LayerNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/Node.d.ts +43 -0
- package/lib/commonjs/dom/nodes/PaintContext.d.ts +18 -0
- package/lib/commonjs/dom/nodes/PaintNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/RenderNode.d.ts +27 -0
- package/lib/commonjs/dom/nodes/datatypes/Circle.d.ts +7 -0
- package/lib/commonjs/dom/nodes/datatypes/Enum.d.ts +1 -0
- package/lib/commonjs/dom/nodes/datatypes/Fitting.d.ts +33 -0
- package/lib/commonjs/dom/nodes/datatypes/Gradient.d.ts +92 -0
- package/lib/commonjs/dom/nodes/datatypes/Path.d.ts +4 -0
- package/lib/commonjs/dom/nodes/datatypes/Radius.d.ts +3 -0
- package/lib/commonjs/dom/nodes/datatypes/Rect.d.ts +5 -0
- package/lib/commonjs/dom/nodes/datatypes/Transform.d.ts +3 -0
- package/lib/commonjs/dom/nodes/datatypes/index.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/BackdropFilterNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/Box.d.ts +13 -0
- package/lib/commonjs/dom/nodes/drawings/CircleNode.d.ts +9 -0
- package/lib/commonjs/dom/nodes/drawings/CustomDrawingNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/DiffRectNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/FillNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/ImageNode.d.ts +25 -0
- package/lib/commonjs/dom/nodes/drawings/ImageSVG.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/LineNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/OvalNode.d.ts +9 -0
- package/lib/commonjs/dom/nodes/drawings/PatchNode.d.ts +18 -0
- package/lib/commonjs/dom/nodes/drawings/PathNode.d.ts +9 -0
- package/lib/commonjs/dom/nodes/drawings/PictureNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/PointsNode.d.ts +8 -0
- package/lib/commonjs/dom/nodes/drawings/RRectNode.d.ts +10 -0
- package/lib/commonjs/dom/nodes/drawings/RectNode.d.ts +9 -0
- package/lib/commonjs/dom/nodes/drawings/Text.d.ts +30 -0
- package/lib/commonjs/dom/nodes/drawings/VerticesNode.d.ts +9 -0
- package/lib/commonjs/dom/nodes/drawings/index.d.ts +18 -0
- package/lib/commonjs/dom/nodes/index.d.ts +3 -0
- package/lib/commonjs/dom/nodes/paint/BlendNode.d.ts +12 -0
- package/lib/commonjs/dom/nodes/paint/ColorFilters.d.ts +36 -0
- package/lib/commonjs/dom/nodes/paint/ImageFilters.d.ts +42 -0
- package/lib/commonjs/dom/nodes/paint/MaskFilters.d.ts +8 -0
- package/lib/commonjs/dom/nodes/paint/PathEffects.d.ts +42 -0
- package/lib/commonjs/dom/nodes/paint/Shaders.d.ts +44 -0
- package/lib/commonjs/dom/nodes/paint/index.d.ts +6 -0
- package/lib/commonjs/dom/types/ColorFilters.d.ts +12 -0
- package/lib/commonjs/dom/types/Common.d.ts +56 -0
- package/lib/commonjs/dom/types/DrawingContext.d.ts +5 -0
- package/lib/commonjs/dom/types/Drawings.d.ts +104 -0
- package/lib/commonjs/dom/types/ImageFilters.d.ts +37 -0
- package/lib/commonjs/dom/types/MaskFilters.d.ts +7 -0
- package/lib/commonjs/dom/types/Node.d.ts +29 -0
- package/lib/commonjs/dom/types/NodeType.d.ts +67 -0
- package/lib/commonjs/dom/types/PathEffects.d.ts +28 -0
- package/lib/commonjs/dom/types/Shaders.d.ts +59 -0
- package/lib/commonjs/dom/types/SkDOM.d.ts +72 -0
- package/lib/commonjs/dom/types/index.d.ts +11 -0
- package/lib/commonjs/external/index.d.ts +1 -0
- package/lib/commonjs/external/reanimated/index.d.ts +1 -0
- package/lib/commonjs/external/reanimated/useSharedValueEffect.d.ts +11 -0
- package/lib/commonjs/index.d.ts +10 -0
- package/lib/commonjs/mock/index.d.ts +16 -0
- package/lib/commonjs/renderer/Canvas.d.ts +11 -0
- package/lib/commonjs/renderer/Container.d.ts +12 -0
- package/lib/commonjs/renderer/DependencyManager.d.ts +46 -0
- package/lib/commonjs/renderer/DrawingContext.d.ts +6 -0
- package/lib/commonjs/renderer/HostComponents.d.ts +132 -0
- package/lib/commonjs/renderer/HostConfig.d.ts +19 -0
- package/lib/commonjs/renderer/Reconciler.d.ts +13 -0
- package/lib/commonjs/renderer/components/Blend.d.ts +4 -0
- package/lib/commonjs/renderer/components/Drawing.d.ts +3 -0
- package/lib/commonjs/renderer/components/Group.d.ts +8 -0
- package/lib/commonjs/renderer/components/Mask.d.ts +9 -0
- package/lib/commonjs/renderer/components/Paint.d.ts +4 -0
- package/lib/commonjs/renderer/components/Picture.d.ts +4 -0
- package/lib/commonjs/renderer/components/backdrop/BackdropBlur.d.ts +9 -0
- package/lib/commonjs/renderer/components/backdrop/BackdropFilter.d.ts +7 -0
- package/lib/commonjs/renderer/components/backdrop/index.d.ts +2 -0
- package/lib/commonjs/renderer/components/colorFilters/BlendColor.d.ts +4 -0
- package/lib/commonjs/renderer/components/colorFilters/Lerp.d.ts +4 -0
- package/lib/commonjs/renderer/components/colorFilters/LinearToSRGBGamma.d.ts +4 -0
- package/lib/commonjs/renderer/components/colorFilters/LumaColorFilter.d.ts +4 -0
- package/lib/commonjs/renderer/components/colorFilters/Matrix.d.ts +5 -0
- package/lib/commonjs/renderer/components/colorFilters/SRGBToLinearGamma.d.ts +4 -0
- package/lib/commonjs/renderer/components/colorFilters/index.d.ts +6 -0
- package/lib/commonjs/renderer/components/image/Image.d.ts +4 -0
- package/lib/commonjs/renderer/components/image/ImageSVG.d.ts +4 -0
- package/lib/commonjs/renderer/components/image/ImageShader.d.ts +4 -0
- package/lib/commonjs/renderer/components/image/index.d.ts +3 -0
- package/lib/commonjs/renderer/components/imageFilters/Blur.d.ts +4 -0
- package/lib/commonjs/renderer/components/imageFilters/DisplacementMap.d.ts +4 -0
- package/lib/commonjs/renderer/components/imageFilters/Morphology.d.ts +4 -0
- package/lib/commonjs/renderer/components/imageFilters/Offset.d.ts +4 -0
- package/lib/commonjs/renderer/components/imageFilters/RuntimeShader.d.ts +4 -0
- package/lib/commonjs/renderer/components/imageFilters/Shadow.d.ts +4 -0
- package/lib/commonjs/renderer/components/imageFilters/index.d.ts +6 -0
- package/lib/commonjs/renderer/components/index.d.ts +16 -0
- package/lib/commonjs/renderer/components/maskFilters/Blur.d.ts +4 -0
- package/lib/commonjs/renderer/components/maskFilters/index.d.ts +1 -0
- package/lib/commonjs/renderer/components/pathEffects/Corner.d.ts +4 -0
- package/lib/commonjs/renderer/components/pathEffects/Dash.d.ts +4 -0
- package/lib/commonjs/renderer/components/pathEffects/Discrete.d.ts +4 -0
- package/lib/commonjs/renderer/components/pathEffects/Line2D.d.ts +4 -0
- package/lib/commonjs/renderer/components/pathEffects/Path1D.d.ts +4 -0
- package/lib/commonjs/renderer/components/pathEffects/Path2D.d.ts +4 -0
- package/lib/commonjs/renderer/components/pathEffects/Sum.d.ts +3 -0
- package/lib/commonjs/renderer/components/pathEffects/index.d.ts +7 -0
- package/lib/commonjs/renderer/components/shaders/Color.d.ts +4 -0
- package/lib/commonjs/renderer/components/shaders/FractalNoise.d.ts +4 -0
- package/lib/commonjs/renderer/components/shaders/LinearGradient.d.ts +4 -0
- package/lib/commonjs/renderer/components/shaders/RadialGradient.d.ts +4 -0
- package/lib/commonjs/renderer/components/shaders/Shader.d.ts +4 -0
- package/lib/commonjs/renderer/components/shaders/ShaderLib.d.ts +4 -0
- package/lib/commonjs/renderer/components/shaders/SweepGradient.d.ts +4 -0
- package/lib/commonjs/renderer/components/shaders/Turbulence.d.ts +4 -0
- package/lib/commonjs/renderer/components/shaders/TwoPointConicalGradient.d.ts +4 -0
- package/lib/commonjs/renderer/components/shaders/index.d.ts +9 -0
- package/lib/commonjs/renderer/components/shapes/Box.d.ts +5 -0
- package/lib/commonjs/renderer/components/shapes/Circle.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/DiffRect.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/Fill.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/FitBox.d.ts +20 -0
- package/lib/commonjs/renderer/components/shapes/Line.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/Oval.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/Patch.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/Path.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/Points.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/Rect.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/RoundedRect.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/Vertices.d.ts +4 -0
- package/lib/commonjs/renderer/components/shapes/index.d.ts +13 -0
- package/lib/commonjs/renderer/components/text/Glyphs.d.ts +4 -0
- package/lib/commonjs/renderer/components/text/Text.d.ts +4 -0
- package/lib/commonjs/renderer/components/text/TextBlob.d.ts +4 -0
- package/lib/commonjs/renderer/components/text/TextPath.d.ts +4 -0
- package/lib/commonjs/renderer/components/text/index.d.ts +4 -0
- package/lib/commonjs/renderer/index.d.ts +2 -0
- package/lib/commonjs/renderer/index.js +0 -13
- package/lib/commonjs/renderer/index.js.map +1 -1
- package/lib/commonjs/renderer/processors/Animations/Animations.d.ts +17 -0
- package/lib/commonjs/renderer/processors/Animations/index.d.ts +1 -0
- package/lib/commonjs/renderer/processors/index.d.ts +2 -0
- package/lib/commonjs/renderer/processors/math/Coordinates.d.ts +29 -0
- package/lib/commonjs/renderer/processors/math/Math.d.ts +15 -0
- package/lib/commonjs/renderer/processors/math/Transforms.d.ts +5 -0
- package/lib/commonjs/renderer/processors/math/index.d.ts +3 -0
- package/lib/commonjs/renderer/typeddash.d.ts +3 -0
- package/lib/commonjs/skia/NativeSetup.d.ts +1 -0
- package/lib/commonjs/skia/Skia.d.ts +8 -0
- package/lib/commonjs/skia/Skia.web.d.ts +1 -0
- package/lib/commonjs/skia/core/Data.d.ts +3 -0
- package/lib/commonjs/skia/core/Font.d.ts +5 -0
- package/lib/commonjs/skia/core/Image.d.ts +5 -0
- package/lib/commonjs/skia/core/Matrix.d.ts +2 -0
- package/lib/commonjs/skia/core/Picture.d.ts +8 -0
- package/lib/commonjs/skia/core/RRect.d.ts +2 -0
- package/lib/commonjs/skia/core/Rect.d.ts +8 -0
- package/lib/commonjs/skia/core/SVG.d.ts +2 -0
- package/lib/commonjs/skia/core/Typeface.d.ts +5 -0
- package/lib/commonjs/skia/core/Vector.d.ts +12 -0
- package/lib/commonjs/skia/core/index.d.ts +10 -0
- package/lib/commonjs/skia/index.d.ts +3 -0
- package/lib/commonjs/skia/types/Canvas.d.ts +381 -0
- package/lib/commonjs/skia/types/Color.d.ts +2 -0
- package/lib/commonjs/skia/types/ColorFilter/ColorFilter.d.ts +3 -0
- package/lib/commonjs/skia/types/ColorFilter/ColorFilterFactory.d.ts +43 -0
- package/lib/commonjs/skia/types/ColorFilter/index.d.ts +2 -0
- package/lib/commonjs/skia/types/ContourMeasure.d.ts +41 -0
- package/lib/commonjs/skia/types/Data/Data.d.ts +12 -0
- package/lib/commonjs/skia/types/Data/DataFactory.d.ts +18 -0
- package/lib/commonjs/skia/types/Data/index.d.ts +2 -0
- package/lib/commonjs/skia/types/Font/Font.d.ts +180 -0
- package/lib/commonjs/skia/types/Font/index.d.ts +1 -0
- package/lib/commonjs/skia/types/Image/Image.d.ts +75 -0
- package/lib/commonjs/skia/types/Image/ImageFactory.d.ts +62 -0
- package/lib/commonjs/skia/types/Image/index.d.ts +2 -0
- package/lib/commonjs/skia/types/ImageFilter/ImageFilter.d.ts +23 -0
- package/lib/commonjs/skia/types/ImageFilter/ImageFilterFactory.d.ts +130 -0
- package/lib/commonjs/skia/types/ImageFilter/index.d.ts +2 -0
- package/lib/commonjs/skia/types/JsiInstance.d.ts +3 -0
- package/lib/commonjs/skia/types/MaskFilter.d.ts +21 -0
- package/lib/commonjs/skia/types/Matrix.d.ts +34 -0
- package/lib/commonjs/skia/types/Paint/BlendMode.d.ts +58 -0
- package/lib/commonjs/skia/types/Paint/Paint.d.ts +136 -0
- package/lib/commonjs/skia/types/Paint/index.d.ts +2 -0
- package/lib/commonjs/skia/types/Path/Path.d.ts +474 -0
- package/lib/commonjs/skia/types/Path/PathFactory.d.ts +29 -0
- package/lib/commonjs/skia/types/Path/index.d.ts +2 -0
- package/lib/commonjs/skia/types/PathEffect.d.ts +75 -0
- package/lib/commonjs/skia/types/Picture/Picture.d.ts +27 -0
- package/lib/commonjs/skia/types/Picture/PictureFactory.d.ts +8 -0
- package/lib/commonjs/skia/types/Picture/PictureRecorder.d.ts +15 -0
- package/lib/commonjs/skia/types/Picture/index.d.ts +3 -0
- package/lib/commonjs/skia/types/Point.d.ts +10 -0
- package/lib/commonjs/skia/types/RRect.d.ts +7 -0
- package/lib/commonjs/skia/types/RSXform.d.ts +2 -0
- package/lib/commonjs/skia/types/Rect.d.ts +6 -0
- package/lib/commonjs/skia/types/RuntimeEffect/RuntimeEffect.d.ts +52 -0
- package/lib/commonjs/skia/types/RuntimeEffect/RuntimeEffectFactory.d.ts +10 -0
- package/lib/commonjs/skia/types/RuntimeEffect/index.d.ts +2 -0
- package/lib/commonjs/skia/types/SVG/SVG.d.ts +2 -0
- package/lib/commonjs/skia/types/SVG/SVGFactory.d.ts +6 -0
- package/lib/commonjs/skia/types/SVG/index.d.ts +2 -0
- package/lib/commonjs/skia/types/Shader/Shader.d.ts +10 -0
- package/lib/commonjs/skia/types/Shader/ShaderFactory.d.ts +104 -0
- package/lib/commonjs/skia/types/Shader/index.d.ts +2 -0
- package/lib/commonjs/skia/types/Size.d.ts +4 -0
- package/lib/commonjs/skia/types/Skia.d.ts +66 -0
- package/lib/commonjs/skia/types/Surface/Surface.d.ts +25 -0
- package/lib/commonjs/skia/types/Surface/SurfaceFactory.d.ts +11 -0
- package/lib/commonjs/skia/types/Surface/index.d.ts +2 -0
- package/lib/commonjs/skia/types/TextBlob.d.ts +44 -0
- package/lib/commonjs/skia/types/Typeface/Typeface.d.ts +2 -0
- package/lib/commonjs/skia/types/Typeface/TypefaceFactory.d.ts +5 -0
- package/lib/commonjs/skia/types/Typeface/index.d.ts +2 -0
- package/lib/commonjs/skia/types/Vertices/Vertices.d.ts +17 -0
- package/lib/commonjs/skia/types/Vertices/index.d.ts +1 -0
- package/lib/commonjs/skia/types/index.d.ts +28 -0
- package/lib/commonjs/skia/web/Host.d.ts +19 -0
- package/lib/commonjs/skia/web/JsiSkCanvas.d.ts +44 -0
- package/lib/commonjs/skia/web/JsiSkColor.d.ts +2 -0
- package/lib/commonjs/skia/web/JsiSkColorFilter.d.ts +6 -0
- package/lib/commonjs/skia/web/JsiSkColorFilterFactory.d.ts +14 -0
- package/lib/commonjs/skia/web/JsiSkContourMeasure.d.ts +12 -0
- package/lib/commonjs/skia/web/JsiSkContourMeasureIter.d.ts +8 -0
- package/lib/commonjs/skia/web/JsiSkData.d.ts +8 -0
- package/lib/commonjs/skia/web/JsiSkDataFactory.d.ts +19 -0
- package/lib/commonjs/skia/web/JsiSkFont.d.ts +33 -0
- package/lib/commonjs/skia/web/JsiSkImage.d.ts +12 -0
- package/lib/commonjs/skia/web/JsiSkImageFactory.d.ts +10 -0
- package/lib/commonjs/skia/web/JsiSkImageFilter.d.ts +6 -0
- package/lib/commonjs/skia/web/JsiSkImageFilterFactory.d.ts +19 -0
- package/lib/commonjs/skia/web/JsiSkMaskFilter.d.ts +6 -0
- package/lib/commonjs/skia/web/JsiSkMaskFilterFactory.d.ts +9 -0
- package/lib/commonjs/skia/web/JsiSkMatrix.d.ts +13 -0
- package/lib/commonjs/skia/web/JsiSkPaint.d.ts +28 -0
- package/lib/commonjs/skia/web/JsiSkPath.d.ts +57 -0
- package/lib/commonjs/skia/web/JsiSkPathEffect.d.ts +6 -0
- package/lib/commonjs/skia/web/JsiSkPathEffectFactory.d.ts +15 -0
- package/lib/commonjs/skia/web/JsiSkPathFactory.d.ts +13 -0
- package/lib/commonjs/skia/web/JsiSkPicture.d.ts +9 -0
- package/lib/commonjs/skia/web/JsiSkPictureFactory.d.ts +8 -0
- package/lib/commonjs/skia/web/JsiSkPictureRecorder.d.ts +11 -0
- package/lib/commonjs/skia/web/JsiSkPoint.d.ts +9 -0
- package/lib/commonjs/skia/web/JsiSkRRect.d.ts +11 -0
- package/lib/commonjs/skia/web/JsiSkRSXform.d.ts +7 -0
- package/lib/commonjs/skia/web/JsiSkRect.d.ts +11 -0
- package/lib/commonjs/skia/web/JsiSkRuntimeEffect.d.ts +16 -0
- package/lib/commonjs/skia/web/JsiSkRuntimeEffectFactory.d.ts +8 -0
- package/lib/commonjs/skia/web/JsiSkSVGFactory.d.ts +9 -0
- package/lib/commonjs/skia/web/JsiSkShader.d.ts +6 -0
- package/lib/commonjs/skia/web/JsiSkShaderFactory.d.ts +16 -0
- package/lib/commonjs/skia/web/JsiSkSurface.d.ts +8 -0
- package/lib/commonjs/skia/web/JsiSkSurfaceFactory.d.ts +8 -0
- package/lib/commonjs/skia/web/JsiSkTextBlob.d.ts +6 -0
- package/lib/commonjs/skia/web/JsiSkTextBlobFactory.d.ts +13 -0
- package/lib/commonjs/skia/web/JsiSkTypeface.d.ts +8 -0
- package/lib/commonjs/skia/web/JsiSkTypefaceFactory.d.ts +8 -0
- package/lib/commonjs/skia/web/JsiSkVertices.d.ts +9 -0
- package/lib/commonjs/skia/web/JsiSkVerticesFactory.d.ts +4 -0
- package/lib/commonjs/skia/web/JsiSkia.d.ts +3 -0
- package/lib/commonjs/skia/web/index.d.ts +1 -0
- package/lib/commonjs/values/api.d.ts +5 -0
- package/lib/commonjs/values/api.web.d.ts +2 -0
- package/lib/commonjs/values/hooks/index.d.ts +4 -0
- package/lib/commonjs/values/hooks/useClockValue.d.ts +6 -0
- package/lib/commonjs/values/hooks/useComputedValue.d.ts +8 -0
- package/lib/commonjs/values/hooks/useValue.d.ts +7 -0
- package/lib/commonjs/values/hooks/useValueEffect.d.ts +7 -0
- package/lib/commonjs/values/index.d.ts +4 -0
- package/lib/commonjs/values/selector.d.ts +14 -0
- package/lib/commonjs/values/types.d.ts +63 -0
- package/lib/commonjs/values/web/RNSkAnimation.d.ts +9 -0
- package/lib/commonjs/values/web/RNSkClockValue.d.ts +13 -0
- package/lib/commonjs/values/web/RNSkComputedValue.d.ts +10 -0
- package/lib/commonjs/values/web/RNSkReadonlyValue.d.ts +12 -0
- package/lib/commonjs/values/web/RNSkValue.d.ts +14 -0
- package/lib/commonjs/values/web/api.d.ts +2 -0
- package/lib/commonjs/values/web/index.d.ts +1 -0
- package/lib/commonjs/views/SkiaBaseWebView.d.ts +62 -0
- package/lib/commonjs/views/SkiaDomView.d.ts +31 -0
- package/lib/commonjs/views/SkiaDomView.web.d.ts +7 -0
- package/lib/commonjs/views/SkiaPictureView.d.ts +27 -0
- package/lib/commonjs/views/SkiaPictureView.web.d.ts +7 -0
- package/lib/commonjs/views/SkiaView.d.ts +30 -0
- package/lib/commonjs/views/SkiaView.web.d.ts +7 -0
- package/lib/commonjs/views/api.d.ts +5 -0
- package/lib/commonjs/views/index.d.ts +6 -0
- package/lib/commonjs/views/types.d.ts +91 -0
- package/lib/commonjs/views/useDrawCallback.d.ts +8 -0
- package/lib/commonjs/views/useTouchHandler.d.ts +22 -0
- package/lib/commonjs/web/LoadSkiaWeb.d.ts +6 -0
- package/lib/commonjs/web/WithSkiaWeb.d.ts +12 -0
- package/lib/commonjs/web/index.d.ts +2 -0
- package/lib/module/animation/decay/decay.d.ts +2 -0
- package/lib/module/animation/decay/index.d.ts +1 -0
- package/lib/module/animation/decay/runDecay.d.ts +10 -0
- package/lib/module/animation/decay/types.d.ts +21 -0
- package/lib/module/animation/functions/index.d.ts +4 -0
- package/lib/module/animation/functions/interpolate.d.ts +17 -0
- package/lib/module/animation/functions/interpolateColors.d.ts +3 -0
- package/lib/module/animation/functions/interpolatePaths.d.ts +19 -0
- package/lib/module/animation/functions/interpolateVector.d.ts +10 -0
- package/lib/module/animation/index.d.ts +4 -0
- package/lib/module/animation/spring/Spring.d.ts +65 -0
- package/lib/module/animation/spring/functions/index.d.ts +1 -0
- package/lib/module/animation/spring/functions/spring.d.ts +10 -0
- package/lib/module/animation/spring/index.d.ts +3 -0
- package/lib/module/animation/spring/runSpring.d.ts +16 -0
- package/lib/module/animation/spring/types.d.ts +6 -0
- package/lib/module/animation/spring/useSpring.d.ts +10 -0
- package/lib/module/animation/timing/Easing.d.ts +19 -0
- package/lib/module/animation/timing/createTiming.d.ts +17 -0
- package/lib/module/animation/timing/functions/bezier.d.ts +1 -0
- package/lib/module/animation/timing/functions/getResolvedParams.d.ts +7 -0
- package/lib/module/animation/timing/functions/index.d.ts +4 -0
- package/lib/module/animation/timing/functions/timing.d.ts +17 -0
- package/lib/module/animation/timing/functions/types.d.ts +7 -0
- package/lib/module/animation/timing/index.d.ts +4 -0
- package/lib/module/animation/timing/runTiming.d.ts +16 -0
- package/lib/module/animation/timing/useLoop.d.ts +8 -0
- package/lib/module/animation/timing/useTiming.d.ts +10 -0
- package/lib/module/animation/types.d.ts +18 -0
- package/lib/module/dom/nodes/DrawingNode.d.ts +14 -0
- package/lib/module/dom/nodes/GroupNode.d.ts +7 -0
- package/lib/module/dom/nodes/JsiSkDOM.d.ts +65 -0
- package/lib/module/dom/nodes/LayerNode.d.ts +8 -0
- package/lib/module/dom/nodes/Node.d.ts +43 -0
- package/lib/module/dom/nodes/PaintContext.d.ts +18 -0
- package/lib/module/dom/nodes/PaintNode.d.ts +8 -0
- package/lib/module/dom/nodes/RenderNode.d.ts +27 -0
- package/lib/module/dom/nodes/datatypes/Circle.d.ts +7 -0
- package/lib/module/dom/nodes/datatypes/Enum.d.ts +1 -0
- package/lib/module/dom/nodes/datatypes/Fitting.d.ts +33 -0
- package/lib/module/dom/nodes/datatypes/Gradient.d.ts +92 -0
- package/lib/module/dom/nodes/datatypes/Path.d.ts +4 -0
- package/lib/module/dom/nodes/datatypes/Radius.d.ts +3 -0
- package/lib/module/dom/nodes/datatypes/Rect.d.ts +5 -0
- package/lib/module/dom/nodes/datatypes/Transform.d.ts +3 -0
- package/lib/module/dom/nodes/datatypes/index.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/BackdropFilterNode.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/Box.d.ts +13 -0
- package/lib/module/dom/nodes/drawings/CircleNode.d.ts +9 -0
- package/lib/module/dom/nodes/drawings/CustomDrawingNode.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/DiffRectNode.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/FillNode.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/ImageNode.d.ts +25 -0
- package/lib/module/dom/nodes/drawings/ImageSVG.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/LineNode.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/OvalNode.d.ts +9 -0
- package/lib/module/dom/nodes/drawings/PatchNode.d.ts +18 -0
- package/lib/module/dom/nodes/drawings/PathNode.d.ts +9 -0
- package/lib/module/dom/nodes/drawings/PictureNode.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/PointsNode.d.ts +8 -0
- package/lib/module/dom/nodes/drawings/RRectNode.d.ts +10 -0
- package/lib/module/dom/nodes/drawings/RectNode.d.ts +9 -0
- package/lib/module/dom/nodes/drawings/Text.d.ts +30 -0
- package/lib/module/dom/nodes/drawings/VerticesNode.d.ts +9 -0
- package/lib/module/dom/nodes/drawings/index.d.ts +18 -0
- package/lib/module/dom/nodes/index.d.ts +3 -0
- package/lib/module/dom/nodes/paint/BlendNode.d.ts +12 -0
- package/lib/module/dom/nodes/paint/ColorFilters.d.ts +36 -0
- package/lib/module/dom/nodes/paint/ImageFilters.d.ts +42 -0
- package/lib/module/dom/nodes/paint/MaskFilters.d.ts +8 -0
- package/lib/module/dom/nodes/paint/PathEffects.d.ts +42 -0
- package/lib/module/dom/nodes/paint/Shaders.d.ts +44 -0
- package/lib/module/dom/nodes/paint/index.d.ts +6 -0
- package/lib/module/dom/types/ColorFilters.d.ts +12 -0
- package/lib/module/dom/types/Common.d.ts +56 -0
- package/lib/module/dom/types/DrawingContext.d.ts +5 -0
- package/lib/module/dom/types/Drawings.d.ts +104 -0
- package/lib/module/dom/types/ImageFilters.d.ts +37 -0
- package/lib/module/dom/types/MaskFilters.d.ts +7 -0
- package/lib/module/dom/types/Node.d.ts +29 -0
- package/lib/module/dom/types/NodeType.d.ts +67 -0
- package/lib/module/dom/types/PathEffects.d.ts +28 -0
- package/lib/module/dom/types/Shaders.d.ts +59 -0
- package/lib/module/dom/types/SkDOM.d.ts +72 -0
- package/lib/module/dom/types/index.d.ts +11 -0
- package/lib/module/external/index.d.ts +1 -0
- package/lib/module/external/reanimated/index.d.ts +1 -0
- package/lib/module/external/reanimated/useSharedValueEffect.d.ts +11 -0
- package/lib/module/index.d.ts +10 -0
- package/lib/module/mock/index.d.ts +16 -0
- package/lib/module/renderer/Canvas.d.ts +11 -0
- package/lib/module/renderer/Container.d.ts +12 -0
- package/lib/module/renderer/DependencyManager.d.ts +46 -0
- package/lib/module/renderer/DrawingContext.d.ts +6 -0
- package/lib/module/renderer/HostComponents.d.ts +132 -0
- package/lib/module/renderer/HostConfig.d.ts +19 -0
- package/lib/module/renderer/Reconciler.d.ts +13 -0
- package/lib/module/renderer/components/Blend.d.ts +4 -0
- package/lib/module/renderer/components/Drawing.d.ts +3 -0
- package/lib/module/renderer/components/Group.d.ts +8 -0
- package/lib/module/renderer/components/Mask.d.ts +9 -0
- package/lib/module/renderer/components/Paint.d.ts +4 -0
- package/lib/module/renderer/components/Picture.d.ts +4 -0
- package/lib/module/renderer/components/backdrop/BackdropBlur.d.ts +9 -0
- package/lib/module/renderer/components/backdrop/BackdropFilter.d.ts +7 -0
- package/lib/module/renderer/components/backdrop/index.d.ts +2 -0
- package/lib/module/renderer/components/colorFilters/BlendColor.d.ts +4 -0
- package/lib/module/renderer/components/colorFilters/Lerp.d.ts +4 -0
- package/lib/module/renderer/components/colorFilters/LinearToSRGBGamma.d.ts +4 -0
- package/lib/module/renderer/components/colorFilters/LumaColorFilter.d.ts +4 -0
- package/lib/module/renderer/components/colorFilters/Matrix.d.ts +5 -0
- package/lib/module/renderer/components/colorFilters/SRGBToLinearGamma.d.ts +4 -0
- package/lib/module/renderer/components/colorFilters/index.d.ts +6 -0
- package/lib/module/renderer/components/image/Image.d.ts +4 -0
- package/lib/module/renderer/components/image/ImageSVG.d.ts +4 -0
- package/lib/module/renderer/components/image/ImageShader.d.ts +4 -0
- package/lib/module/renderer/components/image/index.d.ts +3 -0
- package/lib/module/renderer/components/imageFilters/Blur.d.ts +4 -0
- package/lib/module/renderer/components/imageFilters/DisplacementMap.d.ts +4 -0
- package/lib/module/renderer/components/imageFilters/Morphology.d.ts +4 -0
- package/lib/module/renderer/components/imageFilters/Offset.d.ts +4 -0
- package/lib/module/renderer/components/imageFilters/RuntimeShader.d.ts +4 -0
- package/lib/module/renderer/components/imageFilters/Shadow.d.ts +4 -0
- package/lib/module/renderer/components/imageFilters/index.d.ts +6 -0
- package/lib/module/renderer/components/index.d.ts +16 -0
- package/lib/module/renderer/components/maskFilters/Blur.d.ts +4 -0
- package/lib/module/renderer/components/maskFilters/index.d.ts +1 -0
- package/lib/module/renderer/components/pathEffects/Corner.d.ts +4 -0
- package/lib/module/renderer/components/pathEffects/Dash.d.ts +4 -0
- package/lib/module/renderer/components/pathEffects/Discrete.d.ts +4 -0
- package/lib/module/renderer/components/pathEffects/Line2D.d.ts +4 -0
- package/lib/module/renderer/components/pathEffects/Path1D.d.ts +4 -0
- package/lib/module/renderer/components/pathEffects/Path2D.d.ts +4 -0
- package/lib/module/renderer/components/pathEffects/Sum.d.ts +3 -0
- package/lib/module/renderer/components/pathEffects/index.d.ts +7 -0
- package/lib/module/renderer/components/shaders/Color.d.ts +4 -0
- package/lib/module/renderer/components/shaders/FractalNoise.d.ts +4 -0
- package/lib/module/renderer/components/shaders/LinearGradient.d.ts +4 -0
- package/lib/module/renderer/components/shaders/RadialGradient.d.ts +4 -0
- package/lib/module/renderer/components/shaders/Shader.d.ts +4 -0
- package/lib/module/renderer/components/shaders/ShaderLib.d.ts +4 -0
- package/lib/module/renderer/components/shaders/SweepGradient.d.ts +4 -0
- package/lib/module/renderer/components/shaders/Turbulence.d.ts +4 -0
- package/lib/module/renderer/components/shaders/TwoPointConicalGradient.d.ts +4 -0
- package/lib/module/renderer/components/shaders/index.d.ts +9 -0
- package/lib/module/renderer/components/shapes/Box.d.ts +5 -0
- package/lib/module/renderer/components/shapes/Circle.d.ts +4 -0
- package/lib/module/renderer/components/shapes/DiffRect.d.ts +4 -0
- package/lib/module/renderer/components/shapes/Fill.d.ts +4 -0
- package/lib/module/renderer/components/shapes/FitBox.d.ts +20 -0
- package/lib/module/renderer/components/shapes/Line.d.ts +4 -0
- package/lib/module/renderer/components/shapes/Oval.d.ts +4 -0
- package/lib/module/renderer/components/shapes/Patch.d.ts +4 -0
- package/lib/module/renderer/components/shapes/Path.d.ts +4 -0
- package/lib/module/renderer/components/shapes/Points.d.ts +4 -0
- package/lib/module/renderer/components/shapes/Rect.d.ts +4 -0
- package/lib/module/renderer/components/shapes/RoundedRect.d.ts +4 -0
- package/lib/module/renderer/components/shapes/Vertices.d.ts +4 -0
- package/lib/module/renderer/components/shapes/index.d.ts +13 -0
- package/lib/module/renderer/components/text/Glyphs.d.ts +4 -0
- package/lib/module/renderer/components/text/Text.d.ts +4 -0
- package/lib/module/renderer/components/text/TextBlob.d.ts +4 -0
- package/lib/module/renderer/components/text/TextPath.d.ts +4 -0
- package/lib/module/renderer/components/text/index.d.ts +4 -0
- package/lib/module/renderer/index.d.ts +2 -0
- package/lib/module/renderer/index.js +0 -1
- package/lib/module/renderer/index.js.map +1 -1
- package/lib/module/renderer/processors/Animations/Animations.d.ts +17 -0
- package/lib/module/renderer/processors/Animations/index.d.ts +1 -0
- package/lib/module/renderer/processors/index.d.ts +2 -0
- package/lib/module/renderer/processors/math/Coordinates.d.ts +29 -0
- package/lib/module/renderer/processors/math/Math.d.ts +15 -0
- package/lib/module/renderer/processors/math/Transforms.d.ts +5 -0
- package/lib/module/renderer/processors/math/index.d.ts +3 -0
- package/lib/module/renderer/typeddash.d.ts +3 -0
- package/lib/module/skia/NativeSetup.d.ts +1 -0
- package/lib/module/skia/Skia.d.ts +8 -0
- package/lib/module/skia/Skia.web.d.ts +1 -0
- package/lib/module/skia/core/Data.d.ts +3 -0
- package/lib/module/skia/core/Font.d.ts +5 -0
- package/lib/module/skia/core/Image.d.ts +5 -0
- package/lib/module/skia/core/Matrix.d.ts +2 -0
- package/lib/module/skia/core/Picture.d.ts +8 -0
- package/lib/module/skia/core/RRect.d.ts +2 -0
- package/lib/module/skia/core/Rect.d.ts +8 -0
- package/lib/module/skia/core/SVG.d.ts +2 -0
- package/lib/module/skia/core/Typeface.d.ts +5 -0
- package/lib/module/skia/core/Vector.d.ts +12 -0
- package/lib/module/skia/core/index.d.ts +10 -0
- package/lib/module/skia/index.d.ts +3 -0
- package/lib/module/skia/types/Canvas.d.ts +381 -0
- package/lib/module/skia/types/Color.d.ts +2 -0
- package/lib/module/skia/types/ColorFilter/ColorFilter.d.ts +3 -0
- package/lib/module/skia/types/ColorFilter/ColorFilterFactory.d.ts +43 -0
- package/lib/module/skia/types/ColorFilter/index.d.ts +2 -0
- package/lib/module/skia/types/ContourMeasure.d.ts +41 -0
- package/lib/module/skia/types/Data/Data.d.ts +12 -0
- package/lib/module/skia/types/Data/DataFactory.d.ts +18 -0
- package/lib/module/skia/types/Data/index.d.ts +2 -0
- package/lib/module/skia/types/Font/Font.d.ts +180 -0
- package/lib/module/skia/types/Font/index.d.ts +1 -0
- package/lib/module/skia/types/Image/Image.d.ts +75 -0
- package/lib/module/skia/types/Image/ImageFactory.d.ts +62 -0
- package/lib/module/skia/types/Image/index.d.ts +2 -0
- package/lib/module/skia/types/ImageFilter/ImageFilter.d.ts +23 -0
- package/lib/module/skia/types/ImageFilter/ImageFilterFactory.d.ts +130 -0
- package/lib/module/skia/types/ImageFilter/index.d.ts +2 -0
- package/lib/module/skia/types/JsiInstance.d.ts +3 -0
- package/lib/module/skia/types/MaskFilter.d.ts +21 -0
- package/lib/module/skia/types/Matrix.d.ts +34 -0
- package/lib/module/skia/types/Paint/BlendMode.d.ts +58 -0
- package/lib/module/skia/types/Paint/Paint.d.ts +136 -0
- package/lib/module/skia/types/Paint/index.d.ts +2 -0
- package/lib/module/skia/types/Path/Path.d.ts +474 -0
- package/lib/module/skia/types/Path/PathFactory.d.ts +29 -0
- package/lib/module/skia/types/Path/index.d.ts +2 -0
- package/lib/module/skia/types/PathEffect.d.ts +75 -0
- package/lib/module/skia/types/Picture/Picture.d.ts +27 -0
- package/lib/module/skia/types/Picture/PictureFactory.d.ts +8 -0
- package/lib/module/skia/types/Picture/PictureRecorder.d.ts +15 -0
- package/lib/module/skia/types/Picture/index.d.ts +3 -0
- package/lib/module/skia/types/Point.d.ts +10 -0
- package/lib/module/skia/types/RRect.d.ts +7 -0
- package/lib/module/skia/types/RSXform.d.ts +2 -0
- package/lib/module/skia/types/Rect.d.ts +6 -0
- package/lib/module/skia/types/RuntimeEffect/RuntimeEffect.d.ts +52 -0
- package/lib/module/skia/types/RuntimeEffect/RuntimeEffectFactory.d.ts +10 -0
- package/lib/module/skia/types/RuntimeEffect/index.d.ts +2 -0
- package/lib/module/skia/types/SVG/SVG.d.ts +2 -0
- package/lib/module/skia/types/SVG/SVGFactory.d.ts +6 -0
- package/lib/module/skia/types/SVG/index.d.ts +2 -0
- package/lib/module/skia/types/Shader/Shader.d.ts +10 -0
- package/lib/module/skia/types/Shader/ShaderFactory.d.ts +104 -0
- package/lib/module/skia/types/Shader/index.d.ts +2 -0
- package/lib/module/skia/types/Size.d.ts +4 -0
- package/lib/module/skia/types/Skia.d.ts +66 -0
- package/lib/module/skia/types/Surface/Surface.d.ts +25 -0
- package/lib/module/skia/types/Surface/SurfaceFactory.d.ts +11 -0
- package/lib/module/skia/types/Surface/index.d.ts +2 -0
- package/lib/module/skia/types/TextBlob.d.ts +44 -0
- package/lib/module/skia/types/Typeface/Typeface.d.ts +2 -0
- package/lib/module/skia/types/Typeface/TypefaceFactory.d.ts +5 -0
- package/lib/module/skia/types/Typeface/index.d.ts +2 -0
- package/lib/module/skia/types/Vertices/Vertices.d.ts +17 -0
- package/lib/module/skia/types/Vertices/index.d.ts +1 -0
- package/lib/module/skia/types/index.d.ts +28 -0
- package/lib/module/skia/web/Host.d.ts +19 -0
- package/lib/module/skia/web/JsiSkCanvas.d.ts +44 -0
- package/lib/module/skia/web/JsiSkColor.d.ts +2 -0
- package/lib/module/skia/web/JsiSkColorFilter.d.ts +6 -0
- package/lib/module/skia/web/JsiSkColorFilterFactory.d.ts +14 -0
- package/lib/module/skia/web/JsiSkContourMeasure.d.ts +12 -0
- package/lib/module/skia/web/JsiSkContourMeasureIter.d.ts +8 -0
- package/lib/module/skia/web/JsiSkData.d.ts +8 -0
- package/lib/module/skia/web/JsiSkDataFactory.d.ts +19 -0
- package/lib/module/skia/web/JsiSkFont.d.ts +33 -0
- package/lib/module/skia/web/JsiSkImage.d.ts +12 -0
- package/lib/module/skia/web/JsiSkImageFactory.d.ts +10 -0
- package/lib/module/skia/web/JsiSkImageFilter.d.ts +6 -0
- package/lib/module/skia/web/JsiSkImageFilterFactory.d.ts +19 -0
- package/lib/module/skia/web/JsiSkMaskFilter.d.ts +6 -0
- package/lib/module/skia/web/JsiSkMaskFilterFactory.d.ts +9 -0
- package/lib/module/skia/web/JsiSkMatrix.d.ts +13 -0
- package/lib/module/skia/web/JsiSkPaint.d.ts +28 -0
- package/lib/module/skia/web/JsiSkPath.d.ts +57 -0
- package/lib/module/skia/web/JsiSkPathEffect.d.ts +6 -0
- package/lib/module/skia/web/JsiSkPathEffectFactory.d.ts +15 -0
- package/lib/module/skia/web/JsiSkPathFactory.d.ts +13 -0
- package/lib/module/skia/web/JsiSkPicture.d.ts +9 -0
- package/lib/module/skia/web/JsiSkPictureFactory.d.ts +8 -0
- package/lib/module/skia/web/JsiSkPictureRecorder.d.ts +11 -0
- package/lib/module/skia/web/JsiSkPoint.d.ts +9 -0
- package/lib/module/skia/web/JsiSkRRect.d.ts +11 -0
- package/lib/module/skia/web/JsiSkRSXform.d.ts +7 -0
- package/lib/module/skia/web/JsiSkRect.d.ts +11 -0
- package/lib/module/skia/web/JsiSkRuntimeEffect.d.ts +16 -0
- package/lib/module/skia/web/JsiSkRuntimeEffectFactory.d.ts +8 -0
- package/lib/module/skia/web/JsiSkSVGFactory.d.ts +9 -0
- package/lib/module/skia/web/JsiSkShader.d.ts +6 -0
- package/lib/module/skia/web/JsiSkShaderFactory.d.ts +16 -0
- package/lib/module/skia/web/JsiSkSurface.d.ts +8 -0
- package/lib/module/skia/web/JsiSkSurfaceFactory.d.ts +8 -0
- package/lib/module/skia/web/JsiSkTextBlob.d.ts +6 -0
- package/lib/module/skia/web/JsiSkTextBlobFactory.d.ts +13 -0
- package/lib/module/skia/web/JsiSkTypeface.d.ts +8 -0
- package/lib/module/skia/web/JsiSkTypefaceFactory.d.ts +8 -0
- package/lib/module/skia/web/JsiSkVertices.d.ts +9 -0
- package/lib/module/skia/web/JsiSkVerticesFactory.d.ts +4 -0
- package/lib/module/skia/web/JsiSkia.d.ts +3 -0
- package/lib/module/skia/web/index.d.ts +1 -0
- package/lib/module/values/api.d.ts +5 -0
- package/lib/module/values/api.web.d.ts +2 -0
- package/lib/module/values/hooks/index.d.ts +4 -0
- package/lib/module/values/hooks/useClockValue.d.ts +6 -0
- package/lib/module/values/hooks/useComputedValue.d.ts +8 -0
- package/lib/module/values/hooks/useValue.d.ts +7 -0
- package/lib/module/values/hooks/useValueEffect.d.ts +7 -0
- package/lib/module/values/index.d.ts +4 -0
- package/lib/module/values/selector.d.ts +14 -0
- package/lib/module/values/types.d.ts +63 -0
- package/lib/module/values/web/RNSkAnimation.d.ts +9 -0
- package/lib/module/values/web/RNSkClockValue.d.ts +13 -0
- package/lib/module/values/web/RNSkComputedValue.d.ts +10 -0
- package/lib/module/values/web/RNSkReadonlyValue.d.ts +12 -0
- package/lib/module/values/web/RNSkValue.d.ts +14 -0
- package/lib/module/values/web/api.d.ts +2 -0
- package/lib/module/values/web/index.d.ts +1 -0
- package/lib/module/views/SkiaBaseWebView.d.ts +62 -0
- package/lib/module/views/SkiaDomView.d.ts +31 -0
- package/lib/module/views/SkiaDomView.web.d.ts +7 -0
- package/lib/module/views/SkiaPictureView.d.ts +27 -0
- package/lib/module/views/SkiaPictureView.web.d.ts +7 -0
- package/lib/module/views/SkiaView.d.ts +30 -0
- package/lib/module/views/SkiaView.web.d.ts +7 -0
- package/lib/module/views/api.d.ts +5 -0
- package/lib/module/views/index.d.ts +6 -0
- package/lib/module/views/types.d.ts +91 -0
- package/lib/module/views/useDrawCallback.d.ts +8 -0
- package/lib/module/views/useTouchHandler.d.ts +22 -0
- package/lib/module/web/LoadSkiaWeb.d.ts +6 -0
- package/lib/module/web/WithSkiaWeb.d.ts +12 -0
- package/lib/module/web/index.d.ts +2 -0
- package/lib/typescript/src/renderer/index.d.ts +0 -1
- package/package.json +5 -4
- package/src/renderer/index.ts +0 -1
- package/lib/commonjs/renderer/useContextBridge.js +0 -35
- package/lib/commonjs/renderer/useContextBridge.js.map +0 -1
- package/lib/module/renderer/useContextBridge.js +0 -21
- package/lib/module/renderer/useContextBridge.js.map +0 -1
- package/lib/typescript/src/renderer/useContextBridge.d.ts +0 -5
- package/src/renderer/useContextBridge.tsx +0 -21
package/android/CMakeLists.txt
CHANGED
@@ -12,6 +12,11 @@ set (SKIA_SKSHAPER_LIB "skshaper")
|
|
12
12
|
#set (SKIA_SKPARAGRAPH_LIB "skparagraph")
|
13
13
|
#set (SKIA_SKUNICODE_LIB "skunicode")
|
14
14
|
|
15
|
+
# Clear some variables
|
16
|
+
unset(LIBRN_DIR CACHE)
|
17
|
+
unset(libfbjni_link_DIRS CACHE)
|
18
|
+
unset(libfbjni_include_DIRS CACHE)
|
19
|
+
|
15
20
|
set(build_DIR ${CMAKE_SOURCE_DIR}/build)
|
16
21
|
file(GLOB LIBRN_DIR "${PREBUILT_DIR}/${ANDROID_ABI}")
|
17
22
|
file(GLOB libfbjni_link_DIRS "${build_DIR}/fbjni*.aar/jni/${ANDROID_ABI}")
|
@@ -114,49 +119,72 @@ find_library(
|
|
114
119
|
LOG_LIB
|
115
120
|
log
|
116
121
|
)
|
117
|
-
|
118
122
|
message("-- LOG : " ${LOG_LIB})
|
119
123
|
|
120
|
-
|
121
|
-
|
122
|
-
|
123
|
-
|
124
|
-
|
125
|
-
find_library(
|
126
|
-
JSI_LIB
|
127
|
-
jsi
|
128
|
-
PATHS ${LIBRN_DIR}
|
129
|
-
NO_CMAKE_FIND_ROOT_PATH
|
130
|
-
)
|
131
|
-
endif()
|
132
|
-
|
133
|
-
message("-- JSI : " ${JSI_LIB})
|
124
|
+
if(${REACT_NATIVE_VERSION} GREATER_EQUAL 71)
|
125
|
+
# We need to find packages since from RN 0.71 binaries are prebuilt
|
126
|
+
find_package(fbjni REQUIRED CONFIG)
|
127
|
+
find_package(ReactAndroid REQUIRED CONFIG)
|
128
|
+
endif()
|
134
129
|
|
135
|
-
|
136
|
-
|
137
|
-
|
130
|
+
unset(JSI_LIB CACHE)
|
131
|
+
if(${REACT_NATIVE_VERSION} LESS 66)
|
132
|
+
# JSI lib didn't exist on RN 0.65 and before. Simply omit it.
|
133
|
+
set (JSI_LIB "")
|
134
|
+
elseif(${REACT_NATIVE_VERSION} GREATER_EQUAL 71)
|
135
|
+
# RN 0.71 distributes prebuilt binaries.
|
136
|
+
set (JSI_LIB ReactAndroid::jsi)
|
137
|
+
else()
|
138
|
+
# RN 0.66 distributes libjsi.so, can be used instead of compiling jsi.cpp manually.
|
139
|
+
find_library(
|
140
|
+
JSI_LIB
|
141
|
+
jsi
|
138
142
|
PATHS ${LIBRN_DIR}
|
139
143
|
NO_CMAKE_FIND_ROOT_PATH
|
140
|
-
)
|
141
|
-
|
144
|
+
)
|
145
|
+
endif()
|
146
|
+
message("-- JSI : " ${JSI_LIB})
|
147
|
+
|
148
|
+
unset(REACT_LIB CACHE)
|
149
|
+
if(${REACT_NATIVE_VERSION} GREATER_EQUAL 71)
|
150
|
+
# RN 0.71 distributes prebuilt binaries.
|
151
|
+
set (REACT_LIB ReactAndroid::react_nativemodule_core)
|
152
|
+
else()
|
153
|
+
find_library(
|
154
|
+
REACT_LIB
|
155
|
+
react_nativemodule_core
|
156
|
+
PATHS ${LIBRN_DIR}
|
157
|
+
NO_CMAKE_FIND_ROOT_PATH
|
158
|
+
)
|
159
|
+
endif()
|
142
160
|
message("-- REACT : " ${REACT_LIB})
|
143
161
|
|
144
|
-
|
145
|
-
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
162
|
+
unset(FBJNI_LIBRARY CACHE)
|
163
|
+
if(${REACT_NATIVE_VERSION} GREATER_EQUAL 71)
|
164
|
+
# RN 0.71 distributes prebuilt binaries.
|
165
|
+
set (FBJNI_LIBRARY fbjni::fbjni)
|
166
|
+
else()
|
167
|
+
find_library(
|
168
|
+
FBJNI_LIBRARY
|
169
|
+
fbjni
|
170
|
+
PATHS ${libfbjni_link_DIRS}
|
171
|
+
NO_CMAKE_FIND_ROOT_PATH
|
172
|
+
)
|
173
|
+
endif()
|
151
174
|
message("-- FBJNI : " ${FBJNI_LIBRARY})
|
152
175
|
|
153
|
-
|
154
|
-
|
155
|
-
|
156
|
-
|
157
|
-
|
158
|
-
|
159
|
-
|
176
|
+
unset(TURBOMODULES_LIB CACHE)
|
177
|
+
if(${REACT_NATIVE_VERSION} GREATER_EQUAL 71)
|
178
|
+
# RN 0.71 distributes prebuilt binaries.
|
179
|
+
set (TURBOMODULES_LIB "ReactAndroid::turbomodulejsijni")
|
180
|
+
else()
|
181
|
+
find_library(
|
182
|
+
TURBOMODULES_LIB
|
183
|
+
turbomodulejsijni
|
184
|
+
PATHS ${LIBRN_DIR}
|
185
|
+
NO_CMAKE_FIND_ROOT_PATH
|
186
|
+
)
|
187
|
+
endif()
|
160
188
|
message("-- TURBO : " ${TURBOMODULES_LIB})
|
161
189
|
|
162
190
|
# Link
|
package/android/build.gradle
CHANGED
@@ -47,7 +47,7 @@ def nodeModules = findNodeModules(projectDir)
|
|
47
47
|
logger.warn("react-native-skia: node_modules/ found at: ${nodeModules}")
|
48
48
|
|
49
49
|
def sourceBuild = false
|
50
|
-
def defaultDir
|
50
|
+
def defaultDir
|
51
51
|
|
52
52
|
if (rootProject.ext.has('reactNativeAndroidRoot')) {
|
53
53
|
defaultDir = rootProject.ext.get('reactNativeAndroidRoot')
|
@@ -55,7 +55,7 @@ if (rootProject.ext.has('reactNativeAndroidRoot')) {
|
|
55
55
|
sourceBuild = true
|
56
56
|
defaultDir = project(':ReactAndroid').projectDir
|
57
57
|
} else {
|
58
|
-
defaultDir = file("$nodeModules/react-native
|
58
|
+
defaultDir = file("$nodeModules/react-native")
|
59
59
|
}
|
60
60
|
|
61
61
|
if (!defaultDir.exists()) {
|
@@ -78,7 +78,7 @@ if (gradle.startParameter.taskRequests.args[0].toString().contains("Release")) {
|
|
78
78
|
|
79
79
|
def reactProperties = new Properties()
|
80
80
|
file("$nodeModules/react-native/ReactAndroid/gradle.properties").withInputStream { reactProperties.load(it) }
|
81
|
-
def FULL_RN_VERSION = reactProperties.getProperty("VERSION_NAME")
|
81
|
+
def FULL_RN_VERSION = (System.getenv("REACT_NATIVE_OVERRIDE_VERSION") ?: reactProperties.getProperty("VERSION_NAME"))
|
82
82
|
def REACT_NATIVE_VERSION = FULL_RN_VERSION.split("\\.")[1].toInteger()
|
83
83
|
|
84
84
|
logger.warn("react-native-skia: RN Version: ${REACT_NATIVE_VERSION} / ${FULL_RN_VERSION}")
|
@@ -136,6 +136,10 @@ android {
|
|
136
136
|
}
|
137
137
|
}
|
138
138
|
|
139
|
+
buildFeatures {
|
140
|
+
prefab true
|
141
|
+
}
|
142
|
+
|
139
143
|
packagingOptions {
|
140
144
|
excludes = [
|
141
145
|
"**/libc++_shared.so",
|
@@ -146,8 +150,6 @@ android {
|
|
146
150
|
]
|
147
151
|
}
|
148
152
|
|
149
|
-
|
150
|
-
|
151
153
|
// Create new configurations that can be referred to in dependencies.
|
152
154
|
// The Android Gradle Plugin 3.* does not allow hooking into existing
|
153
155
|
// configurations like `implementation`.
|
@@ -181,17 +183,25 @@ dependencies {
|
|
181
183
|
//noinspection GradleDynamicVersion
|
182
184
|
implementation 'com.facebook.react:react-native:+' // From node_modules
|
183
185
|
|
184
|
-
|
185
|
-
|
186
|
-
|
187
|
-
|
186
|
+
if (REACT_NATIVE_VERSION < 71) {
|
187
|
+
logger.warn("react-native-skia: Extracting files from AAR (pre RN 0.71)")
|
188
|
+
//noinspection GradleDynamicVersion
|
189
|
+
extractHeaders("com.facebook.fbjni:fbjni:0.2.2:headers")
|
190
|
+
//noinspection GradleDynamicVersion
|
191
|
+
extractJNI("com.facebook.fbjni:fbjni:0.2.2")
|
192
|
+
}
|
188
193
|
|
189
194
|
if (!sourceBuild) {
|
190
195
|
def rnAarMatcher = "**/react-native/**/*${buildType}.aar"
|
191
196
|
if (REACT_NATIVE_VERSION < 69) {
|
197
|
+
logger.warn("react-native-skia: aar state pre 69. match **/**/*.aar")
|
192
198
|
rnAarMatcher = "**/**/*.aar"
|
199
|
+
} else if (REACT_NATIVE_VERSION >= 71) {
|
200
|
+
logger.warn("react-native-skia: aar state post 70, do nothing")
|
201
|
+
return
|
193
202
|
}
|
194
|
-
def rnAAR = fileTree("${nodeModules}/react-native/android").matching({ it.include rnAarMatcher }).singleFile
|
203
|
+
def rnAAR = fileTree("${nodeModules}/react-native/android").matching({ it.include rnAarMatcher }).singleFile
|
204
|
+
logger.warn("react-native-skia: Extracting JNI files (pre RN 0.71) ${rnAAR}")
|
195
205
|
extractJNI(files(rnAAR))
|
196
206
|
}
|
197
207
|
}
|
@@ -55,8 +55,8 @@ public:
|
|
55
55
|
auto info = getEnsuredViewInfo(nativeId);
|
56
56
|
|
57
57
|
std::lock_guard<std::mutex> lock(_mutex);
|
58
|
-
info->props.
|
59
|
-
|
58
|
+
info->props.insert_or_assign(arguments[1].asString(runtime).utf8(runtime),
|
59
|
+
RNJsi::JsiValueWrapper(runtime, arguments[2]));
|
60
60
|
|
61
61
|
// Now let's see if we have a view that we can update
|
62
62
|
if (info->view != nullptr) {
|
@@ -7,6 +7,7 @@
|
|
7
7
|
#include "JsiSkPaint.h"
|
8
8
|
|
9
9
|
#include <memory>
|
10
|
+
#include <mutex>
|
10
11
|
#include <utility>
|
11
12
|
|
12
13
|
namespace RNSkia {
|
@@ -76,7 +77,11 @@ protected:
|
|
76
77
|
static_cast<const jsi::Value *>(args.data()), 1);
|
77
78
|
|
78
79
|
auto picture = recorder.finishRecordingAsPicture();
|
79
|
-
|
80
|
+
{
|
81
|
+
// Lock access to the picture property's setter
|
82
|
+
std::lock_guard<std::mutex> lock(_pictureLock);
|
83
|
+
this->_drawingProp->setPicture(picture);
|
84
|
+
}
|
80
85
|
|
81
86
|
// Ask view to redraw itself
|
82
87
|
_inRedrawCycle = true;
|
@@ -86,6 +91,7 @@ protected:
|
|
86
91
|
}
|
87
92
|
|
88
93
|
if (_drawingProp->isSet()) {
|
94
|
+
std::lock_guard<std::mutex> lock(_pictureLock);
|
89
95
|
context->getCanvas()->drawPicture(_drawingProp->getDerivedValue());
|
90
96
|
_inRedrawCycle = false;
|
91
97
|
}
|
@@ -115,6 +121,7 @@ private:
|
|
115
121
|
std::shared_ptr<JsiSkCanvas> _jsiCanvas;
|
116
122
|
|
117
123
|
std::atomic<bool> _inRedrawCycle = {false};
|
124
|
+
std::mutex _pictureLock;
|
118
125
|
};
|
119
126
|
|
120
127
|
} // namespace RNSkia
|
@@ -41,7 +41,7 @@ RNSkCanvasProvider(requestRedraw),
|
|
41
41
|
_layer.opaque = false;
|
42
42
|
_layer.contentsScale = _context->getPixelDensity();
|
43
43
|
_layer.pixelFormat = MTLPixelFormatBGRA8Unorm;
|
44
|
-
_layer.contentsGravity =
|
44
|
+
_layer.contentsGravity = kCAGravityBottomLeft;
|
45
45
|
}
|
46
46
|
|
47
47
|
RNSkMetalCanvasProvider::~RNSkMetalCanvasProvider() {
|
@@ -73,6 +73,10 @@ void RNSkMetalCanvasProvider::renderToCanvas(const std::function<void(SkCanvas*)
|
|
73
73
|
auto state = UIApplication.sharedApplication.applicationState;
|
74
74
|
if (state == UIApplicationStateBackground || state == UIApplicationStateInactive)
|
75
75
|
{
|
76
|
+
// Request a redraw in the next run loop callback
|
77
|
+
_requestRedraw();
|
78
|
+
// and don't draw now since it might cause errors in the metal renderer if
|
79
|
+
// we try to render while in the background. (see above issue)
|
76
80
|
return;
|
77
81
|
}
|
78
82
|
|
@@ -0,0 +1 @@
|
|
1
|
+
export { runDecay } from "./runDecay";
|
@@ -0,0 +1,10 @@
|
|
1
|
+
import type { SkiaMutableValue } from "../../values/types";
|
2
|
+
import type { DecayConfig } from "./types";
|
3
|
+
/**
|
4
|
+
* Runs a decay animation from the current value to zero with the given decay
|
5
|
+
* configuration.
|
6
|
+
* @param value value to animate
|
7
|
+
* @param config Configuration or default configuration
|
8
|
+
* @returns Animation
|
9
|
+
*/
|
10
|
+
export declare const runDecay: (value: SkiaMutableValue<number>, config?: DecayConfig) => import("../../values/types").SkiaAnimation;
|
@@ -0,0 +1,21 @@
|
|
1
|
+
import type { AnimationState } from "../../values/types";
|
2
|
+
export interface DecayConfig {
|
3
|
+
from?: number;
|
4
|
+
deceleration?: number;
|
5
|
+
velocityFactor?: number;
|
6
|
+
clamp?: number[];
|
7
|
+
velocity?: number;
|
8
|
+
}
|
9
|
+
export interface DefaultDecayConfig {
|
10
|
+
from: number;
|
11
|
+
deceleration: number;
|
12
|
+
velocityFactor: number;
|
13
|
+
clamp?: number[];
|
14
|
+
velocity: number;
|
15
|
+
}
|
16
|
+
export interface DecayState extends AnimationState {
|
17
|
+
lastTimestamp: number;
|
18
|
+
startTimestamp: number;
|
19
|
+
initialVelocity: number;
|
20
|
+
velocity: number;
|
21
|
+
}
|
@@ -0,0 +1,17 @@
|
|
1
|
+
export declare enum Extrapolate {
|
2
|
+
IDENTITY = "identity",
|
3
|
+
CLAMP = "clamp",
|
4
|
+
EXTEND = "extend"
|
5
|
+
}
|
6
|
+
export interface ExtrapolationConfig {
|
7
|
+
extrapolateLeft?: Extrapolate | string;
|
8
|
+
extrapolateRight?: Extrapolate | string;
|
9
|
+
}
|
10
|
+
interface RequiredExtrapolationConfig {
|
11
|
+
extrapolateLeft: Extrapolate;
|
12
|
+
extrapolateRight: Extrapolate;
|
13
|
+
}
|
14
|
+
export declare type ExtrapolationType = ExtrapolationConfig | Extrapolate | string | undefined;
|
15
|
+
export declare function validateInterpolationOptions(type: ExtrapolationType): RequiredExtrapolationConfig;
|
16
|
+
export declare function interpolate(x: number, input: readonly number[], output: readonly number[], type?: ExtrapolationType): number;
|
17
|
+
export {};
|
@@ -0,0 +1,19 @@
|
|
1
|
+
import type { SkPath } from "../../skia/types";
|
2
|
+
import type { ExtrapolationType } from "./interpolate";
|
3
|
+
/**
|
4
|
+
* Maps an input value within a range to an output path within a path range.
|
5
|
+
* @param value - The input value.
|
6
|
+
* @param inputRange - The range of the input value.
|
7
|
+
* @param outputRange - The range of the output path.
|
8
|
+
* @param options - Extrapolation options
|
9
|
+
* @returns The output path.
|
10
|
+
* @example <caption>Map a value between 0 and 1 to a path between two paths.</caption>
|
11
|
+
* const path1 = new Path();
|
12
|
+
* path1.moveTo(0, 0);
|
13
|
+
* path1.lineTo(100, 0);
|
14
|
+
* const path2 = new Path();
|
15
|
+
* path2.moveTo(0, 0);
|
16
|
+
* path2.lineTo(0, 100);
|
17
|
+
* const path = interpolatePath(0.5, [0, 1], [path1, path2]);
|
18
|
+
*/
|
19
|
+
export declare const interpolatePaths: (value: number, input: number[], outputRange: SkPath[], options?: ExtrapolationType) => SkPath;
|
@@ -0,0 +1,10 @@
|
|
1
|
+
import type { Vector } from "../../skia/types";
|
2
|
+
import { interpolate } from "./interpolate";
|
3
|
+
export declare const interpolateVector: (value: number, inputRange: readonly number[], outputRange: readonly Vector[], options?: Parameters<typeof interpolate>[3]) => {
|
4
|
+
x: number;
|
5
|
+
y: number;
|
6
|
+
};
|
7
|
+
export declare const mixVector: (value: number, from: Vector, to: Vector) => {
|
8
|
+
x: number;
|
9
|
+
y: number;
|
10
|
+
};
|
@@ -0,0 +1,65 @@
|
|
1
|
+
import type { SpringConfig } from "./types";
|
2
|
+
export declare const Spring: {
|
3
|
+
Config: {
|
4
|
+
Gentle: {
|
5
|
+
mass: number;
|
6
|
+
stiffness: number;
|
7
|
+
damping: number;
|
8
|
+
velocity: number;
|
9
|
+
};
|
10
|
+
Wobbly: {
|
11
|
+
mass: number;
|
12
|
+
stiffness: number;
|
13
|
+
damping: number;
|
14
|
+
velocity: number;
|
15
|
+
};
|
16
|
+
WobblySlow: {
|
17
|
+
mass: number;
|
18
|
+
stiffness: number;
|
19
|
+
damping: number;
|
20
|
+
velocity: number;
|
21
|
+
};
|
22
|
+
Stiff: {
|
23
|
+
mass: number;
|
24
|
+
stiffness: number;
|
25
|
+
damping: number;
|
26
|
+
velocity: number;
|
27
|
+
};
|
28
|
+
Default: {
|
29
|
+
mass: number;
|
30
|
+
stiffness: number;
|
31
|
+
damping: number;
|
32
|
+
velocity: number;
|
33
|
+
};
|
34
|
+
};
|
35
|
+
Gentle: (config?: SpringConfig) => {
|
36
|
+
mass: number;
|
37
|
+
stiffness: number;
|
38
|
+
velocity: number;
|
39
|
+
damping: number;
|
40
|
+
};
|
41
|
+
Wobbly: (config?: SpringConfig) => {
|
42
|
+
mass: number;
|
43
|
+
stiffness: number;
|
44
|
+
velocity: number;
|
45
|
+
damping: number;
|
46
|
+
};
|
47
|
+
WobblySlow: (config?: SpringConfig) => {
|
48
|
+
mass: number;
|
49
|
+
stiffness: number;
|
50
|
+
velocity: number;
|
51
|
+
damping: number;
|
52
|
+
};
|
53
|
+
Stiff: (config?: SpringConfig) => {
|
54
|
+
mass: number;
|
55
|
+
stiffness: number;
|
56
|
+
velocity: number;
|
57
|
+
damping: number;
|
58
|
+
};
|
59
|
+
Default: (config?: SpringConfig) => {
|
60
|
+
mass: number;
|
61
|
+
stiffness: number;
|
62
|
+
velocity: number;
|
63
|
+
damping: number;
|
64
|
+
};
|
65
|
+
};
|
@@ -0,0 +1 @@
|
|
1
|
+
export { createSpringEasing } from "./spring";
|
@@ -0,0 +1,10 @@
|
|
1
|
+
import type { SpringConfig } from "../types";
|
2
|
+
import type { TimingConfig } from "../../types";
|
3
|
+
/**
|
4
|
+
* @description Returns a cached jsContext function for a spring with duration
|
5
|
+
* @param mass The mass of the spring
|
6
|
+
* @param stiffness The stiffness of the spring
|
7
|
+
* @param damping Spring damping
|
8
|
+
* @param velocity The initial velocity
|
9
|
+
*/
|
10
|
+
export declare const createSpringEasing: (params: Partial<SpringConfig>) => TimingConfig;
|
@@ -0,0 +1,16 @@
|
|
1
|
+
import type { SkiaMutableValue, SkiaAnimation } from "../../values/types";
|
2
|
+
import type { AnimationParams, SpringConfig, AnimationCallback } from "../types";
|
3
|
+
/**
|
4
|
+
* Creates a new animation on an existing value that will be driven by
|
5
|
+
* an animation value. The value will be run from / to the value in
|
6
|
+
* params and modified by the provided easing curve for the length of
|
7
|
+
* the duration. When the value has reached its desired "to" value the
|
8
|
+
* animation will be stopped.
|
9
|
+
*
|
10
|
+
* @param value The value to animate
|
11
|
+
* @param toOrParams To value or Animation parameters
|
12
|
+
* @param config Spring configuration
|
13
|
+
* @returns an animation value that can be used to start/stop
|
14
|
+
* the animation.
|
15
|
+
*/
|
16
|
+
export declare const runSpring: (value: SkiaMutableValue<number>, toOrParams: number | AnimationParams, config?: SpringConfig, callback?: AnimationCallback) => SkiaAnimation;
|
@@ -0,0 +1,10 @@
|
|
1
|
+
import type { SkiaValue } from "../../values/types";
|
2
|
+
import type { SpringConfig, AnimationParams, AnimationCallback } from "../types";
|
3
|
+
/**
|
4
|
+
* Creats a spring based animation value that will run whenever
|
5
|
+
* the animation parameters change.
|
6
|
+
* @param toOrParams
|
7
|
+
* @param config
|
8
|
+
* @returns
|
9
|
+
*/
|
10
|
+
export declare const useSpring: (toOrParams: number | AnimationParams, config?: SpringConfig, callback?: AnimationCallback) => SkiaValue<number>;
|
@@ -0,0 +1,19 @@
|
|
1
|
+
export declare class Easing {
|
2
|
+
static step0(n: number): number;
|
3
|
+
static step1(n: number): number;
|
4
|
+
static linear(t: number): number;
|
5
|
+
static ease(t: number): number;
|
6
|
+
static quad(t: number): number;
|
7
|
+
static cubic(t: number): number;
|
8
|
+
static poly(n: number): (t: number) => number;
|
9
|
+
static sin(t: number): number;
|
10
|
+
static circle(t: number): number;
|
11
|
+
static exp(t: number): number;
|
12
|
+
static elastic(bounciness?: number): (t: number) => number;
|
13
|
+
static back(s?: number): (t: number) => number;
|
14
|
+
static bounce(t: number): number;
|
15
|
+
static bezier(x1: number, y1: number, x2: number, y2: number): (t: number) => number;
|
16
|
+
static in(easing: (t: number) => number): (t: number) => number;
|
17
|
+
static out(easing: (t: number) => number): (t: number) => number;
|
18
|
+
static inOut(easing: (t: number) => number): (t: number) => number;
|
19
|
+
}
|
@@ -0,0 +1,17 @@
|
|
1
|
+
import type { TimingConfig, RequiredAnimationParams, AnimationCallback } from "../types";
|
2
|
+
import type { SkiaMutableValue } from "../../values/types";
|
3
|
+
/**
|
4
|
+
* Creates an animation that is driven by a clock value.
|
5
|
+
* The value will be run from / to the value in params and modified
|
6
|
+
* by the provided easing curve for the length of the duration. When
|
7
|
+
* the value has reached its desired "to" value the animation
|
8
|
+
* will be stopped. If loop is set to true, the animation will continue
|
9
|
+
* to run until stopped.
|
10
|
+
*
|
11
|
+
* @param params Animation parameters
|
12
|
+
* @param config Spring or timing configuration
|
13
|
+
* @param value Optional value that the animation will update
|
14
|
+
* @params an animation value that can be used to start/stop
|
15
|
+
* the animation.
|
16
|
+
*/
|
17
|
+
export declare const createTiming: (params: RequiredAnimationParams & Required<TimingConfig>, value?: SkiaMutableValue<number>, callback?: AnimationCallback) => import("../../values/types").SkiaAnimation;
|
@@ -0,0 +1 @@
|
|
1
|
+
export declare function bezier(mX1: number, mY1: number, mX2: number, mY2: number): (x: number) => number;
|
@@ -0,0 +1,7 @@
|
|
1
|
+
import type { RequiredAnimationParams, AnimationParams, TimingConfig } from "../../types";
|
2
|
+
/**
|
3
|
+
* Resolves parameters from optional values to a single object
|
4
|
+
* @param toOrParams Params or to value
|
5
|
+
* @param config timing/spring configuration
|
6
|
+
*/
|
7
|
+
export declare const getResolvedParams: (toOrParams: number | AnimationParams, config?: TimingConfig) => RequiredAnimationParams & Required<TimingConfig>;
|
@@ -0,0 +1,17 @@
|
|
1
|
+
import type { AnimationState } from "../../../values/types";
|
2
|
+
/**
|
3
|
+
* Calculates and returns a timing value based on the
|
4
|
+
* input parameters. The timing value is a number between
|
5
|
+
* 0 and 1.
|
6
|
+
* @param t
|
7
|
+
* @param duration
|
8
|
+
* @param easing
|
9
|
+
* @param loop
|
10
|
+
* @param yoyo
|
11
|
+
* @param onStop
|
12
|
+
* @returns
|
13
|
+
*/
|
14
|
+
export declare const timing: (t: number, duration: number, easing: (t: number) => number, loop: boolean, yoyo: boolean, state: AnimationState) => {
|
15
|
+
current: number;
|
16
|
+
finished: boolean;
|
17
|
+
};
|
@@ -0,0 +1,16 @@
|
|
1
|
+
import type { SkiaMutableValue, SkiaAnimation } from "../../values/types";
|
2
|
+
import type { AnimationParams, TimingConfig, AnimationCallback } from "../types";
|
3
|
+
/**
|
4
|
+
* Creates a new animation on an existing value that will be driven by
|
5
|
+
* an animation value. The value will be run from / to the value in
|
6
|
+
* params and modified by the provided easing curve for the length of
|
7
|
+
* the duration. When the value has reached its desired "to" value the
|
8
|
+
* animation will be stopped.
|
9
|
+
*
|
10
|
+
* @param value The value to animate
|
11
|
+
* @param toOrParams To value or Animation parameters
|
12
|
+
* @param config Spring or timing configuration
|
13
|
+
* @returns an animation value that can be used to start/stop
|
14
|
+
* the animation.
|
15
|
+
*/
|
16
|
+
export declare const runTiming: (value: SkiaMutableValue<number>, toOrParams: number | AnimationParams, config?: TimingConfig, callback?: AnimationCallback) => SkiaAnimation;
|
@@ -0,0 +1,8 @@
|
|
1
|
+
import type { TimingConfig } from "../types";
|
2
|
+
/**
|
3
|
+
* Configures a looped timing value. The value will go back and forth
|
4
|
+
* between 0 and 1 and back.
|
5
|
+
* @param config Timing configuration for easing and duration
|
6
|
+
* @returns A value that can be used for further animations
|
7
|
+
*/
|
8
|
+
export declare const useLoop: (config?: TimingConfig) => import("../..").SkiaValue<number>;
|
@@ -0,0 +1,10 @@
|
|
1
|
+
import type { SkiaValue } from "../../values/types";
|
2
|
+
import type { AnimationParams, TimingConfig, AnimationCallback } from "../types";
|
3
|
+
/**
|
4
|
+
* Creats an animation value that will run whenever
|
5
|
+
* the animation parameters change. The animation start immediately.
|
6
|
+
* @param toOrParams
|
7
|
+
* @param config
|
8
|
+
* @returns A value that is animated
|
9
|
+
*/
|
10
|
+
export declare const useTiming: (toOrParams: number | AnimationParams, config?: TimingConfig, callback?: AnimationCallback) => SkiaValue<number>;
|
@@ -0,0 +1,18 @@
|
|
1
|
+
export interface SpringConfig {
|
2
|
+
mass?: number;
|
3
|
+
stiffness?: number;
|
4
|
+
damping?: number;
|
5
|
+
velocity?: number;
|
6
|
+
}
|
7
|
+
export interface TimingConfig {
|
8
|
+
duration?: number;
|
9
|
+
easing?: (t: number) => number;
|
10
|
+
}
|
11
|
+
export interface AnimationParams {
|
12
|
+
from?: number;
|
13
|
+
to?: number;
|
14
|
+
loop?: boolean;
|
15
|
+
yoyo?: boolean;
|
16
|
+
}
|
17
|
+
export declare type RequiredAnimationParams = Required<Omit<AnimationParams, "from">> & Pick<AnimationParams, "from">;
|
18
|
+
export declare type AnimationCallback = (current: number) => void;
|