@inappstory/react-sdk 1.9.4 → 1.9.6
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/dist/index.esm.mjs +887 -1000
- package/dist/index.esm.mjs.map +1 -1
- package/dist/index.umd.js +2 -2
- package/dist/types/events.d.ts +0 -10
- package/dist/types/ias-container/storyManagerEventsProps.d.ts +0 -7
- package/dist/types/in-app-messaging/inAppMessaging.d.ts +6 -2
- package/package.json +2 -2
- package/plugins/banners/index.esm.mjs +1 -1
package/dist/types/events.d.ts
CHANGED
|
@@ -154,14 +154,6 @@ export interface CloseGameEvent {
|
|
|
154
154
|
id: string;
|
|
155
155
|
}
|
|
156
156
|
|
|
157
|
-
/** Event: mini-game finished */
|
|
158
|
-
export interface FinishGameEvent {
|
|
159
|
-
/** Game ID */
|
|
160
|
-
id: string;
|
|
161
|
-
/** Game result */
|
|
162
|
-
result: Record<string, any>;
|
|
163
|
-
}
|
|
164
|
-
|
|
165
157
|
/** Generic game event */
|
|
166
158
|
export interface EventGameEvent {
|
|
167
159
|
/** Event name */
|
|
@@ -215,8 +207,6 @@ export interface StoryManagerEvents {
|
|
|
215
207
|
startGame: StartGameEvent;
|
|
216
208
|
/** Game closed */
|
|
217
209
|
closeGame: CloseGameEvent;
|
|
218
|
-
/** Game finished */
|
|
219
|
-
finishGame: FinishGameEvent;
|
|
220
210
|
/** Custom game event */
|
|
221
211
|
eventGame: EventGameEvent;
|
|
222
212
|
/** Close story reader event */
|
|
@@ -13,7 +13,6 @@ import {
|
|
|
13
13
|
VisibleAreaUpdatedEvent,
|
|
14
14
|
WidgetEvent,
|
|
15
15
|
StartGameEvent,
|
|
16
|
-
FinishGameEvent,
|
|
17
16
|
CloseGameEvent,
|
|
18
17
|
EventGameEvent,
|
|
19
18
|
ProductCartUpdatedEvent,
|
|
@@ -125,12 +124,6 @@ export interface StoryManagerEventsProps {
|
|
|
125
124
|
*/
|
|
126
125
|
onCloseGame?: (event: CloseGameEvent) => void;
|
|
127
126
|
|
|
128
|
-
/**
|
|
129
|
-
* Called when a game finishes
|
|
130
|
-
* @param event - Contains game identifier and result payload
|
|
131
|
-
*/
|
|
132
|
-
onFinishGame?: (event: FinishGameEvent) => void;
|
|
133
|
-
|
|
134
127
|
/**
|
|
135
128
|
* Called on custom in-game events
|
|
136
129
|
* @param event - Contains event name and custom payload
|
|
@@ -153,6 +153,8 @@ export interface InAppMessaging {
|
|
|
153
153
|
* @param options - Optional display configuration
|
|
154
154
|
* @param options.showOnlyIfLoaded - If true, only shows messages that were preloaded
|
|
155
155
|
* @param options.signal - Abort signal to cancel the operation
|
|
156
|
+
* @param options.appearance - Appearance options for the message
|
|
157
|
+
* @param options.appearance.zIndex - Custom z-index value for the message container (BottomSheet/Modal)
|
|
156
158
|
* @returns Promise resolving to the displayed message
|
|
157
159
|
* @throws {IamNotFoundByIdError} If no message exists with this ID
|
|
158
160
|
* @throws {IamMessageOpenError} If this message is already open
|
|
@@ -160,7 +162,7 @@ export interface InAppMessaging {
|
|
|
160
162
|
* @throws {IamShowOnlyIfLoadedError} If showOnlyIfLoaded=true but message wasn't preloaded
|
|
161
163
|
* @throws {IamMessageLimitExceededError} If message display limit was reached
|
|
162
164
|
*/
|
|
163
|
-
showMessageById(messageId: number | string, options?: { showOnlyIfLoaded?: boolean; signal?: AbortSignal; }): Promise<IamMessage>;
|
|
165
|
+
showMessageById(messageId: number | string, options?: { showOnlyIfLoaded?: boolean; signal?: AbortSignal; appearance?: { zIndex?: number }; }): Promise<IamMessage>;
|
|
164
166
|
|
|
165
167
|
/**
|
|
166
168
|
* Displays a message associated with an event name
|
|
@@ -169,6 +171,8 @@ export interface InAppMessaging {
|
|
|
169
171
|
* @param options.showOnlyIfLoaded - If true, only shows messages that were preloaded
|
|
170
172
|
* @param options.tags - Filter messages by tags
|
|
171
173
|
* @param options.signal - Abort signal to cancel the operation
|
|
174
|
+
* @param options.appearance - Appearance options for the message
|
|
175
|
+
* @param options.appearance.zIndex - Custom z-index value for the message container (BottomSheet/Modal)
|
|
172
176
|
* @returns Promise resolving to the displayed message
|
|
173
177
|
* @throws {IamNotFoundByEventError} If no message exists for this event
|
|
174
178
|
* @throws {IamFrequencyLimitError} If message frequency limit was exceeded
|
|
@@ -178,7 +182,7 @@ export interface InAppMessaging {
|
|
|
178
182
|
*/
|
|
179
183
|
showMessageByEvent(
|
|
180
184
|
eventName: string,
|
|
181
|
-
options?: { showOnlyIfLoaded?: boolean; tags?: string[]; signal?: AbortSignal; }
|
|
185
|
+
options?: { showOnlyIfLoaded?: boolean; tags?: string[]; signal?: AbortSignal; appearance?: { zIndex?: number }; }
|
|
182
186
|
): Promise<IamMessage>;
|
|
183
187
|
|
|
184
188
|
/**
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inappstory/react-sdk",
|
|
3
|
-
"version": "1.9.
|
|
3
|
+
"version": "1.9.6",
|
|
4
4
|
"description": "React SDK",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"stories",
|
|
@@ -58,7 +58,7 @@
|
|
|
58
58
|
"Samsung >= 5"
|
|
59
59
|
],
|
|
60
60
|
"dependencies": {
|
|
61
|
-
"@inappstory/slide-api": "^0.1.
|
|
61
|
+
"@inappstory/slide-api": "^0.1.35",
|
|
62
62
|
"async-mutex": "^0.5.0",
|
|
63
63
|
"bowser": "^2.11.0",
|
|
64
64
|
"classnames": "^2.5.1",
|