ordering-ui-external 10.4.1 → 10.5.0
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/{0.ordering-ui.62d46eec3c210c5257aa.js → 0.ordering-ui.cc1d13aa04732fde3671.js} +1 -1
- package/_bundles/{1.ordering-ui.62d46eec3c210c5257aa.js → 1.ordering-ui.cc1d13aa04732fde3671.js} +1 -1
- package/_bundles/{2.ordering-ui.62d46eec3c210c5257aa.js → 2.ordering-ui.cc1d13aa04732fde3671.js} +1 -1
- package/_bundles/{4.ordering-ui.62d46eec3c210c5257aa.js → 4.ordering-ui.cc1d13aa04732fde3671.js} +1 -1
- package/_bundles/{5.ordering-ui.62d46eec3c210c5257aa.js → 5.ordering-ui.cc1d13aa04732fde3671.js} +1 -1
- package/_bundles/{6.ordering-ui.62d46eec3c210c5257aa.js → 6.ordering-ui.cc1d13aa04732fde3671.js} +1 -1
- package/_bundles/{7.ordering-ui.62d46eec3c210c5257aa.js → 7.ordering-ui.cc1d13aa04732fde3671.js} +2 -2
- package/_bundles/{8.ordering-ui.62d46eec3c210c5257aa.js → 8.ordering-ui.cc1d13aa04732fde3671.js} +1 -1
- package/_bundles/{9.ordering-ui.62d46eec3c210c5257aa.js → 9.ordering-ui.cc1d13aa04732fde3671.js} +1 -1
- package/_bundles/ordering-ui.cc1d13aa04732fde3671.js +2 -0
- package/_modules/themes/callcenterOriginal/src/components/Orders/DeliveriesManager/index.js +4 -2
- package/_modules/themes/callcenterOriginal/src/components/Orders/OrdersDashboardControls/index.js +3 -1
- package/_modules/themes/callcenterOriginal/src/components/Orders/OrdersManager/index.js +2 -0
- package/_modules/themes/five/src/components/BusinessItemAccordion/index.js +5 -2
- package/_modules/themes/five/src/components/BusinessItemAccordion/styles.js +25 -19
- package/_modules/themes/five/src/components/BusinessProductsListing/index.js +2 -0
- package/_modules/themes/five/src/components/BusinessesListing/layouts/OriginalBusinessesListing/index.js +133 -31
- package/_modules/themes/five/src/components/BusinessesListing/layouts/OriginalBusinessesListing/styles.js +37 -3
- package/_modules/themes/five/src/components/Cart/index.js +10 -6
- package/_modules/themes/five/src/components/Checkout/index.js +67 -22
- package/_modules/themes/five/src/components/GiftCard/GiftCardOrdersList/index.js +53 -0
- package/_modules/themes/five/src/components/GiftCard/GiftCardOrdersList/styles.js +16 -0
- package/_modules/themes/five/src/components/GiftCard/HorizontalGiftCardOrdersLayout/index.js +69 -0
- package/_modules/themes/five/src/components/GiftCard/HorizontalGiftCardOrdersLayout/styles.js +16 -0
- package/_modules/themes/five/src/components/GiftCard/SingleGiftCard/index.js +90 -0
- package/_modules/themes/five/src/components/GiftCard/SingleGiftCard/styles.js +43 -0
- package/_modules/themes/five/src/components/GiftCard/VerticalGiftCardOrdersLayout/index.js +75 -0
- package/_modules/themes/five/src/components/GiftCard/VerticalGiftCardOrdersLayout/styles.js +19 -0
- package/_modules/themes/five/src/components/MyOrders/index.js +6 -1
- package/_modules/themes/five/src/components/OrderProgress/index.js +1 -1
- package/_modules/themes/five/src/components/OrdersOption/index.js +1 -0
- package/_modules/themes/five/src/components/PhoneAutocomplete/index.js +165 -31
- package/_modules/themes/five/src/components/PhoneAutocomplete/styles.js +53 -9
- package/_modules/themes/five/src/components/ProductForm/index.js +1 -0
- package/_modules/themes/five/src/components/SingleProductCard/layouts/original/styles.js +1 -1
- package/_modules/themes/five/src/components/UserFormDetails/index.js +5 -17
- package/_modules/themes/five/src/components/UserFormDetails/styles.js +3 -7
- package/index-template.js +9 -1
- package/package.json +2 -2
- package/src/themes/callcenterOriginal/src/components/Orders/DeliveriesManager/index.js +3 -1
- package/src/themes/callcenterOriginal/src/components/Orders/OrdersDashboardControls/index.js +5 -1
- package/src/themes/callcenterOriginal/src/components/Orders/OrdersManager/index.js +2 -0
- package/src/themes/five/src/components/BusinessItemAccordion/index.js +2 -2
- package/src/themes/five/src/components/BusinessItemAccordion/styles.js +8 -7
- package/src/themes/five/src/components/BusinessProductsListing/index.js +2 -0
- package/src/themes/five/src/components/BusinessesListing/layouts/OriginalBusinessesListing/index.js +156 -36
- package/src/themes/five/src/components/BusinessesListing/layouts/OriginalBusinessesListing/styles.js +66 -0
- package/src/themes/five/src/components/Cart/index.js +7 -4
- package/src/themes/five/src/components/Checkout/index.js +61 -35
- package/src/themes/five/src/components/GiftCard/GiftCardOrdersList/index.js +50 -0
- package/src/themes/five/src/components/GiftCard/GiftCardOrdersList/styles.js +34 -0
- package/src/themes/five/src/components/GiftCard/HorizontalGiftCardOrdersLayout/index.js +75 -0
- package/src/themes/five/src/components/GiftCard/HorizontalGiftCardOrdersLayout/styles.js +29 -0
- package/src/themes/five/src/components/GiftCard/SingleGiftCard/index.js +79 -0
- package/src/themes/five/src/components/GiftCard/SingleGiftCard/styles.js +79 -0
- package/src/themes/five/src/components/GiftCard/VerticalGiftCardOrdersLayout/index.js +72 -0
- package/src/themes/five/src/components/GiftCard/VerticalGiftCardOrdersLayout/styles.js +31 -0
- package/src/themes/five/src/components/MyOrders/index.js +6 -1
- package/src/themes/five/src/components/OrderProgress/index.js +1 -1
- package/src/themes/five/src/components/OrdersOption/index.js +1 -0
- package/src/themes/five/src/components/PhoneAutocomplete/index.js +195 -46
- package/src/themes/five/src/components/PhoneAutocomplete/styles.js +106 -10
- package/src/themes/five/src/components/ProductForm/index.js +1 -0
- package/src/themes/five/src/components/SingleProductCard/layouts/original/styles.js +1 -1
- package/src/themes/five/src/components/UserFormDetails/index.js +6 -27
- package/src/themes/five/src/components/UserFormDetails/styles.js +0 -16
- package/template/assets/images/delivery.svg +11 -0
- package/template/assets/images/phone-hero-callcenter.png +0 -0
- package/template/assets/images/phone.svg +11 -0
- package/template/assets/images/pickup.svg +17 -0
- package/_bundles/ordering-ui.62d46eec3c210c5257aa.js +0 -2
- /package/_bundles/{7.ordering-ui.62d46eec3c210c5257aa.js.LICENSE.txt → 7.ordering-ui.cc1d13aa04732fde3671.js.LICENSE.txt} +0 -0
- /package/_bundles/{ordering-ui.62d46eec3c210c5257aa.js.LICENSE.txt → ordering-ui.cc1d13aa04732fde3671.js.LICENSE.txt} +0 -0
|
@@ -44,7 +44,8 @@ var DeliveriesManagerUI = function DeliveriesManagerUI(props) {
|
|
|
44
44
|
handleSelectedSubOrderStatus = props.handleSelectedSubOrderStatus,
|
|
45
45
|
onOrderRedirect = props.onOrderRedirect,
|
|
46
46
|
numberOfOrdersByStatus = props.numberOfOrdersByStatus,
|
|
47
|
-
numberOfOrdersBySubstatus = props.numberOfOrdersBySubstatus
|
|
47
|
+
numberOfOrdersBySubstatus = props.numberOfOrdersBySubstatus,
|
|
48
|
+
franchiseId = props.franchiseId;
|
|
48
49
|
var _useLanguage = (0, _orderingComponentsExternal.useLanguage)(),
|
|
49
50
|
_useLanguage2 = _slicedToArray(_useLanguage, 2),
|
|
50
51
|
t = _useLanguage2[1];
|
|
@@ -128,7 +129,8 @@ var DeliveriesManagerUI = function DeliveriesManagerUI(props) {
|
|
|
128
129
|
slaSettingTime: slaSettingTime,
|
|
129
130
|
timeStatus: timeStatus,
|
|
130
131
|
numberOfOrdersByStatus: numberOfOrdersByStatus,
|
|
131
|
-
numberOfOrdersBySubstatus: numberOfOrdersBySubstatus
|
|
132
|
+
numberOfOrdersBySubstatus: numberOfOrdersBySubstatus,
|
|
133
|
+
franchiseId: franchiseId
|
|
132
134
|
})))), isOpenOrderDetail && /*#__PURE__*/_react.default.createElement(_OrderDetails.OrderDetails, {
|
|
133
135
|
open: isOpenOrderDetail,
|
|
134
136
|
order: detailsOrder,
|
package/_modules/themes/callcenterOriginal/src/components/Orders/OrdersDashboardControls/index.js
CHANGED
|
@@ -21,6 +21,7 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
|
21
21
|
var OrdersDashboardControls = function OrdersDashboardControls(props) {
|
|
22
22
|
var selectedOrderNumber = props.selectedOrderNumber,
|
|
23
23
|
filterValues = props.filterValues,
|
|
24
|
+
franchiseId = props.franchiseId,
|
|
24
25
|
handleDeleteMultiOrders = props.handleDeleteMultiOrders,
|
|
25
26
|
handleChangeMultiOrdersStatus = props.handleChangeMultiOrdersStatus,
|
|
26
27
|
handleOpenCustomOrderDetail = props.handleOpenCustomOrderDetail;
|
|
@@ -30,7 +31,8 @@ var OrdersDashboardControls = function OrdersDashboardControls(props) {
|
|
|
30
31
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_styles.OrderDashboardControlsContainer, null, /*#__PURE__*/_react.default.createElement(_styles.InnerContnet, null, /*#__PURE__*/_react.default.createElement(_CreateCustomOrder.CreateCustomOrder, {
|
|
31
32
|
handleOpenCustomOrderDetail: handleOpenCustomOrderDetail
|
|
32
33
|
}), /*#__PURE__*/_react.default.createElement(_OrdersExportCSV.OrdersExportCSV, {
|
|
33
|
-
filterValues: filterValues
|
|
34
|
+
filterValues: filterValues,
|
|
35
|
+
franchiseId: franchiseId
|
|
34
36
|
}), selectedOrderNumber > 0 && /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, (user === null || user === void 0 ? void 0 : user.level) !== 5 && /*#__PURE__*/_react.default.createElement(_OrderDelete.OrderDelete, {
|
|
35
37
|
handleDeleteMultiOrders: handleDeleteMultiOrders
|
|
36
38
|
}), /*#__PURE__*/_react.default.createElement(_styles.WrapOrderStatusTypeSelector, null, /*#__PURE__*/_react.default.createElement(_OrderStatusTypeSelector.OrderStatusTypeSelector, {
|
|
@@ -232,6 +232,7 @@ var OrdersManagerUI = function OrdersManagerUI(props) {
|
|
|
232
232
|
})), !isSelectedOrders && /*#__PURE__*/_react.default.createElement(_OrdersDashboardControls.OrdersDashboardControls, {
|
|
233
233
|
selectedOrderNumber: selectedOrderIds === null || selectedOrderIds === void 0 ? void 0 : selectedOrderIds.length,
|
|
234
234
|
filterValues: filterValues,
|
|
235
|
+
franchiseId: props.franchiseId,
|
|
235
236
|
handleChangeMultiOrdersStatus: handleChangeMultiOrdersStatus,
|
|
236
237
|
handleDeleteMultiOrders: handleDeleteMultiOrders,
|
|
237
238
|
handleOpenCustomOrderDetail: function handleOpenCustomOrderDetail(id) {
|
|
@@ -245,6 +246,7 @@ var OrdersManagerUI = function OrdersManagerUI(props) {
|
|
|
245
246
|
driverId: props.driverId,
|
|
246
247
|
customerId: props.customerId,
|
|
247
248
|
businessId: props.businessId,
|
|
249
|
+
franchiseId: props.franchiseId,
|
|
248
250
|
searchValue: searchValue,
|
|
249
251
|
filterValues: filterValues,
|
|
250
252
|
selectedOrderIds: selectedOrderIds,
|
|
@@ -162,11 +162,14 @@ var BusinessItemAccordion = function BusinessItemAccordion(props) {
|
|
|
162
162
|
onClick: function onClick(e) {
|
|
163
163
|
return toggleAccordion(e);
|
|
164
164
|
}
|
|
165
|
-
}, /*#__PURE__*/_react.default.createElement(_styles.BusinessInfo,
|
|
165
|
+
}, /*#__PURE__*/_react.default.createElement(_styles.BusinessInfo, {
|
|
166
|
+
isOtherInfo: isClosed && !isStore || !isClosed && !isProducts && !isStore
|
|
167
|
+
}, !hideBusinessLogo && /*#__PURE__*/_react.default.createElement(_styles.WrapperBusinessLogo, null, /*#__PURE__*/_react.default.createElement(_styles.BusinessLogo, {
|
|
166
168
|
bgimage: !isGiftCart ? (business === null || business === void 0 ? void 0 : business.logo) || ((_theme$images = theme.images) === null || _theme$images === void 0 || (_theme$images = _theme$images.dummies) === null || _theme$images === void 0 ? void 0 : _theme$images.businessLogo) : (_theme$images2 = theme.images) === null || _theme$images2 === void 0 || (_theme$images2 = _theme$images2.logos) === null || _theme$images2 === void 0 ? void 0 : _theme$images2.isotype
|
|
167
169
|
})), /*#__PURE__*/_react.default.createElement(_styles.ContentInfo, {
|
|
168
170
|
className: "info",
|
|
169
|
-
isStore: isStore
|
|
171
|
+
isStore: isStore,
|
|
172
|
+
isLogo: !hideBusinessLogo
|
|
170
173
|
}, /*#__PURE__*/_react.default.createElement("h2", null, business === null || business === void 0 ? void 0 : business.name), !hideBusinessTime && /*#__PURE__*/_react.default.createElement(_styles.TimeContainer, null, (orderState === null || orderState === void 0 || (_orderState$options = orderState.options) === null || _orderState$options === void 0 ? void 0 : _orderState$options.type) === 1 ? /*#__PURE__*/_react.default.createElement("span", null, /*#__PURE__*/_react.default.createElement(_FiClock.default, null), (0, _utils.convertHoursToMinutes)(business === null || business === void 0 ? void 0 : business.delivery_time)) : /*#__PURE__*/_react.default.createElement("span", null, /*#__PURE__*/_react.default.createElement(_FiClock.default, null), (0, _utils.convertHoursToMinutes)(business === null || business === void 0 ? void 0 : business.pickup_time))), /*#__PURE__*/_react.default.createElement("div", null, handleStoreRedirect && !isCartOnProductsList && !isStore && !isGiftCart && /*#__PURE__*/_react.default.createElement("span", {
|
|
171
174
|
ref: businessStore,
|
|
172
175
|
onClick: function onClick() {
|
|
@@ -7,7 +7,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.WrapperBusinessLogo = exports.TimeContainer = exports.PriceContainer = exports.ContentInfo = exports.BusinessTotal = exports.BusinessLogo = exports.BusinessInfo = exports.BusinessActions = exports.AccordionText = exports.AccordionSection = exports.AccordionContent = exports.Accordion = void 0;
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
10
|
-
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18, _templateObject19;
|
|
10
|
+
var _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6, _templateObject7, _templateObject8, _templateObject9, _templateObject10, _templateObject11, _templateObject12, _templateObject13, _templateObject14, _templateObject15, _templateObject16, _templateObject17, _templateObject18, _templateObject19, _templateObject20, _templateObject21;
|
|
11
11
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
12
12
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
13
13
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
@@ -25,45 +25,51 @@ var Accordion = _styledComponents.default.div(_templateObject3 || (_templateObje
|
|
|
25
25
|
return props.isClosed && (0, _styledComponents.css)(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5));\n padding: 10px 5px;\n "])));
|
|
26
26
|
});
|
|
27
27
|
exports.Accordion = Accordion;
|
|
28
|
-
var ContentInfo = _styledComponents.default.div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n justify-content: center;\n width: 100%;\n\n > div {\n display: flex;\n align-items: center;\n\n .go-store {\n user-select: none;\n color: ", ";\n margin-right: 5px;\n ", "\n &:hover {\n text-decoration: underline;\n }\n }\n\n .clear-cart {\n user-select: none;\n color: #d81212;\n margin-left: 5px;\n ", "\n &:first-letter {\n text-transform: uppercase;\n }\n &:hover {\n text-decoration: underline;\n }\n }\n\n ", "\n }\n .change-store {\n cursor: pointer;\n color: ", ";\n font-size: 12px;\n &:first-letter {\n text-transform: uppercase;\n }\n &:hover {\n text-decoration: underline;\n }\n }\n ", "\n\n span {\n cursor: pointer;\n }\n\n h2, span {\n margin: 0px;\n }\n\n h2 {\n color: ", ";\n font-size: 16px;\n font-weight: 500;\n }\n\n @media (min-width: 576px) {\n h2 {\n font-size: 18px;\n }\n span {\n font-size: 13px;\n }\n }\n"])), function (
|
|
28
|
+
var ContentInfo = _styledComponents.default.div(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n display: flex;\n flex-direction: column;\n justify-content: center;\n width: 100%;\n ", "\n\n > div {\n display: flex;\n align-items: center;\n\n .go-store {\n user-select: none;\n color: ", ";\n margin-right: 5px;\n ", "\n &:hover {\n text-decoration: underline;\n }\n }\n\n .clear-cart {\n user-select: none;\n color: #d81212;\n margin-left: 5px;\n ", "\n &:first-letter {\n text-transform: uppercase;\n }\n &:hover {\n text-decoration: underline;\n }\n }\n\n ", "\n }\n .change-store {\n cursor: pointer;\n color: ", ";\n font-size: 12px;\n &:first-letter {\n text-transform: uppercase;\n }\n &:hover {\n text-decoration: underline;\n }\n }\n ", "\n\n span {\n cursor: pointer;\n }\n\n h2, span {\n margin: 0px;\n }\n\n h2 {\n color: ", ";\n font-size: 16px;\n font-weight: 500;\n }\n\n @media (min-width: 576px) {\n h2 {\n font-size: 18px;\n }\n span {\n font-size: 13px;\n }\n }\n"])), function (_ref3) {
|
|
29
|
+
var isLogo = _ref3.isLogo;
|
|
30
|
+
return isLogo && (0, _styledComponents.css)(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n width: calc(100% - 80px);\n "])));
|
|
31
|
+
}, function (props) {
|
|
29
32
|
return props.theme.colors.primary;
|
|
30
33
|
}, function (props) {
|
|
31
34
|
var _props$theme;
|
|
32
|
-
return ((_props$theme = props.theme) === null || _props$theme === void 0 ? void 0 : _props$theme.rtl) && (0, _styledComponents.css)(
|
|
35
|
+
return ((_props$theme = props.theme) === null || _props$theme === void 0 ? void 0 : _props$theme.rtl) && (0, _styledComponents.css)(_templateObject7 || (_templateObject7 = _taggedTemplateLiteral(["\n margin-left: 5px;\n margin-right: 0;\n "])));
|
|
33
36
|
}, function (props) {
|
|
34
37
|
var _props$theme2;
|
|
35
|
-
return ((_props$theme2 = props.theme) === null || _props$theme2 === void 0 ? void 0 : _props$theme2.rtl) && (0, _styledComponents.css)(
|
|
36
|
-
}, function (
|
|
37
|
-
var isStore =
|
|
38
|
-
return isStore && (0, _styledComponents.css)(
|
|
38
|
+
return ((_props$theme2 = props.theme) === null || _props$theme2 === void 0 ? void 0 : _props$theme2.rtl) && (0, _styledComponents.css)(_templateObject8 || (_templateObject8 = _taggedTemplateLiteral(["\n margin-right: 5px;\n margin-left: 0;\n "])));
|
|
39
|
+
}, function (_ref4) {
|
|
40
|
+
var isStore = _ref4.isStore;
|
|
41
|
+
return isStore && (0, _styledComponents.css)(_templateObject9 || (_templateObject9 = _taggedTemplateLiteral(["\n .clear-cart {\n margin: 0px;\n }\n "])));
|
|
39
42
|
}, function (props) {
|
|
40
43
|
return props.theme.colors.primary;
|
|
41
44
|
}, function (props) {
|
|
42
45
|
var _props$theme3;
|
|
43
|
-
return ((_props$theme3 = props.theme) === null || _props$theme3 === void 0 ? void 0 : _props$theme3.rtl) && (0, _styledComponents.css)(
|
|
46
|
+
return ((_props$theme3 = props.theme) === null || _props$theme3 === void 0 ? void 0 : _props$theme3.rtl) && (0, _styledComponents.css)(_templateObject10 || (_templateObject10 = _taggedTemplateLiteral(["\n margin-right: 10px;\n margin-left: 0;\n "])));
|
|
44
47
|
}, function (props) {
|
|
45
48
|
return props.theme.colors.darkTextColor;
|
|
46
49
|
});
|
|
47
50
|
exports.ContentInfo = ContentInfo;
|
|
48
|
-
var AccordionContent = _styledComponents.default.div(
|
|
51
|
+
var AccordionContent = _styledComponents.default.div(_templateObject11 || (_templateObject11 = _taggedTemplateLiteral(["\n overflow: hidden;\n transition: min-height 0.6s ease;\n"])));
|
|
49
52
|
exports.AccordionContent = AccordionContent;
|
|
50
|
-
var AccordionText = _styledComponents.default.div(
|
|
53
|
+
var AccordionText = _styledComponents.default.div(_templateObject12 || (_templateObject12 = _taggedTemplateLiteral(["\n font-weight: 400;\n font-size: 14px;\n padding: 18px;\n"])));
|
|
51
54
|
exports.AccordionText = AccordionText;
|
|
52
|
-
var BusinessInfo = _styledComponents.default.div(
|
|
55
|
+
var BusinessInfo = _styledComponents.default.div(_templateObject13 || (_templateObject13 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n width: calc(100% - 30px);\n ", "\n\n h2 {\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n }\n"])), function (_ref5) {
|
|
56
|
+
var isOtherInfo = _ref5.isOtherInfo;
|
|
57
|
+
return isOtherInfo && (0, _styledComponents.css)(_templateObject14 || (_templateObject14 = _taggedTemplateLiteral(["\n width: calc(100% - 100px);\n "])));
|
|
58
|
+
});
|
|
53
59
|
exports.BusinessInfo = BusinessInfo;
|
|
54
|
-
var BusinessTotal = _styledComponents.default.div(
|
|
55
|
-
var isCartOnProductsList =
|
|
60
|
+
var BusinessTotal = _styledComponents.default.div(_templateObject15 || (_templateObject15 = _taggedTemplateLiteral(["\n width: ", ";\n display: none;\n flex-direction: column;\n align-items: center;\n\n p {\n font-size: 13px;\n margin: 0px 5px;\n font-weight: 300;\n\n &:nth-child(1) {\n font-weight: 500;\n }\n }\n\n &.closed {\n flex: 1;\n p {\n text-align: center;\n margin: 0px 20px;\n font-size: 13px;\n }\n }\n\n @media (min-width: 481px) {\n display: flex;\n }\n"])), function (_ref6) {
|
|
61
|
+
var isCartOnProductsList = _ref6.isCartOnProductsList;
|
|
56
62
|
return isCartOnProductsList ? '30%' : '25%';
|
|
57
63
|
});
|
|
58
64
|
exports.BusinessTotal = BusinessTotal;
|
|
59
|
-
var BusinessActions = _styledComponents.default.div(
|
|
65
|
+
var BusinessActions = _styledComponents.default.div(_templateObject16 || (_templateObject16 = _taggedTemplateLiteral(["\n max-width: 30px;\n display: flex;\n align-items: center;\n justify-content: flex-end;\n\n span {\n height: 22px;\n svg {\n font-size: 22px;\n }\n\n &:not(:last-child) {\n margin-right: 5px;\n ", "\n }\n }\n\n @media (min-width: 768px) {\n span {\n height: 27px;\n svg {\n font-size: 27px;\n }\n }\n }\n"])), function (props) {
|
|
60
66
|
var _props$theme4;
|
|
61
|
-
return ((_props$theme4 = props.theme) === null || _props$theme4 === void 0 ? void 0 : _props$theme4.rtl) && (0, _styledComponents.css)(
|
|
67
|
+
return ((_props$theme4 = props.theme) === null || _props$theme4 === void 0 ? void 0 : _props$theme4.rtl) && (0, _styledComponents.css)(_templateObject17 || (_templateObject17 = _taggedTemplateLiteral(["\n margin-left: 5px;\n margin-right: 0;\n "])));
|
|
62
68
|
});
|
|
63
69
|
exports.BusinessActions = BusinessActions;
|
|
64
|
-
var PriceContainer = _styledComponents.default.div(
|
|
70
|
+
var PriceContainer = _styledComponents.default.div(_templateObject18 || (_templateObject18 = _taggedTemplateLiteral(["\n display: flex;\n justify-content: space-between;\n align-items: center;\n h4 {\n font-size: 16px;\n }\n button{ \n padding: 10px 30px;\n min-width: 150px;\n width: 50%;\n height: 50px;\n }\n"])));
|
|
65
71
|
exports.PriceContainer = PriceContainer;
|
|
66
|
-
var BusinessLogoStyled = _styledComponents.default.div(
|
|
72
|
+
var BusinessLogoStyled = _styledComponents.default.div(_templateObject19 || (_templateObject19 = _taggedTemplateLiteral(["\n display: flex;\n width: 75px;\n height: 75px;\n min-height: 75px;\n box-sizing: border-box;\n position: relative;\n background-repeat: no-repeat, repeat;\n background-size: contain;\n object-fit: contain;\n background-position: center;\n border-radius: 10px;\n"])));
|
|
67
73
|
var BusinessLogo = function BusinessLogo(props) {
|
|
68
74
|
return /*#__PURE__*/_react.default.createElement(BusinessLogoStyled, _extends({}, props, {
|
|
69
75
|
style: {
|
|
@@ -72,7 +78,7 @@ var BusinessLogo = function BusinessLogo(props) {
|
|
|
72
78
|
}), props.children);
|
|
73
79
|
};
|
|
74
80
|
exports.BusinessLogo = BusinessLogo;
|
|
75
|
-
var WrapperBusinessLogo = _styledComponents.default.div(
|
|
81
|
+
var WrapperBusinessLogo = _styledComponents.default.div(_templateObject20 || (_templateObject20 = _taggedTemplateLiteral(["\n max-width: 75px;\n max-height: 75px;\n height: 75px;\n width: 75px;\n margin-right: 10px;\n"])));
|
|
76
82
|
exports.WrapperBusinessLogo = WrapperBusinessLogo;
|
|
77
|
-
var TimeContainer = _styledComponents.default.div(
|
|
83
|
+
var TimeContainer = _styledComponents.default.div(_templateObject21 || (_templateObject21 = _taggedTemplateLiteral(["\n svg{\n position: relative;\n top: 1px;\n margin-right: 5px;\n }\n"])));
|
|
78
84
|
exports.TimeContainer = TimeContainer;
|
|
@@ -408,6 +408,8 @@ var BusinessProductsListingUI = function BusinessProductsListingUI(props) {
|
|
|
408
408
|
onChangeMetaTag && onChangeMetaTag(curProduct === null || curProduct === void 0 ? void 0 : curProduct.seo_title, curProduct === null || curProduct === void 0 ? void 0 : curProduct.seo_description, curProduct === null || curProduct === void 0 ? void 0 : curProduct.seo_keywords);
|
|
409
409
|
} else {
|
|
410
410
|
onChangeMetaTag && onChangeMetaTag(business === null || business === void 0 ? void 0 : business.slug, business === null || business === void 0 ? void 0 : business.description, business === null || business === void 0 ? void 0 : business.name);
|
|
411
|
+
updateProductModal(null);
|
|
412
|
+
setCurProduct(null);
|
|
411
413
|
}
|
|
412
414
|
}, [openProduct, loading, business, curProduct]);
|
|
413
415
|
(0, _react.useEffect)(function () {
|
|
@@ -53,7 +53,7 @@ function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefine
|
|
|
53
53
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
54
54
|
var PIXELS_TO_SCROLL = 300;
|
|
55
55
|
var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
56
|
-
var _citiesState$cities, _ref, _theme$business_listi, _orderState$
|
|
56
|
+
var _orderState$options, _citiesState$cities, _ref, _theme$business_listi, _orderState$options2, _theme$business_listi2, _theme$business_listi3, _theme$business_listi4, _theme$business_listi5, _theme$business_listi6, _theme$business_listi7, _businessesList$busin, _theme$header, _orderState$options3, _orderState$options4, _configs$order_types_, _businessesList$busin3, _orderState$options8, _orderState$options10, _configs$business_lis, _configs$business_lis2, _configs$business_lis3, _theme$images2, _theme$business_listi8, _orderState$options13, _theme$images3, _theme$images4, _configs$business_lis4, _theme$images5, _theme$business_listi9, _citiesState$cities5, _citiesState$cities6, _orderState$options15, _configs$advanced_bus2, _citiesState$cities7, _citiesState$cities8, _orderState$options17, _businessesList$busin5, _businessesList$busin6, _orderState$options20;
|
|
57
57
|
var businessesList = props.businessesList,
|
|
58
58
|
paginationProps = props.paginationProps,
|
|
59
59
|
searchValue = props.searchValue,
|
|
@@ -69,14 +69,19 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
69
69
|
getCities = props.getCities,
|
|
70
70
|
citiesState = props.citiesState,
|
|
71
71
|
logosLayout = props.logosLayout,
|
|
72
|
-
actualSlug = props.actualSlug
|
|
72
|
+
actualSlug = props.actualSlug,
|
|
73
|
+
orderTypes = props.orderTypes;
|
|
74
|
+
var allOrderTypes = [1, 2, 3, 4, 5];
|
|
75
|
+
var pickupTypes = [2, 3, 4, 5];
|
|
73
76
|
var _useLanguage = (0, _orderingComponentsExternal.useLanguage)(),
|
|
74
77
|
_useLanguage2 = _slicedToArray(_useLanguage, 2),
|
|
75
78
|
t = _useLanguage2[1];
|
|
76
79
|
var _useOrder = (0, _orderingComponentsExternal.useOrder)(),
|
|
77
80
|
_useOrder2 = _slicedToArray(_useOrder, 2),
|
|
78
81
|
orderState = _useOrder2[0],
|
|
79
|
-
|
|
82
|
+
_useOrder2$ = _useOrder2[1],
|
|
83
|
+
changeCityFilter = _useOrder2$.changeCityFilter,
|
|
84
|
+
changeType = _useOrder2$.changeType;
|
|
80
85
|
var _useSession = (0, _orderingComponentsExternal.useSession)(),
|
|
81
86
|
_useSession2 = _slicedToArray(_useSession, 1),
|
|
82
87
|
auth = _useSession2[0].auth;
|
|
@@ -120,15 +125,19 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
120
125
|
_useState14 = _slicedToArray(_useState13, 2),
|
|
121
126
|
hasHighRatedBusiness = _useState14[0],
|
|
122
127
|
setHasHighRatedBusiness = _useState14[1];
|
|
123
|
-
var
|
|
124
|
-
var _useState15 = (0, _react.useState)([]),
|
|
128
|
+
var _useState15 = (0, _react.useState)(pickupTypes.includes(orderState === null || orderState === void 0 || (_orderState$options = orderState.options) === null || _orderState$options === void 0 ? void 0 : _orderState$options.type)),
|
|
125
129
|
_useState16 = _slicedToArray(_useState15, 2),
|
|
126
|
-
|
|
127
|
-
|
|
130
|
+
isPickupSelected = _useState16[0],
|
|
131
|
+
setIsPickupSelected = _useState16[1];
|
|
132
|
+
var userCustomer = JSON.parse(window.localStorage.getItem('user-customer'));
|
|
133
|
+
var _useState17 = (0, _react.useState)([]),
|
|
134
|
+
_useState18 = _slicedToArray(_useState17, 2),
|
|
135
|
+
favoriteIds = _useState18[0],
|
|
136
|
+
setFavoriteIds = _useState18[1];
|
|
128
137
|
var allCitiesDisabled = citiesState === null || citiesState === void 0 || (_citiesState$cities = citiesState.cities) === null || _citiesState$cities === void 0 ? void 0 : _citiesState$cities.every(function (city) {
|
|
129
138
|
return !city.enabled;
|
|
130
139
|
});
|
|
131
|
-
var hideCities = (_ref = (theme === null || theme === void 0 || (_theme$business_listi = theme.business_listing_view) === null || _theme$business_listi === void 0 || (_theme$business_listi = _theme$business_listi.components) === null || _theme$business_listi === void 0 || (_theme$business_listi = _theme$business_listi.cities) === null || _theme$business_listi === void 0 ? void 0 : _theme$business_listi.hidden) || (orderState === null || orderState === void 0 || (_orderState$
|
|
140
|
+
var hideCities = (_ref = (theme === null || theme === void 0 || (_theme$business_listi = theme.business_listing_view) === null || _theme$business_listi === void 0 || (_theme$business_listi = _theme$business_listi.components) === null || _theme$business_listi === void 0 || (_theme$business_listi = _theme$business_listi.cities) === null || _theme$business_listi === void 0 ? void 0 : _theme$business_listi.hidden) || (orderState === null || orderState === void 0 || (_orderState$options2 = orderState.options) === null || _orderState$options2 === void 0 ? void 0 : _orderState$options2.type) !== 2 || allCitiesDisabled) !== null && _ref !== void 0 ? _ref : true;
|
|
132
141
|
var hideSearch = theme === null || theme === void 0 || (_theme$business_listi2 = theme.business_listing_view) === null || _theme$business_listi2 === void 0 || (_theme$business_listi2 = _theme$business_listi2.components) === null || _theme$business_listi2 === void 0 || (_theme$business_listi2 = _theme$business_listi2.search) === null || _theme$business_listi2 === void 0 ? void 0 : _theme$business_listi2.hidden;
|
|
133
142
|
var hideFilter = (theme === null || theme === void 0 || (_theme$business_listi3 = theme.business_listing_view) === null || _theme$business_listi3 === void 0 || (_theme$business_listi3 = _theme$business_listi3.components) === null || _theme$business_listi3 === void 0 || (_theme$business_listi3 = _theme$business_listi3.filter) === null || _theme$business_listi3 === void 0 ? void 0 : _theme$business_listi3.hidden) || hideSearch;
|
|
134
143
|
var hideHero = theme === null || theme === void 0 || (_theme$business_listi4 = theme.business_listing_view) === null || _theme$business_listi4 === void 0 || (_theme$business_listi4 = _theme$business_listi4.components) === null || _theme$business_listi4 === void 0 || (_theme$business_listi4 = _theme$business_listi4.business_hero) === null || _theme$business_listi4 === void 0 ? void 0 : _theme$business_listi4.hidden;
|
|
@@ -140,7 +149,12 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
140
149
|
return business.id;
|
|
141
150
|
}));
|
|
142
151
|
var isChew = (theme === null || theme === void 0 || (_theme$header = theme.header) === null || _theme$header === void 0 || (_theme$header = _theme$header.components) === null || _theme$header === void 0 || (_theme$header = _theme$header.layout) === null || _theme$header === void 0 || (_theme$header = _theme$header.type) === null || _theme$header === void 0 ? void 0 : _theme$header.toLowerCase()) === 'chew';
|
|
143
|
-
var cateringTypeString = (orderState === null || orderState === void 0 || (_orderState$
|
|
152
|
+
var cateringTypeString = (orderState === null || orderState === void 0 || (_orderState$options3 = orderState.options) === null || _orderState$options3 === void 0 ? void 0 : _orderState$options3.type) === 7 ? 'catering_delivery' : (orderState === null || orderState === void 0 || (_orderState$options4 = orderState.options) === null || _orderState$options4 === void 0 ? void 0 : _orderState$options4.type) === 8 ? 'catering_pickup' : null;
|
|
153
|
+
var configTypes = (configs === null || configs === void 0 || (_configs$order_types_ = configs.order_types_allowed) === null || _configs$order_types_ === void 0 ? void 0 : _configs$order_types_.value.split('|').filter(function (value) {
|
|
154
|
+
return allOrderTypes.includes(Number(value));
|
|
155
|
+
}).map(function (value) {
|
|
156
|
+
return Number(value);
|
|
157
|
+
})) || [];
|
|
144
158
|
var cateringValues = (preorderBusiness === null || preorderBusiness === void 0 ? void 0 : preorderBusiness.configs) && (0, _utils.getCateringValues)(cateringTypeString, preorderBusiness === null || preorderBusiness === void 0 ? void 0 : preorderBusiness.configs);
|
|
145
159
|
var handleScroll = (0, _react.useCallback)(function () {
|
|
146
160
|
var _document$documentEle, _document$documentEle2, _businessesList$error;
|
|
@@ -207,8 +221,24 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
207
221
|
}));
|
|
208
222
|
};
|
|
209
223
|
var handleChangeCity = function handleChangeCity(cityId) {
|
|
210
|
-
var _orderState$
|
|
211
|
-
changeCityFilter(cityId === (orderState === null || orderState === void 0 || (_orderState$
|
|
224
|
+
var _orderState$options5;
|
|
225
|
+
changeCityFilter(cityId === (orderState === null || orderState === void 0 || (_orderState$options5 = orderState.options) === null || _orderState$options5 === void 0 ? void 0 : _orderState$options5.city_id) ? null : cityId);
|
|
226
|
+
};
|
|
227
|
+
var handleChangeType = function handleChangeType(value) {
|
|
228
|
+
if (!(orderState !== null && orderState !== void 0 && orderState.loading)) {
|
|
229
|
+
changeType(value);
|
|
230
|
+
if (value === 1) {
|
|
231
|
+
setIsPickupSelected(false);
|
|
232
|
+
}
|
|
233
|
+
}
|
|
234
|
+
};
|
|
235
|
+
var handleChangeToPickup = function handleChangeToPickup() {
|
|
236
|
+
var _orderTypes$find;
|
|
237
|
+
var firstEnabledPickupType = (_orderTypes$find = orderTypes.find(function (type) {
|
|
238
|
+
return (configTypes === null || configTypes === void 0 ? void 0 : configTypes.includes(type.value)) && type.value !== 1;
|
|
239
|
+
})) === null || _orderTypes$find === void 0 ? void 0 : _orderTypes$find.value;
|
|
240
|
+
handleChangeType(firstEnabledPickupType);
|
|
241
|
+
setIsPickupSelected(true);
|
|
212
242
|
};
|
|
213
243
|
(0, _react.useEffect)(function () {
|
|
214
244
|
if (preorderBusiness) setIsPreorder(true);
|
|
@@ -226,14 +256,36 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
226
256
|
setFavoriteIds(_toConsumableArray(new Set(ids)));
|
|
227
257
|
}, [businessesList === null || businessesList === void 0 || (_businessesList$busin3 = businessesList.businesses) === null || _businessesList$busin3 === void 0 ? void 0 : _businessesList$busin3.length]);
|
|
228
258
|
(0, _react.useEffect)(function () {
|
|
229
|
-
var _citiesState$cities3, _orderState$
|
|
230
|
-
if (!(citiesState !== null && citiesState !== void 0 && (_citiesState$cities3 = citiesState.cities) !== null && _citiesState$cities3 !== void 0 && _citiesState$cities3.length) || !(orderState !== null && orderState !== void 0 && (_orderState$
|
|
259
|
+
var _citiesState$cities3, _orderState$options6, _citiesState$cities4;
|
|
260
|
+
if (!(citiesState !== null && citiesState !== void 0 && (_citiesState$cities3 = citiesState.cities) !== null && _citiesState$cities3 !== void 0 && _citiesState$cities3.length) || !(orderState !== null && orderState !== void 0 && (_orderState$options6 = orderState.options) !== null && _orderState$options6 !== void 0 && _orderState$options6.city_id)) return;
|
|
231
261
|
var selectedCity = citiesState === null || citiesState === void 0 || (_citiesState$cities4 = citiesState.cities) === null || _citiesState$cities4 === void 0 ? void 0 : _citiesState$cities4.find(function (city) {
|
|
232
|
-
var _orderState$
|
|
233
|
-
return (city === null || city === void 0 ? void 0 : city.id) === (orderState === null || orderState === void 0 || (_orderState$
|
|
262
|
+
var _orderState$options7;
|
|
263
|
+
return (city === null || city === void 0 ? void 0 : city.id) === (orderState === null || orderState === void 0 || (_orderState$options7 = orderState.options) === null || _orderState$options7 === void 0 ? void 0 : _orderState$options7.city_id);
|
|
234
264
|
});
|
|
235
265
|
if (!selectedCity || !(selectedCity !== null && selectedCity !== void 0 && selectedCity.enabled)) changeCityFilter(null);
|
|
236
|
-
}, [citiesState, orderState === null || orderState === void 0 || (_orderState$
|
|
266
|
+
}, [citiesState, orderState === null || orderState === void 0 || (_orderState$options8 = orderState.options) === null || _orderState$options8 === void 0 ? void 0 : _orderState$options8.city_id]);
|
|
267
|
+
(0, _react.useEffect)(function () {
|
|
268
|
+
var _orderState$options9;
|
|
269
|
+
if (pickupTypes.includes(orderState === null || orderState === void 0 || (_orderState$options9 = orderState.options) === null || _orderState$options9 === void 0 ? void 0 : _orderState$options9.type) && isCustomerMode) {
|
|
270
|
+
setIsPickupSelected(true);
|
|
271
|
+
}
|
|
272
|
+
}, [orderState === null || orderState === void 0 || (_orderState$options10 = orderState.options) === null || _orderState$options10 === void 0 ? void 0 : _orderState$options10.type]);
|
|
273
|
+
var OrderTypesComponent = function OrderTypesComponent() {
|
|
274
|
+
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, orderTypes && (configTypes ? orderTypes.filter(function (type) {
|
|
275
|
+
return (configTypes === null || configTypes === void 0 ? void 0 : configTypes.includes(type.value)) && type.value !== 1;
|
|
276
|
+
}) : orderTypes).map(function (item, i) {
|
|
277
|
+
var _orderState$options11, _orderState$options12;
|
|
278
|
+
return /*#__PURE__*/_react.default.createElement(_Buttons.Button, {
|
|
279
|
+
key: item.value,
|
|
280
|
+
onClick: function onClick() {
|
|
281
|
+
return handleChangeType(item.value);
|
|
282
|
+
},
|
|
283
|
+
color: (orderState === null || orderState === void 0 || (_orderState$options11 = orderState.options) === null || _orderState$options11 === void 0 ? void 0 : _orderState$options11.type) === (item === null || item === void 0 ? void 0 : item.value) ? 'primary' : 'secondary',
|
|
284
|
+
disabled: orderState === null || orderState === void 0 ? void 0 : orderState.loading,
|
|
285
|
+
className: (orderState === null || orderState === void 0 || (_orderState$options12 = orderState.options) === null || _orderState$options12 === void 0 ? void 0 : _orderState$options12.type) !== (item === null || item === void 0 ? void 0 : item.value) ? 'activated' : ''
|
|
286
|
+
}, item.text);
|
|
287
|
+
}));
|
|
288
|
+
};
|
|
237
289
|
if (logosLayout) {
|
|
238
290
|
var _businessesList$busin4;
|
|
239
291
|
return /*#__PURE__*/_react.default.createElement(_styles.BusinessLogosWrapper, null, /*#__PURE__*/_react.default.createElement(_styles.BusinessLogosContainer, null, /*#__PURE__*/_react.default.createElement(_AutoScroll.AutoScroll, {
|
|
@@ -262,17 +314,43 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
262
314
|
}), (windowSize.width < 576 || (configs === null || configs === void 0 || (_configs$business_lis = configs.business_listing_hide_image) === null || _configs$business_lis === void 0 ? void 0 : _configs$business_lis.value) !== '1' && !isChew) && /*#__PURE__*/_react.default.createElement(_styles.BusinessBanner, null, windowSize.width < 576 && /*#__PURE__*/_react.default.createElement(_OrderContextUI.OrderContextUI, {
|
|
263
315
|
isBusinessList: true,
|
|
264
316
|
hideHero: (configs === null || configs === void 0 || (_configs$business_lis2 = configs.business_listing_hide_image) === null || _configs$business_lis2 === void 0 ? void 0 : _configs$business_lis2.value) !== '1' && !isChew && !hideHero
|
|
265
|
-
}), (configs === null || configs === void 0 || (_configs$business_lis3 = configs.business_listing_hide_image) === null || _configs$business_lis3 === void 0 ? void 0 : _configs$business_lis3.value) !== '1' && !isChew && !hideHero && /*#__PURE__*/_react.default.createElement(_styles.BusinessHeroImg, {
|
|
317
|
+
}), (configs === null || configs === void 0 || (_configs$business_lis3 = configs.business_listing_hide_image) === null || _configs$business_lis3 === void 0 ? void 0 : _configs$business_lis3.value) !== '1' && !isChew && !hideHero && !isCustomerMode && /*#__PURE__*/_react.default.createElement(_styles.BusinessHeroImg, {
|
|
266
318
|
bgimage: (_theme$images2 = theme.images) === null || _theme$images2 === void 0 || (_theme$images2 = _theme$images2.general) === null || _theme$images2 === void 0 ? void 0 : _theme$images2.businessHero,
|
|
267
319
|
height: theme === null || theme === void 0 || (_theme$business_listi8 = theme.business_listing_view) === null || _theme$business_listi8 === void 0 || (_theme$business_listi8 = _theme$business_listi8.components) === null || _theme$business_listi8 === void 0 || (_theme$business_listi8 = _theme$business_listi8.business_hero) === null || _theme$business_listi8 === void 0 || (_theme$business_listi8 = _theme$business_listi8.style) === null || _theme$business_listi8 === void 0 ? void 0 : _theme$business_listi8.height
|
|
268
|
-
})), /*#__PURE__*/_react.default.createElement(
|
|
320
|
+
})), userCustomer && (orderState === null || orderState === void 0 || (_orderState$options13 = orderState.options) === null || _orderState$options13 === void 0 || (_orderState$options13 = _orderState$options13.address) === null || _orderState$options13 === void 0 ? void 0 : _orderState$options13.address) && isCustomerMode && /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement(_styles.Title, null, t('DELIVERY_TYPE', 'Delivery Type')), /*#__PURE__*/_react.default.createElement(_styles.TypesContainer, null, configTypes.includes(1) && /*#__PURE__*/_react.default.createElement(_styles.TypeButton, {
|
|
321
|
+
onClick: function onClick() {
|
|
322
|
+
return handleChangeType(1);
|
|
323
|
+
},
|
|
324
|
+
disabled: orderState === null || orderState === void 0 ? void 0 : orderState.loading,
|
|
325
|
+
activated: !isPickupSelected
|
|
326
|
+
}, /*#__PURE__*/_react.default.createElement(_styles.IconTypeButton, {
|
|
327
|
+
activated: !isPickupSelected
|
|
328
|
+
}, /*#__PURE__*/_react.default.createElement("img", {
|
|
329
|
+
src: theme === null || theme === void 0 || (_theme$images3 = theme.images) === null || _theme$images3 === void 0 || (_theme$images3 = _theme$images3.general) === null || _theme$images3 === void 0 ? void 0 : _theme$images3.deliveryIco,
|
|
330
|
+
width: 20,
|
|
331
|
+
height: 20
|
|
332
|
+
})), /*#__PURE__*/_react.default.createElement("p", null, t('DELIVERY', 'Delivery'))), configTypes.some(function (type) {
|
|
333
|
+
return pickupTypes.includes(type);
|
|
334
|
+
}) && /*#__PURE__*/_react.default.createElement(_styles.TypeButton, {
|
|
335
|
+
disabled: orderState === null || orderState === void 0 ? void 0 : orderState.loading,
|
|
336
|
+
activated: isPickupSelected,
|
|
337
|
+
onClick: function onClick() {
|
|
338
|
+
return handleChangeToPickup();
|
|
339
|
+
}
|
|
340
|
+
}, /*#__PURE__*/_react.default.createElement(_styles.IconTypeButton, {
|
|
341
|
+
activated: isPickupSelected
|
|
342
|
+
}, /*#__PURE__*/_react.default.createElement("img", {
|
|
343
|
+
src: theme === null || theme === void 0 || (_theme$images4 = theme.images) === null || _theme$images4 === void 0 || (_theme$images4 = _theme$images4.general) === null || _theme$images4 === void 0 ? void 0 : _theme$images4.pickupIco,
|
|
344
|
+
width: 22,
|
|
345
|
+
height: 22
|
|
346
|
+
})), /*#__PURE__*/_react.default.createElement("p", null, t('PICKUP', 'Pickup')))), isPickupSelected && /*#__PURE__*/_react.default.createElement(_styles.TypesWrapper, null, /*#__PURE__*/_react.default.createElement("p", null, t('WHAT_PICKUP_YOU_NEED', 'What kind of pickup do you need?')), /*#__PURE__*/_react.default.createElement(_styles.AdditionalTypesContainer, null, /*#__PURE__*/_react.default.createElement(OrderTypesComponent, null)))), !isCustomerMode && /*#__PURE__*/_react.default.createElement(_OrderProgress.OrderProgress, {
|
|
269
347
|
isChew: isChew,
|
|
270
348
|
franchiseId: props.franchiseId,
|
|
271
349
|
userCustomerId: userCustomer === null || userCustomer === void 0 ? void 0 : userCustomer.id,
|
|
272
350
|
asDashboard: isCustomerMode,
|
|
273
351
|
isCustomerMode: isCustomerMode
|
|
274
352
|
}), (configs === null || configs === void 0 || (_configs$business_lis4 = configs.business_listing_hide_image) === null || _configs$business_lis4 === void 0 ? void 0 : _configs$business_lis4.value) !== '1' && isChew && /*#__PURE__*/_react.default.createElement(_styles.BusinessHeroImg, {
|
|
275
|
-
bgimage: (_theme$
|
|
353
|
+
bgimage: (_theme$images5 = theme.images) === null || _theme$images5 === void 0 || (_theme$images5 = _theme$images5.general) === null || _theme$images5 === void 0 ? void 0 : _theme$images5.businessHero,
|
|
276
354
|
height: theme === null || theme === void 0 || (_theme$business_listi9 = theme.business_listing_view) === null || _theme$business_listi9 === void 0 || (_theme$business_listi9 = _theme$business_listi9.components) === null || _theme$business_listi9 === void 0 || (_theme$business_listi9 = _theme$business_listi9.business_hero) === null || _theme$business_listi9 === void 0 || (_theme$business_listi9 = _theme$business_listi9.style) === null || _theme$business_listi9 === void 0 ? void 0 : _theme$business_listi9.height
|
|
277
355
|
}), isCustomerMode && !hidePreviousOrders && !businessesList.loading && /*#__PURE__*/_react.default.createElement(_OrdersSection.OrdersSection, {
|
|
278
356
|
titleContent: t('PREVIOUS_ORDERS', 'Previous orders'),
|
|
@@ -301,13 +379,13 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
301
379
|
color: "primary",
|
|
302
380
|
onClick: handleOpenCities
|
|
303
381
|
}, (citiesState === null || citiesState === void 0 || (_citiesState$cities6 = citiesState.cities) === null || _citiesState$cities6 === void 0 || (_citiesState$cities6 = _citiesState$cities6.find(function (city) {
|
|
304
|
-
var _orderState$
|
|
305
|
-
return (city === null || city === void 0 ? void 0 : city.id) === (orderState === null || orderState === void 0 || (_orderState$
|
|
382
|
+
var _orderState$options14;
|
|
383
|
+
return (city === null || city === void 0 ? void 0 : city.id) === (orderState === null || orderState === void 0 || (_orderState$options14 = orderState.options) === null || _orderState$options14 === void 0 ? void 0 : _orderState$options14.city_id);
|
|
306
384
|
})) === null || _citiesState$cities6 === void 0 ? void 0 : _citiesState$cities6.name) || t('SELECT_A_CITY', 'Select a city')), isCustomLayout && /*#__PURE__*/_react.default.createElement(_FiMap.default, {
|
|
307
385
|
onClick: toggleMap
|
|
308
386
|
})), activeMap && /*#__PURE__*/_react.default.createElement(_BusinessesMap.BusinessesMap, {
|
|
309
387
|
businessList: businessesList.businesses,
|
|
310
|
-
userLocation: orderState === null || orderState === void 0 || (_orderState$
|
|
388
|
+
userLocation: orderState === null || orderState === void 0 || (_orderState$options15 = orderState.options) === null || _orderState$options15 === void 0 || (_orderState$options15 = _orderState$options15.address) === null || _orderState$options15 === void 0 ? void 0 : _orderState$options15.location,
|
|
311
389
|
setErrors: setMapErrors
|
|
312
390
|
})), !isChew && hasHighRatedBusiness && !props.franchiseId && !hideHighestBusiness && /*#__PURE__*/_react.default.createElement(_styles.HightestRatedWrapper, null, /*#__PURE__*/_react.default.createElement(_styles.Divider, null), /*#__PURE__*/_react.default.createElement(_HighestRated.HighestRated, {
|
|
313
391
|
propsToFetch: props.propsToFetch,
|
|
@@ -346,11 +424,11 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
346
424
|
color: "primary",
|
|
347
425
|
onClick: handleOpenCities
|
|
348
426
|
}, (citiesState === null || citiesState === void 0 || (_citiesState$cities8 = citiesState.cities) === null || _citiesState$cities8 === void 0 || (_citiesState$cities8 = _citiesState$cities8.find(function (city) {
|
|
349
|
-
var _orderState$
|
|
350
|
-
return (city === null || city === void 0 ? void 0 : city.id) === (orderState === null || orderState === void 0 || (_orderState$
|
|
427
|
+
var _orderState$options16;
|
|
428
|
+
return (city === null || city === void 0 ? void 0 : city.id) === (orderState === null || orderState === void 0 || (_orderState$options16 = orderState.options) === null || _orderState$options16 === void 0 ? void 0 : _orderState$options16.city_id);
|
|
351
429
|
})) === null || _citiesState$cities8 === void 0 ? void 0 : _citiesState$cities8.name) || t('SELECT_A_CITY', 'Select a city')))), isCustomerMode && activeMap && /*#__PURE__*/_react.default.createElement(_BusinessesMap.BusinessesMap, {
|
|
352
430
|
businessList: businessesList.businesses,
|
|
353
|
-
userLocation: orderState === null || orderState === void 0 || (_orderState$
|
|
431
|
+
userLocation: orderState === null || orderState === void 0 || (_orderState$options17 = orderState.options) === null || _orderState$options17 === void 0 || (_orderState$options17 = _orderState$options17.address) === null || _orderState$options17 === void 0 ? void 0 : _orderState$options17.location,
|
|
354
432
|
setErrors: setMapErrors
|
|
355
433
|
}), /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, (!isCustomLayout && isCustomerMode && (businessesList === null || businessesList === void 0 || (_businessesList$busin5 = businessesList.businesses) === null || _businessesList$busin5 === void 0 ? void 0 : _businessesList$busin5.length) > 0 || isChew) && /*#__PURE__*/_react.default.createElement(_styles.BusinessesTitle, null, t('BUSINESSES', 'Businesses')), /*#__PURE__*/_react.default.createElement(_styles.BusinessList, null, !businessesList.loading && businessesList.businesses.length === 0 && (businessesList === null || businessesList === void 0 ? void 0 : businessesList.fetched) && /*#__PURE__*/_react.default.createElement(_NotFoundSource.NotFoundSource, {
|
|
356
434
|
content: t('NOT_FOUND_BUSINESSES', 'No businesses to delivery / pick up at this address, please change filters or change address.')
|
|
@@ -364,14 +442,14 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
364
442
|
height: '44px'
|
|
365
443
|
}
|
|
366
444
|
}, t('CHANGE_ADDRESS', 'Select other Address'))), (_businessesList$busin6 = businessesList.businesses) === null || _businessesList$busin6 === void 0 ? void 0 : _businessesList$busin6.map(function (business) {
|
|
367
|
-
var _orderState$
|
|
445
|
+
var _orderState$options18, _business$reviews;
|
|
368
446
|
return /*#__PURE__*/_react.default.createElement(_BusinessController.BusinessController, {
|
|
369
447
|
key: business.id,
|
|
370
448
|
className: "card",
|
|
371
449
|
business: business,
|
|
372
450
|
isBusinessOpen: business.open,
|
|
373
451
|
handleCustomClick: handleBusinessClick,
|
|
374
|
-
orderType: orderState === null || orderState === void 0 || (_orderState$
|
|
452
|
+
orderType: orderState === null || orderState === void 0 || (_orderState$options18 = orderState.options) === null || _orderState$options18 === void 0 ? void 0 : _orderState$options18.type,
|
|
375
453
|
isCustomLayout: isCustomLayout,
|
|
376
454
|
isCustomerMode: isCustomerMode,
|
|
377
455
|
onPreorderBusiness: setPreorderBusiness,
|
|
@@ -389,13 +467,13 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
389
467
|
setFavoriteIds: setFavoriteIds
|
|
390
468
|
});
|
|
391
469
|
}), (businessesList.loading || !(businessesList !== null && businessesList !== void 0 && businessesList.fetched)) && _toConsumableArray(Array((paginationProps === null || paginationProps === void 0 ? void 0 : paginationProps.nextPageItems) > 4 ? paginationProps.nextPageItems : 8).keys()).map(function (i) {
|
|
392
|
-
var _orderState$
|
|
470
|
+
var _orderState$options19;
|
|
393
471
|
return /*#__PURE__*/_react.default.createElement(_BusinessController.BusinessController, {
|
|
394
472
|
key: i,
|
|
395
473
|
className: "card",
|
|
396
474
|
business: {},
|
|
397
475
|
isSkeleton: true,
|
|
398
|
-
orderType: orderState === null || orderState === void 0 || (_orderState$
|
|
476
|
+
orderType: orderState === null || orderState === void 0 || (_orderState$options19 = orderState.options) === null || _orderState$options19 === void 0 ? void 0 : _orderState$options19.type
|
|
399
477
|
});
|
|
400
478
|
}))), /*#__PURE__*/_react.default.createElement(_Modal.Modal, {
|
|
401
479
|
open: isPreorder,
|
|
@@ -448,7 +526,7 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
448
526
|
isCustomerMode: isCustomerMode
|
|
449
527
|
}) : /*#__PURE__*/_react.default.createElement(_styles.AddressFormWrapper, null, /*#__PURE__*/_react.default.createElement(_AddressForm.AddressForm, {
|
|
450
528
|
useValidationFileds: true,
|
|
451
|
-
address: (orderState === null || orderState === void 0 || (_orderState$
|
|
529
|
+
address: (orderState === null || orderState === void 0 || (_orderState$options20 = orderState.options) === null || _orderState$options20 === void 0 ? void 0 : _orderState$options20.address) || {},
|
|
452
530
|
onCancel: function onCancel() {
|
|
453
531
|
return setModals(_objectSpread(_objectSpread({}, modals), {}, {
|
|
454
532
|
formOpen: false
|
|
@@ -475,13 +553,37 @@ var BusinessesListingUI = function BusinessesListingUI(props) {
|
|
|
475
553
|
}));
|
|
476
554
|
};
|
|
477
555
|
var OriginalBusinessesListing = function OriginalBusinessesListing(props) {
|
|
556
|
+
var _useLanguage3 = (0, _orderingComponentsExternal.useLanguage)(),
|
|
557
|
+
_useLanguage4 = _slicedToArray(_useLanguage3, 2),
|
|
558
|
+
t = _useLanguage4[1];
|
|
478
559
|
var businessListingProps = _objectSpread(_objectSpread({}, props), {}, {
|
|
479
560
|
UIComponent: BusinessesListingUI,
|
|
480
561
|
paginationSettings: {
|
|
481
562
|
initialPage: 1,
|
|
482
563
|
pageSize: 25,
|
|
483
564
|
controlType: 'infinity'
|
|
484
|
-
}
|
|
565
|
+
},
|
|
566
|
+
orderTypes: props.orderTypes || [{
|
|
567
|
+
value: 1,
|
|
568
|
+
text: t('DELIVERY', 'Delivery'),
|
|
569
|
+
description: t('ORDERTYPE_DESCRIPTION_DELIVERY', 'Delivery description')
|
|
570
|
+
}, {
|
|
571
|
+
value: 2,
|
|
572
|
+
text: t('PICKUP', 'Pickup'),
|
|
573
|
+
description: t('ORDERTYPE_DESCRIPTION_PICKUP', 'Pickup description')
|
|
574
|
+
}, {
|
|
575
|
+
value: 3,
|
|
576
|
+
text: t('EAT_IN', 'Eat in'),
|
|
577
|
+
description: t('ORDERTYPE_DESCRIPTION_EATIN', 'Eat in description')
|
|
578
|
+
}, {
|
|
579
|
+
value: 4,
|
|
580
|
+
text: t('CURBSIDE', 'Curbside'),
|
|
581
|
+
description: t('ORDERTYPE_DESCRIPTION_CURBSIDE', 'Curbside description')
|
|
582
|
+
}, {
|
|
583
|
+
value: 5,
|
|
584
|
+
text: t('DRIVE_THRU', 'Drive thru'),
|
|
585
|
+
description: t('ORDERTYPE_DESCRIPTION_DRIVETHRU', 'Drive Thru description')
|
|
586
|
+
}]
|
|
485
587
|
});
|
|
486
588
|
return /*#__PURE__*/_react.default.createElement(_orderingComponentsExternal.BusinessList, businessListingProps);
|
|
487
589
|
};
|
|
@@ -4,10 +4,10 @@ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" =
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
exports.WrapperSearch = exports.SearchContainer = exports.PreviousOrders = exports.HightestRatedWrapper = exports.HeaderSearchMode = exports.ErrorMessage = exports.Divider = exports.BusinessesTitle = exports.BusinessSearch = exports.BusinessLogosWrapper = exports.BusinessLogosContainer = exports.BusinessLogo = exports.BusinessList = exports.BusinessHeroImgStyled = exports.BusinessHeroImg = exports.BusinessContainer = exports.BusinessBanner = exports.AddressFormWrapper = void 0;
|
|
7
|
+
exports.WrapperSearch = exports.TypesWrapper = exports.TypesContainer = exports.TypeButton = exports.Title = exports.SearchContainer = exports.PreviousOrders = exports.IconTypeButton = exports.HightestRatedWrapper = exports.HeaderSearchMode = exports.ErrorMessage = exports.Divider = exports.BusinessesTitle = exports.BusinessSearch = exports.BusinessLogosWrapper = exports.BusinessLogosContainer = exports.BusinessLogo = exports.BusinessList = exports.BusinessHeroImgStyled = exports.BusinessHeroImg = exports.BusinessContainer = exports.BusinessBanner = exports.AddressFormWrapper = exports.AdditionalTypesContainer = void 0;
|
|
8
8
|
var _styledComponents = _interopRequireWildcard(require("styled-components"));
|
|
9
9
|
var _react = _interopRequireDefault(require("react"));
|
|
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;
|
|
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;
|
|
11
11
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
12
12
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
13
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
@@ -88,4 +88,38 @@ exports.BusinessLogosContainer = BusinessLogosContainer;
|
|
|
88
88
|
var HeaderSearchMode = _styledComponents.default.div(_templateObject23 || (_templateObject23 = _taggedTemplateLiteral(["\n position: absolute;\n width: 200px;\n"])));
|
|
89
89
|
exports.HeaderSearchMode = HeaderSearchMode;
|
|
90
90
|
var AddressFormWrapper = _styledComponents.default.div(_templateObject24 || (_templateObject24 = _taggedTemplateLiteral(["\n @media (min-width: 450px) {\n margin-top: 20px;\n }\n"])));
|
|
91
|
-
exports.AddressFormWrapper = AddressFormWrapper;
|
|
91
|
+
exports.AddressFormWrapper = AddressFormWrapper;
|
|
92
|
+
var IconTypeButton = _styledComponents.default.div(_templateObject25 || (_templateObject25 = _taggedTemplateLiteral(["\n display: flex;\n justify-content: center;\n align-items: center;\n width: 44px;\n height: 44px;\n background: ", ";\n border-radius: 44px;\n"])), function (_ref5) {
|
|
93
|
+
var _theme$colors;
|
|
94
|
+
var activated = _ref5.activated,
|
|
95
|
+
theme = _ref5.theme;
|
|
96
|
+
return activated ? theme === null || theme === void 0 || (_theme$colors = theme.colors) === null || _theme$colors === void 0 ? void 0 : _theme$colors.white : '#F3F9FF';
|
|
97
|
+
});
|
|
98
|
+
exports.IconTypeButton = IconTypeButton;
|
|
99
|
+
var TypesContainer = _styledComponents.default.div(_templateObject26 || (_templateObject26 = _taggedTemplateLiteral(["\n display: flex;\n margin: 42px 20px 0px 20px;\n"])));
|
|
100
|
+
exports.TypesContainer = TypesContainer;
|
|
101
|
+
var AdditionalTypesContainer = _styledComponents.default.div(_templateObject27 || (_templateObject27 = _taggedTemplateLiteral(["\n width: 60%;\n display: flex;\n margin-bottom: 20px;\n margin-left: 20px;\n button {\n padding: 4px 10px;\n border-radius: 50px;\n font-size: 10px;\n line-height: 0;\n height: 25px;\n margin-right: 20px;\n }\n .activated {\n color: ", "\n }\n"])), function (_ref6) {
|
|
102
|
+
var _theme$colors2;
|
|
103
|
+
var theme = _ref6.theme;
|
|
104
|
+
return theme === null || theme === void 0 || (_theme$colors2 = theme.colors) === null || _theme$colors2 === void 0 ? void 0 : _theme$colors2.darkTextColor;
|
|
105
|
+
});
|
|
106
|
+
exports.AdditionalTypesContainer = AdditionalTypesContainer;
|
|
107
|
+
var TypeButton = _styledComponents.default.div(_templateObject28 || (_templateObject28 = _taggedTemplateLiteral(["\n display: flex;\n align-items: center;\n width: 215px;\n height: 75px;\n border-radius: 7.6px;\n padding: 16px;\n box-shadow: 0px 1px 4px 0px rgba(0, 0, 0, 0.10);\n margin-right: 32px;\n margin-bottom: 32px;\n cursor: pointer;\n background: ", ";\n p{\n margin: 0;\n margin-left: 33px;\n ", "\n }\n"])), function (_ref7) {
|
|
108
|
+
var _theme$colors3, _theme$colors4;
|
|
109
|
+
var activated = _ref7.activated,
|
|
110
|
+
theme = _ref7.theme;
|
|
111
|
+
return activated ? theme === null || theme === void 0 || (_theme$colors3 = theme.colors) === null || _theme$colors3 === void 0 ? void 0 : _theme$colors3.primary : theme === null || theme === void 0 || (_theme$colors4 = theme.colors) === null || _theme$colors4 === void 0 ? void 0 : _theme$colors4.white;
|
|
112
|
+
}, function (_ref8) {
|
|
113
|
+
var _theme$colors5;
|
|
114
|
+
var activated = _ref8.activated,
|
|
115
|
+
theme = _ref8.theme;
|
|
116
|
+
return activated && (0, _styledComponents.css)(_templateObject29 || (_templateObject29 = _taggedTemplateLiteral(["\n color: ", ";\n "])), theme === null || theme === void 0 || (_theme$colors5 = theme.colors) === null || _theme$colors5 === void 0 ? void 0 : _theme$colors5.white);
|
|
117
|
+
});
|
|
118
|
+
exports.TypeButton = TypeButton;
|
|
119
|
+
var Title = _styledComponents.default.h2(_templateObject30 || (_templateObject30 = _taggedTemplateLiteral(["\n font-weight: 600;\n font-size: 24px;\n color: ", ";\n margin: 0px 20px 5px 20px;\n"])), function (props) {
|
|
120
|
+
var _props$theme3;
|
|
121
|
+
return (_props$theme3 = props.theme) === null || _props$theme3 === void 0 ? void 0 : _props$theme3.colors.headingColor;
|
|
122
|
+
});
|
|
123
|
+
exports.Title = Title;
|
|
124
|
+
var TypesWrapper = _styledComponents.default.div(_templateObject31 || (_templateObject31 = _taggedTemplateLiteral(["\n margin-left: 20px;\n width: 600px;\n"])));
|
|
125
|
+
exports.TypesWrapper = TypesWrapper;
|