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
|
@@ -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 () {
|
|
@@ -47,7 +47,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
47
47
|
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; } }
|
|
48
48
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
49
49
|
var LoginFormUI = function LoginFormUI(props) {
|
|
50
|
-
var _configs$google_login, _props$beforeElements, _props$beforeComponen, _theme$images, _theme$defaultLanguag, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag2, _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;
|
|
50
|
+
var _configs$google_login, _ref, _props$beforeElements, _props$beforeComponen, _theme$images, _theme$defaultLanguag, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag2, _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;
|
|
51
51
|
var useLoginByEmail = props.useLoginByEmail,
|
|
52
52
|
useLoginByCellphone = props.useLoginByCellphone,
|
|
53
53
|
handleChangeInput = props.handleChangeInput,
|
|
@@ -125,8 +125,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
125
125
|
cookiepolicy: 'single_host_origin',
|
|
126
126
|
scope: 'profile'
|
|
127
127
|
};
|
|
128
|
-
var onSubmit =
|
|
129
|
-
|
|
128
|
+
var onSubmit = function onSubmit() {
|
|
129
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
130
130
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
131
131
|
while (1) switch (_context.prev = _context.next) {
|
|
132
132
|
case 0:
|
|
@@ -154,11 +154,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
154
154
|
return _context.stop();
|
|
155
155
|
}
|
|
156
156
|
}, _callee);
|
|
157
|
-
}));
|
|
158
|
-
|
|
159
|
-
return _ref.apply(this, arguments);
|
|
160
|
-
};
|
|
161
|
-
}();
|
|
157
|
+
}))).apply(this, arguments);
|
|
158
|
+
};
|
|
162
159
|
var handleSuccessFacebook = function handleSuccessFacebook(user) {
|
|
163
160
|
var _user$session;
|
|
164
161
|
login({
|
|
@@ -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,
|
|
@@ -236,8 +236,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
236
236
|
e.preventDefault();
|
|
237
237
|
}
|
|
238
238
|
};
|
|
239
|
-
var onSubmit =
|
|
240
|
-
|
|
239
|
+
var onSubmit = function onSubmit() {
|
|
240
|
+
return (_ref2 = _ref2 || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
241
241
|
var _formState$changes3, _addressState$address6, _formState$changes4, _formState$changes5, _arrayList$map$some2;
|
|
242
242
|
var _formState$changes6, arrayList, addressToCompare, isAddressAlreadyExist;
|
|
243
243
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
@@ -298,11 +298,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
298
298
|
return _context.stop();
|
|
299
299
|
}
|
|
300
300
|
}, _callee);
|
|
301
|
-
}));
|
|
302
|
-
|
|
303
|
-
return _ref2.apply(this, arguments);
|
|
304
|
-
};
|
|
305
|
-
}();
|
|
301
|
+
}))).apply(this, arguments);
|
|
302
|
+
};
|
|
306
303
|
var handleAddressTag = function handleAddressTag(tag) {
|
|
307
304
|
setAddressTag(tag);
|
|
308
305
|
handleChangeInput({
|
|
@@ -522,7 +522,7 @@ var CheckoutUI = function CheckoutUI(props) {
|
|
|
522
522
|
}));
|
|
523
523
|
};
|
|
524
524
|
var Checkout = function Checkout(props) {
|
|
525
|
-
var _Object$values2, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
525
|
+
var _Object$values2, _ref, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
526
526
|
var errors = props.errors,
|
|
527
527
|
clearErrors = props.clearErrors,
|
|
528
528
|
query = props.query,
|
|
@@ -613,8 +613,8 @@ var Checkout = function Checkout(props) {
|
|
|
613
613
|
});
|
|
614
614
|
}
|
|
615
615
|
}, [errors]);
|
|
616
|
-
var getOrder =
|
|
617
|
-
|
|
616
|
+
var getOrder = function getOrder(_x) {
|
|
617
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(cartId) {
|
|
618
618
|
var _result$order, userCustomer, url, response, _yield$response$json, result, _confirmCartRes$resul, confirmCartRes, cart;
|
|
619
619
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
620
620
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -708,11 +708,8 @@ var Checkout = function Checkout(props) {
|
|
|
708
708
|
return _context.stop();
|
|
709
709
|
}
|
|
710
710
|
}, _callee, null, [[0, 35], [17, 26]]);
|
|
711
|
-
}));
|
|
712
|
-
|
|
713
|
-
return _ref.apply(this, arguments);
|
|
714
|
-
};
|
|
715
|
-
}();
|
|
711
|
+
}))).apply(this, arguments);
|
|
712
|
+
};
|
|
716
713
|
(0, _react.useEffect)(function () {
|
|
717
714
|
if (token && cartUuid) {
|
|
718
715
|
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 () {
|
|
@@ -46,7 +46,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
46
46
|
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; } }
|
|
47
47
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
48
48
|
var LoginFormUI = function LoginFormUI(props) {
|
|
49
|
-
var _props$beforeElements, _props$beforeComponen, _theme$images, _theme$defaultLanguag, _theme$defaultLanguag2, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag3, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _configs$apple_login_, _configs$twilio_servi, _configs$twilio_servi2, _props$afterComponent, _props$afterElements;
|
|
49
|
+
var _ref, _props$beforeElements, _props$beforeComponen, _theme$images, _theme$defaultLanguag, _theme$defaultLanguag2, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag3, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _configs$apple_login_, _configs$twilio_servi, _configs$twilio_servi2, _props$afterComponent, _props$afterElements;
|
|
50
50
|
var useLoginByEmail = props.useLoginByEmail,
|
|
51
51
|
useLoginByCellphone = props.useLoginByCellphone,
|
|
52
52
|
handleChangeInput = props.handleChangeInput,
|
|
@@ -119,8 +119,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
119
119
|
otpLeftTime = _useCountdownTimer2[0],
|
|
120
120
|
_ = _useCountdownTimer2[1],
|
|
121
121
|
resetOtpLeftTime = _useCountdownTimer2[2];
|
|
122
|
-
var onSubmit =
|
|
123
|
-
|
|
122
|
+
var onSubmit = function onSubmit() {
|
|
123
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
124
124
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
125
125
|
while (1) switch (_context.prev = _context.next) {
|
|
126
126
|
case 0:
|
|
@@ -148,11 +148,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
148
148
|
return _context.stop();
|
|
149
149
|
}
|
|
150
150
|
}, _callee);
|
|
151
|
-
}));
|
|
152
|
-
|
|
153
|
-
return _ref.apply(this, arguments);
|
|
154
|
-
};
|
|
155
|
-
}();
|
|
151
|
+
}))).apply(this, arguments);
|
|
152
|
+
};
|
|
156
153
|
var handleSuccessFacebook = function handleSuccessFacebook(user) {
|
|
157
154
|
var _user$session;
|
|
158
155
|
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,
|
|
@@ -72,8 +72,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
72
72
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
73
73
|
reorderLoading = _useState4[0],
|
|
74
74
|
setReorderLoading = _useState4[1];
|
|
75
|
-
var handleReorder =
|
|
76
|
-
|
|
75
|
+
var handleReorder = function handleReorder(_x) {
|
|
76
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderId) {
|
|
77
77
|
var _yield$reorder, _error, result;
|
|
78
78
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
79
79
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -110,11 +110,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
110
110
|
return _context.stop();
|
|
111
111
|
}
|
|
112
112
|
}, _callee, null, [[1, 13]]);
|
|
113
|
-
}));
|
|
114
|
-
|
|
115
|
-
return _ref.apply(this, arguments);
|
|
116
|
-
};
|
|
117
|
-
}();
|
|
113
|
+
}))).apply(this, arguments);
|
|
114
|
+
};
|
|
118
115
|
var getOrderStatus = function getOrderStatus(s) {
|
|
119
116
|
var status = parseInt(s);
|
|
120
117
|
var orderStatus = [{
|
|
@@ -493,7 +493,7 @@ var CheckoutUI = function CheckoutUI(props) {
|
|
|
493
493
|
}));
|
|
494
494
|
};
|
|
495
495
|
var Checkout = function Checkout(props) {
|
|
496
|
-
var _Object$values2, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
496
|
+
var _Object$values2, _ref, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
497
497
|
var errors = props.errors,
|
|
498
498
|
clearErrors = props.clearErrors,
|
|
499
499
|
cartUuid = props.cartUuid,
|
|
@@ -583,8 +583,8 @@ var Checkout = function Checkout(props) {
|
|
|
583
583
|
});
|
|
584
584
|
}
|
|
585
585
|
}, [errors]);
|
|
586
|
-
var getOrder =
|
|
587
|
-
|
|
586
|
+
var getOrder = function getOrder(_x) {
|
|
587
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(cartId) {
|
|
588
588
|
var _result$order, userCustomer, url, response, _yield$response$json, result, _confirmCartRes$resul, confirmCartRes, cart;
|
|
589
589
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
590
590
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -678,11 +678,8 @@ var Checkout = function Checkout(props) {
|
|
|
678
678
|
return _context.stop();
|
|
679
679
|
}
|
|
680
680
|
}, _callee, null, [[0, 35], [17, 26]]);
|
|
681
|
-
}));
|
|
682
|
-
|
|
683
|
-
return _ref.apply(this, arguments);
|
|
684
|
-
};
|
|
685
|
-
}();
|
|
681
|
+
}))).apply(this, arguments);
|
|
682
|
+
};
|
|
686
683
|
(0, _react.useEffect)(function () {
|
|
687
684
|
if (token && cartUuid) {
|
|
688
685
|
getOrder(cartUuid);
|
|
@@ -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 () {
|
|
@@ -46,7 +46,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
46
46
|
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; } }
|
|
47
47
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
48
48
|
var LoginFormUI = function LoginFormUI(props) {
|
|
49
|
-
var _props$beforeElements, _props$beforeComponen, _theme$defaultLanguag, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _configs$apple_login_, _configs$twilio_servi, _configs$twilio_servi2, _theme$defaultLanguag2, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _props$afterComponent, _props$afterElements;
|
|
49
|
+
var _ref, _props$beforeElements, _props$beforeComponen, _theme$defaultLanguag, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _configs$apple_login_, _configs$twilio_servi, _configs$twilio_servi2, _theme$defaultLanguag2, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _props$afterComponent, _props$afterElements;
|
|
50
50
|
var useLoginByEmail = props.useLoginByEmail,
|
|
51
51
|
useLoginByCellphone = props.useLoginByCellphone,
|
|
52
52
|
handleChangeInput = props.handleChangeInput,
|
|
@@ -119,8 +119,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
119
119
|
otpLeftTime = _useCountdownTimer2[0],
|
|
120
120
|
_ = _useCountdownTimer2[1],
|
|
121
121
|
resetOtpLeftTime = _useCountdownTimer2[2];
|
|
122
|
-
var onSubmit =
|
|
123
|
-
|
|
122
|
+
var onSubmit = function onSubmit() {
|
|
123
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
124
124
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
125
125
|
while (1) switch (_context.prev = _context.next) {
|
|
126
126
|
case 0:
|
|
@@ -148,11 +148,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
148
148
|
return _context.stop();
|
|
149
149
|
}
|
|
150
150
|
}, _callee);
|
|
151
|
-
}));
|
|
152
|
-
|
|
153
|
-
return _ref.apply(this, arguments);
|
|
154
|
-
};
|
|
155
|
-
}();
|
|
151
|
+
}))).apply(this, arguments);
|
|
152
|
+
};
|
|
156
153
|
var handleSuccessFacebook = function handleSuccessFacebook(user) {
|
|
157
154
|
var _user$session;
|
|
158
155
|
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,
|
|
@@ -72,8 +72,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
72
72
|
_useState4 = _slicedToArray(_useState3, 2),
|
|
73
73
|
reorderLoading = _useState4[0],
|
|
74
74
|
setReorderLoading = _useState4[1];
|
|
75
|
-
var handleReorder =
|
|
76
|
-
|
|
75
|
+
var handleReorder = function handleReorder(_x) {
|
|
76
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderId) {
|
|
77
77
|
var _yield$reorder, _error, result;
|
|
78
78
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
79
79
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -110,11 +110,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
110
110
|
return _context.stop();
|
|
111
111
|
}
|
|
112
112
|
}, _callee, null, [[1, 13]]);
|
|
113
|
-
}));
|
|
114
|
-
|
|
115
|
-
return _ref.apply(this, arguments);
|
|
116
|
-
};
|
|
117
|
-
}();
|
|
113
|
+
}))).apply(this, arguments);
|
|
114
|
+
};
|
|
118
115
|
var getOrderStatus = function getOrderStatus(s) {
|
|
119
116
|
var status = parseInt(s);
|
|
120
117
|
var orderStatus = [{
|
|
@@ -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, _configState$configs5, _ref9, _formState$changes$in, _formState$changes26, _ref10, _formState$changes$zi, _formState$changes27, _ref11, _formState$changes$ad5, _formState$changes28, _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, _configState$configs5, _ref9, _formState$changes$in, _formState$changes26, _ref10, _formState$changes$zi, _formState$changes27, _ref11, _formState$changes$ad5, _formState$changes28, _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,
|
|
@@ -231,8 +231,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
231
231
|
e.preventDefault();
|
|
232
232
|
}
|
|
233
233
|
};
|
|
234
|
-
var onSubmit =
|
|
235
|
-
|
|
234
|
+
var onSubmit = function onSubmit() {
|
|
235
|
+
return (_ref2 = _ref2 || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
236
236
|
var _formState$changes3, _addressState$address6, _formState$changes4, _formState$changes5, _arrayList$map$some2;
|
|
237
237
|
var _formState$changes6, arrayList, addressToCompare, isAddressAlreadyExist;
|
|
238
238
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
@@ -292,11 +292,8 @@ var AddressFormUI = function AddressFormUI(props) {
|
|
|
292
292
|
return _context.stop();
|
|
293
293
|
}
|
|
294
294
|
}, _callee);
|
|
295
|
-
}));
|
|
296
|
-
|
|
297
|
-
return _ref2.apply(this, arguments);
|
|
298
|
-
};
|
|
299
|
-
}();
|
|
295
|
+
}))).apply(this, arguments);
|
|
296
|
+
};
|
|
300
297
|
var handleAddressTag = function handleAddressTag(tag) {
|
|
301
298
|
setAddressTag(tag);
|
|
302
299
|
handleChangeInput({
|
|
@@ -265,7 +265,7 @@ var CheckoutUI = function CheckoutUI(props) {
|
|
|
265
265
|
}));
|
|
266
266
|
};
|
|
267
267
|
var Checkout = function Checkout(props) {
|
|
268
|
-
var _Object$values, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
268
|
+
var _Object$values, _ref, _cartState$cart, _cartState$error, _cartState$cart2;
|
|
269
269
|
var errors = props.errors,
|
|
270
270
|
clearErrors = props.clearErrors,
|
|
271
271
|
query = props.query,
|
|
@@ -352,8 +352,8 @@ var Checkout = function Checkout(props) {
|
|
|
352
352
|
});
|
|
353
353
|
}
|
|
354
354
|
}, [errors]);
|
|
355
|
-
var getOrder =
|
|
356
|
-
|
|
355
|
+
var getOrder = function getOrder(_x) {
|
|
356
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(cartId) {
|
|
357
357
|
var _result$order, _result$paymethod_dat, userCustomer, url, response, _yield$response$json, result, _confirmCartRes$resul, confirmCartRes, cart;
|
|
358
358
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
359
359
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -446,11 +446,8 @@ var Checkout = function Checkout(props) {
|
|
|
446
446
|
return _context.stop();
|
|
447
447
|
}
|
|
448
448
|
}, _callee, null, [[0, 35], [17, 26]]);
|
|
449
|
-
}));
|
|
450
|
-
|
|
451
|
-
return _ref.apply(this, arguments);
|
|
452
|
-
};
|
|
453
|
-
}();
|
|
449
|
+
}))).apply(this, arguments);
|
|
450
|
+
};
|
|
454
451
|
(0, _react.useEffect)(function () {
|
|
455
452
|
if (token && cartUuid) {
|
|
456
453
|
getOrder(cartUuid);
|
|
@@ -42,7 +42,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
42
42
|
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; } }
|
|
43
43
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
44
44
|
var LoginFormUI = function LoginFormUI(props) {
|
|
45
|
-
var _props$beforeElements, _props$beforeComponen, _theme$images, _theme$defaultLanguag, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag2, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _props$afterComponent, _props$afterElements;
|
|
45
|
+
var _ref, _props$beforeElements, _props$beforeComponen, _theme$images, _theme$defaultLanguag, _props$beforeMidEleme, _props$beforeMidCompo, _props$afterMidElemen, _props$afterMidCompon, _theme$defaultLanguag2, _configs$facebook_log, _configs$facebook_log2, _configs$facebook_id, _configs$facebook_id2, _props$afterComponent, _props$afterElements;
|
|
46
46
|
var useLoginByEmail = props.useLoginByEmail,
|
|
47
47
|
useLoginByCellphone = props.useLoginByCellphone,
|
|
48
48
|
handleChangeInput = props.handleChangeInput,
|
|
@@ -77,8 +77,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
77
77
|
passwordSee = _useState4[0],
|
|
78
78
|
setPasswordSee = _useState4[1];
|
|
79
79
|
var emailInput = (0, _react.useRef)(null);
|
|
80
|
-
var onSubmit =
|
|
81
|
-
|
|
80
|
+
var onSubmit = function onSubmit() {
|
|
81
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
82
82
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
83
83
|
while (1) switch (_context.prev = _context.next) {
|
|
84
84
|
case 0:
|
|
@@ -88,11 +88,8 @@ var LoginFormUI = function LoginFormUI(props) {
|
|
|
88
88
|
return _context.stop();
|
|
89
89
|
}
|
|
90
90
|
}, _callee);
|
|
91
|
-
}));
|
|
92
|
-
|
|
93
|
-
return _ref.apply(this, arguments);
|
|
94
|
-
};
|
|
95
|
-
}();
|
|
91
|
+
}))).apply(this, arguments);
|
|
92
|
+
};
|
|
96
93
|
var handleSuccessFacebook = function handleSuccessFacebook(user) {
|
|
97
94
|
var _user$session;
|
|
98
95
|
login({
|
|
@@ -32,7 +32,7 @@ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len
|
|
|
32
32
|
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; } }
|
|
33
33
|
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
34
34
|
var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
35
|
-
var _theme$images, _theme$images2, _theme$images3, _props$beforeElements, _props$beforeComponen, _props$afterComponent, _props$afterElements;
|
|
35
|
+
var _theme$images, _theme$images2, _theme$images3, _ref, _props$beforeElements, _props$beforeComponen, _props$afterComponent, _props$afterElements;
|
|
36
36
|
var isProfile = props.isProfile,
|
|
37
37
|
activeOrders = props.activeOrders,
|
|
38
38
|
previousOrders = props.previousOrders,
|
|
@@ -119,8 +119,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
119
119
|
});
|
|
120
120
|
return objectStatus && objectStatus;
|
|
121
121
|
};
|
|
122
|
-
var handleReorder =
|
|
123
|
-
|
|
122
|
+
var handleReorder = function handleReorder(_x) {
|
|
123
|
+
return (_ref = _ref || _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(orderId) {
|
|
124
124
|
var _yield$reorder, error, result;
|
|
125
125
|
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
126
126
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -152,11 +152,8 @@ var OrdersOptionUI = function OrdersOptionUI(props) {
|
|
|
152
152
|
return _context.stop();
|
|
153
153
|
}
|
|
154
154
|
}, _callee, null, [[1, 10]]);
|
|
155
|
-
}));
|
|
156
|
-
|
|
157
|
-
return _ref.apply(this, arguments);
|
|
158
|
-
};
|
|
159
|
-
}();
|
|
155
|
+
}))).apply(this, arguments);
|
|
156
|
+
};
|
|
160
157
|
(0, _react.useEffect)(function () {
|
|
161
158
|
var ordersSorted = orders.sort(function (a, b) {
|
|
162
159
|
if (activeOrders) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ordering-ui-external",
|
|
3
|
-
"version": "10.9.
|
|
3
|
+
"version": "10.9.1",
|
|
4
4
|
"description": "Ordering UI Components",
|
|
5
5
|
"main": "./_modules/index.js",
|
|
6
6
|
"exports": {
|
|
@@ -88,7 +88,7 @@
|
|
|
88
88
|
"lodash": "^4.17.19",
|
|
89
89
|
"moment": "^2.29.4",
|
|
90
90
|
"nanoid": "^4.0.0",
|
|
91
|
-
"ordering-components-external": "9.9.
|
|
91
|
+
"ordering-components-external": "9.9.1",
|
|
92
92
|
"payment": "^2.4.6",
|
|
93
93
|
"polished": "^3.6.6",
|
|
94
94
|
"react-bootstrap-icons": "^1.7.2",
|
|
@@ -20,14 +20,14 @@ const AddressDetailsUI = (props) => {
|
|
|
20
20
|
googleMapsUrl,
|
|
21
21
|
isCustomerMode,
|
|
22
22
|
apiKey,
|
|
23
|
-
isFromCheckout
|
|
23
|
+
isFromCheckout,
|
|
24
|
+
notUseCustomerInfo
|
|
24
25
|
} = props
|
|
25
26
|
|
|
26
27
|
const [orderState] = useOrder()
|
|
27
28
|
const [, t] = useLanguage()
|
|
28
29
|
const [openModal, setOpenModal] = useState(false)
|
|
29
30
|
const [alertState, setAlertState] = useState({ open: false, content: [] })
|
|
30
|
-
const userCustomer = JSON.parse(window.localStorage.getItem('user-customer'))
|
|
31
31
|
const [{ user }] = useCustomer()
|
|
32
32
|
|
|
33
33
|
const handleFindBusinesses = () => {
|
|
@@ -42,6 +42,12 @@ const AddressDetailsUI = (props) => {
|
|
|
42
42
|
return () => setOpenModal(false)
|
|
43
43
|
}, [])
|
|
44
44
|
|
|
45
|
+
useEffect(() => {
|
|
46
|
+
if (isCustomerMode) {
|
|
47
|
+
setOpenModal(false)
|
|
48
|
+
}
|
|
49
|
+
}, [JSON.stringify(orderState?.options?.address?.address)])
|
|
50
|
+
|
|
45
51
|
return (
|
|
46
52
|
<>
|
|
47
53
|
{props.beforeElements?.map((BeforeElement, i) => (
|
|
@@ -75,7 +81,8 @@ const AddressDetailsUI = (props) => {
|
|
|
75
81
|
<AddressList
|
|
76
82
|
isModal
|
|
77
83
|
changeOrderAddressWithDefault
|
|
78
|
-
|
|
84
|
+
notUseCustomerInfo={notUseCustomerInfo}
|
|
85
|
+
userId={user?.id}
|
|
79
86
|
onCancel={() => setOpenModal(false)}
|
|
80
87
|
onAccept={() => handleFindBusinesses()}
|
|
81
88
|
userCustomerSetup={isCustomerMode && user}
|