react-native-seel-widget 0.1.9 → 0.1.11
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/LICENSE +1 -1
- package/README.md +11 -2
- package/package.json +8 -7
- package/src/ui/seel-wfp-title-view.tsx +4 -1
package/LICENSE
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
MIT License
|
|
2
2
|
|
|
3
|
-
Copyright (c) 2025
|
|
3
|
+
Copyright (c) 2025 qingmingzhang
|
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
|
6
6
|
in the Software without restriction, including without limitation the rights
|
package/README.md
CHANGED
|
@@ -41,11 +41,20 @@ SeelWidgetSDK.shared.configure({
|
|
|
41
41
|
import type { IQuotesRequest, IQuotesResponse } from 'react-native-seel-widget';
|
|
42
42
|
import { SeelWFPWidget } from 'react-native-seel-widget';
|
|
43
43
|
|
|
44
|
+
const quoteEU: IQuotesRequest = {};
|
|
45
|
+
const quoteUS: IQuotesRequest = {};
|
|
44
46
|
export default function YourPage() {
|
|
47
|
+
const [domain, setDomain] = useState<Domain>('');
|
|
48
|
+
const initialRef: any = null;
|
|
49
|
+
const seelWidgetRef = useRef<any>(initialRef);
|
|
45
50
|
useEffect(() => {
|
|
46
|
-
const
|
|
47
|
-
|
|
51
|
+
const setup = () => {
|
|
52
|
+
if (seelWidgetRef.current) {
|
|
53
|
+
const quote = domain === 'EU' ? quoteEU : quoteUS;
|
|
54
|
+
seelWidgetRef.current.setup(quote);
|
|
55
|
+
}
|
|
48
56
|
};
|
|
57
|
+
setup();
|
|
49
58
|
});
|
|
50
59
|
|
|
51
60
|
return (
|
package/package.json
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native-seel-widget",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "React
|
|
5
|
-
"main": "./
|
|
3
|
+
"version": "0.1.11",
|
|
4
|
+
"description": "React Native Seel Widget",
|
|
5
|
+
"main": "./lib/module/index.js",
|
|
6
|
+
"types": "./lib/typescript/src/index.d.ts",
|
|
6
7
|
"exports": {
|
|
7
8
|
".": {
|
|
8
9
|
"source": "./src/index.tsx",
|
|
@@ -45,14 +46,14 @@
|
|
|
45
46
|
],
|
|
46
47
|
"repository": {
|
|
47
48
|
"type": "git",
|
|
48
|
-
"url": "git+https://github.com/
|
|
49
|
+
"url": "git+https://github.com/kover-ai/react-native-seel-widget.git"
|
|
49
50
|
},
|
|
50
|
-
"author": "qingmingzhang <qingming.zhang@seel.com> (https://github.com/
|
|
51
|
+
"author": "qingmingzhang <qingming.zhang@seel.com> (https://github.com/kover-ai)",
|
|
51
52
|
"license": "MIT",
|
|
52
53
|
"bugs": {
|
|
53
|
-
"url": "https://github.com/
|
|
54
|
+
"url": "https://github.com/kover-ai/react-native-seel-widget/issues"
|
|
54
55
|
},
|
|
55
|
-
"homepage": "https://github.com/
|
|
56
|
+
"homepage": "https://github.com/kover-ai/react-native-seel-widget#readme",
|
|
56
57
|
"publishConfig": {
|
|
57
58
|
"registry": "https://registry.npmjs.org/"
|
|
58
59
|
},
|
|
@@ -187,7 +187,10 @@ export default function SeelWFPTitleView({
|
|
|
187
187
|
<TouchableOpacity
|
|
188
188
|
hitSlop={{ top: 8, right: 8, bottom: 8, left: 8 }}
|
|
189
189
|
onPress={() => {
|
|
190
|
-
|
|
190
|
+
// eslint-disable-next-line no-bitwise
|
|
191
|
+
if ((loadingStatue & NetworkRequestStatueEnum.Success) !== 0) {
|
|
192
|
+
onChangeOptedInValue(!optedIn);
|
|
193
|
+
}
|
|
191
194
|
}}
|
|
192
195
|
>
|
|
193
196
|
<Image
|