@popsure/dirty-swan 0.27.12 → 0.28.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +298 -337
- package/dist/index.js.map +1 -1
- package/dist/{mapStyle-a64f125f.js → mapStyle-1288a869.js} +2 -4
- package/dist/mapStyle-1288a869.js.map +1 -0
- package/package.json +1 -1
- package/src/lib/.DS_Store +0 -0
- package/src/lib/components/modal/.DS_Store +0 -0
- package/dist/mapStyle-a64f125f.js.map +0 -1
package/dist/index.js
CHANGED
|
@@ -1,19 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
var require$$0 = require('react');
|
|
7
|
-
var require$$1 = require('react-dom');
|
|
8
|
-
var path = require('path');
|
|
9
|
-
var require$$2 = require('querystring');
|
|
10
|
-
|
|
11
|
-
function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; }
|
|
12
|
-
|
|
13
|
-
var require$$0__default = /*#__PURE__*/_interopDefaultLegacy(require$$0);
|
|
14
|
-
var require$$1__default = /*#__PURE__*/_interopDefaultLegacy(require$$1);
|
|
15
|
-
var path__default = /*#__PURE__*/_interopDefaultLegacy(path);
|
|
16
|
-
var require$$2__default = /*#__PURE__*/_interopDefaultLegacy(require$$2);
|
|
1
|
+
import { jsxs, jsx, Fragment as Fragment$1 } from 'react/jsx-runtime';
|
|
2
|
+
import require$$0, { useState, useEffect, useMemo, useRef, useReducer, useCallback, forwardRef, useImperativeHandle, Fragment, Component, createElement } from 'react';
|
|
3
|
+
import require$$1 from 'react-dom';
|
|
4
|
+
import path from 'path';
|
|
5
|
+
import require$$2 from 'querystring';
|
|
17
6
|
|
|
18
7
|
/*! *****************************************************************************
|
|
19
8
|
Copyright (c) Microsoft Corporation.
|
|
@@ -215,7 +204,7 @@ Object.defineProperty(Caption$1, "__esModule", {
|
|
|
215
204
|
|
|
216
205
|
var _createClass$6 = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
217
206
|
|
|
218
|
-
var _react$6 = require$$
|
|
207
|
+
var _react$6 = require$$0;
|
|
219
208
|
|
|
220
209
|
var _react2$6 = _interopRequireDefault$7(_react$6);
|
|
221
210
|
|
|
@@ -333,7 +322,7 @@ Object.defineProperty(Navbar$1, "__esModule", {
|
|
|
333
322
|
|
|
334
323
|
var _createClass$5 = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
335
324
|
|
|
336
|
-
var _react$5 = require$$
|
|
325
|
+
var _react$5 = require$$0;
|
|
337
326
|
|
|
338
327
|
var _react2$5 = _interopRequireDefault$6(_react$5);
|
|
339
328
|
|
|
@@ -485,7 +474,7 @@ Object.defineProperty(Weekdays$1, "__esModule", {
|
|
|
485
474
|
|
|
486
475
|
var _createClass$4 = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
487
476
|
|
|
488
|
-
var _react$4 = require$$
|
|
477
|
+
var _react$4 = require$$0;
|
|
489
478
|
|
|
490
479
|
var _react2$4 = _interopRequireDefault$5(_react$4);
|
|
491
480
|
|
|
@@ -980,7 +969,7 @@ var _extends$1 = Object.assign || function (target) { for (var i = 1; i < argume
|
|
|
980
969
|
|
|
981
970
|
var _createClass$3 = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
982
971
|
|
|
983
|
-
var _react$3 = require$$
|
|
972
|
+
var _react$3 = require$$0;
|
|
984
973
|
|
|
985
974
|
var _react2$3 = _interopRequireDefault$3(_react$3);
|
|
986
975
|
|
|
@@ -1221,7 +1210,7 @@ Object.defineProperty(Month$1, "__esModule", {
|
|
|
1221
1210
|
|
|
1222
1211
|
var _createClass$2 = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
1223
1212
|
|
|
1224
|
-
var _react$2 = require$$
|
|
1213
|
+
var _react$2 = require$$0;
|
|
1225
1214
|
|
|
1226
1215
|
var _react2$2 = _interopRequireDefault$2(_react$2);
|
|
1227
1216
|
|
|
@@ -1423,7 +1412,7 @@ Object.defineProperty(Weekday$1, "__esModule", {
|
|
|
1423
1412
|
|
|
1424
1413
|
var _createClass$1 = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
1425
1414
|
|
|
1426
|
-
var _react$1 = require$$
|
|
1415
|
+
var _react$1 = require$$0;
|
|
1427
1416
|
|
|
1428
1417
|
var _react2$1 = _interopRequireDefault$1(_react$1);
|
|
1429
1418
|
|
|
@@ -1499,7 +1488,7 @@ var _extends = Object.assign || function (target) { for (var i = 1; i < argument
|
|
|
1499
1488
|
|
|
1500
1489
|
var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
|
|
1501
1490
|
|
|
1502
|
-
var _react = require$$
|
|
1491
|
+
var _react = require$$0;
|
|
1503
1492
|
|
|
1504
1493
|
var _react2 = _interopRequireDefault(_react);
|
|
1505
1494
|
|
|
@@ -2229,8 +2218,8 @@ var DateSelector = function (_a) {
|
|
|
2229
2218
|
var availableDays = fillArray(1, daysInSelectedDate);
|
|
2230
2219
|
var availableYears = fillArray(yearBoundaries.max, yearBoundaries.min);
|
|
2231
2220
|
var availableMonths = localizedMonthsShort;
|
|
2232
|
-
var _f =
|
|
2233
|
-
var _g =
|
|
2221
|
+
var _f = useState(calendarDateValue !== null && calendarDateValue !== void 0 ? calendarDateValue : {}), date = _f[0], setDate = _f[1];
|
|
2222
|
+
var _g = useState(false), openCalendar = _g[0], setOpenCalendar = _g[1];
|
|
2234
2223
|
var calendarDefaultDate = dayjs().year() >= yearBoundaries.min && dayjs().year() <= yearBoundaries.max
|
|
2235
2224
|
? dayjs().toDate()
|
|
2236
2225
|
: dayjs().set('year', yearBoundaries.max).toDate();
|
|
@@ -2243,12 +2232,12 @@ var DateSelector = function (_a) {
|
|
|
2243
2232
|
var dateCalendarToMonth = dayjs(String(yearBoundaries.max))
|
|
2244
2233
|
.endOf('year')
|
|
2245
2234
|
.toDate();
|
|
2246
|
-
|
|
2235
|
+
useEffect(function () {
|
|
2247
2236
|
if (calendarDateValue) {
|
|
2248
2237
|
setDate(calendarDateValue);
|
|
2249
2238
|
}
|
|
2250
2239
|
}, [value]); //eslint-disable-line react-hooks/exhaustive-deps
|
|
2251
|
-
|
|
2240
|
+
useEffect(function () {
|
|
2252
2241
|
if (date.year !== undefined &&
|
|
2253
2242
|
date.month !== undefined &&
|
|
2254
2243
|
date.day !== undefined) {
|
|
@@ -2278,20 +2267,20 @@ var DateSelector = function (_a) {
|
|
|
2278
2267
|
setDate(newValue);
|
|
2279
2268
|
}
|
|
2280
2269
|
};
|
|
2281
|
-
return (
|
|
2270
|
+
return (jsxs("div", __assign({ className: styles$t.container }, { children: [jsxs("div", __assign({ className: styles$t['date-selector-container'] }, { children: [jsxs("div", __assign({ className: styles$t['row-container'] }, { children: [jsxs("select", __assign({ "data-cy": "date-selector-day", className: "p-select " + styles$t['day-select'], id: "day", name: "day", required: true, value: (_b = date.day) !== null && _b !== void 0 ? _b : '', onChange: function (e) {
|
|
2282
2271
|
handleOnChange('day', parseInt(e.target.value, 10));
|
|
2283
|
-
} }, { children: [
|
|
2284
|
-
availableDays.map(function (day) { return (
|
|
2285
|
-
|
|
2272
|
+
} }, { children: [jsx("option", __assign({ value: "", disabled: true }, { children: (placeholders === null || placeholders === void 0 ? void 0 : placeholders.day) || 'Day' }), void 0),
|
|
2273
|
+
availableDays.map(function (day) { return (jsx("option", __assign({ value: day }, { children: day }), day)); })] }), void 0),
|
|
2274
|
+
jsxs("select", __assign({ "data-cy": "date-selector-month", className: "p-select " + styles$t['month-select'], id: "month", name: "month", required: true, value: (_c = date.month) !== null && _c !== void 0 ? _c : '', onChange: function (e) {
|
|
2286
2275
|
handleOnChange('month', parseInt(e.target.value, 10));
|
|
2287
|
-
} }, { children: [
|
|
2288
|
-
availableMonths.map(function (month, i) { return (
|
|
2289
|
-
|
|
2276
|
+
} }, { children: [jsx("option", __assign({ value: "", disabled: true }, { children: (placeholders === null || placeholders === void 0 ? void 0 : placeholders.month) || 'Month' }), void 0),
|
|
2277
|
+
availableMonths.map(function (month, i) { return (jsx("option", __assign({ value: i + 1 }, { children: month }), month)); })] }), void 0)] }), void 0),
|
|
2278
|
+
jsxs("select", __assign({ "data-cy": "date-selector-year", className: "p-select " + styles$t['year-select'], id: "year", name: "year", required: true, value: (_d = date.year) !== null && _d !== void 0 ? _d : '', onChange: function (e) {
|
|
2290
2279
|
handleOnChange('year', parseInt(e.target.value, 10));
|
|
2291
|
-
} }, { children: [
|
|
2292
|
-
availableYears.map(function (year) { return (
|
|
2293
|
-
displayCalendar && (
|
|
2294
|
-
openCalendar && (
|
|
2280
|
+
} }, { children: [jsx("option", __assign({ value: "", disabled: true }, { children: (placeholders === null || placeholders === void 0 ? void 0 : placeholders.year) || 'Year' }), void 0),
|
|
2281
|
+
availableYears.map(function (year) { return (jsx("option", __assign({ value: year }, { children: year }), year)); })] }), void 0)] }), void 0),
|
|
2282
|
+
displayCalendar && (jsxs("div", __assign({ className: styles$t['date-calendar-container'] }, { children: [jsx("img", { className: "c-pointer", src: calendarIcon, alt: "calendar", onClick: function () { return setOpenCalendar(!openCalendar); } }, void 0),
|
|
2283
|
+
openCalendar && (jsx(DayPicker, { month: selectedDateInDateType, showOutsideDays: true, fromMonth: dateCalendarFromMonth, toMonth: dateCalendarToMonth, selectedDays: selectedDateInDateType, onDayClick: function (date) {
|
|
2295
2284
|
if (dayjs(date).isAfter(dateCalendarFromMonth) ||
|
|
2296
2285
|
dayjs(date).isBefore(dateCalendarToMonth)) {
|
|
2297
2286
|
var selectedDate = dayjs(date).format(COLLECTABLE_DATE_FORMAT);
|
|
@@ -4190,7 +4179,7 @@ function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) r
|
|
|
4190
4179
|
* ```
|
|
4191
4180
|
*/
|
|
4192
4181
|
|
|
4193
|
-
var Dropzone = /*#__PURE__*/
|
|
4182
|
+
var Dropzone = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
4194
4183
|
var children = _ref.children,
|
|
4195
4184
|
params = _objectWithoutProperties(_ref, _excluded);
|
|
4196
4185
|
|
|
@@ -4198,13 +4187,13 @@ var Dropzone = /*#__PURE__*/require$$0.forwardRef(function (_ref, ref) {
|
|
|
4198
4187
|
open = _useDropzone.open,
|
|
4199
4188
|
props = _objectWithoutProperties(_useDropzone, _excluded2);
|
|
4200
4189
|
|
|
4201
|
-
|
|
4190
|
+
useImperativeHandle(ref, function () {
|
|
4202
4191
|
return {
|
|
4203
4192
|
open: open
|
|
4204
4193
|
};
|
|
4205
4194
|
}, [open]); // TODO: Figure out why react-styleguidist cannot create docs if we don't return a jsx element
|
|
4206
4195
|
|
|
4207
|
-
return /*#__PURE__*/require$$
|
|
4196
|
+
return /*#__PURE__*/require$$0.createElement(Fragment, null, children(_objectSpread(_objectSpread({}, props), {}, {
|
|
4208
4197
|
open: open
|
|
4209
4198
|
})));
|
|
4210
4199
|
});
|
|
@@ -4603,16 +4592,16 @@ function useDropzone() {
|
|
|
4603
4592
|
onError = _defaultProps$props.onError,
|
|
4604
4593
|
validator = _defaultProps$props.validator;
|
|
4605
4594
|
|
|
4606
|
-
var acceptAttr =
|
|
4595
|
+
var acceptAttr = useMemo(function () {
|
|
4607
4596
|
return acceptPropAsAcceptAttr(accept);
|
|
4608
4597
|
}, [accept]);
|
|
4609
|
-
var pickerTypes =
|
|
4598
|
+
var pickerTypes = useMemo(function () {
|
|
4610
4599
|
return pickerOptionsFromAccept(accept);
|
|
4611
4600
|
}, [accept]);
|
|
4612
|
-
var onFileDialogOpenCb =
|
|
4601
|
+
var onFileDialogOpenCb = useMemo(function () {
|
|
4613
4602
|
return typeof onFileDialogOpen === "function" ? onFileDialogOpen : noop;
|
|
4614
4603
|
}, [onFileDialogOpen]);
|
|
4615
|
-
var onFileDialogCancelCb =
|
|
4604
|
+
var onFileDialogCancelCb = useMemo(function () {
|
|
4616
4605
|
return typeof onFileDialogCancel === "function" ? onFileDialogCancel : noop;
|
|
4617
4606
|
}, [onFileDialogCancel]);
|
|
4618
4607
|
/**
|
|
@@ -4620,17 +4609,17 @@ function useDropzone() {
|
|
|
4620
4609
|
* @type {React.MutableRefObject<HTMLElement>}
|
|
4621
4610
|
*/
|
|
4622
4611
|
|
|
4623
|
-
var rootRef =
|
|
4624
|
-
var inputRef =
|
|
4612
|
+
var rootRef = useRef(null);
|
|
4613
|
+
var inputRef = useRef(null);
|
|
4625
4614
|
|
|
4626
|
-
var _useReducer =
|
|
4615
|
+
var _useReducer = useReducer(reducer, initialState),
|
|
4627
4616
|
_useReducer2 = _slicedToArray$1(_useReducer, 2),
|
|
4628
4617
|
state = _useReducer2[0],
|
|
4629
4618
|
dispatch = _useReducer2[1];
|
|
4630
4619
|
|
|
4631
4620
|
var isFocused = state.isFocused,
|
|
4632
4621
|
isFileDialogActive = state.isFileDialogActive;
|
|
4633
|
-
var fsAccessApiWorksRef =
|
|
4622
|
+
var fsAccessApiWorksRef = useRef(typeof window !== "undefined" && window.isSecureContext && useFsAccessApi && canUseFileSystemAccessAPI()); // Update file dialog active state when the window is focused on
|
|
4634
4623
|
|
|
4635
4624
|
var onWindowFocus = function onWindowFocus() {
|
|
4636
4625
|
// Execute the timeout only if the file dialog is opened in the browser
|
|
@@ -4650,13 +4639,13 @@ function useDropzone() {
|
|
|
4650
4639
|
}
|
|
4651
4640
|
};
|
|
4652
4641
|
|
|
4653
|
-
|
|
4642
|
+
useEffect(function () {
|
|
4654
4643
|
window.addEventListener("focus", onWindowFocus, false);
|
|
4655
4644
|
return function () {
|
|
4656
4645
|
window.removeEventListener("focus", onWindowFocus, false);
|
|
4657
4646
|
};
|
|
4658
4647
|
}, [inputRef, isFileDialogActive, onFileDialogCancelCb, fsAccessApiWorksRef]);
|
|
4659
|
-
var dragTargetsRef =
|
|
4648
|
+
var dragTargetsRef = useRef([]);
|
|
4660
4649
|
|
|
4661
4650
|
var onDocumentDrop = function onDocumentDrop(event) {
|
|
4662
4651
|
if (rootRef.current && rootRef.current.contains(event.target)) {
|
|
@@ -4668,7 +4657,7 @@ function useDropzone() {
|
|
|
4668
4657
|
dragTargetsRef.current = [];
|
|
4669
4658
|
};
|
|
4670
4659
|
|
|
4671
|
-
|
|
4660
|
+
useEffect(function () {
|
|
4672
4661
|
if (preventDropOnDocument) {
|
|
4673
4662
|
document.addEventListener("dragover", onDocumentDragOver, false);
|
|
4674
4663
|
document.addEventListener("drop", onDocumentDrop, false);
|
|
@@ -4682,14 +4671,14 @@ function useDropzone() {
|
|
|
4682
4671
|
};
|
|
4683
4672
|
}, [rootRef, preventDropOnDocument]); // Auto focus the root when autoFocus is true
|
|
4684
4673
|
|
|
4685
|
-
|
|
4674
|
+
useEffect(function () {
|
|
4686
4675
|
if (!disabled && autoFocus && rootRef.current) {
|
|
4687
4676
|
rootRef.current.focus();
|
|
4688
4677
|
}
|
|
4689
4678
|
|
|
4690
4679
|
return function () {};
|
|
4691
4680
|
}, [rootRef, autoFocus, disabled]);
|
|
4692
|
-
var onErrCb =
|
|
4681
|
+
var onErrCb = useCallback(function (e) {
|
|
4693
4682
|
if (onError) {
|
|
4694
4683
|
onError(e);
|
|
4695
4684
|
} else {
|
|
@@ -4697,7 +4686,7 @@ function useDropzone() {
|
|
|
4697
4686
|
console.error(e);
|
|
4698
4687
|
}
|
|
4699
4688
|
}, [onError]);
|
|
4700
|
-
var onDragEnterCb =
|
|
4689
|
+
var onDragEnterCb = useCallback(function (event) {
|
|
4701
4690
|
event.preventDefault(); // Persist here because we need the event later after getFilesFromEvent() is done
|
|
4702
4691
|
|
|
4703
4692
|
event.persist();
|
|
@@ -4736,7 +4725,7 @@ function useDropzone() {
|
|
|
4736
4725
|
});
|
|
4737
4726
|
}
|
|
4738
4727
|
}, [getFilesFromEvent, onDragEnter, onErrCb, noDragEventsBubbling, acceptAttr, minSize, maxSize, multiple, maxFiles, validator]);
|
|
4739
|
-
var onDragOverCb =
|
|
4728
|
+
var onDragOverCb = useCallback(function (event) {
|
|
4740
4729
|
event.preventDefault();
|
|
4741
4730
|
event.persist();
|
|
4742
4731
|
stopPropagation(event);
|
|
@@ -4756,7 +4745,7 @@ function useDropzone() {
|
|
|
4756
4745
|
|
|
4757
4746
|
return false;
|
|
4758
4747
|
}, [onDragOver, noDragEventsBubbling]);
|
|
4759
|
-
var onDragLeaveCb =
|
|
4748
|
+
var onDragLeaveCb = useCallback(function (event) {
|
|
4760
4749
|
event.preventDefault();
|
|
4761
4750
|
event.persist();
|
|
4762
4751
|
stopPropagation(event); // Only deactivate once the dropzone and all children have been left
|
|
@@ -4789,7 +4778,7 @@ function useDropzone() {
|
|
|
4789
4778
|
onDragLeave(event);
|
|
4790
4779
|
}
|
|
4791
4780
|
}, [rootRef, onDragLeave, noDragEventsBubbling]);
|
|
4792
|
-
var setFiles =
|
|
4781
|
+
var setFiles = useCallback(function (files, event) {
|
|
4793
4782
|
var acceptedFiles = [];
|
|
4794
4783
|
var fileRejections = [];
|
|
4795
4784
|
files.forEach(function (file) {
|
|
@@ -4852,7 +4841,7 @@ function useDropzone() {
|
|
|
4852
4841
|
onDropAccepted(acceptedFiles, event);
|
|
4853
4842
|
}
|
|
4854
4843
|
}, [dispatch, multiple, acceptAttr, minSize, maxSize, maxFiles, onDrop, onDropAccepted, onDropRejected, validator]);
|
|
4855
|
-
var onDropCb =
|
|
4844
|
+
var onDropCb = useCallback(function (event) {
|
|
4856
4845
|
event.preventDefault(); // Persist here because we need the event later after getFilesFromEvent() is done
|
|
4857
4846
|
|
|
4858
4847
|
event.persist();
|
|
@@ -4876,7 +4865,7 @@ function useDropzone() {
|
|
|
4876
4865
|
});
|
|
4877
4866
|
}, [getFilesFromEvent, setFiles, onErrCb, noDragEventsBubbling]); // Fn for opening the file dialog programmatically
|
|
4878
4867
|
|
|
4879
|
-
var openFileDialog =
|
|
4868
|
+
var openFileDialog = useCallback(function () {
|
|
4880
4869
|
// No point to use FS access APIs if context is not secure
|
|
4881
4870
|
// https://developer.mozilla.org/en-US/docs/Web/Security/Secure_Contexts#feature_detection
|
|
4882
4871
|
if (fsAccessApiWorksRef.current) {
|
|
@@ -4930,7 +4919,7 @@ function useDropzone() {
|
|
|
4930
4919
|
}
|
|
4931
4920
|
}, [dispatch, onFileDialogOpenCb, onFileDialogCancelCb, useFsAccessApi, setFiles, onErrCb, pickerTypes, multiple]); // Cb to open the file dialog when SPACE/ENTER occurs on the dropzone
|
|
4932
4921
|
|
|
4933
|
-
var onKeyDownCb =
|
|
4922
|
+
var onKeyDownCb = useCallback(function (event) {
|
|
4934
4923
|
// Ignore keyboard events bubbling up the DOM tree
|
|
4935
4924
|
if (!rootRef.current || !rootRef.current.isEqualNode(event.target)) {
|
|
4936
4925
|
return;
|
|
@@ -4942,18 +4931,18 @@ function useDropzone() {
|
|
|
4942
4931
|
}
|
|
4943
4932
|
}, [rootRef, openFileDialog]); // Update focus state for the dropzone
|
|
4944
4933
|
|
|
4945
|
-
var onFocusCb =
|
|
4934
|
+
var onFocusCb = useCallback(function () {
|
|
4946
4935
|
dispatch({
|
|
4947
4936
|
type: "focus"
|
|
4948
4937
|
});
|
|
4949
4938
|
}, []);
|
|
4950
|
-
var onBlurCb =
|
|
4939
|
+
var onBlurCb = useCallback(function () {
|
|
4951
4940
|
dispatch({
|
|
4952
4941
|
type: "blur"
|
|
4953
4942
|
});
|
|
4954
4943
|
}, []); // Cb to open the file dialog when click occurs on the dropzone
|
|
4955
4944
|
|
|
4956
|
-
var onClickCb =
|
|
4945
|
+
var onClickCb = useCallback(function () {
|
|
4957
4946
|
if (noClick) {
|
|
4958
4947
|
return;
|
|
4959
4948
|
} // In IE11/Edge the file-browser dialog is blocking, therefore, use setTimeout()
|
|
@@ -4986,7 +4975,7 @@ function useDropzone() {
|
|
|
4986
4975
|
}
|
|
4987
4976
|
};
|
|
4988
4977
|
|
|
4989
|
-
var getRootProps =
|
|
4978
|
+
var getRootProps = useMemo(function () {
|
|
4990
4979
|
return function () {
|
|
4991
4980
|
var _ref2 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
4992
4981
|
_ref2$refKey = _ref2.refKey,
|
|
@@ -5017,10 +5006,10 @@ function useDropzone() {
|
|
|
5017
5006
|
} : {}), rest);
|
|
5018
5007
|
};
|
|
5019
5008
|
}, [rootRef, onKeyDownCb, onFocusCb, onBlurCb, onClickCb, onDragEnterCb, onDragOverCb, onDragLeaveCb, onDropCb, noKeyboard, noDrag, disabled]);
|
|
5020
|
-
var onInputElementClick =
|
|
5009
|
+
var onInputElementClick = useCallback(function (event) {
|
|
5021
5010
|
event.stopPropagation();
|
|
5022
5011
|
}, []);
|
|
5023
|
-
var getInputProps =
|
|
5012
|
+
var getInputProps = useMemo(function () {
|
|
5024
5013
|
return function () {
|
|
5025
5014
|
var _ref3 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {},
|
|
5026
5015
|
_ref3$refKey = _ref3.refKey,
|
|
@@ -5109,16 +5098,16 @@ var css_248z$t = ".style-module_container__BL4SV {\n cursor: pointer;\n backgr
|
|
|
5109
5098
|
var styles$s = {"container":"style-module_container__BL4SV","container--error":"style-module_container--error__1A9v5","container--uploading":"style-module_container--uploading__R11Jd","container--uploaded":"style-module_container--uploaded__1QbKe","image":"style-module_image__2qnlY","progress-container":"style-module_progress-container__ZQ0Qa","progress-bar":"style-module_progress-bar__1_SWA","action":"style-module_action__3_5C4","action--error":"style-module_action--error__VrIT9","action--uploaded":"style-module_action--uploaded__320Sq"};
|
|
5110
5099
|
styleInject(css_248z$t);
|
|
5111
5100
|
|
|
5112
|
-
var ErrorImage = (function () { return (
|
|
5101
|
+
var ErrorImage = (function () { return (jsx("svg", __assign({ width: "90", height: "66", viewBox: "0 0 90 66", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: jsx("path", { "fill-rule": "evenodd", "clip-rule": "evenodd", d: "M45 0C37.9976 0 30.9572 2.64966 25.6182 7.94665C21.6477 11.8859 19.2407 16.7726 18.2201 21.8685C7.85944 23.8626 0 32.8399 0 43.6762C0 55.9706 10.1084 65.9997 22.5 65.9997H56.656C56.6837 66.0001 56.7114 66.0001 56.7391 65.9997H57.2609C57.2886 66.0001 57.3163 66.0001 57.344 65.9997H70.4348C81.2231 65.9997 90 57.2917 90 46.5881C90 36.486 82.1561 28.2623 72.2079 27.3583C72.2539 20.3322 69.7386 13.2916 64.3512 7.94665C59.0169 2.65398 52.0024 0 45 0ZM57.2609 60.1762H56.7391C56.7114 60.1758 56.6838 60.1758 56.6561 60.1762H22.5C13.2807 60.1762 5.86957 52.8233 5.86957 43.6762C5.86957 35.0382 12.4909 28.0009 20.9715 27.237C21.6366 27.1727 22.2596 26.8852 22.7377 26.4219C23.2157 25.9587 23.5201 25.3474 23.6005 24.6892C24.1405 20.074 26.1989 15.5901 29.7758 12.0413C33.9878 7.86248 39.4844 5.8235 45 5.8235C50.5156 5.8235 55.9776 7.85816 60.1936 12.0413C65.0657 16.8751 67.1274 23.4426 66.3689 29.7241C66.317 30.1333 66.3533 30.5488 66.4754 30.9431C66.5975 31.3373 66.8026 31.7014 67.0772 32.0111C67.3518 32.3208 67.6895 32.5691 68.0681 32.7395C68.4466 32.91 68.8574 32.9987 69.2731 32.9998H70.4348C78.0729 32.9998 84.1304 39.0097 84.1304 46.5881C84.1304 54.1663 78.0729 60.1762 70.4348 60.1762H57.3439C57.3162 60.1758 57.2886 60.1758 57.2609 60.1762ZM32.7678 30.7678C31.7915 29.7915 31.7915 28.2085 32.7678 27.2322C33.7441 26.2559 35.327 26.2559 36.3033 27.2322L44.0355 34.9645L52.2322 26.7678C53.2085 25.7915 54.7915 25.7915 55.7678 26.7678C56.7441 27.7441 56.7441 29.327 55.7678 30.3033L47.5711 38.5L55.3952 46.3241C56.3715 47.3004 56.3715 48.8833 55.3952 49.8596C54.4189 50.836 52.836 50.836 51.8596 49.8596L44.0355 42.0355L36.6759 49.3952C35.6996 50.3715 34.1167 50.3715 33.1404 49.3952C32.164 48.4189 32.164 46.836 33.1404 45.8596L40.5 38.5L32.7678 30.7678Z", fill: "#E55566" }, void 0) }), void 0)); });
|
|
5113
5102
|
|
|
5114
5103
|
var css_248z$s = ".style-module_stroke-primary-500__pRJ6W {\n stroke: var(--ds-primary-500);\n}\n\n.style-module_fill-primary-500__5NoPh {\n fill: var(--ds-primary-500);\n}";
|
|
5115
5104
|
var styles$r = {"stroke-primary-500":"style-module_stroke-primary-500__pRJ6W","fill-primary-500":"style-module_fill-primary-500__5NoPh"};
|
|
5116
5105
|
styleInject(css_248z$s);
|
|
5117
5106
|
|
|
5118
|
-
var UploadImage = (function () { return (
|
|
5107
|
+
var UploadImage = (function () { return (jsx("svg", __assign({ width: "90", height: "73", viewBox: "0 0 90 73", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: jsx("path", { className: styles$r['fill-primary-500'], d: "M45 0C37.9976 0 30.9572 2.67062 25.6182 8.00951C21.6477 11.9799 19.2407 16.9053 18.2201 22.0414C7.85945 24.0513 0 33.0997 0 44.0217C0 56.4134 10.1084 66.5218 22.5 66.5218H33.2609C33.6498 66.5273 34.0359 66.4555 34.3968 66.3104C34.7576 66.1654 35.0861 65.9501 35.3631 65.677C35.64 65.404 35.8599 65.0786 36.01 64.7198C36.1602 64.361 36.2375 63.9759 36.2375 63.587C36.2375 63.1981 36.1602 62.813 36.01 62.4542C35.8599 62.0954 35.64 61.7701 35.3631 61.497C35.0861 61.2239 34.7576 61.0086 34.3968 60.8636C34.0359 60.7186 33.6498 60.6467 33.2609 60.6522H22.5C13.2807 60.6522 5.86957 53.2412 5.86957 44.0217C5.86957 35.3154 12.4909 28.2224 20.9715 27.4524C21.6366 27.3876 22.2596 27.0978 22.7377 26.6309C23.2157 26.164 23.5201 25.5479 23.6005 24.8845C24.1405 20.2328 26.1989 15.7134 29.7758 12.1365C33.9878 7.92468 39.4844 5.86957 45 5.86957C50.5156 5.86957 55.9776 7.92032 60.1936 12.1365C65.0657 17.0086 67.1274 23.628 66.3689 29.9592C66.317 30.3717 66.3533 30.7905 66.4754 31.1879C66.5975 31.5852 66.8026 31.9522 67.0772 32.2643C67.3518 32.5765 67.6895 32.8267 68.0681 32.9985C68.4466 33.1703 68.8574 33.2597 69.2731 33.2609H70.4348C78.0729 33.2609 84.1304 39.3183 84.1304 46.9566C84.1304 54.5947 78.0729 60.6522 70.4348 60.6522H56.7391C56.3502 60.6467 55.9641 60.7186 55.6032 60.8636C55.2424 61.0086 54.9139 61.2239 54.6369 61.497C54.36 61.7701 54.1401 62.0954 53.99 62.4542C53.8398 62.813 53.7626 63.1981 53.7626 63.587C53.7626 63.9759 53.8398 64.361 53.99 64.7198C54.1401 65.0786 54.36 65.404 54.6369 65.677C54.9139 65.9501 55.2424 66.1654 55.6032 66.3104C55.9641 66.4555 56.3502 66.5273 56.7391 66.5218H70.4348C81.2231 66.5218 90 57.7449 90 46.9566C90 36.7746 82.1561 28.4859 72.2079 27.5747C72.2539 20.4931 69.7385 13.3968 64.3512 8.00951C59.0169 2.67498 52.0024 0 45 0ZM45 33.2609C44.0215 33.2609 43.5041 33.5757 43.013 34.0251L32.2521 43.8077C31.0095 44.9609 31.0313 46.8324 32.0686 47.9654C33.1059 49.0983 35.0881 49.1803 36.2262 48.1488L42.0652 42.8295V69.4566C42.0652 71.0774 43.3789 72.3914 45 72.3914C46.6212 72.3914 47.9348 71.0774 47.9348 69.4566V42.8295L53.7738 48.1488C54.912 49.1803 56.8342 49.0405 57.9314 47.9654C59.0876 46.8324 58.8758 44.8505 57.7479 43.8077L46.987 34.0251C46.4057 33.4929 45.9785 33.2609 45 33.2609Z" }, void 0) }), void 0)); });
|
|
5119
5108
|
|
|
5120
|
-
var FileImage = (function () { return (
|
|
5121
|
-
|
|
5109
|
+
var FileImage = (function () { return (jsxs("svg", __assign({ width: "60", height: "72", viewBox: "0 0 60 72", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: [jsx("path", { className: styles$r['stroke-primary-500'], d: "M50.5975 69H8.94969C7.37173 69 5.8584 68.3679 4.74262 67.2426C3.62684 66.1174 3 64.5913 3 63V21L20.8491 3H50.5975C52.1754 3 53.6888 3.63214 54.8045 4.75736C55.9203 5.88258 56.5472 7.4087 56.5472 9V63C56.5472 64.5913 55.9203 66.1174 54.8045 67.2426C53.6888 68.3679 52.1754 69 50.5975 69Z", strokeWidth: "5", strokeLinejoin: "round" }, void 0),
|
|
5110
|
+
jsx("path", { className: styles$r['stroke-primary-500'], d: "M20.434 3V15.4528C20.434 17.1042 19.8217 18.6879 18.7319 19.8556C17.642 21.0233 16.1639 21.6792 14.6226 21.6792H3", strokeWidth: "5", strokeLinejoin: "round" }, void 0)] }), void 0)); });
|
|
5122
5111
|
|
|
5123
5112
|
function truncateStringTail(aString, length) {
|
|
5124
5113
|
if (aString.length > length) {
|
|
@@ -5130,7 +5119,7 @@ function truncateStringTail(aString, length) {
|
|
|
5130
5119
|
}
|
|
5131
5120
|
var index$9 = (function (_a) {
|
|
5132
5121
|
var className = _a.className, uploading = _a.uploading, progress = _a.progress, error = _a.error, uploadedFileUrl = _a.uploadedFileUrl, onSelectedFile = _a.onSelectedFile;
|
|
5133
|
-
var onDrop =
|
|
5122
|
+
var onDrop = useCallback(function (acceptedFiles) {
|
|
5134
5123
|
onSelectedFile(acceptedFiles[0]);
|
|
5135
5124
|
}, [onSelectedFile]);
|
|
5136
5125
|
var uploadedFileName = (uploadedFileUrl &&
|
|
@@ -5186,11 +5175,11 @@ var index$9 = (function (_a) {
|
|
|
5186
5175
|
},
|
|
5187
5176
|
}[state], action = _b.action, Image = _b.Image, text = _b.text, containerStyle = _b.containerStyle, textColor = _b.textColor;
|
|
5188
5177
|
var _c = useDropzone({ onDrop: onDrop }), getRootProps = _c.getRootProps, getInputProps = _c.getInputProps;
|
|
5189
|
-
return (
|
|
5190
|
-
|
|
5191
|
-
|
|
5192
|
-
action &&
|
|
5193
|
-
state === 'uploading' && (
|
|
5178
|
+
return (jsxs("div", __assign({ className: styles$s.container + " " + containerStyle + " " + className }, getRootProps(), { children: [jsx("input", __assign({}, getInputProps()), void 0),
|
|
5179
|
+
jsx(Image, {}, void 0),
|
|
5180
|
+
jsx("div", __assign({ className: "p-p mt16" }, { children: text }), void 0),
|
|
5181
|
+
action && jsx("div", __assign({ className: "p-p " + textColor }, { children: action }), void 0),
|
|
5182
|
+
state === 'uploading' && (jsx("div", __assign({ className: styles$s['progress-container'] }, { children: jsx("div", { className: styles$s['progress-bar'], style: { width: progress + "%" } }, void 0) }), void 0))] }), void 0));
|
|
5194
5183
|
});
|
|
5195
5184
|
|
|
5196
5185
|
/*!
|
|
@@ -5702,7 +5691,7 @@ var Signature = /** @class */ (function (_super) {
|
|
|
5702
5691
|
_this.state = {
|
|
5703
5692
|
hasContent: false,
|
|
5704
5693
|
};
|
|
5705
|
-
_this.canvasRef = require$$
|
|
5694
|
+
_this.canvasRef = require$$0.createRef();
|
|
5706
5695
|
_this.notifyOnChange = _this.notifyOnChange.bind(_this);
|
|
5707
5696
|
_this.resizeCanvas = _this.resizeCanvas.bind(_this);
|
|
5708
5697
|
_this.clear = _this.clear.bind(_this);
|
|
@@ -5717,16 +5706,16 @@ var Signature = /** @class */ (function (_super) {
|
|
|
5717
5706
|
};
|
|
5718
5707
|
Signature.prototype.render = function () {
|
|
5719
5708
|
var hasContent = this.state.hasContent;
|
|
5720
|
-
return (
|
|
5709
|
+
return (jsxs(Fragment$1, { children: [jsx("style", { dangerouslySetInnerHTML: {
|
|
5721
5710
|
__html: "." + styles$q.reset + "::before { \n -webkit-mask-image: url(\"" + reset + "\");\n mask-image: url(\"" + reset + "\");\n }",
|
|
5722
5711
|
} }, void 0),
|
|
5723
|
-
|
|
5724
|
-
|
|
5725
|
-
|
|
5712
|
+
jsxs("div", __assign({ className: styles$q.container }, { children: [jsx("canvas", { className: styles$q.canvas, ref: this.canvasRef }, void 0),
|
|
5713
|
+
jsx("div", { className: styles$q.separator }, void 0),
|
|
5714
|
+
jsx("div", { className: styles$q.sign, style: {
|
|
5726
5715
|
WebkitMaskImage: "url(\"" + sign + "\")",
|
|
5727
5716
|
maskImage: "url(\"" + sign + "\")",
|
|
5728
5717
|
} }, void 0),
|
|
5729
|
-
|
|
5718
|
+
jsx("button", __assign({ className: styles$q.reset, onClick: this.clear, disabled: !hasContent }, { children: "Reset" }), void 0)] }), void 0)] }, void 0));
|
|
5730
5719
|
};
|
|
5731
5720
|
Signature.prototype.notifyOnChange = function () {
|
|
5732
5721
|
var onChange = this.props.onChange;
|
|
@@ -5744,7 +5733,7 @@ var Signature = /** @class */ (function (_super) {
|
|
|
5744
5733
|
this.notifyOnChange();
|
|
5745
5734
|
};
|
|
5746
5735
|
return Signature;
|
|
5747
|
-
}(
|
|
5736
|
+
}(Component));
|
|
5748
5737
|
|
|
5749
5738
|
var classnames = {exports: {}};
|
|
5750
5739
|
|
|
@@ -8043,15 +8032,15 @@ var css_248z$q = ".style-module_container__2L4SP {\n position: relative;\n}\n\n
|
|
|
8043
8032
|
var styles$p = {"container":"style-module_container__2L4SP","prefix":"style-module_prefix__3jAFZ","prefix--with-error":"style-module_prefix--with-error__1yTTM","prefix--disabled":"style-module_prefix--disabled__2-gcw","input":"style-module_input__1eJO5","placeholder":"style-module_placeholder__1U2z0","placeholder--with-error":"style-module_placeholder--with-error__2ieRU","input--no-placeholder":"style-module_input--no-placeholder__3EGwh","input--with-prefix":"style-module_input--with-prefix__38e0j","placeholder--with-prefix":"style-module_placeholder--with-prefix__2PquQ","error":"style-module_error__167Zc"};
|
|
8044
8033
|
styleInject(css_248z$q);
|
|
8045
8034
|
|
|
8046
|
-
var Input = require$$
|
|
8035
|
+
var Input = require$$0.forwardRef(function (_a, ref) {
|
|
8047
8036
|
var _b, _c, _d, _e, _f;
|
|
8048
8037
|
var className = _a.className, placeholder = _a.placeholder, prefix = _a.prefix, error = _a.error, disabled = _a.disabled, props = __rest$1(_a, ["className", "placeholder", "prefix", "error", "disabled"]);
|
|
8049
|
-
return (
|
|
8038
|
+
return (jsxs("div", __assign({ className: styles$p.container + " " + (className !== null && className !== void 0 ? className : '') }, { children: [jsx("input", __assign({ "data-testid": "ds-input-input", type: "text", ref: ref, className: classNames(error ? 'p-input--error' : 'p-input', placeholder && placeholder.length > 0
|
|
8050
8039
|
? styles$p.input
|
|
8051
8040
|
: styles$p['input--no-placeholder'], (_b = {}, _b[styles$p['input--with-prefix']] = prefix, _b)), placeholder: " ", disabled: disabled }, props), void 0),
|
|
8052
|
-
prefix && (
|
|
8053
|
-
|
|
8054
|
-
error && (
|
|
8041
|
+
prefix && (jsx("span", __assign({ className: classNames(styles$p.prefix, (_c = {}, _c[styles$p['prefix--with-error']] = error, _c), (_d = {}, _d[styles$p['prefix--disabled']] = disabled, _d)) }, { children: prefix }), void 0)),
|
|
8042
|
+
jsx("span", __assign({ className: classNames(styles$p.placeholder, (_e = {}, _e[styles$p['placeholder--with-prefix']] = prefix, _e), (_f = {}, _f[styles$p['placeholder--with-error']] = error, _f)) }, { children: placeholder }), void 0),
|
|
8043
|
+
error && (jsx("p", __assign({ className: "p-p--small tc-red-500 w100 " + styles$p.error }, { children: error }), void 0))] }), void 0));
|
|
8055
8044
|
});
|
|
8056
8045
|
|
|
8057
8046
|
var z7=Object.defineProperty;var V=(t,a)=>{for(var z in a)z7(t,z,{get:a[z],enumerable:!0});};var s=["AF","AL","DZ","AD","AS","AO","AI","AQ","AG","AR","AM","AW","AU","AT","AZ","BS","BH","BD","BB","BY","BE","BZ","BJ","BM","BT","BO","BA","BW","BV","BR","IO","BN","BG","BF","BI","KH","CM","CA","CV","KY","CF","TD","CL","CN","CX","CC","CO","KM","CG","CD","CK","CR","CI","HR","CU","CY","CZ","DK","DJ","DM","DO","EC","EG","SV","GQ","ER","EE","ET","FK","FO","FJ","FI","FR","GF","PF","TF","GA","GM","GE","DE","GH","GI","GR","GL","GD","GP","GU","GT","GN","GW","GY","HT","HM","VA","HN","HK","HU","IS","IN","ID","IR","IQ","IE","IL","IT","JM","JP","JO","KZ","KE","KI","KP","KR","KW","KG","LA","LV","LB","LS","LR","LY","LI","LT","LU","MO","MK","MG","MW","MY","MV","ML","MT","MH","MQ","MR","MU","YT","MX","FM","MD","MC","MN","MS","ME","MA","MZ","MM","NA","NR","NP","NL","NC","NZ","NI","NE","NG","NU","NF","MP","NO","OM","PK","PW","PS","PA","PG","PY","PE","PH","PN","PL","PT","PR","QA","RE","RO","RU","RW","SH","KN","LC","PM","VC","WS","SM","ST","SA","SN","RS","SC","SL","SG","SK","SI","SB","SO","ZA","GS","ES","LK","SD","SR","SJ","SZ","SE","CH","SY","TW","TJ","TZ","TH","TL","TG","TK","TO","TT","TN","TR","TM","TC","TV","UG","UA","AE","GB","US","UM","UY","UZ","VU","VE","VN","VG","VI","WF","EH","YE","ZM","ZW","AX","BQ","CW","GG","IM","JE","BL","MF","SX","XK","SS"];var r$1={};V(r$1,{countries:()=>L,default:()=>p7,locale:()=>y$1});var y$1="en",L={AF:"Afghanistan",AL:"Albania",DZ:"Algeria",AS:"American Samoa",AD:"Andorra",AO:"Angola",AI:"Anguilla",AQ:"Antarctica",AG:"Antigua and Barbuda",AR:"Argentina",AM:"Armenia",AW:"Aruba",AU:"Australia",AT:"Austria",AZ:"Azerbaijan",BS:"Bahamas",BH:"Bahrain",BD:"Bangladesh",BB:"Barbados",BY:"Belarus",BE:"Belgium",BZ:"Belize",BJ:"Benin",BM:"Bermuda",BT:"Bhutan",BO:"Bolivia",BA:"Bosnia and Herzegovina",BW:"Botswana",BV:"Bouvet Island",BR:"Brazil",IO:"British Indian Ocean Territory",BN:"Brunei Darussalam",BG:"Bulgaria",BF:"Burkina Faso",BI:"Burundi",KH:"Cambodia",CM:"Cameroon",CA:"Canada",CV:"Cape Verde",KY:"Cayman Islands",CF:"Central African Republic",TD:"Chad",CL:"Chile",CN:"China",CX:"Christmas Island",CC:"Cocos (Keeling) Islands",CO:"Colombia",KM:"Comoros",CG:"Republic of the Congo",CD:"Democratic Republic of the Congo",CK:"Cook Islands",CR:"Costa Rica",CI:"Cote D'Ivoire",HR:"Croatia",CU:"Cuba",CY:"Cyprus",CZ:"Czech Republic",DK:"Denmark",DJ:"Djibouti",DM:"Dominica",DO:"Dominican Republic",EC:"Ecuador",EG:"Egypt",SV:"El Salvador",GQ:"Equatorial Guinea",ER:"Eritrea",EE:"Estonia",ET:"Ethiopia",FK:"Falkland Islands (Malvinas)",FO:"Faroe Islands",FJ:"Fiji",FI:"Finland",FR:"France",GF:"French Guiana",PF:"French Polynesia",TF:"French Southern Territories",GA:"Gabon",GM:"Gambia",GE:"Georgia",DE:"Germany",GH:"Ghana",GI:"Gibraltar",GR:"Greece",GL:"Greenland",GD:"Grenada",GP:"Guadeloupe",GU:"Guam",GT:"Guatemala",GN:"Guinea",GW:"Guinea-Bissau",GY:"Guyana",HT:"Haiti",HM:"Heard Island and McDonald Islands",VA:"Holy See (Vatican City State)",HN:"Honduras",HK:"Hong Kong",HU:"Hungary",IS:"Iceland",IN:"India",ID:"Indonesia",IR:"Iran",IQ:"Iraq",IE:"Ireland",IL:"Israel",IT:"Italy",JM:"Jamaica",JP:"Japan",JO:"Jordan",KZ:"Kazakhstan",KE:"Kenya",KI:"Kiribati",KP:"North Korea",KR:"South Korea",KW:"Kuwait",KG:"Kyrgyzstan",LA:"Lao People's Democratic Republic",LV:"Latvia",LB:"Lebanon",LS:"Lesotho",LR:"Liberia",LY:"Libya",LI:"Liechtenstein",LT:"Lithuania",LU:"Luxembourg",MO:"Macao",MG:"Madagascar",MW:"Malawi",MY:"Malaysia",MV:"Maldives",ML:"Mali",MT:"Malta",MH:"Marshall Islands",MQ:"Martinique",MR:"Mauritania",MU:"Mauritius",YT:"Mayotte",MX:"Mexico",FM:"Micronesia, Federated States of",MD:"Moldova, Republic of",MC:"Monaco",MN:"Mongolia",MS:"Montserrat",MA:"Morocco",MZ:"Mozambique",MM:"Myanmar",NA:"Namibia",NR:"Nauru",NP:"Nepal",NL:"Netherlands",NC:"New Caledonia",NZ:"New Zealand",NI:"Nicaragua",NE:"Niger",NG:"Nigeria",NU:"Niue",NF:"Norfolk Island",MK:"North Macedonia",MP:"Northern Mariana Islands",NO:"Norway",OM:"Oman",PK:"Pakistan",PW:"Palau",PS:"Palestine",PA:"Panama",PG:"Papua New Guinea",PY:"Paraguay",PE:"Peru",PH:"Philippines",PN:"Pitcairn",PL:"Poland",PT:"Portugal",PR:"Puerto Rico",QA:"Qatar",RE:"Reunion",RO:"Romania",RU:"Russia",RW:"Rwanda",SH:"Saint Helena",KN:"Saint Kitts and Nevis",LC:"Saint Lucia",PM:"Saint Pierre and Miquelon",VC:"Saint Vincent and the Grenadines",WS:"Samoa",SM:"San Marino",ST:"Sao Tome and Principe",SA:"Saudi Arabia",SN:"Senegal",SC:"Seychelles",SL:"Sierra Leone",SG:"Singapore",SK:"Slovakia",SI:"Slovenia",SB:"Solomon Islands",SO:"Somalia",ZA:"South Africa",GS:"South Georgia and the South Sandwich Islands",ES:"Spain",LK:"Sri Lanka",SD:"Sudan",SR:"Suriname",SJ:"Svalbard and Jan Mayen",SZ:"Eswatini",SE:"Sweden",CH:"Switzerland",SY:"Syrian Arab Republic",TW:"Taiwan",TJ:"Tajikistan",TZ:"Tanzania",TH:"Thailand",TL:"Timor-Leste",TG:"Togo",TK:"Tokelau",TO:"Tonga",TT:"Trinidad and Tobago",TN:"Tunisia",TR:"Turkey",TM:"Turkmenistan",TC:"Turks and Caicos Islands",TV:"Tuvalu",UG:"Uganda",UA:"Ukraine",AE:"United Arab Emirates",GB:"United Kingdom",US:"United States",UM:"United States Minor Outlying Islands",UY:"Uruguay",UZ:"Uzbekistan",VU:"Vanuatu",VE:"Venezuela",VN:"Vietnam",VG:"Virgin Islands, British",VI:"Virgin Islands, U.S.",WF:"Wallis and Futuna",EH:"Western Sahara",YE:"Yemen",ZM:"Zambia",ZW:"Zimbabwe",AX:"\xC5land Islands",BQ:"Bonaire, Sint Eustatius and Saba",CW:"Cura\xE7ao",GG:"Guernsey",IM:"Isle of Man",JE:"Jersey",ME:"Montenegro",BL:"Saint Barth\xE9lemy",MF:"Saint Martin (French part)",RS:"Serbia",SX:"Sint Maarten (Dutch part)",SS:"South Sudan",XK:"Kosovo"},p7={locale:y$1,countries:L};var m$2={};V(m$2,{countries:()=>S,default:()=>M7,locale:()=>B});var B="de",S={AF:"Afghanistan",EG:"\xC4gypten",AX:"\xC5land",AL:"Albanien",DZ:"Algerien",AS:"Amerikanisch-Samoa",VI:"Amerikanische Jungferninseln",AD:"Andorra",AO:"Angola",AI:"Anguilla",AQ:"Antarktis",AG:"Antigua und Barbuda",GQ:"\xC4quatorialguinea",AR:"Argentinien",AM:"Armenien",AW:"Aruba",AZ:"Aserbaidschan",ET:"\xC4thiopien",AU:"Australien",BS:"Bahamas",BH:"Bahrain",BD:"Bangladesch",BB:"Barbados",BY:"Belarus",BE:"Belgien",BZ:"Belize",BJ:"Benin",BM:"Bermuda",BT:"Bhutan",BO:"Bolivien",BQ:"Bonaire",BA:"Bosnien und Herzegowina",BW:"Botswana",BV:"Bouvetinsel",BR:"Brasilien",VG:"Britische Jungferninseln",IO:"Britisches Territorium im Indischen Ozean",BN:"Brunei Darussalam",BG:"Bulgarien",BF:"Burkina Faso",BI:"Burundi",CL:"Chile",CN:"China",CK:"Cookinseln",CR:"Costa Rica",CI:"Elfenbeink\xFCste",CW:"Cura\xE7ao",DK:"D\xE4nemark",DE:"Deutschland",DM:"Dominica",DO:"Dominikanische Republik",DJ:"Dschibuti",EC:"Ecuador",SV:"El Salvador",ER:"Eritrea",EE:"Estland",FK:"Falklandinseln",FO:"F\xE4r\xF6er",FJ:"Fidschi",FI:"Finnland",FR:"Frankreich",GF:"Franz\xF6sisch-Guayana",PF:"Franz\xF6sisch-Polynesien",TF:"Franz\xF6sische S\xFCd- und Antarktisgebiete",GA:"Gabun",GM:"Gambia",GE:"Georgien",GH:"Ghana",GI:"Gibraltar",GD:"Grenada",GR:"Griechenland",GL:"Gr\xF6nland",GP:"Guadeloupe",GU:"Guam",GT:"Guatemala",GG:"Guernsey",GN:"Guinea",GW:"Guinea-Bissau",GY:"Guyana",HT:"Haiti",HM:"Heard und McDonaldinseln",HN:"Honduras",HK:"Hongkong",IN:"Indien",ID:"Indonesien",IM:"Insel Man",IQ:"Irak",IR:"Iran",IE:"Irland",IS:"Island",IL:"Israel",IT:"Italien",JM:"Jamaika",JP:"Japan",YE:"Jemen",JE:"Jersey",JO:"Jordanien",KY:"Kaimaninseln",KH:"Kambodscha",CM:"Kamerun",CA:"Kanada",CV:"Kap Verde",KZ:"Kasachstan",QA:"Katar",KE:"Kenia",KG:"Kirgisistan",KI:"Kiribati",CC:"Kokosinseln",CO:"Kolumbien",KM:"Komoren",CD:"Kongo",KP:"Nordkorea",KR:"S\xFCdkorea",HR:"Kroatien",CU:"Kuba",KW:"Kuwait",LA:"Laos",LS:"Lesotho",LV:"Lettland",LB:"Libanon",LR:"Liberia",LY:"Libyen",LI:"Liechtenstein",LT:"Litauen",LU:"Luxemburg",MO:"Macao",MG:"Madagaskar",MW:"Malawi",MY:"Malaysia",MV:"Malediven",ML:"Mali",MT:"Malta",MA:"Marokko",MH:"Marshallinseln",MQ:"Martinique",MR:"Mauretanien",MU:"Mauritius",YT:"Mayotte",MX:"Mexiko",FM:"Mikronesien",MD:"Moldawien",MC:"Monaco",MN:"Mongolei",ME:"Montenegro",MS:"Montserrat",MZ:"Mosambik",MM:"Myanmar",NA:"Namibia",NR:"Nauru",NP:"Nepal",NC:"Neukaledonien",NZ:"Neuseeland",NI:"Nicaragua",NL:"Niederlande",NE:"Niger",NG:"Nigeria",NU:"Niue",MK:"Nordmazedonien",MP:"N\xF6rdliche Marianen",NF:"Norfolkinsel",NO:"Norwegen",OM:"Oman",AT:"\xD6sterreich",TL:"Osttimor",PK:"Pakistan",PS:"Staat Pal\xE4stina",PW:"Palau",PA:"Panama",PG:"Papua-Neuguinea",PY:"Paraguay",PE:"Peru",PH:"Philippinen",PN:"Pitcairninseln",PL:"Polen",PT:"Portugal",PR:"Puerto Rico",TW:"Taiwan",CG:"Republik Kongo",RE:"R\xE9union",RW:"Ruanda",RO:"Rum\xE4nien",RU:"Russische F\xF6deration",BL:"Saint-Barth\xE9lemy",MF:"Saint-Martin",SB:"Salomonen",ZM:"Sambia",WS:"Samoa",SM:"San Marino",ST:"S\xE3o Tom\xE9 und Pr\xEDncipe",SA:"Saudi-Arabien",SE:"Schweden",CH:"Schweiz",SN:"Senegal",RS:"Serbien",SC:"Seychellen",SL:"Sierra Leone",ZW:"Simbabwe",SG:"Singapur",SX:"Sint Maarten",SK:"Slowakei",SI:"Slowenien",SO:"Somalia",ES:"Spanien",LK:"Sri Lanka",SH:"St. Helena",KN:"St. Kitts und Nevis",LC:"St. Lucia",PM:"Saint-Pierre und Miquelon",VC:"St. Vincent und die Grenadinen",ZA:"S\xFCdafrika",SD:"Sudan",GS:"S\xFCdgeorgien und die S\xFCdlichen Sandwichinseln",SS:"S\xFCdsudan",SR:"Suriname",SJ:"Svalbard und Jan Mayen",SZ:"Eswatini",SY:"Syrien, Arabische Republik",TJ:"Tadschikistan",TZ:"Tansania, Vereinigte Republik",TH:"Thailand",TG:"Togo",TK:"Tokelau",TO:"Tonga",TT:"Trinidad und Tobago",TD:"Tschad",CZ:"Tschechische Republik",TN:"Tunesien",TR:"T\xFCrkei",TM:"Turkmenistan",TC:"Turks- und Caicosinseln",TV:"Tuvalu",UG:"Uganda",UA:"Ukraine",HU:"Ungarn",UM:"United States Minor Outlying Islands",UY:"Uruguay",UZ:"Usbekistan",VU:"Vanuatu",VA:"Vatikanstadt",VE:"Venezuela",AE:"Vereinigte Arabische Emirate",US:"Vereinigte Staaten",GB:"Vereinigtes K\xF6nigreich",VN:"Vietnam",WF:"Wallis und Futuna",CX:"Weihnachtsinsel",EH:"Westsahara",CF:"Zentralafrikanische Republik",CY:"Zypern",XK:"Kosovo"},M7={locale:B,countries:S};var c7={en:r$1,de:m$2};function $5(t,a="en"){return c7[a].countries[t]}var f7=(t="en")=>s.map(a=>({name:c7[t].countries[a],code:a}));f7();
|
|
@@ -8126,19 +8115,19 @@ var loadGoogleMapsApiDynamically = function (callback, apiKey) {
|
|
|
8126
8115
|
var AutoCompleteAddress = function (_a) {
|
|
8127
8116
|
var _b;
|
|
8128
8117
|
var apiKey = _a.apiKey, initialAddress = _a.address, onAddressChange = _a.onAddressChange, placeholders = _a.placeholders, manualAddressEntryTexts = _a.manualAddressEntryTexts;
|
|
8129
|
-
var _c =
|
|
8130
|
-
var _d =
|
|
8131
|
-
var autocomplete =
|
|
8132
|
-
var autocompleteElement =
|
|
8133
|
-
var map =
|
|
8134
|
-
var marker =
|
|
8135
|
-
var _e =
|
|
8136
|
-
var _f =
|
|
8118
|
+
var _c = useState(false), manualAddressEntry = _c[0], setManualAddressEntry = _c[1];
|
|
8119
|
+
var _d = useState(false), isLoading = _d[0], setIsLoading = _d[1];
|
|
8120
|
+
var autocomplete = useRef(null);
|
|
8121
|
+
var autocompleteElement = useRef(null);
|
|
8122
|
+
var map = useRef(null);
|
|
8123
|
+
var marker = useRef(null);
|
|
8124
|
+
var _e = useState(initialAddress), address = _e[0], setAddress = _e[1];
|
|
8125
|
+
var _f = useState(window.google !== undefined), hasLoadedGoogleAPI = _f[0], setHasLoadedGoogleAPI = _f[1];
|
|
8137
8126
|
loadGoogleMapsApiDynamically(function () {
|
|
8138
8127
|
setHasLoadedGoogleAPI(true);
|
|
8139
8128
|
}, apiKey);
|
|
8140
|
-
var _g =
|
|
8141
|
-
|
|
8129
|
+
var _g = useState(null), place = _g[0], setPlace = _g[1];
|
|
8130
|
+
useEffect(function () {
|
|
8142
8131
|
if (address) {
|
|
8143
8132
|
if (autocompleteElement.current && address.street) {
|
|
8144
8133
|
autocompleteElement.current.value = address.street;
|
|
@@ -8149,7 +8138,7 @@ var AutoCompleteAddress = function (_a) {
|
|
|
8149
8138
|
handleEnterAddressManually();
|
|
8150
8139
|
}
|
|
8151
8140
|
}, [initialAddress, address, onAddressChange, hasLoadedGoogleAPI]);
|
|
8152
|
-
|
|
8141
|
+
useEffect(function () {
|
|
8153
8142
|
if (hasLoadedGoogleAPI === false) {
|
|
8154
8143
|
return;
|
|
8155
8144
|
}
|
|
@@ -8160,7 +8149,7 @@ var AutoCompleteAddress = function (_a) {
|
|
|
8160
8149
|
});
|
|
8161
8150
|
autocomplete.current.addListener('place_changed', onPlaceChanged);
|
|
8162
8151
|
map.current = new google.maps.Map(document.getElementById('map'), MAP_CONFIG_OBJ);
|
|
8163
|
-
|
|
8152
|
+
import('./mapStyle-1288a869.js').then(function (_a) {
|
|
8164
8153
|
var _b, _c;
|
|
8165
8154
|
var style = _a.style;
|
|
8166
8155
|
(_b = map.current) === null || _b === void 0 ? void 0 : _b.mapTypes.set('styled_map', style);
|
|
@@ -8186,7 +8175,7 @@ var AutoCompleteAddress = function (_a) {
|
|
|
8186
8175
|
(_e = marker.current) === null || _e === void 0 ? void 0 : _e.setPosition(newPlace.geometry.location);
|
|
8187
8176
|
}
|
|
8188
8177
|
};
|
|
8189
|
-
var setPlaceFromAddress =
|
|
8178
|
+
var setPlaceFromAddress = useCallback(function (address) {
|
|
8190
8179
|
var _a, _b, _c;
|
|
8191
8180
|
if (!map.current) {
|
|
8192
8181
|
return;
|
|
@@ -8215,38 +8204,38 @@ var AutoCompleteAddress = function (_a) {
|
|
|
8215
8204
|
var handleEnterAddressManually = function () {
|
|
8216
8205
|
setManualAddressEntry(true);
|
|
8217
8206
|
};
|
|
8218
|
-
return (
|
|
8207
|
+
return (jsxs(Fragment$1, { children: [jsxs("div", __assign({ className: classNames("wmx8 bg-grey-500 " + styles$o['map-container'], (_b = {},
|
|
8219
8208
|
_b[styles$o['map-container--hidden']] = place === null,
|
|
8220
|
-
_b)) }, { children: [
|
|
8221
|
-
isLoading && (
|
|
8222
|
-
|
|
8223
|
-
hasLoadedGoogleAPI === false && (
|
|
8209
|
+
_b)) }, { children: [jsx("div", { className: styles$o.map, id: "map" }, void 0),
|
|
8210
|
+
isLoading && (jsx("div", __assign({ className: styles$o['loading-spinner'] }, { children: jsx("div", { className: "ds-spinner ds-spinner__m" }, void 0) }), void 0))] }), void 0),
|
|
8211
|
+
jsx("div", __assign({ className: "wmx8" }, { children: manualAddressEntry === false ? (jsxs("div", __assign({ style: { position: 'relative' } }, { children: [jsx(Input, { className: "w100", id: "autocomplete", "data-cy": "autocomplete", type: "text", placeholder: (placeholders === null || placeholders === void 0 ? void 0 : placeholders.manualAddressEntry) || 'Search for address', ref: autocompleteElement }, void 0),
|
|
8212
|
+
hasLoadedGoogleAPI === false && (jsx("div", __assign({ className: styles$o['loading-spinner'] }, { children: jsx("div", { className: "ds-spinner ds-spinner__m" }, void 0) }), void 0))] }), void 0)) : (jsxs(Fragment$1, { children: [jsxs("div", __assign({ className: "d-flex c-gap16 " + styles$o['input-line'] }, { children: [jsx(Input, { className: "w100", "data-cy": "autocomplete", type: "text", placeholder: (placeholders === null || placeholders === void 0 ? void 0 : placeholders.street) || 'Street', value: (address === null || address === void 0 ? void 0 : address.street) || '', onChange: function (e) {
|
|
8224
8213
|
var newAddress = __assign(__assign({}, address), { street: e.target.value, country: GERMANY_ALPHA_CODE });
|
|
8225
8214
|
setAddress(newAddress);
|
|
8226
8215
|
debouncedSetPlace(newAddress);
|
|
8227
8216
|
} }, void 0),
|
|
8228
|
-
|
|
8217
|
+
jsx(Input, { className: "wmx2 " + styles$o['house-number-input'], "data-cy": "autocomplete-house-number", placeholder: (placeholders === null || placeholders === void 0 ? void 0 : placeholders.houseNumber) || 'House Number', value: (address === null || address === void 0 ? void 0 : address.houseNumber) || '', onChange: function (e) {
|
|
8229
8218
|
var newAddress = __assign(__assign({}, address), { houseNumber: e.target.value, country: GERMANY_ALPHA_CODE });
|
|
8230
8219
|
setAddress(newAddress);
|
|
8231
8220
|
debouncedSetPlace(newAddress);
|
|
8232
8221
|
} }, void 0)] }), void 0),
|
|
8233
|
-
|
|
8222
|
+
jsx(Input, { className: "mt16", "data-cy": "autocomplete-additional-info", placeholder: (placeholders === null || placeholders === void 0 ? void 0 : placeholders.additionalInformation) ||
|
|
8234
8223
|
'Additional information (C/O, apartment, …)', value: (address === null || address === void 0 ? void 0 : address.additionalInformation) || '', onChange: function (e) {
|
|
8235
8224
|
var newAddress = __assign(__assign({}, address), { additionalInformation: e.target.value, country: GERMANY_ALPHA_CODE });
|
|
8236
8225
|
setAddress(newAddress);
|
|
8237
8226
|
} }, void 0),
|
|
8238
|
-
|
|
8227
|
+
jsxs("div", __assign({ className: "d-flex mt16 c-gap16 " + styles$o['input-line'] }, { children: [jsx(Input, { className: "w100", "data-cy": "autocomplete-postcode", placeholder: (placeholders === null || placeholders === void 0 ? void 0 : placeholders.postcode) || 'Postcode', value: (address === null || address === void 0 ? void 0 : address.postcode) || '', onChange: function (e) {
|
|
8239
8228
|
var newAddress = __assign(__assign({}, address), { postcode: e.target.value, country: GERMANY_ALPHA_CODE });
|
|
8240
8229
|
setAddress(newAddress);
|
|
8241
8230
|
debouncedSetPlace(newAddress);
|
|
8242
8231
|
} }, void 0),
|
|
8243
|
-
|
|
8232
|
+
jsx(Input, { className: "w100", "data-cy": "autocomplete-city", placeholder: (placeholders === null || placeholders === void 0 ? void 0 : placeholders.city) || 'City', value: (address === null || address === void 0 ? void 0 : address.city) || '', onChange: function (e) {
|
|
8244
8233
|
var newAddress = __assign(__assign({}, address), { city: e.target.value, country: GERMANY_ALPHA_CODE });
|
|
8245
8234
|
setAddress(newAddress);
|
|
8246
8235
|
debouncedSetPlace(newAddress);
|
|
8247
8236
|
} }, void 0)] }), void 0)] }, void 0)) }), void 0),
|
|
8248
|
-
manualAddressEntry === false && (
|
|
8249
|
-
|
|
8237
|
+
manualAddressEntry === false && (jsxs("div", __assign({ className: "p-p mt8" }, { children: [(manualAddressEntryTexts === null || manualAddressEntryTexts === void 0 ? void 0 : manualAddressEntryTexts.preText) || 'Or ',
|
|
8238
|
+
jsx("span", __assign({ className: "p-a fw-bold c-pointer", onClick: handleEnterAddressManually }, { children: (manualAddressEntryTexts === null || manualAddressEntryTexts === void 0 ? void 0 : manualAddressEntryTexts.cta) || 'Enter address manually' }), void 0)] }), void 0))] }, void 0));
|
|
8250
8239
|
};
|
|
8251
8240
|
|
|
8252
8241
|
var __rest = (undefined && undefined.__rest) || function (s, e) {
|
|
@@ -8308,13 +8297,13 @@ function getStaticStateClasses(animationStateClasses, height) {
|
|
|
8308
8297
|
const AnimateHeight = (_a) => {
|
|
8309
8298
|
var { animateOpacity = false, animationStateClasses = {}, applyInlineTransitions = true, children, className = '', contentClassName, delay: userDelay = 0, duration: userDuration = 500, easing = 'ease', height, onHeightAnimationEnd, onHeightAnimationStart, style } = _a, props = __rest(_a, ["animateOpacity", "animationStateClasses", "applyInlineTransitions", "children", "className", "contentClassName", "delay", "duration", "easing", "height", "onHeightAnimationEnd", "onHeightAnimationStart", "style"]);
|
|
8310
8299
|
// ------------------ Initialization
|
|
8311
|
-
const prevHeight =
|
|
8312
|
-
const contentElement =
|
|
8313
|
-
const animationClassesTimeoutID =
|
|
8314
|
-
const timeoutID =
|
|
8315
|
-
const stateClasses =
|
|
8300
|
+
const prevHeight = useRef(height);
|
|
8301
|
+
const contentElement = useRef(null);
|
|
8302
|
+
const animationClassesTimeoutID = useRef();
|
|
8303
|
+
const timeoutID = useRef();
|
|
8304
|
+
const stateClasses = useRef(Object.assign(Object.assign({}, ANIMATION_STATE_CLASSES), animationStateClasses));
|
|
8316
8305
|
const isBrowser = typeof window !== 'undefined';
|
|
8317
|
-
const prefersReducedMotion =
|
|
8306
|
+
const prefersReducedMotion = useRef(isBrowser && window.matchMedia
|
|
8318
8307
|
? window.matchMedia('(prefers-reduced-motion)').matches
|
|
8319
8308
|
: false);
|
|
8320
8309
|
const delay = prefersReducedMotion.current ? 0 : userDelay;
|
|
@@ -8331,19 +8320,19 @@ const AnimateHeight = (_a) => {
|
|
|
8331
8320
|
initHeight = height === '0%' ? 0 : height;
|
|
8332
8321
|
initOverflow = 'hidden';
|
|
8333
8322
|
}
|
|
8334
|
-
const [currentHeight, setCurrentHeight] =
|
|
8335
|
-
const [overflow, setOverflow] =
|
|
8336
|
-
const [useTransitions, setUseTransitions] =
|
|
8337
|
-
const [animationStateClassNames, setAnimationStateClassNames] =
|
|
8323
|
+
const [currentHeight, setCurrentHeight] = useState(initHeight);
|
|
8324
|
+
const [overflow, setOverflow] = useState(initOverflow);
|
|
8325
|
+
const [useTransitions, setUseTransitions] = useState(false);
|
|
8326
|
+
const [animationStateClassNames, setAnimationStateClassNames] = useState(getStaticStateClasses(stateClasses.current, height));
|
|
8338
8327
|
// ------------------ Did mount
|
|
8339
|
-
|
|
8328
|
+
useEffect(() => {
|
|
8340
8329
|
// Hide content if height is 0 (to prevent tabbing into it)
|
|
8341
8330
|
hideContent(contentElement.current, currentHeight);
|
|
8342
8331
|
// This should be explicitly run only on mount
|
|
8343
8332
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
8344
8333
|
}, []);
|
|
8345
8334
|
// ------------------ Height update
|
|
8346
|
-
|
|
8335
|
+
useEffect(() => {
|
|
8347
8336
|
if (height !== prevHeight.current && contentElement.current) {
|
|
8348
8337
|
showContent(contentElement.current, prevHeight.current);
|
|
8349
8338
|
// Cache content height
|
|
@@ -8477,8 +8466,8 @@ const AnimateHeight = (_a) => {
|
|
|
8477
8466
|
// Check if user passed aria-hidden prop
|
|
8478
8467
|
const hasAriaHiddenProp = typeof props['aria-hidden'] !== 'undefined';
|
|
8479
8468
|
const ariaHidden = hasAriaHiddenProp ? props['aria-hidden'] : height === 0;
|
|
8480
|
-
return (require$$
|
|
8481
|
-
require$$
|
|
8469
|
+
return (require$$0.createElement("div", Object.assign({}, props, { "aria-hidden": ariaHidden, className: `${animationStateClassNames} ${className}`, style: componentStyle }),
|
|
8470
|
+
require$$0.createElement("div", { className: contentClassName, style: contentStyle, ref: contentElement }, children)));
|
|
8482
8471
|
};
|
|
8483
8472
|
|
|
8484
8473
|
var css_248z$o = ".style-module_container__Uyltc {\n background-color: transparent;\n}\n\n.style-module_dropzoneContainer__yZoGP {\n border: 1px dashed var(--ds-primary-500);\n padding: 32px 0;\n background-color: white;\n transition: all 0.6s ease-in-out;\n}\n\n.style-module_img__11JI8 {\n vertical-align: middle;\n margin-right: 8px;\n height: 18px;\n}\n\n.style-module_textInline__2F21z {\n display: inline-flex;\n}\n\n.style-module_dropzoneContainer__yZoGP:focus {\n outline: none;\n}\n\n.style-module_dropzoneContainer__yZoGP:hover {\n background-color: var(--ds-primary-100);\n transition: 0.5s ease;\n}\n\n.style-module_dropzoneContainerDisabled__1X3gP {\n pointer-events: none;\n opacity: 0.4;\n}";
|
|
@@ -8616,16 +8605,16 @@ var UploadFileCell = (function (_a) {
|
|
|
8616
8605
|
COMPLETE: name,
|
|
8617
8606
|
ERROR: error !== null && error !== void 0 ? error : 'Something went wrong. Try uploading again.',
|
|
8618
8607
|
};
|
|
8619
|
-
return (
|
|
8608
|
+
return (jsxs("div", __assign({ className: classNames("mt8 " + styles$m['upload-file-cell'], (_b = {},
|
|
8620
8609
|
_b[styles$m['upload-file-cell-error']] = uploadStatus === 'ERROR',
|
|
8621
|
-
_b)) }, { children: [
|
|
8622
|
-
|
|
8623
|
-
uploadStatus === 'UPLOADING' && (
|
|
8624
|
-
|
|
8625
|
-
|
|
8610
|
+
_b)) }, { children: [jsxs("div", __assign({ className: "w100 " + styles$m['cell-left-section'] }, { children: [jsx("img", { className: styles$m['main-icon'], src: mapFileIcon[uploadStatus], alt: "" }, void 0),
|
|
8611
|
+
jsxs("div", __assign({ className: "w100" }, { children: [jsx("div", __assign({ className: "p-p wmx5 " + styles$m['upload-display-text'] }, { children: mapDisplayText[uploadStatus] }), void 0),
|
|
8612
|
+
uploadStatus === 'UPLOADING' && (jsxs("div", __assign({ className: "mt8 w100 " + styles$m['progress-bar-container'] }, { children: [jsx("div", { className: "" + styles$m['progress-bar'] }, void 0),
|
|
8613
|
+
jsx("div", { className: "" + styles$m['progress-bar-filler'], style: { width: progress + "%" } }, void 0)] }), void 0))] }), void 0)] }), void 0),
|
|
8614
|
+
jsx("div", __assign({ className: classNames(styles$m['cell-right-section'], (_c = {},
|
|
8626
8615
|
_c[styles$m['cell-right-section-complete']] = uploadStatus === 'COMPLETE',
|
|
8627
|
-
_c)) }, { children: uploadStatus === 'UPLOADING' ? (
|
|
8628
|
-
|
|
8616
|
+
_c)) }, { children: uploadStatus === 'UPLOADING' ? (jsx("div", { className: "p-spinner p-spinner__m " + styles$m.spinner }, void 0)) : (jsxs("div", { children: [uploadStatus === 'COMPLETE' && (jsx("a", __assign({ className: styles$m['view-icon'], href: previewUrl, target: "_blank", rel: "noopener noreferrer" }, { children: jsx("img", { src: icons.eyeIcon, alt: "preview" }, void 0) }), void 0)),
|
|
8617
|
+
jsx("img", { className: classNames(styles$m['remove-icon'], (_d = {},
|
|
8629
8618
|
_d[styles$m.disabled] = uploading,
|
|
8630
8619
|
_d)), src: icons.trashIcon, onClick: function () { return onRemoveFile(id); }, alt: "remove" }, void 0)] }, void 0)) }), void 0)] }), void 0));
|
|
8631
8620
|
});
|
|
@@ -8642,8 +8631,8 @@ var getUploadStatus = function (progress, error) {
|
|
|
8642
8631
|
var index$8 = (function (_a) {
|
|
8643
8632
|
var _b;
|
|
8644
8633
|
var uploadedFiles = _a.uploadedFiles, onFileSelect = _a.onFileSelect, uploading = _a.uploading, onRemoveFile = _a.onRemoveFile, _c = _a.isCondensed, isCondensed = _c === void 0 ? false : _c, _d = _a.maxFiles, maxFiles = _d === void 0 ? 0 : _d;
|
|
8645
|
-
var _e =
|
|
8646
|
-
var onDrop =
|
|
8634
|
+
var _e = useState(''), error = _e[0], setError = _e[1];
|
|
8635
|
+
var onDrop = useCallback(function (acceptedFiles, filesRejected) {
|
|
8647
8636
|
setError('');
|
|
8648
8637
|
if (filesRejected.length > 0) {
|
|
8649
8638
|
setError(filesRejected[0].errors[0].message);
|
|
@@ -8652,29 +8641,29 @@ var index$8 = (function (_a) {
|
|
|
8652
8641
|
onFileSelect(acceptedFiles);
|
|
8653
8642
|
}, [onFileSelect]);
|
|
8654
8643
|
var _f = useDropzone({ onDrop: onDrop, maxFiles: maxFiles }), getRootProps = _f.getRootProps, getInputProps = _f.getInputProps;
|
|
8655
|
-
return (
|
|
8644
|
+
return (jsxs("div", __assign({ className: styles$n.container }, { children: [jsxs("div", __assign({ className: classNames("w100 ta-center br8 c-pointer " + styles$n.dropzoneContainer, (_b = {},
|
|
8656
8645
|
_b[styles$n['dropzoneContainerDisabled']] = uploading,
|
|
8657
|
-
_b)) }, getRootProps(), { children: [
|
|
8658
|
-
|
|
8659
|
-
|
|
8646
|
+
_b)) }, getRootProps(), { children: [jsx("input", __assign({}, getInputProps()), void 0),
|
|
8647
|
+
jsx("img", { className: isCondensed ? styles$n.img : '', src: icons.uploadIcon, alt: "purple cloud with an arrow" }, void 0),
|
|
8648
|
+
jsx("div", __assign({ className: "p-h4 mt8 " + (isCondensed ? styles$n.textInline : '') }, { children: uploading
|
|
8660
8649
|
? 'Please wait while uploading file...'
|
|
8661
8650
|
: 'Choose file or drag & drop' }), void 0),
|
|
8662
|
-
|
|
8663
|
-
|
|
8664
|
-
uploadedFiles.length > 0 && (
|
|
8651
|
+
jsx("div", __assign({ className: "p-p--small tc-grey-500" }, { children: "Supports JPEG, PNG, PDF" }), void 0)] }), void 0),
|
|
8652
|
+
jsx(AnimateHeight, __assign({ duration: 300, height: error ? 'auto' : 0 }, { children: jsx("p", __assign({ className: "tc-red-500 p-p--small" }, { children: error }), void 0) }), void 0),
|
|
8653
|
+
uploadedFiles.length > 0 && (jsx("div", __assign({ className: "w100 mt16" }, { children: uploadedFiles.map(function (file) {
|
|
8665
8654
|
var uploadStatus = getUploadStatus(file.progress, file.error);
|
|
8666
|
-
return (
|
|
8655
|
+
return (jsx(UploadFileCell, { uploadStatus: uploadStatus, file: file, onRemoveFile: onRemoveFile, uploading: uploading }, file.id));
|
|
8667
8656
|
}) }), void 0))] }), void 0));
|
|
8668
8657
|
});
|
|
8669
8658
|
|
|
8670
|
-
var CheckOutsideCircleIcon = (function () { return (
|
|
8671
|
-
|
|
8659
|
+
var CheckOutsideCircleIcon = (function () { return (jsxs("svg", __assign({ width: "63", height: "63", viewBox: "0 0 63 63", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: [jsx("path", { d: "M57.75 29.0849V31.4999C57.7468 37.1605 55.9138 42.6684 52.5245 47.2022C49.1352 51.7359 44.3711 55.0526 38.9428 56.6576C33.5145 58.2626 27.7128 58.0699 22.403 56.1082C17.0932 54.1465 12.5597 50.5209 9.47877 45.7722C6.39782 41.0235 4.93445 35.4061 5.3069 29.7577C5.67935 24.1094 7.86767 18.7327 11.5455 14.4297C15.2233 10.1267 20.1936 7.12777 25.715 5.88027C31.2364 4.63278 37.0132 5.20352 42.1838 7.50739", stroke: "#90DF9B", strokeWidth: "5", strokeLinecap: "round", strokeLinejoin: "round" }, void 0),
|
|
8660
|
+
jsx("path", { d: "M57.75 10.5L31.5 36.7762L23.625 28.9012", stroke: "#90DF9B", strokeWidth: "5", strokeLinecap: "round", strokeLinejoin: "round" }, void 0)] }), void 0)); });
|
|
8672
8661
|
|
|
8673
8662
|
var css_248z$m = ".style-module_stroke-primary-500__3E5m3 {\n stroke: var(--ds-primary-500);\n}\n\n.style-module_fill-primary-500__1_3Nh {\n fill: var(--ds-primary-500);\n}";
|
|
8674
8663
|
var styles$l = {"stroke-primary-500":"style-module_stroke-primary-500__3E5m3","fill-primary-500":"style-module_fill-primary-500__1_3Nh"};
|
|
8675
8664
|
styleInject(css_248z$m);
|
|
8676
8665
|
|
|
8677
|
-
var DownloadCloudIcon = (function () { return (
|
|
8666
|
+
var DownloadCloudIcon = (function () { return (jsx("svg", __assign({ width: "81", height: "60", viewBox: "0 0 81 60", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: jsx("path", { className: styles$l['fill-primary-500'], d: "M40.5003 0.52832C34.2609 0.52832 27.9875 2.90796 23.2303 7.66515C19.6924 11.203 17.5477 15.5917 16.6382 20.1682C7.40644 21.9591 0.40332 30.0216 0.40332 39.7537C0.40332 50.7951 9.41033 59.8022 20.4518 59.8022H51.4253C51.7718 59.8071 52.1159 59.7431 52.4374 59.6139C52.759 59.4846 53.0517 59.2928 53.2985 59.0495C53.5452 58.8062 53.7412 58.5163 53.8749 58.1965C54.0087 57.8768 54.0776 57.5337 54.0776 57.1872C54.0776 56.8406 54.0087 56.4975 53.8749 56.1778C53.7412 55.8581 53.5452 55.5682 53.2985 55.3249C53.0517 55.0816 52.759 54.8897 52.4374 54.7605C52.1159 54.6313 51.7718 54.5673 51.4253 54.5722H20.4518C12.237 54.5722 5.63336 47.9686 5.63336 39.7537C5.63336 31.9959 11.5333 25.6757 19.0898 24.9897C19.6825 24.9319 20.2376 24.6737 20.6636 24.2577C21.0895 23.8416 21.3608 23.2926 21.4325 22.7015C21.9136 18.5566 23.7477 14.5297 26.9349 11.3425C30.688 7.58956 35.5857 5.75836 40.5003 5.75836C45.415 5.75836 50.2818 7.58568 54.0385 11.3425C58.3797 15.6837 60.2168 21.5819 59.541 27.2233C59.4947 27.5909 59.5271 27.964 59.6359 28.3181C59.7447 28.6722 59.9274 28.9991 60.1721 29.2773C60.4168 29.5554 60.7177 29.7784 61.055 29.9315C61.3923 30.0845 61.7583 30.1642 62.1287 30.1652H63.1639C69.9698 30.1652 75.3673 35.5627 75.3673 42.3687C75.3673 49.1747 69.9698 54.5722 63.1639 54.5722H50.9604C50.6139 54.5673 50.2699 54.6313 49.9483 54.7605C49.6267 54.8897 49.334 55.0816 49.0873 55.3249C48.8405 55.5682 48.6445 55.8581 48.5108 56.1778C48.377 56.4975 48.3081 56.8406 48.3081 57.1872C48.3081 57.5337 48.377 57.8768 48.5108 58.1965C48.6445 58.5163 48.8405 58.8062 49.0873 59.0495C49.334 59.2928 49.6267 59.4846 49.9483 59.6139C50.2699 59.7431 50.6139 59.8071 50.9604 59.8022H63.1639C72.7768 59.8022 80.5973 51.9816 80.5973 42.3687C80.5973 33.2962 73.6081 25.9105 64.7438 25.0986C64.7847 18.7886 62.5435 12.4655 57.7431 7.66515C52.99 2.91184 46.7398 0.52832 40.5003 0.52832ZM40.5003 48.1024C39.6285 48.1024 39.1674 47.8218 38.7298 47.4214L29.1414 38.7047C28.0342 37.6771 28.0536 36.0095 28.9778 35C29.9022 33.9906 31.6684 33.9175 32.6825 34.8366L37.8853 39.5763V22.0877C37.8853 20.6435 39.0559 19.4727 40.5003 19.4727C41.9449 19.4727 43.1153 20.6435 43.1153 22.0877V39.5763L48.3182 34.8366C49.3324 33.9175 51.0451 34.0421 52.0228 35C53.053 36.0095 52.8643 37.7756 51.8593 38.7047L42.2709 47.4214C41.7528 47.8957 41.3722 48.1024 40.5003 48.1024Z" }, void 0) }), void 0)); });
|
|
8678
8667
|
|
|
8679
8668
|
var css_248z$l = ".style-module_container__3JjNt {\n position: relative;\n display: flex;\n justify-content: center;\n}\n\n.style-module_button__V6Lgi {\n background-color: transparent;\n border: none;\n cursor: pointer;\n}\n\n.style-module_button__V6Lgi:hover .style-module_inner-circle-hover__SLIPe {\n animation: style-module_borderBlink__39PO3 1.3s ease-in-out infinite;\n}\n\n.style-module_button__V6Lgi:focus {\n outline: none;\n}\n\ncircle {\n transition: stroke-dashoffset 0.35s;\n transform: rotate(-90deg);\n transform-origin: 50% 50%;\n position: absolute;\n}\n\n.style-module_overlay-circle__2Q8LI {\n z-index: 1;\n stroke: var(--ds-primary-500);\n fill: transparent;\n}\n\n.style-module_overlay-circle-completed__1C1xp {\n z-index: 1;\n stroke: #90df9b;\n fill: rgba(144, 223, 155, 0.1);\n}\n\n.style-module_inner-circle__2MySo {\n z-index: 0;\n stroke: var(--ds-primary-100);\n fill: transparent;\n}\n\n.style-module_text-container__2Rn84 {\n position: absolute;\n top: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n}\n\n@keyframes style-module_borderBlink__39PO3 {\n from, to {\n stroke: var(--ds-primary-100);\n }\n 50% {\n stroke: var(--ds-primary-500);\n }\n}";
|
|
8680
8669
|
var styles$k = {"container":"style-module_container__3JjNt","button":"style-module_button__V6Lgi","inner-circle-hover":"style-module_inner-circle-hover__SLIPe","borderBlink":"style-module_borderBlink__39PO3","overlay-circle":"style-module_overlay-circle__2Q8LI","overlay-circle-completed":"style-module_overlay-circle-completed__1C1xp","inner-circle":"style-module_inner-circle__2MySo","text-container":"style-module_text-container__2Rn84"};
|
|
@@ -8695,14 +8684,14 @@ var index$7 = (function (_a) {
|
|
|
8695
8684
|
var normalizedRadius = RADIUS - STROKE * 2;
|
|
8696
8685
|
var circumference = normalizedRadius * 2 * Math.PI;
|
|
8697
8686
|
var strokeDashoffset = circumference - (progress / 100) * circumference;
|
|
8698
|
-
return (
|
|
8687
|
+
return (jsx("div", __assign({ className: "w100 " + styles$k.container }, { children: jsxs("button", __assign({ className: styles$k.button, type: "button", onClick: handleClick, "data-cy": "download-documents-button" }, { children: [jsxs("svg", __assign({ height: RADIUS * 2, width: RADIUS * 2 }, { children: [jsx("circle", { className: classNames("" + styles$k['inner-circle'], (_b = {},
|
|
8699
8688
|
_b[styles$k['inner-circle-hover']] = progress === 0,
|
|
8700
8689
|
_b)), strokeWidth: STROKE, strokeDasharray: circumference + ' ' + circumference, r: normalizedRadius, cx: RADIUS, cy: RADIUS }, void 0),
|
|
8701
|
-
|
|
8690
|
+
jsx("circle", { className: status === 'COMPLETED'
|
|
8702
8691
|
? styles$k['overlay-circle-completed']
|
|
8703
8692
|
: styles$k['overlay-circle'], strokeWidth: STROKE, strokeDasharray: circumference + ' ' + circumference, style: { strokeDashoffset: strokeDashoffset }, r: normalizedRadius, cx: RADIUS, cy: RADIUS }, void 0)] }), void 0),
|
|
8704
|
-
|
|
8705
|
-
|
|
8693
|
+
jsxs("div", __assign({ className: "ws2 " + styles$k['text-container'] }, { children: [status === 'COMPLETED' ? (jsx(CheckOutsideCircleIcon, {}, void 0)) : (jsx(DownloadCloudIcon, {}, void 0)),
|
|
8694
|
+
jsx("div", __assign({ className: "p-p mt8" }, { children: mappingStatus[status] }), void 0)] }), void 0)] }), void 0) }), void 0));
|
|
8706
8695
|
});
|
|
8707
8696
|
|
|
8708
8697
|
var css_248z$k = ".styles-module_content-container__4wuQ0 {\n display: flex;\n justify-content: center;\n align-items: center;\n}";
|
|
@@ -8715,12 +8704,12 @@ var buttonTypeClassNameMap = {
|
|
|
8715
8704
|
outline: 'p-btn--outline',
|
|
8716
8705
|
outlineGrey: 'p-btn--outline-grey',
|
|
8717
8706
|
};
|
|
8718
|
-
var Button = require$$
|
|
8707
|
+
var Button = require$$0.forwardRef(function (_a, ref) {
|
|
8719
8708
|
var className = _a.className, _b = _a.loading, loading = _b === void 0 ? false : _b, buttonTitle = _a.buttonTitle, _c = _a.buttonType, buttonType = _c === void 0 ? 'primary' : _c, leftIcon = _a.leftIcon; _a.type; var props = __rest$1(_a, ["className", "loading", "buttonTitle", "buttonType", "leftIcon", "type"]);
|
|
8720
8709
|
var buttonClassName = buttonTypeClassNameMap[buttonType];
|
|
8721
8710
|
var loadingClassName = loading ? 'p-btn--loading' : '';
|
|
8722
|
-
return (
|
|
8723
|
-
|
|
8711
|
+
return (jsx("button", __assign({ ref: ref, className: buttonClassName + " " + loadingClassName + " " + (className !== null && className !== void 0 ? className : '') }, props, { children: leftIcon ? (jsxs("div", __assign({ className: styles$j['content-container'] }, { children: [jsx("img", { width: "20px", height: "20px", className: "mr8", src: leftIcon.src, alt: leftIcon.alt }, void 0),
|
|
8712
|
+
jsx("div", { children: buttonTitle }, void 0)] }), void 0)) : (jsx(Fragment$1, { children: buttonTitle }, void 0)) }), void 0));
|
|
8724
8713
|
});
|
|
8725
8714
|
|
|
8726
8715
|
var checkIcon = "data:image/svg+xml,%3Csvg%20width%3D%2220%22%20height%3D%2220%22%20viewBox%3D%220%200%2020%2020%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M16.6666%205.83203L7.49992%2014.9987L3.33325%2010.832%22%20stroke%3D%22%23B4B4BA%22%20stroke-width%3D%222%22%20stroke-linecap%3D%22round%22%20stroke-linejoin%3D%22round%22%2F%3E%3C%2Fsvg%3E";
|
|
@@ -8733,22 +8722,22 @@ styleInject(css_248z$j);
|
|
|
8733
8722
|
|
|
8734
8723
|
var InitialButton = function (_a) {
|
|
8735
8724
|
var onDownload = _a.onDownload;
|
|
8736
|
-
return (
|
|
8725
|
+
return (jsx(Button, { className: "w100 " + styles$i.button, buttonTitle: "Download", leftIcon: { src: downloadIcon, alt: 'download arrow icon' }, onClick: onDownload, "data-cy": "download-documents-button" }, void 0));
|
|
8737
8726
|
};
|
|
8738
8727
|
// TODO: Allow setting loading to true to display text
|
|
8739
|
-
var GeneratingButton = function () { return (
|
|
8740
|
-
var CompletedChip = function () { return (
|
|
8741
|
-
|
|
8728
|
+
var GeneratingButton = function () { return (jsx(Button, { className: "w100 " + styles$i.button, buttonTitle: "Generating", loading: true }, void 0)); };
|
|
8729
|
+
var CompletedChip = function () { return (jsxs("div", __assign({ className: styles$i['chip-complete'] }, { children: [jsx("img", { src: checkIcon, alt: "grey check" }, void 0),
|
|
8730
|
+
jsx("div", __assign({ className: "p-h4 tc-grey-500 ml8" }, { children: "Download complete" }), void 0)] }), void 0)); };
|
|
8742
8731
|
var DownloadButton = function (_a) {
|
|
8743
8732
|
var downloadStatus = _a.downloadStatus, onDownload = _a.onDownload, _b = _a.className, className = _b === void 0 ? '' : _b, customFail = _a.customFail;
|
|
8744
8733
|
var mapDownloadButton = {
|
|
8745
|
-
INITIAL:
|
|
8746
|
-
GENERATING:
|
|
8747
|
-
COMPLETED:
|
|
8748
|
-
FAILED:
|
|
8734
|
+
INITIAL: jsx(InitialButton, { onDownload: onDownload }, void 0),
|
|
8735
|
+
GENERATING: jsx(GeneratingButton, {}, void 0),
|
|
8736
|
+
COMPLETED: jsx(CompletedChip, {}, void 0),
|
|
8737
|
+
FAILED: jsx(InitialButton, { onDownload: onDownload }, void 0),
|
|
8749
8738
|
};
|
|
8750
|
-
return (
|
|
8751
|
-
downloadStatus === 'FAILED' && (
|
|
8739
|
+
return (jsxs("div", __assign({ className: "d-flex fd-column ai-center " + className }, { children: [jsx("div", __assign({ className: "ws4" }, { children: mapDownloadButton[downloadStatus] }), void 0),
|
|
8740
|
+
downloadStatus === 'FAILED' && (jsx("div", __assign({ className: "p-notice p-notice--danger p-p mt40 wmx5" }, { children: customFail !== null && customFail !== void 0 ? customFail : 'An error occured when generating documents. Please try again or contact us.' }), void 0))] }), void 0));
|
|
8752
8741
|
};
|
|
8753
8742
|
|
|
8754
8743
|
var IBAN_CHAR_LIMIT = 4;
|
|
@@ -8771,7 +8760,7 @@ var formatIban = function (iban) {
|
|
|
8771
8760
|
|
|
8772
8761
|
var IbanInput = function (_a) {
|
|
8773
8762
|
var value = _a.value, onChange = _a.onChange, props = __rest$1(_a, ["value", "onChange"]);
|
|
8774
|
-
return (
|
|
8763
|
+
return (jsx(Input, __assign({ value: formatIban(value), onChange: function (e) { return onChange(formatIban(e.target.value)); } }, props), void 0));
|
|
8775
8764
|
};
|
|
8776
8765
|
|
|
8777
8766
|
var formatInput = function (input) {
|
|
@@ -8791,7 +8780,7 @@ function reverseFormatInput(input) {
|
|
|
8791
8780
|
|
|
8792
8781
|
var CurrencyInput = function (_a) {
|
|
8793
8782
|
var value = _a.value, onChange = _a.onChange; _a.type; var props = __rest$1(_a, ["value", "onChange", "type"]);
|
|
8794
|
-
var _b =
|
|
8783
|
+
var _b = useState(''), shadowValue = _b[0], setShadowValue = _b[1];
|
|
8795
8784
|
var formattedShadowValue = formatInput(shadowValue
|
|
8796
8785
|
.replace(/ /g, '') // remove all whitespace
|
|
8797
8786
|
.replace(',', '.') // change commas to dot for decimal separator
|
|
@@ -8800,17 +8789,17 @@ var CurrencyInput = function (_a) {
|
|
|
8800
8789
|
.replace('DECIMAL_SEPARATOR', '.') // End of the Gymnastic 🤸
|
|
8801
8790
|
.replace(/[^\d\\.]/g, '') // remove all non decimal and dot
|
|
8802
8791
|
);
|
|
8803
|
-
|
|
8792
|
+
useEffect(function () {
|
|
8804
8793
|
if (value && value !== reverseFormatInput(shadowValue)) {
|
|
8805
8794
|
setShadowValue(formatInput(value.toString()));
|
|
8806
8795
|
}
|
|
8807
8796
|
// eslint-disable-next-line
|
|
8808
8797
|
}, [value]);
|
|
8809
|
-
|
|
8798
|
+
useEffect(function () {
|
|
8810
8799
|
onChange === null || onChange === void 0 ? void 0 : onChange(reverseFormatInput(shadowValue));
|
|
8811
8800
|
// eslint-disable-next-line
|
|
8812
8801
|
}, [shadowValue]);
|
|
8813
|
-
return (
|
|
8802
|
+
return (jsx(Input, __assign({ prefix: "\u20AC", type: "string", value: formattedShadowValue, onChange: function (e) {
|
|
8814
8803
|
setShadowValue(e.target.value);
|
|
8815
8804
|
} }, props), void 0));
|
|
8816
8805
|
};
|
|
@@ -8822,15 +8811,15 @@ styleInject(css_248z$i);
|
|
|
8822
8811
|
var imageClose$1 = "data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M18%206L6%2018%22%20stroke%3D%22%2326262E%22%20strokeWidth%3D%222%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M6%206L18%2018%22%20stroke%3D%22%2326262E%22%20strokeWidth%3D%222%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%2F%3E%3C%2Fsvg%3E";
|
|
8823
8812
|
|
|
8824
8813
|
var useOnClose = function (onClose, isOpen, dismissable) {
|
|
8825
|
-
var _a =
|
|
8826
|
-
var handleOnClose =
|
|
8814
|
+
var _a = useState(false), isClosing = _a[0], setIsClosing = _a[1];
|
|
8815
|
+
var handleOnClose = useCallback(function () {
|
|
8827
8816
|
setIsClosing(true);
|
|
8828
8817
|
setTimeout(function () {
|
|
8829
8818
|
onClose();
|
|
8830
8819
|
setIsClosing(false);
|
|
8831
8820
|
}, 300);
|
|
8832
8821
|
}, [setIsClosing, onClose]);
|
|
8833
|
-
var handleEscKey =
|
|
8822
|
+
var handleEscKey = useCallback(function (e) {
|
|
8834
8823
|
if (e.code !== 'Escape')
|
|
8835
8824
|
return;
|
|
8836
8825
|
if (!dismissable)
|
|
@@ -8839,13 +8828,13 @@ var useOnClose = function (onClose, isOpen, dismissable) {
|
|
|
8839
8828
|
return null;
|
|
8840
8829
|
handleOnClose();
|
|
8841
8830
|
}, [isOpen, dismissable, handleOnClose]);
|
|
8842
|
-
|
|
8831
|
+
useEffect(function () {
|
|
8843
8832
|
window.addEventListener('keydown', handleEscKey);
|
|
8844
8833
|
return function () {
|
|
8845
8834
|
window.removeEventListener('keydown', handleEscKey);
|
|
8846
8835
|
};
|
|
8847
8836
|
}, [handleEscKey]);
|
|
8848
|
-
|
|
8837
|
+
useEffect(function () {
|
|
8849
8838
|
document.body.style.overflow = isOpen ? 'hidden' : 'auto';
|
|
8850
8839
|
return function () {
|
|
8851
8840
|
document.body.style.overflow = 'auto';
|
|
@@ -8859,19 +8848,19 @@ var useOnClose = function (onClose, isOpen, dismissable) {
|
|
|
8859
8848
|
|
|
8860
8849
|
var BottomModal = (function (_a) {
|
|
8861
8850
|
var title = _a.title, isOpen = _a.isOpen, children = _a.children, onClose = _a.onClose, _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.dismissible, dismissible = _c === void 0 ? true : _c;
|
|
8862
|
-
var _d =
|
|
8851
|
+
var _d = useState(0), containerXOffset = _d[0], setContainerXOffset = _d[1];
|
|
8863
8852
|
var _e = useOnClose(onClose, isOpen, dismissible), isClosing = _e.isClosing, handleContainerClick = _e.handleContainerClick, handleOnClose = _e.handleOnClose;
|
|
8864
|
-
var containerRef =
|
|
8853
|
+
var containerRef = useCallback(function (node) {
|
|
8865
8854
|
if (node !== null) {
|
|
8866
8855
|
setContainerXOffset(Math.max(window.innerHeight * 0.1, window.innerHeight - node.getBoundingClientRect().height));
|
|
8867
8856
|
}
|
|
8868
8857
|
}, []);
|
|
8869
8858
|
if (!isOpen) {
|
|
8870
|
-
return
|
|
8859
|
+
return jsx(Fragment$1, {}, void 0);
|
|
8871
8860
|
}
|
|
8872
|
-
return (
|
|
8873
|
-
dismissible && (
|
|
8874
|
-
|
|
8861
|
+
return (jsx("div", __assign({ className: isClosing ? styles$h['overlay--close'] : styles$h.overlay, onClick: handleOnClose }, { children: jsxs("div", __assign({ className: (isClosing ? styles$h['container--close'] : styles$h.container) + " " + className, ref: containerRef, style: { top: containerXOffset + "px" }, onClick: handleContainerClick }, { children: [jsxs("div", __assign({ className: styles$h.header }, { children: [jsx("div", __assign({ className: "p-h4 " + styles$h.title }, { children: title }), void 0),
|
|
8862
|
+
dismissible && (jsx("button", __assign({ type: "button", className: styles$h.close, onClick: handleOnClose }, { children: jsx("img", { src: imageClose$1, alt: "Close" }, void 0) }), void 0))] }), void 0),
|
|
8863
|
+
jsx("div", __assign({ className: styles$h.content }, { children: children }), void 0)] }), void 0) }), void 0));
|
|
8875
8864
|
});
|
|
8876
8865
|
|
|
8877
8866
|
var css_248z$h = "@keyframes style-module_fade-in__nLzzO {\n 0% {\n background-color: rgba(0, 0, 0, 0);\n visibility: hidden;\n }\n 100% {\n background-color: rgba(0, 0, 0, 0.3);\n visibility: visible;\n }\n}\n@keyframes style-module_fade-out__IuSV7 {\n from {\n background-color: rgba(0, 0, 0, 0.3);\n visibility: visible;\n }\n to {\n background-color: rgba(0, 0, 0, 0);\n visibility: hidden;\n }\n}\n@keyframes style-module_appear-in__2ZMqz {\n 0% {\n transform: translateY(24px) translateX(-50%);\n opacity: 0;\n visibility: hidden;\n }\n 100% {\n transform: translateY(0) translateX(-50%);\n opacity: 1;\n visibility: visible;\n }\n}\n@keyframes style-module_disappear-out__38TSV {\n 0% {\n transform: translateY(0) translateX(-50%);\n opacity: 1;\n visibility: visible;\n }\n 100% {\n transform: translateY(24px) translateX(-50%);\n opacity: 0;\n visibility: hidden;\n }\n}\n.style-module_overlay__1Zbce, .style-module_overlay--close__2dytn {\n position: fixed;\n z-index: 100;\n overflow: auto;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n animation: style-module_fade-in__nLzzO 0.3s both;\n}\n.style-module_overlay--close__2dytn {\n animation-delay: 0.1s;\n animation: style-module_fade-out__IuSV7 0.3s both;\n}\n\n.style-module_container__1XZj_, .style-module_container--close__3UYsJ {\n position: relative;\n background-color: white;\n border-radius: 8px;\n max-width: 592px;\n width: fit-content;\n width: -moz-fit-content;\n animation-name: style-module_appear-in__2ZMqz;\n animation-duration: 0.4s;\n animation-fill-mode: both;\n animation-timing-function: ease-out;\n top: calc(100vh / 2 - 50% / 2);\n left: 50%;\n transform: translateX(-50%);\n margin-bottom: 80px;\n}\n.style-module_container--close__3UYsJ {\n animation-name: style-module_disappear-out__38TSV;\n animation-duration: 0.4s;\n animation-delay: 0s;\n animation-fill-mode: both;\n animation-timing-function: ease-out;\n}\n\n.style-module_header__2oEKp {\n display: flex;\n justify-content: space-between;\n align-items: center;\n padding: 24px 24px 0 24px;\n}\n\n.style-module_close__p3Axi {\n border: none;\n background-color: transparent;\n cursor: pointer;\n}";
|
|
@@ -8884,10 +8873,10 @@ var RegularModal = (function (_a) {
|
|
|
8884
8873
|
var title = _a.title, isOpen = _a.isOpen, children = _a.children, onClose = _a.onClose, _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.dismissible, dismissible = _c === void 0 ? true : _c;
|
|
8885
8874
|
var _d = useOnClose(onClose, isOpen, dismissible), isClosing = _d.isClosing, handleContainerClick = _d.handleContainerClick, handleOnClose = _d.handleOnClose;
|
|
8886
8875
|
if (!isOpen) {
|
|
8887
|
-
return
|
|
8876
|
+
return jsx(Fragment$1, {}, void 0);
|
|
8888
8877
|
}
|
|
8889
|
-
return (
|
|
8890
|
-
dismissible && (
|
|
8878
|
+
return (jsx("div", __assign({ className: isClosing ? styles$g['overlay--close'] : styles$g.overlay, onClick: handleOnClose }, { children: jsxs("div", __assign({ className: (isClosing ? styles$g['container--close'] : styles$g.container) + " " + className, onClick: handleContainerClick }, { children: [jsxs("div", __assign({ className: styles$g.header }, { children: [jsx("div", __assign({ className: "p-h2 " + styles$g.title }, { children: title }), void 0),
|
|
8879
|
+
dismissible && (jsx("button", __assign({ type: "button", className: styles$g.close, onClick: handleOnClose }, { children: jsx("img", { src: imageClose, alt: "Close" }, void 0) }), void 0))] }), void 0), children] }), void 0) }), void 0));
|
|
8891
8880
|
});
|
|
8892
8881
|
|
|
8893
8882
|
var css_248z$g = "@media (min-width: 34rem) {\n .style-module_mobile__3k175 {\n display: none;\n }\n}\n@media (max-width: 34rem) {\n .style-module_mobile__3k175 {\n display: block !important;\n }\n}\n\n@media (max-width: 34rem) {\n .style-module_desktop__2lclr {\n display: none;\n }\n}";
|
|
@@ -8896,23 +8885,23 @@ styleInject(css_248z$g);
|
|
|
8896
8885
|
|
|
8897
8886
|
var index$6 = (function (_a) {
|
|
8898
8887
|
var isOpen = _a.isOpen, props = __rest$1(_a, ["isOpen"]);
|
|
8899
|
-
var mobileRef =
|
|
8900
|
-
var _b =
|
|
8888
|
+
var mobileRef = useRef(null);
|
|
8889
|
+
var _b = useState('desktop'), visibleSize = _b[0], setVisibleSize = _b[1];
|
|
8901
8890
|
var handleResize = function () {
|
|
8902
8891
|
setVisibleSize(mobileRef.current !== null &&
|
|
8903
8892
|
window.getComputedStyle(mobileRef.current).display !== 'none'
|
|
8904
8893
|
? 'mobile'
|
|
8905
8894
|
: 'desktop');
|
|
8906
8895
|
};
|
|
8907
|
-
|
|
8896
|
+
useEffect(function () {
|
|
8908
8897
|
window.addEventListener('resize', handleResize);
|
|
8909
8898
|
handleResize();
|
|
8910
8899
|
return function () {
|
|
8911
8900
|
window.removeEventListener('resize', handleResize);
|
|
8912
8901
|
};
|
|
8913
8902
|
}, []);
|
|
8914
|
-
return (
|
|
8915
|
-
visibleSize === 'desktop' && (
|
|
8903
|
+
return (jsxs(Fragment$1, { children: [jsx("div", __assign({ className: styles$f.mobile, ref: mobileRef }, { children: visibleSize === 'mobile' && jsx(BottomModal, __assign({}, props, { isOpen: isOpen }), void 0) }), void 0),
|
|
8904
|
+
visibleSize === 'desktop' && (jsx("div", __assign({ className: styles$f.desktop }, { children: jsx(RegularModal, __assign({}, props, { isOpen: isOpen }), void 0) }), void 0))] }, void 0));
|
|
8916
8905
|
});
|
|
8917
8906
|
|
|
8918
8907
|
var arrowRightImage = "data:image/svg+xml,%3Csvg%20width%3D%2224%22%20height%3D%2224%22%20viewBox%3D%220%200%2024%2024%22%20fill%3D%22none%22%20xmlns%3D%22http%3A%2F%2Fwww.w3.org%2F2000%2Fsvg%22%3E%3Cpath%20d%3D%22M5%2012H19%22%20stroke%3D%22%238E8CEE%22%20strokeWidth%3D%222%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%2F%3E%3Cpath%20d%3D%22M12%205L19%2012L12%2019%22%20stroke%3D%22%238E8CEE%22%20strokeWidth%3D%222%22%20strokeLinecap%3D%22round%22%20strokeLinejoin%3D%22round%22%2F%3E%3C%2Fsvg%3E";
|
|
@@ -8959,10 +8948,10 @@ var index$5 = (function (_a) {
|
|
|
8959
8948
|
var headingStyle = headingForCardSize(cardSize);
|
|
8960
8949
|
var iconStyle = styles$e['right-icon'];
|
|
8961
8950
|
var cardTextStyle = "p-p tc-grey-600 " + (cardSize === 'xsmall' ? styles$e.indent : 'mt16');
|
|
8962
|
-
return (
|
|
8963
|
-
|
|
8964
|
-
rightIcon && (
|
|
8965
|
-
|
|
8951
|
+
return (jsxs("div", __assign({ className: cardStyle }, props, { children: [jsxs("div", __assign({ className: titleContainerStyle }, { children: [leftIcon && (jsx("img", { className: "mr8", width: "28px", height: "28px", src: leftIcon === 'logo' ? featherLogo.src : leftIcon.src, alt: leftIcon === 'logo' ? featherLogo.alt : leftIcon.src }, void 0)),
|
|
8952
|
+
jsx("div", __assign({ className: headingStyle }, { children: title }), void 0),
|
|
8953
|
+
rightIcon && (jsx("img", { className: iconStyle, width: "24px", height: "24px", src: rightIcon === 'arrow' ? arrowRight.src : rightIcon.src, alt: rightIcon === 'arrow' ? arrowRight.alt : rightIcon.alt }, void 0))] }), void 0),
|
|
8954
|
+
jsx("p", __assign({ className: cardTextStyle }, { children: children }), void 0)] }), void 0));
|
|
8966
8955
|
});
|
|
8967
8956
|
|
|
8968
8957
|
var css_248z$e = ".style-module_container__384bg {\n padding: 24px 24px 24px 32px;\n}\n.style-module_container--small__35EZ1 {\n padding: 16px 24px 16px 32px;\n}\n.style-module_container--xsmall__2DDsN {\n padding: 16px 16px 16px 24px;\n}\n\n.style-module_card-text--small__1L_Fe {\n margin-top: 2px;\n}\n\n.style-module_card-text--medium__qoKv2 {\n margin-top: 4px;\n}\n\n.style-module_card-text--big__mMB2v {\n margin-top: 6px;\n}";
|
|
@@ -8996,10 +8985,10 @@ var index$4 = (function (_a) {
|
|
|
8996
8985
|
var headingStyle = headingForCardSize(cardSize);
|
|
8997
8986
|
var iconStyle = cardSize === 'xsmall' ? 'mr16' : 'mr32';
|
|
8998
8987
|
var cardTextStyle = "tc-grey-600 " + (cardSize === 'xsmall' ? 'p-p--small' : 'p-p ') + " " + styles$d[cardTextStyleFromCardSize(cardSize)];
|
|
8999
|
-
return (
|
|
9000
|
-
|
|
9001
|
-
rightIcon && (
|
|
9002
|
-
|
|
8988
|
+
return (jsxs("div", __assign({ className: cardStyle }, props, { children: [leftIcon && (jsx("img", { width: "48px", height: "48px", className: iconStyle, src: leftIcon.src, alt: leftIcon.alt }, void 0)),
|
|
8989
|
+
jsxs("div", { children: [jsxs("div", __assign({ className: "d-flex" }, { children: [jsx("div", __assign({ className: headingStyle }, { children: title }), void 0),
|
|
8990
|
+
rightIcon && (jsx("img", { className: "ml-auto", width: "24px", height: "24px", src: rightIcon === 'arrow' ? arrowRight.src : rightIcon.src, alt: rightIcon === 'arrow' ? arrowRight.alt : rightIcon.alt }, void 0))] }), void 0),
|
|
8991
|
+
jsx("p", __assign({ className: cardTextStyle }, { children: children }), void 0)] }, void 0)] }), void 0));
|
|
9003
8992
|
});
|
|
9004
8993
|
|
|
9005
8994
|
var css_248z$d = ".style-module_container__34kUF {\n padding: 32px 24px 24px 24px;\n display: flex;\n flex-direction: column;\n align-items: center;\n}\n\n.style-module_right-icon__3_kH9 {\n margin-left: 4px;\n}";
|
|
@@ -9011,9 +9000,9 @@ var index$3 = (function (_a) {
|
|
|
9011
9000
|
var cardStyle = "d-flex fd-column ai-center " + className + " " + associatedClassForCardState(state, dropshadow) + " " + styles$c.container;
|
|
9012
9001
|
var headingStyle = headingForCardSize(cardSize);
|
|
9013
9002
|
var iconStyle = styles$c['right-icon'];
|
|
9014
|
-
return (
|
|
9015
|
-
|
|
9016
|
-
rightIcon && (
|
|
9003
|
+
return (jsx(Fragment$1, { children: jsxs("div", __assign({ className: cardStyle }, props, { children: [jsx("img", { width: topIconSize.width, height: topIconSize.height, alt: topIcon.alt, src: topIcon.src }, void 0),
|
|
9004
|
+
jsxs("div", __assign({ className: "d-flex mt16" }, { children: [jsx("div", __assign({ className: headingStyle }, { children: title }), void 0),
|
|
9005
|
+
rightIcon && (jsx("img", { className: iconStyle, width: "24px", height: "24px", src: rightIcon === 'arrow' ? arrowRight.src : rightIcon.src, alt: rightIcon === 'arrow' ? arrowRight.alt : rightIcon.alt }, void 0))] }), void 0), children] }), void 0) }, void 0));
|
|
9017
9006
|
});
|
|
9018
9007
|
|
|
9019
9008
|
var css_248z$c = "@keyframes style-module_appear-in__23V7k {\n from {\n opacity: 0;\n }\n to {\n opacity: 1;\n }\n}\n.style-module_root-container__3r_b9 {\n position: relative;\n padding-top: 40px;\n}\n.style-module_root-container__3r_b9:hover .style-module_right-icon__L6sf3 {\n visibility: visible;\n animation-name: style-module_appear-in__23V7k;\n animation-duration: 0.3s;\n animation-fill-mode: both;\n}\n\n.style-module_top-icon__10CJ3 {\n position: absolute;\n left: 50%;\n transform: translateX(-50%) translateY(-40px);\n}\n.style-module_top-icon--muted__3PZ1X {\n opacity: 0.25;\n}\n\n.style-module_right-icon__L6sf3 {\n visibility: hidden;\n position: absolute;\n top: 64px;\n right: 24px;\n}\n\n.style-module_container__19mu2 {\n padding: 0 24px 24px 24px;\n height: 100%;\n}\n@media (max-width: 34rem) {\n .style-module_container__19mu2 {\n height: fit-content;\n }\n}";
|
|
@@ -9022,10 +9011,10 @@ styleInject(css_248z$c);
|
|
|
9022
9011
|
|
|
9023
9012
|
var index$2 = (function (_a) {
|
|
9024
9013
|
var className = _a.className, title = _a.title, children = _a.children, topIcon = _a.topIcon, rightIcon = _a.rightIcon, _b = _a.state, state = _b === void 0 ? 'actionable' : _b, _c = _a.dropshadow, dropshadow = _c === void 0 ? true : _c, props = __rest$1(_a, ["className", "title", "children", "topIcon", "rightIcon", "state", "dropshadow"]);
|
|
9025
|
-
return (
|
|
9026
|
-
|
|
9027
|
-
|
|
9028
|
-
|
|
9014
|
+
return (jsxs("div", __assign({ className: styles$b['root-container'] + " " + (className !== null && className !== void 0 ? className : '') }, props, { children: [jsx("img", { src: topIcon.src, alt: topIcon.alt, className: styles$b['top-icon'] + " " + (state === 'muted' ? styles$b['top-icon--muted'] : '') + " ", width: "80px", height: "80px" }, void 0),
|
|
9015
|
+
jsxs("div", __assign({ className: associatedClassForCardState(state, dropshadow) + " " + styles$b.container }, { children: [rightIcon && (jsx("img", { width: "20px", height: "20px", className: styles$b['right-icon'], src: rightIcon === 'info' ? info.src : rightIcon.src, alt: rightIcon === 'info' ? info.alt : rightIcon.alt }, void 0)),
|
|
9016
|
+
jsx("div", __assign({ className: "p-h4 ta-center mt64" }, { children: title }), void 0),
|
|
9017
|
+
jsx("p", __assign({ className: "p-p mt16 tc-grey-600" }, { children: children }), void 0)] }), void 0)] }), void 0));
|
|
9029
9018
|
});
|
|
9030
9019
|
|
|
9031
9020
|
var css_248z$b = ".style-module_container__2tJCE {\n background-color: white;\n padding: 8px 16px;\n box-shadow: 0px 2px 20px rgba(97, 96, 162, 0.07);\n border-radius: 8px;\n border: 2px solid white;\n transition: border 0.2s ease-in-out;\n display: flex;\n justify-content: space-between;\n align-items: center;\n text-decoration: none;\n}\n.style-module_container__2tJCE:hover {\n border: 2px solid #b1b0f5;\n}\n.style-module_container__2tJCE[disabled] {\n pointer-events: none;\n opacity: 0.25;\n}\n.style-module_container__2tJCE:focus {\n border: 2px solid #8e8cee;\n}";
|
|
@@ -9034,14 +9023,14 @@ styleInject(css_248z$b);
|
|
|
9034
9023
|
|
|
9035
9024
|
var CardContent = function (_a) {
|
|
9036
9025
|
var title = _a.title, description = _a.description;
|
|
9037
|
-
return (
|
|
9038
|
-
typeof description === 'string' ? (
|
|
9039
|
-
|
|
9026
|
+
return (jsxs(Fragment$1, { children: [jsxs("div", { children: [jsx("div", __assign({ className: "p-p--small" }, { children: title }), void 0),
|
|
9027
|
+
typeof description === 'string' ? (jsx("div", __assign({ className: "tc-primary-500 p-p" }, { children: description }), void 0)) : (description)] }, void 0),
|
|
9028
|
+
jsx("img", __assign({}, chevronRight, { alt: "Expander icon" }), void 0)] }, void 0));
|
|
9040
9029
|
};
|
|
9041
9030
|
var CardButton = function (_a) {
|
|
9042
9031
|
var title = _a.title, description = _a.description, _b = _a.disabled, disabled = _b === void 0 ? false : _b, onClick = _a.onClick, href = _a.href, className = _a.className;
|
|
9043
9032
|
var component = href ? 'a' : 'button';
|
|
9044
|
-
return (
|
|
9033
|
+
return (jsx(Fragment$1, { children: createElement(component, __assign({ className: "c-pointer ta-left w100 " + styles$a.container + " " + (className !== null && className !== void 0 ? className : '') + "\n ", children: jsx(CardContent, { title: title, description: description }, void 0), disabled: disabled }, (component === 'a' ? { href: href } : { onClick: onClick }))) }, void 0));
|
|
9045
9034
|
};
|
|
9046
9035
|
|
|
9047
9036
|
var headingForCardSize = function (cardSize) {
|
|
@@ -9082,10 +9071,10 @@ var removeButtonHighlightedIcon = "data:image/svg+xml,%3Csvg%20width%3D%2216%22%
|
|
|
9082
9071
|
|
|
9083
9072
|
var Chip = (function (_a) {
|
|
9084
9073
|
var value = _a.value, onRemove = _a.onRemove;
|
|
9085
|
-
return (
|
|
9086
|
-
|
|
9087
|
-
|
|
9088
|
-
|
|
9074
|
+
return (jsxs("div", __assign({ className: "p-p mr8 mb8 d-flex " + styles$9['chip'] }, { children: [value.leftIcon && (jsx("img", { className: "mr8 " + styles$9['chip-image'], src: value.leftIcon, alt: value.value }, void 0)),
|
|
9075
|
+
jsx("div", __assign({ className: "mr8" }, { children: value.value }), void 0),
|
|
9076
|
+
jsxs("div", __assign({ className: "c-pointer " + styles$9['chip-button-container'], onClick: function () { return onRemove(value); } }, { children: [jsx("img", { className: styles$9['chip-remove-button-highlighted'], src: removeButtonHighlightedIcon, alt: "removal x button highlighted" }, void 0),
|
|
9077
|
+
jsx("img", { className: styles$9['chip-remove-button'], src: removeButtonIcon, alt: "removal x button" }, void 0)] }), void 0)] }), void 0));
|
|
9089
9078
|
});
|
|
9090
9079
|
|
|
9091
9080
|
var Autosuggest = {};
|
|
@@ -10379,7 +10368,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
10379
10368
|
});
|
|
10380
10369
|
exports["default"] = void 0;
|
|
10381
10370
|
|
|
10382
|
-
var _react = _interopRequireWildcard(require$$
|
|
10371
|
+
var _react = _interopRequireWildcard(require$$0);
|
|
10383
10372
|
|
|
10384
10373
|
var _propTypes = _interopRequireDefault(propTypes.exports);
|
|
10385
10374
|
|
|
@@ -10473,7 +10462,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
10473
10462
|
});
|
|
10474
10463
|
exports["default"] = void 0;
|
|
10475
10464
|
|
|
10476
|
-
var _react = _interopRequireWildcard(require$$
|
|
10465
|
+
var _react = _interopRequireWildcard(require$$0);
|
|
10477
10466
|
|
|
10478
10467
|
var _propTypes = _interopRequireDefault(propTypes.exports);
|
|
10479
10468
|
|
|
@@ -10658,7 +10647,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
10658
10647
|
});
|
|
10659
10648
|
exports["default"] = void 0;
|
|
10660
10649
|
|
|
10661
|
-
var _react = _interopRequireWildcard(require$$
|
|
10650
|
+
var _react = _interopRequireWildcard(require$$0);
|
|
10662
10651
|
|
|
10663
10652
|
var _propTypes = _interopRequireDefault(propTypes.exports);
|
|
10664
10653
|
|
|
@@ -10813,7 +10802,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
10813
10802
|
});
|
|
10814
10803
|
exports["default"] = void 0;
|
|
10815
10804
|
|
|
10816
|
-
var _react = _interopRequireWildcard(require$$
|
|
10805
|
+
var _react = _interopRequireWildcard(require$$0);
|
|
10817
10806
|
|
|
10818
10807
|
var _propTypes = _interopRequireDefault(propTypes.exports);
|
|
10819
10808
|
|
|
@@ -11354,7 +11343,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
11354
11343
|
});
|
|
11355
11344
|
exports["default"] = void 0;
|
|
11356
11345
|
|
|
11357
|
-
var _react = _interopRequireWildcard(require$$
|
|
11346
|
+
var _react = _interopRequireWildcard(require$$0);
|
|
11358
11347
|
|
|
11359
11348
|
var _propTypes = _interopRequireDefault(propTypes.exports);
|
|
11360
11349
|
|
|
@@ -12210,14 +12199,14 @@ var AutoSuggestInput = (function (_a) {
|
|
|
12210
12199
|
var currentOption = _a.currentOption, suggestions = _a.suggestions, handleSuggestionSelected = _a.handleSuggestionSelected, onChange = _a.onChange, handleSuggestionFetchRequest = _a.handleSuggestionFetchRequest, handleSuggestionClearRequest = _a.handleSuggestionClearRequest, placeholder = _a.placeholder, className = _a.className, wrapText = _a.wrapText;
|
|
12211
12200
|
var renderSuggestion = function (suggestion) {
|
|
12212
12201
|
var _a;
|
|
12213
|
-
return (
|
|
12214
|
-
|
|
12202
|
+
return (jsxs("div", __assign({ className: "" + styles$8['suggestion-option'] }, { children: [suggestion.leftIcon && (jsx("img", { className: "mr16 " + styles$8['suggestion-img'], src: suggestion.leftIcon, alt: suggestion.value }, void 0)),
|
|
12203
|
+
jsx("div", __assign({ className: classNames(styles$8['suggestion-text'], (_a = {},
|
|
12215
12204
|
_a[styles$8.nowrap] = !wrapText,
|
|
12216
12205
|
_a)) }, { children: suggestion.value }), void 0)] }), void 0));
|
|
12217
12206
|
};
|
|
12218
12207
|
var getSuggestionValue = function (suggestion) { return suggestion.value; };
|
|
12219
|
-
var renderInputComponent = function (inputProps) { return (
|
|
12220
|
-
return (
|
|
12208
|
+
var renderInputComponent = function (inputProps) { return (jsx(Input, __assign({}, inputProps, { placeholder: placeholder, "data-cy": "suggest-multi-select-input" }), void 0)); };
|
|
12209
|
+
return (jsx("div", __assign({ className: className }, { children: jsx(dist$1, { theme: styles$8, suggestions: suggestions, onSuggestionsFetchRequested: handleSuggestionFetchRequest, onSuggestionsClearRequested: handleSuggestionClearRequest, getSuggestionValue: getSuggestionValue, renderSuggestion: renderSuggestion, highlightFirstSuggestion: true, inputProps: {
|
|
12221
12210
|
value: currentOption,
|
|
12222
12211
|
onChange: function (_, _a) {
|
|
12223
12212
|
var newValue = _a.newValue;
|
|
@@ -12235,13 +12224,13 @@ styleInject(css_248z$8);
|
|
|
12235
12224
|
|
|
12236
12225
|
var index$1 = (function (_a) {
|
|
12237
12226
|
var options = _a.options, selectedValues = _a.selectedValues, setValues = _a.setValues, placeholder = _a.placeholder, chipsListClassName = _a.chipsListClassName, multiSelectClassName = _a.multiSelectClassName, wrapText = _a.wrapText;
|
|
12238
|
-
var _b =
|
|
12239
|
-
var _c =
|
|
12240
|
-
return (
|
|
12227
|
+
var _b = useState([]), suggestions = _b[0], setSuggestions = _b[1];
|
|
12228
|
+
var _c = useState(''), currentOption = _c[0], setCurrentOption = _c[1];
|
|
12229
|
+
return (jsxs(Fragment$1, { children: [selectedValues && selectedValues.length > 0 && (jsx("div", __assign({ className: "mb8 " + styles$7['chip-container'] + " " + chipsListClassName }, { children: selectedValues.map(function (value, index) { return (jsx(Chip, { value: value, onRemove: function (value) {
|
|
12241
12230
|
var newValues = __spreadArray$1([], selectedValues).filter(function (selectedValue) { return selectedValue.value !== value.value; });
|
|
12242
12231
|
setValues(newValues);
|
|
12243
12232
|
} }, value.value + "-" + index)); }) }), void 0)),
|
|
12244
|
-
|
|
12233
|
+
jsx(AutoSuggestInput, { className: multiSelectClassName, placeholder: placeholder, onChange: setCurrentOption, handleSuggestionSelected: function (value) {
|
|
12245
12234
|
var newSelectedOptions = selectedValues !== null && selectedValues !== void 0 ? selectedValues : [];
|
|
12246
12235
|
newSelectedOptions === null || newSelectedOptions === void 0 ? void 0 : newSelectedOptions.push(value);
|
|
12247
12236
|
setValues(newSelectedOptions);
|
|
@@ -12260,7 +12249,7 @@ var dist = {exports: {}};
|
|
|
12260
12249
|
|
|
12261
12250
|
(function (module, exports) {
|
|
12262
12251
|
(function webpackUniversalModuleDefinition(root, factory) {
|
|
12263
|
-
module.exports = factory(require$$
|
|
12252
|
+
module.exports = factory(require$$0, require$$1);
|
|
12264
12253
|
})(commonjsGlobal, function(__WEBPACK_EXTERNAL_MODULE_2__, __WEBPACK_EXTERNAL_MODULE_13__) {
|
|
12265
12254
|
return /******/ (function(modules) { // webpackBootstrap
|
|
12266
12255
|
/******/ // The module cache
|
|
@@ -13684,7 +13673,7 @@ styleInject(css_248z$7);
|
|
|
13684
13673
|
|
|
13685
13674
|
var Row = function (props) {
|
|
13686
13675
|
var cell = props.cell, data = props.data, isRowHeader = props.isRowHeader, rowId = props.rowId;
|
|
13687
|
-
return (
|
|
13676
|
+
return (jsxs("div", __assign({ className: "\n d-flex\n w-100\n " + (isRowHeader ? styles$6.header : '') + "\n " }, { children: [jsx("h4", __assign({ className: "\n wmx4\n " + styles$6.cell + "\n " + styles$6.sticky + "\n " + (isRowHeader ? "p-h2 p--serif " + styles$6.title : '') + "\n " + (typeof cell.key === 'undefined' ? styles$6.addon : '') + "\n " }, { children: cell.label }), void 0),
|
|
13688
13677
|
Array.isArray(data) &&
|
|
13689
13678
|
data.map(function (item) {
|
|
13690
13679
|
/**
|
|
@@ -13695,7 +13684,7 @@ var Row = function (props) {
|
|
|
13695
13684
|
return null;
|
|
13696
13685
|
if (typeof item[cell.key] === 'undefined')
|
|
13697
13686
|
return null;
|
|
13698
|
-
return (
|
|
13687
|
+
return (jsx("div", __assign({ className: "ta-center " + styles$6.cell }, { children:
|
|
13699
13688
|
/**
|
|
13700
13689
|
* Return a function if `render` option is present
|
|
13701
13690
|
* else print the current data source value
|
|
@@ -13705,11 +13694,11 @@ var Row = function (props) {
|
|
|
13705
13694
|
: "" + item[cell.key] }), rowId + "-" + item.id));
|
|
13706
13695
|
})] }), rowId));
|
|
13707
13696
|
};
|
|
13708
|
-
var Row$1 = require$$
|
|
13697
|
+
var Row$1 = require$$0.memo(Row);
|
|
13709
13698
|
|
|
13710
13699
|
var ArrowIcon = function (_a) {
|
|
13711
13700
|
var className = _a.className;
|
|
13712
|
-
return (
|
|
13701
|
+
return (jsx("svg", __assign({ width: "14", height: "8", viewBox: "0 0 14 8", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className }, { children: jsx("path", { d: "M1 1.00003L7 7.00003L13 1.00003", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, void 0) }), void 0));
|
|
13713
13702
|
};
|
|
13714
13703
|
|
|
13715
13704
|
var css_248z$6 = ".style-module_container__3BxOi {\n position: absolute;\n width: 100vw;\n padding: 0 16px;\n justify-content: space-between;\n z-index: 1;\n display: flex;\n}\n@media (min-width: 34rem) {\n .style-module_container__3BxOi {\n display: none;\n }\n}\n\n.style-module_next__3yJsi {\n transform: rotate(-90deg);\n}\n\n.style-module_prev__3rIR_ {\n transform: rotate(90deg);\n}\n\n.style-module_arrow__1tlbD {\n width: 32px;\n height: 32px;\n padding: 0;\n border-radius: 50%;\n background-color: #f5f5fa;\n justify-content: center;\n align-items: center;\n stroke: #e6e5ff;\n}\n.style-module_arrow__1tlbD:hover, .style-module_arrow__1tlbD:focus {\n background-color: #f5f5fa;\n cursor: not-allowed;\n}\n\n.style-module_active__2kklB {\n stroke: #8e8cee;\n}\n.style-module_active__2kklB:hover, .style-module_active__2kklB:focus {\n background-color: #f5f5fa;\n cursor: pointer;\n}";
|
|
@@ -13720,22 +13709,22 @@ var TableArrows = function (props) {
|
|
|
13720
13709
|
var _a, _b;
|
|
13721
13710
|
var active = props.active, onClick = props.onClick;
|
|
13722
13711
|
var handleButtonClick = function (value) { return function () { return onClick(value); }; };
|
|
13723
|
-
return (
|
|
13712
|
+
return (jsxs("div", __assign({ className: "mt24 " + styles$5.container }, { children: [jsx("button", __assign({ onClick: handleButtonClick('prev'), className: classNames("p-btn--secondary d-flex", styles$5.prev, styles$5.arrow, (_a = {},
|
|
13724
13713
|
_a[styles$5.active] = active.left,
|
|
13725
|
-
_a)) }, { children:
|
|
13726
|
-
|
|
13714
|
+
_a)) }, { children: jsx(ArrowIcon, {}, void 0) }), void 0),
|
|
13715
|
+
jsx("button", __assign({ onClick: handleButtonClick('next'), className: classNames("p-btn--secondary d-flex", styles$5.next, styles$5.arrow, (_b = {},
|
|
13727
13716
|
_b[styles$5.active] = active.right,
|
|
13728
|
-
_b)) }, { children:
|
|
13717
|
+
_b)) }, { children: jsx(ArrowIcon, {}, void 0) }), void 0)] }), void 0));
|
|
13729
13718
|
};
|
|
13730
13719
|
|
|
13731
13720
|
var StarIcon = function (_a) {
|
|
13732
13721
|
var className = _a.className;
|
|
13733
|
-
return (
|
|
13722
|
+
return (jsx("svg", __assign({ width: "12", height: "12", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className }, { children: jsx("path", { d: "M5.933.004a.73.73 0 01.756.468L7.891 3.67l3.407.16c.677.03.954.886.422 1.306l-2.66 2.145.899 3.296c.17.647-.545 1.166-1.105.8l-2.85-1.872-2.858 1.873c-.561.368-1.28-.152-1.107-.801l.9-3.296L.278 5.136C-.253 4.716.024 3.86.7 3.831l3.407-.161L5.322.472a.73.73 0 01.61-.468z" }, void 0) }), void 0));
|
|
13734
13723
|
};
|
|
13735
13724
|
|
|
13736
13725
|
var ZapIcon = function (_a) {
|
|
13737
13726
|
var className = _a.className;
|
|
13738
|
-
return (
|
|
13727
|
+
return (jsx("svg", __assign({ width: "12", height: "12", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className }, { children: jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M7.492 1.124A1 1 0 005.732.36l-5 6A1 1 0 001.5 8h3.367l-.36 2.876a1 1 0 001.761.764l5-6A1 1 0 0010.5 4H7.133l.36-2.876z" }, void 0) }), void 0));
|
|
13739
13728
|
};
|
|
13740
13729
|
|
|
13741
13730
|
var css_248z$5 = ".style-module_icon__1ep7- {\n margin-right: 4px;\n}\n\n.style-module_filled__3l-v0 {\n fill: #8e8cee;\n}\n\n.style-module_empty__Ikg_s {\n fill: #f5f5fa;\n}";
|
|
@@ -13753,15 +13742,15 @@ var VALID_VALUES = [1, 2, 3];
|
|
|
13753
13742
|
var TableRating = function (props) {
|
|
13754
13743
|
var rating = props.rating, type = props.type;
|
|
13755
13744
|
var SelectedIcon = getRatingIcon(type);
|
|
13756
|
-
return (
|
|
13745
|
+
return (jsx("div", { children: VALID_VALUES.map(function (value) { return (jsx(SelectedIcon, { className: classNames(styles$4.icon, value <= rating ? styles$4.filled : styles$4.empty) }, value)); }) }, void 0));
|
|
13757
13746
|
};
|
|
13758
13747
|
|
|
13759
13748
|
var TableTrueFalse = function (_a) {
|
|
13760
13749
|
var value = _a.value, _b = _a.className, className = _b === void 0 ? '' : _b;
|
|
13761
13750
|
if (value) {
|
|
13762
|
-
return (
|
|
13751
|
+
return (jsx("svg", __assign({ width: "18", height: "13", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className }, { children: jsx("path", { d: "M15.667 1.833L6.5 11 2.333 6.833", stroke: "#8E8CEE", strokeWidth: "3", strokeLinecap: "round", strokeLinejoin: "round" }, void 0) }), void 0));
|
|
13763
13752
|
}
|
|
13764
|
-
return (
|
|
13753
|
+
return (jsx("svg", __assign({ width: "12", height: "12", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M11.707 1.707A1 1 0 0010.293.293L6 4.586 1.707.293A1 1 0 00.293 1.707L4.586 6 .293 10.293a1 1 0 101.414 1.414L6 7.414l4.293 4.293a1 1 0 001.414-1.414L7.414 6l4.293-4.293z", fill: "#D2D2D8" }, void 0) }), void 0));
|
|
13765
13754
|
};
|
|
13766
13755
|
|
|
13767
13756
|
var css_248z$4 = ".style-module_button__3TkNT {\n padding: 0;\n display: inline-flex;\n justify-content: center;\n align-items: center;\n vertical-align: bottom;\n width: 24px;\n height: 24px;\n transition: all 0.3s ease;\n}\n.style-module_button__3TkNT:hover, .style-module_button__3TkNT:focus {\n background-color: #f7f7ff;\n}\n.style-module_button__3TkNT:hover svg, .style-module_button__3TkNT:focus svg {\n fill: #b1b0f5;\n}\n.style-module_button__3TkNT svg {\n fill: #e6e5ff;\n transition: all 0.3s ease;\n}";
|
|
@@ -13770,9 +13759,9 @@ styleInject(css_248z$4);
|
|
|
13770
13759
|
|
|
13771
13760
|
var TableInfoButton = function (_a) {
|
|
13772
13761
|
var onClick = _a.onClick, _b = _a.className, className = _b === void 0 ? '' : _b;
|
|
13773
|
-
return (
|
|
13774
|
-
|
|
13775
|
-
|
|
13762
|
+
return (jsx("span", __assign({ role: "button", className: "p-btn--secondary " + styles$3.button + " " + className, onClick: onClick }, { children: jsxs("svg", __assign({ width: "20", height: "20", viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: [jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M10 2.66667C5.94991 2.66667 2.66667 5.94991 2.66667 10C2.66667 14.0501 5.94991 17.3333 10 17.3333C14.0501 17.3333 17.3333 14.0501 17.3333 10C17.3333 5.94991 14.0501 2.66667 10 2.66667ZM0.666667 10C0.666667 4.84534 4.84534 0.666667 10 0.666667C15.1547 0.666667 19.3333 4.84534 19.3333 10C19.3333 15.1547 15.1547 19.3333 10 19.3333C4.84534 19.3333 0.666667 15.1547 0.666667 10Z" }, void 0),
|
|
13763
|
+
jsx("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M10 9C10.5523 9 11 9.44772 11 10V13.3333C11 13.8856 10.5523 14.3333 10 14.3333C9.44772 14.3333 9 13.8856 9 13.3333V10C9 9.44772 9.44772 9 10 9Z" }, void 0),
|
|
13764
|
+
jsx("path", { d: "M10.8333 6.66667C10.8333 7.1269 10.4602 7.5 10 7.5C9.53976 7.5 9.16667 7.1269 9.16667 6.66667C9.16667 6.20643 9.53976 5.83333 10 5.83333C10.4602 5.83333 10.8333 6.20643 10.8333 6.66667Z" }, void 0)] }), void 0) }), void 0));
|
|
13776
13765
|
};
|
|
13777
13766
|
|
|
13778
13767
|
var css_248z$3 = ".style-module_icon__30Nor {\n min-width: 20px;\n}";
|
|
@@ -13781,26 +13770,26 @@ styleInject(css_248z$3);
|
|
|
13781
13770
|
|
|
13782
13771
|
var TableRowHeader = function (props) {
|
|
13783
13772
|
var icon = props.icon, label = props.label, subtitle = props.subtitle, onClickInfo = props.onClickInfo;
|
|
13784
|
-
return (
|
|
13785
|
-
|
|
13773
|
+
return (jsxs("div", __assign({ className: "d-flex" }, { children: [jsx("span", __assign({ className: "mr8 " + styles$2.icon }, { children: icon }), void 0),
|
|
13774
|
+
jsxs("div", { children: [jsxs("p", __assign({ className: "p-p d-inline" }, { children: [jsx("span", __assign({ className: classNames({
|
|
13786
13775
|
mr8: onClickInfo,
|
|
13787
13776
|
}) }, { children: label }), void 0),
|
|
13788
|
-
onClickInfo &&
|
|
13789
|
-
subtitle &&
|
|
13777
|
+
onClickInfo && jsx(TableInfoButton, { onClick: onClickInfo }, void 0)] }), void 0),
|
|
13778
|
+
subtitle && jsx("p", __assign({ className: "p-p--small tc-grey-500" }, { children: subtitle }), void 0)] }, void 0)] }), void 0));
|
|
13790
13779
|
};
|
|
13791
13780
|
|
|
13792
13781
|
var Chevron = function (_a) {
|
|
13793
13782
|
var className = _a.className;
|
|
13794
|
-
return (
|
|
13783
|
+
return (jsx("svg", __assign({ width: "20", height: "20", fill: "none", xmlns: "http://www.w3.org/2000/svg", className: className }, { children: jsx("path", { d: "M15 12.5l-5-5-5 5", stroke: "#8E8CEE", strokeWidth: "2", strokeLinecap: "round", strokeLinejoin: "round" }, void 0) }), void 0));
|
|
13795
13784
|
};
|
|
13796
13785
|
|
|
13797
13786
|
var useActiveTableArrows = function () {
|
|
13798
|
-
var _a =
|
|
13787
|
+
var _a = useState({
|
|
13799
13788
|
left: false,
|
|
13800
13789
|
right: true,
|
|
13801
13790
|
}), activeArrows = _a[0], setActiveArrows = _a[1];
|
|
13802
|
-
var contentContainerRef =
|
|
13803
|
-
var contentWrapperRef =
|
|
13791
|
+
var contentContainerRef = useRef(null);
|
|
13792
|
+
var contentWrapperRef = useRef(null);
|
|
13804
13793
|
var handleTableScroll = function (e) {
|
|
13805
13794
|
var width = window.innerWidth;
|
|
13806
13795
|
if (e.target === contentWrapperRef.current &&
|
|
@@ -13815,7 +13804,7 @@ var useActiveTableArrows = function () {
|
|
|
13815
13804
|
}
|
|
13816
13805
|
};
|
|
13817
13806
|
var debouncedTableScroll = lodash_debounce(handleTableScroll, 150);
|
|
13818
|
-
|
|
13807
|
+
useEffect(function () {
|
|
13819
13808
|
var _a, _b;
|
|
13820
13809
|
(_a = contentWrapperRef.current) === null || _a === void 0 ? void 0 : _a.addEventListener('scroll', debouncedTableScroll, {
|
|
13821
13810
|
passive: true,
|
|
@@ -13835,8 +13824,8 @@ styleInject(css_248z$2);
|
|
|
13835
13824
|
|
|
13836
13825
|
var ComparisonTable = function (props) {
|
|
13837
13826
|
var headers = props.headers, data = props.data, hideDetails = props.hideDetails, styles = props.styles;
|
|
13838
|
-
var _a =
|
|
13839
|
-
var headerContainerRef =
|
|
13827
|
+
var _a = useState(false), showMore = _a[0], setShowMore = _a[1];
|
|
13828
|
+
var headerContainerRef = useRef(null);
|
|
13840
13829
|
var _b = useActiveTableArrows(), activeArrows = _b.activeArrows, contentContainerRef = _b.contentContainerRef, contentWrapperRef = _b.contentWrapperRef;
|
|
13841
13830
|
/** narrow types */
|
|
13842
13831
|
var headerContainer = headerContainerRef
|
|
@@ -13867,30 +13856,30 @@ var ComparisonTable = function (props) {
|
|
|
13867
13856
|
return [2 /*return*/];
|
|
13868
13857
|
});
|
|
13869
13858
|
}); };
|
|
13870
|
-
return (
|
|
13871
|
-
|
|
13872
|
-
|
|
13859
|
+
return (jsx(dist.exports.ScrollSync, { children: jsxs("div", { children: [jsx("div", __assign({ className: classNames(baseStyles.header, styles === null || styles === void 0 ? void 0 : styles.header) }, { children: jsx(dist.exports.ScrollSyncPane, { children: jsx("div", __assign({ className: baseStyles.container, ref: headerContainerRef }, { children: jsx("div", __assign({ className: classNames(baseStyles['overflow-container']) }, { children: jsxs("div", __assign({ className: baseStyles['group-container'] }, { children: [jsx(TableArrows, { onClick: handleArrowsClick, active: activeArrows }, void 0),
|
|
13860
|
+
jsx(Row$1, { rowId: "table-header-row", cell: headers[0].cells[0], data: data, isRowHeader: true }, "table-header-row")] }), void 0) }), void 0) }), void 0) }, void 0) }), void 0),
|
|
13861
|
+
jsx(dist.exports.ScrollSyncPane, { children: jsx("div", __assign({ className: classNames(baseStyles.container, styles === null || styles === void 0 ? void 0 : styles.container), ref: contentWrapperRef }, { children: jsx("div", __assign({ className: classNames(baseStyles['overflow-container']), ref: contentContainerRef }, { children: jsxs("div", __assign({ className: baseStyles['group-container'] }, { children: [Array.isArray(headers) &&
|
|
13873
13862
|
headers
|
|
13874
13863
|
.filter(function (headerGroup) {
|
|
13875
13864
|
return !hideDetails || showMore || headerGroup.default;
|
|
13876
13865
|
})
|
|
13877
13866
|
.map(function (headerGroup, headerGroupIndex) {
|
|
13878
13867
|
var _a;
|
|
13879
|
-
return (
|
|
13868
|
+
return (jsxs("div", { children: [
|
|
13880
13869
|
/**
|
|
13881
13870
|
* Print a table subheader if the `label` value is present
|
|
13882
13871
|
*/
|
|
13883
|
-
headerGroup.label && (
|
|
13872
|
+
headerGroup.label && (jsx("div", __assign({ className: baseStyles['group-title'] }, { children: jsx("h4", __assign({ className: "p-h4 " + baseStyles.sticky }, { children: headerGroup.label }), void 0) }), void 0)),
|
|
13884
13873
|
(_a = headerGroup.cells) === null || _a === void 0 ? void 0 : _a.map(function (cell, index) {
|
|
13885
13874
|
var _a;
|
|
13886
13875
|
var rowId = headerGroup.id + "-" + ((_a = cell.key) !== null && _a !== void 0 ? _a : 'addon') + "-" + index;
|
|
13887
13876
|
/** Do not render the first row */
|
|
13888
13877
|
if (index === 0 && headerGroupIndex === 0)
|
|
13889
13878
|
return null;
|
|
13890
|
-
return (
|
|
13879
|
+
return (jsx(Row$1, { rowId: rowId, cell: cell, data: data }, rowId));
|
|
13891
13880
|
})] }, headerGroup.id));
|
|
13892
13881
|
}),
|
|
13893
|
-
hideDetails && (
|
|
13882
|
+
hideDetails && (jsx("div", __assign({ className: classNames(baseStyles['show-details-container'], baseStyles.sticky, 'mt48') }, { children: jsx("div", { children: jsxs("button", __assign({ className: "w100 d-flex p-a p-h4 c-pointer " + baseStyles['show-details-button'], onClick: toggleMoreRows }, { children: [showMore ? 'Hide details' : 'Show details', jsx(Chevron, { className: showMore ? '' : baseStyles['icon-inverted'] }, void 0)] }), void 0) }, void 0) }), void 0))] }), void 0) }), void 0) }), void 0) }, void 0)] }, void 0) }, void 0));
|
|
13894
13883
|
};
|
|
13895
13884
|
|
|
13896
13885
|
var css_248z$1 = ".style-module_background-container__2Gjka {\n position: relative;\n display: inline-block;\n background-color: var(--ds-primary-100);\n border-radius: 8px;\n padding: 0 8px;\n}\n\n.style-module_chip-container__7XeKn {\n display: flex;\n align-items: center;\n}\n\n.style-module_chip__3rgLT {\n cursor: pointer;\n z-index: 2;\n padding-left: 16px;\n padding-right: 16px;\n}\n\n.style-module_select-chip-background__YCAyw {\n position: absolute;\n background-color: white;\n border-radius: 8px;\n top: 8px;\n z-index: 1;\n transition: width 0.3s, left 0.3s;\n}";
|
|
@@ -13899,29 +13888,29 @@ styleInject(css_248z$1);
|
|
|
13899
13888
|
|
|
13900
13889
|
var SegmentedControl = function (_a) {
|
|
13901
13890
|
var _b = _a.className, className = _b === void 0 ? '' : _b, values = _a.values, selectedIndex = _a.selectedIndex, onChange = _a.onChange;
|
|
13902
|
-
var _c =
|
|
13903
|
-
var chipContainer =
|
|
13891
|
+
var _c = useState({ left: 0, width: 0 }), selectedChipBackgroundWidthLeft = _c[0], setSelectedChipBackgroundWidthLeft = _c[1];
|
|
13892
|
+
var chipContainer = useRef(null);
|
|
13904
13893
|
var height = typeof values[0] === 'string' ? 48 : 66;
|
|
13905
|
-
|
|
13894
|
+
useEffect(function () {
|
|
13906
13895
|
var _a;
|
|
13907
13896
|
var selectedChip = (_a = chipContainer.current) === null || _a === void 0 ? void 0 : _a.children[selectedIndex];
|
|
13908
13897
|
var left = selectedChip.offsetLeft;
|
|
13909
13898
|
var width = selectedChip.offsetWidth;
|
|
13910
13899
|
setSelectedChipBackgroundWidthLeft({ left: left, width: width });
|
|
13911
13900
|
}, [selectedIndex]);
|
|
13912
|
-
return (
|
|
13913
|
-
return (
|
|
13901
|
+
return (jsx("div", __assign({ className: className }, { children: jsxs("div", __assign({ className: styles$1['background-container'] }, { children: [jsx("div", __assign({ ref: chipContainer, className: styles$1['chip-container'], style: { height: height + "px" } }, { children: values.map(function (value, index) {
|
|
13902
|
+
return (jsx("div", __assign({ role: "button", tabIndex: 0, onKeyDown: function (e) {
|
|
13914
13903
|
if (e.key === 'Enter') {
|
|
13915
13904
|
onChange(index);
|
|
13916
13905
|
}
|
|
13917
13906
|
}, onClick: function () {
|
|
13918
13907
|
onChange(index);
|
|
13919
|
-
}, className: styles$1.chip }, { children: typeof value === 'string' ? (
|
|
13920
|
-
|
|
13908
|
+
}, className: styles$1.chip }, { children: typeof value === 'string' ? (jsx("div", __assign({ className: "p-h4 ta-center " + (selectedIndex === index ? '' : 'tc-primary-500') }, { children: value }), void 0)) : (jsxs(Fragment$1, { children: [jsx("div", __assign({ className: "p-h4 ta-center " + (selectedIndex === index ? '' : 'tc-primary-500') }, { children: value.title }), void 0),
|
|
13909
|
+
jsx("div", __assign({ className: "p-p--small ta-center " + (selectedIndex === index
|
|
13921
13910
|
? 'tc-grey-500'
|
|
13922
13911
|
: 'tc-primary-500') }, { children: value.subtitle }), void 0)] }, void 0)) }), void 0));
|
|
13923
13912
|
}) }), void 0),
|
|
13924
|
-
|
|
13913
|
+
jsx("div", { className: styles$1['select-chip-background'], style: {
|
|
13925
13914
|
width: selectedChipBackgroundWidthLeft.width + "px",
|
|
13926
13915
|
height: height - 16 + "px",
|
|
13927
13916
|
left: selectedChipBackgroundWidthLeft.left + "px",
|
|
@@ -16489,7 +16478,7 @@ var protocolPattern = /^([a-z0-9.+-]+:)/i,
|
|
|
16489
16478
|
'gopher:': true,
|
|
16490
16479
|
'file:': true
|
|
16491
16480
|
},
|
|
16492
|
-
querystring = require$$
|
|
16481
|
+
querystring = require$$2;
|
|
16493
16482
|
|
|
16494
16483
|
function urlParse(url, parseQueryString, slashesDenoteHost) {
|
|
16495
16484
|
if (url && util.isObject(url) && url instanceof Url) return url;
|
|
@@ -17362,7 +17351,7 @@ class VFile$1 {
|
|
|
17362
17351
|
* Get the parent path (example: `'~'`).
|
|
17363
17352
|
*/
|
|
17364
17353
|
get dirname() {
|
|
17365
|
-
return typeof this.path === 'string' ?
|
|
17354
|
+
return typeof this.path === 'string' ? path.dirname(this.path) : undefined
|
|
17366
17355
|
}
|
|
17367
17356
|
|
|
17368
17357
|
/**
|
|
@@ -17371,14 +17360,14 @@ class VFile$1 {
|
|
|
17371
17360
|
*/
|
|
17372
17361
|
set dirname(dirname) {
|
|
17373
17362
|
assertPath$1(this.basename, 'dirname');
|
|
17374
|
-
this.path =
|
|
17363
|
+
this.path = path.join(dirname || '', this.basename);
|
|
17375
17364
|
}
|
|
17376
17365
|
|
|
17377
17366
|
/**
|
|
17378
17367
|
* Get the basename (including extname) (example: `'index.min.js'`).
|
|
17379
17368
|
*/
|
|
17380
17369
|
get basename() {
|
|
17381
|
-
return typeof this.path === 'string' ?
|
|
17370
|
+
return typeof this.path === 'string' ? path.basename(this.path) : undefined
|
|
17382
17371
|
}
|
|
17383
17372
|
|
|
17384
17373
|
/**
|
|
@@ -17390,14 +17379,14 @@ class VFile$1 {
|
|
|
17390
17379
|
set basename(basename) {
|
|
17391
17380
|
assertNonEmpty$1(basename, 'basename');
|
|
17392
17381
|
assertPart$1(basename, 'basename');
|
|
17393
|
-
this.path =
|
|
17382
|
+
this.path = path.join(this.dirname || '', basename);
|
|
17394
17383
|
}
|
|
17395
17384
|
|
|
17396
17385
|
/**
|
|
17397
17386
|
* Get the extname (including dot) (example: `'.js'`).
|
|
17398
17387
|
*/
|
|
17399
17388
|
get extname() {
|
|
17400
|
-
return typeof this.path === 'string' ?
|
|
17389
|
+
return typeof this.path === 'string' ? path.extname(this.path) : undefined
|
|
17401
17390
|
}
|
|
17402
17391
|
|
|
17403
17392
|
/**
|
|
@@ -17420,7 +17409,7 @@ class VFile$1 {
|
|
|
17420
17409
|
}
|
|
17421
17410
|
}
|
|
17422
17411
|
|
|
17423
|
-
this.path =
|
|
17412
|
+
this.path = path.join(this.dirname, this.stem + (extname || ''));
|
|
17424
17413
|
}
|
|
17425
17414
|
|
|
17426
17415
|
/**
|
|
@@ -17428,7 +17417,7 @@ class VFile$1 {
|
|
|
17428
17417
|
*/
|
|
17429
17418
|
get stem() {
|
|
17430
17419
|
return typeof this.path === 'string'
|
|
17431
|
-
?
|
|
17420
|
+
? path.basename(this.path, this.extname)
|
|
17432
17421
|
: undefined
|
|
17433
17422
|
}
|
|
17434
17423
|
|
|
@@ -17441,7 +17430,7 @@ class VFile$1 {
|
|
|
17441
17430
|
set stem(stem) {
|
|
17442
17431
|
assertNonEmpty$1(stem, 'stem');
|
|
17443
17432
|
assertPart$1(stem, 'stem');
|
|
17444
|
-
this.path =
|
|
17433
|
+
this.path = path.join(this.dirname || '', stem + (this.extname || ''));
|
|
17445
17434
|
}
|
|
17446
17435
|
|
|
17447
17436
|
/**
|
|
@@ -17539,9 +17528,9 @@ class VFile$1 {
|
|
|
17539
17528
|
* @returns {void}
|
|
17540
17529
|
*/
|
|
17541
17530
|
function assertPart$1(part, name) {
|
|
17542
|
-
if (part && part.includes(
|
|
17531
|
+
if (part && part.includes(path.sep)) {
|
|
17543
17532
|
throw new Error(
|
|
17544
|
-
'`' + name + '` cannot be a path: did not expect `' +
|
|
17533
|
+
'`' + name + '` cannot be a path: did not expect `' + path.sep + '`'
|
|
17545
17534
|
)
|
|
17546
17535
|
}
|
|
17547
17536
|
}
|
|
@@ -18263,7 +18252,7 @@ class VFile {
|
|
|
18263
18252
|
* Get the parent path (example: `'~'`).
|
|
18264
18253
|
*/
|
|
18265
18254
|
get dirname() {
|
|
18266
|
-
return typeof this.path === 'string' ?
|
|
18255
|
+
return typeof this.path === 'string' ? path.dirname(this.path) : undefined
|
|
18267
18256
|
}
|
|
18268
18257
|
|
|
18269
18258
|
/**
|
|
@@ -18272,14 +18261,14 @@ class VFile {
|
|
|
18272
18261
|
*/
|
|
18273
18262
|
set dirname(dirname) {
|
|
18274
18263
|
assertPath(this.basename, 'dirname');
|
|
18275
|
-
this.path =
|
|
18264
|
+
this.path = path.join(dirname || '', this.basename);
|
|
18276
18265
|
}
|
|
18277
18266
|
|
|
18278
18267
|
/**
|
|
18279
18268
|
* Get the basename (including extname) (example: `'index.min.js'`).
|
|
18280
18269
|
*/
|
|
18281
18270
|
get basename() {
|
|
18282
|
-
return typeof this.path === 'string' ?
|
|
18271
|
+
return typeof this.path === 'string' ? path.basename(this.path) : undefined
|
|
18283
18272
|
}
|
|
18284
18273
|
|
|
18285
18274
|
/**
|
|
@@ -18291,14 +18280,14 @@ class VFile {
|
|
|
18291
18280
|
set basename(basename) {
|
|
18292
18281
|
assertNonEmpty(basename, 'basename');
|
|
18293
18282
|
assertPart(basename, 'basename');
|
|
18294
|
-
this.path =
|
|
18283
|
+
this.path = path.join(this.dirname || '', basename);
|
|
18295
18284
|
}
|
|
18296
18285
|
|
|
18297
18286
|
/**
|
|
18298
18287
|
* Get the extname (including dot) (example: `'.js'`).
|
|
18299
18288
|
*/
|
|
18300
18289
|
get extname() {
|
|
18301
|
-
return typeof this.path === 'string' ?
|
|
18290
|
+
return typeof this.path === 'string' ? path.extname(this.path) : undefined
|
|
18302
18291
|
}
|
|
18303
18292
|
|
|
18304
18293
|
/**
|
|
@@ -18321,7 +18310,7 @@ class VFile {
|
|
|
18321
18310
|
}
|
|
18322
18311
|
}
|
|
18323
18312
|
|
|
18324
|
-
this.path =
|
|
18313
|
+
this.path = path.join(this.dirname, this.stem + (extname || ''));
|
|
18325
18314
|
}
|
|
18326
18315
|
|
|
18327
18316
|
/**
|
|
@@ -18329,7 +18318,7 @@ class VFile {
|
|
|
18329
18318
|
*/
|
|
18330
18319
|
get stem() {
|
|
18331
18320
|
return typeof this.path === 'string'
|
|
18332
|
-
?
|
|
18321
|
+
? path.basename(this.path, this.extname)
|
|
18333
18322
|
: undefined
|
|
18334
18323
|
}
|
|
18335
18324
|
|
|
@@ -18342,7 +18331,7 @@ class VFile {
|
|
|
18342
18331
|
set stem(stem) {
|
|
18343
18332
|
assertNonEmpty(stem, 'stem');
|
|
18344
18333
|
assertPart(stem, 'stem');
|
|
18345
|
-
this.path =
|
|
18334
|
+
this.path = path.join(this.dirname || '', stem + (this.extname || ''));
|
|
18346
18335
|
}
|
|
18347
18336
|
|
|
18348
18337
|
/**
|
|
@@ -18440,9 +18429,9 @@ class VFile {
|
|
|
18440
18429
|
* @returns {void}
|
|
18441
18430
|
*/
|
|
18442
18431
|
function assertPart(part, name) {
|
|
18443
|
-
if (part && part.includes(
|
|
18432
|
+
if (part && part.includes(path.sep)) {
|
|
18444
18433
|
throw new Error(
|
|
18445
|
-
'`' + name + '` cannot be a path: did not expect `' +
|
|
18434
|
+
'`' + name + '` cannot be a path: did not expect `' + path.sep + '`'
|
|
18446
18435
|
)
|
|
18447
18436
|
}
|
|
18448
18437
|
}
|
|
@@ -32978,7 +32967,7 @@ function toReact(context, node, index, parent) {
|
|
|
32978
32967
|
options.components && own$2.call(options.components, name)
|
|
32979
32968
|
? options.components[name]
|
|
32980
32969
|
: name;
|
|
32981
|
-
const basic = typeof component === 'string' || component === require$$
|
|
32970
|
+
const basic = typeof component === 'string' || component === require$$0.Fragment;
|
|
32982
32971
|
|
|
32983
32972
|
if (!ReactIs.isValidElementType(component)) {
|
|
32984
32973
|
throw new TypeError(
|
|
@@ -33092,8 +33081,8 @@ function toReact(context, node, index, parent) {
|
|
|
33092
33081
|
|
|
33093
33082
|
// Ensure no React warnings are emitted for void elements w/ children.
|
|
33094
33083
|
return children.length > 0
|
|
33095
|
-
? require$$
|
|
33096
|
-
: require$$
|
|
33084
|
+
? require$$0.createElement(component, properties, children)
|
|
33085
|
+
: require$$0.createElement(component, properties)
|
|
33097
33086
|
}
|
|
33098
33087
|
|
|
33099
33088
|
/**
|
|
@@ -33322,14 +33311,14 @@ function ReactMarkdown(options) {
|
|
|
33322
33311
|
}
|
|
33323
33312
|
|
|
33324
33313
|
/** @type {ReactElement} */
|
|
33325
|
-
let result = require$$
|
|
33326
|
-
require$$
|
|
33314
|
+
let result = require$$0.createElement(
|
|
33315
|
+
require$$0.Fragment,
|
|
33327
33316
|
{},
|
|
33328
33317
|
childrenToReact({options, schema: html, listDepth: 0}, hastNode)
|
|
33329
33318
|
);
|
|
33330
33319
|
|
|
33331
33320
|
if (options.className) {
|
|
33332
|
-
result = require$$
|
|
33321
|
+
result = require$$0.createElement('div', {className: options.className}, result);
|
|
33333
33322
|
}
|
|
33334
33323
|
|
|
33335
33324
|
return result
|
|
@@ -36040,73 +36029,45 @@ var directiveToHTMLTag = function () {
|
|
|
36040
36029
|
};
|
|
36041
36030
|
};
|
|
36042
36031
|
var Link = function (openLinksInNewTab) { return function (props) {
|
|
36043
|
-
return openLinksInNewTab ? (
|
|
36032
|
+
return openLinksInNewTab ? (jsx("a", __assign({ href: props.href, className: "p-a", target: "_blank", rel: "noreferrer" }, { children: props.children }), void 0)) : (jsx("a", __assign({ href: props.href, className: "p-a" }, { children: props.children }), void 0));
|
|
36044
36033
|
}; };
|
|
36045
36034
|
var Paragraph = function (className) { return function (props) {
|
|
36046
|
-
return
|
|
36035
|
+
return jsx("p", __assign({ className: className || 'p-p mt8' }, { children: props.children }), void 0);
|
|
36047
36036
|
}; };
|
|
36048
36037
|
var Heading = function (props) {
|
|
36049
36038
|
var level = props.level;
|
|
36050
36039
|
switch (level) {
|
|
36051
36040
|
case 1:
|
|
36052
|
-
return
|
|
36041
|
+
return jsx("h1", __assign({ className: "p-h1 p--serif mt32" }, { children: props.children }), void 0);
|
|
36053
36042
|
case 2:
|
|
36054
|
-
return
|
|
36043
|
+
return jsx("h2", __assign({ className: "p-h2 mt24" }, { children: props.children }), void 0);
|
|
36055
36044
|
case 3:
|
|
36056
|
-
return
|
|
36045
|
+
return jsx("h3", __assign({ className: "p-h3 mt16" }, { children: props.children }), void 0);
|
|
36057
36046
|
case 4:
|
|
36058
|
-
return
|
|
36047
|
+
return jsx("h4", __assign({ className: "p-h4 mt8" }, { children: props.children }), void 0);
|
|
36059
36048
|
default:
|
|
36060
|
-
return
|
|
36049
|
+
return jsx("p", { children: props.children }, void 0);
|
|
36061
36050
|
}
|
|
36062
36051
|
};
|
|
36063
36052
|
var UList = function (props) {
|
|
36064
|
-
return
|
|
36053
|
+
return jsx("ul", __assign({ className: "p-p " + styles.ulist + " mt8" }, { children: props.children }), void 0);
|
|
36065
36054
|
};
|
|
36066
36055
|
var OList = function (props) {
|
|
36067
|
-
return
|
|
36056
|
+
return jsx("ol", __assign({ className: "p-p " + styles.olist + " mt8" }, { children: props.children }), void 0);
|
|
36068
36057
|
};
|
|
36069
36058
|
var Strong = function (props) {
|
|
36070
|
-
return
|
|
36059
|
+
return jsx("strong", __assign({ className: "fw-bold" }, { children: props.children }), void 0);
|
|
36071
36060
|
};
|
|
36072
36061
|
var Italic = function (props) {
|
|
36073
|
-
return
|
|
36062
|
+
return jsx("em", __assign({ className: "fs-italic" }, { children: props.children }), void 0);
|
|
36074
36063
|
};
|
|
36075
36064
|
var Code = function (props) {
|
|
36076
|
-
return (
|
|
36065
|
+
return (jsx("div", __assign({ className: "bg-grey-200 p8 p-p--small my8 br2 " + styles.code }, { children: props.children }), void 0));
|
|
36077
36066
|
};
|
|
36078
36067
|
var Markdown = function (_a) {
|
|
36079
36068
|
var children = _a.children, customMDComponents = _a.customMDComponents, _b = _a.className, className = _b === void 0 ? '' : _b, _c = _a.openLinksInNewTab, openLinksInNewTab = _c === void 0 ? false : _c, _d = _a.paragraphClassName, paragraphClassName = _d === void 0 ? '' : _d;
|
|
36080
|
-
return (
|
|
36069
|
+
return (jsx(ReactMarkdown, { children: children, className: className, components: __assign({ a: Link(openLinksInNewTab), p: Paragraph(paragraphClassName), h1: Heading, h2: Heading, h3: Heading, h4: Heading, h5: Heading, ol: OList, ul: UList, strong: Strong, em: Italic, code: Code }, customMDComponents), remarkPlugins: [remarkDirective, directiveToHTMLTag] }, void 0));
|
|
36081
36070
|
};
|
|
36082
36071
|
|
|
36083
|
-
|
|
36084
|
-
exports.AutoSuggestMultiSelect = index$1;
|
|
36085
|
-
exports.AutocompleteAddress = AutoCompleteAddress;
|
|
36086
|
-
exports.BottomModal = BottomModal;
|
|
36087
|
-
exports.BottomOrRegularModal = index$6;
|
|
36088
|
-
exports.Button = Button;
|
|
36089
|
-
exports.CardButton = CardButton;
|
|
36090
|
-
exports.CardWithLeftIcon = index$4;
|
|
36091
|
-
exports.CardWithTopIcon = index$3;
|
|
36092
|
-
exports.CardWithTopLeftIcon = index$5;
|
|
36093
|
-
exports.Chip = Chip;
|
|
36094
|
-
exports.ComparisonTable = ComparisonTable;
|
|
36095
|
-
exports.CurrencyInput = CurrencyInput;
|
|
36096
|
-
exports.DateSelector = DateSelector;
|
|
36097
|
-
exports.DownloadButton = DownloadButton;
|
|
36098
|
-
exports.DownloadRing = index$7;
|
|
36099
|
-
exports.Dropzone = index$9;
|
|
36100
|
-
exports.IbanInput = IbanInput;
|
|
36101
|
-
exports.InfoCard = index$2;
|
|
36102
|
-
exports.Input = Input;
|
|
36103
|
-
exports.Markdown = Markdown;
|
|
36104
|
-
exports.MultiDropzone = index$8;
|
|
36105
|
-
exports.RegularModal = RegularModal;
|
|
36106
|
-
exports.SegmentedControl = SegmentedControl;
|
|
36107
|
-
exports.SignaturePad = Signature;
|
|
36108
|
-
exports.TableInfoButton = TableInfoButton;
|
|
36109
|
-
exports.TableRating = TableRating;
|
|
36110
|
-
exports.TableRowHeader = TableRowHeader;
|
|
36111
|
-
exports.TableTrueFalse = TableTrueFalse;
|
|
36072
|
+
export { AutoSuggestInput, index$1 as AutoSuggestMultiSelect, AutoCompleteAddress as AutocompleteAddress, BottomModal, index$6 as BottomOrRegularModal, Button, CardButton, index$4 as CardWithLeftIcon, index$3 as CardWithTopIcon, index$5 as CardWithTopLeftIcon, Chip, ComparisonTable, CurrencyInput, DateSelector, DownloadButton, index$7 as DownloadRing, index$9 as Dropzone, IbanInput, index$2 as InfoCard, Input, Markdown, index$8 as MultiDropzone, RegularModal, SegmentedControl, Signature as SignaturePad, TableInfoButton, TableRating, TableRowHeader, TableTrueFalse };
|
|
36112
36073
|
//# sourceMappingURL=index.js.map
|