botframework-webchat-fluent-theme 4.17.0-main.20240416.e3f5401 → 4.17.0-main.20240419.2240f2a
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/botframework-webchat-fluent-theme.development.css.map +1 -0
- package/dist/botframework-webchat-fluent-theme.development.js +418 -2085
- package/dist/botframework-webchat-fluent-theme.development.js.map +1 -1
- package/dist/botframework-webchat-fluent-theme.production.min.css.map +1 -0
- package/dist/botframework-webchat-fluent-theme.production.min.js +1 -3
- package/dist/botframework-webchat-fluent-theme.production.min.js.map +1 -1
- package/dist/index.css.map +1 -0
- package/dist/index.js +285 -545
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +335 -595
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -5
- package/src/components/Theme.module.css +65 -0
- package/src/components/Theme.tsx +4 -65
- package/src/components/dropZone/index.module.css +23 -0
- package/src/components/dropZone/index.tsx +6 -31
- package/src/components/sendbox/AddAttachmentButton.module.css +10 -0
- package/src/components/sendbox/AddAttachmentButton.tsx +5 -17
- package/src/components/sendbox/Attachments.module.css +7 -0
- package/src/components/sendbox/Attachments.tsx +7 -13
- package/src/components/sendbox/ErrorMessage.module.css +9 -0
- package/src/components/sendbox/ErrorMessage.tsx +2 -13
- package/src/components/sendbox/TelephoneKeypadToolbarButton.tsx +3 -2
- package/src/components/sendbox/TextArea.module.css +63 -0
- package/src/components/sendbox/TextArea.tsx +9 -70
- package/src/components/sendbox/Toolbar.module.css +51 -0
- package/src/components/sendbox/Toolbar.tsx +7 -55
- package/src/components/sendbox/index.module.css +86 -0
- package/src/components/sendbox/index.tsx +18 -77
- package/src/components/suggestedActions/SuggestedAction.module.css +35 -0
- package/src/components/suggestedActions/SuggestedAction.tsx +3 -43
- package/src/components/suggestedActions/index.module.css +23 -0
- package/src/components/suggestedActions/index.tsx +6 -29
- package/src/components/telephoneKeypad/private/Button.module.css +62 -0
- package/src/components/telephoneKeypad/private/Button.tsx +5 -67
- package/src/components/telephoneKeypad/private/TelephoneKeypad.module.css +59 -0
- package/src/components/telephoneKeypad/private/TelephoneKeypad.tsx +17 -35
- package/src/env.d.ts +7 -0
- package/src/icons/AddDocumentIcon.tsx +0 -1
- package/src/icons/AttachmentIcon.tsx +0 -1
- package/src/icons/InfoSmallIcon.tsx +17 -0
- package/src/icons/SendIcon.tsx +0 -1
- package/src/icons/TelephoneKeypad.tsx +0 -1
- package/src/index.ts +3 -0
- package/src/styles/injectStyle.ts +9 -0
- package/src/styles/useStyles.ts +19 -0
- package/src/styles.ts +4 -0
- package/src/tsconfig.json +2 -1
- package/src/private/useStyleToEmotionObject.ts +0 -32
- package/src/styles/index.ts +0 -15
|
@@ -9,11 +9,11 @@
|
|
|
9
9
|
var __commonJS = (cb, mod) => function __require() {
|
|
10
10
|
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
11
11
|
};
|
|
12
|
-
var __copyProps = (to,
|
|
13
|
-
if (
|
|
14
|
-
for (let key of __getOwnPropNames(
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
15
|
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
-
__defProp(to, key, { get: () =>
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
17
|
}
|
|
18
18
|
return to;
|
|
19
19
|
};
|
|
@@ -43,6 +43,66 @@
|
|
|
43
43
|
}
|
|
44
44
|
});
|
|
45
45
|
|
|
46
|
+
// node_modules/classnames/index.js
|
|
47
|
+
var require_classnames = __commonJS({
|
|
48
|
+
"node_modules/classnames/index.js"(exports, module) {
|
|
49
|
+
(function() {
|
|
50
|
+
"use strict";
|
|
51
|
+
var hasOwn = {}.hasOwnProperty;
|
|
52
|
+
function classNames() {
|
|
53
|
+
var classes = "";
|
|
54
|
+
for (var i = 0; i < arguments.length; i++) {
|
|
55
|
+
var arg = arguments[i];
|
|
56
|
+
if (arg) {
|
|
57
|
+
classes = appendClass(classes, parseValue(arg));
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
return classes;
|
|
61
|
+
}
|
|
62
|
+
function parseValue(arg) {
|
|
63
|
+
if (typeof arg === "string" || typeof arg === "number") {
|
|
64
|
+
return arg;
|
|
65
|
+
}
|
|
66
|
+
if (typeof arg !== "object") {
|
|
67
|
+
return "";
|
|
68
|
+
}
|
|
69
|
+
if (Array.isArray(arg)) {
|
|
70
|
+
return classNames.apply(null, arg);
|
|
71
|
+
}
|
|
72
|
+
if (arg.toString !== Object.prototype.toString && !arg.toString.toString().includes("[native code]")) {
|
|
73
|
+
return arg.toString();
|
|
74
|
+
}
|
|
75
|
+
var classes = "";
|
|
76
|
+
for (var key in arg) {
|
|
77
|
+
if (hasOwn.call(arg, key) && arg[key]) {
|
|
78
|
+
classes = appendClass(classes, key);
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
return classes;
|
|
82
|
+
}
|
|
83
|
+
function appendClass(value, newClass) {
|
|
84
|
+
if (!newClass) {
|
|
85
|
+
return value;
|
|
86
|
+
}
|
|
87
|
+
if (value) {
|
|
88
|
+
return value + " " + newClass;
|
|
89
|
+
}
|
|
90
|
+
return value + newClass;
|
|
91
|
+
}
|
|
92
|
+
if (typeof module !== "undefined" && module.exports) {
|
|
93
|
+
classNames.default = classNames;
|
|
94
|
+
module.exports = classNames;
|
|
95
|
+
} else if (typeof define === "function" && typeof define.amd === "object" && define.amd) {
|
|
96
|
+
define("classnames", [], function() {
|
|
97
|
+
return classNames;
|
|
98
|
+
});
|
|
99
|
+
} else {
|
|
100
|
+
window.classNames = classNames;
|
|
101
|
+
}
|
|
102
|
+
})();
|
|
103
|
+
}
|
|
104
|
+
});
|
|
105
|
+
|
|
46
106
|
// node_modules/core-js-pure/internals/global.js
|
|
47
107
|
var require_global = __commonJS({
|
|
48
108
|
"node_modules/core-js-pure/internals/global.js"(exports, module) {
|
|
@@ -320,22 +380,22 @@
|
|
|
320
380
|
"use strict";
|
|
321
381
|
var global2 = require_global();
|
|
322
382
|
var userAgent = require_engine_user_agent();
|
|
323
|
-
var
|
|
383
|
+
var process = global2.process;
|
|
324
384
|
var Deno = global2.Deno;
|
|
325
|
-
var versions =
|
|
385
|
+
var versions = process && process.versions || Deno && Deno.version;
|
|
326
386
|
var v8 = versions && versions.v8;
|
|
327
|
-
var
|
|
387
|
+
var match;
|
|
328
388
|
var version;
|
|
329
389
|
if (v8) {
|
|
330
|
-
|
|
331
|
-
version =
|
|
390
|
+
match = v8.split(".");
|
|
391
|
+
version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);
|
|
332
392
|
}
|
|
333
393
|
if (!version && userAgent) {
|
|
334
|
-
|
|
335
|
-
if (!
|
|
336
|
-
|
|
337
|
-
if (
|
|
338
|
-
version = +
|
|
394
|
+
match = userAgent.match(/Edge\/(\d+)/);
|
|
395
|
+
if (!match || match[1] >= 74) {
|
|
396
|
+
match = userAgent.match(/Chrome\/(\d+)/);
|
|
397
|
+
if (match)
|
|
398
|
+
version = +match[1];
|
|
339
399
|
}
|
|
340
400
|
}
|
|
341
401
|
module.exports = version;
|
|
@@ -917,9 +977,9 @@
|
|
|
917
977
|
var toIntegerOrInfinity = require_to_integer_or_infinity();
|
|
918
978
|
var max = Math.max;
|
|
919
979
|
var min = Math.min;
|
|
920
|
-
module.exports = function(index,
|
|
980
|
+
module.exports = function(index, length) {
|
|
921
981
|
var integer = toIntegerOrInfinity(index);
|
|
922
|
-
return integer < 0 ? max(integer +
|
|
982
|
+
return integer < 0 ? max(integer + length, 0) : min(integer, length);
|
|
923
983
|
};
|
|
924
984
|
}
|
|
925
985
|
});
|
|
@@ -958,19 +1018,19 @@
|
|
|
958
1018
|
var createMethod = function(IS_INCLUDES) {
|
|
959
1019
|
return function($this, el, fromIndex) {
|
|
960
1020
|
var O = toIndexedObject($this);
|
|
961
|
-
var
|
|
962
|
-
if (
|
|
1021
|
+
var length = lengthOfArrayLike(O);
|
|
1022
|
+
if (length === 0)
|
|
963
1023
|
return !IS_INCLUDES && -1;
|
|
964
|
-
var index = toAbsoluteIndex(fromIndex,
|
|
1024
|
+
var index = toAbsoluteIndex(fromIndex, length);
|
|
965
1025
|
var value;
|
|
966
1026
|
if (IS_INCLUDES && el !== el)
|
|
967
|
-
while (
|
|
1027
|
+
while (length > index) {
|
|
968
1028
|
value = O[index++];
|
|
969
1029
|
if (value !== value)
|
|
970
1030
|
return true;
|
|
971
1031
|
}
|
|
972
1032
|
else
|
|
973
|
-
for (;
|
|
1033
|
+
for (; length > index; index++) {
|
|
974
1034
|
if ((IS_INCLUDES || index in O) && O[index] === el)
|
|
975
1035
|
return IS_INCLUDES || index || 0;
|
|
976
1036
|
}
|
|
@@ -1064,10 +1124,10 @@
|
|
|
1064
1124
|
anObject(O);
|
|
1065
1125
|
var props = toIndexedObject(Properties);
|
|
1066
1126
|
var keys = objectKeys(Properties);
|
|
1067
|
-
var
|
|
1127
|
+
var length = keys.length;
|
|
1068
1128
|
var index = 0;
|
|
1069
1129
|
var key;
|
|
1070
|
-
while (
|
|
1130
|
+
while (length > index)
|
|
1071
1131
|
definePropertyModule.f(O, key = keys[index++], props[key]);
|
|
1072
1132
|
return O;
|
|
1073
1133
|
};
|
|
@@ -1144,9 +1204,9 @@
|
|
|
1144
1204
|
} catch (error) {
|
|
1145
1205
|
}
|
|
1146
1206
|
NullProtoObject = typeof document != "undefined" ? document.domain && activeXDocument ? NullProtoObjectViaActiveX(activeXDocument) : NullProtoObjectViaIFrame() : NullProtoObjectViaActiveX(activeXDocument);
|
|
1147
|
-
var
|
|
1148
|
-
while (
|
|
1149
|
-
delete NullProtoObject[PROTOTYPE][enumBugKeys[
|
|
1207
|
+
var length = enumBugKeys.length;
|
|
1208
|
+
while (length--)
|
|
1209
|
+
delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];
|
|
1150
1210
|
return NullProtoObject();
|
|
1151
1211
|
};
|
|
1152
1212
|
hiddenKeys[IE_PROTO] = true;
|
|
@@ -1206,75 +1266,6 @@
|
|
|
1206
1266
|
}
|
|
1207
1267
|
});
|
|
1208
1268
|
|
|
1209
|
-
// node_modules/classnames/index.js
|
|
1210
|
-
var require_classnames = __commonJS({
|
|
1211
|
-
"node_modules/classnames/index.js"(exports, module) {
|
|
1212
|
-
(function() {
|
|
1213
|
-
"use strict";
|
|
1214
|
-
var hasOwn = {}.hasOwnProperty;
|
|
1215
|
-
function classNames() {
|
|
1216
|
-
var classes = "";
|
|
1217
|
-
for (var i = 0; i < arguments.length; i++) {
|
|
1218
|
-
var arg = arguments[i];
|
|
1219
|
-
if (arg) {
|
|
1220
|
-
classes = appendClass(classes, parseValue(arg));
|
|
1221
|
-
}
|
|
1222
|
-
}
|
|
1223
|
-
return classes;
|
|
1224
|
-
}
|
|
1225
|
-
function parseValue(arg) {
|
|
1226
|
-
if (typeof arg === "string" || typeof arg === "number") {
|
|
1227
|
-
return arg;
|
|
1228
|
-
}
|
|
1229
|
-
if (typeof arg !== "object") {
|
|
1230
|
-
return "";
|
|
1231
|
-
}
|
|
1232
|
-
if (Array.isArray(arg)) {
|
|
1233
|
-
return classNames.apply(null, arg);
|
|
1234
|
-
}
|
|
1235
|
-
if (arg.toString !== Object.prototype.toString && !arg.toString.toString().includes("[native code]")) {
|
|
1236
|
-
return arg.toString();
|
|
1237
|
-
}
|
|
1238
|
-
var classes = "";
|
|
1239
|
-
for (var key in arg) {
|
|
1240
|
-
if (hasOwn.call(arg, key) && arg[key]) {
|
|
1241
|
-
classes = appendClass(classes, key);
|
|
1242
|
-
}
|
|
1243
|
-
}
|
|
1244
|
-
return classes;
|
|
1245
|
-
}
|
|
1246
|
-
function appendClass(value, newClass) {
|
|
1247
|
-
if (!newClass) {
|
|
1248
|
-
return value;
|
|
1249
|
-
}
|
|
1250
|
-
if (value) {
|
|
1251
|
-
return value + " " + newClass;
|
|
1252
|
-
}
|
|
1253
|
-
return value + newClass;
|
|
1254
|
-
}
|
|
1255
|
-
if (typeof module !== "undefined" && module.exports) {
|
|
1256
|
-
classNames.default = classNames;
|
|
1257
|
-
module.exports = classNames;
|
|
1258
|
-
} else if (typeof define === "function" && typeof define.amd === "object" && define.amd) {
|
|
1259
|
-
define("classnames", [], function() {
|
|
1260
|
-
return classNames;
|
|
1261
|
-
});
|
|
1262
|
-
} else {
|
|
1263
|
-
window.classNames = classNames;
|
|
1264
|
-
}
|
|
1265
|
-
})();
|
|
1266
|
-
}
|
|
1267
|
-
});
|
|
1268
|
-
|
|
1269
|
-
// src/external.umd/botframework-webchat-api.ts
|
|
1270
|
-
var require_botframework_webchat_api = __commonJS({
|
|
1271
|
-
"src/external.umd/botframework-webchat-api.ts"(exports, module) {
|
|
1272
|
-
module.exports = {
|
|
1273
|
-
hooks: globalThis.WebChat.hooks
|
|
1274
|
-
};
|
|
1275
|
-
}
|
|
1276
|
-
});
|
|
1277
|
-
|
|
1278
1269
|
// node_modules/inject-meta-tag/lib/esmodules/injectMetaTag.js
|
|
1279
1270
|
function injectMeta(name, content) {
|
|
1280
1271
|
try {
|
|
@@ -1291,7 +1282,7 @@
|
|
|
1291
1282
|
}
|
|
1292
1283
|
|
|
1293
1284
|
// src/private/FluentThemeProvider.tsx
|
|
1294
|
-
var
|
|
1285
|
+
var import_botframework_webchat_component10 = __toESM(require_botframework_webchat_component());
|
|
1295
1286
|
var import_react28 = __toESM(require_react());
|
|
1296
1287
|
|
|
1297
1288
|
// src/components/telephoneKeypad/Provider.tsx
|
|
@@ -1328,6 +1319,7 @@
|
|
|
1328
1319
|
|
|
1329
1320
|
// src/components/telephoneKeypad/private/TelephoneKeypad.tsx
|
|
1330
1321
|
var import_react8 = __toESM(require_react());
|
|
1322
|
+
var import_classnames = __toESM(require_classnames());
|
|
1331
1323
|
|
|
1332
1324
|
// node_modules/use-ref-from/lib/esmodules/useRefFrom.js
|
|
1333
1325
|
var import_create = __toESM(require_create3());
|
|
@@ -1347,1591 +1339,145 @@
|
|
|
1347
1339
|
return readOnlyRef;
|
|
1348
1340
|
}
|
|
1349
1341
|
|
|
1350
|
-
// src/
|
|
1342
|
+
// src/components/telephoneKeypad/private/TelephoneKeypad.tsx
|
|
1343
|
+
var import_botframework_webchat_component = __toESM(require_botframework_webchat_component());
|
|
1344
|
+
|
|
1345
|
+
// src/components/telephoneKeypad/private/Button.tsx
|
|
1351
1346
|
var import_react5 = __toESM(require_react());
|
|
1352
1347
|
|
|
1353
|
-
//
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1360
|
-
|
|
1361
|
-
|
|
1348
|
+
// src/components/telephoneKeypad/private/Button.module.css
|
|
1349
|
+
var Button_default = {
|
|
1350
|
+
"telephone-keypad__button": "Button_telephone-keypad__button",
|
|
1351
|
+
"telephone-keypad__button__ruby": "Button_telephone-keypad__button__ruby",
|
|
1352
|
+
"telephone-keypad__button__text": "Button_telephone-keypad__button__text",
|
|
1353
|
+
"telephone-keypad--horizontal": "Button_telephone-keypad--horizontal"
|
|
1354
|
+
};
|
|
1355
|
+
|
|
1356
|
+
// src/styles/injectStyle.ts
|
|
1357
|
+
var injectedStyles = "/* src/components/telephoneKeypad/private/Button.module.css */\n.webchat-fluent .Button_telephone-keypad__button {\n -webkit-user-select: none;\n align-items: center;\n appearance: none;\n background-color: White;\n border-radius: 100%;\n border: solid 1px var(--webchat-colorNeutralStroke1);\n color: var(--webchat-colorGray200);\n font-weight: var(--webchat-fontWeightSemibold);\n cursor: pointer;\n display: flex;\n flex-direction: column;\n height: 60px;\n opacity: 0.7;\n padding: 0;\n position: relative;\n touch-action: none;\n user-select: none;\n width: 60px;\n}\n.webchat-fluent .Button_telephone-keypad__button:hover {\n background-color: var(--webchat-colorGray30);\n}\n.webchat-fluent .Button_telephone-keypad__button__ruby {\n color: var(--webchat-colorGray190);\n font-size: 10px;\n}\n.webchat-fluent .Button_telephone-keypad__button__text {\n font-size: 24px;\n margin-top: 8px;\n}\n.webchat-fluent .Button_telephone-keypad--horizontal .Button_telephone-keypad__button {\n height: 32px;\n justify-content: center;\n margin: 8px 4px;\n width: 32px;\n}\n.webchat-fluent .Button_telephone-keypad--horizontal .Button_telephone-keypad__button__ruby {\n display: none;\n}\n.webchat-fluent .Button_telephone-keypad--horizontal .Button_telephone-keypad__button__text {\n font-size: 20px;\n margin-top: 0;\n}\n\n/* src/components/telephoneKeypad/private/TelephoneKeypad.module.css */\n.webchat-fluent .TelephoneKeypad_telephone-keypad {\n align-items: center;\n background: var(--webchat-colorNeutralBackground1);\n border: none;\n border-radius: var(--webchat-borderRadiusXLarge);\n display: flex;\n flex-direction: column;\n font-family: var(--webchat-fontFamilyBase);\n justify-content: center;\n}\n.webchat-fluent .TelephoneKeypad_telephone-keypad__box {\n box-sizing: border-box;\n display: grid;\n gap: 16px;\n grid-template-columns: repeat(3, 1fr);\n grid-template-rows: repeat(4, 1fr);\n justify-items: center;\n padding: 16px;\n width: 100%;\n}\n.webchat-fluent .TelephoneKeypad_telephone-keypad__info-message {\n align-items: center;\n color: var(--webchat-colorNeutralForeground4);\n display: flex;\n font-size: 12px;\n gap: 6px;\n margin-block-end: 6px;\n}\n.webchat-fluent .TelephoneKeypad_telephone-keypad__info-message-link {\n color: var(--webchat-colorBrandForegroundLink);\n text-decoration-color: transparent;\n}\n.webchat-fluent .TelephoneKeypad_telephone-keypad__info-message-link:target {\n color: var(--webchat-colorBrandForegroundLinkSelected);\n}\n.webchat-fluent .TelephoneKeypad_telephone-keypad__info-message-link:hover {\n color: var(--webchat-colorBrandForegroundLinkHover);\n text-decoration: underline 1px currentColor;\n}\n.webchat-fluent .TelephoneKeypad_telephone-keypad__info-message-link:active {\n color: var(--webchat-colorBrandForegroundLinkPressed);\n}\n.webchat-fluent .TelephoneKeypad_telephone-keypad__info-message-link:focus-visible {\n outline: none;\n text-decoration: underline 1px double var(--webchat-colorStrokeFocus2);\n}\n\n/* src/components/Theme.module.css */\n.webchat-fluent.Theme_theme {\n display: contents;\n --webchat-colorNeutralForeground1: var(--colorNeutralForeground1, #242424);\n --webchat-colorNeutralForeground2: var(--colorNeutralForeground2, #424242);\n --webchat-colorNeutralForeground4: var(--colorNeutralForeground4, #707070);\n --webchat-colorNeutralForeground2BrandHover: var(--colorNeutralForeground2BrandHover, #02729c);\n --webchat-colorNeutralForeground2BrandPressed: var(--colorNeutralForeground2BrandPressed, #01678c);\n --webchat-colorNeutralForeground2BrandSelected: var(--colorNeutralForeground2BrandSelected, #067191);\n --webchat-colorNeutralForegroundDisabled: var(--colorNeutralForegroundDisabled, #bdbdbd);\n --webchat-colorNeutralBackground1: var(--colorNeutralBackground1, #ffffff);\n --webchat-colorNeutralBackground4: var(--colorNeutralBackground4, #f0f0f0);\n --webchat-colorNeutralBackground5: var(--colorNeutralBackground5, #ebebeb);\n --webchat-colorNeutralStroke1: var(--colorNeutralStroke1, #d1d1d1);\n --webchat-colorNeutralStroke2: var(--colorNeutralStroke2, #e0e0e0);\n --webchat-colorNeutralStroke1Selected: var(--colorNeutralStroke1Selected, #bdbdbd);\n --webchat-colorStrokeFocus2: var(--colorStrokeFocus2, #000000);\n --webchat-colorBrandStroke2: var(--colorBrandStroke2, #9edcf7);\n --webchat-colorBrandForeground2Hover: var(--colorBrandForeground2Hover, #015a7a);\n --webchat-colorBrandForeground2Pressed: var(--colorBrandForeground2Pressed, #01384d);\n --webchat-colorBrandForegroundLink: var(--colorBrandForegroundLink, #01678c);\n --webchat-colorBrandForegroundLinkHover: var(--colorBrandForegroundLinkHover, #015a7a);\n --webchat-colorBrandForegroundLinkPressed: var(--colorBrandForegroundLinkPressed, #014259);\n --webchat-colorBrandForegroundLinkSelected: var(--colorBrandForegroundLinkSelected, #01678c);\n --webchat-colorBrandBackground2Hover: var(--colorBrandBackground2Hover, #bee7fa);\n --webchat-colorBrandBackground2Pressed: var(--colorBrandBackground2Pressed, #7fd2f5);\n --webchat-colorCompoundBrandForeground1Hover: var(--colorCompoundBrandForeground1Hover, #02729c);\n --webchat-colorStatusDangerForeground1: var(--colorStatusDangerForeground1, #b10e1c);\n --webchat-colorGray30: var(--colorGray30, #edebe9);\n --webchat-colorGray160: var(--colorGray160, #323130);\n --webchat-colorGray190: var(--colorGray190, #201f1e);\n --webchat-colorGray200: var(--colorGray200, #1b1a19);\n --webchat-borderRadiusSmall: var(--borderRadiusSmall, 2px);\n --webchat-borderRadiusLarge: var(--borderRadiusLarge, 6px);\n --webchat-borderRadiusXLarge: var(--borderRadiusXLarge, 8px);\n --webchat-shadow16: var(--shadow16, 0 6.4px 14.4px 0 rgba(0, 0, 0, 0.132), 0 1.2px 3.6px 0 rgba(0, 0, 0, 0.108));\n --webchat-spacingHorizontalMNudge: var(--spacingHorizontalMNudge, 10px);\n --webchat-fontFamilyBase: var(--fontFamilyBase, \"Segoe UI\", \"Segoe UI Web (West European)\", -apple-system, BlinkMacSystemFont, Roboto, \"Helvetica Neue\", sans-serif);\n --webchat-fontFamilyNumeric: var(--fontFamilyNumeric, Bahnschrift, \"Segoe UI\", \"Segoe UI Web (West European)\", -apple-system, BlinkMacSystemFont, Roboto, \"Helvetica Neue\", sans-serif);\n --webchat-fontWeightSemibold: var(--fontWeightSemibold, 600);\n}\n\n/* src/components/dropZone/index.module.css */\n.webchat-fluent .dropZone_sendbox__attachment-drop-zone {\n background-color: var(--webchat-colorNeutralBackground4);\n border-radius: inherit;\n cursor: copy;\n display: grid;\n gap: 8px;\n inset: 0;\n place-content: center;\n place-items: center;\n position: absolute;\n}\n.webchat-fluent .dropZone_sendbox__attachment-drop-zone--droppable {\n background-color: #e00;\n color: White;\n}\n.webchat-fluent .dropZone_sendbox__attachment-drop-zone-icon {\n height: 36px;\n pointer-events: none;\n width: 36px;\n}\n\n/* src/components/suggestedActions/SuggestedAction.module.css */\n.webchat-fluent .SuggestedAction_suggested-action {\n align-items: center;\n background: transparent;\n border-radius: 8px;\n border: 1px solid var(--webchat-colorBrandStroke2);\n color: currentColor;\n cursor: pointer;\n display: flex;\n font-size: 12px;\n gap: 4px;\n padding: 4px 8px 4px;\n text-align: start;\n transition: all .15s ease-out;\n}\n@media (hover: hover) {\n .webchat-fluent .SuggestedAction_suggested-action:not([aria-disabled=true]):hover {\n background-color: var(--webchat-colorBrandBackground2Hover);\n color: var(--webchat-colorBrandForeground2Hover);\n }\n}\n.webchat-fluent .SuggestedAction_suggested-action:not([aria-disabled=true]):active {\n background-color: var(--webchat-colorBrandBackground2Pressed);\n color: var(--webchat-colorBrandForeground2Pressed);\n}\n.webchat-fluent .SuggestedAction_suggested-action[aria-disabled=true] {\n color: var(--webchat-colorNeutralForegroundDisabled);\n cursor: not-allowed;\n}\n.webchat-fluent .SuggestedAction_suggested-action__image {\n font-size: 12px;\n height: 1em;\n width: 1em;\n}\n\n/* src/components/suggestedActions/index.module.css */\n.webchat-fluent .suggestedActions_suggested-actions {\n align-items: flex-end;\n align-self: flex-end;\n display: flex;\n flex-direction: column;\n gap: 8px;\n}\n.webchat-fluent .suggestedActions_suggested-actions:not(:empty) {\n padding-block-end: 8px;\n padding-inline-start: 4px;\n}\n.webchat-fluent .suggestedActions_suggested-actions.suggestedActions_suggested-actions--flow {\n flex-direction: row;\n flex-wrap: wrap;\n justify-content: flex-end;\n}\n.webchat-fluent .suggestedActions_suggested-actions.suggestedActions_suggested-actions--stacked {\n flex-direction: column;\n}\n\n/* src/components/sendbox/Toolbar.module.css */\n.webchat-fluent .Toolbar_sendbox__toolbar {\n display: flex;\n gap: 4px;\n margin-inline-start: auto;\n}\n.webchat-fluent .Toolbar_sendbox__toolbar-button {\n align-items: center;\n appearance: none;\n aspect-ratio: 1;\n background: transparent;\n border-radius: var(--webchat-borderRadiusSmall);\n border: none;\n color: currentColor;\n cursor: pointer;\n display: flex;\n justify-content: center;\n padding: 3px;\n width: 32px;\n}\n.webchat-fluent .Toolbar_sendbox__toolbar-button > svg {\n font-size: 20px;\n pointer-events: none;\n}\n.webchat-fluent .Toolbar_sendbox__toolbar-button.Toolbar_sendbox__toolbar-button--selected {\n color: var(--webchat-colorNeutralForeground2BrandSelected);\n}\n@media (hover: hover) {\n .webchat-fluent .Toolbar_sendbox__toolbar-button:not([aria-disabled=true]):hover {\n color: var(--webchat-colorNeutralForeground2BrandHover);\n }\n}\n.webchat-fluent .Toolbar_sendbox__toolbar-button:not([aria-disabled=true]):active {\n color: var(--webchat-colorNeutralForeground2BrandPressed);\n}\n.webchat-fluent .Toolbar_sendbox__toolbar-button[aria-disabled=true] {\n color: var(--webchat-colorNeutralForegroundDisabled);\n cursor: not-allowed;\n}\n.webchat-fluent .Toolbar_sendbox__toolbar-separator {\n align-self: center;\n border-inline-end: 1px solid var(--webchat-colorNeutralStroke2);\n height: 28px;\n}\n.webchat-fluent .Toolbar_sendbox__toolbar-separator:is(:first-child, :last-child, :only-child) {\n display: none;\n}\n\n/* src/components/sendbox/AddAttachmentButton.module.css */\n.webchat-fluent .AddAttachmentButton_sendbox__add-attachment {\n display: grid;\n}\n.webchat-fluent .AddAttachmentButton_sendbox__add-attachment-input {\n font-size: 0;\n height: 0;\n opacity: 0;\n width: 0;\n}\n\n/* src/components/sendbox/Attachments.module.css */\n.webchat-fluent .Attachments_sendbox__attachment {\n border-radius: var(--webchat-borderRadiusLarge);\n border: 1px solid var(--webchat-colorNeutralStroke1);\n cursor: default;\n padding: 6px 8px;\n width: fit-content;\n}\n\n/* src/components/sendbox/ErrorMessage.module.css */\n.webchat-fluent .ErrorMessage_sendbox__error-message {\n color: transparent;\n font-size: 0;\n height: 0;\n left: 0;\n position: absolute;\n top: 0;\n width: 0;\n}\n\n/* src/components/sendbox/TextArea.module.css */\n.webchat-fluent .TextArea_sendbox__text-area {\n display: grid;\n grid-template-areas: \"main\";\n max-height: 200px;\n overflow: hidden;\n}\n.webchat-fluent .TextArea_sendbox__text-area--hidden {\n height: 0;\n visibility: collapse;\n}\n.webchat-fluent .TextArea_sendbox__text-area-shared {\n border: none;\n font: inherit;\n grid-area: main;\n outline: inherit;\n overflow-wrap: anywhere;\n resize: inherit;\n scrollbar-gutter: stable;\n}\n.webchat-fluent .TextArea_sendbox__text-area-doppelganger {\n overflow: hidden;\n visibility: hidden;\n white-space: pre-wrap;\n}\n.webchat-fluent .TextArea_sendbox__text-area-input {\n background-color: inherit;\n color: currentColor;\n height: 100%;\n padding: 0;\n}\n.webchat-fluent .TextArea_sendbox__text-area-input--scroll {\n scrollbar-color: unset;\n scrollbar-width: unset;\n -moz-scrollbar-color: var(--webchat-colorNeutralBackground5) var(--webchat-colorNeutralForeground2);\n -moz-scrollbar-width: thin;\n}\n.webchat-fluent .TextArea_sendbox__text-area-input--scroll::-webkit-scrollbar {\n width: 8px;\n}\n.webchat-fluent .TextArea_sendbox__text-area-input--scroll::-webkit-scrollbar-track {\n background-color: var(--webchat-colorNeutralBackground5);\n border-radius: 16px;\n}\n.webchat-fluent .TextArea_sendbox__text-area-input--scroll::-webkit-scrollbar-thumb {\n background-color: var(--webchat-colorNeutralForeground2);\n border-radius: 16px;\n}\n.webchat-fluent .TextArea_sendbox__text-area-input--scroll::-webkit-scrollbar-corner {\n background-color: var(--webchat-colorNeutralBackground5);\n}\n\n/* src/components/sendbox/index.module.css */\n.webchat-fluent .sendbox_sendbox {\n color: var(--webchat-colorNeutralForeground1);\n font-family: var(--webchat-fontFamilyBase);\n padding: 0 10px 10px;\n text-rendering: optimizeLegibility;\n --webchat-sendbox-attachment-area-active: ;\n}\n.webchat-fluent .sendbox_sendbox__sendbox {\n background-color: var(--webchat-colorNeutralBackground1);\n border-radius: var(--webchat-borderRadiusLarge);\n border: 1px solid var(--webchat-colorNeutralStroke1);\n display: grid;\n font-family: var(--webchat-fontFamilyBase);\n font-size: 14px;\n gap: 6px;\n grid-template: [telephone-keypad-start] \"text-area\" [telephone-keypad-end] var(--webchat-sendbox-attachment-area-active) \"controls\" / [telephone-keypad] 1fr;\n line-height: 20px;\n padding: 8px;\n position: relative;\n}\n.webchat-fluent .sendbox_sendbox__sendbox:has(.sendbox_sendbox__attachment--in-grid) {\n --webchat-sendbox-attachment-area-active: \"attachment\" ;\n}\n.webchat-fluent .sendbox_sendbox__sendbox:focus-within {\n border-color: var(--webchat-colorNeutralStroke1Selected);\n box-shadow: inset 0 -6px 0 -3px var(--webchat-colorCompoundBrandForeground1Hover);\n}\n.webchat-fluent .sendbox_sendbox__sendbox > .sendbox_sendbox__text-area--in-grid {\n grid-area: text-area;\n}\n.webchat-fluent .sendbox_sendbox__sendbox > .sendbox_sendbox__attachment--in-grid {\n grid-area: attachment;\n}\n.webchat-fluent .sendbox_sendbox__sendbox > .sendbox_sendbox__sendbox-controls--in-grid {\n grid-area: controls;\n}\n.webchat-fluent .sendbox_sendbox__sendbox > .sendbox_sendbox__telephone-keypad--in-grid {\n grid-area: telephone-keypad;\n}\n.webchat-fluent .sendbox_sendbox__sendbox-text {\n background-color: transparent;\n border: none;\n flex: auto;\n font-family: var(--webchat-fontFamilyBase);\n font-size: 14px;\n line-height: 20px;\n outline: none;\n padding: 4px 4px 0;\n resize: none;\n}\n.webchat-fluent .sendbox_sendbox__sendbox-controls {\n align-items: center;\n display: flex;\n padding-inline-start: 4px;\n}\n.webchat-fluent .sendbox_sendbox__text-counter {\n color: var(--webchat-colorNeutralForeground4);\n cursor: default;\n font-family: var(--webchat-fontFamilyNumeric);\n font-size: 10px;\n line-height: 14px;\n margin-inline-end: 4px;\n}\n.webchat-fluent .sendbox_sendbox__text-counter--error {\n color: var(--webchat-colorStatusDangerForeground1);\n}\n";
|
|
1358
|
+
function injectStyles() {
|
|
1359
|
+
if (globalThis.document) {
|
|
1360
|
+
const style = document.createElement("style");
|
|
1361
|
+
style.append(document.createTextNode(injectedStyles));
|
|
1362
|
+
document.head.appendChild(style);
|
|
1362
1363
|
}
|
|
1363
1364
|
}
|
|
1364
|
-
function createStyleElement(options) {
|
|
1365
|
-
var tag = document.createElement("style");
|
|
1366
|
-
tag.setAttribute("data-emotion", options.key);
|
|
1367
|
-
if (options.nonce !== void 0) {
|
|
1368
|
-
tag.setAttribute("nonce", options.nonce);
|
|
1369
|
-
}
|
|
1370
|
-
tag.appendChild(document.createTextNode(""));
|
|
1371
|
-
tag.setAttribute("data-s", "");
|
|
1372
|
-
return tag;
|
|
1373
|
-
}
|
|
1374
|
-
var StyleSheet = /* @__PURE__ */ function() {
|
|
1375
|
-
function StyleSheet2(options) {
|
|
1376
|
-
var _this = this;
|
|
1377
|
-
this._insertTag = function(tag) {
|
|
1378
|
-
var before;
|
|
1379
|
-
if (_this.tags.length === 0) {
|
|
1380
|
-
if (_this.insertionPoint) {
|
|
1381
|
-
before = _this.insertionPoint.nextSibling;
|
|
1382
|
-
} else if (_this.prepend) {
|
|
1383
|
-
before = _this.container.firstChild;
|
|
1384
|
-
} else {
|
|
1385
|
-
before = _this.before;
|
|
1386
|
-
}
|
|
1387
|
-
} else {
|
|
1388
|
-
before = _this.tags[_this.tags.length - 1].nextSibling;
|
|
1389
|
-
}
|
|
1390
|
-
_this.container.insertBefore(tag, before);
|
|
1391
|
-
_this.tags.push(tag);
|
|
1392
|
-
};
|
|
1393
|
-
this.isSpeedy = options.speedy === void 0 ? false : options.speedy;
|
|
1394
|
-
this.tags = [];
|
|
1395
|
-
this.ctr = 0;
|
|
1396
|
-
this.nonce = options.nonce;
|
|
1397
|
-
this.key = options.key;
|
|
1398
|
-
this.container = options.container;
|
|
1399
|
-
this.prepend = options.prepend;
|
|
1400
|
-
this.insertionPoint = options.insertionPoint;
|
|
1401
|
-
this.before = null;
|
|
1402
|
-
}
|
|
1403
|
-
var _proto = StyleSheet2.prototype;
|
|
1404
|
-
_proto.hydrate = function hydrate(nodes) {
|
|
1405
|
-
nodes.forEach(this._insertTag);
|
|
1406
|
-
};
|
|
1407
|
-
_proto.insert = function insert(rule) {
|
|
1408
|
-
if (this.ctr % (this.isSpeedy ? 65e3 : 1) === 0) {
|
|
1409
|
-
this._insertTag(createStyleElement(this));
|
|
1410
|
-
}
|
|
1411
|
-
var tag = this.tags[this.tags.length - 1];
|
|
1412
|
-
if (true) {
|
|
1413
|
-
var isImportRule3 = rule.charCodeAt(0) === 64 && rule.charCodeAt(1) === 105;
|
|
1414
|
-
if (isImportRule3 && this._alreadyInsertedOrderInsensitiveRule) {
|
|
1415
|
-
console.error("You're attempting to insert the following rule:\n" + rule + "\n\n`@import` rules must be before all other types of rules in a stylesheet but other rules have already been inserted. Please ensure that `@import` rules are before all other rules.");
|
|
1416
|
-
}
|
|
1417
|
-
this._alreadyInsertedOrderInsensitiveRule = this._alreadyInsertedOrderInsensitiveRule || !isImportRule3;
|
|
1418
|
-
}
|
|
1419
|
-
if (this.isSpeedy) {
|
|
1420
|
-
var sheet = sheetForTag(tag);
|
|
1421
|
-
try {
|
|
1422
|
-
sheet.insertRule(rule, sheet.cssRules.length);
|
|
1423
|
-
} catch (e) {
|
|
1424
|
-
if (!/:(-moz-placeholder|-moz-focus-inner|-moz-focusring|-ms-input-placeholder|-moz-read-write|-moz-read-only|-ms-clear|-ms-expand|-ms-reveal){/.test(rule)) {
|
|
1425
|
-
console.error('There was a problem inserting the following rule: "' + rule + '"', e);
|
|
1426
|
-
}
|
|
1427
|
-
}
|
|
1428
|
-
} else {
|
|
1429
|
-
tag.appendChild(document.createTextNode(rule));
|
|
1430
|
-
}
|
|
1431
|
-
this.ctr++;
|
|
1432
|
-
};
|
|
1433
|
-
_proto.flush = function flush() {
|
|
1434
|
-
this.tags.forEach(function(tag) {
|
|
1435
|
-
return tag.parentNode && tag.parentNode.removeChild(tag);
|
|
1436
|
-
});
|
|
1437
|
-
this.tags = [];
|
|
1438
|
-
this.ctr = 0;
|
|
1439
|
-
if (true) {
|
|
1440
|
-
this._alreadyInsertedOrderInsensitiveRule = false;
|
|
1441
|
-
}
|
|
1442
|
-
};
|
|
1443
|
-
return StyleSheet2;
|
|
1444
|
-
}();
|
|
1445
|
-
|
|
1446
|
-
// node_modules/stylis/src/Enum.js
|
|
1447
|
-
var MS = "-ms-";
|
|
1448
|
-
var MOZ = "-moz-";
|
|
1449
|
-
var WEBKIT = "-webkit-";
|
|
1450
|
-
var COMMENT = "comm";
|
|
1451
|
-
var RULESET = "rule";
|
|
1452
|
-
var DECLARATION = "decl";
|
|
1453
|
-
var IMPORT = "@import";
|
|
1454
|
-
var KEYFRAMES = "@keyframes";
|
|
1455
|
-
var LAYER = "@layer";
|
|
1456
|
-
|
|
1457
|
-
// node_modules/stylis/src/Utility.js
|
|
1458
|
-
var abs = Math.abs;
|
|
1459
|
-
var from = String.fromCharCode;
|
|
1460
|
-
var assign = Object.assign;
|
|
1461
|
-
function hash(value, length2) {
|
|
1462
|
-
return charat(value, 0) ^ 45 ? (((length2 << 2 ^ charat(value, 0)) << 2 ^ charat(value, 1)) << 2 ^ charat(value, 2)) << 2 ^ charat(value, 3) : 0;
|
|
1463
|
-
}
|
|
1464
|
-
function trim(value) {
|
|
1465
|
-
return value.trim();
|
|
1466
|
-
}
|
|
1467
|
-
function match(value, pattern) {
|
|
1468
|
-
return (value = pattern.exec(value)) ? value[0] : value;
|
|
1469
|
-
}
|
|
1470
|
-
function replace(value, pattern, replacement) {
|
|
1471
|
-
return value.replace(pattern, replacement);
|
|
1472
|
-
}
|
|
1473
|
-
function indexof(value, search) {
|
|
1474
|
-
return value.indexOf(search);
|
|
1475
|
-
}
|
|
1476
|
-
function charat(value, index) {
|
|
1477
|
-
return value.charCodeAt(index) | 0;
|
|
1478
|
-
}
|
|
1479
|
-
function substr(value, begin, end) {
|
|
1480
|
-
return value.slice(begin, end);
|
|
1481
|
-
}
|
|
1482
|
-
function strlen(value) {
|
|
1483
|
-
return value.length;
|
|
1484
|
-
}
|
|
1485
|
-
function sizeof(value) {
|
|
1486
|
-
return value.length;
|
|
1487
|
-
}
|
|
1488
|
-
function append(value, array) {
|
|
1489
|
-
return array.push(value), value;
|
|
1490
|
-
}
|
|
1491
|
-
function combine(array, callback) {
|
|
1492
|
-
return array.map(callback).join("");
|
|
1493
|
-
}
|
|
1494
1365
|
|
|
1495
|
-
//
|
|
1496
|
-
var
|
|
1497
|
-
|
|
1498
|
-
|
|
1499
|
-
|
|
1500
|
-
|
|
1501
|
-
|
|
1502
|
-
|
|
1503
|
-
|
|
1504
|
-
|
|
1505
|
-
|
|
1506
|
-
|
|
1507
|
-
|
|
1508
|
-
|
|
1509
|
-
return character;
|
|
1510
|
-
}
|
|
1511
|
-
function prev() {
|
|
1512
|
-
character = position > 0 ? charat(characters, --position) : 0;
|
|
1513
|
-
if (column--, character === 10)
|
|
1514
|
-
column = 1, line--;
|
|
1515
|
-
return character;
|
|
1516
|
-
}
|
|
1517
|
-
function next() {
|
|
1518
|
-
character = position < length ? charat(characters, position++) : 0;
|
|
1519
|
-
if (column++, character === 10)
|
|
1520
|
-
column = 1, line++;
|
|
1521
|
-
return character;
|
|
1522
|
-
}
|
|
1523
|
-
function peek() {
|
|
1524
|
-
return charat(characters, position);
|
|
1525
|
-
}
|
|
1526
|
-
function caret() {
|
|
1527
|
-
return position;
|
|
1528
|
-
}
|
|
1529
|
-
function slice(begin, end) {
|
|
1530
|
-
return substr(characters, begin, end);
|
|
1531
|
-
}
|
|
1532
|
-
function token(type) {
|
|
1533
|
-
switch (type) {
|
|
1534
|
-
case 0:
|
|
1535
|
-
case 9:
|
|
1536
|
-
case 10:
|
|
1537
|
-
case 13:
|
|
1538
|
-
case 32:
|
|
1539
|
-
return 5;
|
|
1540
|
-
case 33:
|
|
1541
|
-
case 43:
|
|
1542
|
-
case 44:
|
|
1543
|
-
case 47:
|
|
1544
|
-
case 62:
|
|
1545
|
-
case 64:
|
|
1546
|
-
case 126:
|
|
1547
|
-
case 59:
|
|
1548
|
-
case 123:
|
|
1549
|
-
case 125:
|
|
1550
|
-
return 4;
|
|
1551
|
-
case 58:
|
|
1552
|
-
return 3;
|
|
1553
|
-
case 34:
|
|
1554
|
-
case 39:
|
|
1555
|
-
case 40:
|
|
1556
|
-
case 91:
|
|
1557
|
-
return 2;
|
|
1558
|
-
case 41:
|
|
1559
|
-
case 93:
|
|
1560
|
-
return 1;
|
|
1561
|
-
}
|
|
1562
|
-
return 0;
|
|
1563
|
-
}
|
|
1564
|
-
function alloc(value) {
|
|
1565
|
-
return line = column = 1, length = strlen(characters = value), position = 0, [];
|
|
1566
|
-
}
|
|
1567
|
-
function dealloc(value) {
|
|
1568
|
-
return characters = "", value;
|
|
1569
|
-
}
|
|
1570
|
-
function delimit(type) {
|
|
1571
|
-
return trim(slice(position - 1, delimiter(type === 91 ? type + 2 : type === 40 ? type + 1 : type)));
|
|
1572
|
-
}
|
|
1573
|
-
function whitespace(type) {
|
|
1574
|
-
while (character = peek())
|
|
1575
|
-
if (character < 33)
|
|
1576
|
-
next();
|
|
1577
|
-
else
|
|
1578
|
-
break;
|
|
1579
|
-
return token(type) > 2 || token(character) > 3 ? "" : " ";
|
|
1580
|
-
}
|
|
1581
|
-
function escaping(index, count) {
|
|
1582
|
-
while (--count && next())
|
|
1583
|
-
if (character < 48 || character > 102 || character > 57 && character < 65 || character > 70 && character < 97)
|
|
1584
|
-
break;
|
|
1585
|
-
return slice(index, caret() + (count < 6 && peek() == 32 && next() == 32));
|
|
1586
|
-
}
|
|
1587
|
-
function delimiter(type) {
|
|
1588
|
-
while (next())
|
|
1589
|
-
switch (character) {
|
|
1590
|
-
case type:
|
|
1591
|
-
return position;
|
|
1592
|
-
case 34:
|
|
1593
|
-
case 39:
|
|
1594
|
-
if (type !== 34 && type !== 39)
|
|
1595
|
-
delimiter(character);
|
|
1596
|
-
break;
|
|
1597
|
-
case 40:
|
|
1598
|
-
if (type === 41)
|
|
1599
|
-
delimiter(type);
|
|
1600
|
-
break;
|
|
1601
|
-
case 92:
|
|
1602
|
-
next();
|
|
1603
|
-
break;
|
|
1604
|
-
}
|
|
1605
|
-
return position;
|
|
1606
|
-
}
|
|
1607
|
-
function commenter(type, index) {
|
|
1608
|
-
while (next())
|
|
1609
|
-
if (type + character === 47 + 10)
|
|
1610
|
-
break;
|
|
1611
|
-
else if (type + character === 42 + 42 && peek() === 47)
|
|
1612
|
-
break;
|
|
1613
|
-
return "/*" + slice(index, position - 1) + "*" + from(type === 47 ? type : next());
|
|
1614
|
-
}
|
|
1615
|
-
function identifier(index) {
|
|
1616
|
-
while (!token(peek()))
|
|
1617
|
-
next();
|
|
1618
|
-
return slice(index, position);
|
|
1366
|
+
// src/styles/useStyles.ts
|
|
1367
|
+
var import_react4 = __toESM(require_react());
|
|
1368
|
+
function useStyles(styles) {
|
|
1369
|
+
return (0, import_react4.useMemo)(
|
|
1370
|
+
() => Object.freeze(
|
|
1371
|
+
Object.fromEntries(
|
|
1372
|
+
Object.entries(styles).map(([baseClassName, resultClassName]) => [
|
|
1373
|
+
baseClassName,
|
|
1374
|
+
`${baseClassName} ${resultClassName}`
|
|
1375
|
+
])
|
|
1376
|
+
)
|
|
1377
|
+
),
|
|
1378
|
+
[styles]
|
|
1379
|
+
);
|
|
1619
1380
|
}
|
|
1381
|
+
var useStyles_default = useStyles;
|
|
1620
1382
|
|
|
1621
|
-
//
|
|
1622
|
-
|
|
1623
|
-
|
|
1624
|
-
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1643
|
-
|
|
1644
|
-
|
|
1645
|
-
if (indexof(characters2 += replace(delimit(character2), "&", "&\f"), "&\f") != -1)
|
|
1646
|
-
ampersand = -1;
|
|
1647
|
-
break;
|
|
1648
|
-
}
|
|
1649
|
-
case 34:
|
|
1650
|
-
case 39:
|
|
1651
|
-
case 91:
|
|
1652
|
-
characters2 += delimit(character2);
|
|
1653
|
-
break;
|
|
1654
|
-
case 9:
|
|
1655
|
-
case 10:
|
|
1656
|
-
case 13:
|
|
1657
|
-
case 32:
|
|
1658
|
-
characters2 += whitespace(previous);
|
|
1659
|
-
break;
|
|
1660
|
-
case 92:
|
|
1661
|
-
characters2 += escaping(caret() - 1, 7);
|
|
1662
|
-
continue;
|
|
1663
|
-
case 47:
|
|
1664
|
-
switch (peek()) {
|
|
1665
|
-
case 42:
|
|
1666
|
-
case 47:
|
|
1667
|
-
append(comment(commenter(next(), caret()), root, parent), declarations);
|
|
1668
|
-
break;
|
|
1669
|
-
default:
|
|
1670
|
-
characters2 += "/";
|
|
1671
|
-
}
|
|
1672
|
-
break;
|
|
1673
|
-
case 123 * variable:
|
|
1674
|
-
points[index++] = strlen(characters2) * ampersand;
|
|
1675
|
-
case 125 * variable:
|
|
1676
|
-
case 59:
|
|
1677
|
-
case 0:
|
|
1678
|
-
switch (character2) {
|
|
1679
|
-
case 0:
|
|
1680
|
-
case 125:
|
|
1681
|
-
scanning = 0;
|
|
1682
|
-
case 59 + offset:
|
|
1683
|
-
if (ampersand == -1)
|
|
1684
|
-
characters2 = replace(characters2, /\f/g, "");
|
|
1685
|
-
if (property > 0 && strlen(characters2) - length2)
|
|
1686
|
-
append(property > 32 ? declaration(characters2 + ";", rule, parent, length2 - 1) : declaration(replace(characters2, " ", "") + ";", rule, parent, length2 - 2), declarations);
|
|
1687
|
-
break;
|
|
1688
|
-
case 59:
|
|
1689
|
-
characters2 += ";";
|
|
1690
|
-
default:
|
|
1691
|
-
append(reference = ruleset(characters2, root, parent, index, offset, rules, points, type, props = [], children = [], length2), rulesets);
|
|
1692
|
-
if (character2 === 123)
|
|
1693
|
-
if (offset === 0)
|
|
1694
|
-
parse(characters2, root, reference, reference, props, rulesets, length2, points, children);
|
|
1695
|
-
else
|
|
1696
|
-
switch (atrule === 99 && charat(characters2, 3) === 110 ? 100 : atrule) {
|
|
1697
|
-
case 100:
|
|
1698
|
-
case 108:
|
|
1699
|
-
case 109:
|
|
1700
|
-
case 115:
|
|
1701
|
-
parse(value, reference, reference, rule && append(ruleset(value, reference, reference, 0, 0, rules, points, type, rules, props = [], length2), children), rules, children, length2, points, rule ? props : children);
|
|
1702
|
-
break;
|
|
1703
|
-
default:
|
|
1704
|
-
parse(characters2, reference, reference, reference, [""], children, 0, points, children);
|
|
1705
|
-
}
|
|
1706
|
-
}
|
|
1707
|
-
index = offset = property = 0, variable = ampersand = 1, type = characters2 = "", length2 = pseudo;
|
|
1708
|
-
break;
|
|
1709
|
-
case 58:
|
|
1710
|
-
length2 = 1 + strlen(characters2), property = previous;
|
|
1711
|
-
default:
|
|
1712
|
-
if (variable < 1) {
|
|
1713
|
-
if (character2 == 123)
|
|
1714
|
-
--variable;
|
|
1715
|
-
else if (character2 == 125 && variable++ == 0 && prev() == 125)
|
|
1716
|
-
continue;
|
|
1717
|
-
}
|
|
1718
|
-
switch (characters2 += from(character2), character2 * variable) {
|
|
1719
|
-
case 38:
|
|
1720
|
-
ampersand = offset > 0 ? 1 : (characters2 += "\f", -1);
|
|
1721
|
-
break;
|
|
1722
|
-
case 44:
|
|
1723
|
-
points[index++] = (strlen(characters2) - 1) * ampersand, ampersand = 1;
|
|
1724
|
-
break;
|
|
1725
|
-
case 64:
|
|
1726
|
-
if (peek() === 45)
|
|
1727
|
-
characters2 += delimit(next());
|
|
1728
|
-
atrule = peek(), offset = length2 = strlen(type = characters2 += identifier(caret())), character2++;
|
|
1729
|
-
break;
|
|
1730
|
-
case 45:
|
|
1731
|
-
if (previous === 45 && strlen(characters2) == 2)
|
|
1732
|
-
variable = 0;
|
|
1733
|
-
}
|
|
1734
|
-
}
|
|
1735
|
-
return rulesets;
|
|
1736
|
-
}
|
|
1737
|
-
function ruleset(value, root, parent, index, offset, rules, points, type, props, children, length2) {
|
|
1738
|
-
var post = offset - 1;
|
|
1739
|
-
var rule = offset === 0 ? rules : [""];
|
|
1740
|
-
var size = sizeof(rule);
|
|
1741
|
-
for (var i = 0, j = 0, k = 0; i < index; ++i)
|
|
1742
|
-
for (var x = 0, y = substr(value, post + 1, post = abs(j = points[i])), z = value; x < size; ++x)
|
|
1743
|
-
if (z = trim(j > 0 ? rule[x] + " " + y : replace(y, /&\f/g, rule[x])))
|
|
1744
|
-
props[k++] = z;
|
|
1745
|
-
return node(value, root, parent, offset === 0 ? RULESET : type, props, children, length2);
|
|
1746
|
-
}
|
|
1747
|
-
function comment(value, root, parent) {
|
|
1748
|
-
return node(value, root, parent, COMMENT, from(char()), substr(value, 2, -2), 0);
|
|
1749
|
-
}
|
|
1750
|
-
function declaration(value, root, parent, length2) {
|
|
1751
|
-
return node(value, root, parent, DECLARATION, substr(value, 0, length2), substr(value, length2 + 1, -1), length2);
|
|
1752
|
-
}
|
|
1383
|
+
// src/components/telephoneKeypad/private/Button.tsx
|
|
1384
|
+
var Button = (0, import_react5.memo)(
|
|
1385
|
+
// As we are all TypeScript, internal components do not need propTypes.
|
|
1386
|
+
// eslint-disable-next-line react/prop-types
|
|
1387
|
+
(0, import_react5.forwardRef)(({ button, "data-testid": dataTestId, onClick, ruby }, ref) => {
|
|
1388
|
+
const classNames = useStyles_default(Button_default);
|
|
1389
|
+
const onClickRef = useRefFrom(onClick);
|
|
1390
|
+
const handleClick = (0, import_react5.useCallback)(() => onClickRef.current?.(), [onClickRef]);
|
|
1391
|
+
return /* @__PURE__ */ import_react5.default.createElement(
|
|
1392
|
+
"button",
|
|
1393
|
+
{
|
|
1394
|
+
className: classNames["telephone-keypad__button"],
|
|
1395
|
+
"data-testid": dataTestId,
|
|
1396
|
+
onClick: handleClick,
|
|
1397
|
+
ref,
|
|
1398
|
+
type: "button"
|
|
1399
|
+
},
|
|
1400
|
+
/* @__PURE__ */ import_react5.default.createElement("span", { className: classNames["telephone-keypad__button__text"] }, button === "star" ? "\u2217" : button === "pound" ? "#" : button),
|
|
1401
|
+
!!ruby && /* @__PURE__ */ import_react5.default.createElement("ruby", { className: classNames["telephone-keypad__button__ruby"] }, ruby)
|
|
1402
|
+
);
|
|
1403
|
+
})
|
|
1404
|
+
);
|
|
1405
|
+
Button.displayName = "TelephoneKeypad.Button";
|
|
1406
|
+
var Button_default2 = Button;
|
|
1753
1407
|
|
|
1754
|
-
//
|
|
1755
|
-
|
|
1756
|
-
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
|
|
1765
|
-
|
|
1766
|
-
|
|
1767
|
-
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
|
|
1775
|
-
element.value = element.props.join(",");
|
|
1776
|
-
}
|
|
1777
|
-
return strlen(children = serialize(element.children, callback)) ? element.return = element.value + "{" + children + "}" : "";
|
|
1778
|
-
}
|
|
1408
|
+
// src/testIds.ts
|
|
1409
|
+
var testIds = {
|
|
1410
|
+
sendBoxDropZone: "send box drop zone",
|
|
1411
|
+
sendBoxSendButton: "send box send button",
|
|
1412
|
+
sendBoxTextBox: "send box text area",
|
|
1413
|
+
sendBoxTelephoneKeypadButton1: `send box telephone keypad button 1`,
|
|
1414
|
+
sendBoxTelephoneKeypadButton2: `send box telephone keypad button 2`,
|
|
1415
|
+
sendBoxTelephoneKeypadButton3: `send box telephone keypad button 3`,
|
|
1416
|
+
sendBoxTelephoneKeypadButton4: `send box telephone keypad button 4`,
|
|
1417
|
+
sendBoxTelephoneKeypadButton5: `send box telephone keypad button 5`,
|
|
1418
|
+
sendBoxTelephoneKeypadButton6: `send box telephone keypad button 6`,
|
|
1419
|
+
sendBoxTelephoneKeypadButton7: `send box telephone keypad button 7`,
|
|
1420
|
+
sendBoxTelephoneKeypadButton8: `send box telephone keypad button 8`,
|
|
1421
|
+
sendBoxTelephoneKeypadButton9: `send box telephone keypad button 9`,
|
|
1422
|
+
sendBoxTelephoneKeypadButton0: `send box telephone keypad button 0`,
|
|
1423
|
+
sendBoxTelephoneKeypadButtonStar: `send box telephone keypad button star`,
|
|
1424
|
+
sendBoxTelephoneKeypadButtonPound: `send box telephone keypad button pound`,
|
|
1425
|
+
sendBoxTelephoneKeypadToolbarButton: "send box telephone keypad toolbar button",
|
|
1426
|
+
sendBoxUploadButton: "send box upload button"
|
|
1427
|
+
};
|
|
1428
|
+
var testIds_default = testIds;
|
|
1779
1429
|
|
|
1780
|
-
//
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
for (var i = 0; i < length2; i++)
|
|
1786
|
-
output += collection[i](element, index, children, callback) || "";
|
|
1787
|
-
return output;
|
|
1788
|
-
};
|
|
1430
|
+
// src/components/telephoneKeypad/useShown.ts
|
|
1431
|
+
var import_react6 = __toESM(require_react());
|
|
1432
|
+
function useShown() {
|
|
1433
|
+
const { setShown, shown } = (0, import_react6.useContext)(Context_default);
|
|
1434
|
+
return (0, import_react6.useMemo)(() => Object.freeze([shown, setShown]), [shown, setShown]);
|
|
1789
1435
|
}
|
|
1790
1436
|
|
|
1791
|
-
//
|
|
1792
|
-
var
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
}
|
|
1798
|
-
var ret = func(arg);
|
|
1799
|
-
cache.set(arg, ret);
|
|
1800
|
-
return ret;
|
|
1801
|
-
};
|
|
1437
|
+
// src/components/telephoneKeypad/private/TelephoneKeypad.module.css
|
|
1438
|
+
var TelephoneKeypad_default = {
|
|
1439
|
+
"telephone-keypad": "TelephoneKeypad_telephone-keypad",
|
|
1440
|
+
"telephone-keypad__box": "TelephoneKeypad_telephone-keypad__box",
|
|
1441
|
+
"telephone-keypad__info-message": "TelephoneKeypad_telephone-keypad__info-message",
|
|
1442
|
+
"telephone-keypad__info-message-link": "TelephoneKeypad_telephone-keypad__info-message-link"
|
|
1802
1443
|
};
|
|
1803
1444
|
|
|
1804
|
-
//
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
if (previous === 38 && character2 === 12) {
|
|
1822
|
-
points[index] = 1;
|
|
1823
|
-
}
|
|
1824
|
-
if (token(character2)) {
|
|
1825
|
-
break;
|
|
1445
|
+
// src/icons/InfoSmallIcon.tsx
|
|
1446
|
+
var import_react7 = __toESM(require_react());
|
|
1447
|
+
var InfoSmallIcon_default = (0, import_react7.memo)((props) => /* @__PURE__ */ import_react7.default.createElement(
|
|
1448
|
+
"svg",
|
|
1449
|
+
{
|
|
1450
|
+
"aria-hidden": "true",
|
|
1451
|
+
className: props.className,
|
|
1452
|
+
height: "1em",
|
|
1453
|
+
viewBox: "0 0 16 16",
|
|
1454
|
+
width: "1em",
|
|
1455
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
1456
|
+
},
|
|
1457
|
+
/* @__PURE__ */ import_react7.default.createElement(
|
|
1458
|
+
"path",
|
|
1459
|
+
{
|
|
1460
|
+
d: "M8.5 7.5a.5.5 0 1 0-1 0v3a.5.5 0 0 0 1 0v-3Zm.25-2a.75.75 0 1 1-1.5 0 .75.75 0 0 1 1.5 0ZM8 1a7 7 0 1 0 0 14A7 7 0 0 0 8 1ZM2 8a6 6 0 1 1 12 0A6 6 0 0 1 2 8Z",
|
|
1461
|
+
fill: "currentColor"
|
|
1826
1462
|
}
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
var
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
}
|
|
1840
|
-
parsed[index] += identifierWithPointTracking(position - 1, points, index);
|
|
1841
|
-
break;
|
|
1842
|
-
case 2:
|
|
1843
|
-
parsed[index] += delimit(character2);
|
|
1844
|
-
break;
|
|
1845
|
-
case 4:
|
|
1846
|
-
if (character2 === 44) {
|
|
1847
|
-
parsed[++index] = peek() === 58 ? "&\f" : "";
|
|
1848
|
-
points[index] = parsed[index].length;
|
|
1849
|
-
break;
|
|
1850
|
-
}
|
|
1851
|
-
default:
|
|
1852
|
-
parsed[index] += from(character2);
|
|
1853
|
-
}
|
|
1854
|
-
} while (character2 = next());
|
|
1855
|
-
return parsed;
|
|
1856
|
-
};
|
|
1857
|
-
var getRules = function getRules2(value, points) {
|
|
1858
|
-
return dealloc(toRules(alloc(value), points));
|
|
1859
|
-
};
|
|
1860
|
-
var fixedElements = /* @__PURE__ */ new WeakMap();
|
|
1861
|
-
var compat = function compat2(element) {
|
|
1862
|
-
if (element.type !== "rule" || !element.parent || // positive .length indicates that this rule contains pseudo
|
|
1863
|
-
// negative .length indicates that this rule has been already prefixed
|
|
1864
|
-
element.length < 1) {
|
|
1865
|
-
return;
|
|
1866
|
-
}
|
|
1867
|
-
var value = element.value, parent = element.parent;
|
|
1868
|
-
var isImplicitRule = element.column === parent.column && element.line === parent.line;
|
|
1869
|
-
while (parent.type !== "rule") {
|
|
1870
|
-
parent = parent.parent;
|
|
1871
|
-
if (!parent)
|
|
1872
|
-
return;
|
|
1873
|
-
}
|
|
1874
|
-
if (element.props.length === 1 && value.charCodeAt(0) !== 58 && !fixedElements.get(parent)) {
|
|
1875
|
-
return;
|
|
1876
|
-
}
|
|
1877
|
-
if (isImplicitRule) {
|
|
1878
|
-
return;
|
|
1879
|
-
}
|
|
1880
|
-
fixedElements.set(element, true);
|
|
1881
|
-
var points = [];
|
|
1882
|
-
var rules = getRules(value, points);
|
|
1883
|
-
var parentRules = parent.props;
|
|
1884
|
-
for (var i = 0, k = 0; i < rules.length; i++) {
|
|
1885
|
-
for (var j = 0; j < parentRules.length; j++, k++) {
|
|
1886
|
-
element.props[k] = points[i] ? rules[i].replace(/&\f/g, parentRules[j]) : parentRules[j] + " " + rules[i];
|
|
1887
|
-
}
|
|
1888
|
-
}
|
|
1889
|
-
};
|
|
1890
|
-
var removeLabel = function removeLabel2(element) {
|
|
1891
|
-
if (element.type === "decl") {
|
|
1892
|
-
var value = element.value;
|
|
1893
|
-
if (
|
|
1894
|
-
// charcode for l
|
|
1895
|
-
value.charCodeAt(0) === 108 && // charcode for b
|
|
1896
|
-
value.charCodeAt(2) === 98
|
|
1897
|
-
) {
|
|
1898
|
-
element["return"] = "";
|
|
1899
|
-
element.value = "";
|
|
1900
|
-
}
|
|
1901
|
-
}
|
|
1902
|
-
};
|
|
1903
|
-
var ignoreFlag = "emotion-disable-server-rendering-unsafe-selector-warning-please-do-not-use-this-the-warning-exists-for-a-reason";
|
|
1904
|
-
var isIgnoringComment = function isIgnoringComment2(element) {
|
|
1905
|
-
return element.type === "comm" && element.children.indexOf(ignoreFlag) > -1;
|
|
1906
|
-
};
|
|
1907
|
-
var createUnsafeSelectorsAlarm = function createUnsafeSelectorsAlarm2(cache) {
|
|
1908
|
-
return function(element, index, children) {
|
|
1909
|
-
if (element.type !== "rule" || cache.compat)
|
|
1910
|
-
return;
|
|
1911
|
-
var unsafePseudoClasses = element.value.match(/(:first|:nth|:nth-last)-child/g);
|
|
1912
|
-
if (unsafePseudoClasses) {
|
|
1913
|
-
var isNested = !!element.parent;
|
|
1914
|
-
var commentContainer = isNested ? element.parent.children : (
|
|
1915
|
-
// global rule at the root level
|
|
1916
|
-
children
|
|
1917
|
-
);
|
|
1918
|
-
for (var i = commentContainer.length - 1; i >= 0; i--) {
|
|
1919
|
-
var node2 = commentContainer[i];
|
|
1920
|
-
if (node2.line < element.line) {
|
|
1921
|
-
break;
|
|
1922
|
-
}
|
|
1923
|
-
if (node2.column < element.column) {
|
|
1924
|
-
if (isIgnoringComment(node2)) {
|
|
1925
|
-
return;
|
|
1926
|
-
}
|
|
1927
|
-
break;
|
|
1928
|
-
}
|
|
1929
|
-
}
|
|
1930
|
-
unsafePseudoClasses.forEach(function(unsafePseudoClass) {
|
|
1931
|
-
console.error('The pseudo class "' + unsafePseudoClass + '" is potentially unsafe when doing server-side rendering. Try changing it to "' + unsafePseudoClass.split("-child")[0] + '-of-type".');
|
|
1932
|
-
});
|
|
1933
|
-
}
|
|
1934
|
-
};
|
|
1935
|
-
};
|
|
1936
|
-
var isImportRule = function isImportRule2(element) {
|
|
1937
|
-
return element.type.charCodeAt(1) === 105 && element.type.charCodeAt(0) === 64;
|
|
1938
|
-
};
|
|
1939
|
-
var isPrependedWithRegularRules = function isPrependedWithRegularRules2(index, children) {
|
|
1940
|
-
for (var i = index - 1; i >= 0; i--) {
|
|
1941
|
-
if (!isImportRule(children[i])) {
|
|
1942
|
-
return true;
|
|
1943
|
-
}
|
|
1944
|
-
}
|
|
1945
|
-
return false;
|
|
1946
|
-
};
|
|
1947
|
-
var nullifyElement = function nullifyElement2(element) {
|
|
1948
|
-
element.type = "";
|
|
1949
|
-
element.value = "";
|
|
1950
|
-
element["return"] = "";
|
|
1951
|
-
element.children = "";
|
|
1952
|
-
element.props = "";
|
|
1953
|
-
};
|
|
1954
|
-
var incorrectImportAlarm = function incorrectImportAlarm2(element, index, children) {
|
|
1955
|
-
if (!isImportRule(element)) {
|
|
1956
|
-
return;
|
|
1957
|
-
}
|
|
1958
|
-
if (element.parent) {
|
|
1959
|
-
console.error("`@import` rules can't be nested inside other rules. Please move it to the top level and put it before regular rules. Keep in mind that they can only be used within global styles.");
|
|
1960
|
-
nullifyElement(element);
|
|
1961
|
-
} else if (isPrependedWithRegularRules(index, children)) {
|
|
1962
|
-
console.error("`@import` rules can't be after other rules. Please put your `@import` rules before your other rules.");
|
|
1963
|
-
nullifyElement(element);
|
|
1964
|
-
}
|
|
1965
|
-
};
|
|
1966
|
-
function prefix(value, length2) {
|
|
1967
|
-
switch (hash(value, length2)) {
|
|
1968
|
-
case 5103:
|
|
1969
|
-
return WEBKIT + "print-" + value + value;
|
|
1970
|
-
case 5737:
|
|
1971
|
-
case 4201:
|
|
1972
|
-
case 3177:
|
|
1973
|
-
case 3433:
|
|
1974
|
-
case 1641:
|
|
1975
|
-
case 4457:
|
|
1976
|
-
case 2921:
|
|
1977
|
-
case 5572:
|
|
1978
|
-
case 6356:
|
|
1979
|
-
case 5844:
|
|
1980
|
-
case 3191:
|
|
1981
|
-
case 6645:
|
|
1982
|
-
case 3005:
|
|
1983
|
-
case 6391:
|
|
1984
|
-
case 5879:
|
|
1985
|
-
case 5623:
|
|
1986
|
-
case 6135:
|
|
1987
|
-
case 4599:
|
|
1988
|
-
case 4855:
|
|
1989
|
-
case 4215:
|
|
1990
|
-
case 6389:
|
|
1991
|
-
case 5109:
|
|
1992
|
-
case 5365:
|
|
1993
|
-
case 5621:
|
|
1994
|
-
case 3829:
|
|
1995
|
-
return WEBKIT + value + value;
|
|
1996
|
-
case 5349:
|
|
1997
|
-
case 4246:
|
|
1998
|
-
case 4810:
|
|
1999
|
-
case 6968:
|
|
2000
|
-
case 2756:
|
|
2001
|
-
return WEBKIT + value + MOZ + value + MS + value + value;
|
|
2002
|
-
case 6828:
|
|
2003
|
-
case 4268:
|
|
2004
|
-
return WEBKIT + value + MS + value + value;
|
|
2005
|
-
case 6165:
|
|
2006
|
-
return WEBKIT + value + MS + "flex-" + value + value;
|
|
2007
|
-
case 5187:
|
|
2008
|
-
return WEBKIT + value + replace(value, /(\w+).+(:[^]+)/, WEBKIT + "box-$1$2" + MS + "flex-$1$2") + value;
|
|
2009
|
-
case 5443:
|
|
2010
|
-
return WEBKIT + value + MS + "flex-item-" + replace(value, /flex-|-self/, "") + value;
|
|
2011
|
-
case 4675:
|
|
2012
|
-
return WEBKIT + value + MS + "flex-line-pack" + replace(value, /align-content|flex-|-self/, "") + value;
|
|
2013
|
-
case 5548:
|
|
2014
|
-
return WEBKIT + value + MS + replace(value, "shrink", "negative") + value;
|
|
2015
|
-
case 5292:
|
|
2016
|
-
return WEBKIT + value + MS + replace(value, "basis", "preferred-size") + value;
|
|
2017
|
-
case 6060:
|
|
2018
|
-
return WEBKIT + "box-" + replace(value, "-grow", "") + WEBKIT + value + MS + replace(value, "grow", "positive") + value;
|
|
2019
|
-
case 4554:
|
|
2020
|
-
return WEBKIT + replace(value, /([^-])(transform)/g, "$1" + WEBKIT + "$2") + value;
|
|
2021
|
-
case 6187:
|
|
2022
|
-
return replace(replace(replace(value, /(zoom-|grab)/, WEBKIT + "$1"), /(image-set)/, WEBKIT + "$1"), value, "") + value;
|
|
2023
|
-
case 5495:
|
|
2024
|
-
case 3959:
|
|
2025
|
-
return replace(value, /(image-set\([^]*)/, WEBKIT + "$1$`$1");
|
|
2026
|
-
case 4968:
|
|
2027
|
-
return replace(replace(value, /(.+:)(flex-)?(.*)/, WEBKIT + "box-pack:$3" + MS + "flex-pack:$3"), /s.+-b[^;]+/, "justify") + WEBKIT + value + value;
|
|
2028
|
-
case 4095:
|
|
2029
|
-
case 3583:
|
|
2030
|
-
case 4068:
|
|
2031
|
-
case 2532:
|
|
2032
|
-
return replace(value, /(.+)-inline(.+)/, WEBKIT + "$1$2") + value;
|
|
2033
|
-
case 8116:
|
|
2034
|
-
case 7059:
|
|
2035
|
-
case 5753:
|
|
2036
|
-
case 5535:
|
|
2037
|
-
case 5445:
|
|
2038
|
-
case 5701:
|
|
2039
|
-
case 4933:
|
|
2040
|
-
case 4677:
|
|
2041
|
-
case 5533:
|
|
2042
|
-
case 5789:
|
|
2043
|
-
case 5021:
|
|
2044
|
-
case 4765:
|
|
2045
|
-
if (strlen(value) - 1 - length2 > 6)
|
|
2046
|
-
switch (charat(value, length2 + 1)) {
|
|
2047
|
-
case 109:
|
|
2048
|
-
if (charat(value, length2 + 4) !== 45)
|
|
2049
|
-
break;
|
|
2050
|
-
case 102:
|
|
2051
|
-
return replace(value, /(.+:)(.+)-([^]+)/, "$1" + WEBKIT + "$2-$3$1" + MOZ + (charat(value, length2 + 3) == 108 ? "$3" : "$2-$3")) + value;
|
|
2052
|
-
case 115:
|
|
2053
|
-
return ~indexof(value, "stretch") ? prefix(replace(value, "stretch", "fill-available"), length2) + value : value;
|
|
2054
|
-
}
|
|
2055
|
-
break;
|
|
2056
|
-
case 4949:
|
|
2057
|
-
if (charat(value, length2 + 1) !== 115)
|
|
2058
|
-
break;
|
|
2059
|
-
case 6444:
|
|
2060
|
-
switch (charat(value, strlen(value) - 3 - (~indexof(value, "!important") && 10))) {
|
|
2061
|
-
case 107:
|
|
2062
|
-
return replace(value, ":", ":" + WEBKIT) + value;
|
|
2063
|
-
case 101:
|
|
2064
|
-
return replace(value, /(.+:)([^;!]+)(;|!.+)?/, "$1" + WEBKIT + (charat(value, 14) === 45 ? "inline-" : "") + "box$3$1" + WEBKIT + "$2$3$1" + MS + "$2box$3") + value;
|
|
2065
|
-
}
|
|
2066
|
-
break;
|
|
2067
|
-
case 5936:
|
|
2068
|
-
switch (charat(value, length2 + 11)) {
|
|
2069
|
-
case 114:
|
|
2070
|
-
return WEBKIT + value + MS + replace(value, /[svh]\w+-[tblr]{2}/, "tb") + value;
|
|
2071
|
-
case 108:
|
|
2072
|
-
return WEBKIT + value + MS + replace(value, /[svh]\w+-[tblr]{2}/, "tb-rl") + value;
|
|
2073
|
-
case 45:
|
|
2074
|
-
return WEBKIT + value + MS + replace(value, /[svh]\w+-[tblr]{2}/, "lr") + value;
|
|
2075
|
-
}
|
|
2076
|
-
return WEBKIT + value + MS + value + value;
|
|
2077
|
-
}
|
|
2078
|
-
return value;
|
|
2079
|
-
}
|
|
2080
|
-
var prefixer = function prefixer2(element, index, children, callback) {
|
|
2081
|
-
if (element.length > -1) {
|
|
2082
|
-
if (!element["return"])
|
|
2083
|
-
switch (element.type) {
|
|
2084
|
-
case DECLARATION:
|
|
2085
|
-
element["return"] = prefix(element.value, element.length);
|
|
2086
|
-
break;
|
|
2087
|
-
case KEYFRAMES:
|
|
2088
|
-
return serialize([copy(element, {
|
|
2089
|
-
value: replace(element.value, "@", "@" + WEBKIT)
|
|
2090
|
-
})], callback);
|
|
2091
|
-
case RULESET:
|
|
2092
|
-
if (element.length)
|
|
2093
|
-
return combine(element.props, function(value) {
|
|
2094
|
-
switch (match(value, /(::plac\w+|:read-\w+)/)) {
|
|
2095
|
-
case ":read-only":
|
|
2096
|
-
case ":read-write":
|
|
2097
|
-
return serialize([copy(element, {
|
|
2098
|
-
props: [replace(value, /:(read-\w+)/, ":" + MOZ + "$1")]
|
|
2099
|
-
})], callback);
|
|
2100
|
-
case "::placeholder":
|
|
2101
|
-
return serialize([copy(element, {
|
|
2102
|
-
props: [replace(value, /:(plac\w+)/, ":" + WEBKIT + "input-$1")]
|
|
2103
|
-
}), copy(element, {
|
|
2104
|
-
props: [replace(value, /:(plac\w+)/, ":" + MOZ + "$1")]
|
|
2105
|
-
}), copy(element, {
|
|
2106
|
-
props: [replace(value, /:(plac\w+)/, MS + "input-$1")]
|
|
2107
|
-
})], callback);
|
|
2108
|
-
}
|
|
2109
|
-
return "";
|
|
2110
|
-
});
|
|
2111
|
-
}
|
|
2112
|
-
}
|
|
2113
|
-
};
|
|
2114
|
-
var isBrowser = typeof document !== "undefined";
|
|
2115
|
-
var getServerStylisCache = isBrowser ? void 0 : weakMemoize(function() {
|
|
2116
|
-
return memoize(function() {
|
|
2117
|
-
var cache = {};
|
|
2118
|
-
return function(name) {
|
|
2119
|
-
return cache[name];
|
|
2120
|
-
};
|
|
2121
|
-
});
|
|
2122
|
-
});
|
|
2123
|
-
var defaultStylisPlugins = [prefixer];
|
|
2124
|
-
var createCache = function createCache2(options) {
|
|
2125
|
-
var key = options.key;
|
|
2126
|
-
if (!key) {
|
|
2127
|
-
throw new Error("You have to configure `key` for your cache. Please make sure it's unique (and not equal to 'css') as it's used for linking styles to your cache.\nIf multiple caches share the same key they might \"fight\" for each other's style elements.");
|
|
2128
|
-
}
|
|
2129
|
-
if (isBrowser && key === "css") {
|
|
2130
|
-
var ssrStyles = document.querySelectorAll("style[data-emotion]:not([data-s])");
|
|
2131
|
-
Array.prototype.forEach.call(ssrStyles, function(node2) {
|
|
2132
|
-
var dataEmotionAttribute = node2.getAttribute("data-emotion");
|
|
2133
|
-
if (dataEmotionAttribute.indexOf(" ") === -1) {
|
|
2134
|
-
return;
|
|
2135
|
-
}
|
|
2136
|
-
document.head.appendChild(node2);
|
|
2137
|
-
node2.setAttribute("data-s", "");
|
|
2138
|
-
});
|
|
2139
|
-
}
|
|
2140
|
-
var stylisPlugins = options.stylisPlugins || defaultStylisPlugins;
|
|
2141
|
-
if (true) {
|
|
2142
|
-
if (/[^a-z-]/.test(key)) {
|
|
2143
|
-
throw new Error('Emotion key must only contain lower case alphabetical characters and - but "' + key + '" was passed');
|
|
2144
|
-
}
|
|
2145
|
-
}
|
|
2146
|
-
var inserted = {};
|
|
2147
|
-
var container;
|
|
2148
|
-
var nodesToHydrate = [];
|
|
2149
|
-
if (isBrowser) {
|
|
2150
|
-
container = options.container || document.head;
|
|
2151
|
-
Array.prototype.forEach.call(
|
|
2152
|
-
// this means we will ignore elements which don't have a space in them which
|
|
2153
|
-
// means that the style elements we're looking at are only Emotion 11 server-rendered style elements
|
|
2154
|
-
document.querySelectorAll('style[data-emotion^="' + key + ' "]'),
|
|
2155
|
-
function(node2) {
|
|
2156
|
-
var attrib = node2.getAttribute("data-emotion").split(" ");
|
|
2157
|
-
for (var i = 1; i < attrib.length; i++) {
|
|
2158
|
-
inserted[attrib[i]] = true;
|
|
2159
|
-
}
|
|
2160
|
-
nodesToHydrate.push(node2);
|
|
2161
|
-
}
|
|
2162
|
-
);
|
|
2163
|
-
}
|
|
2164
|
-
var _insert;
|
|
2165
|
-
var omnipresentPlugins = [compat, removeLabel];
|
|
2166
|
-
if (true) {
|
|
2167
|
-
omnipresentPlugins.push(createUnsafeSelectorsAlarm({
|
|
2168
|
-
get compat() {
|
|
2169
|
-
return cache.compat;
|
|
2170
|
-
}
|
|
2171
|
-
}), incorrectImportAlarm);
|
|
2172
|
-
}
|
|
2173
|
-
if (isBrowser) {
|
|
2174
|
-
var currentSheet;
|
|
2175
|
-
var finalizingPlugins = [stringify, true ? function(element) {
|
|
2176
|
-
if (!element.root) {
|
|
2177
|
-
if (element["return"]) {
|
|
2178
|
-
currentSheet.insert(element["return"]);
|
|
2179
|
-
} else if (element.value && element.type !== COMMENT) {
|
|
2180
|
-
currentSheet.insert(element.value + "{}");
|
|
2181
|
-
}
|
|
2182
|
-
}
|
|
2183
|
-
} : rulesheet(function(rule) {
|
|
2184
|
-
currentSheet.insert(rule);
|
|
2185
|
-
})];
|
|
2186
|
-
var serializer = middleware(omnipresentPlugins.concat(stylisPlugins, finalizingPlugins));
|
|
2187
|
-
var stylis = function stylis2(styles13) {
|
|
2188
|
-
return serialize(compile(styles13), serializer);
|
|
2189
|
-
};
|
|
2190
|
-
_insert = function insert(selector, serialized, sheet, shouldCache) {
|
|
2191
|
-
currentSheet = sheet;
|
|
2192
|
-
if (serialized.map !== void 0) {
|
|
2193
|
-
currentSheet = {
|
|
2194
|
-
insert: function insert2(rule) {
|
|
2195
|
-
sheet.insert(rule + serialized.map);
|
|
2196
|
-
}
|
|
2197
|
-
};
|
|
2198
|
-
}
|
|
2199
|
-
stylis(selector ? selector + "{" + serialized.styles + "}" : serialized.styles);
|
|
2200
|
-
if (shouldCache) {
|
|
2201
|
-
cache.inserted[serialized.name] = true;
|
|
2202
|
-
}
|
|
2203
|
-
};
|
|
2204
|
-
} else {
|
|
2205
|
-
var _finalizingPlugins = [stringify];
|
|
2206
|
-
var _serializer = middleware(omnipresentPlugins.concat(stylisPlugins, _finalizingPlugins));
|
|
2207
|
-
var _stylis = function _stylis2(styles13) {
|
|
2208
|
-
return serialize(compile(styles13), _serializer);
|
|
2209
|
-
};
|
|
2210
|
-
var serverStylisCache = getServerStylisCache(stylisPlugins)(key);
|
|
2211
|
-
var getRules3 = function getRules4(selector, serialized) {
|
|
2212
|
-
var name = serialized.name;
|
|
2213
|
-
if (serverStylisCache[name] === void 0) {
|
|
2214
|
-
serverStylisCache[name] = _stylis(selector ? selector + "{" + serialized.styles + "}" : serialized.styles);
|
|
2215
|
-
}
|
|
2216
|
-
return serverStylisCache[name];
|
|
2217
|
-
};
|
|
2218
|
-
_insert = function _insert2(selector, serialized, sheet, shouldCache) {
|
|
2219
|
-
var name = serialized.name;
|
|
2220
|
-
var rules = getRules3(selector, serialized);
|
|
2221
|
-
if (cache.compat === void 0) {
|
|
2222
|
-
if (shouldCache) {
|
|
2223
|
-
cache.inserted[name] = true;
|
|
2224
|
-
}
|
|
2225
|
-
if (serialized.map !== void 0) {
|
|
2226
|
-
return rules + serialized.map;
|
|
2227
|
-
}
|
|
2228
|
-
return rules;
|
|
2229
|
-
} else {
|
|
2230
|
-
if (shouldCache) {
|
|
2231
|
-
cache.inserted[name] = rules;
|
|
2232
|
-
} else {
|
|
2233
|
-
return rules;
|
|
2234
|
-
}
|
|
2235
|
-
}
|
|
2236
|
-
};
|
|
2237
|
-
}
|
|
2238
|
-
var cache = {
|
|
2239
|
-
key,
|
|
2240
|
-
sheet: new StyleSheet({
|
|
2241
|
-
key,
|
|
2242
|
-
container,
|
|
2243
|
-
nonce: options.nonce,
|
|
2244
|
-
speedy: options.speedy,
|
|
2245
|
-
prepend: options.prepend,
|
|
2246
|
-
insertionPoint: options.insertionPoint
|
|
2247
|
-
}),
|
|
2248
|
-
nonce: options.nonce,
|
|
2249
|
-
inserted,
|
|
2250
|
-
registered: {},
|
|
2251
|
-
insert: _insert
|
|
2252
|
-
};
|
|
2253
|
-
cache.sheet.hydrate(nodesToHydrate);
|
|
2254
|
-
return cache;
|
|
2255
|
-
};
|
|
2256
|
-
|
|
2257
|
-
// node_modules/@emotion/hash/dist/emotion-hash.esm.js
|
|
2258
|
-
function murmur2(str) {
|
|
2259
|
-
var h = 0;
|
|
2260
|
-
var k, i = 0, len = str.length;
|
|
2261
|
-
for (; len >= 4; ++i, len -= 4) {
|
|
2262
|
-
k = str.charCodeAt(i) & 255 | (str.charCodeAt(++i) & 255) << 8 | (str.charCodeAt(++i) & 255) << 16 | (str.charCodeAt(++i) & 255) << 24;
|
|
2263
|
-
k = /* Math.imul(k, m): */
|
|
2264
|
-
(k & 65535) * 1540483477 + ((k >>> 16) * 59797 << 16);
|
|
2265
|
-
k ^= /* k >>> r: */
|
|
2266
|
-
k >>> 24;
|
|
2267
|
-
h = /* Math.imul(k, m): */
|
|
2268
|
-
(k & 65535) * 1540483477 + ((k >>> 16) * 59797 << 16) ^ /* Math.imul(h, m): */
|
|
2269
|
-
(h & 65535) * 1540483477 + ((h >>> 16) * 59797 << 16);
|
|
2270
|
-
}
|
|
2271
|
-
switch (len) {
|
|
2272
|
-
case 3:
|
|
2273
|
-
h ^= (str.charCodeAt(i + 2) & 255) << 16;
|
|
2274
|
-
case 2:
|
|
2275
|
-
h ^= (str.charCodeAt(i + 1) & 255) << 8;
|
|
2276
|
-
case 1:
|
|
2277
|
-
h ^= str.charCodeAt(i) & 255;
|
|
2278
|
-
h = /* Math.imul(h, m): */
|
|
2279
|
-
(h & 65535) * 1540483477 + ((h >>> 16) * 59797 << 16);
|
|
2280
|
-
}
|
|
2281
|
-
h ^= h >>> 13;
|
|
2282
|
-
h = /* Math.imul(h, m): */
|
|
2283
|
-
(h & 65535) * 1540483477 + ((h >>> 16) * 59797 << 16);
|
|
2284
|
-
return ((h ^ h >>> 15) >>> 0).toString(36);
|
|
2285
|
-
}
|
|
2286
|
-
|
|
2287
|
-
// node_modules/@emotion/unitless/dist/emotion-unitless.esm.js
|
|
2288
|
-
var unitlessKeys = {
|
|
2289
|
-
animationIterationCount: 1,
|
|
2290
|
-
aspectRatio: 1,
|
|
2291
|
-
borderImageOutset: 1,
|
|
2292
|
-
borderImageSlice: 1,
|
|
2293
|
-
borderImageWidth: 1,
|
|
2294
|
-
boxFlex: 1,
|
|
2295
|
-
boxFlexGroup: 1,
|
|
2296
|
-
boxOrdinalGroup: 1,
|
|
2297
|
-
columnCount: 1,
|
|
2298
|
-
columns: 1,
|
|
2299
|
-
flex: 1,
|
|
2300
|
-
flexGrow: 1,
|
|
2301
|
-
flexPositive: 1,
|
|
2302
|
-
flexShrink: 1,
|
|
2303
|
-
flexNegative: 1,
|
|
2304
|
-
flexOrder: 1,
|
|
2305
|
-
gridRow: 1,
|
|
2306
|
-
gridRowEnd: 1,
|
|
2307
|
-
gridRowSpan: 1,
|
|
2308
|
-
gridRowStart: 1,
|
|
2309
|
-
gridColumn: 1,
|
|
2310
|
-
gridColumnEnd: 1,
|
|
2311
|
-
gridColumnSpan: 1,
|
|
2312
|
-
gridColumnStart: 1,
|
|
2313
|
-
msGridRow: 1,
|
|
2314
|
-
msGridRowSpan: 1,
|
|
2315
|
-
msGridColumn: 1,
|
|
2316
|
-
msGridColumnSpan: 1,
|
|
2317
|
-
fontWeight: 1,
|
|
2318
|
-
lineHeight: 1,
|
|
2319
|
-
opacity: 1,
|
|
2320
|
-
order: 1,
|
|
2321
|
-
orphans: 1,
|
|
2322
|
-
tabSize: 1,
|
|
2323
|
-
widows: 1,
|
|
2324
|
-
zIndex: 1,
|
|
2325
|
-
zoom: 1,
|
|
2326
|
-
WebkitLineClamp: 1,
|
|
2327
|
-
// SVG-related properties
|
|
2328
|
-
fillOpacity: 1,
|
|
2329
|
-
floodOpacity: 1,
|
|
2330
|
-
stopOpacity: 1,
|
|
2331
|
-
strokeDasharray: 1,
|
|
2332
|
-
strokeDashoffset: 1,
|
|
2333
|
-
strokeMiterlimit: 1,
|
|
2334
|
-
strokeOpacity: 1,
|
|
2335
|
-
strokeWidth: 1
|
|
2336
|
-
};
|
|
2337
|
-
|
|
2338
|
-
// node_modules/@emotion/serialize/dist/emotion-serialize.esm.js
|
|
2339
|
-
var ILLEGAL_ESCAPE_SEQUENCE_ERROR = `You have illegal escape sequence in your template literal, most likely inside content's property value.
|
|
2340
|
-
Because you write your CSS inside a JavaScript string you actually have to do double escaping, so for example "content: '\\00d7';" should become "content: '\\\\00d7';".
|
|
2341
|
-
You can read more about this here:
|
|
2342
|
-
https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_literals#ES2018_revision_of_illegal_escape_sequences`;
|
|
2343
|
-
var UNDEFINED_AS_OBJECT_KEY_ERROR = "You have passed in falsy value as style object's key (can happen when in example you pass unexported component as computed key).";
|
|
2344
|
-
var hyphenateRegex = /[A-Z]|^ms/g;
|
|
2345
|
-
var animationRegex = /_EMO_([^_]+?)_([^]*?)_EMO_/g;
|
|
2346
|
-
var isCustomProperty = function isCustomProperty2(property) {
|
|
2347
|
-
return property.charCodeAt(1) === 45;
|
|
2348
|
-
};
|
|
2349
|
-
var isProcessableValue = function isProcessableValue2(value) {
|
|
2350
|
-
return value != null && typeof value !== "boolean";
|
|
2351
|
-
};
|
|
2352
|
-
var processStyleName = /* @__PURE__ */ memoize(function(styleName) {
|
|
2353
|
-
return isCustomProperty(styleName) ? styleName : styleName.replace(hyphenateRegex, "-$&").toLowerCase();
|
|
2354
|
-
});
|
|
2355
|
-
var processStyleValue = function processStyleValue2(key, value) {
|
|
2356
|
-
switch (key) {
|
|
2357
|
-
case "animation":
|
|
2358
|
-
case "animationName": {
|
|
2359
|
-
if (typeof value === "string") {
|
|
2360
|
-
return value.replace(animationRegex, function(match2, p1, p2) {
|
|
2361
|
-
cursor = {
|
|
2362
|
-
name: p1,
|
|
2363
|
-
styles: p2,
|
|
2364
|
-
next: cursor
|
|
2365
|
-
};
|
|
2366
|
-
return p1;
|
|
2367
|
-
});
|
|
2368
|
-
}
|
|
2369
|
-
}
|
|
2370
|
-
}
|
|
2371
|
-
if (unitlessKeys[key] !== 1 && !isCustomProperty(key) && typeof value === "number" && value !== 0) {
|
|
2372
|
-
return value + "px";
|
|
2373
|
-
}
|
|
2374
|
-
return value;
|
|
2375
|
-
};
|
|
2376
|
-
if (true) {
|
|
2377
|
-
contentValuePattern = /(var|attr|counters?|url|element|(((repeating-)?(linear|radial))|conic)-gradient)\(|(no-)?(open|close)-quote/;
|
|
2378
|
-
contentValues = ["normal", "none", "initial", "inherit", "unset"];
|
|
2379
|
-
oldProcessStyleValue = processStyleValue;
|
|
2380
|
-
msPattern = /^-ms-/;
|
|
2381
|
-
hyphenPattern = /-(.)/g;
|
|
2382
|
-
hyphenatedCache = {};
|
|
2383
|
-
processStyleValue = function processStyleValue3(key, value) {
|
|
2384
|
-
if (key === "content") {
|
|
2385
|
-
if (typeof value !== "string" || contentValues.indexOf(value) === -1 && !contentValuePattern.test(value) && (value.charAt(0) !== value.charAt(value.length - 1) || value.charAt(0) !== '"' && value.charAt(0) !== "'")) {
|
|
2386
|
-
throw new Error("You seem to be using a value for 'content' without quotes, try replacing it with `content: '\"" + value + "\"'`");
|
|
2387
|
-
}
|
|
2388
|
-
}
|
|
2389
|
-
var processed = oldProcessStyleValue(key, value);
|
|
2390
|
-
if (processed !== "" && !isCustomProperty(key) && key.indexOf("-") !== -1 && hyphenatedCache[key] === void 0) {
|
|
2391
|
-
hyphenatedCache[key] = true;
|
|
2392
|
-
console.error("Using kebab-case for css properties in objects is not supported. Did you mean " + key.replace(msPattern, "ms-").replace(hyphenPattern, function(str, _char) {
|
|
2393
|
-
return _char.toUpperCase();
|
|
2394
|
-
}) + "?");
|
|
2395
|
-
}
|
|
2396
|
-
return processed;
|
|
2397
|
-
};
|
|
2398
|
-
}
|
|
2399
|
-
var contentValuePattern;
|
|
2400
|
-
var contentValues;
|
|
2401
|
-
var oldProcessStyleValue;
|
|
2402
|
-
var msPattern;
|
|
2403
|
-
var hyphenPattern;
|
|
2404
|
-
var hyphenatedCache;
|
|
2405
|
-
var noComponentSelectorMessage = "Component selectors can only be used in conjunction with @emotion/babel-plugin, the swc Emotion plugin, or another Emotion-aware compiler transform.";
|
|
2406
|
-
function handleInterpolation(mergedProps, registered, interpolation) {
|
|
2407
|
-
if (interpolation == null) {
|
|
2408
|
-
return "";
|
|
2409
|
-
}
|
|
2410
|
-
if (interpolation.__emotion_styles !== void 0) {
|
|
2411
|
-
if (interpolation.toString() === "NO_COMPONENT_SELECTOR") {
|
|
2412
|
-
throw new Error(noComponentSelectorMessage);
|
|
2413
|
-
}
|
|
2414
|
-
return interpolation;
|
|
2415
|
-
}
|
|
2416
|
-
switch (typeof interpolation) {
|
|
2417
|
-
case "boolean": {
|
|
2418
|
-
return "";
|
|
2419
|
-
}
|
|
2420
|
-
case "object": {
|
|
2421
|
-
if (interpolation.anim === 1) {
|
|
2422
|
-
cursor = {
|
|
2423
|
-
name: interpolation.name,
|
|
2424
|
-
styles: interpolation.styles,
|
|
2425
|
-
next: cursor
|
|
2426
|
-
};
|
|
2427
|
-
return interpolation.name;
|
|
2428
|
-
}
|
|
2429
|
-
if (interpolation.styles !== void 0) {
|
|
2430
|
-
var next2 = interpolation.next;
|
|
2431
|
-
if (next2 !== void 0) {
|
|
2432
|
-
while (next2 !== void 0) {
|
|
2433
|
-
cursor = {
|
|
2434
|
-
name: next2.name,
|
|
2435
|
-
styles: next2.styles,
|
|
2436
|
-
next: cursor
|
|
2437
|
-
};
|
|
2438
|
-
next2 = next2.next;
|
|
2439
|
-
}
|
|
2440
|
-
}
|
|
2441
|
-
var styles13 = interpolation.styles + ";";
|
|
2442
|
-
if (interpolation.map !== void 0) {
|
|
2443
|
-
styles13 += interpolation.map;
|
|
2444
|
-
}
|
|
2445
|
-
return styles13;
|
|
2446
|
-
}
|
|
2447
|
-
return createStringFromObject(mergedProps, registered, interpolation);
|
|
2448
|
-
}
|
|
2449
|
-
case "function": {
|
|
2450
|
-
if (mergedProps !== void 0) {
|
|
2451
|
-
var previousCursor = cursor;
|
|
2452
|
-
var result = interpolation(mergedProps);
|
|
2453
|
-
cursor = previousCursor;
|
|
2454
|
-
return handleInterpolation(mergedProps, registered, result);
|
|
2455
|
-
} else if (true) {
|
|
2456
|
-
console.error("Functions that are interpolated in css calls will be stringified.\nIf you want to have a css call based on props, create a function that returns a css call like this\nlet dynamicStyle = (props) => css`color: ${props.color}`\nIt can be called directly with props or interpolated in a styled call like this\nlet SomeComponent = styled('div')`${dynamicStyle}`");
|
|
2457
|
-
}
|
|
2458
|
-
break;
|
|
2459
|
-
}
|
|
2460
|
-
case "string":
|
|
2461
|
-
if (true) {
|
|
2462
|
-
var matched = [];
|
|
2463
|
-
var replaced = interpolation.replace(animationRegex, function(match2, p1, p2) {
|
|
2464
|
-
var fakeVarName = "animation" + matched.length;
|
|
2465
|
-
matched.push("const " + fakeVarName + " = keyframes`" + p2.replace(/^@keyframes animation-\w+/, "") + "`");
|
|
2466
|
-
return "${" + fakeVarName + "}";
|
|
2467
|
-
});
|
|
2468
|
-
if (matched.length) {
|
|
2469
|
-
console.error("`keyframes` output got interpolated into plain string, please wrap it with `css`.\n\nInstead of doing this:\n\n" + [].concat(matched, ["`" + replaced + "`"]).join("\n") + "\n\nYou should wrap it with `css` like this:\n\n" + ("css`" + replaced + "`"));
|
|
2470
|
-
}
|
|
2471
|
-
}
|
|
2472
|
-
break;
|
|
2473
|
-
}
|
|
2474
|
-
if (registered == null) {
|
|
2475
|
-
return interpolation;
|
|
2476
|
-
}
|
|
2477
|
-
var cached = registered[interpolation];
|
|
2478
|
-
return cached !== void 0 ? cached : interpolation;
|
|
2479
|
-
}
|
|
2480
|
-
function createStringFromObject(mergedProps, registered, obj) {
|
|
2481
|
-
var string = "";
|
|
2482
|
-
if (Array.isArray(obj)) {
|
|
2483
|
-
for (var i = 0; i < obj.length; i++) {
|
|
2484
|
-
string += handleInterpolation(mergedProps, registered, obj[i]) + ";";
|
|
2485
|
-
}
|
|
2486
|
-
} else {
|
|
2487
|
-
for (var _key in obj) {
|
|
2488
|
-
var value = obj[_key];
|
|
2489
|
-
if (typeof value !== "object") {
|
|
2490
|
-
if (registered != null && registered[value] !== void 0) {
|
|
2491
|
-
string += _key + "{" + registered[value] + "}";
|
|
2492
|
-
} else if (isProcessableValue(value)) {
|
|
2493
|
-
string += processStyleName(_key) + ":" + processStyleValue(_key, value) + ";";
|
|
2494
|
-
}
|
|
2495
|
-
} else {
|
|
2496
|
-
if (_key === "NO_COMPONENT_SELECTOR" && true) {
|
|
2497
|
-
throw new Error(noComponentSelectorMessage);
|
|
2498
|
-
}
|
|
2499
|
-
if (Array.isArray(value) && typeof value[0] === "string" && (registered == null || registered[value[0]] === void 0)) {
|
|
2500
|
-
for (var _i = 0; _i < value.length; _i++) {
|
|
2501
|
-
if (isProcessableValue(value[_i])) {
|
|
2502
|
-
string += processStyleName(_key) + ":" + processStyleValue(_key, value[_i]) + ";";
|
|
2503
|
-
}
|
|
2504
|
-
}
|
|
2505
|
-
} else {
|
|
2506
|
-
var interpolated = handleInterpolation(mergedProps, registered, value);
|
|
2507
|
-
switch (_key) {
|
|
2508
|
-
case "animation":
|
|
2509
|
-
case "animationName": {
|
|
2510
|
-
string += processStyleName(_key) + ":" + interpolated + ";";
|
|
2511
|
-
break;
|
|
2512
|
-
}
|
|
2513
|
-
default: {
|
|
2514
|
-
if (_key === "undefined") {
|
|
2515
|
-
console.error(UNDEFINED_AS_OBJECT_KEY_ERROR);
|
|
2516
|
-
}
|
|
2517
|
-
string += _key + "{" + interpolated + "}";
|
|
2518
|
-
}
|
|
2519
|
-
}
|
|
2520
|
-
}
|
|
2521
|
-
}
|
|
2522
|
-
}
|
|
2523
|
-
}
|
|
2524
|
-
return string;
|
|
2525
|
-
}
|
|
2526
|
-
var labelPattern = /label:\s*([^\s;\n{]+)\s*(;|$)/g;
|
|
2527
|
-
var sourceMapPattern;
|
|
2528
|
-
if (true) {
|
|
2529
|
-
sourceMapPattern = /\/\*#\ssourceMappingURL=data:application\/json;\S+\s+\*\//g;
|
|
2530
|
-
}
|
|
2531
|
-
var cursor;
|
|
2532
|
-
var serializeStyles = function serializeStyles2(args, registered, mergedProps) {
|
|
2533
|
-
if (args.length === 1 && typeof args[0] === "object" && args[0] !== null && args[0].styles !== void 0) {
|
|
2534
|
-
return args[0];
|
|
2535
|
-
}
|
|
2536
|
-
var stringMode = true;
|
|
2537
|
-
var styles13 = "";
|
|
2538
|
-
cursor = void 0;
|
|
2539
|
-
var strings = args[0];
|
|
2540
|
-
if (strings == null || strings.raw === void 0) {
|
|
2541
|
-
stringMode = false;
|
|
2542
|
-
styles13 += handleInterpolation(mergedProps, registered, strings);
|
|
2543
|
-
} else {
|
|
2544
|
-
if (strings[0] === void 0) {
|
|
2545
|
-
console.error(ILLEGAL_ESCAPE_SEQUENCE_ERROR);
|
|
2546
|
-
}
|
|
2547
|
-
styles13 += strings[0];
|
|
2548
|
-
}
|
|
2549
|
-
for (var i = 1; i < args.length; i++) {
|
|
2550
|
-
styles13 += handleInterpolation(mergedProps, registered, args[i]);
|
|
2551
|
-
if (stringMode) {
|
|
2552
|
-
if (strings[i] === void 0) {
|
|
2553
|
-
console.error(ILLEGAL_ESCAPE_SEQUENCE_ERROR);
|
|
2554
|
-
}
|
|
2555
|
-
styles13 += strings[i];
|
|
2556
|
-
}
|
|
2557
|
-
}
|
|
2558
|
-
var sourceMap;
|
|
2559
|
-
if (true) {
|
|
2560
|
-
styles13 = styles13.replace(sourceMapPattern, function(match3) {
|
|
2561
|
-
sourceMap = match3;
|
|
2562
|
-
return "";
|
|
2563
|
-
});
|
|
2564
|
-
}
|
|
2565
|
-
labelPattern.lastIndex = 0;
|
|
2566
|
-
var identifierName = "";
|
|
2567
|
-
var match2;
|
|
2568
|
-
while ((match2 = labelPattern.exec(styles13)) !== null) {
|
|
2569
|
-
identifierName += "-" + // $FlowFixMe we know it's not null
|
|
2570
|
-
match2[1];
|
|
2571
|
-
}
|
|
2572
|
-
var name = murmur2(styles13) + identifierName;
|
|
2573
|
-
if (true) {
|
|
2574
|
-
return {
|
|
2575
|
-
name,
|
|
2576
|
-
styles: styles13,
|
|
2577
|
-
map: sourceMap,
|
|
2578
|
-
next: cursor,
|
|
2579
|
-
toString: function toString() {
|
|
2580
|
-
return "You have tried to stringify object returned from `css` function. It isn't supposed to be used directly (e.g. as value of the `className` prop), but rather handed to emotion so it can handle it (e.g. as value of `css` prop).";
|
|
2581
|
-
}
|
|
2582
|
-
};
|
|
2583
|
-
}
|
|
2584
|
-
return {
|
|
2585
|
-
name,
|
|
2586
|
-
styles: styles13,
|
|
2587
|
-
next: cursor
|
|
2588
|
-
};
|
|
2589
|
-
};
|
|
2590
|
-
|
|
2591
|
-
// node_modules/@emotion/utils/dist/emotion-utils.esm.js
|
|
2592
|
-
var isBrowser2 = typeof document !== "undefined";
|
|
2593
|
-
function getRegisteredStyles(registered, registeredStyles, classNames) {
|
|
2594
|
-
var rawClassName = "";
|
|
2595
|
-
classNames.split(" ").forEach(function(className) {
|
|
2596
|
-
if (registered[className] !== void 0) {
|
|
2597
|
-
registeredStyles.push(registered[className] + ";");
|
|
2598
|
-
} else {
|
|
2599
|
-
rawClassName += className + " ";
|
|
2600
|
-
}
|
|
2601
|
-
});
|
|
2602
|
-
return rawClassName;
|
|
2603
|
-
}
|
|
2604
|
-
var registerStyles = function registerStyles2(cache, serialized, isStringTag) {
|
|
2605
|
-
var className = cache.key + "-" + serialized.name;
|
|
2606
|
-
if (
|
|
2607
|
-
// we only need to add the styles to the registered cache if the
|
|
2608
|
-
// class name could be used further down
|
|
2609
|
-
// the tree but if it's a string tag, we know it won't
|
|
2610
|
-
// so we don't have to add it to registered cache.
|
|
2611
|
-
// this improves memory usage since we can avoid storing the whole style string
|
|
2612
|
-
(isStringTag === false || // we need to always store it if we're in compat mode and
|
|
2613
|
-
// in node since emotion-server relies on whether a style is in
|
|
2614
|
-
// the registered cache to know whether a style is global or not
|
|
2615
|
-
// also, note that this check will be dead code eliminated in the browser
|
|
2616
|
-
isBrowser2 === false && cache.compat !== void 0) && cache.registered[className] === void 0
|
|
2617
|
-
) {
|
|
2618
|
-
cache.registered[className] = serialized.styles;
|
|
2619
|
-
}
|
|
2620
|
-
};
|
|
2621
|
-
var insertStyles = function insertStyles2(cache, serialized, isStringTag) {
|
|
2622
|
-
registerStyles(cache, serialized, isStringTag);
|
|
2623
|
-
var className = cache.key + "-" + serialized.name;
|
|
2624
|
-
if (cache.inserted[serialized.name] === void 0) {
|
|
2625
|
-
var stylesForSSR = "";
|
|
2626
|
-
var current = serialized;
|
|
2627
|
-
do {
|
|
2628
|
-
var maybeStyles = cache.insert(serialized === current ? "." + className : "", current, cache.sheet, true);
|
|
2629
|
-
if (!isBrowser2 && maybeStyles !== void 0) {
|
|
2630
|
-
stylesForSSR += maybeStyles;
|
|
2631
|
-
}
|
|
2632
|
-
current = current.next;
|
|
2633
|
-
} while (current !== void 0);
|
|
2634
|
-
if (!isBrowser2 && stylesForSSR.length !== 0) {
|
|
2635
|
-
return stylesForSSR;
|
|
2636
|
-
}
|
|
2637
|
-
}
|
|
2638
|
-
};
|
|
2639
|
-
|
|
2640
|
-
// node_modules/@emotion/css/create-instance/dist/emotion-css-create-instance.esm.js
|
|
2641
|
-
function insertWithoutScoping(cache, serialized) {
|
|
2642
|
-
if (cache.inserted[serialized.name] === void 0) {
|
|
2643
|
-
return cache.insert("", serialized, cache.sheet, true);
|
|
2644
|
-
}
|
|
2645
|
-
}
|
|
2646
|
-
function merge(registered, css, className) {
|
|
2647
|
-
var registeredStyles = [];
|
|
2648
|
-
var rawClassName = getRegisteredStyles(registered, registeredStyles, className);
|
|
2649
|
-
if (registeredStyles.length < 2) {
|
|
2650
|
-
return className;
|
|
2651
|
-
}
|
|
2652
|
-
return rawClassName + css(registeredStyles);
|
|
2653
|
-
}
|
|
2654
|
-
var createEmotion = function createEmotion2(options) {
|
|
2655
|
-
var cache = createCache(options);
|
|
2656
|
-
cache.sheet.speedy = function(value) {
|
|
2657
|
-
if (this.ctr !== 0) {
|
|
2658
|
-
throw new Error("speedy must be changed before any rules are inserted");
|
|
2659
|
-
}
|
|
2660
|
-
this.isSpeedy = value;
|
|
2661
|
-
};
|
|
2662
|
-
cache.compat = true;
|
|
2663
|
-
var css = function css2() {
|
|
2664
|
-
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
2665
|
-
args[_key] = arguments[_key];
|
|
2666
|
-
}
|
|
2667
|
-
var serialized = serializeStyles(args, cache.registered, void 0);
|
|
2668
|
-
insertStyles(cache, serialized, false);
|
|
2669
|
-
return cache.key + "-" + serialized.name;
|
|
2670
|
-
};
|
|
2671
|
-
var keyframes = function keyframes2() {
|
|
2672
|
-
for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {
|
|
2673
|
-
args[_key2] = arguments[_key2];
|
|
2674
|
-
}
|
|
2675
|
-
var serialized = serializeStyles(args, cache.registered);
|
|
2676
|
-
var animation = "animation-" + serialized.name;
|
|
2677
|
-
insertWithoutScoping(cache, {
|
|
2678
|
-
name: serialized.name,
|
|
2679
|
-
styles: "@keyframes " + animation + "{" + serialized.styles + "}"
|
|
2680
|
-
});
|
|
2681
|
-
return animation;
|
|
2682
|
-
};
|
|
2683
|
-
var injectGlobal = function injectGlobal2() {
|
|
2684
|
-
for (var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) {
|
|
2685
|
-
args[_key3] = arguments[_key3];
|
|
2686
|
-
}
|
|
2687
|
-
var serialized = serializeStyles(args, cache.registered);
|
|
2688
|
-
insertWithoutScoping(cache, serialized);
|
|
2689
|
-
};
|
|
2690
|
-
var cx7 = function cx8() {
|
|
2691
|
-
for (var _len4 = arguments.length, args = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) {
|
|
2692
|
-
args[_key4] = arguments[_key4];
|
|
2693
|
-
}
|
|
2694
|
-
return merge(cache.registered, css, classnames(args));
|
|
2695
|
-
};
|
|
2696
|
-
return {
|
|
2697
|
-
css,
|
|
2698
|
-
cx: cx7,
|
|
2699
|
-
injectGlobal,
|
|
2700
|
-
keyframes,
|
|
2701
|
-
hydrate: function hydrate(ids) {
|
|
2702
|
-
ids.forEach(function(key) {
|
|
2703
|
-
cache.inserted[key] = true;
|
|
2704
|
-
});
|
|
2705
|
-
},
|
|
2706
|
-
flush: function flush() {
|
|
2707
|
-
cache.registered = {};
|
|
2708
|
-
cache.inserted = {};
|
|
2709
|
-
cache.sheet.flush();
|
|
2710
|
-
},
|
|
2711
|
-
// $FlowFixMe
|
|
2712
|
-
sheet: cache.sheet,
|
|
2713
|
-
cache,
|
|
2714
|
-
getRegisteredStyles: getRegisteredStyles.bind(null, cache.registered),
|
|
2715
|
-
merge: merge.bind(null, cache.registered, css)
|
|
2716
|
-
};
|
|
2717
|
-
};
|
|
2718
|
-
var classnames = function classnames2(args) {
|
|
2719
|
-
var cls = "";
|
|
2720
|
-
for (var i = 0; i < args.length; i++) {
|
|
2721
|
-
var arg = args[i];
|
|
2722
|
-
if (arg == null)
|
|
2723
|
-
continue;
|
|
2724
|
-
var toAdd = void 0;
|
|
2725
|
-
switch (typeof arg) {
|
|
2726
|
-
case "boolean":
|
|
2727
|
-
break;
|
|
2728
|
-
case "object": {
|
|
2729
|
-
if (Array.isArray(arg)) {
|
|
2730
|
-
toAdd = classnames2(arg);
|
|
2731
|
-
} else {
|
|
2732
|
-
toAdd = "";
|
|
2733
|
-
for (var k in arg) {
|
|
2734
|
-
if (arg[k] && k) {
|
|
2735
|
-
toAdd && (toAdd += " ");
|
|
2736
|
-
toAdd += k;
|
|
2737
|
-
}
|
|
2738
|
-
}
|
|
2739
|
-
}
|
|
2740
|
-
break;
|
|
2741
|
-
}
|
|
2742
|
-
default: {
|
|
2743
|
-
toAdd = arg;
|
|
2744
|
-
}
|
|
2745
|
-
}
|
|
2746
|
-
if (toAdd) {
|
|
2747
|
-
cls && (cls += " ");
|
|
2748
|
-
cls += toAdd;
|
|
2749
|
-
}
|
|
2750
|
-
}
|
|
2751
|
-
return cls;
|
|
2752
|
-
};
|
|
2753
|
-
|
|
2754
|
-
// src/private/useStyleToEmotionObject.ts
|
|
2755
|
-
var import_react4 = __toESM(require_react());
|
|
2756
|
-
var { random } = Math;
|
|
2757
|
-
var emotionPool = {};
|
|
2758
|
-
var nonce = "";
|
|
2759
|
-
function createCSSKey() {
|
|
2760
|
-
return random().toString(26).substr(2, 5).replace(/\d/gu, (value) => String.fromCharCode(value.charCodeAt(0) + 65));
|
|
2761
|
-
}
|
|
2762
|
-
function useStyleToEmotionObject() {
|
|
2763
|
-
return (0, import_react4.useMemo)(() => {
|
|
2764
|
-
const emotion = (
|
|
2765
|
-
// Prefix "id-" to prevent object injection attack.
|
|
2766
|
-
emotionPool[`id-${nonce}`] || (emotionPool[`id-${nonce}`] = createEmotion({ key: `webchat--css-${createCSSKey()}`, nonce }))
|
|
2767
|
-
);
|
|
2768
|
-
return (style) => emotion.css(style);
|
|
2769
|
-
}, []);
|
|
2770
|
-
}
|
|
2771
|
-
|
|
2772
|
-
// src/styles/index.ts
|
|
2773
|
-
function useStyles(styles13) {
|
|
2774
|
-
const getClassName = useStyleToEmotionObject();
|
|
2775
|
-
return (0, import_react5.useMemo)(
|
|
2776
|
-
() => Object.freeze(
|
|
2777
|
-
Object.fromEntries(Object.entries(styles13).map(([cls, style]) => [cls, `${cls} ${getClassName(style)}`]))
|
|
2778
|
-
),
|
|
2779
|
-
[styles13, getClassName]
|
|
2780
|
-
);
|
|
2781
|
-
}
|
|
2782
|
-
|
|
2783
|
-
// src/components/telephoneKeypad/private/Button.tsx
|
|
2784
|
-
var import_react6 = __toESM(require_react());
|
|
2785
|
-
var styles = {
|
|
2786
|
-
"webchat__telephone-keypad__button": {
|
|
2787
|
-
"-webkit-user-select": "none",
|
|
2788
|
-
alignItems: "center",
|
|
2789
|
-
appearance: "none",
|
|
2790
|
-
// backgroundColor: isDarkTheme() || isHighContrastTheme() ? black : white,
|
|
2791
|
-
backgroundColor: "White",
|
|
2792
|
-
borderRadius: "100%",
|
|
2793
|
-
// Whitelabel styles
|
|
2794
|
-
// border: `solid 1px ${isHighContrastTheme() ? white : isDarkTheme() ? gray160 : gray40}`,
|
|
2795
|
-
// color: 'inherit',
|
|
2796
|
-
border: "solid 1px var(--webchat-colorNeutralStroke1)",
|
|
2797
|
-
color: "var(--webchat-colorGray200)",
|
|
2798
|
-
fontWeight: "var(--webchat-fontWeightSemibold)",
|
|
2799
|
-
cursor: "pointer",
|
|
2800
|
-
display: "flex",
|
|
2801
|
-
flexDirection: "column",
|
|
2802
|
-
height: 60,
|
|
2803
|
-
opacity: 0.7,
|
|
2804
|
-
padding: 0,
|
|
2805
|
-
position: "relative",
|
|
2806
|
-
touchAction: "none",
|
|
2807
|
-
userSelect: "none",
|
|
2808
|
-
width: 60,
|
|
2809
|
-
"&:hover": {
|
|
2810
|
-
// backgroundColor: isHighContrastTheme() ? gray210 : isDarkTheme() ? gray150 : gray30
|
|
2811
|
-
backgroundColor: "var(--webchat-colorGray30)"
|
|
2812
|
-
}
|
|
2813
|
-
},
|
|
2814
|
-
"webchat__telephone-keypad__button__ruby": {
|
|
2815
|
-
// color: isHighContrastTheme() ? white : isDarkTheme() ? gray40 : gray160,
|
|
2816
|
-
color: "var(--webchat-colorGray190)",
|
|
2817
|
-
fontSize: 10
|
|
2818
|
-
},
|
|
2819
|
-
"webchat__telephone-keypad__button__text": {
|
|
2820
|
-
fontSize: 24,
|
|
2821
|
-
marginTop: 8
|
|
2822
|
-
},
|
|
2823
|
-
"webchat__telephone-keypad--horizontal": {
|
|
2824
|
-
"& .webchat__telephone-keypad__button": {
|
|
2825
|
-
height: 32,
|
|
2826
|
-
width: 32,
|
|
2827
|
-
margin: "8px 4px",
|
|
2828
|
-
justifyContent: "center"
|
|
2829
|
-
},
|
|
2830
|
-
"webchat__telephone-keypad__button__ruby": {
|
|
2831
|
-
display: "none"
|
|
2832
|
-
},
|
|
2833
|
-
"& .webchat__telephone-keypad__button__text": {
|
|
2834
|
-
fontSize: 20,
|
|
2835
|
-
marginTop: 0
|
|
2836
|
-
}
|
|
2837
|
-
}
|
|
2838
|
-
};
|
|
2839
|
-
var Button = (0, import_react6.memo)(
|
|
2840
|
-
// As we are all TypeScript, internal components do not need propTypes.
|
|
2841
|
-
// eslint-disable-next-line react/prop-types
|
|
2842
|
-
(0, import_react6.forwardRef)(({ button, "data-testid": dataTestId, onClick, ruby }, ref) => {
|
|
2843
|
-
const classNames = useStyles(styles);
|
|
2844
|
-
const onClickRef = useRefFrom(onClick);
|
|
2845
|
-
const handleClick = (0, import_react6.useCallback)(() => onClickRef.current?.(), [onClickRef]);
|
|
2846
|
-
return /* @__PURE__ */ import_react6.default.createElement(
|
|
2847
|
-
"button",
|
|
2848
|
-
{
|
|
2849
|
-
className: classNames["webchat__telephone-keypad__button"],
|
|
2850
|
-
"data-testid": dataTestId,
|
|
2851
|
-
onClick: handleClick,
|
|
2852
|
-
ref,
|
|
2853
|
-
type: "button"
|
|
2854
|
-
},
|
|
2855
|
-
/* @__PURE__ */ import_react6.default.createElement("span", { className: classNames["webchat__telephone-keypad__button__text"] }, button === "star" ? "\u2217" : button === "pound" ? "#" : button),
|
|
2856
|
-
!!ruby && /* @__PURE__ */ import_react6.default.createElement("ruby", { className: classNames["webchat__telephone-keypad__button__ruby"] }, ruby)
|
|
2857
|
-
);
|
|
2858
|
-
})
|
|
2859
|
-
);
|
|
2860
|
-
Button.displayName = "TelephoneKeypad.Button";
|
|
2861
|
-
var Button_default = Button;
|
|
2862
|
-
|
|
2863
|
-
// src/testIds.ts
|
|
2864
|
-
var testIds = {
|
|
2865
|
-
sendBoxDropZone: "send box drop zone",
|
|
2866
|
-
sendBoxSendButton: "send box send button",
|
|
2867
|
-
sendBoxTextBox: "send box text area",
|
|
2868
|
-
sendBoxTelephoneKeypadButton1: `send box telephone keypad button 1`,
|
|
2869
|
-
sendBoxTelephoneKeypadButton2: `send box telephone keypad button 2`,
|
|
2870
|
-
sendBoxTelephoneKeypadButton3: `send box telephone keypad button 3`,
|
|
2871
|
-
sendBoxTelephoneKeypadButton4: `send box telephone keypad button 4`,
|
|
2872
|
-
sendBoxTelephoneKeypadButton5: `send box telephone keypad button 5`,
|
|
2873
|
-
sendBoxTelephoneKeypadButton6: `send box telephone keypad button 6`,
|
|
2874
|
-
sendBoxTelephoneKeypadButton7: `send box telephone keypad button 7`,
|
|
2875
|
-
sendBoxTelephoneKeypadButton8: `send box telephone keypad button 8`,
|
|
2876
|
-
sendBoxTelephoneKeypadButton9: `send box telephone keypad button 9`,
|
|
2877
|
-
sendBoxTelephoneKeypadButton0: `send box telephone keypad button 0`,
|
|
2878
|
-
sendBoxTelephoneKeypadButtonStar: `send box telephone keypad button star`,
|
|
2879
|
-
sendBoxTelephoneKeypadButtonPound: `send box telephone keypad button pound`,
|
|
2880
|
-
sendBoxTelephoneKeypadToolbarButton: "send box telephone keypad toolbar button",
|
|
2881
|
-
sendBoxUploadButton: "send box upload button"
|
|
2882
|
-
};
|
|
2883
|
-
var testIds_default = testIds;
|
|
2884
|
-
|
|
2885
|
-
// src/components/telephoneKeypad/useShown.ts
|
|
2886
|
-
var import_react7 = __toESM(require_react());
|
|
2887
|
-
function useShown() {
|
|
2888
|
-
const { setShown, shown } = (0, import_react7.useContext)(Context_default);
|
|
2889
|
-
return (0, import_react7.useMemo)(() => Object.freeze([shown, setShown]), [shown, setShown]);
|
|
2890
|
-
}
|
|
2891
|
-
|
|
2892
|
-
// src/components/telephoneKeypad/private/TelephoneKeypad.tsx
|
|
2893
|
-
var styles2 = {
|
|
2894
|
-
"webchat__telephone-keypad": {
|
|
2895
|
-
/* Commented out whitelabel styles for now. */
|
|
2896
|
-
// background: getHighContrastDarkThemeColor(highContrastColor: black, darkThemeColor: gray190, string, defaultColor: gray10),
|
|
2897
|
-
// borderRadius: '8px 8px 0px 0px',
|
|
2898
|
-
// boxShadow: '-3px 0px 7px 0px rgba(0, 0, 0, 0.13), -0.6px 0px 1.8px 0px rgba(0, 0, 0, 0.10)',
|
|
2899
|
-
alignItems: "center",
|
|
2900
|
-
background: "var(--webchat-colorNeutralBackground1)",
|
|
2901
|
-
// border: isHighContrastTheme() ? `1px solid ${white}` : 'none',
|
|
2902
|
-
border: "none",
|
|
2903
|
-
borderRadius: "var(--webchat-borderRadiusXLarge)",
|
|
2904
|
-
// boxShadow: 'var(--shadow16)',
|
|
2905
|
-
display: "flex",
|
|
2906
|
-
flexDirection: "column",
|
|
2907
|
-
fontFamily: "var(--webchat-fontFamilyBase)",
|
|
2908
|
-
justifyContent: "center"
|
|
2909
|
-
// margin: 'var(--spacingHorizontalMNudge)'
|
|
2910
|
-
},
|
|
2911
|
-
"webchat__telephone-keypad__box": {
|
|
2912
|
-
boxSizing: "border-box",
|
|
2913
|
-
display: "grid",
|
|
2914
|
-
gap: "16px",
|
|
2915
|
-
gridTemplateColumns: "repeat(3, 1fr)",
|
|
2916
|
-
gridTemplateRows: "repeat(4, 1fr)",
|
|
2917
|
-
justifyItems: "center",
|
|
2918
|
-
padding: "16px",
|
|
2919
|
-
width: "100%"
|
|
2920
|
-
}
|
|
2921
|
-
};
|
|
2922
|
-
var Orientation = (0, import_react8.memo)(
|
|
2923
|
-
({ children, isHorizontal }) => {
|
|
2924
|
-
const classNames = useStyles(styles2);
|
|
2925
|
-
return isHorizontal ? (
|
|
2926
|
-
// <HorizontalDialPadController>{children}</HorizontalDialPadController>
|
|
2927
|
-
false
|
|
2928
|
-
) : /* @__PURE__ */ import_react8.default.createElement("div", { className: classNames["webchat__telephone-keypad__box"] }, children);
|
|
1463
|
+
)
|
|
1464
|
+
));
|
|
1465
|
+
|
|
1466
|
+
// src/components/telephoneKeypad/private/TelephoneKeypad.tsx
|
|
1467
|
+
var { LocalizedString } = import_botframework_webchat_component.Components;
|
|
1468
|
+
var Orientation = (0, import_react8.memo)(
|
|
1469
|
+
({ children, isHorizontal }) => {
|
|
1470
|
+
const classNames = useStyles_default(TelephoneKeypad_default);
|
|
1471
|
+
return isHorizontal ? (
|
|
1472
|
+
// <HorizontalDialPadController>{children}</HorizontalDialPadController>
|
|
1473
|
+
false
|
|
1474
|
+
) : /* @__PURE__ */ import_react8.default.createElement("div", { className: classNames["telephone-keypad__box"] }, children);
|
|
2929
1475
|
}
|
|
2930
1476
|
);
|
|
2931
1477
|
Orientation.displayName = "TelephoneKeypad:Orientation";
|
|
2932
|
-
var TelephoneKeypad = (0, import_react8.memo)(({ autoFocus, onButtonClick, isHorizontal }) => {
|
|
1478
|
+
var TelephoneKeypad = (0, import_react8.memo)(({ autoFocus, className, onButtonClick, isHorizontal }) => {
|
|
2933
1479
|
const autoFocusRef = useRefFrom(autoFocus);
|
|
2934
|
-
const classNames =
|
|
1480
|
+
const classNames = useStyles_default(TelephoneKeypad_default);
|
|
2935
1481
|
const firstButtonRef = (0, import_react8.useRef)(null);
|
|
2936
1482
|
const onButtonClickRef = useRefFrom(onButtonClick);
|
|
2937
1483
|
const [, setShown] = useShown();
|
|
@@ -2958,8 +1504,8 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
2958
1504
|
(0, import_react8.useEffect)(() => {
|
|
2959
1505
|
autoFocusRef.current && firstButtonRef.current?.focus();
|
|
2960
1506
|
}, [autoFocusRef, firstButtonRef]);
|
|
2961
|
-
return /* @__PURE__ */ import_react8.default.createElement("div", { className: classNames["
|
|
2962
|
-
|
|
1507
|
+
return /* @__PURE__ */ import_react8.default.createElement("div", { className: (0, import_classnames.default)(classNames["telephone-keypad"], className), onKeyDown: handleKeyDown }, /* @__PURE__ */ import_react8.default.createElement(Orientation, { isHorizontal }, /* @__PURE__ */ import_react8.default.createElement(
|
|
1508
|
+
Button_default2,
|
|
2963
1509
|
{
|
|
2964
1510
|
button: "1",
|
|
2965
1511
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButton1,
|
|
@@ -2967,7 +1513,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
2967
1513
|
ref: firstButtonRef
|
|
2968
1514
|
}
|
|
2969
1515
|
), /* @__PURE__ */ import_react8.default.createElement(
|
|
2970
|
-
|
|
1516
|
+
Button_default2,
|
|
2971
1517
|
{
|
|
2972
1518
|
button: "2",
|
|
2973
1519
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButton2,
|
|
@@ -2975,7 +1521,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
2975
1521
|
ruby: "ABC"
|
|
2976
1522
|
}
|
|
2977
1523
|
), /* @__PURE__ */ import_react8.default.createElement(
|
|
2978
|
-
|
|
1524
|
+
Button_default2,
|
|
2979
1525
|
{
|
|
2980
1526
|
button: "3",
|
|
2981
1527
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButton3,
|
|
@@ -2983,7 +1529,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
2983
1529
|
ruby: "DEF"
|
|
2984
1530
|
}
|
|
2985
1531
|
), /* @__PURE__ */ import_react8.default.createElement(
|
|
2986
|
-
|
|
1532
|
+
Button_default2,
|
|
2987
1533
|
{
|
|
2988
1534
|
button: "4",
|
|
2989
1535
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButton4,
|
|
@@ -2991,7 +1537,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
2991
1537
|
ruby: "GHI"
|
|
2992
1538
|
}
|
|
2993
1539
|
), /* @__PURE__ */ import_react8.default.createElement(
|
|
2994
|
-
|
|
1540
|
+
Button_default2,
|
|
2995
1541
|
{
|
|
2996
1542
|
button: "5",
|
|
2997
1543
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButton5,
|
|
@@ -2999,7 +1545,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
2999
1545
|
ruby: "JKL"
|
|
3000
1546
|
}
|
|
3001
1547
|
), /* @__PURE__ */ import_react8.default.createElement(
|
|
3002
|
-
|
|
1548
|
+
Button_default2,
|
|
3003
1549
|
{
|
|
3004
1550
|
button: "6",
|
|
3005
1551
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButton6,
|
|
@@ -3007,7 +1553,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3007
1553
|
ruby: "MNO"
|
|
3008
1554
|
}
|
|
3009
1555
|
), /* @__PURE__ */ import_react8.default.createElement(
|
|
3010
|
-
|
|
1556
|
+
Button_default2,
|
|
3011
1557
|
{
|
|
3012
1558
|
button: "7",
|
|
3013
1559
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButton7,
|
|
@@ -3015,7 +1561,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3015
1561
|
ruby: "PQRS"
|
|
3016
1562
|
}
|
|
3017
1563
|
), /* @__PURE__ */ import_react8.default.createElement(
|
|
3018
|
-
|
|
1564
|
+
Button_default2,
|
|
3019
1565
|
{
|
|
3020
1566
|
button: "8",
|
|
3021
1567
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButton8,
|
|
@@ -3023,86 +1569,55 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3023
1569
|
ruby: "TUV"
|
|
3024
1570
|
}
|
|
3025
1571
|
), /* @__PURE__ */ import_react8.default.createElement(
|
|
3026
|
-
|
|
1572
|
+
Button_default2,
|
|
3027
1573
|
{
|
|
3028
1574
|
button: "9",
|
|
3029
1575
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButton9,
|
|
3030
1576
|
onClick: handleButton9Click,
|
|
3031
1577
|
ruby: "WXYZ"
|
|
3032
1578
|
}
|
|
3033
|
-
), /* @__PURE__ */ import_react8.default.createElement(
|
|
3034
|
-
|
|
1579
|
+
), /* @__PURE__ */ import_react8.default.createElement(Button_default2, { button: "star", "data-testid": testIds_default.sendBoxTelephoneKeypadButtonStar, onClick: handleButtonStarClick }), /* @__PURE__ */ import_react8.default.createElement(Button_default2, { button: "0", "data-testid": testIds_default.sendBoxTelephoneKeypadButton0, onClick: handleButton0Click, ruby: "+" }), /* @__PURE__ */ import_react8.default.createElement(
|
|
1580
|
+
Button_default2,
|
|
3035
1581
|
{
|
|
3036
1582
|
button: "pound",
|
|
3037
1583
|
"data-testid": testIds_default.sendBoxTelephoneKeypadButtonPound,
|
|
3038
1584
|
onClick: handleButtonPoundClick
|
|
3039
1585
|
}
|
|
1586
|
+
)), /* @__PURE__ */ import_react8.default.createElement("div", { className: classNames["telephone-keypad__info-message"] }, /* @__PURE__ */ import_react8.default.createElement(InfoSmallIcon_default, null), /* @__PURE__ */ import_react8.default.createElement(
|
|
1587
|
+
LocalizedString,
|
|
1588
|
+
{
|
|
1589
|
+
linkClassName: classNames["telephone-keypad__info-message-link"],
|
|
1590
|
+
stringIds: "TELEPHONE_KEYPAD_INPUT_MESSAGE"
|
|
1591
|
+
}
|
|
3040
1592
|
)));
|
|
3041
1593
|
});
|
|
3042
1594
|
TelephoneKeypad.displayName = "TelephoneKeypad";
|
|
3043
|
-
var
|
|
1595
|
+
var TelephoneKeypad_default2 = TelephoneKeypad;
|
|
3044
1596
|
|
|
3045
1597
|
// src/components/telephoneKeypad/Surrogate.tsx
|
|
3046
|
-
var TelephoneKeypadSurrogate = (0, import_react9.memo)((props) => useShown()[0] ? /* @__PURE__ */ import_react9.default.createElement(
|
|
1598
|
+
var TelephoneKeypadSurrogate = (0, import_react9.memo)((props) => useShown()[0] ? /* @__PURE__ */ import_react9.default.createElement(TelephoneKeypad_default2, { ...props }) : false);
|
|
3047
1599
|
TelephoneKeypadSurrogate.displayName = "TelephoneKeypad.Surrogate";
|
|
3048
1600
|
var Surrogate_default = TelephoneKeypadSurrogate;
|
|
3049
1601
|
|
|
3050
1602
|
// src/components/Theme.tsx
|
|
3051
1603
|
var import_react10 = __toESM(require_react());
|
|
3052
|
-
var
|
|
3053
|
-
|
|
3054
|
-
|
|
3055
|
-
|
|
3056
|
-
|
|
3057
|
-
"--webchat-colorNeutralForeground4": "var(--colorNeutralForeground4, #707070)",
|
|
3058
|
-
"--webchat-colorNeutralForegroundDisabled": "var(--colorNeutralForegroundDisabled, #bdbdbd)",
|
|
3059
|
-
"--webchat-colorNeutralBackground1": "var(--colorNeutralBackground1, #ffffff)",
|
|
3060
|
-
"--webchat-colorNeutralBackground4": "var(--colorNeutralBackground4, #f0f0f0)",
|
|
3061
|
-
"--webchat-colorNeutralBackground5": "var(--colorNeutralBackground5, #ebebeb)",
|
|
3062
|
-
"--webchat-colorSubtleBackgroundHover": "var(--colorSubtleBackgroundHover, #f5f5f5)",
|
|
3063
|
-
"--webchat-colorSubtleBackgroundPressed": "var(--colorSubtleBackgroundPressed, #e0e0e0)",
|
|
3064
|
-
"--webchat-colorNeutralStroke1": "var(--colorNeutralStroke1, #d1d1d1)",
|
|
3065
|
-
"--webchat-colorNeutralStroke2": "var(--colorNeutralStroke2, #e0e0e0)",
|
|
3066
|
-
"--webchat-colorNeutralStroke1Selected": "var(--colorNeutralStroke1Selected, #bdbdbd)",
|
|
3067
|
-
"--webchat-colorBrandStroke2": "var(--colorBrandStroke2, #9edcf7)",
|
|
3068
|
-
"--webchat-colorBrandForeground2Hover": "var(--colorBrandForeground2Hover, #015a7a)",
|
|
3069
|
-
"--webchat-colorBrandForeground2Pressed": "var(--colorBrandForeground2Pressed, #01384d)",
|
|
3070
|
-
"--webchat-colorBrandBackground2Hover": "var(--colorBrandBackground2Hover, #bee7fa)",
|
|
3071
|
-
"--webchat-colorBrandBackground2Pressed": "var(--colorBrandBackground2Pressed, #7fd2f5)",
|
|
3072
|
-
"--webchat-colorCompoundBrandForeground1": "var(--colorCompoundBrandForeground1, #077fab)",
|
|
3073
|
-
"--webchat-colorCompoundBrandForeground1Hover": "var(--colorCompoundBrandForeground1Hover, #02729c)",
|
|
3074
|
-
"--webchat-colorCompoundBrandForeground1Pressed": "var(--colorCompoundBrandForeground1Pressed, #01678c)",
|
|
3075
|
-
"--webchat-colorStatusDangerForeground1": "var(--colorStatusDangerForeground1, #b10e1c)",
|
|
3076
|
-
// https://github.com/microsoft/fluentui/blob/master/packages/theme/src/colors/FluentColors.ts
|
|
3077
|
-
"--webchat-colorGray30": "var(--colorGray30, #edebe9)",
|
|
3078
|
-
"--webchat-colorGray160": "var(--colorGray160, #323130)",
|
|
3079
|
-
"--webchat-colorGray190": "var(--colorGray190, #201f1e)",
|
|
3080
|
-
"--webchat-colorGray200": "var(--colorGray200, #1b1a19)",
|
|
3081
|
-
// https://github.com/microsoft/fluentui/blob/master/packages/tokens/src/global/borderRadius.ts
|
|
3082
|
-
"--webchat-borderRadiusSmall": "var(--borderRadiusSmall, 2px)",
|
|
3083
|
-
"--webchat-borderRadiusLarge": "var(--borderRadiusLarge, 6px)",
|
|
3084
|
-
"--webchat-borderRadiusXLarge": "var(--borderRadiusXLarge, 8px)",
|
|
3085
|
-
// https://github.com/microsoft/fluentui/blob/master/packages/tokens/src/utils/shadows.ts
|
|
3086
|
-
"--webchat-shadow16": "var(--shadow16, 0 6.4px 14.4px 0 rgba(0, 0, 0, 0.132), 0 1.2px 3.6px 0 rgba(0, 0, 0, 0.108))",
|
|
3087
|
-
// https://github.com/microsoft/fluentui/blob/master/packages/tokens/src/global/spacings.ts
|
|
3088
|
-
"--webchat-spacingHorizontalMNudge": "var(--spacingHorizontalMNudge, 10px)",
|
|
3089
|
-
// https://github.com/microsoft/fluentui/blob/master/packages/tokens/src/global/fonts.ts
|
|
3090
|
-
"--webchat-fontFamilyBase": `var(--fontFamilyBase, 'Segoe UI)', 'Segoe UI Web (West European))', -apple-system,
|
|
3091
|
-
BlinkMacSystemFont, Roboto, 'Helvetica Neue)', sans-serif)`,
|
|
3092
|
-
"--webchat-fontFamilyNumeric": `var(--fontFamilyNumeric, Bahnschrift, 'Segoe UI)', 'Segoe UI Web (West European))',
|
|
3093
|
-
-apple-system, BlinkMacSystemFont, Roboto, 'Helvetica Neue)', sans-serif)`,
|
|
3094
|
-
// https://github.com/microsoft/fluentui/blob/master/packages/tokens/src/global/fonts.ts
|
|
3095
|
-
"--webchat-fontWeightSemibold": "var(--fontWeightSemibold, 600)"
|
|
3096
|
-
}
|
|
1604
|
+
var import_classnames2 = __toESM(require_classnames());
|
|
1605
|
+
|
|
1606
|
+
// src/components/Theme.module.css
|
|
1607
|
+
var Theme_default = {
|
|
1608
|
+
theme: "Theme_theme"
|
|
3097
1609
|
};
|
|
1610
|
+
|
|
1611
|
+
// src/components/Theme.tsx
|
|
1612
|
+
var rootClassName = "webchat-fluent";
|
|
3098
1613
|
function WebchatTheme(props) {
|
|
3099
|
-
const classNames =
|
|
3100
|
-
return /* @__PURE__ */ import_react10.default.createElement("div", { className: classNames["
|
|
1614
|
+
const classNames = useStyles_default(Theme_default);
|
|
1615
|
+
return /* @__PURE__ */ import_react10.default.createElement("div", { className: (0, import_classnames2.default)(rootClassName, classNames["theme"]) }, props.children);
|
|
3101
1616
|
}
|
|
3102
1617
|
|
|
3103
1618
|
// src/components/sendbox/index.tsx
|
|
3104
|
-
var
|
|
3105
|
-
var
|
|
1619
|
+
var import_botframework_webchat_component9 = __toESM(require_botframework_webchat_component());
|
|
1620
|
+
var import_classnames9 = __toESM(require_classnames());
|
|
3106
1621
|
var import_react27 = __toESM(require_react());
|
|
3107
1622
|
|
|
3108
1623
|
// src/icons/SendIcon.tsx
|
|
@@ -3113,7 +1628,6 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3113
1628
|
{
|
|
3114
1629
|
"aria-hidden": "true",
|
|
3115
1630
|
className: props.className,
|
|
3116
|
-
fill: "currentColor",
|
|
3117
1631
|
height: "1em",
|
|
3118
1632
|
viewBox: "0 0 20 20",
|
|
3119
1633
|
width: "1em",
|
|
@@ -3130,8 +1644,8 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3130
1644
|
}
|
|
3131
1645
|
|
|
3132
1646
|
// src/components/dropZone/index.tsx
|
|
3133
|
-
var
|
|
3134
|
-
var
|
|
1647
|
+
var import_botframework_webchat_component2 = __toESM(require_botframework_webchat_component());
|
|
1648
|
+
var import_classnames3 = __toESM(require_classnames());
|
|
3135
1649
|
var import_react13 = __toESM(require_react());
|
|
3136
1650
|
|
|
3137
1651
|
// src/icons/AddDocumentIcon.tsx
|
|
@@ -3142,7 +1656,6 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3142
1656
|
{
|
|
3143
1657
|
"aria-hidden": "true",
|
|
3144
1658
|
className: props.className,
|
|
3145
|
-
fill: "currentColor",
|
|
3146
1659
|
height: "1em",
|
|
3147
1660
|
viewBox: "0 0 20 20",
|
|
3148
1661
|
width: "1em",
|
|
@@ -3158,31 +1671,15 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3158
1671
|
);
|
|
3159
1672
|
}
|
|
3160
1673
|
|
|
3161
|
-
// src/components/dropZone/index.
|
|
3162
|
-
var
|
|
3163
|
-
|
|
3164
|
-
"
|
|
3165
|
-
|
|
3166
|
-
borderRadius: "inherit",
|
|
3167
|
-
cursor: "copy",
|
|
3168
|
-
display: "grid",
|
|
3169
|
-
gap: "8px",
|
|
3170
|
-
inset: "0",
|
|
3171
|
-
placeContent: "center",
|
|
3172
|
-
placeItems: "center",
|
|
3173
|
-
position: "absolute"
|
|
3174
|
-
},
|
|
3175
|
-
"webchat-fluent__sendbox__attachment-drop-zone--droppable": {
|
|
3176
|
-
backgroundColor: "#e00",
|
|
3177
|
-
color: "White"
|
|
3178
|
-
},
|
|
3179
|
-
"webchat-fluent__sendbox__attachment-drop-zone-icon": {
|
|
3180
|
-
height: "36px",
|
|
3181
|
-
// Set "pointer-events: none" to ignore dragging over the icon. Otherwise, when dragging over the icon, it would disable the "--droppable" modifier.
|
|
3182
|
-
pointerEvents: "none",
|
|
3183
|
-
width: "36px"
|
|
3184
|
-
}
|
|
1674
|
+
// src/components/dropZone/index.module.css
|
|
1675
|
+
var dropZone_default = {
|
|
1676
|
+
"sendbox__attachment-drop-zone": "dropZone_sendbox__attachment-drop-zone",
|
|
1677
|
+
"sendbox__attachment-drop-zone--droppable": "dropZone_sendbox__attachment-drop-zone--droppable",
|
|
1678
|
+
"sendbox__attachment-drop-zone-icon": "dropZone_sendbox__attachment-drop-zone-icon"
|
|
3185
1679
|
};
|
|
1680
|
+
|
|
1681
|
+
// src/components/dropZone/index.tsx
|
|
1682
|
+
var { useLocalizer } = import_botframework_webchat_component2.hooks;
|
|
3186
1683
|
var handleDragOver = (event) => {
|
|
3187
1684
|
event.preventDefault();
|
|
3188
1685
|
};
|
|
@@ -3199,7 +1696,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3199
1696
|
}
|
|
3200
1697
|
var DropZone = (props) => {
|
|
3201
1698
|
const [dropZoneState, setDropZoneState] = (0, import_react13.useState)(false);
|
|
3202
|
-
const classNames =
|
|
1699
|
+
const classNames = useStyles_default(dropZone_default);
|
|
3203
1700
|
const dropZoneRef = (0, import_react13.useRef)(null);
|
|
3204
1701
|
const localize = useLocalizer();
|
|
3205
1702
|
const onFilesAddedRef = useRefFrom(props.onFilesAdded);
|
|
@@ -3235,34 +1732,40 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3235
1732
|
return dropZoneState ? /* @__PURE__ */ import_react13.default.createElement(
|
|
3236
1733
|
"div",
|
|
3237
1734
|
{
|
|
3238
|
-
className: (0,
|
|
3239
|
-
[classNames["
|
|
1735
|
+
className: (0, import_classnames3.default)(classNames["sendbox__attachment-drop-zone"], {
|
|
1736
|
+
[classNames["sendbox__attachment-drop-zone--droppable"]]: dropZoneState === "droppable"
|
|
3240
1737
|
}),
|
|
3241
1738
|
"data-testid": testIds_default.sendBoxDropZone,
|
|
3242
1739
|
onDragOver: handleDragOver,
|
|
3243
1740
|
onDrop: handleDrop,
|
|
3244
1741
|
ref: dropZoneRef
|
|
3245
1742
|
},
|
|
3246
|
-
/* @__PURE__ */ import_react13.default.createElement(AddDocumentIcon, { className: classNames["
|
|
1743
|
+
/* @__PURE__ */ import_react13.default.createElement(AddDocumentIcon, { className: classNames["sendbox__attachment-drop-zone-icon"] }),
|
|
3247
1744
|
localize("TEXT_INPUT_DROP_ZONE")
|
|
3248
1745
|
) : null;
|
|
3249
1746
|
};
|
|
3250
1747
|
DropZone.displayName = "DropZone";
|
|
3251
|
-
var
|
|
1748
|
+
var dropZone_default2 = (0, import_react13.memo)(DropZone);
|
|
3252
1749
|
|
|
3253
1750
|
// src/components/DropZone.tsx
|
|
3254
|
-
var DropZone_default =
|
|
1751
|
+
var DropZone_default = dropZone_default2;
|
|
3255
1752
|
|
|
3256
1753
|
// src/components/suggestedActions/index.tsx
|
|
3257
|
-
var
|
|
3258
|
-
var
|
|
1754
|
+
var import_botframework_webchat_component4 = __toESM(require_botframework_webchat_component());
|
|
1755
|
+
var import_classnames5 = __toESM(require_classnames());
|
|
3259
1756
|
var import_react16 = __toESM(require_react());
|
|
3260
1757
|
|
|
3261
1758
|
// src/components/suggestedActions/SuggestedAction.tsx
|
|
3262
|
-
var
|
|
3263
|
-
var
|
|
1759
|
+
var import_botframework_webchat_component3 = __toESM(require_botframework_webchat_component());
|
|
1760
|
+
var import_classnames4 = __toESM(require_classnames());
|
|
3264
1761
|
var import_react15 = __toESM(require_react());
|
|
3265
1762
|
|
|
1763
|
+
// src/components/suggestedActions/SuggestedAction.module.css
|
|
1764
|
+
var SuggestedAction_default = {
|
|
1765
|
+
"suggested-action": "SuggestedAction_suggested-action",
|
|
1766
|
+
"suggested-action__image": "SuggestedAction_suggested-action__image"
|
|
1767
|
+
};
|
|
1768
|
+
|
|
3266
1769
|
// src/components/suggestedActions/AccessibleButton.tsx
|
|
3267
1770
|
var import_react14 = __toESM(require_react());
|
|
3268
1771
|
var preventDefaultHandler = (event) => event.preventDefault();
|
|
@@ -3292,39 +1795,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3292
1795
|
var AccessibleButton_default = (0, import_react14.memo)(AccessibleButton);
|
|
3293
1796
|
|
|
3294
1797
|
// src/components/suggestedActions/SuggestedAction.tsx
|
|
3295
|
-
var { useDisabled, useFocus, usePerformCardAction, useScrollToEnd, useStyleSet, useSuggestedActions } =
|
|
3296
|
-
var styles5 = {
|
|
3297
|
-
"webchat-fluent__suggested-action": {
|
|
3298
|
-
alignItems: "center",
|
|
3299
|
-
background: "transparent",
|
|
3300
|
-
border: "1px solid var(--webchat-colorBrandStroke2)",
|
|
3301
|
-
borderRadius: "8px",
|
|
3302
|
-
cursor: "pointer",
|
|
3303
|
-
display: "flex",
|
|
3304
|
-
fontSize: "12px",
|
|
3305
|
-
gap: "4px",
|
|
3306
|
-
padding: "4px 8px 4px",
|
|
3307
|
-
textAlign: "start",
|
|
3308
|
-
transition: "all .15s ease-out",
|
|
3309
|
-
"@media (hover: hover)": {
|
|
3310
|
-
'&:not([aria-disabled="true"]):hover': {
|
|
3311
|
-
backgroundColor: "var(--webchat-colorBrandBackground2Hover)",
|
|
3312
|
-
color: "var(--webchat-colorBrandForeground2Hover)"
|
|
3313
|
-
}
|
|
3314
|
-
},
|
|
3315
|
-
'&:not([aria-disabled="true"]):active': {
|
|
3316
|
-
backgroundColor: "var(--webchat-colorBrandBackground2Pressed)",
|
|
3317
|
-
color: "var(--webchat-colorBrandForeground2Pressed)"
|
|
3318
|
-
},
|
|
3319
|
-
'&[aria-disabled="true"]': {
|
|
3320
|
-
color: "var(--webchat-colorNeutralForegroundDisabled)",
|
|
3321
|
-
cursor: "not-allowed"
|
|
3322
|
-
}
|
|
3323
|
-
},
|
|
3324
|
-
"webchat-fluent__suggested-action__image": {
|
|
3325
|
-
height: "12px"
|
|
3326
|
-
}
|
|
3327
|
-
};
|
|
1798
|
+
var { useDisabled, useFocus, usePerformCardAction, useScrollToEnd, useStyleSet, useSuggestedActions } = import_botframework_webchat_component3.hooks;
|
|
3328
1799
|
function SuggestedAction({
|
|
3329
1800
|
buttonText,
|
|
3330
1801
|
className,
|
|
@@ -3341,7 +1812,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3341
1812
|
const focus = useFocus();
|
|
3342
1813
|
const focusRef = (0, import_react15.useRef)(null);
|
|
3343
1814
|
const performCardAction = usePerformCardAction();
|
|
3344
|
-
const classNames =
|
|
1815
|
+
const classNames = useStyles_default(SuggestedAction_default);
|
|
3345
1816
|
const scrollToEnd = useScrollToEnd();
|
|
3346
1817
|
const handleClick = (0, import_react15.useCallback)(
|
|
3347
1818
|
({ target }) => {
|
|
@@ -3357,21 +1828,17 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3357
1828
|
return /* @__PURE__ */ import_react15.default.createElement(
|
|
3358
1829
|
AccessibleButton_default,
|
|
3359
1830
|
{
|
|
3360
|
-
className: (0,
|
|
3361
|
-
classNames["webchat-fluent__suggested-action"],
|
|
3362
|
-
suggestedActionStyleSet + "",
|
|
3363
|
-
(className || "") + ""
|
|
3364
|
-
),
|
|
1831
|
+
className: (0, import_classnames4.default)(classNames["suggested-action"], suggestedActionStyleSet + "", (className || "") + ""),
|
|
3365
1832
|
disabled,
|
|
3366
1833
|
onClick: handleClick,
|
|
3367
1834
|
ref: focusRef,
|
|
3368
1835
|
type: "button"
|
|
3369
1836
|
},
|
|
3370
|
-
image && /* @__PURE__ */ import_react15.default.createElement("img", { alt: imageAlt, className: classNames["
|
|
1837
|
+
image && /* @__PURE__ */ import_react15.default.createElement("img", { alt: imageAlt, className: classNames["suggested-action__image"], src: image }),
|
|
3371
1838
|
/* @__PURE__ */ import_react15.default.createElement("span", null, buttonText)
|
|
3372
1839
|
);
|
|
3373
1840
|
}
|
|
3374
|
-
var
|
|
1841
|
+
var SuggestedAction_default2 = (0, import_react15.memo)(SuggestedAction);
|
|
3375
1842
|
|
|
3376
1843
|
// src/components/suggestedActions/private/computeSuggestedActionText.ts
|
|
3377
1844
|
function computeSuggestedActionText(cardAction) {
|
|
@@ -3387,44 +1854,31 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3387
1854
|
return JSON.stringify(value);
|
|
3388
1855
|
}
|
|
3389
1856
|
|
|
3390
|
-
// src/components/suggestedActions/index.
|
|
3391
|
-
var
|
|
3392
|
-
|
|
3393
|
-
"
|
|
3394
|
-
|
|
3395
|
-
alignSelf: "flex-end",
|
|
3396
|
-
display: "flex",
|
|
3397
|
-
gap: "8px",
|
|
3398
|
-
"&:not(:empty)": {
|
|
3399
|
-
paddingBlockEnd: "8px",
|
|
3400
|
-
paddingInlineStart: "4px"
|
|
3401
|
-
},
|
|
3402
|
-
"&.webchat-fluent__suggested-actions--flow": {
|
|
3403
|
-
flexDirection: "row",
|
|
3404
|
-
flexWrap: "wrap",
|
|
3405
|
-
justifyContent: "flex-end"
|
|
3406
|
-
},
|
|
3407
|
-
"&.webchat-fluent__suggested-actions--stacked": {
|
|
3408
|
-
flexDirection: "column"
|
|
3409
|
-
}
|
|
3410
|
-
}
|
|
1857
|
+
// src/components/suggestedActions/index.module.css
|
|
1858
|
+
var suggestedActions_default = {
|
|
1859
|
+
"suggested-actions": "suggestedActions_suggested-actions",
|
|
1860
|
+
"suggested-actions--flow": "suggestedActions_suggested-actions--flow",
|
|
1861
|
+
"suggested-actions--stacked": "suggestedActions_suggested-actions--stacked"
|
|
3411
1862
|
};
|
|
1863
|
+
|
|
1864
|
+
// src/components/suggestedActions/index.tsx
|
|
1865
|
+
var { useLocalizer: useLocalizer2, useStyleOptions, useStyleSet: useStyleSet2, useSuggestedActions: useSuggestedActions2 } = import_botframework_webchat_component4.hooks;
|
|
3412
1866
|
function SuggestedActionStackedOrFlowContainer(props) {
|
|
3413
1867
|
const [{ suggestedActionLayout }] = useStyleOptions();
|
|
3414
1868
|
const [{ suggestedActions: suggestedActionsStyleSet }] = useStyleSet2();
|
|
3415
|
-
const classNames =
|
|
1869
|
+
const classNames = useStyles_default(suggestedActions_default);
|
|
3416
1870
|
return /* @__PURE__ */ import_react16.default.createElement(
|
|
3417
1871
|
"div",
|
|
3418
1872
|
{
|
|
3419
1873
|
"aria-label": props["aria-label"],
|
|
3420
1874
|
"aria-live": "polite",
|
|
3421
1875
|
"aria-orientation": "vertical",
|
|
3422
|
-
className: (0,
|
|
3423
|
-
classNames["
|
|
1876
|
+
className: (0, import_classnames5.default)(
|
|
1877
|
+
classNames["suggested-actions"],
|
|
3424
1878
|
suggestedActionsStyleSet + "",
|
|
3425
1879
|
{
|
|
3426
|
-
"
|
|
3427
|
-
"
|
|
1880
|
+
[classNames["suggested-actions--flow"]]: suggestedActionLayout === "flow",
|
|
1881
|
+
[classNames["suggested-actions--stacked"]]: suggestedActionLayout !== "flow"
|
|
3428
1882
|
},
|
|
3429
1883
|
props.className
|
|
3430
1884
|
),
|
|
@@ -3434,7 +1888,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3434
1888
|
);
|
|
3435
1889
|
}
|
|
3436
1890
|
function SuggestedActions() {
|
|
3437
|
-
const classNames =
|
|
1891
|
+
const classNames = useStyles_default(suggestedActions_default);
|
|
3438
1892
|
const localize = useLocalizer2();
|
|
3439
1893
|
const [suggestedActions] = useSuggestedActions2();
|
|
3440
1894
|
const children = suggestedActions.map((cardAction, index) => {
|
|
@@ -3443,7 +1897,7 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3443
1897
|
return null;
|
|
3444
1898
|
}
|
|
3445
1899
|
return /* @__PURE__ */ import_react16.default.createElement(
|
|
3446
|
-
|
|
1900
|
+
SuggestedAction_default2,
|
|
3447
1901
|
{
|
|
3448
1902
|
buttonText: computeSuggestedActionText(cardAction),
|
|
3449
1903
|
displayText,
|
|
@@ -3461,18 +1915,18 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3461
1915
|
SuggestedActionStackedOrFlowContainer,
|
|
3462
1916
|
{
|
|
3463
1917
|
"aria-label": localize("SUGGESTED_ACTIONS_LABEL_ALT"),
|
|
3464
|
-
className: classNames["
|
|
1918
|
+
className: classNames["suggested-actions"]
|
|
3465
1919
|
},
|
|
3466
1920
|
children
|
|
3467
1921
|
);
|
|
3468
1922
|
}
|
|
3469
|
-
var
|
|
1923
|
+
var suggestedActions_default2 = (0, import_react16.memo)(SuggestedActions);
|
|
3470
1924
|
|
|
3471
1925
|
// src/components/SuggestedActions.tsx
|
|
3472
|
-
var SuggestedActions_default =
|
|
1926
|
+
var SuggestedActions_default = suggestedActions_default2;
|
|
3473
1927
|
|
|
3474
1928
|
// src/components/sendbox/AddAttachmentButton.tsx
|
|
3475
|
-
var
|
|
1929
|
+
var import_botframework_webchat_component5 = __toESM(require_botframework_webchat_component());
|
|
3476
1930
|
var import_react19 = __toESM(require_react());
|
|
3477
1931
|
|
|
3478
1932
|
// src/icons/AttachmentIcon.tsx
|
|
@@ -3483,7 +1937,6 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3483
1937
|
{
|
|
3484
1938
|
"aria-hidden": "true",
|
|
3485
1939
|
className: props.className,
|
|
3486
|
-
fill: "currentColor",
|
|
3487
1940
|
height: "1em",
|
|
3488
1941
|
viewBox: "0 0 20 20",
|
|
3489
1942
|
width: "1em",
|
|
@@ -3500,63 +1953,29 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3500
1953
|
}
|
|
3501
1954
|
|
|
3502
1955
|
// src/components/sendbox/Toolbar.tsx
|
|
3503
|
-
var
|
|
1956
|
+
var import_classnames6 = __toESM(require_classnames());
|
|
3504
1957
|
var import_react18 = __toESM(require_react());
|
|
3505
|
-
|
|
3506
|
-
|
|
3507
|
-
|
|
3508
|
-
|
|
3509
|
-
|
|
3510
|
-
|
|
3511
|
-
"
|
|
3512
|
-
alignItems: "center",
|
|
3513
|
-
appearance: "none",
|
|
3514
|
-
aspectRatio: "1",
|
|
3515
|
-
background: "transparent",
|
|
3516
|
-
border: "none",
|
|
3517
|
-
borderRadius: "var(--webchat-borderRadiusSmall)",
|
|
3518
|
-
cursor: "pointer",
|
|
3519
|
-
display: "flex",
|
|
3520
|
-
justifyContent: "center",
|
|
3521
|
-
padding: "3px",
|
|
3522
|
-
width: "32px",
|
|
3523
|
-
"> svg": {
|
|
3524
|
-
fontSize: "20px",
|
|
3525
|
-
pointerEvents: "none"
|
|
3526
|
-
},
|
|
3527
|
-
"@media (hover: hover)": {
|
|
3528
|
-
'&:not([aria-disabled="true"]):hover': {
|
|
3529
|
-
backgroundColor: "var(--webchat-colorSubtleBackgroundHover)",
|
|
3530
|
-
color: "var(--webchat-colorCompoundBrandForeground1Hover)"
|
|
3531
|
-
}
|
|
3532
|
-
},
|
|
3533
|
-
'&:not([aria-disabled="true"]):active': {
|
|
3534
|
-
backgroundColor: "var(--webchat-colorSubtleBackgroundPressed)",
|
|
3535
|
-
color: "var(--webchat-colorCompoundBrandForeground1Pressed)"
|
|
3536
|
-
},
|
|
3537
|
-
'&[aria-disabled="true"]': {
|
|
3538
|
-
color: "var(--webchat-colorNeutralForegroundDisabled)",
|
|
3539
|
-
cursor: "not-allowed"
|
|
3540
|
-
}
|
|
3541
|
-
},
|
|
3542
|
-
"webchat-fluent__sendbox__toolbar-separator": {
|
|
3543
|
-
alignSelf: "center",
|
|
3544
|
-
borderInlineEnd: "1px solid var(--webchat-colorNeutralStroke2)",
|
|
3545
|
-
height: "28px",
|
|
3546
|
-
"&:first-child, &:last-child, &:only-child": {
|
|
3547
|
-
display: "none"
|
|
3548
|
-
}
|
|
3549
|
-
}
|
|
1958
|
+
|
|
1959
|
+
// src/components/sendbox/Toolbar.module.css
|
|
1960
|
+
var Toolbar_default = {
|
|
1961
|
+
sendbox__toolbar: "Toolbar_sendbox__toolbar",
|
|
1962
|
+
"sendbox__toolbar-button": "Toolbar_sendbox__toolbar-button",
|
|
1963
|
+
"sendbox__toolbar-button--selected": "Toolbar_sendbox__toolbar-button--selected",
|
|
1964
|
+
"sendbox__toolbar-separator": "Toolbar_sendbox__toolbar-separator"
|
|
3550
1965
|
};
|
|
1966
|
+
|
|
1967
|
+
// src/components/sendbox/Toolbar.tsx
|
|
3551
1968
|
var preventDefaultHandler2 = (event) => event.preventDefault();
|
|
3552
1969
|
var ToolbarButton = (0, import_react18.memo)(
|
|
3553
1970
|
(props) => {
|
|
3554
|
-
const classNames =
|
|
1971
|
+
const classNames = useStyles_default(Toolbar_default);
|
|
3555
1972
|
return /* @__PURE__ */ import_react18.default.createElement(
|
|
3556
1973
|
"button",
|
|
3557
1974
|
{
|
|
3558
1975
|
"aria-label": props["aria-label"],
|
|
3559
|
-
className: (0,
|
|
1976
|
+
className: (0, import_classnames6.default)(classNames["sendbox__toolbar-button"], props.className, {
|
|
1977
|
+
[classNames["sendbox__toolbar-button--selected"]]: props.selected
|
|
1978
|
+
}),
|
|
3560
1979
|
"data-testid": props["data-testid"],
|
|
3561
1980
|
onClick: props.disabled ? preventDefaultHandler2 : props.onClick,
|
|
3562
1981
|
type: props.type === "submit" ? "submit" : "button",
|
|
@@ -3571,18 +1990,18 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3571
1990
|
);
|
|
3572
1991
|
ToolbarButton.displayName = "ToolbarButton";
|
|
3573
1992
|
var Toolbar = (0, import_react18.memo)((props) => {
|
|
3574
|
-
const classNames =
|
|
3575
|
-
return /* @__PURE__ */ import_react18.default.createElement("div", { className: (0,
|
|
1993
|
+
const classNames = useStyles_default(Toolbar_default);
|
|
1994
|
+
return /* @__PURE__ */ import_react18.default.createElement("div", { className: (0, import_classnames6.default)(classNames["sendbox__toolbar"], props.className) }, props.children);
|
|
3576
1995
|
});
|
|
3577
1996
|
Toolbar.displayName = "Toolbar";
|
|
3578
1997
|
var ToolbarSeparator = (0, import_react18.memo)(
|
|
3579
1998
|
(props) => {
|
|
3580
|
-
const classNames =
|
|
1999
|
+
const classNames = useStyles_default(Toolbar_default);
|
|
3581
2000
|
return /* @__PURE__ */ import_react18.default.createElement(
|
|
3582
2001
|
"div",
|
|
3583
2002
|
{
|
|
3584
2003
|
"aria-orientation": "vertical",
|
|
3585
|
-
className: (0,
|
|
2004
|
+
className: (0, import_classnames6.default)(classNames["sendbox__toolbar-separator"], props.className),
|
|
3586
2005
|
role: "separator"
|
|
3587
2006
|
}
|
|
3588
2007
|
);
|
|
@@ -3590,22 +2009,17 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3590
2009
|
);
|
|
3591
2010
|
ToolbarSeparator.displayName = "ToolbarSeparator";
|
|
3592
2011
|
|
|
3593
|
-
// src/components/sendbox/AddAttachmentButton.
|
|
3594
|
-
var
|
|
3595
|
-
|
|
3596
|
-
"
|
|
3597
|
-
display: "grid"
|
|
3598
|
-
},
|
|
3599
|
-
"webchat-fluent__sendbox__add-attachment-input": {
|
|
3600
|
-
fontSize: 0,
|
|
3601
|
-
height: 0,
|
|
3602
|
-
opacity: 0,
|
|
3603
|
-
width: 0
|
|
3604
|
-
}
|
|
2012
|
+
// src/components/sendbox/AddAttachmentButton.module.css
|
|
2013
|
+
var AddAttachmentButton_default = {
|
|
2014
|
+
"sendbox__add-attachment": "AddAttachmentButton_sendbox__add-attachment",
|
|
2015
|
+
"sendbox__add-attachment-input": "AddAttachmentButton_sendbox__add-attachment-input"
|
|
3605
2016
|
};
|
|
2017
|
+
|
|
2018
|
+
// src/components/sendbox/AddAttachmentButton.tsx
|
|
2019
|
+
var { useLocalizer: useLocalizer3, useStyleOptions: useStyleOptions2 } = import_botframework_webchat_component5.hooks;
|
|
3606
2020
|
function AddAttachmentButton(props) {
|
|
3607
2021
|
const inputRef = (0, import_react19.useRef)(null);
|
|
3608
|
-
const classNames =
|
|
2022
|
+
const classNames = useStyles_default(AddAttachmentButton_default);
|
|
3609
2023
|
const localize = useLocalizer3();
|
|
3610
2024
|
const [{ uploadAccept, uploadMultiple }] = useStyleOptions2();
|
|
3611
2025
|
const onFilesAddedRef = useRefFrom(props.onFilesAdded);
|
|
@@ -3621,13 +2035,13 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3621
2035
|
},
|
|
3622
2036
|
[inputRef, onFilesAddedRef]
|
|
3623
2037
|
);
|
|
3624
|
-
return /* @__PURE__ */ import_react19.default.createElement("div", { className: classNames["
|
|
2038
|
+
return /* @__PURE__ */ import_react19.default.createElement("div", { className: classNames["sendbox__add-attachment"] }, /* @__PURE__ */ import_react19.default.createElement(
|
|
3625
2039
|
"input",
|
|
3626
2040
|
{
|
|
3627
2041
|
accept: uploadAccept,
|
|
3628
2042
|
"aria-disabled": props.disabled,
|
|
3629
2043
|
"aria-hidden": "true",
|
|
3630
|
-
className: classNames["
|
|
2044
|
+
className: classNames["sendbox__add-attachment-input"],
|
|
3631
2045
|
multiple: uploadMultiple,
|
|
3632
2046
|
onInput: props.disabled ? void 0 : handleFileChange,
|
|
3633
2047
|
readOnly: props.disabled,
|
|
@@ -3646,21 +2060,20 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3646
2060
|
/* @__PURE__ */ import_react19.default.createElement(AttachmentIcon, null)
|
|
3647
2061
|
));
|
|
3648
2062
|
}
|
|
3649
|
-
var
|
|
2063
|
+
var AddAttachmentButton_default2 = (0, import_react19.memo)(AddAttachmentButton);
|
|
3650
2064
|
|
|
3651
2065
|
// src/components/sendbox/Attachments.tsx
|
|
3652
|
-
var
|
|
2066
|
+
var import_botframework_webchat_component6 = __toESM(require_botframework_webchat_component());
|
|
3653
2067
|
var import_react20 = __toESM(require_react());
|
|
3654
|
-
var
|
|
3655
|
-
|
|
3656
|
-
|
|
3657
|
-
|
|
3658
|
-
|
|
3659
|
-
cursor: "default",
|
|
3660
|
-
padding: "6px 8px",
|
|
3661
|
-
width: "fit-content"
|
|
3662
|
-
}
|
|
2068
|
+
var import_classnames7 = __toESM(require_classnames());
|
|
2069
|
+
|
|
2070
|
+
// src/components/sendbox/Attachments.module.css
|
|
2071
|
+
var Attachments_default = {
|
|
2072
|
+
sendbox__attachment: "Attachments_sendbox__attachment"
|
|
3663
2073
|
};
|
|
2074
|
+
|
|
2075
|
+
// src/components/sendbox/Attachments.tsx
|
|
2076
|
+
var { useLocalizer: useLocalizer4 } = import_botframework_webchat_component6.hooks;
|
|
3664
2077
|
var attachmentsPluralStringIds = {
|
|
3665
2078
|
one: "TEXT_INPUT_ATTACHMENTS_ONE",
|
|
3666
2079
|
two: "TEXT_INPUT_ATTACHMENTS_TWO",
|
|
@@ -3669,39 +2082,36 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3669
2082
|
other: "TEXT_INPUT_ATTACHMENTS_OTHER"
|
|
3670
2083
|
};
|
|
3671
2084
|
function Attachments({
|
|
3672
|
-
attachments
|
|
2085
|
+
attachments,
|
|
2086
|
+
className
|
|
3673
2087
|
}) {
|
|
3674
|
-
const classNames =
|
|
2088
|
+
const classNames = useStyles_default(Attachments_default);
|
|
3675
2089
|
const localizeWithPlural = useLocalizer4({ plural: true });
|
|
3676
|
-
return attachments.length ? /* @__PURE__ */ import_react20.default.createElement("div", { className: classNames["
|
|
2090
|
+
return attachments.length ? /* @__PURE__ */ import_react20.default.createElement("div", { className: (0, import_classnames7.default)(classNames["sendbox__attachment"], className) }, localizeWithPlural(attachmentsPluralStringIds, attachments.length)) : null;
|
|
3677
2091
|
}
|
|
3678
|
-
var
|
|
2092
|
+
var Attachments_default2 = (0, import_react20.memo)(Attachments);
|
|
3679
2093
|
|
|
3680
2094
|
// src/components/sendbox/ErrorMessage.tsx
|
|
3681
2095
|
var import_react21 = __toESM(require_react());
|
|
3682
|
-
|
|
3683
|
-
|
|
3684
|
-
|
|
3685
|
-
|
|
3686
|
-
width: 0,
|
|
3687
|
-
position: "absolute",
|
|
3688
|
-
top: 0,
|
|
3689
|
-
left: 0,
|
|
3690
|
-
color: "transparent"
|
|
3691
|
-
}
|
|
2096
|
+
|
|
2097
|
+
// src/components/sendbox/ErrorMessage.module.css
|
|
2098
|
+
var ErrorMessage_default = {
|
|
2099
|
+
"sendbox__error-message": "ErrorMessage_sendbox__error-message"
|
|
3692
2100
|
};
|
|
2101
|
+
|
|
2102
|
+
// src/components/sendbox/ErrorMessage.tsx
|
|
3693
2103
|
function ErrorMessage(props) {
|
|
3694
|
-
const classNames =
|
|
2104
|
+
const classNames = useStyles_default(ErrorMessage_default);
|
|
3695
2105
|
return (
|
|
3696
2106
|
// eslint-disable-next-line react/forbid-dom-props
|
|
3697
|
-
/* @__PURE__ */ import_react21.default.createElement("span", { className: classNames["
|
|
2107
|
+
/* @__PURE__ */ import_react21.default.createElement("span", { className: classNames["sendbox__error-message"], id: props.id, role: "alert" }, props.error)
|
|
3698
2108
|
);
|
|
3699
2109
|
}
|
|
3700
|
-
var
|
|
2110
|
+
var ErrorMessage_default2 = (0, import_react21.memo)(ErrorMessage);
|
|
3701
2111
|
|
|
3702
2112
|
// src/components/sendbox/TelephoneKeypadToolbarButton.tsx
|
|
3703
2113
|
var import_react23 = __toESM(require_react());
|
|
3704
|
-
var
|
|
2114
|
+
var import_botframework_webchat_component7 = __toESM(require_botframework_webchat_component());
|
|
3705
2115
|
|
|
3706
2116
|
// src/icons/TelephoneKeypad.tsx
|
|
3707
2117
|
var import_react22 = __toESM(require_react());
|
|
@@ -3711,7 +2121,6 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3711
2121
|
{
|
|
3712
2122
|
"aria-hidden": "true",
|
|
3713
2123
|
className: props.className,
|
|
3714
|
-
fill: "currentColor",
|
|
3715
2124
|
height: "1em",
|
|
3716
2125
|
viewBox: "0 0 20 20",
|
|
3717
2126
|
width: "1em",
|
|
@@ -3728,9 +2137,9 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3728
2137
|
}
|
|
3729
2138
|
|
|
3730
2139
|
// src/components/sendbox/TelephoneKeypadToolbarButton.tsx
|
|
3731
|
-
var { useLocalizer: useLocalizer5 } =
|
|
2140
|
+
var { useLocalizer: useLocalizer5 } = import_botframework_webchat_component7.hooks;
|
|
3732
2141
|
var TelephoneKeypadToolbarButton = (0, import_react23.memo)(() => {
|
|
3733
|
-
const [, setTelephoneKeypadShown] = useShown();
|
|
2142
|
+
const [telephoneKeypadShown, setTelephoneKeypadShown] = useShown();
|
|
3734
2143
|
const localize = useLocalizer5();
|
|
3735
2144
|
const handleClick = (0, import_react23.useCallback)(() => setTelephoneKeypadShown((shown) => !shown), [setTelephoneKeypadShown]);
|
|
3736
2145
|
return /* @__PURE__ */ import_react23.default.createElement(
|
|
@@ -3738,7 +2147,8 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3738
2147
|
{
|
|
3739
2148
|
"aria-label": localize("TEXT_INPUT_TELEPHONE_KEYPAD_BUTTON_ALT"),
|
|
3740
2149
|
"data-testid": testIds_default.sendBoxTelephoneKeypadToolbarButton,
|
|
3741
|
-
onClick: handleClick
|
|
2150
|
+
onClick: handleClick,
|
|
2151
|
+
selected: telephoneKeypadShown
|
|
3742
2152
|
},
|
|
3743
2153
|
/* @__PURE__ */ import_react23.default.createElement(TelephoneKeypadIcon, null)
|
|
3744
2154
|
);
|
|
@@ -3747,61 +2157,22 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3747
2157
|
var TelephoneKeypadToolbarButton_default = TelephoneKeypadToolbarButton;
|
|
3748
2158
|
|
|
3749
2159
|
// src/components/sendbox/TextArea.tsx
|
|
3750
|
-
var
|
|
2160
|
+
var import_classnames8 = __toESM(require_classnames());
|
|
3751
2161
|
var import_react24 = __toESM(require_react());
|
|
3752
|
-
|
|
3753
|
-
|
|
3754
|
-
|
|
3755
|
-
|
|
3756
|
-
|
|
3757
|
-
|
|
3758
|
-
|
|
3759
|
-
"
|
|
3760
|
-
|
|
3761
|
-
height: 0,
|
|
3762
|
-
visibility: "collapse"
|
|
3763
|
-
},
|
|
3764
|
-
"webchat-fluent__sendbox__text-area-shared": {
|
|
3765
|
-
border: "none",
|
|
3766
|
-
font: "inherit",
|
|
3767
|
-
gridArea: "main",
|
|
3768
|
-
outline: "inherit",
|
|
3769
|
-
overflowWrap: "anywhere",
|
|
3770
|
-
resize: "inherit",
|
|
3771
|
-
scrollbarGutter: "stable"
|
|
3772
|
-
},
|
|
3773
|
-
"webchat-fluent__sendbox__text-area-doppelganger": {
|
|
3774
|
-
overflow: "hidden",
|
|
3775
|
-
visibility: "hidden",
|
|
3776
|
-
whiteSpace: "pre-wrap"
|
|
3777
|
-
},
|
|
3778
|
-
"webchat-fluent__sendbox__text-area-input": {
|
|
3779
|
-
height: "100%",
|
|
3780
|
-
padding: 0
|
|
3781
|
-
},
|
|
3782
|
-
"webchat-fluent__sendbox__text-area-input--scroll": {
|
|
3783
|
-
/* Firefox */
|
|
3784
|
-
MozScrollbarColor: "var(--webchat-colorNeutralBackground5) var(--webchat-colorNeutralForeground2)",
|
|
3785
|
-
MozScrollbarWidth: "thin",
|
|
3786
|
-
/* Chrome, Edge, and Safari */
|
|
3787
|
-
"&::-webkit-scrollbar": {
|
|
3788
|
-
width: "8px"
|
|
3789
|
-
},
|
|
3790
|
-
"&::-webkit-scrollbar-track": {
|
|
3791
|
-
backgroundColor: "var(--webchat-colorNeutralBackground5)",
|
|
3792
|
-
borderRadius: "16px"
|
|
3793
|
-
},
|
|
3794
|
-
"&::-webkit-scrollbar-thumb": {
|
|
3795
|
-
backgroundColor: "var(--webchat-colorNeutralForeground2)",
|
|
3796
|
-
borderRadius: "16px"
|
|
3797
|
-
},
|
|
3798
|
-
"&::-webkit-scrollbar-corner": {
|
|
3799
|
-
backgroundColor: "var(--webchat-colorNeutralBackground5)"
|
|
3800
|
-
}
|
|
3801
|
-
}
|
|
2162
|
+
|
|
2163
|
+
// src/components/sendbox/TextArea.module.css
|
|
2164
|
+
var TextArea_default = {
|
|
2165
|
+
"sendbox__text-area": "TextArea_sendbox__text-area",
|
|
2166
|
+
"sendbox__text-area--hidden": "TextArea_sendbox__text-area--hidden",
|
|
2167
|
+
"sendbox__text-area-shared": "TextArea_sendbox__text-area-shared",
|
|
2168
|
+
"sendbox__text-area-doppelganger": "TextArea_sendbox__text-area-doppelganger",
|
|
2169
|
+
"sendbox__text-area-input": "TextArea_sendbox__text-area-input",
|
|
2170
|
+
"sendbox__text-area-input--scroll": "TextArea_sendbox__text-area-input--scroll"
|
|
3802
2171
|
};
|
|
2172
|
+
|
|
2173
|
+
// src/components/sendbox/TextArea.tsx
|
|
3803
2174
|
var TextArea = (0, import_react24.forwardRef)((props, ref) => {
|
|
3804
|
-
const classNames =
|
|
2175
|
+
const classNames = useStyles_default(TextArea_default);
|
|
3805
2176
|
const handleKeyDown = (0, import_react24.useCallback)((event) => {
|
|
3806
2177
|
if (!event.shiftKey && event.key === "Enter") {
|
|
3807
2178
|
event.preventDefault();
|
|
@@ -3813,10 +2184,10 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3813
2184
|
return /* @__PURE__ */ import_react24.default.createElement(
|
|
3814
2185
|
"div",
|
|
3815
2186
|
{
|
|
3816
|
-
className: (0,
|
|
3817
|
-
classNames["
|
|
2187
|
+
className: (0, import_classnames8.default)(
|
|
2188
|
+
classNames["sendbox__text-area"],
|
|
3818
2189
|
{
|
|
3819
|
-
[classNames["
|
|
2190
|
+
[classNames["sendbox__text-area--hidden"]]: props.hidden
|
|
3820
2191
|
},
|
|
3821
2192
|
props.className
|
|
3822
2193
|
),
|
|
@@ -3825,10 +2196,10 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3825
2196
|
/* @__PURE__ */ import_react24.default.createElement(
|
|
3826
2197
|
"div",
|
|
3827
2198
|
{
|
|
3828
|
-
className: (0,
|
|
3829
|
-
classNames["
|
|
3830
|
-
classNames["
|
|
3831
|
-
classNames["
|
|
2199
|
+
className: (0, import_classnames8.default)(
|
|
2200
|
+
classNames["sendbox__text-area-doppelganger"],
|
|
2201
|
+
classNames["sendbox__text-area-shared"],
|
|
2202
|
+
classNames["sendbox__text-area-input--scroll"]
|
|
3832
2203
|
)
|
|
3833
2204
|
},
|
|
3834
2205
|
props.value || props.placeholder,
|
|
@@ -3838,10 +2209,10 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3838
2209
|
"textarea",
|
|
3839
2210
|
{
|
|
3840
2211
|
"aria-label": props["aria-label"],
|
|
3841
|
-
className: (0,
|
|
3842
|
-
classNames["
|
|
3843
|
-
classNames["
|
|
3844
|
-
classNames["
|
|
2212
|
+
className: (0, import_classnames8.default)(
|
|
2213
|
+
classNames["sendbox__text-area-input"],
|
|
2214
|
+
classNames["sendbox__text-area-shared"],
|
|
2215
|
+
classNames["sendbox__text-area-input--scroll"]
|
|
3845
2216
|
),
|
|
3846
2217
|
"data-testid": props["data-testid"],
|
|
3847
2218
|
onInput: props.onInput,
|
|
@@ -3856,12 +2227,12 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3856
2227
|
);
|
|
3857
2228
|
});
|
|
3858
2229
|
TextArea.displayName = "TextArea";
|
|
3859
|
-
var
|
|
2230
|
+
var TextArea_default2 = TextArea;
|
|
3860
2231
|
|
|
3861
2232
|
// src/components/sendbox/private/useSubmitError.ts
|
|
3862
|
-
var
|
|
2233
|
+
var import_botframework_webchat_component8 = __toESM(require_botframework_webchat_component());
|
|
3863
2234
|
var import_react25 = __toESM(require_react());
|
|
3864
|
-
var { useConnectivityStatus, useLocalizer: useLocalizer6 } =
|
|
2235
|
+
var { useConnectivityStatus, useLocalizer: useLocalizer6 } = import_botframework_webchat_component8.hooks;
|
|
3865
2236
|
var useSubmitError = ({
|
|
3866
2237
|
attachments,
|
|
3867
2238
|
message
|
|
@@ -3886,79 +2257,39 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
3886
2257
|
|
|
3887
2258
|
// src/components/sendbox/private/useUniqueId.ts
|
|
3888
2259
|
var import_react26 = __toESM(require_react());
|
|
3889
|
-
function useUniqueId(
|
|
2260
|
+
function useUniqueId(prefix) {
|
|
3890
2261
|
const id = (0, import_react26.useMemo)(() => Math.random().toString(36).substr(2, 5), []);
|
|
3891
|
-
|
|
3892
|
-
return `${
|
|
3893
|
-
}
|
|
2262
|
+
prefix = prefix ? `${prefix}--` : "";
|
|
2263
|
+
return `${prefix}${id}`;
|
|
2264
|
+
}
|
|
2265
|
+
|
|
2266
|
+
// src/components/sendbox/index.module.css
|
|
2267
|
+
var sendbox_default = {
|
|
2268
|
+
sendbox: "sendbox_sendbox",
|
|
2269
|
+
sendbox__sendbox: "sendbox_sendbox__sendbox",
|
|
2270
|
+
"sendbox__attachment--in-grid": "sendbox_sendbox__attachment--in-grid",
|
|
2271
|
+
"sendbox__text-area--in-grid": "sendbox_sendbox__text-area--in-grid",
|
|
2272
|
+
"sendbox__sendbox-controls--in-grid": "sendbox_sendbox__sendbox-controls--in-grid",
|
|
2273
|
+
"sendbox__telephone-keypad--in-grid": "sendbox_sendbox__telephone-keypad--in-grid",
|
|
2274
|
+
"sendbox__sendbox-text": "sendbox_sendbox__sendbox-text",
|
|
2275
|
+
"sendbox__sendbox-controls": "sendbox_sendbox__sendbox-controls",
|
|
2276
|
+
"sendbox__text-counter": "sendbox_sendbox__text-counter",
|
|
2277
|
+
"sendbox__text-counter--error": "sendbox_sendbox__text-counter--error"
|
|
2278
|
+
};
|
|
3894
2279
|
|
|
3895
2280
|
// src/components/sendbox/index.tsx
|
|
3896
|
-
var { useStyleOptions: useStyleOptions3, useMakeThumbnail, useLocalizer: useLocalizer7, useSendBoxAttachments, useSendMessage } =
|
|
3897
|
-
var styles12 = {
|
|
3898
|
-
"webchat-fluent__sendbox": {
|
|
3899
|
-
color: "var(--webchat-colorNeutralForeground1)",
|
|
3900
|
-
fontFamily: "var(--webchat-fontFamilyBase)",
|
|
3901
|
-
padding: "0 10px 10px",
|
|
3902
|
-
textRendering: "optimizeLegibility"
|
|
3903
|
-
},
|
|
3904
|
-
"webchat-fluent__sendbox__sendbox": {
|
|
3905
|
-
backgroundColor: "var(--webchat-colorNeutralBackground1)",
|
|
3906
|
-
border: "1px solid var(--webchat-colorNeutralStroke1)",
|
|
3907
|
-
borderRadius: "var(--webchat-borderRadiusLarge)",
|
|
3908
|
-
display: "grid",
|
|
3909
|
-
fontFamily: "var(--webchat-fontFamilyBase)",
|
|
3910
|
-
fontSize: "14px",
|
|
3911
|
-
gap: "6px",
|
|
3912
|
-
lineHeight: "20px",
|
|
3913
|
-
padding: "8px",
|
|
3914
|
-
position: "relative",
|
|
3915
|
-
"&:focus-within": {
|
|
3916
|
-
borderColor: "var(--webchat-colorNeutralStroke1Selected)",
|
|
3917
|
-
// TODO clarify with design the color:
|
|
3918
|
-
// - Teams is using colorCompoundBrandForeground1
|
|
3919
|
-
// - Fluent is using colorCompoundBrandStroke
|
|
3920
|
-
// - we are using colorCompoundBrandForeground1Hover
|
|
3921
|
-
boxShadow: "inset 0 -6px 0 -3px var(--webchat-colorCompoundBrandForeground1Hover)"
|
|
3922
|
-
}
|
|
3923
|
-
},
|
|
3924
|
-
"webchat-fluent__sendbox__sendbox-text": {
|
|
3925
|
-
backgroundColor: "transparent",
|
|
3926
|
-
border: "none",
|
|
3927
|
-
flex: "auto",
|
|
3928
|
-
fontFamily: "var(--webchat-fontFamilyBase)",
|
|
3929
|
-
fontSize: "14px",
|
|
3930
|
-
lineHeight: "20px",
|
|
3931
|
-
outline: "none",
|
|
3932
|
-
padding: "4px 4px 0",
|
|
3933
|
-
resize: "none"
|
|
3934
|
-
},
|
|
3935
|
-
"webchat-fluent__sendbox__sendbox-controls": {
|
|
3936
|
-
alignItems: "center",
|
|
3937
|
-
display: "flex",
|
|
3938
|
-
paddingInlineStart: "4px"
|
|
3939
|
-
},
|
|
3940
|
-
"webchat-fluent__sendbox__text-counter": {
|
|
3941
|
-
color: "var(--webchat-colorNeutralForeground4)",
|
|
3942
|
-
cursor: "default",
|
|
3943
|
-
fontFamily: "var(--webchat-fontFamilyNumeric)",
|
|
3944
|
-
fontSize: "10px",
|
|
3945
|
-
lineHeight: "14px"
|
|
3946
|
-
},
|
|
3947
|
-
"webchat-fluent__sendbox__text-counter--error": {
|
|
3948
|
-
color: "var(--webchat-colorStatusDangerForeground1)"
|
|
3949
|
-
}
|
|
3950
|
-
};
|
|
2281
|
+
var { useStyleOptions: useStyleOptions3, useMakeThumbnail, useLocalizer: useLocalizer7, useSendBoxAttachments, useSendMessage } = import_botframework_webchat_component9.hooks;
|
|
3951
2282
|
function SendBox(props) {
|
|
3952
2283
|
const inputRef = (0, import_react27.useRef)(null);
|
|
3953
2284
|
const [message, setMessage] = (0, import_react27.useState)("");
|
|
3954
2285
|
const [attachments, setAttachments] = useSendBoxAttachments();
|
|
3955
2286
|
const [{ hideTelephoneKeypadButton, hideUploadButton, maxMessageLength }] = useStyleOptions3();
|
|
3956
2287
|
const isMessageLengthExceeded = !!maxMessageLength && message.length > maxMessageLength;
|
|
3957
|
-
const classNames =
|
|
2288
|
+
const classNames = useStyles_default(sendbox_default);
|
|
3958
2289
|
const localize = useLocalizer7();
|
|
3959
2290
|
const sendMessage = useSendMessage();
|
|
3960
2291
|
const makeThumbnail = useMakeThumbnail();
|
|
3961
|
-
const errorMessageId = useUniqueId("
|
|
2292
|
+
const errorMessageId = useUniqueId("sendbox__error-message-id");
|
|
3962
2293
|
const [errorRef, errorMessage] = useSubmitError_default({ message, attachments });
|
|
3963
2294
|
const [telephoneKeypadShown] = useShown();
|
|
3964
2295
|
const attachmentsRef = useRefFrom(attachments);
|
|
@@ -4018,18 +2349,11 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
4018
2349
|
"aria-errormessage": errorMessageId
|
|
4019
2350
|
}
|
|
4020
2351
|
};
|
|
4021
|
-
return /* @__PURE__ */ import_react27.default.createElement("form", { ...aria, className: (0,
|
|
4022
|
-
|
|
4023
|
-
{
|
|
4024
|
-
autoFocus: true,
|
|
4025
|
-
isHorizontal: false,
|
|
4026
|
-
onButtonClick: handleTelephoneKeypadButtonClick
|
|
4027
|
-
}
|
|
4028
|
-
), /* @__PURE__ */ import_react27.default.createElement(
|
|
4029
|
-
TextArea_default,
|
|
2352
|
+
return /* @__PURE__ */ import_react27.default.createElement("form", { ...aria, className: (0, import_classnames9.default)(classNames["sendbox"], props.className), onSubmit: handleFormSubmit }, /* @__PURE__ */ import_react27.default.createElement(SuggestedActions_default, null), /* @__PURE__ */ import_react27.default.createElement("div", { className: (0, import_classnames9.default)(classNames["sendbox__sendbox"]), onClickCapture: handleSendBoxClick }, /* @__PURE__ */ import_react27.default.createElement(
|
|
2353
|
+
TextArea_default2,
|
|
4030
2354
|
{
|
|
4031
2355
|
"aria-label": isMessageLengthExceeded ? localize("TEXT_INPUT_LENGTH_EXCEEDED_ALT") : localize("TEXT_INPUT_ALT"),
|
|
4032
|
-
className: classNames["
|
|
2356
|
+
className: (0, import_classnames9.default)(classNames["sendbox__sendbox-text"], classNames["sendbox__text-area--in-grid"]),
|
|
4033
2357
|
"data-testid": testIds_default.sendBoxTextBox,
|
|
4034
2358
|
hidden: telephoneKeypadShown,
|
|
4035
2359
|
onInput: handleMessageChange,
|
|
@@ -4037,38 +2361,47 @@ https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Template_liter
|
|
|
4037
2361
|
ref: inputRef,
|
|
4038
2362
|
value: message
|
|
4039
2363
|
}
|
|
4040
|
-
), /* @__PURE__ */ import_react27.default.createElement(
|
|
2364
|
+
), /* @__PURE__ */ import_react27.default.createElement(
|
|
2365
|
+
Surrogate_default,
|
|
2366
|
+
{
|
|
2367
|
+
autoFocus: true,
|
|
2368
|
+
className: classNames["sendbox__telephone-keypad--in-grid"],
|
|
2369
|
+
isHorizontal: false,
|
|
2370
|
+
onButtonClick: handleTelephoneKeypadButtonClick
|
|
2371
|
+
}
|
|
2372
|
+
), /* @__PURE__ */ import_react27.default.createElement(Attachments_default2, { attachments, className: classNames["sendbox__attachment--in-grid"] }), /* @__PURE__ */ import_react27.default.createElement("div", { className: (0, import_classnames9.default)(classNames["sendbox__sendbox-controls"], classNames["sendbox__sendbox-controls--in-grid"]) }, !telephoneKeypadShown && maxMessageLength && /* @__PURE__ */ import_react27.default.createElement(
|
|
4041
2373
|
"div",
|
|
4042
2374
|
{
|
|
4043
|
-
className: (0,
|
|
4044
|
-
[classNames["
|
|
2375
|
+
className: (0, import_classnames9.default)(classNames["sendbox__text-counter"], {
|
|
2376
|
+
[classNames["sendbox__text-counter--error"]]: isMessageLengthExceeded
|
|
4045
2377
|
})
|
|
4046
2378
|
},
|
|
4047
2379
|
`${message.length}/${maxMessageLength}`
|
|
4048
|
-
), /* @__PURE__ */ import_react27.default.createElement(Toolbar, null, !hideTelephoneKeypadButton && /* @__PURE__ */ import_react27.default.createElement(TelephoneKeypadToolbarButton_default, null), !hideUploadButton && /* @__PURE__ */ import_react27.default.createElement(
|
|
2380
|
+
), /* @__PURE__ */ import_react27.default.createElement(Toolbar, null, !hideTelephoneKeypadButton && /* @__PURE__ */ import_react27.default.createElement(TelephoneKeypadToolbarButton_default, null), !hideUploadButton && /* @__PURE__ */ import_react27.default.createElement(AddAttachmentButton_default2, { onFilesAdded: handleAddFiles }), /* @__PURE__ */ import_react27.default.createElement(ToolbarSeparator, null), /* @__PURE__ */ import_react27.default.createElement(
|
|
4049
2381
|
ToolbarButton,
|
|
4050
2382
|
{
|
|
4051
2383
|
"aria-label": localize("TEXT_INPUT_SEND_BUTTON_ALT"),
|
|
4052
2384
|
"data-testid": testIds_default.sendBoxSendButton,
|
|
4053
|
-
disabled: isMessageLengthExceeded,
|
|
2385
|
+
disabled: isMessageLengthExceeded || telephoneKeypadShown,
|
|
4054
2386
|
type: "submit"
|
|
4055
2387
|
},
|
|
4056
2388
|
/* @__PURE__ */ import_react27.default.createElement(SendIcon, null)
|
|
4057
|
-
))), /* @__PURE__ */ import_react27.default.createElement(DropZone_default, { onFilesAdded: handleAddFiles }), /* @__PURE__ */ import_react27.default.createElement(
|
|
2389
|
+
))), /* @__PURE__ */ import_react27.default.createElement(DropZone_default, { onFilesAdded: handleAddFiles }), /* @__PURE__ */ import_react27.default.createElement(ErrorMessage_default2, { error: errorMessage, id: errorMessageId })));
|
|
4058
2390
|
}
|
|
4059
|
-
var
|
|
2391
|
+
var sendbox_default2 = (0, import_react27.memo)(SendBox);
|
|
4060
2392
|
|
|
4061
2393
|
// src/components/SendBox.tsx
|
|
4062
|
-
var SendBox_default =
|
|
2394
|
+
var SendBox_default = sendbox_default2;
|
|
4063
2395
|
|
|
4064
2396
|
// src/private/FluentThemeProvider.tsx
|
|
4065
|
-
var { ThemeProvider } =
|
|
2397
|
+
var { ThemeProvider } = import_botframework_webchat_component10.Components;
|
|
4066
2398
|
var sendBoxMiddleware = [() => () => () => SendBox_default];
|
|
4067
2399
|
var FluentThemeProvider = ({ children }) => /* @__PURE__ */ import_react28.default.createElement(WebchatTheme, null, /* @__PURE__ */ import_react28.default.createElement(Provider_default, null, /* @__PURE__ */ import_react28.default.createElement(ThemeProvider, { sendBoxMiddleware }, children)));
|
|
4068
2400
|
var FluentThemeProvider_default = (0, import_react28.memo)(FluentThemeProvider);
|
|
4069
2401
|
|
|
4070
2402
|
// src/index.ts
|
|
4071
|
-
injectMeta("botframework-webchat-fluent-theme:version", "4.17.0-main.
|
|
2403
|
+
injectMeta("botframework-webchat-fluent-theme:version", "4.17.0-main.20240419.2240f2a");
|
|
2404
|
+
injectStyles();
|
|
4072
2405
|
|
|
4073
2406
|
// src/bundle.ts
|
|
4074
2407
|
globalThis.WebChat = {
|