react-native-seel-widget 0.1.4 → 0.1.7
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 +22 -23
- package/lib/module/assets/images/accredited.png +0 -0
- package/lib/module/assets/images/background_image.jpg +0 -0
- package/lib/module/assets/images/button_close.png +0 -0
- package/lib/module/assets/images/button_close_background.png +0 -0
- package/lib/module/assets/images/checkbox_normal.png +0 -0
- package/lib/module/assets/images/checkbox_selected.png +0 -0
- package/lib/module/assets/images/close_white.png +0 -0
- package/lib/module/assets/images/ic_launcher.png +0 -0
- package/lib/module/assets/images/icon_arrow_left.png +0 -0
- package/lib/module/assets/images/icon_bg_select.png +0 -0
- package/lib/module/assets/images/icon_check_selected_black.png +0 -0
- package/lib/module/assets/images/icon_select.png +0 -0
- package/lib/module/assets/images/info_black.png +0 -0
- package/lib/module/assets/images/seel_icon.png +0 -0
- package/lib/module/assets/images/seel_logo.png +0 -0
- package/lib/module/assets/images/seel_word.png +0 -0
- package/lib/module/assets/images/tick_small_minor.png +0 -0
- package/lib/module/constants/key_value.js +50 -0
- package/lib/module/constants/key_value.js.map +1 -0
- package/lib/module/constants/network_request_statue_enum.js +17 -0
- package/lib/module/constants/network_request_statue_enum.js.map +1 -0
- package/lib/module/core/SeelWidgetSDK.js +85 -0
- package/lib/module/core/SeelWidgetSDK.js.map +1 -0
- package/lib/module/dto/EventsRequest.js +71 -0
- package/lib/module/dto/EventsRequest.js.map +1 -0
- package/lib/module/dto/EventsResponse.js +15 -0
- package/lib/module/dto/EventsResponse.js.map +1 -0
- package/lib/module/dto/IEvents.js +31 -0
- package/lib/module/dto/IEvents.js.map +1 -0
- package/lib/module/dto/IQuotes.js +2 -0
- package/lib/module/dto/IQuotes.js.map +1 -0
- package/lib/module/dto/IQuotesRequest.js +4 -0
- package/lib/module/dto/IQuotesRequest.js.map +1 -0
- package/lib/module/dto/IQuotesResponse.js +2 -0
- package/lib/module/dto/IQuotesResponse.js.map +1 -0
- package/lib/module/index.js +6 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/network/request.js +194 -0
- package/lib/module/network/request.js.map +1 -0
- package/lib/module/package.json +1 -0
- package/lib/module/ui/coverage-info-footer.js +170 -0
- package/lib/module/ui/coverage-info-footer.js.map +1 -0
- package/lib/module/ui/gradient-animation-text.js +116 -0
- package/lib/module/ui/gradient-animation-text.js.map +1 -0
- package/lib/module/ui/gradient-animation-view.js +110 -0
- package/lib/module/ui/gradient-animation-view.js.map +1 -0
- package/lib/module/ui/index.js +7 -0
- package/lib/module/ui/index.js.map +1 -0
- package/lib/module/ui/seel-wfp-info-view.js +312 -0
- package/lib/module/ui/seel-wfp-info-view.js.map +1 -0
- package/lib/module/ui/seel-wfp-title-view.js +286 -0
- package/lib/module/ui/seel-wfp-title-view.js.map +1 -0
- package/lib/module/ui/seel-wfp-widget.js +224 -0
- package/lib/module/ui/seel-wfp-widget.js.map +1 -0
- package/lib/module/utils/format_util.js +107 -0
- package/lib/module/utils/format_util.js.map +1 -0
- package/lib/module/utils/http_util.js +27 -0
- package/lib/module/utils/http_util.js.map +1 -0
- package/lib/module/utils/storage_util.js +36 -0
- package/lib/module/utils/storage_util.js.map +1 -0
- package/lib/module/utils/uuid.js +21 -0
- package/lib/module/utils/uuid.js.map +1 -0
- package/lib/typescript/package.json +1 -0
- package/lib/typescript/src/constants/key_value.d.ts +48 -0
- package/lib/typescript/src/constants/key_value.d.ts.map +1 -0
- package/lib/typescript/src/constants/network_request_statue_enum.d.ts +13 -0
- package/lib/typescript/src/constants/network_request_statue_enum.d.ts.map +1 -0
- package/lib/typescript/src/core/SeelWidgetSDK.d.ts +52 -0
- package/lib/typescript/src/core/SeelWidgetSDK.d.ts.map +1 -0
- package/lib/typescript/src/dto/EventsRequest.d.ts +60 -0
- package/lib/typescript/src/dto/EventsRequest.d.ts.map +1 -0
- package/lib/typescript/src/dto/EventsResponse.d.ts +11 -0
- package/lib/typescript/src/dto/EventsResponse.d.ts.map +1 -0
- package/lib/typescript/src/dto/IEvents.d.ts +48 -0
- package/lib/typescript/src/dto/IEvents.d.ts.map +1 -0
- package/lib/typescript/src/dto/IQuotes.d.ts +36 -0
- package/lib/typescript/src/dto/IQuotes.d.ts.map +1 -0
- package/lib/typescript/src/dto/IQuotesRequest.d.ts +213 -0
- package/lib/typescript/src/dto/IQuotesRequest.d.ts.map +1 -0
- package/lib/typescript/src/dto/IQuotesResponse.d.ts +96 -0
- package/lib/typescript/src/dto/IQuotesResponse.d.ts.map +1 -0
- package/lib/typescript/src/index.d.ts +2 -0
- package/lib/typescript/src/index.d.ts.map +1 -0
- package/lib/typescript/src/network/request.d.ts +53 -0
- package/lib/typescript/src/network/request.d.ts.map +1 -0
- package/lib/typescript/src/ui/coverage-info-footer.d.ts +9 -0
- package/lib/typescript/src/ui/coverage-info-footer.d.ts.map +1 -0
- package/lib/typescript/src/ui/gradient-animation-text.d.ts +40 -0
- package/lib/typescript/src/ui/gradient-animation-text.d.ts.map +1 -0
- package/lib/typescript/src/ui/gradient-animation-view.d.ts +32 -0
- package/lib/typescript/src/ui/gradient-animation-view.d.ts.map +1 -0
- package/lib/typescript/src/ui/index.d.ts +5 -0
- package/lib/typescript/src/ui/index.d.ts.map +1 -0
- package/lib/typescript/src/ui/seel-wfp-info-view.d.ts +13 -0
- package/lib/typescript/src/ui/seel-wfp-info-view.d.ts.map +1 -0
- package/lib/typescript/src/ui/seel-wfp-title-view.d.ts +68 -0
- package/lib/typescript/src/ui/seel-wfp-title-view.d.ts.map +1 -0
- package/lib/typescript/src/ui/seel-wfp-widget.d.ts +16 -0
- package/lib/typescript/src/ui/seel-wfp-widget.d.ts.map +1 -0
- package/lib/typescript/src/utils/format_util.d.ts +2 -0
- package/lib/typescript/src/utils/format_util.d.ts.map +1 -0
- package/lib/typescript/src/utils/http_util.d.ts +18 -0
- package/lib/typescript/src/utils/http_util.d.ts.map +1 -0
- package/lib/typescript/src/utils/storage_util.d.ts +6 -0
- package/lib/typescript/src/utils/storage_util.d.ts.map +1 -0
- package/lib/typescript/src/utils/uuid.d.ts +6 -0
- package/lib/typescript/src/utils/uuid.d.ts.map +1 -0
- package/package.json +23 -12
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import type { TextStyle, ViewStyle } from 'react-native';
|
|
2
|
+
import { NetworkRequestStatueEnum } from '../constants/network_request_statue_enum';
|
|
3
|
+
export interface SeelWFPTitleViewProps {
|
|
4
|
+
status: string;
|
|
5
|
+
/**
|
|
6
|
+
* Title text to display
|
|
7
|
+
*/
|
|
8
|
+
title?: string;
|
|
9
|
+
/**
|
|
10
|
+
* Price text to display
|
|
11
|
+
*/
|
|
12
|
+
price?: string;
|
|
13
|
+
/**
|
|
14
|
+
* Custom container style
|
|
15
|
+
*/
|
|
16
|
+
containerStyle?: ViewStyle;
|
|
17
|
+
/**
|
|
18
|
+
* Custom container style for dark mode
|
|
19
|
+
*/
|
|
20
|
+
darkContainerStyle?: ViewStyle;
|
|
21
|
+
/**
|
|
22
|
+
* Custom container style for light mode
|
|
23
|
+
*/
|
|
24
|
+
lightContainerStyle?: ViewStyle;
|
|
25
|
+
/**
|
|
26
|
+
* Custom title text style
|
|
27
|
+
*/
|
|
28
|
+
titleStyle?: TextStyle;
|
|
29
|
+
/**
|
|
30
|
+
* Custom title text style for dark mode
|
|
31
|
+
*/
|
|
32
|
+
darkTitleStyle?: TextStyle;
|
|
33
|
+
/**
|
|
34
|
+
* Custom title text style for light mode
|
|
35
|
+
*/
|
|
36
|
+
lightTitleStyle?: TextStyle;
|
|
37
|
+
/**
|
|
38
|
+
* Custom price text style
|
|
39
|
+
*/
|
|
40
|
+
priceStyle?: TextStyle;
|
|
41
|
+
/**
|
|
42
|
+
* Custom price text style for dark mode
|
|
43
|
+
*/
|
|
44
|
+
darkPriceStyle?: TextStyle;
|
|
45
|
+
/**
|
|
46
|
+
* Custom price text style for light mode
|
|
47
|
+
*/
|
|
48
|
+
lightPriceStyle?: TextStyle;
|
|
49
|
+
/**
|
|
50
|
+
* Callback function when title is pressed
|
|
51
|
+
* @param route - Route name or path to navigate to
|
|
52
|
+
*/
|
|
53
|
+
onClickInfoIcon?: (route?: string) => void;
|
|
54
|
+
/**
|
|
55
|
+
* Route name or path for navigation (optional, can be used with onClickInfoIcon)
|
|
56
|
+
*/
|
|
57
|
+
route?: string;
|
|
58
|
+
/**
|
|
59
|
+
* Whether the title is pressable (default: true if onClickInfoIcon is provided)
|
|
60
|
+
*/
|
|
61
|
+
pressable?: boolean;
|
|
62
|
+
optedIn: boolean;
|
|
63
|
+
dictionary: any;
|
|
64
|
+
loadingStatue: NetworkRequestStatueEnum;
|
|
65
|
+
onChangeOptedInValue: (optedIn: boolean) => void;
|
|
66
|
+
}
|
|
67
|
+
export default function SeelWFPTitleView({ status, title, price, containerStyle, lightContainerStyle, darkContainerStyle, titleStyle, lightTitleStyle, darkTitleStyle, priceStyle, lightPriceStyle, darkPriceStyle, optedIn, dictionary, loadingStatue, onClickInfoIcon, onChangeOptedInValue, }: SeelWFPTitleViewProps): import("react/jsx-runtime").JSX.Element;
|
|
68
|
+
//# sourceMappingURL=seel-wfp-title-view.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"seel-wfp-title-view.d.ts","sourceRoot":"","sources":["../../../../src/ui/seel-wfp-title-view.tsx"],"names":[],"mappings":"AASA,OAAO,KAAK,EAAE,SAAS,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC;AAMzD,OAAO,EAAE,wBAAwB,EAAE,MAAM,0CAA0C,CAAC;AAEpF,MAAM,WAAW,qBAAqB;IACpC,MAAM,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,cAAc,CAAC,EAAE,SAAS,CAAC;IAC3B;;OAEG;IACH,kBAAkB,CAAC,EAAE,SAAS,CAAC;IAC/B;;OAEG;IACH,mBAAmB,CAAC,EAAE,SAAS,CAAC;IAChC;;OAEG;IACH,UAAU,CAAC,EAAE,SAAS,CAAC;IACvB;;OAEG;IACH,cAAc,CAAC,EAAE,SAAS,CAAC;IAC3B;;OAEG;IACH,eAAe,CAAC,EAAE,SAAS,CAAC;IAC5B;;OAEG;IACH,UAAU,CAAC,EAAE,SAAS,CAAC;IACvB;;OAEG;IACH,cAAc,CAAC,EAAE,SAAS,CAAC;IAC3B;;OAEG;IACH,eAAe,CAAC,EAAE,SAAS,CAAC;IAC5B;;;OAGG;IACH,eAAe,CAAC,EAAE,CAAC,KAAK,CAAC,EAAE,MAAM,KAAK,IAAI,CAAC;IAC3C;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,SAAS,CAAC,EAAE,OAAO,CAAC;IACpB,OAAO,EAAE,OAAO,CAAC;IACjB,UAAU,EAAE,GAAG,CAAC;IAChB,aAAa,EAAE,wBAAwB,CAAC;IACxC,oBAAoB,EAAE,CAAC,OAAO,EAAE,OAAO,KAAK,IAAI,CAAC;CAClD;AAED,MAAM,CAAC,OAAO,UAAU,gBAAgB,CAAC,EACvC,MAAM,EACN,KAAK,EACL,KAAK,EACL,cAAc,EACd,mBAAmB,EACnB,kBAAkB,EAClB,UAAU,EACV,eAAe,EACf,cAAc,EACd,UAAU,EACV,eAAe,EACf,cAAc,EACd,OAAe,EACf,UAAe,EACf,aAA6C,EAC7C,eAAe,EACf,oBAAyC,GAC1C,EAAE,qBAAqB,2CAmKvB"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { type Domain } from './seel-wfp-info-view';
|
|
2
|
+
import type { IQuotesRequest } from '../dto/IQuotesRequest';
|
|
3
|
+
import type IQuotesResponse from '../dto/IQuotesResponse';
|
|
4
|
+
export interface SeelWFPWidgetRef {
|
|
5
|
+
setup(quote: IQuotesRequest): void;
|
|
6
|
+
}
|
|
7
|
+
interface SeelWFPWidgetProps {
|
|
8
|
+
domain: Domain;
|
|
9
|
+
onChangeValue: ({ optedIn, quotesResponse, }: {
|
|
10
|
+
optedIn: boolean;
|
|
11
|
+
quotesResponse?: IQuotesResponse;
|
|
12
|
+
}) => void;
|
|
13
|
+
}
|
|
14
|
+
declare const _default: import("react").ForwardRefExoticComponent<SeelWFPWidgetProps & import("react").RefAttributes<SeelWFPWidgetRef>>;
|
|
15
|
+
export default _default;
|
|
16
|
+
//# sourceMappingURL=seel-wfp-widget.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"seel-wfp-widget.d.ts","sourceRoot":"","sources":["../../../../src/ui/seel-wfp-widget.tsx"],"names":[],"mappings":"AAUA,OAAwB,EAAE,KAAK,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAGpE,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAE5D,OAAO,KAAK,eAAe,MAAM,wBAAwB,CAAC;AAI1D,MAAM,WAAW,gBAAgB;IAC/B,KAAK,CAAC,KAAK,EAAE,cAAc,GAAG,IAAI,CAAC;CACpC;AAED,UAAU,kBAAkB;IAC1B,MAAM,EAAE,MAAM,CAAC;IACf,aAAa,EAAE,CAAC,EACd,OAAO,EACP,cAAc,GACf,EAAE;QACD,OAAO,EAAE,OAAO,CAAC;QACjB,cAAc,CAAC,EAAE,eAAe,CAAC;KAClC,KAAK,IAAI,CAAC;CACZ;;AA4OD,wBAA+E"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"format_util.d.ts","sourceRoot":"","sources":["../../../../src/utils/format_util.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,WAAW,GAAI,OAAO,GAAG,EAAE,UAAU,MAAM,EAAE,SAAS,GAAG,QAoHrE,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { IEvents } from '../dto/IEvents';
|
|
2
|
+
import type { IQuotesRequest } from '../dto/IQuotesRequest';
|
|
3
|
+
import type IQuotesResponse from '../dto/IQuotesResponse';
|
|
4
|
+
export declare enum NetworkErrorEnum {
|
|
5
|
+
InvalidURL = 0,
|
|
6
|
+
NoData = 1,
|
|
7
|
+
DecodingError = 2,
|
|
8
|
+
NetworkError = 3,
|
|
9
|
+
ServerError = 4,
|
|
10
|
+
/**
|
|
11
|
+
* Configuration error
|
|
12
|
+
*/
|
|
13
|
+
ConfigError = 5,
|
|
14
|
+
Unknown = 6
|
|
15
|
+
}
|
|
16
|
+
export declare const createQuote: (body: IQuotesRequest) => Promise<IQuotesResponse>;
|
|
17
|
+
export declare const createEvent: (body: IEvents) => Promise<IQuotesResponse>;
|
|
18
|
+
//# sourceMappingURL=http_util.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"http_util.d.ts","sourceRoot":"","sources":["../../../../src/utils/http_util.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,uBAAuB,CAAC;AAC5D,OAAO,KAAK,eAAe,MAAM,wBAAwB,CAAC;AAG1D,oBAAY,gBAAgB;IAC1B,UAAU,IAAA;IACV,MAAM,IAAA;IACN,aAAa,IAAA;IACb,YAAY,IAAA;IACZ,WAAW,IAAA;IACX;;OAEG;IACH,WAAW,IAAA;IACX,OAAO,IAAA;CACR;AAID,eAAO,MAAM,WAAW,GAAI,MAAM,cAAc,6BAG/C,CAAC;AAEF,eAAO,MAAM,WAAW,GAAI,MAAM,OAAO,6BAGxC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"storage_util.d.ts","sourceRoot":"","sources":["../../../../src/utils/storage_util.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,eAAe;;CAE3B,CAAC;AAUF,eAAO,MAAM,YAAY,GAAU,OAAO,OAAO,KAAG,OAAO,CAAC,IAAI,CAW/D,CAAC;AAEF,eAAO,MAAM,WAAW,QAAa,OAAO,CAAC,OAAO,CASnD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"uuid.d.ts","sourceRoot":"","sources":["../../../../src/utils/uuid.ts"],"names":[],"mappings":"AACA;;;GAGG;AACH,wBAAgB,UAAU,IAAI,MAAM,CAYnC"}
|
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "react-native-seel-widget",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.7",
|
|
4
4
|
"description": "React-Native SeelWidget",
|
|
5
|
+
"main": "./src/index.tsx",
|
|
5
6
|
"exports": {
|
|
6
7
|
".": {
|
|
7
8
|
"source": "./src/index.tsx",
|
|
@@ -32,7 +33,6 @@
|
|
|
32
33
|
"scripts": {
|
|
33
34
|
"example": "yarn workspace react-native-seel-widget-example",
|
|
34
35
|
"clean": "del-cli lib",
|
|
35
|
-
"prepare": "bob build",
|
|
36
36
|
"typecheck": "tsc",
|
|
37
37
|
"lint": "eslint \"**/*.{js,ts,tsx}\"",
|
|
38
38
|
"test": "jest",
|
|
@@ -47,11 +47,12 @@
|
|
|
47
47
|
"type": "git",
|
|
48
48
|
"url": "git+https://github.com/seelinc/react-native-seel-widget.git"
|
|
49
49
|
},
|
|
50
|
-
"
|
|
50
|
+
"author": "qingmingzhang <qingming.zhang@seel.com> (https://github.com/seelinc)",
|
|
51
|
+
"license": "MIT",
|
|
51
52
|
"bugs": {
|
|
52
53
|
"url": "https://github.com/seelinc/react-native-seel-widget/issues"
|
|
53
54
|
},
|
|
54
|
-
"
|
|
55
|
+
"homepage": "https://github.com/seelinc/react-native-seel-widget#readme",
|
|
55
56
|
"publishConfig": {
|
|
56
57
|
"registry": "https://registry.npmjs.org/"
|
|
57
58
|
},
|
|
@@ -87,6 +88,24 @@
|
|
|
87
88
|
"example"
|
|
88
89
|
],
|
|
89
90
|
"packageManager": "yarn@4.11.0",
|
|
91
|
+
"react-native-builder-bob": {
|
|
92
|
+
"source": "src",
|
|
93
|
+
"output": "lib",
|
|
94
|
+
"targets": [
|
|
95
|
+
[
|
|
96
|
+
"module",
|
|
97
|
+
{
|
|
98
|
+
"esm": true
|
|
99
|
+
}
|
|
100
|
+
],
|
|
101
|
+
[
|
|
102
|
+
"typescript",
|
|
103
|
+
{
|
|
104
|
+
"project": "tsconfig.build.json"
|
|
105
|
+
}
|
|
106
|
+
]
|
|
107
|
+
]
|
|
108
|
+
},
|
|
90
109
|
"prettier": {
|
|
91
110
|
"quoteProps": "consistent",
|
|
92
111
|
"singleQuote": true,
|
|
@@ -138,13 +157,5 @@
|
|
|
138
157
|
},
|
|
139
158
|
"dependencies": {
|
|
140
159
|
"@react-native-async-storage/async-storage": "^2.2.0"
|
|
141
|
-
},
|
|
142
|
-
"author": "qingming.zhang",
|
|
143
|
-
"main": "./src/index.tsx",
|
|
144
|
-
"directories": {
|
|
145
|
-
"example": "example"
|
|
146
|
-
},
|
|
147
|
-
"scripts": {
|
|
148
|
-
"test": "jest"
|
|
149
160
|
}
|
|
150
161
|
}
|