@micromag/screen-conversation 0.3.88 → 0.3.89
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/es/index.js +11 -5
- package/lib/index.js +11 -5
- package/package.json +3 -3
package/es/index.js
CHANGED
|
@@ -187,6 +187,8 @@ var propTypes = {
|
|
|
187
187
|
type: PropTypes$1.string,
|
|
188
188
|
conversation: PropTypes.conversation,
|
|
189
189
|
transitions: PropTypes.transitions,
|
|
190
|
+
enableInteraction: PropTypes$1.func,
|
|
191
|
+
disableInteraction: PropTypes$1.func,
|
|
190
192
|
className: PropTypes$1.string
|
|
191
193
|
};
|
|
192
194
|
var defaultProps = {
|
|
@@ -201,6 +203,8 @@ var defaultProps = {
|
|
|
201
203
|
type: null,
|
|
202
204
|
conversation: null,
|
|
203
205
|
transitions: null,
|
|
206
|
+
enableInteraction: null,
|
|
207
|
+
disableInteraction: null,
|
|
204
208
|
className: null
|
|
205
209
|
};
|
|
206
210
|
|
|
@@ -217,6 +221,8 @@ var ConversationScreen = function ConversationScreen(_ref) {
|
|
|
217
221
|
type = _ref.type,
|
|
218
222
|
conversation = _ref.conversation,
|
|
219
223
|
transitions = _ref.transitions,
|
|
224
|
+
enableInteraction = _ref.enableInteraction,
|
|
225
|
+
disableInteraction = _ref.disableInteraction,
|
|
220
226
|
className = _ref.className;
|
|
221
227
|
|
|
222
228
|
var _useScreenSize = useScreenSize(),
|
|
@@ -289,15 +295,13 @@ var ConversationScreen = function ConversationScreen(_ref) {
|
|
|
289
295
|
var filteredMessages = (messages || []).filter(function (m) {
|
|
290
296
|
return m !== null;
|
|
291
297
|
});
|
|
292
|
-
var timings = filteredMessages.map(function () {
|
|
293
|
-
var _ref4 =
|
|
298
|
+
var timings = filteredMessages.map(function (messageParams, messageI) {
|
|
299
|
+
var _ref4 = messageParams || {},
|
|
294
300
|
_ref4$timing = _ref4.timing,
|
|
295
301
|
timing = _ref4$timing === void 0 ? null : _ref4$timing,
|
|
296
302
|
_ref4$message = _ref4.message,
|
|
297
303
|
message = _ref4$message === void 0 ? null : _ref4$message;
|
|
298
304
|
|
|
299
|
-
var messageI = arguments.length > 1 ? arguments[1] : undefined;
|
|
300
|
-
|
|
301
305
|
if (timing !== null) {
|
|
302
306
|
return timing;
|
|
303
307
|
}
|
|
@@ -438,7 +442,9 @@ var ConversationScreen = function ConversationScreen(_ref) {
|
|
|
438
442
|
screenSize: {
|
|
439
443
|
width: width,
|
|
440
444
|
height: height
|
|
441
|
-
}
|
|
445
|
+
},
|
|
446
|
+
enableInteraction: enableInteraction,
|
|
447
|
+
disableInteraction: disableInteraction
|
|
442
448
|
})) : null, /*#__PURE__*/React.createElement("div", {
|
|
443
449
|
ref: chatBottomRef
|
|
444
450
|
}))))))));
|
package/lib/index.js
CHANGED
|
@@ -209,6 +209,8 @@ var propTypes = {
|
|
|
209
209
|
type: PropTypes__default["default"].string,
|
|
210
210
|
conversation: core.PropTypes.conversation,
|
|
211
211
|
transitions: core.PropTypes.transitions,
|
|
212
|
+
enableInteraction: PropTypes__default["default"].func,
|
|
213
|
+
disableInteraction: PropTypes__default["default"].func,
|
|
212
214
|
className: PropTypes__default["default"].string
|
|
213
215
|
};
|
|
214
216
|
var defaultProps = {
|
|
@@ -223,6 +225,8 @@ var defaultProps = {
|
|
|
223
225
|
type: null,
|
|
224
226
|
conversation: null,
|
|
225
227
|
transitions: null,
|
|
228
|
+
enableInteraction: null,
|
|
229
|
+
disableInteraction: null,
|
|
226
230
|
className: null
|
|
227
231
|
};
|
|
228
232
|
|
|
@@ -239,6 +243,8 @@ var ConversationScreen = function ConversationScreen(_ref) {
|
|
|
239
243
|
type = _ref.type,
|
|
240
244
|
conversation = _ref.conversation,
|
|
241
245
|
transitions = _ref.transitions,
|
|
246
|
+
enableInteraction = _ref.enableInteraction,
|
|
247
|
+
disableInteraction = _ref.disableInteraction,
|
|
242
248
|
className = _ref.className;
|
|
243
249
|
|
|
244
250
|
var _useScreenSize = contexts.useScreenSize(),
|
|
@@ -311,15 +317,13 @@ var ConversationScreen = function ConversationScreen(_ref) {
|
|
|
311
317
|
var filteredMessages = (messages || []).filter(function (m) {
|
|
312
318
|
return m !== null;
|
|
313
319
|
});
|
|
314
|
-
var timings = filteredMessages.map(function () {
|
|
315
|
-
var _ref4 =
|
|
320
|
+
var timings = filteredMessages.map(function (messageParams, messageI) {
|
|
321
|
+
var _ref4 = messageParams || {},
|
|
316
322
|
_ref4$timing = _ref4.timing,
|
|
317
323
|
timing = _ref4$timing === void 0 ? null : _ref4$timing,
|
|
318
324
|
_ref4$message = _ref4.message,
|
|
319
325
|
message = _ref4$message === void 0 ? null : _ref4$message;
|
|
320
326
|
|
|
321
|
-
var messageI = arguments.length > 1 ? arguments[1] : undefined;
|
|
322
|
-
|
|
323
327
|
if (timing !== null) {
|
|
324
328
|
return timing;
|
|
325
329
|
}
|
|
@@ -460,7 +464,9 @@ var ConversationScreen = function ConversationScreen(_ref) {
|
|
|
460
464
|
screenSize: {
|
|
461
465
|
width: width,
|
|
462
466
|
height: height
|
|
463
|
-
}
|
|
467
|
+
},
|
|
468
|
+
enableInteraction: enableInteraction,
|
|
469
|
+
disableInteraction: disableInteraction
|
|
464
470
|
})) : null, /*#__PURE__*/React__default["default"].createElement("div", {
|
|
465
471
|
ref: chatBottomRef
|
|
466
472
|
}))))))));
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@micromag/screen-conversation",
|
|
3
|
-
"version": "0.3.
|
|
3
|
+
"version": "0.3.89",
|
|
4
4
|
"description": "",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"javascript"
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
"@babel/runtime": "^7.13.10",
|
|
52
52
|
"@micromag/core": "^0.3.88",
|
|
53
53
|
"@micromag/element-background": "^0.3.88",
|
|
54
|
-
"@micromag/element-call-to-action": "^0.3.
|
|
54
|
+
"@micromag/element-call-to-action": "^0.3.89",
|
|
55
55
|
"@micromag/element-container": "^0.3.88",
|
|
56
56
|
"@micromag/element-heading": "^0.3.88",
|
|
57
57
|
"@micromag/element-layout": "^0.3.88",
|
|
@@ -68,5 +68,5 @@
|
|
|
68
68
|
"publishConfig": {
|
|
69
69
|
"access": "public"
|
|
70
70
|
},
|
|
71
|
-
"gitHead": "
|
|
71
|
+
"gitHead": "b79d346163c149050ed713e8162675f11b8baf4b"
|
|
72
72
|
}
|