sonic-widget 2.1.3 → 2.1.4
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/README.md +9 -3
- package/dist/index.js +1464 -1464
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
Use this script tag to get access to the widget:
|
|
17
17
|
|
|
18
18
|
```html
|
|
19
|
-
<script src="https://cdn.jsdelivr.net/npm/sonic-widget@2.1.
|
|
19
|
+
<script src="https://cdn.jsdelivr.net/npm/sonic-widget@2.1.4/dist/index.min.js"></script>
|
|
20
20
|
```
|
|
21
21
|
|
|
22
22
|
or
|
|
@@ -43,7 +43,7 @@ and adding path in `angular.json`
|
|
|
43
43
|
2. Use this script tag to get access to the widget at initial html page:
|
|
44
44
|
|
|
45
45
|
```html
|
|
46
|
-
<script src="https://cdn.jsdelivr.net/npm/sonic-widget@2.1.
|
|
46
|
+
<script src="https://cdn.jsdelivr.net/npm/sonic-widget@2.1.4/dist/index.min.js"></script>
|
|
47
47
|
```
|
|
48
48
|
|
|
49
49
|
or
|
|
@@ -79,6 +79,8 @@ ngOnInit(): void {
|
|
|
79
79
|
|
|
80
80
|
const config = {
|
|
81
81
|
baseurl: string, // the base url of the backend server
|
|
82
|
+
docModelUrl: string, // the doc model url of the document recognition process
|
|
83
|
+
maskModelUrl: string, // the mask model url of the mask detect process
|
|
82
84
|
showPage: boolean, // used to show the page or not
|
|
83
85
|
ipInfoKey: string, // api key to detect vpn used or not from "ipInfo.io" (Optional)
|
|
84
86
|
videoURL: string, // url of video to do (e.g: demo doing kyc) (Optional)
|
|
@@ -128,7 +130,7 @@ ngOnInit(): void {
|
|
|
128
130
|
4. Add a Script tag to the head tag or body tag. And use the latest version.
|
|
129
131
|
|
|
130
132
|
```html
|
|
131
|
-
<script src="https://cdn.jsdelivr.net/npm/sonic-widget@2.1.
|
|
133
|
+
<script src="https://cdn.jsdelivr.net/npm/sonic-widget@2.1.4/dist/index.min.js"></script>
|
|
132
134
|
```
|
|
133
135
|
|
|
134
136
|
5. Next, add the script tag at a necessary place. But add below the widget script.
|
|
@@ -137,6 +139,8 @@ ngOnInit(): void {
|
|
|
137
139
|
<script>
|
|
138
140
|
const config = {
|
|
139
141
|
baseurl: string, // the base url of the backend server
|
|
142
|
+
docModelUrl: string, // the doc model url of the document recognition process
|
|
143
|
+
maskModelUrl: string, // the mask model url of the mask detect process
|
|
140
144
|
showPage: boolean, // used to show the page or not
|
|
141
145
|
ipInfoKey: string, // api key to detect vpn used or not from "ipInfo.io" (Optional)
|
|
142
146
|
videoURL: string, // url of video to do (e.g: demo doing kyc) (Optional)
|
|
@@ -181,6 +185,8 @@ Check with **`data.code`**_
|
|
|
181
185
|
**Note:-**
|
|
182
186
|
|
|
183
187
|
- _**`baseurl`** should pass as a string value. It is used as the base URL for API calls._
|
|
188
|
+
- _**`docModelUrl`** should pass as a string value. It is used as the base URL for document model._
|
|
189
|
+
- _**`maskModelUrl`** should pass as a string value. It is used as the base URL for mask model._
|
|
184
190
|
- _**`showPage`** is used to pass a boolean value ( **`true`** or **`false`** ). To toggle the widget page open or close._
|
|
185
191
|
- _**`ipInfoKey`** should pass as a string value. It is used to detect whether vpn is used or not from "ipInfo.io" with this api key and it is optional._
|
|
186
192
|
- _**`videoURL`** should pass as a string value as url. It is used to show the video onboard sonic kyc and it is optional._
|