ordering-ui-external 10.9.0 → 10.9.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/_bundles/{0.ordering-ui.ac159b0ec9eb4a80c944.js → 0.ordering-ui.c4b4f29a4f0c8eaad874.js} +1 -1
- package/_bundles/{1.ordering-ui.ac159b0ec9eb4a80c944.js → 1.ordering-ui.c4b4f29a4f0c8eaad874.js} +1 -1
- package/_bundles/{2.ordering-ui.ac159b0ec9eb4a80c944.js → 2.ordering-ui.c4b4f29a4f0c8eaad874.js} +1 -1
- package/_bundles/{4.ordering-ui.ac159b0ec9eb4a80c944.js → 4.ordering-ui.c4b4f29a4f0c8eaad874.js} +1 -1
- package/_bundles/{5.ordering-ui.ac159b0ec9eb4a80c944.js → 5.ordering-ui.c4b4f29a4f0c8eaad874.js} +1 -1
- package/_bundles/{6.ordering-ui.ac159b0ec9eb4a80c944.js → 6.ordering-ui.c4b4f29a4f0c8eaad874.js} +1 -1
- package/_bundles/{7.ordering-ui.ac159b0ec9eb4a80c944.js → 7.ordering-ui.c4b4f29a4f0c8eaad874.js} +2 -2
- package/_bundles/{8.ordering-ui.ac159b0ec9eb4a80c944.js → 8.ordering-ui.c4b4f29a4f0c8eaad874.js} +1 -1
- package/_bundles/{9.ordering-ui.ac159b0ec9eb4a80c944.js → 9.ordering-ui.c4b4f29a4f0c8eaad874.js} +1 -1
- package/_bundles/ordering-ui.c4b4f29a4f0c8eaad874.js +2 -0
- package/_modules/components/AddressForm/index.js +5 -8
- package/_modules/components/BusinessProductsListing/index.js +5 -8
- package/_modules/components/Checkout/index.js +5 -8
- package/_modules/components/Footer/index.js +5 -7
- package/_modules/components/HelpStaticPage/index.js +5 -7
- package/_modules/components/LoginForm/index.js +5 -8
- package/_modules/components/OrdersOption/index.js +5 -8
- package/_modules/components/PagesList/index.js +5 -7
- package/_modules/components/StripeMethodForm/index.js +5 -8
- package/_modules/hooks/useIntersectionObserver.js +5 -7
- package/_modules/themes/callcenterOriginal/src/components/AddressDetails/index.js +11 -5
- package/_modules/themes/callcenterOriginal/src/components/AddressForm/index.js +22 -14
- package/_modules/themes/callcenterOriginal/src/components/AddressForm/styles.js +5 -4
- package/_modules/themes/callcenterOriginal/src/components/AddressList/index.js +10 -5
- package/_modules/themes/callcenterOriginal/src/components/AddressList/styles.js +7 -6
- package/_modules/themes/callcenterOriginal/src/components/Checkout/index.js +7 -9
- package/_modules/themes/callcenterOriginal/src/components/Footer/index.js +5 -7
- package/_modules/themes/callcenterOriginal/src/components/Header/index.js +5 -2
- package/_modules/themes/callcenterOriginal/src/components/HelpStaticPage/index.js +5 -7
- package/_modules/themes/callcenterOriginal/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/callcenterOriginal/src/components/Orders/AddressForm/index.js +6 -9
- package/_modules/themes/callcenterOriginal/src/components/Orders/CreateCustomOrder/Checkout/index.js +5 -8
- package/_modules/themes/callcenterOriginal/src/components/Orders/CreateCustomOrder/StripeMethodForm/index.js +5 -8
- package/_modules/themes/callcenterOriginal/src/components/OrdersOption/index.js +5 -8
- package/_modules/themes/callcenterOriginal/src/components/PhoneAutocomplete/index.js +40 -25
- package/_modules/themes/callcenterOriginal/src/components/PhoneAutocomplete/styles.js +9 -7
- package/_modules/themes/callcenterOriginal/src/components/Shared/ImageCrop/index.js +5 -7
- package/_modules/themes/eight/src/components/AddressForm/index.js +5 -8
- package/_modules/themes/eight/src/components/Checkout/index.js +5 -8
- package/_modules/themes/eight/src/components/Footer/index.js +5 -7
- package/_modules/themes/eight/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/five/src/components/AddressForm/index.js +5 -8
- package/_modules/themes/five/src/components/AddressList/index.js +5 -8
- package/_modules/themes/five/src/components/BusinessProductsListing/index.js +9 -15
- package/_modules/themes/five/src/components/Checkout/index.js +5 -8
- package/_modules/themes/five/src/components/Footer/index.js +5 -8
- package/_modules/themes/five/src/components/HelpStaticPage/index.js +5 -7
- package/_modules/themes/five/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/five/src/components/LogoutPopup/index.js +9 -15
- package/_modules/themes/five/src/components/NotNetworkConnectivity/index.js +5 -8
- package/_modules/themes/five/src/components/OrderDetails/index.js +10 -16
- package/_modules/themes/five/src/components/OrderDetails/layouts/Kiosk/index.js +5 -8
- package/_modules/themes/five/src/components/SignUpForm/index.js +5 -8
- package/_modules/themes/five/src/components/SingleOrderCard/index.js +5 -8
- package/_modules/themes/four/src/components/AddressForm/index.js +5 -8
- package/_modules/themes/four/src/components/BusinessProductsListing/index.js +5 -8
- package/_modules/themes/four/src/components/Checkout/index.js +5 -8
- package/_modules/themes/four/src/components/Footer/index.js +5 -7
- package/_modules/themes/four/src/components/HelpStaticPage/index.js +5 -7
- package/_modules/themes/four/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/four/src/components/OrdersOption/index.js +5 -8
- package/_modules/themes/franchise/src/components/AddressForm/index.js +5 -8
- package/_modules/themes/franchise/src/components/Checkout/index.js +5 -8
- package/_modules/themes/franchise/src/components/Footer/index.js +5 -7
- package/_modules/themes/franchise/src/components/HelpStaticPage/index.js +5 -7
- package/_modules/themes/franchise/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/franchise/src/components/OrdersOption/index.js +5 -8
- package/_modules/themes/orderAndPay/src/components/Checkout/index.js +20 -31
- package/_modules/themes/orderAndPay/src/components/Footer/index.js +5 -7
- package/_modules/themes/orderAndPay/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/orderAndPay/src/components/OrderTypeSelectorContent/index.js +9 -15
- package/_modules/themes/orderAndPay/src/components/OrdersOption/index.js +5 -8
- package/_modules/themes/pwa/src/components/AddressForm/index.js +5 -8
- package/_modules/themes/pwa/src/components/Checkout/index.js +5 -8
- package/_modules/themes/pwa/src/components/Footer/index.js +5 -7
- package/_modules/themes/pwa/src/components/HelpStaticPage/index.js +5 -7
- package/_modules/themes/pwa/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/pwa/src/components/OrdersOption/index.js +5 -8
- package/_modules/themes/seven/src/components/AddressForm/index.js +5 -8
- package/_modules/themes/seven/src/components/Checkout/index.js +5 -8
- package/_modules/themes/seven/src/components/Footer/index.js +5 -7
- package/_modules/themes/seven/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/seven/src/components/OrdersOption/index.js +5 -8
- package/_modules/themes/seven/src/components/ProductForm/productForm.js +9 -15
- package/_modules/themes/six/src/components/AddressForm/index.js +5 -8
- package/_modules/themes/six/src/components/Checkout/index.js +5 -8
- package/_modules/themes/six/src/components/Footer/index.js +5 -7
- package/_modules/themes/six/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/three/src/components/AddressForm/index.js +5 -8
- package/_modules/themes/three/src/components/Checkout/index.js +5 -8
- package/_modules/themes/three/src/components/Footer/index.js +5 -7
- package/_modules/themes/three/src/components/HelpStaticPage/index.js +5 -7
- package/_modules/themes/three/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/three/src/components/OrdersOption/index.js +5 -8
- package/_modules/themes/two/src/components/Checkout/index.js +5 -8
- package/_modules/themes/two/src/components/HelpStaticPage/index.js +5 -7
- package/_modules/themes/two/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/two/src/components/OrdersOption/index.js +5 -8
- package/_modules/themes/wow/src/components/AddressForm/index.js +5 -8
- package/_modules/themes/wow/src/components/Checkout/index.js +5 -8
- package/_modules/themes/wow/src/components/LoginForm/index.js +5 -8
- package/_modules/themes/wow/src/components/OrdersOption/index.js +5 -8
- package/package.json +2 -2
- package/src/themes/callcenterOriginal/src/components/AddressDetails/index.js +10 -3
- package/src/themes/callcenterOriginal/src/components/AddressForm/index.js +15 -4
- package/src/themes/callcenterOriginal/src/components/AddressForm/styles.js +3 -1
- package/src/themes/callcenterOriginal/src/components/AddressList/index.js +14 -4
- package/src/themes/callcenterOriginal/src/components/AddressList/styles.js +5 -5
- package/src/themes/callcenterOriginal/src/components/Checkout/index.js +1 -0
- package/src/themes/callcenterOriginal/src/components/Header/index.js +4 -1
- package/src/themes/callcenterOriginal/src/components/Orders/AddressForm/index.js +1 -1
- package/src/themes/callcenterOriginal/src/components/PhoneAutocomplete/index.js +39 -11
- package/src/themes/callcenterOriginal/src/components/PhoneAutocomplete/styles.js +9 -4
- package/_bundles/ordering-ui.ac159b0ec9eb4a80c944.js +0 -2
- /package/_bundles/{7.ordering-ui.ac159b0ec9eb4a80c944.js.LICENSE.txt → 7.ordering-ui.c4b4f29a4f0c8eaad874.js.LICENSE.txt} +0 -0
- /package/_bundles/{ordering-ui.ac159b0ec9eb4a80c944.js.LICENSE.txt → ordering-ui.c4b4f29a4f0c8eaad874.js.LICENSE.txt} +0 -0
|
@@ -49,7 +49,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
49
49
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
50
50
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
51
51
|
var LoginFormUI = function LoginFormUI(props) {
|
|
52
|
-
var _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$google_login, _configs$apple_login_, _configs$google_login2, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag, _configs$facebook_log3, _configs$facebook_log4, _configs$facebook_id2, _configs$facebook_id3, _configs$google_login3, _configs$apple_login_2, _configs$twilio_servi, _configs$twilio_servi2, _props$afterComponent, _props$afterElements;
|
|
52
|
+
var _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$google_login, _configs$apple_login_, _configs$google_login2, _ref, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag, _configs$facebook_log3, _configs$facebook_log4, _configs$facebook_id2, _configs$facebook_id3, _configs$google_login3, _configs$apple_login_2, _configs$twilio_servi, _configs$twilio_servi2, _props$afterComponent, _props$afterElements;
|
|
53
53
|
var useLoginByEmail = props.useLoginByEmail,
|
|
54
54
|
useLoginByCellphone = props.useLoginByCellphone,
|
|
55
55
|
handleChangeInput = props.handleChangeInput,
|
|
@@ -118,8 +118,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
118
118
|
cookiepolicy: 'single_host_origin',
|
|
119
119
|
scope: 'profile'
|
|
120
120
|
};
|
|
121
|
-
var onSubmit =
|
|
122
|
-
|
|
121
|
+
var onSubmit = function onSubmit() {
|
|
122
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
123
123
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
124
124
|
while (1) switch (_context.prev = _context.next) {
|
|
125
125
|
case 0:
|
|
@@ -147,11 +147,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
147
147
|
return _context.stop();
|
|
148
148
|
}
|
|
149
149
|
}, _callee);
|
|
150
|
-
}));
|
|
151
|
-
|
|
152
|
-
return _ref.apply(this, arguments);
|
|
153
|
-
};
|
|
154
|
-
}();
|
|
150
|
+
}))).apply(this, arguments);
|
|
151
|
+
};
|
|
155
152
|
var handleSuccessFacebook = function handleSuccessFacebook(user) {
|
|
156
153
|
var _user$session;
|
|
157
154
|
login({
|
|
@@ -35,7 +35,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
35
35
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
36
36
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
37
37
|
var OrderTypeSelectorContentUI = function OrderTypeSelectorContentUI(props) {
|
|
38
|
-
var _configState$configs, _props$beforeElements, _props$beforeComponen, _props$afterComponent, _props$afterElements;
|
|
38
|
+
var _configState$configs, _ref2, _ref3, _props$beforeElements, _props$beforeComponen, _props$afterComponent, _props$afterElements;
|
|
39
39
|
var handleChangeOrderType = props.handleChangeOrderType,
|
|
40
40
|
orderTypes = props.orderTypes,
|
|
41
41
|
onClose = props.onClose,
|
|
@@ -105,8 +105,8 @@ var OrderTypeSelectorContentUI = function OrderTypeSelectorContentUI(props) {
|
|
|
105
105
|
label: label
|
|
106
106
|
});
|
|
107
107
|
};
|
|
108
|
-
var getPlaces =
|
|
109
|
-
|
|
108
|
+
var getPlaces = function getPlaces() {
|
|
109
|
+
return (_ref2 = _ref2 || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
110
110
|
var response, _yield$response$json, result, error;
|
|
111
111
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
112
112
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -150,13 +150,10 @@ var OrderTypeSelectorContentUI = function OrderTypeSelectorContentUI(props) {
|
|
|
150
150
|
return _context.stop();
|
|
151
151
|
}
|
|
152
152
|
}, _callee, null, [[0, 12]]);
|
|
153
|
-
}));
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
}();
|
|
158
|
-
var handleChangePlace = /*#__PURE__*/function () {
|
|
159
|
-
var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
|
|
153
|
+
}))).apply(this, arguments);
|
|
154
|
+
};
|
|
155
|
+
var handleChangePlace = function handleChangePlace() {
|
|
156
|
+
return (_ref3 = _ref3 || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
|
|
160
157
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
161
158
|
while (1) switch (_context2.prev = _context2.next) {
|
|
162
159
|
case 0:
|
|
@@ -192,11 +189,8 @@ var OrderTypeSelectorContentUI = function OrderTypeSelectorContentUI(props) {
|
|
|
192
189
|
return _context2.stop();
|
|
193
190
|
}
|
|
194
191
|
}, _callee2);
|
|
195
|
-
}));
|
|
196
|
-
|
|
197
|
-
return _ref3.apply(this, arguments);
|
|
198
|
-
};
|
|
199
|
-
}();
|
|
192
|
+
}))).apply(this, arguments);
|
|
193
|
+
};
|
|
200
194
|
var closeAlert = function closeAlert() {
|
|
201
195
|
setAlertState({
|
|
202
196
|
open: false,
|
|
@@ -36,7 +36,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
36
36
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
37
37
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
38
38
|
var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
39
|
-
var _theme$images, _theme$images2, _props$beforeElements, _props$beforeComponen, _props$afterComponent, _props$afterElements;
|
|
39
|
+
var _theme$images, _theme$images2, _ref, _props$beforeElements, _props$beforeComponen, _props$afterComponent, _props$afterElements;
|
|
40
40
|
var horizontal = props.horizontal,
|
|
41
41
|
activeOrders = props.activeOrders,
|
|
42
42
|
orderList = props.orderList,
|
|
@@ -84,8 +84,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
84
84
|
}).every(function (i) {
|
|
85
85
|
return !i;
|
|
86
86
|
}) : orders.length > 0;
|
|
87
|
-
var handleReorder =
|
|
88
|
-
|
|
87
|
+
var handleReorder = function handleReorder(_x) {
|
|
88
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderId) {
|
|
89
89
|
var _yield$reorder, _error, result;
|
|
90
90
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
91
91
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -122,11 +122,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
122
122
|
return _context.stop();
|
|
123
123
|
}
|
|
124
124
|
}, _callee, null, [[1, 13]]);
|
|
125
|
-
}));
|
|
126
|
-
|
|
127
|
-
return _ref.apply(this, arguments);
|
|
128
|
-
};
|
|
129
|
-
}();
|
|
125
|
+
}))).apply(this, arguments);
|
|
126
|
+
};
|
|
130
127
|
var getOrderStatus = function getOrderStatus(s) {
|
|
131
128
|
var _theme$defaultLanguag, _theme$defaultLanguag2, _theme$defaultLanguag3, _theme$defaultLanguag4, _theme$defaultLanguag5, _theme$defaultLanguag6, _theme$defaultLanguag7, _theme$defaultLanguag8, _theme$defaultLanguag9, _theme$defaultLanguag10, _theme$defaultLanguag11, _theme$defaultLanguag12, _theme$defaultLanguag13, _theme$defaultLanguag14, _theme$defaultLanguag15, _theme$defaultLanguag16, _theme$defaultLanguag17, _theme$defaultLanguag18, _theme$defaultLanguag19, _theme$defaultLanguag20, _theme$defaultLanguag21, _theme$defaultLanguag22, _theme$defaultLanguag23, _theme$defaultLanguag24;
|
|
132
129
|
var status = parseInt(s);
|
|
@@ -55,7 +55,7 @@ var inputNames = [{
|
|
|
55
55
|
code: 'Address notes'
|
|
56
56
|
}];
|
|
57
57
|
var AddressFormUI = function AddressFormUI(props) {
|
|
58
|
-
var _addressState$address, _ref, _formState$changes$ad, _formState$changes, _addressState$address2, _addressState$address3, _addressState$address4, _formState$changes$lo, _formState$changes2, _configState$configs, _configState$configs2, _configState$configs3, _configState$configs4, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _orderState$options6, _props$afterComponent, _props$afterElements;
|
|
58
|
+
var _addressState$address, _ref, _formState$changes$ad, _formState$changes, _addressState$address2, _addressState$address3, _addressState$address4, _formState$changes$lo, _formState$changes2, _configState$configs, _configState$configs2, _configState$configs3, _configState$configs4, _ref2, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _orderState$options6, _props$afterComponent, _props$afterElements;
|
|
59
59
|
var addressesList = props.addressesList,
|
|
60
60
|
googleMapsControls = props.googleMapsControls,
|
|
61
61
|
formState = props.formState,
|
|
@@ -234,8 +234,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
234
234
|
e.preventDefault();
|
|
235
235
|
}
|
|
236
236
|
};
|
|
237
|
-
var onSubmit =
|
|
238
|
-
|
|
237
|
+
var onSubmit = function onSubmit() {
|
|
238
|
+
return (_ref2 = _ref2 || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
239
239
|
var _formState$changes3, _addressState$address6, _formState$changes4, _formState$changes5, _arrayList$map$some2;
|
|
240
240
|
var _formState$changes6, arrayList, addressToCompare, isAddressAlreadyExist;
|
|
241
241
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
@@ -296,11 +296,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
296
296
|
return _context.stop();
|
|
297
297
|
}
|
|
298
298
|
}, _callee);
|
|
299
|
-
}));
|
|
300
|
-
|
|
301
|
-
return _ref2.apply(this, arguments);
|
|
302
|
-
};
|
|
303
|
-
}();
|
|
299
|
+
}))).apply(this, arguments);
|
|
300
|
+
};
|
|
304
301
|
var handleAddressTag = function handleAddressTag(tag) {
|
|
305
302
|
setAddressTag(tag);
|
|
306
303
|
handleChangeInput({
|
|
@@ -396,7 +396,7 @@ var CheckoutUI = function CheckoutUI(props) {
|
|
|
396
396
|
}));
|
|
397
397
|
};
|
|
398
398
|
var Checkout = function Checkout(props) {
|
|
399
|
-
var _Object$values2, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
399
|
+
var _Object$values2, _ref, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
400
400
|
var errors = props.errors,
|
|
401
401
|
clearErrors = props.clearErrors,
|
|
402
402
|
cartUuid = props.cartUuid,
|
|
@@ -486,8 +486,8 @@ var Checkout = function Checkout(props) {
|
|
|
486
486
|
});
|
|
487
487
|
}
|
|
488
488
|
}, [errors]);
|
|
489
|
-
var getOrder =
|
|
490
|
-
|
|
489
|
+
var getOrder = function getOrder(_x) {
|
|
490
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(cartId) {
|
|
491
491
|
var _result$order, userCustomer, url, response, _yield$response$json, result, _confirmCartRes$resul, confirmCartRes, cart;
|
|
492
492
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
493
493
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -581,11 +581,8 @@ var Checkout = function Checkout(props) {
|
|
|
581
581
|
return _context.stop();
|
|
582
582
|
}
|
|
583
583
|
}, _callee, null, [[0, 35], [17, 26]]);
|
|
584
|
-
}));
|
|
585
|
-
|
|
586
|
-
return _ref.apply(this, arguments);
|
|
587
|
-
};
|
|
588
|
-
}();
|
|
584
|
+
}))).apply(this, arguments);
|
|
585
|
+
};
|
|
589
586
|
(0, _react.useEffect)(function () {
|
|
590
587
|
if (token && cartUuid) {
|
|
591
588
|
getOrder(cartUuid);
|
|
@@ -24,6 +24,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
24
24
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
25
25
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
26
26
|
var Footer = function Footer() {
|
|
27
|
+
var _ref;
|
|
27
28
|
var _useState = (0, _react.useState)({
|
|
28
29
|
body: null,
|
|
29
30
|
loading: false,
|
|
@@ -36,8 +37,8 @@ var Footer = function Footer() {
|
|
|
36
37
|
_useApi2 = _slicedToArray(_useApi, 1),
|
|
37
38
|
ordering = _useApi2[0];
|
|
38
39
|
var requestsState = {};
|
|
39
|
-
var getPage =
|
|
40
|
-
|
|
40
|
+
var getPage = function getPage() {
|
|
41
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
41
42
|
var source, _yield$ordering$pages, _yield$ordering$pages2, error, result;
|
|
42
43
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
43
44
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -85,11 +86,8 @@ var Footer = function Footer() {
|
|
|
85
86
|
return _context.stop();
|
|
86
87
|
}
|
|
87
88
|
}, _callee, null, [[1, 14]]);
|
|
88
|
-
}));
|
|
89
|
-
|
|
90
|
-
return _ref.apply(this, arguments);
|
|
91
|
-
};
|
|
92
|
-
}();
|
|
89
|
+
}))).apply(this, arguments);
|
|
90
|
+
};
|
|
93
91
|
(0, _react.useEffect)(function () {
|
|
94
92
|
getPage();
|
|
95
93
|
return function () {
|
|
@@ -26,6 +26,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
26
26
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
27
27
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
28
28
|
var HelpStaticPage = function HelpStaticPage(props) {
|
|
29
|
+
var _ref;
|
|
29
30
|
var slug = props.slug;
|
|
30
31
|
var _useState = (0, _react.useState)({
|
|
31
32
|
body: null,
|
|
@@ -39,8 +40,8 @@ var HelpStaticPage = function HelpStaticPage(props) {
|
|
|
39
40
|
_useApi2 = _slicedToArray(_useApi, 1),
|
|
40
41
|
ordering = _useApi2[0];
|
|
41
42
|
var requestsState = {};
|
|
42
|
-
var getPage =
|
|
43
|
-
|
|
43
|
+
var getPage = function getPage() {
|
|
44
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
44
45
|
var source, _yield$ordering$pages, _yield$ordering$pages2, error, result;
|
|
45
46
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
46
47
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -88,11 +89,8 @@ var HelpStaticPage = function HelpStaticPage(props) {
|
|
|
88
89
|
return _context.stop();
|
|
89
90
|
}
|
|
90
91
|
}, _callee, null, [[1, 14]]);
|
|
91
|
-
}));
|
|
92
|
-
|
|
93
|
-
return _ref.apply(this, arguments);
|
|
94
|
-
};
|
|
95
|
-
}();
|
|
92
|
+
}))).apply(this, arguments);
|
|
93
|
+
};
|
|
96
94
|
(0, _react.useEffect)(function () {
|
|
97
95
|
getPage();
|
|
98
96
|
return function () {
|
|
@@ -48,7 +48,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
48
48
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
49
49
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
50
50
|
var LoginFormUI = function LoginFormUI(props) {
|
|
51
|
-
var _configs$google_login, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _configs$google_login2, _configs$apple_login_, _configs$twilio_servi, _configs$twilio_servi2, _props$afterComponent, _props$afterElements;
|
|
51
|
+
var _configs$google_login, _ref, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _configs$google_login2, _configs$apple_login_, _configs$twilio_servi, _configs$twilio_servi2, _props$afterComponent, _props$afterElements;
|
|
52
52
|
var useLoginByEmail = props.useLoginByEmail,
|
|
53
53
|
useLoginByCellphone = props.useLoginByCellphone,
|
|
54
54
|
handleChangeInput = props.handleChangeInput,
|
|
@@ -116,8 +116,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
116
116
|
cookiepolicy: 'single_host_origin',
|
|
117
117
|
scope: 'profile'
|
|
118
118
|
};
|
|
119
|
-
var onSubmit =
|
|
120
|
-
|
|
119
|
+
var onSubmit = function onSubmit() {
|
|
120
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
121
121
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
122
122
|
while (1) switch (_context.prev = _context.next) {
|
|
123
123
|
case 0:
|
|
@@ -145,11 +145,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
145
145
|
return _context.stop();
|
|
146
146
|
}
|
|
147
147
|
}, _callee);
|
|
148
|
-
}));
|
|
149
|
-
|
|
150
|
-
return _ref.apply(this, arguments);
|
|
151
|
-
};
|
|
152
|
-
}();
|
|
148
|
+
}))).apply(this, arguments);
|
|
149
|
+
};
|
|
153
150
|
var handleSuccessFacebook = function handleSuccessFacebook(user) {
|
|
154
151
|
var _user$session;
|
|
155
152
|
login({
|
|
@@ -36,7 +36,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
36
36
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
37
37
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
38
38
|
var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
39
|
-
var _theme$images, _theme$images2, _props$beforeElements, _props$beforeComponen, _props$afterComponent, _props$afterElements;
|
|
39
|
+
var _theme$images, _theme$images2, _ref, _props$beforeElements, _props$beforeComponen, _props$afterComponent, _props$afterElements;
|
|
40
40
|
var horizontal = props.horizontal,
|
|
41
41
|
activeOrders = props.activeOrders,
|
|
42
42
|
orderList = props.orderList,
|
|
@@ -76,8 +76,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
76
76
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
77
77
|
loadingOrders = _useState4[0],
|
|
78
78
|
setLoadingOrders = _useState4[1];
|
|
79
|
-
var handleReorder =
|
|
80
|
-
|
|
79
|
+
var handleReorder = function handleReorder(_x) {
|
|
80
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderId) {
|
|
81
81
|
var _yield$reorder, _error, result;
|
|
82
82
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
83
83
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -114,11 +114,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
114
114
|
return _context.stop();
|
|
115
115
|
}
|
|
116
116
|
}, _callee, null, [[1, 13]]);
|
|
117
|
-
}));
|
|
118
|
-
|
|
119
|
-
return _ref.apply(this, arguments);
|
|
120
|
-
};
|
|
121
|
-
}();
|
|
117
|
+
}))).apply(this, arguments);
|
|
118
|
+
};
|
|
122
119
|
var getOrderStatus = function getOrderStatus(s) {
|
|
123
120
|
var _theme$defaultLanguag, _theme$defaultLanguag2, _theme$defaultLanguag3, _theme$defaultLanguag4, _theme$defaultLanguag5, _theme$defaultLanguag6, _theme$defaultLanguag7, _theme$defaultLanguag8, _theme$defaultLanguag9, _theme$defaultLanguag10, _theme$defaultLanguag11, _theme$defaultLanguag12, _theme$defaultLanguag13, _theme$defaultLanguag14, _theme$defaultLanguag15, _theme$defaultLanguag16, _theme$defaultLanguag17, _theme$defaultLanguag18, _theme$defaultLanguag19, _theme$defaultLanguag20, _theme$defaultLanguag21, _theme$defaultLanguag22, _theme$defaultLanguag23, _theme$defaultLanguag24;
|
|
124
121
|
var status = parseInt(s);
|
|
@@ -54,7 +54,7 @@ var inputNames = [{
|
|
|
54
54
|
code: 'Address notes'
|
|
55
55
|
}];
|
|
56
56
|
var AddressFormUI = function AddressFormUI(props) {
|
|
57
|
-
var _addressState$address, _ref, _formState$changes$ad, _formState$changes, _addressState$address2, _addressState$address3, _addressState$address4, _formState$changes$lo, _formState$changes2, _configState$configs, _configState$configs2, _configState$configs3, _configState$configs4, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _orderState$options6, _props$afterComponent, _props$afterElements;
|
|
57
|
+
var _addressState$address, _ref, _formState$changes$ad, _formState$changes, _addressState$address2, _addressState$address3, _addressState$address4, _formState$changes$lo, _formState$changes2, _configState$configs, _configState$configs2, _configState$configs3, _configState$configs4, _ref2, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _orderState$options6, _props$afterComponent, _props$afterElements;
|
|
58
58
|
var addressesList = props.addressesList,
|
|
59
59
|
googleMapsControls = props.googleMapsControls,
|
|
60
60
|
formState = props.formState,
|
|
@@ -225,8 +225,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
225
225
|
e.preventDefault();
|
|
226
226
|
}
|
|
227
227
|
};
|
|
228
|
-
var onSubmit =
|
|
229
|
-
|
|
228
|
+
var onSubmit = function onSubmit() {
|
|
229
|
+
return (_ref2 = _ref2 || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
230
230
|
var _formState$changes3, _addressState$address6, _formState$changes4, _formState$changes5, _arrayList$map$some2;
|
|
231
231
|
var _formState$changes6, arrayList, addressToCompare, isAddressAlreadyExist;
|
|
232
232
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
@@ -286,11 +286,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
286
286
|
return _context.stop();
|
|
287
287
|
}
|
|
288
288
|
}, _callee);
|
|
289
|
-
}));
|
|
290
|
-
|
|
291
|
-
return _ref2.apply(this, arguments);
|
|
292
|
-
};
|
|
293
|
-
}();
|
|
289
|
+
}))).apply(this, arguments);
|
|
290
|
+
};
|
|
294
291
|
var handleAddressTag = function handleAddressTag(tag) {
|
|
295
292
|
setAddressTag(tag);
|
|
296
293
|
handleChangeInput({
|
|
@@ -394,7 +394,7 @@ var CheckoutUI = function CheckoutUI(props) {
|
|
|
394
394
|
}));
|
|
395
395
|
};
|
|
396
396
|
var Checkout = function Checkout(props) {
|
|
397
|
-
var _Object$values2, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
397
|
+
var _Object$values2, _ref, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
398
398
|
var errors = props.errors,
|
|
399
399
|
clearErrors = props.clearErrors,
|
|
400
400
|
cartUuid = props.cartUuid,
|
|
@@ -484,8 +484,8 @@ var Checkout = function Checkout(props) {
|
|
|
484
484
|
});
|
|
485
485
|
}
|
|
486
486
|
}, [errors]);
|
|
487
|
-
var getOrder =
|
|
488
|
-
|
|
487
|
+
var getOrder = function getOrder(_x) {
|
|
488
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(cartId) {
|
|
489
489
|
var _result$order, userCustomer, url, response, _yield$response$json, result, _confirmCartRes$resul, confirmCartRes, cart;
|
|
490
490
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
491
491
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -579,11 +579,8 @@ var Checkout = function Checkout(props) {
|
|
|
579
579
|
return _context.stop();
|
|
580
580
|
}
|
|
581
581
|
}, _callee, null, [[0, 35], [17, 26]]);
|
|
582
|
-
}));
|
|
583
|
-
|
|
584
|
-
return _ref.apply(this, arguments);
|
|
585
|
-
};
|
|
586
|
-
}();
|
|
582
|
+
}))).apply(this, arguments);
|
|
583
|
+
};
|
|
587
584
|
(0, _react.useEffect)(function () {
|
|
588
585
|
if (token && cartUuid) {
|
|
589
586
|
getOrder(cartUuid);
|
|
@@ -24,6 +24,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
24
24
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
25
25
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
26
26
|
var Footer = function Footer() {
|
|
27
|
+
var _ref;
|
|
27
28
|
var _useState = (0, _react.useState)({
|
|
28
29
|
body: null,
|
|
29
30
|
loading: false,
|
|
@@ -36,8 +37,8 @@ var Footer = function Footer() {
|
|
|
36
37
|
_useApi2 = _slicedToArray(_useApi, 1),
|
|
37
38
|
ordering = _useApi2[0];
|
|
38
39
|
var requestsState = {};
|
|
39
|
-
var getPage =
|
|
40
|
-
|
|
40
|
+
var getPage = function getPage() {
|
|
41
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
41
42
|
var source, _yield$ordering$pages, _yield$ordering$pages2, error, result;
|
|
42
43
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
43
44
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -85,11 +86,8 @@ var Footer = function Footer() {
|
|
|
85
86
|
return _context.stop();
|
|
86
87
|
}
|
|
87
88
|
}, _callee, null, [[1, 14]]);
|
|
88
|
-
}));
|
|
89
|
-
|
|
90
|
-
return _ref.apply(this, arguments);
|
|
91
|
-
};
|
|
92
|
-
}();
|
|
89
|
+
}))).apply(this, arguments);
|
|
90
|
+
};
|
|
93
91
|
(0, _react.useEffect)(function () {
|
|
94
92
|
getPage();
|
|
95
93
|
return function () {
|
|
@@ -44,7 +44,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
44
44
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
45
45
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
46
46
|
var LoginFormUI = function LoginFormUI(props) {
|
|
47
|
-
var _configs$google_login, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _configs$apple_login_, _configs$google_login2, _configs$twilio_servi, _configs$twilio_servi2, _props$afterComponent, _props$afterElements;
|
|
47
|
+
var _configs$google_login, _ref, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _configs$apple_login_, _configs$google_login2, _configs$twilio_servi, _configs$twilio_servi2, _props$afterComponent, _props$afterElements;
|
|
48
48
|
var useLoginByEmail = props.useLoginByEmail,
|
|
49
49
|
useLoginByCellphone = props.useLoginByCellphone,
|
|
50
50
|
handleChangeInput = props.handleChangeInput,
|
|
@@ -121,8 +121,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
121
121
|
cookiepolicy: 'single_host_origin',
|
|
122
122
|
scope: 'profile'
|
|
123
123
|
};
|
|
124
|
-
var onSubmit =
|
|
125
|
-
|
|
124
|
+
var onSubmit = function onSubmit() {
|
|
125
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
126
126
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
127
127
|
while (1) switch (_context.prev = _context.next) {
|
|
128
128
|
case 0:
|
|
@@ -150,11 +150,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
150
150
|
return _context.stop();
|
|
151
151
|
}
|
|
152
152
|
}, _callee);
|
|
153
|
-
}));
|
|
154
|
-
|
|
155
|
-
return _ref.apply(this, arguments);
|
|
156
|
-
};
|
|
157
|
-
}();
|
|
153
|
+
}))).apply(this, arguments);
|
|
154
|
+
};
|
|
158
155
|
var handleSuccessFacebook = function handleSuccessFacebook(user) {
|
|
159
156
|
var _user$session;
|
|
160
157
|
login({
|
|
@@ -36,7 +36,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
36
36
|
function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
|
|
37
37
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
38
38
|
var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
39
|
-
var _theme$images, _theme$images2, _props$beforeElements, _props$beforeComponen, _orders$filter, _props$afterComponent, _props$afterElements;
|
|
39
|
+
var _theme$images, _theme$images2, _ref, _props$beforeElements, _props$beforeComponen, _orders$filter, _props$afterComponent, _props$afterElements;
|
|
40
40
|
var horizontal = props.horizontal,
|
|
41
41
|
activeOrders = props.activeOrders,
|
|
42
42
|
orderList = props.orderList,
|
|
@@ -85,8 +85,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
85
85
|
}).every(function (i) {
|
|
86
86
|
return !i;
|
|
87
87
|
}) : orders.length > 0;
|
|
88
|
-
var handleReorder =
|
|
89
|
-
|
|
88
|
+
var handleReorder = function handleReorder(_x) {
|
|
89
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderId) {
|
|
90
90
|
var _yield$reorder, _error, result;
|
|
91
91
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
92
92
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -123,11 +123,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
123
123
|
return _context.stop();
|
|
124
124
|
}
|
|
125
125
|
}, _callee, null, [[1, 13]]);
|
|
126
|
-
}));
|
|
127
|
-
|
|
128
|
-
return _ref.apply(this, arguments);
|
|
129
|
-
};
|
|
130
|
-
}();
|
|
126
|
+
}))).apply(this, arguments);
|
|
127
|
+
};
|
|
131
128
|
var getOrderStatus = function getOrderStatus(s) {
|
|
132
129
|
var _theme$defaultLanguag, _theme$defaultLanguag2, _theme$defaultLanguag3, _theme$defaultLanguag4, _theme$defaultLanguag5, _theme$defaultLanguag6, _theme$defaultLanguag7, _theme$defaultLanguag8, _theme$defaultLanguag9, _theme$defaultLanguag10, _theme$defaultLanguag11, _theme$defaultLanguag12, _theme$defaultLanguag13, _theme$defaultLanguag14, _theme$defaultLanguag15, _theme$defaultLanguag16, _theme$defaultLanguag17, _theme$defaultLanguag18, _theme$defaultLanguag19, _theme$defaultLanguag20, _theme$defaultLanguag21, _theme$defaultLanguag22, _theme$defaultLanguag23, _theme$defaultLanguag24;
|
|
133
130
|
var status = parseInt(s);
|
|
@@ -33,7 +33,7 @@ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; } // import
|
|
|
33
33
|
// import { useConfig } from '../../contexts/ConfigContext'
|
|
34
34
|
// import { useApi } from '../../contexts/ApiContext'
|
|
35
35
|
var ProductForm = function ProductForm(props) {
|
|
36
|
-
var _props$productCart, _orderState$carts, _cart$products, _cart$products2, _product$product, _product$product2, _product$product3, _product$product4;
|
|
36
|
+
var _props$productCart, _orderState$carts, _cart$products, _cart$products2, _product$product, _product$product2, _product$product3, _product$product4, _ref, _ref3;
|
|
37
37
|
var UIComponent = props.UIComponent,
|
|
38
38
|
useOrderContext = props.useOrderContext,
|
|
39
39
|
onSave = props.onSave,
|
|
@@ -229,8 +229,8 @@ var ProductForm = function ProductForm(props) {
|
|
|
229
229
|
/**
|
|
230
230
|
* Load product from API
|
|
231
231
|
*/
|
|
232
|
-
var loadProductWithOptions =
|
|
233
|
-
|
|
232
|
+
var loadProductWithOptions = function loadProductWithOptions() {
|
|
233
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
234
234
|
var source, _yield$ordering$busin, result;
|
|
235
235
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
236
236
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -266,11 +266,8 @@ var ProductForm = function ProductForm(props) {
|
|
|
266
266
|
return _context.stop();
|
|
267
267
|
}
|
|
268
268
|
}, _callee, null, [[0, 11]]);
|
|
269
|
-
}));
|
|
270
|
-
|
|
271
|
-
return _ref.apply(this, arguments);
|
|
272
|
-
};
|
|
273
|
-
}();
|
|
269
|
+
}))).apply(this, arguments);
|
|
270
|
+
};
|
|
274
271
|
|
|
275
272
|
/**
|
|
276
273
|
* Remove related option by respect_to
|
|
@@ -459,8 +456,8 @@ var ProductForm = function ProductForm(props) {
|
|
|
459
456
|
/**
|
|
460
457
|
* Handle when click on save product
|
|
461
458
|
*/
|
|
462
|
-
var handleSave =
|
|
463
|
-
|
|
459
|
+
var handleSave = function handleSave() {
|
|
460
|
+
return (_ref3 = _ref3 || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2() {
|
|
464
461
|
var errors, successful, _props$productCart6, _props$productCart7;
|
|
465
462
|
return _regeneratorRuntime().wrap(function _callee2$(_context2) {
|
|
466
463
|
while (1) switch (_context2.prev = _context2.next) {
|
|
@@ -507,11 +504,8 @@ var ProductForm = function ProductForm(props) {
|
|
|
507
504
|
return _context2.stop();
|
|
508
505
|
}
|
|
509
506
|
}, _callee2);
|
|
510
|
-
}));
|
|
511
|
-
|
|
512
|
-
return _ref3.apply(this, arguments);
|
|
513
|
-
};
|
|
514
|
-
}();
|
|
507
|
+
}))).apply(this, arguments);
|
|
508
|
+
};
|
|
515
509
|
var increment = function increment() {
|
|
516
510
|
if (maxProductQuantity <= 0 || productCart.quantity >= maxProductQuantity) {
|
|
517
511
|
return;
|
|
@@ -54,7 +54,7 @@ var inputNames = [{
|
|
|
54
54
|
code: 'Address notes'
|
|
55
55
|
}];
|
|
56
56
|
var AddressFormUI = function AddressFormUI(props) {
|
|
57
|
-
var _addressState$address, _ref, _formState$changes$ad, _formState$changes, _addressState$address2, _addressState$address3, _addressState$address4, _formState$changes$lo, _formState$changes2, _configState$configs, _configState$configs2, _configState$configs3, _configState$configs4, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _orderState$options6, _props$afterComponent, _props$afterElements;
|
|
57
|
+
var _addressState$address, _ref, _formState$changes$ad, _formState$changes, _addressState$address2, _addressState$address3, _addressState$address4, _formState$changes$lo, _formState$changes2, _configState$configs, _configState$configs2, _configState$configs3, _configState$configs4, _ref2, _props$beforeElements, _props$beforeComponen, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _orderState$options6, _props$afterComponent, _props$afterElements;
|
|
58
58
|
var addressesList = props.addressesList,
|
|
59
59
|
googleMapsControls = props.googleMapsControls,
|
|
60
60
|
formState = props.formState,
|
|
@@ -232,8 +232,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
232
232
|
e.preventDefault();
|
|
233
233
|
}
|
|
234
234
|
};
|
|
235
|
-
var onSubmit =
|
|
236
|
-
|
|
235
|
+
var onSubmit = function onSubmit() {
|
|
236
|
+
return (_ref2 = _ref2 || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
237
237
|
var _formState$changes3, _addressState$address6, _formState$changes4, _formState$changes5, _arrayList$map$some2;
|
|
238
238
|
var _formState$changes6, arrayList, addressToCompare, isAddressAlreadyExist;
|
|
239
239
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
@@ -293,11 +293,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
293
293
|
return _context.stop();
|
|
294
294
|
}
|
|
295
295
|
}, _callee);
|
|
296
|
-
}));
|
|
297
|
-
|
|
298
|
-
return _ref2.apply(this, arguments);
|
|
299
|
-
};
|
|
300
|
-
}();
|
|
296
|
+
}))).apply(this, arguments);
|
|
297
|
+
};
|
|
301
298
|
var handleAddressTag = function handleAddressTag(tag) {
|
|
302
299
|
setAddressTag(tag);
|
|
303
300
|
handleChangeInput({
|
|
@@ -315,7 +315,7 @@ var CheckoutUI = function CheckoutUI(props) {
|
|
|
315
315
|
}));
|
|
316
316
|
};
|
|
317
317
|
var Checkout = function Checkout(props) {
|
|
318
|
-
var _Object$values, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
318
|
+
var _Object$values, _ref, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
319
319
|
var errors = props.errors,
|
|
320
320
|
clearErrors = props.clearErrors,
|
|
321
321
|
cartUuid = props.cartUuid,
|
|
@@ -406,8 +406,8 @@ var Checkout = function Checkout(props) {
|
|
|
406
406
|
});
|
|
407
407
|
}
|
|
408
408
|
}, [errors]);
|
|
409
|
-
var getOrder =
|
|
410
|
-
|
|
409
|
+
var getOrder = function getOrder(_x) {
|
|
410
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(cartId) {
|
|
411
411
|
var _result$order, userCustomer, url, response, _yield$response$json, result, _confirmCartRes$resul, confirmCartRes, cart;
|
|
412
412
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
413
413
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -501,11 +501,8 @@ var Checkout = function Checkout(props) {
|
|
|
501
501
|
return _context.stop();
|
|
502
502
|
}
|
|
503
503
|
}, _callee, null, [[0, 35], [17, 26]]);
|
|
504
|
-
}));
|
|
505
|
-
|
|
506
|
-
return _ref.apply(this, arguments);
|
|
507
|
-
};
|
|
508
|
-
}();
|
|
504
|
+
}))).apply(this, arguments);
|
|
505
|
+
};
|
|
509
506
|
(0, _react.useEffect)(function () {
|
|
510
507
|
if (token && cartUuid) {
|
|
511
508
|
getOrder(cartUuid);
|