ordering-ui-admin-external 1.43.30 → 1.43.32
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/_bundles/{ordering-ui-admin.2175191dd9617085f573.js → ordering-ui-admin.395af03194f63ca488ce.js} +2 -2
- package/_modules/components/Delivery/DriverGroupSelectorHeader/index.js +14 -13
- package/_modules/components/Delivery/DriversGroupLogs/index.js +2 -75
- package/_modules/components/Delivery/DriversTimeDisplay/UserList.js +10 -18
- package/_modules/components/Delivery/DriversTimeDisplay/index.js +63 -16
- package/_modules/components/Delivery/DriversTimeDisplay/styles.js +7 -6
- package/_modules/components/Orders/DriverMultiSelector/index.js +46 -17
- package/_modules/components/Stores/BusinessDetails/index.js +4 -1
- package/_modules/components/Stores/BusinessLogs/index.js +185 -0
- package/_modules/components/Stores/BusinessLogs/styles.js +73 -0
- package/_modules/components/Stores/BusinessSummary/index.js +8 -7
- package/_modules/components/Stores/index.js +7 -0
- package/_modules/components/Users/UserFormDetails/index.js +48 -13
- package/_modules/components/Users/UserFormDetails/styles.js +8 -2
- package/_modules/index.js +6 -0
- package/_modules/styles/MultiSelect/index.js +56 -10
- package/_modules/styles/MultiSelect/styles.js +16 -5
- package/_modules/styles/Selects/index.js +62 -51
- package/_modules/utils/index.js +107 -30
- package/package.json +2 -2
- package/src/components/Delivery/DriverGroupSelectorHeader/index.js +21 -21
- package/src/components/Delivery/DriversGroupLogs/index.js +1 -32
- package/src/components/Delivery/DriversTimeDisplay/UserList.js +35 -41
- package/src/components/Delivery/DriversTimeDisplay/index.js +89 -34
- package/src/components/Delivery/DriversTimeDisplay/styles.js +22 -4
- package/src/components/Orders/DriverMultiSelector/index.js +46 -10
- package/src/components/Stores/BusinessDetails/index.js +6 -0
- package/src/components/Stores/BusinessLogs/index.js +304 -0
- package/src/components/Stores/BusinessLogs/styles.js +224 -0
- package/src/components/Stores/BusinessSummary/index.js +7 -5
- package/src/components/Stores/index.js +2 -0
- package/src/components/Users/UserFormDetails/index.js +32 -2
- package/src/components/Users/UserFormDetails/styles.js +26 -0
- package/src/index.js +2 -0
- package/src/styles/MultiSelect/index.js +104 -33
- package/src/styles/MultiSelect/styles.js +16 -1
- package/src/styles/Selects/index.js +14 -10
- package/src/utils/index.js +62 -29
- /package/_bundles/{ordering-ui-admin.2175191dd9617085f573.js.LICENSE.txt → ordering-ui-admin.395af03194f63ca488ce.js.LICENSE.txt} +0 -0
|
@@ -37,7 +37,17 @@ var MultiSelect = exports.MultiSelect = function MultiSelect(props) {
|
|
|
37
37
|
searchBarPlaceholder = props.searchBarPlaceholder,
|
|
38
38
|
searchBarIsCustomLayout = props.searchBarIsCustomLayout,
|
|
39
39
|
searchValue = props.searchValue,
|
|
40
|
-
handleChangeSearch = props.handleChangeSearch
|
|
40
|
+
handleChangeSearch = props.handleChangeSearch,
|
|
41
|
+
useTextStyle = props.useTextStyle,
|
|
42
|
+
textClassnames = props.textClassnames,
|
|
43
|
+
hideChevronIcon = props.hideChevronIcon,
|
|
44
|
+
andText = props.andText,
|
|
45
|
+
pagination = props.pagination,
|
|
46
|
+
handleChangePage = props.handleChangePage,
|
|
47
|
+
handleChangePageSize = props.handleChangePageSize,
|
|
48
|
+
useLazyPagination = props.useLazyPagination,
|
|
49
|
+
isLoading = props.isLoading,
|
|
50
|
+
optionsPosition = props.optionsPosition;
|
|
41
51
|
var _useState = (0, _react.useState)(false),
|
|
42
52
|
_useState2 = _slicedToArray(_useState, 2),
|
|
43
53
|
open = _useState2[0],
|
|
@@ -57,7 +67,7 @@ var MultiSelect = exports.MultiSelect = function MultiSelect(props) {
|
|
|
57
67
|
setOpen(!open);
|
|
58
68
|
};
|
|
59
69
|
var closeSelect = function closeSelect(e) {
|
|
60
|
-
if (open) {
|
|
70
|
+
if (open && !isLoading) {
|
|
61
71
|
var _dropdownReference$cu;
|
|
62
72
|
var outsideDropdown = !((_dropdownReference$cu = dropdownReference.current) !== null && _dropdownReference$cu !== void 0 && _dropdownReference$cu.contains(e.target));
|
|
63
73
|
if (outsideDropdown) {
|
|
@@ -70,7 +80,9 @@ var MultiSelect = exports.MultiSelect = function MultiSelect(props) {
|
|
|
70
80
|
var _defaultOption = options === null || options === void 0 ? void 0 : options.filter(function (option) {
|
|
71
81
|
return defaultValue.includes(option.value);
|
|
72
82
|
});
|
|
73
|
-
|
|
83
|
+
if (!(useLazyPagination && pagination)) {
|
|
84
|
+
setSelectedOptions(_defaultOption);
|
|
85
|
+
}
|
|
74
86
|
setValues(defaultValue);
|
|
75
87
|
}, [defaultValue, options, searchValue]);
|
|
76
88
|
(0, _react.useEffect)(function () {
|
|
@@ -83,6 +95,10 @@ var MultiSelect = exports.MultiSelect = function MultiSelect(props) {
|
|
|
83
95
|
return document.removeEventListener('click', closeSelect);
|
|
84
96
|
};
|
|
85
97
|
}, [open]);
|
|
98
|
+
var handlerChangePage = function handlerChangePage(page) {
|
|
99
|
+
setOpen(true);
|
|
100
|
+
handleChangePage(page);
|
|
101
|
+
};
|
|
86
102
|
var handleSelectOption = function handleSelectOption(option) {
|
|
87
103
|
if (option.value === null || option.value === 'default') return;
|
|
88
104
|
var _selectedOptions = _toConsumableArray(selectedOptions);
|
|
@@ -103,20 +119,43 @@ var MultiSelect = exports.MultiSelect = function MultiSelect(props) {
|
|
|
103
119
|
setValues(_values);
|
|
104
120
|
onChange && onChange(option.value);
|
|
105
121
|
};
|
|
122
|
+
var optionsTextFormatted = function optionsTextFormatted(selectedOption, index) {
|
|
123
|
+
if (index <= 2) {
|
|
124
|
+
return "".concat(selectedOption.showOnSelected || selectedOption.content).concat(index + 1 !== (selectedOptions === null || selectedOptions === void 0 ? void 0 : selectedOptions.length) && index <= 2 ? ', ' : ' ');
|
|
125
|
+
}
|
|
126
|
+
if (index + 1 === (selectedOptions === null || selectedOptions === void 0 ? void 0 : selectedOptions.length) && (selectedOptions === null || selectedOptions === void 0 ? void 0 : selectedOptions.length) >= 4) {
|
|
127
|
+
return "".concat(andText || 'And', " ").concat(index - 2, " +");
|
|
128
|
+
}
|
|
129
|
+
return null;
|
|
130
|
+
};
|
|
131
|
+
var filterFunction = function filterFunction(_, index) {
|
|
132
|
+
if (!pagination || useLazyPagination) return true;
|
|
133
|
+
var validation = (pagination === null || pagination === void 0 ? void 0 : pagination.currentPage) === 1 ? index < pagination.pageSize * pagination.currentPage : index >= pagination.pageSize * (pagination.currentPage - 1) && index < pagination.pageSize * pagination.currentPage;
|
|
134
|
+
return validation;
|
|
135
|
+
};
|
|
106
136
|
return /*#__PURE__*/_react.default.createElement(_Selects.Select, {
|
|
137
|
+
useTextStyle: useTextStyle,
|
|
107
138
|
className: className || 'multi-select'
|
|
108
139
|
}, selectedOptions.length === 0 ? /*#__PURE__*/_react.default.createElement(_Selects.Selected, {
|
|
140
|
+
useTextStyle: useTextStyle,
|
|
109
141
|
onClick: function onClick(e) {
|
|
110
142
|
return handleSelectClick(e);
|
|
111
143
|
}
|
|
112
|
-
},
|
|
144
|
+
}, useTextStyle ? /*#__PURE__*/_react.default.createElement(_Selects.Header, null, /*#__PURE__*/_react.default.createElement(_styles.TextFormatted, {
|
|
145
|
+
className: textClassnames
|
|
146
|
+
}, placeholder || '')) : /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, placeholder || ''), !hideChevronIcon && /*#__PURE__*/_react.default.createElement(_Selects.Chevron, null, /*#__PURE__*/_react.default.createElement(_EnChevronDown.default, null))) : /*#__PURE__*/_react.default.createElement(_Selects.Selected, {
|
|
113
147
|
onClick: function onClick(e) {
|
|
114
148
|
return handleSelectClick(e);
|
|
115
149
|
}
|
|
116
|
-
}, /*#__PURE__*/_react.default.createElement(_Selects.Header,
|
|
150
|
+
}, /*#__PURE__*/_react.default.createElement(_Selects.Header, {
|
|
151
|
+
useTextStyle: useTextStyle
|
|
152
|
+
}, selectedOptions.map(function (selectedOption, index) {
|
|
117
153
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, {
|
|
118
154
|
key: selectedOption.value
|
|
119
|
-
},
|
|
155
|
+
}, useTextStyle ? /*#__PURE__*/_react.default.createElement(_styles.TextFormatted, {
|
|
156
|
+
className: textClassnames,
|
|
157
|
+
primary: true
|
|
158
|
+
}, optionsTextFormatted(selectedOption, index)) : /*#__PURE__*/_react.default.createElement(_Selects.MultiSelectOption, null, selectedOption.showOnSelected || selectedOption.content, (selectedOption === null || selectedOption === void 0 ? void 0 : selectedOption.value) !== 'default' && /*#__PURE__*/_react.default.createElement(_Buttons.Button, {
|
|
120
159
|
circle: true,
|
|
121
160
|
outline: true,
|
|
122
161
|
color: "primary",
|
|
@@ -126,10 +165,11 @@ var MultiSelect = exports.MultiSelect = function MultiSelect(props) {
|
|
|
126
165
|
return onChange && onChange(selectedOption.value);
|
|
127
166
|
}
|
|
128
167
|
}, /*#__PURE__*/_react.default.createElement(_MdClose.default, null))));
|
|
129
|
-
})), /*#__PURE__*/_react.default.createElement(_Selects.Chevron, null, /*#__PURE__*/_react.default.createElement(_EnChevronDown.default, null))), open && options && /*#__PURE__*/_react.default.createElement(_Selects.Options, {
|
|
168
|
+
})), !hideChevronIcon && /*#__PURE__*/_react.default.createElement(_Selects.Chevron, null, /*#__PURE__*/_react.default.createElement(_EnChevronDown.default, null))), open && options && /*#__PURE__*/_react.default.createElement(_Selects.Options, {
|
|
130
169
|
isAbsolute: true,
|
|
131
|
-
position:
|
|
132
|
-
ref: dropdownReference
|
|
170
|
+
position: optionsPosition !== null && optionsPosition !== void 0 ? optionsPosition : 'right',
|
|
171
|
+
ref: dropdownReference,
|
|
172
|
+
minWidth: "330px"
|
|
133
173
|
}, isShowSearchBar && /*#__PURE__*/_react.default.createElement(_Selects.SearchBarWrapper, {
|
|
134
174
|
className: "search-bar-container"
|
|
135
175
|
}, /*#__PURE__*/_react.default.createElement(_Shared.SearchBar, {
|
|
@@ -141,7 +181,7 @@ var MultiSelect = exports.MultiSelect = function MultiSelect(props) {
|
|
|
141
181
|
})), /*#__PURE__*/_react.default.createElement(_Selects.OptionsInner, {
|
|
142
182
|
optionInnerMargin: props.optionInnerMargin,
|
|
143
183
|
optionInnerMaxHeight: props.optionInnerMaxHeight
|
|
144
|
-
}, options.map(function (option, i) {
|
|
184
|
+
}, options.filter(filterFunction).map(function (option, i) {
|
|
145
185
|
return /*#__PURE__*/_react.default.createElement(_Selects.MultiOption, {
|
|
146
186
|
key: i,
|
|
147
187
|
color: option.color,
|
|
@@ -150,5 +190,11 @@ var MultiSelect = exports.MultiSelect = function MultiSelect(props) {
|
|
|
150
190
|
},
|
|
151
191
|
optionBottomBorder: props.optionBottomBorder
|
|
152
192
|
}, option.value !== 'default' && /*#__PURE__*/_react.default.createElement(_styles.CheckBox, null, values.includes(option.value) ? /*#__PURE__*/_react.default.createElement(_reactBootstrapIcons.CheckSquareFill, null) : /*#__PURE__*/_react.default.createElement(_reactBootstrapIcons.Square, null)), option.content);
|
|
193
|
+
})), pagination && handleChangePageSize && handleChangePage && /*#__PURE__*/_react.default.createElement(_styles.PaginationWrapper, null, /*#__PURE__*/_react.default.createElement(_Shared.Pagination, {
|
|
194
|
+
currentPage: pagination === null || pagination === void 0 ? void 0 : pagination.currentPage,
|
|
195
|
+
totalPages: pagination === null || pagination === void 0 ? void 0 : pagination.totalPages,
|
|
196
|
+
handleChangePage: handlerChangePage,
|
|
197
|
+
handleChangePageSize: handleChangePageSize,
|
|
198
|
+
defaultPageSize: pagination === null || pagination === void 0 ? void 0 : pagination.pageSize
|
|
153
199
|
}))));
|
|
154
200
|
};
|
|
@@ -1,13 +1,24 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
|
|
3
4
|
Object.defineProperty(exports, "__esModule", {
|
|
4
5
|
value: true
|
|
5
6
|
});
|
|
6
|
-
exports.CheckBox = void 0;
|
|
7
|
-
var _styledComponents =
|
|
8
|
-
var _templateObject;
|
|
9
|
-
function
|
|
7
|
+
exports.TextFormatted = exports.PaginationWrapper = exports.CheckBox = void 0;
|
|
8
|
+
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
9
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4;
|
|
10
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
11
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
10
12
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
11
13
|
var CheckBox = exports.CheckBox = _styledComponents.default.div(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n color: ", ";\n display: flex;\n svg {\n font-size: 16px;\n }\n"])), function (props) {
|
|
12
14
|
return props.theme.colors.primary;
|
|
13
|
-
});
|
|
15
|
+
});
|
|
16
|
+
var TextFormatted = exports.TextFormatted = _styledComponents.default.span(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n ", "\n\n div {\n font-size: 14px;\n color: ", ";\n }\n"])), function (_ref) {
|
|
17
|
+
var _theme$colors;
|
|
18
|
+
var primary = _ref.primary,
|
|
19
|
+
theme = _ref.theme;
|
|
20
|
+
return primary && (0, _styledComponents.css)(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n color: ", ";\n "])), theme === null || theme === void 0 || (_theme$colors = theme.colors) === null || _theme$colors === void 0 ? void 0 : _theme$colors.primary);
|
|
21
|
+
}, function (props) {
|
|
22
|
+
return props.theme.colors.primary;
|
|
23
|
+
});
|
|
24
|
+
var PaginationWrapper = exports.PaginationWrapper = _styledComponents.default.div(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n margin: 20px;\n"])));
|
|
@@ -7,7 +7,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.Selected = exports.SelectImage = exports.Select = exports.SearchBarWrapper = exports.OptionsInner = exports.Options = exports.Option = exports.MultiSelectOption = exports.MultiOption = exports.Header = exports.FunctionalityContainer = exports.Chevron = void 0;
|
|
8
8
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
9
9
|
var _polished = require("polished");
|
|
10
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18, _templateObject19, _templateObject20, _templateObject21, _templateObject22, _templateObject23, _templateObject24, _templateObject25, _templateObject26, _templateObject27, _templateObject28, _templateObject29, _templateObject30, _templateObject31, _templateObject32, _templateObject33, _templateObject34, _templateObject35, _templateObject36, _templateObject37, _templateObject38;
|
|
10
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18, _templateObject19, _templateObject20, _templateObject21, _templateObject22, _templateObject23, _templateObject24, _templateObject25, _templateObject26, _templateObject27, _templateObject28, _templateObject29, _templateObject30, _templateObject31, _templateObject32, _templateObject33, _templateObject34, _templateObject35, _templateObject36, _templateObject37, _templateObject38, _templateObject39, _templateObject40;
|
|
11
11
|
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
12
12
|
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
13
13
|
function _taggedTemplateLiteral(strings, raw) { if (!raw) { raw = strings.slice(0); } return Object.freeze(Object.defineProperties(strings, { raw: { value: Object.freeze(raw) } })); }
|
|
@@ -41,91 +41,102 @@ var Option = exports.Option = _styledComponents.default.div(_templateObject || (
|
|
|
41
41
|
var color = _ref6.color;
|
|
42
42
|
return color === 'primary' && (0, _styledComponents.css)(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n color: #C3C3C3;\n "])));
|
|
43
43
|
});
|
|
44
|
-
var Options = exports.Options = _styledComponents.default.div(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["\n min-width:
|
|
44
|
+
var Options = exports.Options = _styledComponents.default.div(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["\n min-width: ", ";\n background: ", ";\n z-index: 10000;\n border-width: 1px;\n border-style: solid;\n border-color: #E9ECEF;\n border-radius: 7.6px;\n overflow: hidden;\n\n ", "\n ", "\n\n ", "\n"])), function (_ref7) {
|
|
45
|
+
var minWidth = _ref7.minWidth;
|
|
46
|
+
return minWidth || '100%';
|
|
47
|
+
}, function (props) {
|
|
45
48
|
var _props$theme$colors;
|
|
46
49
|
return ((_props$theme$colors = props.theme.colors) === null || _props$theme$colors === void 0 ? void 0 : _props$theme$colors.backgroundPage) || '#FFF';
|
|
47
|
-
}, function (
|
|
48
|
-
var position =
|
|
50
|
+
}, function (_ref8) {
|
|
51
|
+
var position = _ref8.position;
|
|
49
52
|
return (position === null || position === void 0 ? void 0 : position.toLowerCase()) === 'left' && (0, _styledComponents.css)(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["\n left: 0;\n margin-left: -1px;\n ", "\n "])), function (props) {
|
|
50
53
|
var _props$theme2;
|
|
51
54
|
return ((_props$theme2 = props.theme) === null || _props$theme2 === void 0 ? void 0 : _props$theme2.rtl) && (0, _styledComponents.css)(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["\n margin-right: -1px;\n margin-left: 0px;\n right: 0;\n left: initial;\n "])));
|
|
52
55
|
});
|
|
53
|
-
}, function (
|
|
54
|
-
var position =
|
|
56
|
+
}, function (_ref9) {
|
|
57
|
+
var position = _ref9.position;
|
|
55
58
|
return (position === null || position === void 0 ? void 0 : position.toLowerCase()) === 'right' && (0, _styledComponents.css)(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["\n right: 0;\n margin-right: -1px;\n ", "\n "])), function (props) {
|
|
56
59
|
var _props$theme3;
|
|
57
60
|
return ((_props$theme3 = props.theme) === null || _props$theme3 === void 0 ? void 0 : _props$theme3.rtl) && (0, _styledComponents.css)(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["\n margin-left: -1px;\n margin-right: 0px;\n left: 0;\n right: initial;\n "])));
|
|
58
61
|
});
|
|
59
|
-
}, function (
|
|
60
|
-
var isAbsolute =
|
|
62
|
+
}, function (_ref10) {
|
|
63
|
+
var isAbsolute = _ref10.isAbsolute;
|
|
61
64
|
return isAbsolute && (0, _styledComponents.css)(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["\n position: absolute;\n margin-top: 7px;\n "])));
|
|
62
65
|
});
|
|
63
|
-
var OptionsInner = exports.OptionsInner = _styledComponents.default.div(_templateObject15 || (_templateObject15 = _taggedTemplateLiteral(["\n overflow-x: hidden;\n margin: ", ";\n max-height: ", ";\n overscroll-behavior: contain;\n"])), function (
|
|
64
|
-
var optionInnerMargin =
|
|
66
|
+
var OptionsInner = exports.OptionsInner = _styledComponents.default.div(_templateObject15 || (_templateObject15 = _taggedTemplateLiteral(["\n overflow-x: hidden;\n margin: ", ";\n max-height: ", ";\n overscroll-behavior: contain;\n"])), function (_ref11) {
|
|
67
|
+
var optionInnerMargin = _ref11.optionInnerMargin;
|
|
65
68
|
return optionInnerMargin;
|
|
66
|
-
}, function (
|
|
67
|
-
var optionInnerMaxHeight =
|
|
69
|
+
}, function (_ref12) {
|
|
70
|
+
var optionInnerMaxHeight = _ref12.optionInnerMaxHeight;
|
|
68
71
|
return optionInnerMaxHeight;
|
|
69
72
|
});
|
|
70
|
-
var Selected = exports.Selected = _styledComponents.default.div(_templateObject16 || (_templateObject16 = _taggedTemplateLiteral(["\n
|
|
71
|
-
var
|
|
72
|
-
return
|
|
73
|
+
var Selected = exports.Selected = _styledComponents.default.div(_templateObject16 || (_templateObject16 = _taggedTemplateLiteral(["\n ", "\n cursor: pointer;\n position: relative;\n display: flex;\n align-items: center;\n justify-content: space-between;\n flex: 1;\n\n -webkit-touch-callout: none;\n -webkit-user-select: none;\n -khtml-user-select: none;\n -moz-user-select: none;\n -ms-user-select: none;\n user-select: none;\n z-index: 11;\n\n p {\n margin: 0px;\n }\n\n @media (max-width: 380px) {\n padding-left: 9px;\n padding-right: 9px;\n font-size: 13px;\n }\n\n ", "\n"])), function (_ref13) {
|
|
74
|
+
var useTextStyle = _ref13.useTextStyle;
|
|
75
|
+
return !useTextStyle && (0, _styledComponents.css)(_templateObject17 || (_templateObject17 = _taggedTemplateLiteral(["\n padding-left: 15px;\n padding-right: 15px;\n "])));
|
|
76
|
+
}, function (_ref14) {
|
|
77
|
+
var isDisabled = _ref14.isDisabled;
|
|
78
|
+
return isDisabled && (0, _styledComponents.css)(_templateObject18 || (_templateObject18 = _taggedTemplateLiteral(["\n pointer-events: none;\n "])));
|
|
73
79
|
});
|
|
74
|
-
var Select = exports.Select = _styledComponents.default.div(
|
|
75
|
-
return props.
|
|
76
|
-
}, function (
|
|
77
|
-
|
|
78
|
-
|
|
80
|
+
var Select = exports.Select = _styledComponents.default.div(_templateObject19 || (_templateObject19 = _taggedTemplateLiteral(["\n display: inline-block;\n color: #344050;\n position: relative;\n\n ", "\n ", "\n\n ", "\n\n ", "\n"])), function (props) {
|
|
81
|
+
return !props.useTextStyle && (0, _styledComponents.css)(_templateObject20 || (_templateObject20 = _taggedTemplateLiteral(["\n border-radius: 7.6px;\n line-height: 34px;\n border-width: 1px;\n border-style: solid;\n border-color: #DEE2E6;\n "])));
|
|
82
|
+
}, function (props) {
|
|
83
|
+
return props.open && (0, _styledComponents.css)(_templateObject21 || (_templateObject21 = _taggedTemplateLiteral(["\n background-color: ", ";\n "])), (0, _polished.darken)(0.07, '#CCC'));
|
|
84
|
+
}, function (_ref15) {
|
|
85
|
+
var type = _ref15.type;
|
|
86
|
+
return type === 'primary' && (0, _styledComponents.css)(_templateObject22 || (_templateObject22 = _taggedTemplateLiteral(["\n background: ", ";\n color: ", ";\n border-color: ", ";\n border-radius: 7.6px;\n "])), function (props) {
|
|
79
87
|
return props.theme.colors.btnPrimary;
|
|
80
88
|
}, function (props) {
|
|
81
89
|
return props.theme.colors.btnPrimaryContrast;
|
|
82
90
|
}, function (props) {
|
|
83
91
|
return props.theme.colors.btnPrimary;
|
|
84
92
|
});
|
|
85
|
-
}, function (
|
|
86
|
-
var isDisabled =
|
|
87
|
-
return isDisabled && (0, _styledComponents.css)(
|
|
93
|
+
}, function (_ref16) {
|
|
94
|
+
var isDisabled = _ref16.isDisabled;
|
|
95
|
+
return isDisabled && (0, _styledComponents.css)(_templateObject23 || (_templateObject23 = _taggedTemplateLiteral(["\n cursor: not-allowed;\n background-color: ", " !important;\n "])), function (props) {
|
|
88
96
|
return props.theme.colors.disabled;
|
|
89
97
|
});
|
|
90
98
|
});
|
|
91
|
-
var Chevron = exports.Chevron = _styledComponents.default.div(
|
|
99
|
+
var Chevron = exports.Chevron = _styledComponents.default.div(_templateObject24 || (_templateObject24 = _taggedTemplateLiteral(["\n font-size: 14px;\n display: flex;\n align-items: center;\n margin-left: 5px;\n ", "\n"])), function (props) {
|
|
92
100
|
var _props$theme4;
|
|
93
|
-
return ((_props$theme4 = props.theme) === null || _props$theme4 === void 0 ? void 0 : _props$theme4.rtl) && (0, _styledComponents.css)(
|
|
101
|
+
return ((_props$theme4 = props.theme) === null || _props$theme4 === void 0 ? void 0 : _props$theme4.rtl) && (0, _styledComponents.css)(_templateObject25 || (_templateObject25 = _taggedTemplateLiteral(["\n margin-right: 5px;\n margin-left: 0px;\n "])));
|
|
94
102
|
});
|
|
95
|
-
var Header = exports.Header = _styledComponents.default.div(
|
|
96
|
-
var
|
|
103
|
+
var Header = exports.Header = _styledComponents.default.div(_templateObject26 || (_templateObject26 = _taggedTemplateLiteral(["\n flex: 1;\n overflow: auto;\n white-space: ", ";\n display: flex;\n align-items: center;\n"])), function (_ref17) {
|
|
104
|
+
var useTextStyle = _ref17.useTextStyle;
|
|
105
|
+
return useTextStyle ? 'pre-wrap' : 'nowrap';
|
|
106
|
+
});
|
|
107
|
+
var SelectImage = exports.SelectImage = _styledComponents.default.div(_templateObject27 || (_templateObject27 = _taggedTemplateLiteral(["\n width: 28px;\n height: 28px;\n border-radius: 1000px;\n margin-left: 5px;\n overflow: hidden;\n\n ", "\n\n img {\n width: 100%;\n height: 100%;\n }\n"])), function (props) {
|
|
97
108
|
var _props$theme5;
|
|
98
|
-
return ((_props$theme5 = props.theme) === null || _props$theme5 === void 0 ? void 0 : _props$theme5.rtl) && (0, _styledComponents.css)(
|
|
109
|
+
return ((_props$theme5 = props.theme) === null || _props$theme5 === void 0 ? void 0 : _props$theme5.rtl) && (0, _styledComponents.css)(_templateObject28 || (_templateObject28 = _taggedTemplateLiteral(["\n margin-left: 5px;\n margin-right: 0;\n "])));
|
|
99
110
|
});
|
|
100
|
-
var MultiSelectOption = exports.MultiSelectOption = _styledComponents.default.div(
|
|
111
|
+
var MultiSelectOption = exports.MultiSelectOption = _styledComponents.default.div(_templateObject29 || (_templateObject29 = _taggedTemplateLiteral(["\n position: relative;\n button {\n display: flex;\n align-items: center;\n justify-content: center;\n position: absolute;\n background: ", ";\n width: 20px;\n height: 20px;\n transform: translate(100%, -50%);\n top: 11px;\n right: 15px;\n }\n"])), function (props) {
|
|
101
112
|
var _props$theme$colors2;
|
|
102
113
|
return ((_props$theme$colors2 = props.theme.colors) === null || _props$theme$colors2 === void 0 ? void 0 : _props$theme$colors2.backgroundPage) || '#FFF';
|
|
103
114
|
});
|
|
104
|
-
var FunctionalityContainer = exports.FunctionalityContainer = _styledComponents.default.div(
|
|
105
|
-
return props.disabled && (0, _styledComponents.css)(
|
|
115
|
+
var FunctionalityContainer = exports.FunctionalityContainer = _styledComponents.default.div(_templateObject30 || (_templateObject30 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n svg{\n margin-left: 20px;\n ", "\n }\n"])), function (props) {
|
|
116
|
+
return props.disabled && (0, _styledComponents.css)(_templateObject31 || (_templateObject31 = _taggedTemplateLiteral(["\n opacity: 0.4;\n pointer-events: none;\n "])));
|
|
106
117
|
});
|
|
107
|
-
var SearchBarWrapper = exports.SearchBarWrapper = _styledComponents.default.div(
|
|
108
|
-
var MultiOption = exports.MultiOption = _styledComponents.default.div(
|
|
109
|
-
var minWidth =
|
|
118
|
+
var SearchBarWrapper = exports.SearchBarWrapper = _styledComponents.default.div(_templateObject32 || (_templateObject32 = _taggedTemplateLiteral(["\n padding: 5px 10px;\n width: 100%;\n > div {\n input {\n height: 42px;\n }\n }\n"])));
|
|
119
|
+
var MultiOption = exports.MultiOption = _styledComponents.default.div(_templateObject33 || (_templateObject33 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n padding: 5px 10px;\n box-sizing: border-box;\n min-width: ", ";\n color: #333;\n cursor: pointer;\n\n ", "\n\n ", "\n\n ", "\n\n &:hover {\n background-color: ", ";\n }\n\n ", "\n\n svg {\n vertical-align: text-top;\n }\n\n ", "\n\n ", "\n"])), function (_ref18) {
|
|
120
|
+
var minWidth = _ref18.minWidth;
|
|
110
121
|
return minWidth || '100px';
|
|
111
|
-
}, function (_ref16) {
|
|
112
|
-
var disabled = _ref16.disabled;
|
|
113
|
-
return disabled && (0, _styledComponents.css)(_templateObject32 || (_templateObject32 = _taggedTemplateLiteral(["\n cursor: no-drop;\n opacity: 0.6;\n "])));
|
|
114
|
-
}, function (_ref17) {
|
|
115
|
-
var showDisable = _ref17.showDisable;
|
|
116
|
-
return showDisable && (0, _styledComponents.css)(_templateObject33 || (_templateObject33 = _taggedTemplateLiteral(["\n display: none;\n "])));
|
|
117
|
-
}, function (_ref18) {
|
|
118
|
-
var optionBottomBorder = _ref18.optionBottomBorder;
|
|
119
|
-
return optionBottomBorder && (0, _styledComponents.css)(_templateObject34 || (_templateObject34 = _taggedTemplateLiteral(["\n border-bottom: 1px solid #D8D8D8;\n "])));
|
|
120
|
-
}, (0, _polished.darken)(0.03, '#fafafa'), function (props) {
|
|
121
|
-
return props.selected && (0, _styledComponents.css)(_templateObject35 || (_templateObject35 = _taggedTemplateLiteral(["\n background-color: ", ";\n \n &:hover {\n background-color: ", ";\n }\n "])), (0, _polished.darken)(0.07, '#fafafa'), (0, _polished.darken)(0.07, '#fafafa'));
|
|
122
122
|
}, function (_ref19) {
|
|
123
|
-
var
|
|
124
|
-
return
|
|
123
|
+
var disabled = _ref19.disabled;
|
|
124
|
+
return disabled && (0, _styledComponents.css)(_templateObject34 || (_templateObject34 = _taggedTemplateLiteral(["\n cursor: no-drop;\n opacity: 0.6;\n "])));
|
|
125
|
+
}, function (_ref20) {
|
|
126
|
+
var showDisable = _ref20.showDisable;
|
|
127
|
+
return showDisable && (0, _styledComponents.css)(_templateObject35 || (_templateObject35 = _taggedTemplateLiteral(["\n display: none;\n "])));
|
|
128
|
+
}, function (_ref21) {
|
|
129
|
+
var optionBottomBorder = _ref21.optionBottomBorder;
|
|
130
|
+
return optionBottomBorder && (0, _styledComponents.css)(_templateObject36 || (_templateObject36 = _taggedTemplateLiteral(["\n border-bottom: 1px solid #D8D8D8;\n "])));
|
|
131
|
+
}, (0, _polished.darken)(0.03, '#fafafa'), function (props) {
|
|
132
|
+
return props.selected && (0, _styledComponents.css)(_templateObject37 || (_templateObject37 = _taggedTemplateLiteral(["\n background-color: ", ";\n\n &:hover {\n background-color: ", ";\n }\n "])), (0, _polished.darken)(0.07, '#fafafa'), (0, _polished.darken)(0.07, '#fafafa'));
|
|
133
|
+
}, function (_ref22) {
|
|
134
|
+
var withIcons = _ref22.withIcons;
|
|
135
|
+
return withIcons && (0, _styledComponents.css)(_templateObject38 || (_templateObject38 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n justify-content: flex-start;\n svg {\n margin-right: 3px;\n ", "\n }\n "])), function (props) {
|
|
125
136
|
var _props$theme6;
|
|
126
|
-
return ((_props$theme6 = props.theme) === null || _props$theme6 === void 0 ? void 0 : _props$theme6.rtl) && (0, _styledComponents.css)(
|
|
137
|
+
return ((_props$theme6 = props.theme) === null || _props$theme6 === void 0 ? void 0 : _props$theme6.rtl) && (0, _styledComponents.css)(_templateObject39 || (_templateObject39 = _taggedTemplateLiteral(["\n margin-left: 3px;\n margin-right: 0px;\n "])));
|
|
127
138
|
});
|
|
128
|
-
}, function (
|
|
129
|
-
var color =
|
|
130
|
-
return color === 'primary' && (0, _styledComponents.css)(
|
|
139
|
+
}, function (_ref23) {
|
|
140
|
+
var color = _ref23.color;
|
|
141
|
+
return color === 'primary' && (0, _styledComponents.css)(_templateObject40 || (_templateObject40 = _taggedTemplateLiteral(["\n color: #C3C3C3;\n "])));
|
|
131
142
|
});
|
package/_modules/utils/index.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.widgetURL = exports.verifyDecimals = exports.stringToSlug = exports.sortInputFields = exports.shape = exports.setStorageItem = exports.scrollTo = exports.ribbonValues = exports.reviewCommentList = exports.removeStorageItem = exports.removeQueryToUrl = exports.queryStringToObject = exports.orderStatus = exports.orderRejectCommentList = exports.optimizeImage = exports.getUniqueId = exports.getStorageItem = exports.getStarWidth = exports.getSeconds = exports.getOrderStatus = exports.getOrderStatuPickUp = exports.getMinutes = exports.getLocale = exports.getIconCard = exports.getHours = exports.getCurrenySymbol = exports.getCurrentDiffDays = exports.getAgoMinutes = exports.formatUrlVideo = exports.formatSeconds = exports.firstLetterCapital = exports.findExitingCountryPhoneCode = exports.findExitingCode = exports.fieldsToSort = exports.disableReasons = exports.convertHoursToMinutes = exports.convertHMS = exports.checkValidUrlFormat = exports.checkSiteUrl = exports.checkPreSiteUrl = exports.capitalize = exports.bytesConverter = exports.addQueryToUrl = exports.TwentyFourHours = exports.TwelveHours = exports.DriverTipsOptions = void 0;
|
|
6
|
+
exports.widgetURL = exports.verifyDecimals = exports.stringToSlug = exports.sortInputFields = exports.shape = exports.setStorageItem = exports.scrollTo = exports.ribbonValues = exports.reviewCommentList = exports.removeStorageItem = exports.removeQueryToUrl = exports.queryStringToObject = exports.orderStatus = exports.orderRejectCommentList = exports.optimizeImage = exports.getUniqueId = exports.getStorageItem = exports.getStarWidth = exports.getSeconds = exports.getOrderStatus = exports.getOrderStatuPickUp = exports.getMinutes = exports.getLocale = exports.getIconCard = exports.getHours = exports.getCurrenySymbol = exports.getCurrentDiffDays = exports.getAttributeName = exports.getAgoMinutes = exports.formatUrlVideo = exports.formatSeconds = exports.firstLetterCapital = exports.findExitingCountryPhoneCode = exports.findExitingCode = exports.fieldsToSort = exports.disableReasons = exports.convertHoursToMinutes = exports.convertHMS = exports.checkValidUrlFormat = exports.checkSiteUrl = exports.checkPreSiteUrl = exports.capitalize = exports.bytesConverter = exports.addQueryToUrl = exports.TwentyFourHours = exports.TwelveHours = exports.DriverTipsOptions = void 0;
|
|
7
7
|
var _react = _interopRequireDefault(require("react"));
|
|
8
8
|
var _FaCcMastercard = _interopRequireDefault(require("@meronex/icons/fa/FaCcMastercard"));
|
|
9
9
|
var _FaCcVisa = _interopRequireDefault(require("@meronex/icons/fa/FaCcVisa"));
|
|
@@ -437,104 +437,104 @@ var reviewCommentList = exports.reviewCommentList = function reviewCommentList(t
|
|
|
437
437
|
var reviews = {
|
|
438
438
|
1: {
|
|
439
439
|
1: {
|
|
440
|
-
title: t('CUSTOMER_QUICK_COMMENT_TITLE_1',
|
|
440
|
+
title: t('CUSTOMER_QUICK_COMMENT_TITLE_1', 'What went wrong?'),
|
|
441
441
|
list: [{
|
|
442
442
|
key: 0,
|
|
443
|
-
content: t('CUSTOMER_QUICK_COMMENT_1_0',
|
|
443
|
+
content: t('CUSTOMER_QUICK_COMMENT_1_0', 'Not handled with care')
|
|
444
444
|
}, {
|
|
445
445
|
key: 1,
|
|
446
|
-
content: t('CUSTOMER_QUICK_COMMENT_1_1',
|
|
446
|
+
content: t('CUSTOMER_QUICK_COMMENT_1_1', 'Poor communication')
|
|
447
447
|
}, {
|
|
448
448
|
key: 2,
|
|
449
|
-
content: t('CUSTOMER_QUICK_COMMENT_1_2',
|
|
449
|
+
content: t('CUSTOMER_QUICK_COMMENT_1_2', 'COVID-19 issue')
|
|
450
450
|
}, {
|
|
451
451
|
key: 3,
|
|
452
452
|
content: t('CUSTOMER_QUICK_COMMENT_1_3', "Didn't follow instructions")
|
|
453
453
|
}, {
|
|
454
454
|
key: 4,
|
|
455
|
-
content: t('CUSTOMER_QUICK_COMMENT_1_4',
|
|
455
|
+
content: t('CUSTOMER_QUICK_COMMENT_1_4', 'Rude')
|
|
456
456
|
}, {
|
|
457
457
|
key: 5,
|
|
458
|
-
content: t('CUSTOMER_QUICK_COMMENT_1_5',
|
|
458
|
+
content: t('CUSTOMER_QUICK_COMMENT_1_5', 'Not on-time')
|
|
459
459
|
}]
|
|
460
460
|
},
|
|
461
461
|
2: {
|
|
462
|
-
title: t('CUSTOMER_QUICK_COMMENT_TITLE_2',
|
|
462
|
+
title: t('CUSTOMER_QUICK_COMMENT_TITLE_2', 'What went wrong?'),
|
|
463
463
|
list: [{
|
|
464
464
|
key: 0,
|
|
465
|
-
content: t('CUSTOMER_QUICK_COMMENT_2_0',
|
|
465
|
+
content: t('CUSTOMER_QUICK_COMMENT_2_0', 'Not handled with care')
|
|
466
466
|
}, {
|
|
467
467
|
key: 1,
|
|
468
|
-
content: t('CUSTOMER_QUICK_COMMENT_2_1',
|
|
468
|
+
content: t('CUSTOMER_QUICK_COMMENT_2_1', 'Poor communication')
|
|
469
469
|
}, {
|
|
470
470
|
key: 2,
|
|
471
|
-
content: t('CUSTOMER_QUICK_COMMENT_2_2',
|
|
471
|
+
content: t('CUSTOMER_QUICK_COMMENT_2_2', 'COVID-19 issue')
|
|
472
472
|
}, {
|
|
473
473
|
key: 3,
|
|
474
474
|
content: t('CUSTOMER_QUICK_COMMENT_2_3', "Didn't follow instructions")
|
|
475
475
|
}, {
|
|
476
476
|
key: 4,
|
|
477
|
-
content: t('CUSTOMER_QUICK_COMMENT_2_4',
|
|
477
|
+
content: t('CUSTOMER_QUICK_COMMENT_2_4', 'Rude')
|
|
478
478
|
}, {
|
|
479
479
|
key: 5,
|
|
480
|
-
content: t('CUSTOMER_QUICK_COMMENT_2_5',
|
|
480
|
+
content: t('CUSTOMER_QUICK_COMMENT_2_5', 'Not on-time')
|
|
481
481
|
}]
|
|
482
482
|
},
|
|
483
483
|
3: {
|
|
484
|
-
title: t('CUSTOMER_QUICK_COMMENT_TITLE_3',
|
|
484
|
+
title: t('CUSTOMER_QUICK_COMMENT_TITLE_3', 'What could have been better?'),
|
|
485
485
|
list: [{
|
|
486
486
|
key: 0,
|
|
487
|
-
content: t('CUSTOMER_QUICK_COMMENT_3_0',
|
|
487
|
+
content: t('CUSTOMER_QUICK_COMMENT_3_0', 'Not handled with care')
|
|
488
488
|
}, {
|
|
489
489
|
key: 1,
|
|
490
|
-
content: t('CUSTOMER_QUICK_COMMENT_3_1',
|
|
490
|
+
content: t('CUSTOMER_QUICK_COMMENT_3_1', 'Poor communication')
|
|
491
491
|
}, {
|
|
492
492
|
key: 2,
|
|
493
|
-
content: t('CUSTOMER_QUICK_COMMENT_3_2',
|
|
493
|
+
content: t('CUSTOMER_QUICK_COMMENT_3_2', 'COVID-19 issue')
|
|
494
494
|
}, {
|
|
495
495
|
key: 3,
|
|
496
496
|
content: t('CUSTOMER_QUICK_COMMENT_3_3', "Didn't follow instructions")
|
|
497
497
|
}, {
|
|
498
498
|
key: 4,
|
|
499
|
-
content: t('CUSTOMER_QUICK_COMMENT_3_4',
|
|
499
|
+
content: t('CUSTOMER_QUICK_COMMENT_3_4', 'Rude')
|
|
500
500
|
}, {
|
|
501
501
|
key: 5,
|
|
502
|
-
content: t('CUSTOMER_QUICK_COMMENT_3_5',
|
|
502
|
+
content: t('CUSTOMER_QUICK_COMMENT_3_5', 'Not on-time')
|
|
503
503
|
}]
|
|
504
504
|
},
|
|
505
505
|
4: {
|
|
506
|
-
title: t('CUSTOMER_QUICK_COMMENT_TITLE_4',
|
|
506
|
+
title: t('CUSTOMER_QUICK_COMMENT_TITLE_4', ' Tell us more'),
|
|
507
507
|
list: [{
|
|
508
508
|
key: 0,
|
|
509
|
-
content: t('CUSTOMER_QUICK_COMMENT_4_0',
|
|
509
|
+
content: t('CUSTOMER_QUICK_COMMENT_4_0', 'Not handled with care')
|
|
510
510
|
}, {
|
|
511
511
|
key: 1,
|
|
512
|
-
content: t('CUSTOMER_QUICK_COMMENT_4_1',
|
|
512
|
+
content: t('CUSTOMER_QUICK_COMMENT_4_1', 'Poor communication')
|
|
513
513
|
}, {
|
|
514
514
|
key: 2,
|
|
515
|
-
content: t('CUSTOMER_QUICK_COMMENT_4_2',
|
|
515
|
+
content: t('CUSTOMER_QUICK_COMMENT_4_2', 'COVID-19 issue')
|
|
516
516
|
}, {
|
|
517
517
|
key: 3,
|
|
518
518
|
content: t('CUSTOMER_QUICK_COMMENT_4_3', "Didn't follow instructions")
|
|
519
519
|
}, {
|
|
520
520
|
key: 4,
|
|
521
|
-
content: t('CUSTOMER_QUICK_COMMENT_4_4',
|
|
521
|
+
content: t('CUSTOMER_QUICK_COMMENT_4_4', 'Rude')
|
|
522
522
|
}, {
|
|
523
523
|
key: 5,
|
|
524
|
-
content: t('CUSTOMER_QUICK_COMMENT_4_5',
|
|
524
|
+
content: t('CUSTOMER_QUICK_COMMENT_4_5', 'Not on-time')
|
|
525
525
|
}]
|
|
526
526
|
},
|
|
527
527
|
5: {
|
|
528
|
-
title: t('CUSTOMER_QUICK_COMMENT_TITLE_5',
|
|
528
|
+
title: t('CUSTOMER_QUICK_COMMENT_TITLE_5', 'What went well?'),
|
|
529
529
|
list: [{
|
|
530
530
|
key: 0,
|
|
531
|
-
content: t('CUSTOMER_QUICK_COMMENT_5_0',
|
|
531
|
+
content: t('CUSTOMER_QUICK_COMMENT_5_0', 'Good communication')
|
|
532
532
|
}, {
|
|
533
533
|
key: 1,
|
|
534
|
-
content: t('CUSTOMER_QUICK_COMMENT_5_1',
|
|
534
|
+
content: t('CUSTOMER_QUICK_COMMENT_5_1', 'Friendly')
|
|
535
535
|
}, {
|
|
536
536
|
key: 2,
|
|
537
|
-
content: t('CUSTOMER_QUICK_COMMENT_5_2',
|
|
537
|
+
content: t('CUSTOMER_QUICK_COMMENT_5_2', 'Above and beyond')
|
|
538
538
|
}]
|
|
539
539
|
}
|
|
540
540
|
}
|
|
@@ -895,4 +895,81 @@ var disableReasons = exports.disableReasons = function disableReasons() {
|
|
|
895
895
|
return disableReasonDictionary;
|
|
896
896
|
};
|
|
897
897
|
var TwelveHours = exports.TwelveHours = ['12:00 AM', '01:00 AM', '02:00 AM', '03:00 AM', '04:00 AM', '05:00 AM', '06:00 AM', '07:00 AM', '08:00 AM', '09:00 AM', '10:00 AM', '11:00 AM', '12:00 PM', '01:00 PM', '02:00 PM', '03:00 PM', '04:00 PM', '05:00 PM', '06:00 PM', '07:00 PM', '08:00 PM', '09:00 PM', '10:00 PM', '11:00 PM'];
|
|
898
|
-
var TwentyFourHours = exports.TwentyFourHours = ['00:00', '01:00', '02:00', '03:00', '04:00', '05:00', '06:00', '07:00', '08:00', '09:00', '10:00', '11:00', '12:00', '13:00', '14:00', '15:00', '16:00', '17:00', '18:00', '19:00', '20:00', '21:00', '22:00', '23:00'];
|
|
898
|
+
var TwentyFourHours = exports.TwentyFourHours = ['00:00', '01:00', '02:00', '03:00', '04:00', '05:00', '06:00', '07:00', '08:00', '09:00', '10:00', '11:00', '12:00', '13:00', '14:00', '15:00', '16:00', '17:00', '18:00', '19:00', '20:00', '21:00', '22:00', '23:00'];
|
|
899
|
+
var getAttributeName = exports.getAttributeName = function getAttributeName(key) {
|
|
900
|
+
var _useLanguage5 = (0, _orderingComponentsAdminExternal.useLanguage)(),
|
|
901
|
+
_useLanguage6 = _slicedToArray(_useLanguage5, 2),
|
|
902
|
+
t = _useLanguage6[1];
|
|
903
|
+
var attributes = [{
|
|
904
|
+
key: 'autoassign_amount_drivers',
|
|
905
|
+
content: t('AUTO_ASSIGN_GROUP_ORDERS_TO_DRIVERS', 'Auto assign the order of group to this amount of drivers')
|
|
906
|
+
}, {
|
|
907
|
+
key: 'orders_group_max_orders',
|
|
908
|
+
content: t('MAX_NUMBER_ORDERS', 'Maximum Number of Orders')
|
|
909
|
+
}, {
|
|
910
|
+
key: 'autoassign_autoaccept_by_driver',
|
|
911
|
+
content: t('ORDER_CONFIRMED_ACCEPTED_BY_DRIVER', 'Accepted by Driver')
|
|
912
|
+
}, {
|
|
913
|
+
key: 'orders_group_max_time_between',
|
|
914
|
+
content: t('MAX_ORDER_TIME_BETWEEN', 'Maximum time between orders in seconds')
|
|
915
|
+
}, {
|
|
916
|
+
key: 'orders_group_max_distance_between_pickup',
|
|
917
|
+
content: t('MAX_DISTANCE_BETWEEN_BUSINESS', 'Maximum distance between businesses in meters')
|
|
918
|
+
}, {
|
|
919
|
+
key: 'orders_group_max_distance_between_delivery',
|
|
920
|
+
content: t('MAX_DISTANCE_BETWEEN_DELIVERY', 'Maximum distance between deliveries in meters')
|
|
921
|
+
}, {
|
|
922
|
+
key: 'orders_group_use_maps_api',
|
|
923
|
+
content: t('USE_MAPS_API', 'Use maps api')
|
|
924
|
+
}, {
|
|
925
|
+
key: 'orders_group_max_time_between_pickup',
|
|
926
|
+
content: t('MAX_DISTANCE_BETWEEN_BUSINESS', 'Maximum distance between businesses in meters')
|
|
927
|
+
}, {
|
|
928
|
+
key: 'orders_group_max_time_between_delivery',
|
|
929
|
+
content: t('MAX_DISTANCE_BETWEEN_DELIVERY', 'Maximum distance between deliveries in meters')
|
|
930
|
+
}, {
|
|
931
|
+
key: 'autoassign_forced_assignment',
|
|
932
|
+
content: t('AUTO_ASSIGN_FORCED_ASSIGNMENT', 'Forced assignment')
|
|
933
|
+
}, {
|
|
934
|
+
key: 'autoassign_customer_max_distance_from_business',
|
|
935
|
+
content: t('MAX_CUSTOMER_DISTANCE_FROM_BUSINESS', 'Max distance between customer and business')
|
|
936
|
+
}, {
|
|
937
|
+
key: 'autoassign_initial_radius',
|
|
938
|
+
content: t('INITIAL_RADIUS', 'Initial radius in meters')
|
|
939
|
+
}, {
|
|
940
|
+
key: 'autoassign_increment_radius',
|
|
941
|
+
content: t('INCREMENT_RADIUS', 'Radius increase in meters')
|
|
942
|
+
}, {
|
|
943
|
+
key: 'autoassign_max_radius',
|
|
944
|
+
content: t('MAX_RADIUS', 'Maximum radius in meters')
|
|
945
|
+
}, {
|
|
946
|
+
key: 'autoassign_autoreject_time',
|
|
947
|
+
content: t('AUTO_REJECT_ORDER_GROUP_AFTER', 'Auto reject Orders After')
|
|
948
|
+
}, {
|
|
949
|
+
key: 'autoassign_max_orders',
|
|
950
|
+
content: t('MAX_AMOUNT_ORDERS_PER_DRIVER', 'Maximum amount of orders per drivers')
|
|
951
|
+
}, {
|
|
952
|
+
key: 'autoassign_max_in_pending',
|
|
953
|
+
content: t('ORDER_PENDING', 'Pending')
|
|
954
|
+
}, {
|
|
955
|
+
key: 'available',
|
|
956
|
+
content: t('AVAILABLE', 'Available')
|
|
957
|
+
}, {
|
|
958
|
+
key: 'enabled',
|
|
959
|
+
content: t('ENABLED', 'Enabled')
|
|
960
|
+
}, {
|
|
961
|
+
key: 'last_available_at',
|
|
962
|
+
content: t('LAST_AVAILABLE_AT', 'Last available at')
|
|
963
|
+
}, {
|
|
964
|
+
key: 'busy',
|
|
965
|
+
content: t('BUSY', 'Busy')
|
|
966
|
+
}];
|
|
967
|
+
var found = attributes.find(function (attribute) {
|
|
968
|
+
return attribute.key === key;
|
|
969
|
+
});
|
|
970
|
+
if (found) {
|
|
971
|
+
return found.content;
|
|
972
|
+
} else {
|
|
973
|
+
return key;
|
|
974
|
+
}
|
|
975
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ordering-ui-admin-external",
|
|
3
|
-
"version": "1.43.
|
|
3
|
+
"version": "1.43.32",
|
|
4
4
|
"description": "Ordering UI Admin Components",
|
|
5
5
|
"main": "./_modules/index.js",
|
|
6
6
|
"exports": {
|
|
@@ -83,7 +83,7 @@
|
|
|
83
83
|
"lodash": "^4.17.20",
|
|
84
84
|
"moment": "^2.29.1",
|
|
85
85
|
"moment-range": "^4.0.2",
|
|
86
|
-
"ordering-components-admin-external": "1.43.
|
|
86
|
+
"ordering-components-admin-external": "1.43.21",
|
|
87
87
|
"polished": "^3.6.7",
|
|
88
88
|
"prop-types": "^15.7.2",
|
|
89
89
|
"react-big-calendar": "^1.4.2",
|