@soyio/soyio-widget 0.0.35 → 0.0.37
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 +8 -6
- package/dist/index.js +740 -740
- package/dist/index.umd.cjs +9 -9
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -40,7 +40,7 @@ Integrate the widget into your frontend framework using the script below. Ensure
|
|
|
40
40
|
flowTemplateId: "<flow template id>",
|
|
41
41
|
identityId: "<identity id>",
|
|
42
42
|
},
|
|
43
|
-
onEvent: (data) => console.log(
|
|
43
|
+
onEvent: (data) => console.log(data),
|
|
44
44
|
isSandbox: true,
|
|
45
45
|
};
|
|
46
46
|
|
|
@@ -49,10 +49,6 @@ Integrate the widget into your frontend framework using the script below. Ensure
|
|
|
49
49
|
new Widget(widgetConfig);
|
|
50
50
|
});
|
|
51
51
|
</script>
|
|
52
|
-
|
|
53
|
-
<body>
|
|
54
|
-
<div id="soyio-widget-iframe-container"></div>
|
|
55
|
-
</body>
|
|
56
52
|
```
|
|
57
53
|
|
|
58
54
|
#### Attribute Descriptions
|
|
@@ -64,7 +60,7 @@ Integrate the widget into your frontend framework using the script below. Ensure
|
|
|
64
60
|
- **`flowTemplateId`**: : Required only in the `'register'` flow, this identifier specifies the order and quantity of documents requested from the user. It must start with `'vft_'`.
|
|
65
61
|
- **`identityId`**: Necessary only in the `'authenticate'` flow, this identifier must start with `'id_'` and signifies the user's identity.
|
|
66
62
|
- **`onEvent`**: A callback function triggered upon event occurrences, used for capturing and logging event-related data.
|
|
67
|
-
- **`isSandbox`**: (Optional) Indicates if the widget should operate in sandbox mode, defaulting to false
|
|
63
|
+
- **`isSandbox`**: (Optional) Indicates if the widget should operate in sandbox mode, defaulting to `false`.
|
|
68
64
|
|
|
69
65
|
#### Events
|
|
70
66
|
|
|
@@ -80,3 +76,9 @@ The `onEvent` callback is designed to handle various events that occur during wi
|
|
|
80
76
|
- `eventName`: The name of the event, here `'IDENTITY_AUTHENTICATED'`.
|
|
81
77
|
- `identityId`: The unique identifier for the authenticated identity.
|
|
82
78
|
- `userReference`: The reference identifier for the user, facilitating the association of the event with the user within the company's context.
|
|
79
|
+
|
|
80
|
+
- **`WIDGET_CLOSED`**: This events occurs when user closes the `Soyio` pop up. The event object is as follow:
|
|
81
|
+
- `{ eventName: 'WIDGET_CLOSED' }`.
|
|
82
|
+
|
|
83
|
+
- **`WIDGET_OPENED`**: This events occurs when user closes the `Soyio` pop up. The event object is as follow:
|
|
84
|
+
- `{ eventName: 'WIDGET_CLOSED' }`.
|