@shopify/react-native-skia 2.5.4 → 2.5.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/src/main/java/com/shopify/reactnative/skia/WebGPUViewManager.java +7 -7
- package/apple/{WebGPUView.h → SkiaWebGPUView.h} +1 -1
- package/apple/{WebGPUView.mm → SkiaWebGPUView.mm} +7 -7
- package/lib/commonjs/specs/WebGPUViewNativeComponent.js +1 -1
- package/lib/commonjs/specs/WebGPUViewNativeComponent.js.map +1 -1
- package/lib/module/specs/WebGPUViewNativeComponent.js +1 -1
- package/lib/module/specs/WebGPUViewNativeComponent.js.map +1 -1
- package/package.json +2 -2
- package/src/specs/WebGPUViewNativeComponent.ts +1 -1
|
@@ -5,24 +5,24 @@ import com.facebook.react.uimanager.ThemedReactContext;
|
|
|
5
5
|
import com.facebook.react.uimanager.annotations.ReactProp;
|
|
6
6
|
import com.facebook.react.views.view.ReactViewGroup;
|
|
7
7
|
import com.facebook.react.views.view.ReactViewManager;
|
|
8
|
-
import com.facebook.react.viewmanagers.
|
|
9
|
-
import com.facebook.react.viewmanagers.
|
|
8
|
+
import com.facebook.react.viewmanagers.SkiaWebGPUViewManagerDelegate;
|
|
9
|
+
import com.facebook.react.viewmanagers.SkiaWebGPUViewManagerInterface;
|
|
10
10
|
|
|
11
11
|
import androidx.annotation.NonNull;
|
|
12
12
|
import androidx.annotation.Nullable;
|
|
13
13
|
|
|
14
14
|
@ReactModule(name = WebGPUViewManager.NAME)
|
|
15
|
-
public class WebGPUViewManager extends ReactViewManager implements
|
|
15
|
+
public class WebGPUViewManager extends ReactViewManager implements SkiaWebGPUViewManagerInterface<WebGPUView> {
|
|
16
16
|
|
|
17
|
-
public static final String NAME = "
|
|
17
|
+
public static final String NAME = "SkiaWebGPUView";
|
|
18
18
|
|
|
19
|
-
protected
|
|
19
|
+
protected SkiaWebGPUViewManagerDelegate mDelegate;
|
|
20
20
|
|
|
21
21
|
public WebGPUViewManager() {
|
|
22
|
-
mDelegate = new
|
|
22
|
+
mDelegate = new SkiaWebGPUViewManagerDelegate(this);
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
protected
|
|
25
|
+
protected SkiaWebGPUViewManagerDelegate getDelegate() {
|
|
26
26
|
return mDelegate;
|
|
27
27
|
}
|
|
28
28
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
#ifdef RCT_NEW_ARCH_ENABLED
|
|
2
2
|
|
|
3
|
-
#import "
|
|
3
|
+
#import "SkiaWebGPUView.h"
|
|
4
4
|
|
|
5
5
|
#import <react/renderer/components/rnskia/ComponentDescriptors.h>
|
|
6
6
|
#import <react/renderer/components/rnskia/EventEmitters.h>
|
|
@@ -12,18 +12,18 @@
|
|
|
12
12
|
|
|
13
13
|
using namespace facebook::react;
|
|
14
14
|
|
|
15
|
-
@implementation
|
|
15
|
+
@implementation SkiaWebGPUView
|
|
16
16
|
|
|
17
17
|
- (instancetype)initWithFrame:(CGRect)frame {
|
|
18
18
|
if (self = [super initWithFrame:frame]) {
|
|
19
|
-
static const auto defaultProps = std::make_shared<const
|
|
19
|
+
static const auto defaultProps = std::make_shared<const SkiaWebGPUViewProps>();
|
|
20
20
|
_props = defaultProps;
|
|
21
21
|
}
|
|
22
22
|
return self;
|
|
23
23
|
}
|
|
24
24
|
|
|
25
25
|
+ (ComponentDescriptorProvider)componentDescriptorProvider {
|
|
26
|
-
return concreteComponentDescriptorProvider<
|
|
26
|
+
return concreteComponentDescriptorProvider<SkiaWebGPUViewComponentDescriptor>();
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
- (void)prepareForRecycle {
|
|
@@ -46,9 +46,9 @@ using namespace facebook::react;
|
|
|
46
46
|
- (void)updateProps:(const Props::Shared &)props
|
|
47
47
|
oldProps:(const Props::Shared &)oldProps {
|
|
48
48
|
const auto &oldViewProps =
|
|
49
|
-
*std::static_pointer_cast<const
|
|
49
|
+
*std::static_pointer_cast<const SkiaWebGPUViewProps>(_props);
|
|
50
50
|
const auto &newViewProps =
|
|
51
|
-
*std::static_pointer_cast<const
|
|
51
|
+
*std::static_pointer_cast<const SkiaWebGPUViewProps>(props);
|
|
52
52
|
|
|
53
53
|
if (newViewProps.contextId != oldViewProps.contextId) {
|
|
54
54
|
/*
|
|
@@ -72,6 +72,6 @@ using namespace facebook::react;
|
|
|
72
72
|
|
|
73
73
|
@end
|
|
74
74
|
|
|
75
|
-
Class<RCTComponentViewProtocol>
|
|
75
|
+
Class<RCTComponentViewProtocol> SkiaWebGPUViewCls(void) { return SkiaWebGPUView.class; }
|
|
76
76
|
|
|
77
77
|
#endif // RCT_NEW_ARCH_ENABLED
|
|
@@ -7,5 +7,5 @@ exports.default = void 0;
|
|
|
7
7
|
var _codegenNativeComponent = _interopRequireDefault(require("react-native/Libraries/Utilities/codegenNativeComponent"));
|
|
8
8
|
function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e }; }
|
|
9
9
|
// eslint-disable-next-line import/no-default-export
|
|
10
|
-
var _default = exports.default = (0, _codegenNativeComponent.default)("
|
|
10
|
+
var _default = exports.default = (0, _codegenNativeComponent.default)("SkiaWebGPUView");
|
|
11
11
|
//# sourceMappingURL=WebGPUViewNativeComponent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_codegenNativeComponent","_interopRequireDefault","require","e","__esModule","default","_default","exports","codegenNativeComponent"],"sources":["WebGPUViewNativeComponent.ts"],"sourcesContent":["import codegenNativeComponent from \"react-native/Libraries/Utilities/codegenNativeComponent\";\nimport type { Int32 } from \"react-native/Libraries/Types/CodegenTypes\";\nimport type { ViewProps } from \"react-native\";\n\nexport interface NativeProps extends ViewProps {\n contextId: Int32;\n transparent: boolean;\n}\n\n// eslint-disable-next-line import/no-default-export\nexport default codegenNativeComponent<NativeProps>(\"
|
|
1
|
+
{"version":3,"names":["_codegenNativeComponent","_interopRequireDefault","require","e","__esModule","default","_default","exports","codegenNativeComponent"],"sources":["WebGPUViewNativeComponent.ts"],"sourcesContent":["import codegenNativeComponent from \"react-native/Libraries/Utilities/codegenNativeComponent\";\nimport type { Int32 } from \"react-native/Libraries/Types/CodegenTypes\";\nimport type { ViewProps } from \"react-native\";\n\nexport interface NativeProps extends ViewProps {\n contextId: Int32;\n transparent: boolean;\n}\n\n// eslint-disable-next-line import/no-default-export\nexport default codegenNativeComponent<NativeProps>(\"SkiaWebGPUView\");\n"],"mappings":";;;;;;AAAA,IAAAA,uBAAA,GAAAC,sBAAA,CAAAC,OAAA;AAA6F,SAAAD,uBAAAE,CAAA,WAAAA,CAAA,IAAAA,CAAA,CAAAC,UAAA,GAAAD,CAAA,KAAAE,OAAA,EAAAF,CAAA;AAS7F;AAAA,IAAAG,QAAA,GAAAC,OAAA,CAAAF,OAAA,GACe,IAAAG,+BAAsB,EAAc,gBAAgB,CAAC","ignoreList":[]}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import codegenNativeComponent from "react-native/Libraries/Utilities/codegenNativeComponent";
|
|
2
2
|
// eslint-disable-next-line import/no-default-export
|
|
3
|
-
export default codegenNativeComponent("
|
|
3
|
+
export default codegenNativeComponent("SkiaWebGPUView");
|
|
4
4
|
//# sourceMappingURL=WebGPUViewNativeComponent.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["codegenNativeComponent"],"sources":["WebGPUViewNativeComponent.ts"],"sourcesContent":["import codegenNativeComponent from \"react-native/Libraries/Utilities/codegenNativeComponent\";\nimport type { Int32 } from \"react-native/Libraries/Types/CodegenTypes\";\nimport type { ViewProps } from \"react-native\";\n\nexport interface NativeProps extends ViewProps {\n contextId: Int32;\n transparent: boolean;\n}\n\n// eslint-disable-next-line import/no-default-export\nexport default codegenNativeComponent<NativeProps>(\"
|
|
1
|
+
{"version":3,"names":["codegenNativeComponent"],"sources":["WebGPUViewNativeComponent.ts"],"sourcesContent":["import codegenNativeComponent from \"react-native/Libraries/Utilities/codegenNativeComponent\";\nimport type { Int32 } from \"react-native/Libraries/Types/CodegenTypes\";\nimport type { ViewProps } from \"react-native\";\n\nexport interface NativeProps extends ViewProps {\n contextId: Int32;\n transparent: boolean;\n}\n\n// eslint-disable-next-line import/no-default-export\nexport default codegenNativeComponent<NativeProps>(\"SkiaWebGPUView\");\n"],"mappings":"AAAA,OAAOA,sBAAsB,MAAM,yDAAyD;AAS5F;AACA,eAAeA,sBAAsB,CAAc,gBAAgB,CAAC","ignoreList":[]}
|
package/package.json
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"setup-skia-web": "scripts/setup-canvaskit.js"
|
|
10
10
|
},
|
|
11
11
|
"title": "React Native Skia",
|
|
12
|
-
"version": "2.5.
|
|
12
|
+
"version": "2.5.5",
|
|
13
13
|
"description": "High-performance React Native Graphics using Skia",
|
|
14
14
|
"main": "lib/module/index.js",
|
|
15
15
|
"react-native": "src/index.ts",
|
|
@@ -148,7 +148,7 @@
|
|
|
148
148
|
"ios": {
|
|
149
149
|
"componentProvider": {
|
|
150
150
|
"SkiaPictureView": "SkiaPictureView",
|
|
151
|
-
"
|
|
151
|
+
"SkiaWebGPUView": "SkiaWebGPUView"
|
|
152
152
|
}
|
|
153
153
|
}
|
|
154
154
|
},
|