@bonlineza/luxity-lib 2.34.1 → 2.34.3
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/Accordion.js +76 -116
- package/AddInterest.js +434 -768
- package/BrandSelector.js +176 -336
- package/Checkbox.js +68 -101
- package/CheckboxButton.js +79 -124
- package/CommunicationPreferenceOptionsRenderer.js +107 -125
- package/CommunicationPreferenceSection.js +114 -134
- package/CommunicationPreferences.js +443 -339
- package/CountryCodeSelect.js +7 -10
- package/CurrencyInputFormatter.js +29 -56
- package/CurrencySelect.js +188 -19
- package/GALink.js +6 -16
- package/GenderSelector.js +88 -142
- package/GraphQLDropdownSelector.js +505 -939
- package/GraphQLMultiSelector.js +141 -274
- package/IconHeader.js +11 -25
- package/IconWrapper.js +3 -7
- package/InterestCatSelector.js +34 -74
- package/InterestItem.js +103 -187
- package/Interests.js +485 -890
- package/InterestsSubheading.js +5 -10
- package/InvertedTextButton.js +27 -63
- package/LuxityAppSideNav.js +18 -21
- package/LuxityDesktopHeader.js +360 -211
- package/LuxityFooter.js +464 -260
- package/LuxityGraphQLDropdownSelector.js +519 -969
- package/LuxityGraphQLMultiselector.js +167 -321
- package/LuxityMobileHeader.js +453 -283
- package/LuxityPageReady.js +74 -136
- package/LuxitySideNav.js +355 -159
- package/MaterialSelector.js +525 -976
- package/ModelSelector.js +525 -976
- package/NotificationDropDown.js +111 -209
- package/Notify.js +0 -1
- package/OutlinePrimaryButton.js +26 -58
- package/PriceRangeSelector.js +168 -281
- package/PrimaryButton.js +26 -58
- package/RadioButtons.js +114 -140
- package/RangeSlider.js +152 -242
- package/RareStepFooter.js +27 -41
- package/RareStepHeader.js +139 -190
- package/ReactSelectWrapper.js +0 -1
- package/SecondaryButton.js +26 -58
- package/ShoeSizeRangeSelector.js +162 -260
- package/ShoeSizeSelector.js +158 -263
- package/SimpleErrorBoundary.js +59 -106
- package/StyleSelector.js +176 -336
- package/TextButton.js +26 -58
- package/Tooltip.js +17 -39
- package/Tracking.js +0 -1
- package/WrapperButton.js +20 -43
- package/build/bundle.css +1 -1
- package/build/bundle.js +1321 -1697
- package/package.json +1 -1
- package/svg/Accessories.js +6 -13
- package/svg/Account.js +6 -13
- package/svg/Add.js +6 -13
- package/svg/ArrowRight.js +6 -13
- package/svg/Bags.js +6 -13
- package/svg/BurgerMenu.js +6 -13
- package/svg/Calendar.js +6 -13
- package/svg/CalendarCircled.js +6 -13
- package/svg/CheckCircled.js +6 -13
- package/svg/Close.js +6 -13
- package/svg/Clothing.js +6 -13
- package/svg/Dot.js +6 -13
- package/svg/Edit.js +6 -13
- package/svg/Eye.js +6 -13
- package/svg/FileAttach.js +6 -13
- package/svg/FileAttachCircled.js +6 -13
- package/svg/LightBulb.js +6 -13
- package/svg/Logo.js +6 -13
- package/svg/LuxityMenu.js +6 -13
- package/svg/Minus.js +6 -13
- package/svg/MobileAvatar.js +6 -13
- package/svg/MyOrder.js +6 -13
- package/svg/MyPayment.js +6 -13
- package/svg/MyProfile.js +8 -14
- package/svg/MySale.js +6 -13
- package/svg/Notification.js +6 -13
- package/svg/PointerDown.js +6 -13
- package/svg/Search.js +6 -13
- package/svg/Shoes.js +6 -13
- package/svg/SvgWrapper.js +3 -7
- package/svg/Trash.js +6 -13
- package/svg/Watches.js +6 -13
package/MaterialSelector.js
CHANGED
|
@@ -17,293 +17,200 @@
|
|
|
17
17
|
var Notifications__default = 'default' in Notifications ? Notifications['default'] : Notifications;
|
|
18
18
|
axios = axios && Object.prototype.hasOwnProperty.call(axios, 'default') ? axios['default'] : axios;
|
|
19
19
|
|
|
20
|
-
function
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
var symbols = Object.getOwnPropertySymbols(object);
|
|
25
|
-
enumerableOnly && (symbols = symbols.filter(function (sym) {
|
|
26
|
-
return Object.getOwnPropertyDescriptor(object, sym).enumerable;
|
|
27
|
-
})), keys.push.apply(keys, symbols);
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
return keys;
|
|
20
|
+
function _arrayLikeToArray(r, a) {
|
|
21
|
+
(null == a || a > r.length) && (a = r.length);
|
|
22
|
+
for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e];
|
|
23
|
+
return n;
|
|
31
24
|
}
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
for (var i = 1; i < arguments.length; i++) {
|
|
35
|
-
var source = null != arguments[i] ? arguments[i] : {};
|
|
36
|
-
i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {
|
|
37
|
-
_defineProperty(target, key, source[key]);
|
|
38
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {
|
|
39
|
-
Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
|
|
40
|
-
});
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
return target;
|
|
25
|
+
function _arrayWithHoles(r) {
|
|
26
|
+
if (Array.isArray(r)) return r;
|
|
44
27
|
}
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
if (!(instance instanceof Constructor)) {
|
|
48
|
-
throw new TypeError("Cannot call a class as a function");
|
|
49
|
-
}
|
|
28
|
+
function _arrayWithoutHoles(r) {
|
|
29
|
+
if (Array.isArray(r)) return _arrayLikeToArray(r);
|
|
50
30
|
}
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
var descriptor = props[i];
|
|
55
|
-
descriptor.enumerable = descriptor.enumerable || false;
|
|
56
|
-
descriptor.configurable = true;
|
|
57
|
-
if ("value" in descriptor) descriptor.writable = true;
|
|
58
|
-
Object.defineProperty(target, descriptor.key, descriptor);
|
|
59
|
-
}
|
|
31
|
+
function _assertThisInitialized(e) {
|
|
32
|
+
if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
33
|
+
return e;
|
|
60
34
|
}
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
if (protoProps) _defineProperties(Constructor.prototype, protoProps);
|
|
64
|
-
if (staticProps) _defineProperties(Constructor, staticProps);
|
|
65
|
-
Object.defineProperty(Constructor, "prototype", {
|
|
66
|
-
writable: false
|
|
67
|
-
});
|
|
68
|
-
return Constructor;
|
|
35
|
+
function _callSuper(t, o, e) {
|
|
36
|
+
return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e));
|
|
69
37
|
}
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
writable: true
|
|
78
|
-
});
|
|
79
|
-
} else {
|
|
80
|
-
obj[key] = value;
|
|
38
|
+
function _classCallCheck(a, n) {
|
|
39
|
+
if (!(a instanceof n)) throw new TypeError("Cannot call a class as a function");
|
|
40
|
+
}
|
|
41
|
+
function _defineProperties(e, r) {
|
|
42
|
+
for (var t = 0; t < r.length; t++) {
|
|
43
|
+
var o = r[t];
|
|
44
|
+
o.enumerable = o.enumerable || !1, o.configurable = !0, "value" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o);
|
|
81
45
|
}
|
|
82
|
-
|
|
83
|
-
return obj;
|
|
84
46
|
}
|
|
85
|
-
|
|
47
|
+
function _createClass(e, r, t) {
|
|
48
|
+
return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, "prototype", {
|
|
49
|
+
writable: !1
|
|
50
|
+
}), e;
|
|
51
|
+
}
|
|
52
|
+
function _defineProperty(e, r, t) {
|
|
53
|
+
return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
|
|
54
|
+
value: t,
|
|
55
|
+
enumerable: !0,
|
|
56
|
+
configurable: !0,
|
|
57
|
+
writable: !0
|
|
58
|
+
}) : e[r] = t, e;
|
|
59
|
+
}
|
|
86
60
|
function _extends() {
|
|
87
|
-
_extends = Object.assign ? Object.assign.bind() : function (
|
|
88
|
-
for (var
|
|
89
|
-
var
|
|
90
|
-
|
|
91
|
-
for (var key in source) {
|
|
92
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
93
|
-
target[key] = source[key];
|
|
94
|
-
}
|
|
95
|
-
}
|
|
61
|
+
return _extends = Object.assign ? Object.assign.bind() : function (n) {
|
|
62
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
63
|
+
var t = arguments[e];
|
|
64
|
+
for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
|
|
96
65
|
}
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
};
|
|
100
|
-
return _extends.apply(this, arguments);
|
|
66
|
+
return n;
|
|
67
|
+
}, _extends.apply(null, arguments);
|
|
101
68
|
}
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
69
|
+
function _getPrototypeOf(t) {
|
|
70
|
+
return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) {
|
|
71
|
+
return t.__proto__ || Object.getPrototypeOf(t);
|
|
72
|
+
}, _getPrototypeOf(t);
|
|
73
|
+
}
|
|
74
|
+
function _inherits(t, e) {
|
|
75
|
+
if ("function" != typeof e && null !== e) throw new TypeError("Super expression must either be null or a function");
|
|
76
|
+
t.prototype = Object.create(e && e.prototype, {
|
|
109
77
|
constructor: {
|
|
110
|
-
value:
|
|
111
|
-
writable:
|
|
112
|
-
configurable:
|
|
78
|
+
value: t,
|
|
79
|
+
writable: !0,
|
|
80
|
+
configurable: !0
|
|
113
81
|
}
|
|
114
|
-
})
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
});
|
|
118
|
-
if (superClass) _setPrototypeOf(subClass, superClass);
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
function _getPrototypeOf(o) {
|
|
122
|
-
_getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) {
|
|
123
|
-
return o.__proto__ || Object.getPrototypeOf(o);
|
|
124
|
-
};
|
|
125
|
-
return _getPrototypeOf(o);
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
function _setPrototypeOf(o, p) {
|
|
129
|
-
_setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
|
|
130
|
-
o.__proto__ = p;
|
|
131
|
-
return o;
|
|
132
|
-
};
|
|
133
|
-
return _setPrototypeOf(o, p);
|
|
82
|
+
}), Object.defineProperty(t, "prototype", {
|
|
83
|
+
writable: !1
|
|
84
|
+
}), e && _setPrototypeOf(t, e);
|
|
134
85
|
}
|
|
135
|
-
|
|
136
86
|
function _isNativeReflectConstruct() {
|
|
137
|
-
if (typeof Reflect === "undefined" || !Reflect.construct) return false;
|
|
138
|
-
if (Reflect.construct.sham) return false;
|
|
139
|
-
if (typeof Proxy === "function") return true;
|
|
140
|
-
|
|
141
87
|
try {
|
|
142
|
-
Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
return
|
|
146
|
-
}
|
|
88
|
+
var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
89
|
+
} catch (t) {}
|
|
90
|
+
return (_isNativeReflectConstruct = function () {
|
|
91
|
+
return !!t;
|
|
92
|
+
})();
|
|
147
93
|
}
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
if (source == null) return {};
|
|
151
|
-
var target = {};
|
|
152
|
-
var sourceKeys = Object.keys(source);
|
|
153
|
-
var key, i;
|
|
154
|
-
|
|
155
|
-
for (i = 0; i < sourceKeys.length; i++) {
|
|
156
|
-
key = sourceKeys[i];
|
|
157
|
-
if (excluded.indexOf(key) >= 0) continue;
|
|
158
|
-
target[key] = source[key];
|
|
159
|
-
}
|
|
160
|
-
|
|
161
|
-
return target;
|
|
94
|
+
function _iterableToArray(r) {
|
|
95
|
+
if ("undefined" != typeof Symbol && null != r[Symbol.iterator] || null != r["@@iterator"]) return Array.from(r);
|
|
162
96
|
}
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
if (
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
97
|
+
function _iterableToArrayLimit(r, l) {
|
|
98
|
+
var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
|
|
99
|
+
if (null != t) {
|
|
100
|
+
var e,
|
|
101
|
+
n,
|
|
102
|
+
i,
|
|
103
|
+
u,
|
|
104
|
+
a = [],
|
|
105
|
+
f = !0,
|
|
106
|
+
o = !1;
|
|
107
|
+
try {
|
|
108
|
+
if (i = (t = t.call(r)).next, 0 === l) {
|
|
109
|
+
if (Object(t) !== t) return;
|
|
110
|
+
f = !1;
|
|
111
|
+
} else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
|
|
112
|
+
} catch (r) {
|
|
113
|
+
o = !0, n = r;
|
|
114
|
+
} finally {
|
|
115
|
+
try {
|
|
116
|
+
if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
|
|
117
|
+
} finally {
|
|
118
|
+
if (o) throw n;
|
|
119
|
+
}
|
|
179
120
|
}
|
|
121
|
+
return a;
|
|
180
122
|
}
|
|
181
|
-
|
|
182
|
-
return target;
|
|
183
123
|
}
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
if (self === void 0) {
|
|
187
|
-
throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
return self;
|
|
124
|
+
function _nonIterableRest() {
|
|
125
|
+
throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
191
126
|
}
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
if (call && (typeof call === "object" || typeof call === "function")) {
|
|
195
|
-
return call;
|
|
196
|
-
} else if (call !== void 0) {
|
|
197
|
-
throw new TypeError("Derived constructors may only return object or undefined");
|
|
198
|
-
}
|
|
199
|
-
|
|
200
|
-
return _assertThisInitialized(self);
|
|
127
|
+
function _nonIterableSpread() {
|
|
128
|
+
throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
|
|
201
129
|
}
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
var NewTarget = _getPrototypeOf(this).constructor;
|
|
212
|
-
|
|
213
|
-
result = Reflect.construct(Super, arguments, NewTarget);
|
|
214
|
-
} else {
|
|
215
|
-
result = Super.apply(this, arguments);
|
|
216
|
-
}
|
|
217
|
-
|
|
218
|
-
return _possibleConstructorReturn(this, result);
|
|
219
|
-
};
|
|
130
|
+
function ownKeys(e, r) {
|
|
131
|
+
var t = Object.keys(e);
|
|
132
|
+
if (Object.getOwnPropertySymbols) {
|
|
133
|
+
var o = Object.getOwnPropertySymbols(e);
|
|
134
|
+
r && (o = o.filter(function (r) {
|
|
135
|
+
return Object.getOwnPropertyDescriptor(e, r).enumerable;
|
|
136
|
+
})), t.push.apply(t, o);
|
|
137
|
+
}
|
|
138
|
+
return t;
|
|
220
139
|
}
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
140
|
+
function _objectSpread2(e) {
|
|
141
|
+
for (var r = 1; r < arguments.length; r++) {
|
|
142
|
+
var t = null != arguments[r] ? arguments[r] : {};
|
|
143
|
+
r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {
|
|
144
|
+
_defineProperty(e, r, t[r]);
|
|
145
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {
|
|
146
|
+
Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
|
|
147
|
+
});
|
|
225
148
|
}
|
|
226
|
-
|
|
227
|
-
return Object.freeze(Object.defineProperties(strings, {
|
|
228
|
-
raw: {
|
|
229
|
-
value: Object.freeze(raw)
|
|
230
|
-
}
|
|
231
|
-
}));
|
|
149
|
+
return e;
|
|
232
150
|
}
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
151
|
+
function _objectWithoutProperties(e, t) {
|
|
152
|
+
if (null == e) return {};
|
|
153
|
+
var o,
|
|
154
|
+
r,
|
|
155
|
+
i = _objectWithoutPropertiesLoose(e, t);
|
|
156
|
+
if (Object.getOwnPropertySymbols) {
|
|
157
|
+
var s = Object.getOwnPropertySymbols(e);
|
|
158
|
+
for (r = 0; r < s.length; r++) o = s[r], t.includes(o) || {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]);
|
|
159
|
+
}
|
|
160
|
+
return i;
|
|
236
161
|
}
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
162
|
+
function _objectWithoutPropertiesLoose(r, e) {
|
|
163
|
+
if (null == r) return {};
|
|
164
|
+
var t = {};
|
|
165
|
+
for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
|
|
166
|
+
if (e.includes(n)) continue;
|
|
167
|
+
t[n] = r[n];
|
|
168
|
+
}
|
|
169
|
+
return t;
|
|
240
170
|
}
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
if (
|
|
171
|
+
function _possibleConstructorReturn(t, e) {
|
|
172
|
+
if (e && ("object" == typeof e || "function" == typeof e)) return e;
|
|
173
|
+
if (void 0 !== e) throw new TypeError("Derived constructors may only return object or undefined");
|
|
174
|
+
return _assertThisInitialized(t);
|
|
244
175
|
}
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
176
|
+
function _setPrototypeOf(t, e) {
|
|
177
|
+
return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) {
|
|
178
|
+
return t.__proto__ = e, t;
|
|
179
|
+
}, _setPrototypeOf(t, e);
|
|
248
180
|
}
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
|
|
181
|
+
function _slicedToArray(r, e) {
|
|
182
|
+
return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest();
|
|
252
183
|
}
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
if (_i == null) return;
|
|
258
|
-
var _arr = [];
|
|
259
|
-
var _n = true;
|
|
260
|
-
var _d = false;
|
|
261
|
-
|
|
262
|
-
var _s, _e;
|
|
263
|
-
|
|
264
|
-
try {
|
|
265
|
-
for (_i = _i.call(arr); !(_n = (_s = _i.next()).done); _n = true) {
|
|
266
|
-
_arr.push(_s.value);
|
|
267
|
-
|
|
268
|
-
if (i && _arr.length === i) break;
|
|
269
|
-
}
|
|
270
|
-
} catch (err) {
|
|
271
|
-
_d = true;
|
|
272
|
-
_e = err;
|
|
273
|
-
} finally {
|
|
274
|
-
try {
|
|
275
|
-
if (!_n && _i["return"] != null) _i["return"]();
|
|
276
|
-
} finally {
|
|
277
|
-
if (_d) throw _e;
|
|
184
|
+
function _taggedTemplateLiteral(e, t) {
|
|
185
|
+
return t || (t = e.slice(0)), Object.freeze(Object.defineProperties(e, {
|
|
186
|
+
raw: {
|
|
187
|
+
value: Object.freeze(t)
|
|
278
188
|
}
|
|
279
|
-
}
|
|
280
|
-
|
|
281
|
-
return _arr;
|
|
189
|
+
}));
|
|
282
190
|
}
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
if (!o) return;
|
|
286
|
-
if (typeof o === "string") return _arrayLikeToArray(o, minLen);
|
|
287
|
-
var n = Object.prototype.toString.call(o).slice(8, -1);
|
|
288
|
-
if (n === "Object" && o.constructor) n = o.constructor.name;
|
|
289
|
-
if (n === "Map" || n === "Set") return Array.from(o);
|
|
290
|
-
if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
|
|
191
|
+
function _toConsumableArray(r) {
|
|
192
|
+
return _arrayWithoutHoles(r) || _iterableToArray(r) || _unsupportedIterableToArray(r) || _nonIterableSpread();
|
|
291
193
|
}
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
194
|
+
function _toPrimitive(t, r) {
|
|
195
|
+
if ("object" != typeof t || !t) return t;
|
|
196
|
+
var e = t[Symbol.toPrimitive];
|
|
197
|
+
if (void 0 !== e) {
|
|
198
|
+
var i = e.call(t, r || "default");
|
|
199
|
+
if ("object" != typeof i) return i;
|
|
200
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
201
|
+
}
|
|
202
|
+
return ("string" === r ? String : Number)(t);
|
|
299
203
|
}
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
204
|
+
function _toPropertyKey(t) {
|
|
205
|
+
var i = _toPrimitive(t, "string");
|
|
206
|
+
return "symbol" == typeof i ? i : i + "";
|
|
303
207
|
}
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
208
|
+
function _unsupportedIterableToArray(r, a) {
|
|
209
|
+
if (r) {
|
|
210
|
+
if ("string" == typeof r) return _arrayLikeToArray(r, a);
|
|
211
|
+
var t = {}.toString.call(r).slice(8, -1);
|
|
212
|
+
return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0;
|
|
213
|
+
}
|
|
307
214
|
}
|
|
308
215
|
|
|
309
216
|
var interpretErrorMessage = function interpretErrorMessage(error) {
|
|
@@ -315,50 +222,39 @@
|
|
|
315
222
|
var LuxityPageReadyContext = /*#__PURE__*/React__default.createContext({
|
|
316
223
|
data: null
|
|
317
224
|
});
|
|
225
|
+
|
|
318
226
|
/**
|
|
319
227
|
* A flavour of PageReady with Luxity customisations
|
|
320
228
|
* 1. the onIsLoading callback is useful to parent components that have more complex data interactions
|
|
321
229
|
* 2. an error message interpreter is supplied from the local helper library
|
|
322
230
|
*/
|
|
323
|
-
|
|
324
231
|
var LuxityPageReady = /*#__PURE__*/function (_React$Component) {
|
|
325
|
-
_inherits(LuxityPageReady, _React$Component);
|
|
326
|
-
|
|
327
|
-
var _super = _createSuper(LuxityPageReady);
|
|
328
|
-
|
|
329
232
|
function LuxityPageReady() {
|
|
330
233
|
var _this;
|
|
331
|
-
|
|
332
234
|
_classCallCheck(this, LuxityPageReady);
|
|
333
|
-
|
|
334
235
|
for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) {
|
|
335
236
|
args[_key] = arguments[_key];
|
|
336
237
|
}
|
|
337
|
-
|
|
338
|
-
_this
|
|
339
|
-
|
|
340
|
-
_defineProperty(_assertThisInitialized(_this), "state", {
|
|
238
|
+
_this = _callSuper(this, LuxityPageReady, [].concat(args));
|
|
239
|
+
_defineProperty(_this, "state", {
|
|
341
240
|
data: null
|
|
342
241
|
});
|
|
343
|
-
|
|
344
|
-
_defineProperty(_assertThisInitialized(_this), "refreshPage", function () {
|
|
242
|
+
_defineProperty(_this, "refreshPage", function () {
|
|
345
243
|
return _this.pageReadyInstance.initRequest();
|
|
346
244
|
});
|
|
347
|
-
|
|
348
245
|
return _this;
|
|
349
246
|
}
|
|
350
|
-
|
|
351
|
-
_createClass(LuxityPageReady, [{
|
|
247
|
+
_inherits(LuxityPageReady, _React$Component);
|
|
248
|
+
return _createClass(LuxityPageReady, [{
|
|
352
249
|
key: "render",
|
|
353
250
|
value: function render() {
|
|
354
251
|
var _this2 = this;
|
|
355
|
-
|
|
356
252
|
var _this$props = this.props,
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
253
|
+
customErrorMessage = _this$props.customErrorMessage,
|
|
254
|
+
customErrorHandler = _this$props.customErrorHandler,
|
|
255
|
+
getRequestPromise = _this$props.getRequestPromise,
|
|
256
|
+
_onData = _this$props.onData,
|
|
257
|
+
children = _this$props.children;
|
|
362
258
|
var data = this.state.data;
|
|
363
259
|
return /*#__PURE__*/React__default.createElement(PageReady, {
|
|
364
260
|
ref: function ref(inst) {
|
|
@@ -368,19 +264,15 @@
|
|
|
368
264
|
_this2.setState({
|
|
369
265
|
data: res.data
|
|
370
266
|
});
|
|
371
|
-
|
|
372
267
|
_onData(res);
|
|
373
268
|
},
|
|
374
269
|
getRequestInstance: function getRequestInstance() {
|
|
375
270
|
_this2.props.onIsLoading(true);
|
|
376
|
-
|
|
377
271
|
return getRequestPromise().then(function (out) {
|
|
378
272
|
_this2.props.onIsLoading(false);
|
|
379
|
-
|
|
380
273
|
return out;
|
|
381
274
|
}).catch(function (oops) {
|
|
382
275
|
_this2.props.onIsLoading(false);
|
|
383
|
-
|
|
384
276
|
return oops;
|
|
385
277
|
});
|
|
386
278
|
},
|
|
@@ -397,10 +289,7 @@
|
|
|
397
289
|
}, children));
|
|
398
290
|
}
|
|
399
291
|
}]);
|
|
400
|
-
|
|
401
|
-
return LuxityPageReady;
|
|
402
292
|
}(React__default.Component);
|
|
403
|
-
|
|
404
293
|
LuxityPageReady.defaultProps = {
|
|
405
294
|
onIsLoading: function onIsLoading() {
|
|
406
295
|
return null;
|
|
@@ -516,7 +405,6 @@
|
|
|
516
405
|
var inputMarginRight = '0.2em';
|
|
517
406
|
var CheckboxLabel = styled__default.label(_templateObject$6 || (_templateObject$6 = _taggedTemplateLiteral(["\n cursor: pointer;\n position: relative;\n display: flex;\n align-items: center;\n\n span {\n :before {\n content: '\\2713';\n position: absolute;\n display: none;\n color: white;\n left: 0.4em;\n top: 0.1em;\n font-size: ", ";\n text-align: center;\n }\n }\n\n input {\n font-size: ", ";\n background-color: ", ";\n appearance: none;\n outline: none;\n height: 1em;\n width: 1em;\n margin-right: ", ";\n border: 1px solid ", ";\n border-radius: ", ";\n transition-duration: 0.3s;\n cursor: pointer;\n\n &:checked {\n background-color: ", ";\n }\n\n &:checked + span:before {\n display: block;\n }\n }\n"], ["\n cursor: pointer;\n position: relative;\n display: flex;\n align-items: center;\n\n span {\n :before {\n content: '\\\\2713';\n position: absolute;\n display: none;\n color: white;\n left: 0.4em;\n top: 0.1em;\n font-size: ", ";\n text-align: center;\n }\n }\n\n input {\n font-size: ", ";\n background-color: ", ";\n appearance: none;\n outline: none;\n height: 1em;\n width: 1em;\n margin-right: ", ";\n border: 1px solid ", ";\n border-radius: ", ";\n transition-duration: 0.3s;\n cursor: pointer;\n\n &:checked {\n background-color: ", ";\n }\n\n &:checked + span:before {\n display: block;\n }\n }\n"])), function (props) {
|
|
518
407
|
var _props$theme;
|
|
519
|
-
|
|
520
408
|
return (_props$theme = props.theme) !== null && _props$theme !== void 0 && _props$theme.fontSizes.length ? props.theme.fontSizes[4] : '1em';
|
|
521
409
|
}, function (props) {
|
|
522
410
|
return props.theme.fontSizes[4];
|
|
@@ -535,8 +423,7 @@
|
|
|
535
423
|
}
|
|
536
424
|
});
|
|
537
425
|
|
|
538
|
-
|
|
539
|
-
|
|
426
|
+
// Register a locale for South African currency confiuguration
|
|
540
427
|
numeral.register('locale', 'en-ZA', {
|
|
541
428
|
delimiters: {
|
|
542
429
|
thousands: ',',
|
|
@@ -557,12 +444,12 @@
|
|
|
557
444
|
});
|
|
558
445
|
numeral.locale('en-ZA');
|
|
559
446
|
String.locale = numeral.locale;
|
|
447
|
+
|
|
560
448
|
/**
|
|
561
449
|
* Curreny Formatter
|
|
562
450
|
* @param {number} number - the number to be formatted
|
|
563
451
|
* @param {boolean} round - flag to indicate if the number needs to be rounded off
|
|
564
452
|
*/
|
|
565
|
-
|
|
566
453
|
function fC(number) {
|
|
567
454
|
var round = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
568
455
|
var parsedNumber = parseFloat(number);
|
|
@@ -570,6 +457,7 @@
|
|
|
570
457
|
}
|
|
571
458
|
|
|
572
459
|
/** @format */
|
|
460
|
+
|
|
573
461
|
var request = {
|
|
574
462
|
fetching: false,
|
|
575
463
|
failed: false,
|
|
@@ -676,48 +564,35 @@
|
|
|
676
564
|
|
|
677
565
|
var _templateObject$9, _templateObject2, _templateObject3, _templateObject4;
|
|
678
566
|
var MALE = genders.MALE,
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
567
|
+
FEMALE = genders.FEMALE,
|
|
568
|
+
UNISEX = genders.UNISEX;
|
|
682
569
|
var TrashIcon = function TrashIcon(_ref) {
|
|
683
570
|
var onClick = _ref.onClick,
|
|
684
|
-
|
|
571
|
+
id = _ref.id;
|
|
685
572
|
return /*#__PURE__*/React__default.createElement(IconWrapper, {
|
|
686
573
|
onClick: onClick,
|
|
687
574
|
id: id
|
|
688
575
|
}, /*#__PURE__*/React__default.createElement(SvgWrapper, null, /*#__PURE__*/React__default.createElement(Trash, null)));
|
|
689
576
|
};
|
|
690
|
-
|
|
691
577
|
var InterestItem = /*#__PURE__*/function (_React$Component) {
|
|
692
|
-
_inherits(InterestItem, _React$Component);
|
|
693
|
-
|
|
694
|
-
var _super = _createSuper(InterestItem);
|
|
695
|
-
|
|
696
578
|
function InterestItem(props) {
|
|
697
579
|
var _this;
|
|
698
|
-
|
|
699
580
|
_classCallCheck(this, InterestItem);
|
|
700
|
-
|
|
701
|
-
_this
|
|
702
|
-
|
|
703
|
-
_defineProperty(_assertThisInitialized(_this), "deleteInterestItem", function () {
|
|
581
|
+
_this = _callSuper(this, InterestItem, [props]);
|
|
582
|
+
_defineProperty(_this, "deleteInterestItem", function () {
|
|
704
583
|
var id = _this.props.data.id;
|
|
705
|
-
|
|
706
584
|
_this.setState({
|
|
707
585
|
delete: _objectSpread2(_objectSpread2({}, request), {}, {
|
|
708
586
|
fetching: true
|
|
709
587
|
})
|
|
710
588
|
});
|
|
711
|
-
|
|
712
589
|
var url = _this.props.deleteInterestApi(id);
|
|
713
|
-
|
|
714
590
|
simpleRequest(_this.props.requestInstance, url, method.DELETE, null, function () {
|
|
715
591
|
_this.setState({
|
|
716
592
|
delete: _objectSpread2(_objectSpread2({}, request), {}, {
|
|
717
593
|
success: true
|
|
718
594
|
})
|
|
719
595
|
});
|
|
720
|
-
|
|
721
596
|
_this.props.onDeleted(_this.props.data);
|
|
722
597
|
}, function () {
|
|
723
598
|
return _this.setState({
|
|
@@ -725,32 +600,25 @@
|
|
|
725
600
|
});
|
|
726
601
|
});
|
|
727
602
|
});
|
|
728
|
-
|
|
729
|
-
_defineProperty(_assertThisInitialized(_this), "getGender", function (gender) {
|
|
603
|
+
_defineProperty(_this, "getGender", function (gender) {
|
|
730
604
|
switch (gender) {
|
|
731
605
|
case MALE:
|
|
732
606
|
return 'Male';
|
|
733
|
-
|
|
734
607
|
case FEMALE:
|
|
735
608
|
return 'Female';
|
|
736
|
-
|
|
737
609
|
case UNISEX:
|
|
738
610
|
default:
|
|
739
611
|
return 'Unisex';
|
|
740
612
|
}
|
|
741
613
|
});
|
|
742
|
-
|
|
743
|
-
_defineProperty(_assertThisInitialized(_this), "getCategory", function (category) {
|
|
614
|
+
_defineProperty(_this, "getCategory", function (category) {
|
|
744
615
|
if (category === interestCategories.APPAREL) {
|
|
745
616
|
return 'CLOTHING';
|
|
746
617
|
}
|
|
747
|
-
|
|
748
618
|
return category;
|
|
749
619
|
});
|
|
750
|
-
|
|
751
|
-
_defineProperty(_assertThisInitialized(_this), "render", function () {
|
|
620
|
+
_defineProperty(_this, "render", function () {
|
|
752
621
|
var _data$min_shoe_size, _data$max_shoe_size;
|
|
753
|
-
|
|
754
622
|
var data = _this.props.data;
|
|
755
623
|
var success = _this.state.delete.success;
|
|
756
624
|
return /*#__PURE__*/React__default.createElement(InterestItemContainer, {
|
|
@@ -800,16 +668,14 @@
|
|
|
800
668
|
}
|
|
801
669
|
}));
|
|
802
670
|
});
|
|
803
|
-
|
|
804
671
|
_this.state = {
|
|
805
672
|
delete: _objectSpread2({}, request)
|
|
806
673
|
};
|
|
807
674
|
return _this;
|
|
808
675
|
}
|
|
809
|
-
|
|
676
|
+
_inherits(InterestItem, _React$Component);
|
|
810
677
|
return _createClass(InterestItem);
|
|
811
678
|
}(React__default.Component);
|
|
812
|
-
|
|
813
679
|
var SheoSizeContentDiv = styled__default.div(_templateObject$9 || (_templateObject$9 = _taggedTemplateLiteral(["\n @media (max-width: ", ") {\n display: none;\n }\n"])), media.xs);
|
|
814
680
|
var InterestItemTitle = styled__default.div(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n font-weight: bold;\n display: none;\n\n @media (max-width: ", ") {\n display: inline;\n }\n"])), media.xs);
|
|
815
681
|
var InterestItemContainer = styled__default.div(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n display: flex;\n\n .no-shoe-size-section {\n @media (max-width: ", ") {\n display: none;\n }\n }\n"])), media.xs);
|
|
@@ -825,11 +691,11 @@
|
|
|
825
691
|
return props.theme.marginPaddings[0];
|
|
826
692
|
}, media.xs);
|
|
827
693
|
var ThemedInterestItem = themed(InterestItem);
|
|
694
|
+
|
|
828
695
|
/**
|
|
829
696
|
* The Interest Item view shows the selected interest configuration,
|
|
830
697
|
* and gives user control to delete it.
|
|
831
698
|
*/
|
|
832
|
-
|
|
833
699
|
var InterestItem$1 = (function (props) {
|
|
834
700
|
return /*#__PURE__*/React__default.createElement(ThemedInterestItem, props);
|
|
835
701
|
});
|
|
@@ -876,16 +742,14 @@
|
|
|
876
742
|
*/
|
|
877
743
|
var RadioButtons = function RadioButtons(_ref) {
|
|
878
744
|
var options = _ref.options,
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
745
|
+
name = _ref.name,
|
|
746
|
+
noWrap = _ref.noWrap,
|
|
747
|
+
title = _ref.title,
|
|
748
|
+
errors = _ref.errors;
|
|
884
749
|
var _useState = React.useState(errors[name]),
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
750
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
751
|
+
errMsg = _useState2[0],
|
|
752
|
+
setErrMsg = _useState2[1];
|
|
889
753
|
React.useEffect(function () {
|
|
890
754
|
setErrMsg(errors[name]);
|
|
891
755
|
}, [errors, name]);
|
|
@@ -893,15 +757,15 @@
|
|
|
893
757
|
noWrap: noWrap
|
|
894
758
|
}, options.map(function (_ref2, index) {
|
|
895
759
|
var _ref2$actionCallback = _ref2.actionCallback,
|
|
896
|
-
|
|
897
|
-
|
|
898
|
-
|
|
899
|
-
|
|
900
|
-
|
|
901
|
-
|
|
902
|
-
|
|
903
|
-
|
|
904
|
-
|
|
760
|
+
actionCallback = _ref2$actionCallback === void 0 ? function () {
|
|
761
|
+
return null;
|
|
762
|
+
} : _ref2$actionCallback,
|
|
763
|
+
_ref2$value = _ref2.value,
|
|
764
|
+
value = _ref2$value === void 0 ? '' : _ref2$value,
|
|
765
|
+
_ref2$innerText = _ref2.innerText,
|
|
766
|
+
innerText = _ref2$innerText === void 0 ? '' : _ref2$innerText,
|
|
767
|
+
_ref2$checked = _ref2.checked,
|
|
768
|
+
checked = _ref2$checked === void 0 ? false : _ref2$checked;
|
|
905
769
|
return /*#__PURE__*/React__default.createElement(RadioButtonLabel, {
|
|
906
770
|
key: "".concat(name, "-").concat(index),
|
|
907
771
|
htmlFor: "".concat(name, "_").concat(index)
|
|
@@ -918,7 +782,6 @@
|
|
|
918
782
|
}), /*#__PURE__*/React__default.createElement(RadioButtonCircle, null, /*#__PURE__*/React__default.createElement(RadioButtonCircleInner, null)), /*#__PURE__*/React__default.createElement(RadioButtonText, null, innerText));
|
|
919
783
|
}))), errMsg && /*#__PURE__*/React__default.createElement(ErrorMessage, null, errMsg));
|
|
920
784
|
};
|
|
921
|
-
|
|
922
785
|
RadioButtons.defaultProps = {
|
|
923
786
|
noWrap: false,
|
|
924
787
|
title: '',
|
|
@@ -927,8 +790,8 @@
|
|
|
927
790
|
var RadioButtons$1 = themed(RadioButtons);
|
|
928
791
|
|
|
929
792
|
var _templateObject$i, _templateObject2$1, _templateObject3$1, _templateObject4$1, _templateObject5;
|
|
930
|
-
/* position relative is required for the Body element to be positioned correctly */
|
|
931
793
|
|
|
794
|
+
/* position relative is required for the Body element to be positioned correctly */
|
|
932
795
|
var relativeInlineStyle = styled.css(_templateObject$i || (_templateObject$i = _taggedTemplateLiteral(["\n position: relative;\n"])));
|
|
933
796
|
var topMiddleBodyStyle = styled.css(_templateObject2$1 || (_templateObject2$1 = _taggedTemplateLiteral(["\n position: absolute;\n z-index: 1;\n bottom: 50%;\n left: 50%;\n transform: translate(-50%, -50%);\n"])));
|
|
934
797
|
var getTopMiddleArrowAfterStyle = function getTopMiddleArrowAfterStyle(props) {
|
|
@@ -942,40 +805,31 @@
|
|
|
942
805
|
};
|
|
943
806
|
|
|
944
807
|
var _templateObject$j;
|
|
945
|
-
|
|
946
808
|
var getBodyStyle = function getBodyStyle() {
|
|
947
809
|
var props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
948
810
|
var _props$toolTipPositio = props.toolTipPosition,
|
|
949
|
-
|
|
950
|
-
|
|
811
|
+
toolTipPosition = _props$toolTipPositio === void 0 ? '' : _props$toolTipPositio;
|
|
951
812
|
switch (toolTipPosition) {
|
|
952
813
|
case 'top':
|
|
953
814
|
return topMiddleBodyStyle;
|
|
954
|
-
|
|
955
815
|
case 'bottom':
|
|
956
816
|
return getBottomMiddleBodyStyle(props);
|
|
957
|
-
|
|
958
817
|
default:
|
|
959
818
|
return null;
|
|
960
819
|
}
|
|
961
820
|
};
|
|
962
|
-
|
|
963
821
|
var getAfterStyling = function getAfterStyling() {
|
|
964
822
|
var props = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
965
823
|
var toolTipPosition = props.toolTipPosition;
|
|
966
|
-
|
|
967
824
|
switch (toolTipPosition) {
|
|
968
825
|
case 'top':
|
|
969
826
|
return getTopMiddleArrowAfterStyle(props);
|
|
970
|
-
|
|
971
827
|
case 'bottom':
|
|
972
828
|
return getBottomMiddleArrowAfterStyle(props);
|
|
973
|
-
|
|
974
829
|
default:
|
|
975
830
|
return '';
|
|
976
831
|
}
|
|
977
832
|
};
|
|
978
|
-
|
|
979
833
|
var Body$1 = styled__default.span(_templateObject$j || (_templateObject$j = _taggedTemplateLiteral(["\n ", ";\n visibility: hidden;\n opacity: 0;\n width: ", ";\n transition: visibility 0.3s linear, opacity 0.3s linear;\n background-color: ", ";\n color: white;\n text-align: center;\n border-radius: 5px;\n ", "\n &::after {\n content: ' ';\n position: absolute;\n ", "\n }\n"])), relativeInlineStyle, function (props) {
|
|
980
834
|
return props.bodyWidth;
|
|
981
835
|
}, function (props) {
|
|
@@ -994,25 +848,20 @@
|
|
|
994
848
|
var baseButtonStyle = styled.css(_templateObject2$2 || (_templateObject2$2 = _taggedTemplateLiteral(["\n padding: 1rem 2rem;\n cursor: pointer;\n letter-spacing: 1.3px;\n border-style: none;\n text-transform: uppercase;\n font-size: 12px;\n color: #fff;\n transition: 0.2s ease-in-out;\n outline: none;\n"])));
|
|
995
849
|
|
|
996
850
|
var _excluded = ["children"];
|
|
997
|
-
|
|
998
851
|
var _templateObject$m;
|
|
999
852
|
var Button = styled__default.button(_templateObject$m || (_templateObject$m = _taggedTemplateLiteral(["\n ", ";\n background-color: #fff;\n color: ", ";\n border: 1px solid ", ";\n\n &:disabled {\n ", "\n }\n"])), baseButtonStyle, function (props) {
|
|
1000
853
|
return props.theme.colors.primary;
|
|
1001
854
|
}, function (props) {
|
|
1002
855
|
return props.theme.colors.primary;
|
|
1003
856
|
}, disabledButtonStyle);
|
|
1004
|
-
|
|
1005
857
|
var PrimaryButton = function PrimaryButton(_ref) {
|
|
1006
858
|
var children = _ref.children,
|
|
1007
|
-
|
|
1008
|
-
|
|
859
|
+
restProps = _objectWithoutProperties(_ref, _excluded);
|
|
1009
860
|
return /*#__PURE__*/React__default.createElement(Button, restProps, children);
|
|
1010
861
|
};
|
|
1011
|
-
|
|
1012
862
|
var PrimaryButton$1 = themed(PrimaryButton);
|
|
1013
863
|
|
|
1014
864
|
var _excluded$1 = ["children"];
|
|
1015
|
-
|
|
1016
865
|
var _templateObject$n;
|
|
1017
866
|
var Button$1 = styled__default.button(_templateObject$n || (_templateObject$n = _taggedTemplateLiteral(["\n ", ";\n background-color: ", ";\n color: ", ";\n border: 1px solid ", ";\n &:hover {\n background-color: ", ";\n color: ", ";\n }\n &:disabled {\n ", "\n &:hover {\n background-color: ", ";\n }\n }\n"])), baseButtonStyle, function (props) {
|
|
1018
867
|
return props.theme.colors.ntrlMin;
|
|
@@ -1027,18 +876,14 @@
|
|
|
1027
876
|
}, disabledButtonStyle, function (props) {
|
|
1028
877
|
return props.theme.colors.base;
|
|
1029
878
|
});
|
|
1030
|
-
|
|
1031
879
|
var SecondaryButton = function SecondaryButton(_ref) {
|
|
1032
880
|
var children = _ref.children,
|
|
1033
|
-
|
|
1034
|
-
|
|
881
|
+
restProps = _objectWithoutProperties(_ref, _excluded$1);
|
|
1035
882
|
return /*#__PURE__*/React__default.createElement(Button$1, restProps, children);
|
|
1036
883
|
};
|
|
1037
|
-
|
|
1038
884
|
var SecondaryButton$1 = themed(SecondaryButton);
|
|
1039
885
|
|
|
1040
886
|
var _excluded$2 = ["children"];
|
|
1041
|
-
|
|
1042
887
|
var _templateObject$o;
|
|
1043
888
|
var Button$2 = styled__default.button(_templateObject$o || (_templateObject$o = _taggedTemplateLiteral(["\n ", ";\n background-color: transparent;\n color: ", ";\n &:hover {\n color: ", ";\n }\n &:disabled {\n ", ";\n color: ", ";\n }\n"])), baseButtonStyle, function (props) {
|
|
1044
889
|
return props.theme.colors.base;
|
|
@@ -1047,21 +892,17 @@
|
|
|
1047
892
|
}, disabledButtonStyle, function (props) {
|
|
1048
893
|
return props.theme.colors.base;
|
|
1049
894
|
});
|
|
1050
|
-
|
|
1051
895
|
var TextButton = function TextButton(_ref) {
|
|
1052
896
|
var children = _ref.children,
|
|
1053
|
-
|
|
1054
|
-
|
|
897
|
+
restProps = _objectWithoutProperties(_ref, _excluded$2);
|
|
1055
898
|
return /*#__PURE__*/React__default.createElement(Button$2, restProps, children);
|
|
1056
899
|
};
|
|
1057
|
-
|
|
1058
900
|
TextButton.defaultProps = {
|
|
1059
901
|
type: 'button'
|
|
1060
902
|
};
|
|
1061
903
|
var TextButton$1 = themed(TextButton);
|
|
1062
904
|
|
|
1063
905
|
var _excluded$3 = ["children"];
|
|
1064
|
-
|
|
1065
906
|
var _templateObject$p;
|
|
1066
907
|
var Button$3 = styled__default(TextButton$1)(_templateObject$p || (_templateObject$p = _taggedTemplateLiteral(["\n color: ", ";\n background-color: ", ";\n &:hover {\n color: ", ";\n background-color: ", ";\n }\n &:disabled {\n background-color: ", ";\n color: ", ";\n }\n"])), function (props) {
|
|
1067
908
|
return props.theme.colors.ntrlMin;
|
|
@@ -1076,25 +917,19 @@
|
|
|
1076
917
|
}, function (props) {
|
|
1077
918
|
return props.theme.colors.primary;
|
|
1078
919
|
});
|
|
1079
|
-
|
|
1080
920
|
var InvertedTextButton = function InvertedTextButton(_ref) {
|
|
1081
921
|
var children = _ref.children,
|
|
1082
|
-
|
|
1083
|
-
|
|
922
|
+
restProps = _objectWithoutProperties(_ref, _excluded$3);
|
|
1084
923
|
return /*#__PURE__*/React__default.createElement(Button$3, restProps, children);
|
|
1085
924
|
};
|
|
1086
|
-
|
|
1087
925
|
var InvertedTextButton$1 = themed(InvertedTextButton);
|
|
1088
926
|
|
|
1089
927
|
var _excluded$4 = ["children"];
|
|
1090
|
-
|
|
1091
928
|
var _templateObject$q;
|
|
1092
929
|
var Button$4 = styled__default.button(_templateObject$q || (_templateObject$q = _taggedTemplateLiteral(["\n outline: none;\n cursor: pointer;\n background-color: transparent;\n border: none;\n &:disabled {\n ", ";\n }\n"])), disabledButtonStyle);
|
|
1093
|
-
|
|
1094
930
|
var WrapperButton = function WrapperButton(_ref) {
|
|
1095
931
|
var children = _ref.children,
|
|
1096
|
-
|
|
1097
|
-
|
|
932
|
+
restProps = _objectWithoutProperties(_ref, _excluded$4);
|
|
1098
933
|
return /*#__PURE__*/React__default.createElement(Button$4, restProps, children);
|
|
1099
934
|
};
|
|
1100
935
|
|
|
@@ -1103,31 +938,28 @@
|
|
|
1103
938
|
var value = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
|
|
1104
939
|
return value.replace(/\D/g, '');
|
|
1105
940
|
};
|
|
941
|
+
|
|
1106
942
|
/**
|
|
1107
943
|
* Currency Input which formats the value to a specific format
|
|
1108
944
|
*/
|
|
1109
|
-
|
|
1110
945
|
var CurrencyInputFormatter = function CurrencyInputFormatter(_ref) {
|
|
1111
946
|
var value = _ref.value,
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
947
|
+
onChange = _ref.onChange,
|
|
948
|
+
prefix = _ref.prefix,
|
|
949
|
+
allowNegativeValue = _ref.allowNegativeValue,
|
|
950
|
+
groupSeparator = _ref.groupSeparator,
|
|
951
|
+
decimalSeparator = _ref.decimalSeparator,
|
|
952
|
+
rest = _objectWithoutProperties(_ref, _excluded$5);
|
|
1119
953
|
var handleValueChange = function handleValueChange(event) {
|
|
1120
954
|
var inputValue = event.target.value;
|
|
1121
955
|
var unmaskedValue = unMask(inputValue);
|
|
1122
956
|
onChange(unmaskedValue);
|
|
1123
957
|
};
|
|
1124
|
-
|
|
1125
958
|
var formatCurrency = function formatCurrency(originalValue) {
|
|
1126
959
|
var numericValue = Number(originalValue);
|
|
1127
960
|
var formattedValue = numericValue.toLocaleString('en-US');
|
|
1128
961
|
return prefix + formattedValue;
|
|
1129
962
|
};
|
|
1130
|
-
|
|
1131
963
|
var formattedValue = formatCurrency(value);
|
|
1132
964
|
return /*#__PURE__*/React__default.createElement("input", _extends({}, rest, {
|
|
1133
965
|
type: "text",
|
|
@@ -1135,7 +967,6 @@
|
|
|
1135
967
|
onChange: handleValueChange
|
|
1136
968
|
}));
|
|
1137
969
|
};
|
|
1138
|
-
|
|
1139
970
|
CurrencyInputFormatter.defaultProps = {
|
|
1140
971
|
value: '',
|
|
1141
972
|
prefix: 'R',
|
|
@@ -7713,7 +7544,6 @@
|
|
|
7713
7544
|
var ReactSelectWrapper = function ReactSelectWrapper(props) {
|
|
7714
7545
|
return /*#__PURE__*/React__default.createElement(index$1, props);
|
|
7715
7546
|
};
|
|
7716
|
-
|
|
7717
7547
|
ReactSelectWrapper.defaultProps = {
|
|
7718
7548
|
isMulti: false,
|
|
7719
7549
|
isSearchable: false,
|
|
@@ -7741,23 +7571,23 @@
|
|
|
7741
7571
|
return props.hasBorder ? props.theme.colors.borderColor : props.theme.colors.ntrlMin;
|
|
7742
7572
|
}, function (_ref) {
|
|
7743
7573
|
var isChecked = _ref.isChecked,
|
|
7744
|
-
|
|
7574
|
+
theme = _ref.theme;
|
|
7745
7575
|
return isChecked ? theme.colors.primary : theme.colors.gray;
|
|
7746
7576
|
}, function (_ref2) {
|
|
7747
7577
|
var isChecked = _ref2.isChecked,
|
|
7748
|
-
|
|
7578
|
+
theme = _ref2.theme;
|
|
7749
7579
|
return isChecked ? 'white' : theme.colors.base;
|
|
7750
7580
|
}, function (_ref3) {
|
|
7751
7581
|
var isChecked = _ref3.isChecked,
|
|
7752
|
-
|
|
7582
|
+
theme = _ref3.theme;
|
|
7753
7583
|
return isChecked ? theme.colors.ntrlMin : theme.colors.primary;
|
|
7754
7584
|
}, function (_ref4) {
|
|
7755
7585
|
var isChecked = _ref4.isChecked,
|
|
7756
|
-
|
|
7586
|
+
theme = _ref4.theme;
|
|
7757
7587
|
return isChecked ? 'white' : theme.colors.base;
|
|
7758
7588
|
}, function (_ref5) {
|
|
7759
7589
|
var isChecked = _ref5.isChecked,
|
|
7760
|
-
|
|
7590
|
+
theme = _ref5.theme;
|
|
7761
7591
|
return isChecked ? theme.colors.primary : 'white';
|
|
7762
7592
|
}, media.sm, function (props) {
|
|
7763
7593
|
return props.theme.marginPaddings[2];
|
|
@@ -7909,43 +7739,35 @@
|
|
|
7909
7739
|
|
|
7910
7740
|
var _templateObject$u, _templateObject2$3;
|
|
7911
7741
|
var categories = catArray;
|
|
7912
|
-
|
|
7913
7742
|
var getSvg = function getSvg() {
|
|
7914
7743
|
var category = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
|
|
7915
|
-
|
|
7916
7744
|
switch (category) {
|
|
7917
7745
|
case interestCategories.BAGS:
|
|
7918
7746
|
return /*#__PURE__*/React__default.createElement(Bags, null);
|
|
7919
|
-
|
|
7920
7747
|
case interestCategories.SHOES:
|
|
7921
7748
|
return /*#__PURE__*/React__default.createElement(Shoes, null);
|
|
7922
|
-
|
|
7923
7749
|
case interestCategories.APPAREL:
|
|
7924
7750
|
return /*#__PURE__*/React__default.createElement(Clothing, null);
|
|
7925
|
-
|
|
7926
7751
|
case interestCategories.ACCESSORIES:
|
|
7927
7752
|
return /*#__PURE__*/React__default.createElement(Accessories, null);
|
|
7928
|
-
|
|
7929
7753
|
case interestCategories.WATCHES:
|
|
7930
7754
|
return /*#__PURE__*/React__default.createElement(Watches, null);
|
|
7931
|
-
|
|
7932
7755
|
default:
|
|
7933
7756
|
return null;
|
|
7934
7757
|
}
|
|
7935
7758
|
};
|
|
7936
|
-
|
|
7937
7759
|
var Container$1 = styled__default.div(_templateObject$u || (_templateObject$u = _taggedTemplateLiteral(["\n margin-bottom: ", ";\n"])), function (props) {
|
|
7938
7760
|
return props.theme.marginPaddings[5];
|
|
7939
7761
|
});
|
|
7940
7762
|
var CategoryTitle = styled__default.h1(_templateObject2$3 || (_templateObject2$3 = _taggedTemplateLiteral(["\n margin-top: 10px;\n font-size: 14px;\n text-transform: uppercase;\n"])));
|
|
7763
|
+
|
|
7941
7764
|
/**
|
|
7942
7765
|
* InterestCatSelector is a specialized selector for select luxity specific interest categories
|
|
7943
7766
|
*/
|
|
7944
|
-
|
|
7945
7767
|
var InterestCatSelector = function InterestCatSelector(_ref) {
|
|
7946
7768
|
var onCategoryChange = _ref.onCategoryChange,
|
|
7947
|
-
|
|
7948
|
-
|
|
7769
|
+
errorMessage = _ref.errorMessage,
|
|
7770
|
+
category = _ref.category;
|
|
7949
7771
|
return /*#__PURE__*/React__default.createElement(Container$1, null, /*#__PURE__*/React__default.createElement(Body$2, null, categories.map(function (cat, index) {
|
|
7950
7772
|
return /*#__PURE__*/React__default.createElement(WrapperButton, {
|
|
7951
7773
|
key: "cat-".concat(index),
|
|
@@ -7960,7 +7782,6 @@
|
|
|
7960
7782
|
}, getSvg(cat.value), /*#__PURE__*/React__default.createElement(CategoryTitle, null, cat.categoryTitle)));
|
|
7961
7783
|
})), errorMessage && /*#__PURE__*/React__default.createElement(ErrorMessage$1, null, errorMessage));
|
|
7962
7784
|
};
|
|
7963
|
-
|
|
7964
7785
|
InterestCatSelector.defaultProps = {
|
|
7965
7786
|
errorMessage: '',
|
|
7966
7787
|
category: null,
|
|
@@ -7971,117 +7792,82 @@
|
|
|
7971
7792
|
var CategoryInterestSelector = themed(InterestCatSelector);
|
|
7972
7793
|
|
|
7973
7794
|
function _extends$2() {
|
|
7974
|
-
_extends$2 = Object.assign ? Object.assign.bind() : function (
|
|
7975
|
-
for (var
|
|
7976
|
-
var
|
|
7977
|
-
|
|
7978
|
-
for (var key in source) {
|
|
7979
|
-
if (Object.prototype.hasOwnProperty.call(source, key)) {
|
|
7980
|
-
target[key] = source[key];
|
|
7981
|
-
}
|
|
7982
|
-
}
|
|
7795
|
+
return _extends$2 = Object.assign ? Object.assign.bind() : function (n) {
|
|
7796
|
+
for (var e = 1; e < arguments.length; e++) {
|
|
7797
|
+
var t = arguments[e];
|
|
7798
|
+
for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]);
|
|
7983
7799
|
}
|
|
7984
|
-
|
|
7985
|
-
|
|
7986
|
-
};
|
|
7987
|
-
return _extends$2.apply(this, arguments);
|
|
7800
|
+
return n;
|
|
7801
|
+
}, _extends$2.apply(null, arguments);
|
|
7988
7802
|
}
|
|
7989
7803
|
|
|
7990
|
-
function _assertThisInitialized$2(
|
|
7991
|
-
if (
|
|
7992
|
-
|
|
7993
|
-
}
|
|
7994
|
-
|
|
7995
|
-
return self;
|
|
7804
|
+
function _assertThisInitialized$2(e) {
|
|
7805
|
+
if (void 0 === e) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
|
|
7806
|
+
return e;
|
|
7996
7807
|
}
|
|
7997
7808
|
|
|
7998
|
-
function _setPrototypeOf$2(
|
|
7999
|
-
_setPrototypeOf$2 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function
|
|
8000
|
-
|
|
8001
|
-
|
|
8002
|
-
};
|
|
8003
|
-
return _setPrototypeOf$2(o, p);
|
|
7809
|
+
function _setPrototypeOf$2(t, e) {
|
|
7810
|
+
return _setPrototypeOf$2 = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) {
|
|
7811
|
+
return t.__proto__ = e, t;
|
|
7812
|
+
}, _setPrototypeOf$2(t, e);
|
|
8004
7813
|
}
|
|
8005
7814
|
|
|
8006
|
-
function _inheritsLoose(
|
|
8007
|
-
|
|
8008
|
-
subClass.prototype.constructor = subClass;
|
|
8009
|
-
_setPrototypeOf$2(subClass, superClass);
|
|
7815
|
+
function _inheritsLoose(t, o) {
|
|
7816
|
+
t.prototype = Object.create(o.prototype), t.prototype.constructor = t, _setPrototypeOf$2(t, o);
|
|
8010
7817
|
}
|
|
8011
7818
|
|
|
8012
|
-
function _getPrototypeOf$2(
|
|
8013
|
-
_getPrototypeOf$2 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function
|
|
8014
|
-
return
|
|
8015
|
-
};
|
|
8016
|
-
return _getPrototypeOf$2(o);
|
|
7819
|
+
function _getPrototypeOf$2(t) {
|
|
7820
|
+
return _getPrototypeOf$2 = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) {
|
|
7821
|
+
return t.__proto__ || Object.getPrototypeOf(t);
|
|
7822
|
+
}, _getPrototypeOf$2(t);
|
|
8017
7823
|
}
|
|
8018
7824
|
|
|
8019
|
-
function _isNativeFunction(
|
|
8020
|
-
|
|
7825
|
+
function _isNativeFunction(t) {
|
|
7826
|
+
try {
|
|
7827
|
+
return -1 !== Function.toString.call(t).indexOf("[native code]");
|
|
7828
|
+
} catch (n) {
|
|
7829
|
+
return "function" == typeof t;
|
|
7830
|
+
}
|
|
8021
7831
|
}
|
|
8022
7832
|
|
|
8023
7833
|
function _isNativeReflectConstruct$1() {
|
|
8024
|
-
if (typeof Reflect === "undefined" || !Reflect.construct) return false;
|
|
8025
|
-
if (Reflect.construct.sham) return false;
|
|
8026
|
-
if (typeof Proxy === "function") return true;
|
|
8027
|
-
|
|
8028
7834
|
try {
|
|
8029
|
-
Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
8030
|
-
|
|
8031
|
-
|
|
8032
|
-
return
|
|
8033
|
-
}
|
|
7835
|
+
var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {}));
|
|
7836
|
+
} catch (t) {}
|
|
7837
|
+
return (_isNativeReflectConstruct$1 = function _isNativeReflectConstruct() {
|
|
7838
|
+
return !!t;
|
|
7839
|
+
})();
|
|
8034
7840
|
}
|
|
8035
7841
|
|
|
8036
|
-
function _construct(
|
|
8037
|
-
if (_isNativeReflectConstruct$1())
|
|
8038
|
-
|
|
8039
|
-
|
|
8040
|
-
|
|
8041
|
-
|
|
8042
|
-
a.push.apply(a, args);
|
|
8043
|
-
var Constructor = Function.bind.apply(Parent, a);
|
|
8044
|
-
var instance = new Constructor();
|
|
8045
|
-
if (Class) _setPrototypeOf$2(instance, Class.prototype);
|
|
8046
|
-
return instance;
|
|
8047
|
-
};
|
|
8048
|
-
}
|
|
8049
|
-
|
|
8050
|
-
return _construct.apply(null, arguments);
|
|
7842
|
+
function _construct(t, e, r) {
|
|
7843
|
+
if (_isNativeReflectConstruct$1()) return Reflect.construct.apply(null, arguments);
|
|
7844
|
+
var o = [null];
|
|
7845
|
+
o.push.apply(o, e);
|
|
7846
|
+
var p = new (t.bind.apply(t, o))();
|
|
7847
|
+
return r && _setPrototypeOf$2(p, r.prototype), p;
|
|
8051
7848
|
}
|
|
8052
7849
|
|
|
8053
|
-
function _wrapNativeSuper(
|
|
8054
|
-
var
|
|
8055
|
-
|
|
8056
|
-
|
|
8057
|
-
if (
|
|
8058
|
-
|
|
8059
|
-
|
|
8060
|
-
|
|
7850
|
+
function _wrapNativeSuper(t) {
|
|
7851
|
+
var r = "function" == typeof Map ? new Map() : void 0;
|
|
7852
|
+
return _wrapNativeSuper = function _wrapNativeSuper(t) {
|
|
7853
|
+
if (null === t || !_isNativeFunction(t)) return t;
|
|
7854
|
+
if ("function" != typeof t) throw new TypeError("Super expression must either be null or a function");
|
|
7855
|
+
if (void 0 !== r) {
|
|
7856
|
+
if (r.has(t)) return r.get(t);
|
|
7857
|
+
r.set(t, Wrapper);
|
|
8061
7858
|
}
|
|
8062
|
-
|
|
8063
|
-
if (typeof _cache !== "undefined") {
|
|
8064
|
-
if (_cache.has(Class)) return _cache.get(Class);
|
|
8065
|
-
|
|
8066
|
-
_cache.set(Class, Wrapper);
|
|
8067
|
-
}
|
|
8068
|
-
|
|
8069
7859
|
function Wrapper() {
|
|
8070
|
-
return _construct(
|
|
7860
|
+
return _construct(t, arguments, _getPrototypeOf$2(this).constructor);
|
|
8071
7861
|
}
|
|
8072
|
-
|
|
8073
|
-
Wrapper.prototype = Object.create(Class.prototype, {
|
|
7862
|
+
return Wrapper.prototype = Object.create(t.prototype, {
|
|
8074
7863
|
constructor: {
|
|
8075
7864
|
value: Wrapper,
|
|
8076
|
-
enumerable:
|
|
8077
|
-
writable:
|
|
8078
|
-
configurable:
|
|
7865
|
+
enumerable: !1,
|
|
7866
|
+
writable: !0,
|
|
7867
|
+
configurable: !0
|
|
8079
7868
|
}
|
|
8080
|
-
});
|
|
8081
|
-
|
|
8082
|
-
};
|
|
8083
|
-
|
|
8084
|
-
return _wrapNativeSuper(Class);
|
|
7869
|
+
}), _setPrototypeOf$2(Wrapper, t);
|
|
7870
|
+
}, _wrapNativeSuper(t);
|
|
8085
7871
|
}
|
|
8086
7872
|
|
|
8087
7873
|
// based on https://github.com/styled-components/styled-components/blob/fcf6f3804c57a14dd7984dfab7bc06ee2edca044/src/utils/error.js
|
|
@@ -8750,10 +8536,9 @@
|
|
|
8750
8536
|
}, function (props) {
|
|
8751
8537
|
return getSliderMarkStyle(props);
|
|
8752
8538
|
});
|
|
8753
|
-
|
|
8754
8539
|
var getSliderMarkStyle = function getSliderMarkStyle(_ref) {
|
|
8755
8540
|
var showMarks = _ref.showMarks,
|
|
8756
|
-
|
|
8541
|
+
primary = _ref.theme.colors.primary;
|
|
8757
8542
|
var visiblityStyle = showMarks ? styled.css(_templateObject2$4 || (_templateObject2$4 = _taggedTemplateLiteral([""]))) : styled.css(_templateObject3$2 || (_templateObject3$2 = _taggedTemplateLiteral(["\n .rc-slider-mark-text,\n .rc-slider-dot {\n visibility: hidden;\n }\n "])));
|
|
8758
8543
|
return styled.css(_templateObject4$2 || (_templateObject4$2 = _taggedTemplateLiteral(["\n .rc-slider-mark-text {\n color: ", ";\n }\n\n .rc-slider-dot {\n border-color: ", ";\n background-color: white;\n }\n ", "\n "])), primary, primary, visiblityStyle);
|
|
8759
8544
|
};
|
|
@@ -8765,28 +8550,24 @@
|
|
|
8765
8550
|
var Footer = styled__default.div(_templateObject$y || (_templateObject$y = _taggedTemplateLiteral(["\n display: flex;\n flex-flow: row nowrap;\n justify-content: flex-end;\n"])));
|
|
8766
8551
|
|
|
8767
8552
|
var _excluded$6 = ["dragging", "value", "offset", "index"],
|
|
8768
|
-
|
|
8769
|
-
|
|
8553
|
+
_excluded2 = ["renderTitleSection", "marks", "defaultMinValue", "defaultMaxValue", "min", "max", "toolTipComponent", "renderFooterSection", "onChange", "children", "identifier", "showMarks"];
|
|
8770
8554
|
var _templateObject$z;
|
|
8771
8555
|
var debounceBuilder = functions.debounced(100);
|
|
8772
8556
|
var ChildrenWrapper = styled__default.div(_templateObject$z || (_templateObject$z = _taggedTemplateLiteral(["\n margin-bottom: ", ";\n"])), function (props) {
|
|
8773
8557
|
return props.theme.marginPaddings[3];
|
|
8774
8558
|
});
|
|
8775
|
-
|
|
8776
8559
|
var renderCustomHandle = function renderCustomHandle() {
|
|
8777
8560
|
var marks = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
|
|
8778
8561
|
var toolTipComponent = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : null;
|
|
8779
8562
|
var handleProps = arguments.length > 2 ? arguments[2] : undefined;
|
|
8780
|
-
|
|
8781
8563
|
var dragging = handleProps.dragging,
|
|
8782
|
-
|
|
8783
|
-
|
|
8784
|
-
|
|
8785
|
-
|
|
8786
|
-
|
|
8564
|
+
value = handleProps.value,
|
|
8565
|
+
offset = handleProps.offset,
|
|
8566
|
+
index = handleProps.index,
|
|
8567
|
+
restHandleProps = _objectWithoutProperties(handleProps, _excluded$6);
|
|
8787
8568
|
var getToolTipProps = function getToolTipProps() {
|
|
8788
|
-
var newProps = {};
|
|
8789
|
-
|
|
8569
|
+
var newProps = {};
|
|
8570
|
+
// Ensures that Tooltip component does not get ref prop
|
|
8790
8571
|
Object.keys(handleProps).forEach(function (propName) {
|
|
8791
8572
|
if (propName !== 'ref') {
|
|
8792
8573
|
newProps[propName] = handleProps[propName];
|
|
@@ -8794,7 +8575,6 @@
|
|
|
8794
8575
|
});
|
|
8795
8576
|
return newProps;
|
|
8796
8577
|
};
|
|
8797
|
-
|
|
8798
8578
|
var Tooltip = toolTipComponent;
|
|
8799
8579
|
return /*#__PURE__*/React__default.createElement(React.Fragment, {
|
|
8800
8580
|
key: index
|
|
@@ -8811,55 +8591,47 @@
|
|
|
8811
8591
|
marks: marks
|
|
8812
8592
|
}, getToolTipProps()))));
|
|
8813
8593
|
};
|
|
8814
|
-
/** slider ui component for react */
|
|
8815
|
-
|
|
8816
8594
|
|
|
8595
|
+
/** slider ui component for react */
|
|
8817
8596
|
var RangeSlider = function RangeSlider(_ref) {
|
|
8818
8597
|
var renderTitleSection = _ref.renderTitleSection,
|
|
8819
|
-
|
|
8820
|
-
|
|
8821
|
-
|
|
8822
|
-
|
|
8823
|
-
|
|
8824
|
-
|
|
8825
|
-
|
|
8826
|
-
|
|
8827
|
-
|
|
8828
|
-
|
|
8829
|
-
|
|
8830
|
-
|
|
8831
|
-
|
|
8598
|
+
marks = _ref.marks,
|
|
8599
|
+
defaultMinValue = _ref.defaultMinValue,
|
|
8600
|
+
defaultMaxValue = _ref.defaultMaxValue,
|
|
8601
|
+
min = _ref.min,
|
|
8602
|
+
max = _ref.max,
|
|
8603
|
+
toolTipComponent = _ref.toolTipComponent,
|
|
8604
|
+
renderFooterSection = _ref.renderFooterSection,
|
|
8605
|
+
onChange = _ref.onChange,
|
|
8606
|
+
childRenderer = _ref.children,
|
|
8607
|
+
identifier = _ref.identifier,
|
|
8608
|
+
showMarks = _ref.showMarks,
|
|
8609
|
+
restProps = _objectWithoutProperties(_ref, _excluded2);
|
|
8832
8610
|
var _useState = React.useState(defaultMinValue),
|
|
8833
|
-
|
|
8834
|
-
|
|
8835
|
-
|
|
8836
|
-
|
|
8611
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
8612
|
+
currMinVal = _useState2[0],
|
|
8613
|
+
setMinVal = _useState2[1];
|
|
8837
8614
|
var _useState3 = React.useState(defaultMaxValue),
|
|
8838
|
-
|
|
8839
|
-
|
|
8840
|
-
|
|
8615
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
8616
|
+
currMaxVal = _useState4[0],
|
|
8617
|
+
setMaxVal = _useState4[1];
|
|
8841
8618
|
/*
|
|
8842
8619
|
*Description variable stores the time that the component renders
|
|
8843
8620
|
* the state is used to enforce reenders for the component since the date now
|
|
8844
8621
|
* is always changing
|
|
8845
8622
|
* */
|
|
8846
|
-
|
|
8847
|
-
|
|
8848
8623
|
var _useState5 = React.useState(0),
|
|
8849
|
-
|
|
8850
|
-
|
|
8851
|
-
|
|
8852
|
-
|
|
8624
|
+
_useState6 = _slicedToArray(_useState5, 2),
|
|
8625
|
+
seed = _useState6[0],
|
|
8626
|
+
setSeed = _useState6[1];
|
|
8853
8627
|
var manuallyChangeMinValue = function manuallyChangeMinValue(val) {
|
|
8854
8628
|
setMinVal(val);
|
|
8855
8629
|
setSeed(Date.now());
|
|
8856
8630
|
};
|
|
8857
|
-
|
|
8858
8631
|
var manuallyChangeMaxValue = function manuallyChangeMaxValue(val) {
|
|
8859
8632
|
setMaxVal(val);
|
|
8860
8633
|
setSeed(Date.now());
|
|
8861
8634
|
};
|
|
8862
|
-
|
|
8863
8635
|
var prevMinVal = functions.usePrevious(currMinVal);
|
|
8864
8636
|
var prevMaxVal = functions.usePrevious(currMaxVal);
|
|
8865
8637
|
React.useEffect(function () {
|
|
@@ -8895,9 +8667,8 @@
|
|
|
8895
8667
|
defaultValue: [defaultMinValue, defaultMaxValue],
|
|
8896
8668
|
onChange: function onChange(_ref2) {
|
|
8897
8669
|
var _ref3 = _slicedToArray(_ref2, 2),
|
|
8898
|
-
|
|
8899
|
-
|
|
8900
|
-
|
|
8670
|
+
nextMin = _ref3[0],
|
|
8671
|
+
nextMax = _ref3[1];
|
|
8901
8672
|
setMinVal(nextMin);
|
|
8902
8673
|
setMaxVal(nextMax);
|
|
8903
8674
|
},
|
|
@@ -8910,7 +8681,6 @@
|
|
|
8910
8681
|
allowCross: false
|
|
8911
8682
|
}, restProps)), /*#__PURE__*/React__default.createElement(Footer, null, renderFooterSection(actionsObj)));
|
|
8912
8683
|
};
|
|
8913
|
-
|
|
8914
8684
|
RangeSlider.defaultProps = {
|
|
8915
8685
|
renderTitleSection: function renderTitleSection() {
|
|
8916
8686
|
return false;
|
|
@@ -8941,11 +8711,10 @@
|
|
|
8941
8711
|
}, function (props) {
|
|
8942
8712
|
return props.theme.marginPaddings[3];
|
|
8943
8713
|
});
|
|
8944
|
-
|
|
8945
8714
|
var InterestsSubheading = function InterestsSubheading(_ref) {
|
|
8946
8715
|
var title = _ref.title,
|
|
8947
|
-
|
|
8948
|
-
|
|
8716
|
+
children = _ref.children,
|
|
8717
|
+
className = _ref.className;
|
|
8949
8718
|
return /*#__PURE__*/React__default.createElement(InterestsSubheadingContainer, {
|
|
8950
8719
|
className: className
|
|
8951
8720
|
}, /*#__PURE__*/React__default.createElement(Title$2, null, title), /*#__PURE__*/React__default.createElement("div", null, children));
|
|
@@ -8957,31 +8726,23 @@
|
|
|
8957
8726
|
});
|
|
8958
8727
|
|
|
8959
8728
|
var debounceBuilder$1 = functions.debounced(50);
|
|
8960
|
-
|
|
8961
8729
|
var getMaxPrice = function getMaxPrice() {
|
|
8962
8730
|
var interestCategory = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '';
|
|
8963
|
-
|
|
8964
8731
|
switch (interestCategory) {
|
|
8965
8732
|
case interestCategories.ACCESSORIES:
|
|
8966
8733
|
return interestCategoryMaxPrices.ACCESSORIES;
|
|
8967
|
-
|
|
8968
8734
|
case interestCategories.BAGS:
|
|
8969
8735
|
return interestCategoryMaxPrices.BAGS;
|
|
8970
|
-
|
|
8971
8736
|
case interestCategories.SHOES:
|
|
8972
8737
|
return interestCategoryMaxPrices.SHOES;
|
|
8973
|
-
|
|
8974
8738
|
case interestCategories.WATCHES:
|
|
8975
8739
|
return interestCategoryMaxPrices.WATCHES;
|
|
8976
|
-
|
|
8977
8740
|
case interestCategories.APPAREL:
|
|
8978
8741
|
return interestCategoryMaxPrices.APPAREL;
|
|
8979
|
-
|
|
8980
8742
|
default:
|
|
8981
8743
|
return 0;
|
|
8982
8744
|
}
|
|
8983
8745
|
};
|
|
8984
|
-
|
|
8985
8746
|
var getFooterButtons = function getFooterButtons(actionObj) {
|
|
8986
8747
|
var giveFullRange = actionObj.giveFullRange;
|
|
8987
8748
|
return /*#__PURE__*/React__default.createElement(SecondaryButton$1, {
|
|
@@ -8989,24 +8750,21 @@
|
|
|
8989
8750
|
onClick: giveFullRange
|
|
8990
8751
|
}, "Full Price Range");
|
|
8991
8752
|
};
|
|
8753
|
+
|
|
8992
8754
|
/** UI Slider with minimum and max input fields give the ability to
|
|
8993
8755
|
* select a price range */
|
|
8994
|
-
|
|
8995
|
-
|
|
8996
8756
|
var PriceRangeSelector = function PriceRangeSelector(_ref) {
|
|
8997
8757
|
var onChange = _ref.onChange,
|
|
8998
|
-
|
|
8758
|
+
category = _ref.category;
|
|
8999
8759
|
var maxPrice = getMaxPrice(category);
|
|
9000
|
-
|
|
9001
8760
|
var handleSlideChange = function handleSlideChange(value) {
|
|
9002
8761
|
var min_price = value.min,
|
|
9003
|
-
|
|
8762
|
+
max_price = value.max;
|
|
9004
8763
|
onChange({
|
|
9005
8764
|
min_price: min_price,
|
|
9006
8765
|
max_price: max_price
|
|
9007
8766
|
});
|
|
9008
8767
|
};
|
|
9009
|
-
|
|
9010
8768
|
var handleMinCurrencyChange = function handleMinCurrencyChange(targetValue, currMaxVal, manuallyChangeMinValue) {
|
|
9011
8769
|
var value = parseInt(unMask(targetValue), 10);
|
|
9012
8770
|
value = Number.isNaN(value) ? 0 : value;
|
|
@@ -9019,7 +8777,6 @@
|
|
|
9019
8777
|
});
|
|
9020
8778
|
});
|
|
9021
8779
|
};
|
|
9022
|
-
|
|
9023
8780
|
var handleMaxCurrencyChange = function handleMaxCurrencyChange(targetValue, currMinVal, manuallyChangeMaxValue) {
|
|
9024
8781
|
var value = parseInt(unMask(targetValue), 10);
|
|
9025
8782
|
value = Number.isNaN(value) ? 0 : value;
|
|
@@ -9032,7 +8789,6 @@
|
|
|
9032
8789
|
});
|
|
9033
8790
|
});
|
|
9034
8791
|
};
|
|
9035
|
-
|
|
9036
8792
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
9037
8793
|
className: "price-ranges"
|
|
9038
8794
|
}, /*#__PURE__*/React__default.createElement(RangeSlider$1, {
|
|
@@ -9051,9 +8807,9 @@
|
|
|
9051
8807
|
title: "Price Ranges"
|
|
9052
8808
|
}, function (_ref2) {
|
|
9053
8809
|
var manuallyChangeMinValue = _ref2.manuallyChangeMinValue,
|
|
9054
|
-
|
|
9055
|
-
|
|
9056
|
-
|
|
8810
|
+
manuallyChangeMaxValue = _ref2.manuallyChangeMaxValue,
|
|
8811
|
+
currMinVal = _ref2.currMinVal,
|
|
8812
|
+
currMaxVal = _ref2.currMaxVal;
|
|
9057
8813
|
return /*#__PURE__*/React__default.createElement(CurrencyInputWrapper, null, /*#__PURE__*/React__default.createElement(CurrencyInputFormatter, {
|
|
9058
8814
|
"data-qe-id": "masked-input-min",
|
|
9059
8815
|
value: currMinVal,
|
|
@@ -9069,7 +8825,6 @@
|
|
|
9069
8825
|
}));
|
|
9070
8826
|
}));
|
|
9071
8827
|
};
|
|
9072
|
-
|
|
9073
8828
|
PriceRangeSelector.defaultProps = {
|
|
9074
8829
|
onChange: function onChange() {
|
|
9075
8830
|
return false;
|
|
@@ -9090,7 +8845,6 @@
|
|
|
9090
8845
|
var shoe_sizes = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
9091
8846
|
return shoe_sizes.length - 1;
|
|
9092
8847
|
};
|
|
9093
|
-
|
|
9094
8848
|
var formatResultsForRangeSlider = function formatResultsForRangeSlider() {
|
|
9095
8849
|
var shoe_sizes = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
9096
8850
|
var newDataShape = {};
|
|
@@ -9100,28 +8854,24 @@
|
|
|
9100
8854
|
});
|
|
9101
8855
|
return newDataShape;
|
|
9102
8856
|
};
|
|
9103
|
-
|
|
9104
8857
|
var ToolTipComponent = function ToolTipComponent(props) {
|
|
9105
8858
|
var marks = props.marks,
|
|
9106
|
-
|
|
8859
|
+
value = props.value;
|
|
9107
8860
|
return /*#__PURE__*/React__default.createElement("div", null, marks[value]);
|
|
9108
8861
|
};
|
|
9109
|
-
/** slider ui component for shoe size selection interests */
|
|
9110
|
-
|
|
9111
8862
|
|
|
8863
|
+
/** slider ui component for shoe size selection interests */
|
|
9112
8864
|
var ShoeSizeSelector = function ShoeSizeSelector(_ref2) {
|
|
9113
8865
|
var onChange = _ref2.onChange,
|
|
9114
|
-
|
|
9115
|
-
|
|
8866
|
+
shoeSizes = _ref2.shoeSizes;
|
|
9116
8867
|
var handleShoeSizeChange = function handleShoeSizeChange(value) {
|
|
9117
8868
|
var min_shoe_key = value.min,
|
|
9118
|
-
|
|
8869
|
+
max_shoe_key = value.max;
|
|
9119
8870
|
onChange({
|
|
9120
8871
|
min_shoe_size_id: shoeSizes[min_shoe_key].id,
|
|
9121
8872
|
max_shoe_size_id: shoeSizes[max_shoe_key].id
|
|
9122
8873
|
});
|
|
9123
8874
|
};
|
|
9124
|
-
|
|
9125
8875
|
var getFooterButtons = function getFooterButtons(actionObj) {
|
|
9126
8876
|
var giveFullRange = actionObj.giveFullRange;
|
|
9127
8877
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(InvertedTextButton$1, {
|
|
@@ -9130,7 +8880,6 @@
|
|
|
9130
8880
|
onClick: giveFullRange
|
|
9131
8881
|
}, "Full Shoe Size Range"));
|
|
9132
8882
|
};
|
|
9133
|
-
|
|
9134
8883
|
return /*#__PURE__*/React__default.createElement(React__default.Fragment, null, /*#__PURE__*/React__default.createElement(RangeSlider$1, {
|
|
9135
8884
|
identifier: "shoe-size-range-slider",
|
|
9136
8885
|
marks: formatResultsForRangeSlider(shoeSizes),
|
|
@@ -9143,7 +8892,6 @@
|
|
|
9143
8892
|
onChange: handleShoeSizeChange
|
|
9144
8893
|
}));
|
|
9145
8894
|
};
|
|
9146
|
-
|
|
9147
8895
|
ShoeSizeSelector.defaultProps = {
|
|
9148
8896
|
onChange: function onChange() {
|
|
9149
8897
|
return false;
|
|
@@ -9152,23 +8900,17 @@
|
|
|
9152
8900
|
};
|
|
9153
8901
|
|
|
9154
8902
|
var SimpleErrorBoundary = /*#__PURE__*/function (_React$Component) {
|
|
9155
|
-
_inherits(SimpleErrorBoundary, _React$Component);
|
|
9156
|
-
|
|
9157
|
-
var _super = _createSuper(SimpleErrorBoundary);
|
|
9158
|
-
|
|
9159
8903
|
function SimpleErrorBoundary(props) {
|
|
9160
8904
|
var _this;
|
|
9161
|
-
|
|
9162
8905
|
_classCallCheck(this, SimpleErrorBoundary);
|
|
9163
|
-
|
|
9164
|
-
_this = _super.call(this, props);
|
|
8906
|
+
_this = _callSuper(this, SimpleErrorBoundary, [props]);
|
|
9165
8907
|
_this.state = {
|
|
9166
8908
|
hasError: false
|
|
9167
8909
|
};
|
|
9168
8910
|
return _this;
|
|
9169
8911
|
}
|
|
9170
|
-
|
|
9171
|
-
_createClass(SimpleErrorBoundary, [{
|
|
8912
|
+
_inherits(SimpleErrorBoundary, _React$Component);
|
|
8913
|
+
return _createClass(SimpleErrorBoundary, [{
|
|
9172
8914
|
key: "componentDidCatch",
|
|
9173
8915
|
value: function componentDidCatch(error, errorInfo) {
|
|
9174
8916
|
// You can also log the error to an error reporting service
|
|
@@ -9181,7 +8923,6 @@
|
|
|
9181
8923
|
// You can render any custom fallback UI
|
|
9182
8924
|
return this.props.showMessageOnError ? /*#__PURE__*/React__default.createElement("h1", null, this.props.errorMessage) : null;
|
|
9183
8925
|
}
|
|
9184
|
-
|
|
9185
8926
|
return this.props.children;
|
|
9186
8927
|
}
|
|
9187
8928
|
}], [{
|
|
@@ -9193,10 +8934,7 @@
|
|
|
9193
8934
|
};
|
|
9194
8935
|
}
|
|
9195
8936
|
}]);
|
|
9196
|
-
|
|
9197
|
-
return SimpleErrorBoundary;
|
|
9198
8937
|
}(React__default.Component);
|
|
9199
|
-
|
|
9200
8938
|
SimpleErrorBoundary.defaultProps = {
|
|
9201
8939
|
errorMessage: 'Something went wrong',
|
|
9202
8940
|
errorLogger: null,
|
|
@@ -9207,21 +8945,19 @@
|
|
|
9207
8945
|
var StyledHeader = styled__default.h5(_templateObject$D || (_templateObject$D = _taggedTemplateLiteral(["\n display: flex;\n flex-flow: row nowrap;\n align-items: center;\n\n @media (max-width: ", ") {\n display: block;\n }\n\n .icon-header__left {\n display: flex;\n flex-flow: row nowrap;\n align-items: center;\n\n @media (max-width: ", ") {\n align-self: flex-start;\n }\n\n svg {\n height: 1.5em;\n width: 1.5em;\n margin-right: ", ";\n }\n }\n\n .icon-header__right {\n display: flex;\n flex-grow: 1;\n justify-content: flex-end;\n }\n"])), media.sm, media.sm, function (props) {
|
|
9208
8946
|
return props.theme.marginPaddings[1];
|
|
9209
8947
|
});
|
|
9210
|
-
|
|
9211
8948
|
/**
|
|
9212
8949
|
* IconHeader can render the standard Luxity Page/Section Header nodes with SVG
|
|
9213
8950
|
*/
|
|
9214
8951
|
var IconHeader = function IconHeader(_ref) {
|
|
9215
8952
|
var title = _ref.title,
|
|
9216
|
-
|
|
9217
|
-
|
|
8953
|
+
SvgComponent = _ref.svgComponent,
|
|
8954
|
+
renderAppendage = _ref.renderAppendage;
|
|
9218
8955
|
return /*#__PURE__*/React__default.createElement(StyledHeader, null, /*#__PURE__*/React__default.createElement("div", {
|
|
9219
8956
|
className: "icon-header__left"
|
|
9220
8957
|
}, /*#__PURE__*/React__default.createElement(SvgComponent, null), title), /*#__PURE__*/React__default.createElement("div", {
|
|
9221
8958
|
className: "icon-header__right"
|
|
9222
8959
|
}, renderAppendage && renderAppendage()));
|
|
9223
8960
|
};
|
|
9224
|
-
|
|
9225
8961
|
IconHeader.defaultProps = {
|
|
9226
8962
|
title: '',
|
|
9227
8963
|
svgComponent: function svgComponent() {
|
|
@@ -9275,30 +9011,21 @@
|
|
|
9275
9011
|
/**
|
|
9276
9012
|
* It represents the React Component that contains the notifications.
|
|
9277
9013
|
* */
|
|
9278
|
-
|
|
9279
9014
|
var LuxityNotifications = function LuxityNotifications(props) {
|
|
9280
9015
|
return /*#__PURE__*/React__default.createElement(Notifications__default, props);
|
|
9281
9016
|
};
|
|
9282
9017
|
|
|
9283
9018
|
var NotificationDropDown = /*#__PURE__*/function (_React$Component) {
|
|
9284
|
-
_inherits(NotificationDropDown, _React$Component);
|
|
9285
|
-
|
|
9286
|
-
var _super = _createSuper(NotificationDropDown);
|
|
9287
|
-
|
|
9288
9019
|
function NotificationDropDown(props) {
|
|
9289
9020
|
var _this;
|
|
9290
|
-
|
|
9291
9021
|
_classCallCheck(this, NotificationDropDown);
|
|
9292
|
-
|
|
9293
|
-
_this
|
|
9294
|
-
|
|
9295
|
-
_defineProperty(_assertThisInitialized(_this), "postUpdate", function (selectedOption) {
|
|
9022
|
+
_this = _callSuper(this, NotificationDropDown, [props]);
|
|
9023
|
+
_defineProperty(_this, "postUpdate", function (selectedOption) {
|
|
9296
9024
|
_this.setState({
|
|
9297
9025
|
request: _objectSpread2(_objectSpread2({}, request), {}, {
|
|
9298
9026
|
fetching: true
|
|
9299
9027
|
})
|
|
9300
9028
|
});
|
|
9301
|
-
|
|
9302
9029
|
_this.props.setSchedule(selectedOption.value).then(function () {
|
|
9303
9030
|
_this.setState({
|
|
9304
9031
|
selectedOption: selectedOption,
|
|
@@ -9306,7 +9033,6 @@
|
|
|
9306
9033
|
success: true
|
|
9307
9034
|
})
|
|
9308
9035
|
});
|
|
9309
|
-
|
|
9310
9036
|
success('Notification Frequency Updated');
|
|
9311
9037
|
}).catch(function () {
|
|
9312
9038
|
_this.setState({
|
|
@@ -9314,12 +9040,10 @@
|
|
|
9314
9040
|
failed: true
|
|
9315
9041
|
})
|
|
9316
9042
|
});
|
|
9317
|
-
|
|
9318
9043
|
error('Error Ocurred');
|
|
9319
9044
|
});
|
|
9320
9045
|
});
|
|
9321
|
-
|
|
9322
|
-
_defineProperty(_assertThisInitialized(_this), "getOptionsFromEnumResult", function (enumResult) {
|
|
9046
|
+
_defineProperty(_this, "getOptionsFromEnumResult", function (enumResult) {
|
|
9323
9047
|
var enumValues = enumResult.data.__type.enumValues;
|
|
9324
9048
|
return enumValues.map(function (enumItem) {
|
|
9325
9049
|
return {
|
|
@@ -9328,14 +9052,10 @@
|
|
|
9328
9052
|
};
|
|
9329
9053
|
});
|
|
9330
9054
|
});
|
|
9331
|
-
|
|
9332
|
-
_defineProperty(_assertThisInitialized(_this), "onData", function (_ref) {
|
|
9055
|
+
_defineProperty(_this, "onData", function (_ref) {
|
|
9333
9056
|
var data = _ref.data;
|
|
9334
|
-
|
|
9335
9057
|
var options = _this.getOptionsFromEnumResult(data);
|
|
9336
|
-
|
|
9337
9058
|
var currentValue = data.data.user.email_interest_send_schedule;
|
|
9338
|
-
|
|
9339
9059
|
_this.setState(function (prevState) {
|
|
9340
9060
|
return {
|
|
9341
9061
|
options: options,
|
|
@@ -9347,12 +9067,11 @@
|
|
|
9347
9067
|
};
|
|
9348
9068
|
});
|
|
9349
9069
|
});
|
|
9350
|
-
|
|
9351
|
-
_defineProperty(_assertThisInitialized(_this), "render", function () {
|
|
9070
|
+
_defineProperty(_this, "render", function () {
|
|
9352
9071
|
var _this$state = _this.state,
|
|
9353
|
-
|
|
9354
|
-
|
|
9355
|
-
|
|
9072
|
+
options = _this$state.options,
|
|
9073
|
+
selectedOption = _this$state.selectedOption,
|
|
9074
|
+
updating = _this$state.request.fetching;
|
|
9356
9075
|
return /*#__PURE__*/React__default.createElement(NotifyContainer, null, /*#__PURE__*/React__default.createElement(LuxityNotifications, null), /*#__PURE__*/React__default.createElement(LuxityPageReady, {
|
|
9357
9076
|
getRequestPromise: _this.props.getSchedule,
|
|
9358
9077
|
onData: function onData(data) {
|
|
@@ -9375,7 +9094,6 @@
|
|
|
9375
9094
|
value: selectedOption
|
|
9376
9095
|
}))));
|
|
9377
9096
|
});
|
|
9378
|
-
|
|
9379
9097
|
_this.state = {
|
|
9380
9098
|
options: [],
|
|
9381
9099
|
selectedOption: null,
|
|
@@ -9383,10 +9101,9 @@
|
|
|
9383
9101
|
};
|
|
9384
9102
|
return _this;
|
|
9385
9103
|
}
|
|
9386
|
-
|
|
9104
|
+
_inherits(NotificationDropDown, _React$Component);
|
|
9387
9105
|
return _createClass(NotificationDropDown);
|
|
9388
9106
|
}(React__default.Component);
|
|
9389
|
-
|
|
9390
9107
|
var NotificationDropDown$1 = themed(NotificationDropDown);
|
|
9391
9108
|
|
|
9392
9109
|
var _templateObject$F, _templateObject2$6;
|
|
@@ -9428,65 +9145,49 @@
|
|
|
9428
9145
|
}, function (props) {
|
|
9429
9146
|
return props.theme.colors.ntrlMin;
|
|
9430
9147
|
});
|
|
9148
|
+
|
|
9431
9149
|
/**
|
|
9432
9150
|
* Multiselector with a GraphQL flavour (TODO: to be revised to make it remote api agnostic)
|
|
9433
9151
|
*/
|
|
9434
|
-
|
|
9435
9152
|
var GraphQLMultiSelector = /*#__PURE__*/function (_React$Component) {
|
|
9436
|
-
_inherits(GraphQLMultiSelector, _React$Component);
|
|
9437
|
-
|
|
9438
|
-
var _super = _createSuper(GraphQLMultiSelector);
|
|
9439
|
-
|
|
9440
9153
|
function GraphQLMultiSelector(props) {
|
|
9441
9154
|
var _this;
|
|
9442
|
-
|
|
9443
9155
|
_classCallCheck(this, GraphQLMultiSelector);
|
|
9444
|
-
|
|
9445
|
-
_this
|
|
9446
|
-
|
|
9447
|
-
_defineProperty(_assertThisInitialized(_this), "componentDidUpdate", function (prevProps) {
|
|
9156
|
+
_this = _callSuper(this, GraphQLMultiSelector, [props]);
|
|
9157
|
+
_defineProperty(_this, "componentDidUpdate", function (prevProps) {
|
|
9448
9158
|
if (prevProps.graphQuery !== _this.props.graphQuery) {
|
|
9449
9159
|
_this.makeRequest();
|
|
9450
9160
|
}
|
|
9451
9161
|
});
|
|
9452
|
-
|
|
9453
|
-
_defineProperty(_assertThisInitialized(_this), "makeRequest", function () {
|
|
9162
|
+
_defineProperty(_this, "makeRequest", function () {
|
|
9454
9163
|
_this.pageReady.refreshPage();
|
|
9455
9164
|
});
|
|
9456
|
-
|
|
9457
|
-
_defineProperty(_assertThisInitialized(_this), "emptySelected", function () {
|
|
9165
|
+
_defineProperty(_this, "emptySelected", function () {
|
|
9458
9166
|
return _this.setState({
|
|
9459
9167
|
selected: [ALL_ITEM]
|
|
9460
9168
|
});
|
|
9461
9169
|
});
|
|
9462
|
-
|
|
9463
|
-
_defineProperty(_assertThisInitialized(_this), "setNewResults", function (res) {
|
|
9170
|
+
_defineProperty(_this, "setNewResults", function (res) {
|
|
9464
9171
|
var selectedIds = _this.state.selected.map(function (sel) {
|
|
9465
9172
|
return sel.id;
|
|
9466
9173
|
});
|
|
9467
|
-
|
|
9468
9174
|
var pagination = _this.props.resultProcessor(res);
|
|
9469
|
-
|
|
9470
9175
|
var allSelected = _this.state.selected.some(function (item) {
|
|
9471
9176
|
return item.id === ALL_ITEM.id;
|
|
9472
9177
|
});
|
|
9473
|
-
|
|
9474
9178
|
var newList = pagination.data.filter(function (newItem) {
|
|
9475
9179
|
return !selectedIds.includes(newItem.id);
|
|
9476
9180
|
});
|
|
9477
9181
|
newList = allSelected ? newList : [ALL_ITEM].concat(_toConsumableArray(newList));
|
|
9478
|
-
|
|
9479
9182
|
_this.setState({
|
|
9480
9183
|
list: newList,
|
|
9481
9184
|
pagination: pagination
|
|
9482
9185
|
});
|
|
9483
9186
|
});
|
|
9484
|
-
|
|
9485
|
-
_defineProperty(_assertThisInitialized(_this), "onAddItem", function (addSelectedItem) {
|
|
9187
|
+
_defineProperty(_this, "onAddItem", function (addSelectedItem) {
|
|
9486
9188
|
_this.setState(function (prevState) {
|
|
9487
9189
|
var newSelectedList;
|
|
9488
9190
|
var newList;
|
|
9489
|
-
|
|
9490
9191
|
if (addSelectedItem.id === ALL_ITEM.id) {
|
|
9491
9192
|
// Clear Selected List
|
|
9492
9193
|
// and move previous Selected items to list
|
|
@@ -9506,7 +9207,6 @@
|
|
|
9506
9207
|
return item.id !== addSelectedItem.id;
|
|
9507
9208
|
})));
|
|
9508
9209
|
}
|
|
9509
|
-
|
|
9510
9210
|
return {
|
|
9511
9211
|
selected: newSelectedList,
|
|
9512
9212
|
list: newList
|
|
@@ -9517,24 +9217,20 @@
|
|
|
9517
9217
|
}));
|
|
9518
9218
|
});
|
|
9519
9219
|
});
|
|
9520
|
-
|
|
9521
|
-
_defineProperty(_assertThisInitialized(_this), "onRemoveItem", function (removeSelectedItem) {
|
|
9220
|
+
_defineProperty(_this, "onRemoveItem", function (removeSelectedItem) {
|
|
9522
9221
|
_this.setState(function (prevState) {
|
|
9523
9222
|
// Cannot remove ALL from selection by unselecting it
|
|
9524
9223
|
if ((removeSelectedItem === null || removeSelectedItem === void 0 ? void 0 : removeSelectedItem.id) === ALL_ITEM.id) {
|
|
9525
9224
|
return {};
|
|
9526
9225
|
}
|
|
9527
|
-
|
|
9528
9226
|
var newSelectedList = prevState.selected.filter(function (item) {
|
|
9529
9227
|
return item.id !== removeSelectedItem.id;
|
|
9530
9228
|
});
|
|
9531
|
-
|
|
9532
9229
|
var newList = _toConsumableArray(prevState.list).concat(removeSelectedItem).filter(function (item) {
|
|
9533
9230
|
return item.id !== ALL_ITEM.id;
|
|
9534
9231
|
}).sort(function (a, b) {
|
|
9535
9232
|
return a.id - b.id;
|
|
9536
9233
|
});
|
|
9537
|
-
|
|
9538
9234
|
return {
|
|
9539
9235
|
list: newList,
|
|
9540
9236
|
selected: newSelectedList.length ? newSelectedList : [ALL_ITEM]
|
|
@@ -9545,25 +9241,23 @@
|
|
|
9545
9241
|
}));
|
|
9546
9242
|
});
|
|
9547
9243
|
});
|
|
9548
|
-
|
|
9549
|
-
_defineProperty(_assertThisInitialized(_this), "onIsLoading", function (flag) {
|
|
9244
|
+
_defineProperty(_this, "onIsLoading", function (flag) {
|
|
9550
9245
|
_this.setState({
|
|
9551
9246
|
isLoading: flag
|
|
9552
9247
|
});
|
|
9553
9248
|
});
|
|
9554
|
-
|
|
9555
|
-
_defineProperty(_assertThisInitialized(_this), "render", function () {
|
|
9249
|
+
_defineProperty(_this, "render", function () {
|
|
9556
9250
|
var _this$props = _this.props,
|
|
9557
|
-
|
|
9558
|
-
|
|
9559
|
-
|
|
9560
|
-
|
|
9561
|
-
|
|
9251
|
+
baseClass = _this$props.baseClass,
|
|
9252
|
+
ItemRenderer = _this$props.itemRenderer,
|
|
9253
|
+
identifier = _this$props.identifier,
|
|
9254
|
+
triggerRequest = _this$props.triggerRequest,
|
|
9255
|
+
className = _this$props.className;
|
|
9562
9256
|
var _this$state = _this.state,
|
|
9563
|
-
|
|
9564
|
-
|
|
9565
|
-
|
|
9566
|
-
|
|
9257
|
+
list = _this$state.list,
|
|
9258
|
+
selected = _this$state.selected,
|
|
9259
|
+
pagination = _this$state.pagination,
|
|
9260
|
+
isLoading = _this$state.isLoading;
|
|
9567
9261
|
return /*#__PURE__*/React__default.createElement(StyledMultiselector, null, /*#__PURE__*/React__default.createElement("div", {
|
|
9568
9262
|
"data-qe-id": identifier,
|
|
9569
9263
|
className: "".concat(className, " ").concat(baseClass)
|
|
@@ -9602,7 +9296,6 @@
|
|
|
9602
9296
|
type: "button"
|
|
9603
9297
|
}, "SHOW MORE"))));
|
|
9604
9298
|
});
|
|
9605
|
-
|
|
9606
9299
|
_this.state = {
|
|
9607
9300
|
selected: [ALL_ITEM],
|
|
9608
9301
|
list: [],
|
|
@@ -9611,10 +9304,9 @@
|
|
|
9611
9304
|
};
|
|
9612
9305
|
return _this;
|
|
9613
9306
|
}
|
|
9614
|
-
|
|
9307
|
+
_inherits(GraphQLMultiSelector, _React$Component);
|
|
9615
9308
|
return _createClass(GraphQLMultiSelector);
|
|
9616
9309
|
}(React__default.Component);
|
|
9617
|
-
|
|
9618
9310
|
GraphQLMultiSelector.defaultProps = {
|
|
9619
9311
|
baseClass: 'multiselector'
|
|
9620
9312
|
};
|
|
@@ -9635,13 +9327,12 @@
|
|
|
9635
9327
|
});
|
|
9636
9328
|
|
|
9637
9329
|
var _templateObject$G;
|
|
9638
|
-
|
|
9639
9330
|
var Title$3 = function Title(_ref) {
|
|
9640
9331
|
var baseClass = _ref.baseClass,
|
|
9641
|
-
|
|
9642
|
-
|
|
9643
|
-
|
|
9644
|
-
|
|
9332
|
+
className = _ref.className,
|
|
9333
|
+
title = _ref.title,
|
|
9334
|
+
searchPlaceHolder = _ref.searchPlaceHolder,
|
|
9335
|
+
onSearchChanged = _ref.onSearchChanged;
|
|
9645
9336
|
return /*#__PURE__*/React__default.createElement(InterestsSubheading, {
|
|
9646
9337
|
className: "".concat(className, " ").concat(baseClass, "__title"),
|
|
9647
9338
|
title: title
|
|
@@ -9654,7 +9345,6 @@
|
|
|
9654
9345
|
onChange: onSearchChanged
|
|
9655
9346
|
})));
|
|
9656
9347
|
};
|
|
9657
|
-
|
|
9658
9348
|
var StyledTitle = styled__default(Title$3)(_templateObject$G || (_templateObject$G = _taggedTemplateLiteral(["\n margin-bottom: ", ";\n font-weight: bold;\n display: flex;\n align-items: center;\n font-size: ", ";\n\n .title__search,\n .title__search {\n display: flex;\n justify-content: center;\n align-items: center;\n min-height: 30px;\n margin-bottom: ", ";\n\n svg {\n margin-left: ", ";\n fill: ", ";\n stroke: ", ";\n }\n\n input {\n width: 140px;\n border: none;\n font-size: ", ";\n transition: 0.2s border-color ease-in-out;\n margin-left: ", ";\n padding: 0;\n\n :focus {\n border-color: ", ";\n border-bottom: none;\n }\n }\n }\n"])), function (props) {
|
|
9659
9349
|
return props.theme.marginPaddings[2];
|
|
9660
9350
|
}, function (props) {
|
|
@@ -9677,37 +9367,26 @@
|
|
|
9677
9367
|
var Title$4 = themed(StyledTitle);
|
|
9678
9368
|
|
|
9679
9369
|
var debounceBuilder$3 = functions.debounced(200);
|
|
9680
|
-
|
|
9681
9370
|
/**
|
|
9682
9371
|
* Luxity flavoured GraphQLMultiselector with text Search, category and limit controls
|
|
9683
9372
|
*/
|
|
9684
9373
|
var LuxityGraphQLMultiselector = /*#__PURE__*/function (_React$Component) {
|
|
9685
|
-
_inherits(LuxityGraphQLMultiselector, _React$Component);
|
|
9686
|
-
|
|
9687
|
-
var _super = _createSuper(LuxityGraphQLMultiselector);
|
|
9688
|
-
|
|
9689
9374
|
function LuxityGraphQLMultiselector(props) {
|
|
9690
9375
|
var _this;
|
|
9691
|
-
|
|
9692
9376
|
_classCallCheck(this, LuxityGraphQLMultiselector);
|
|
9693
|
-
|
|
9694
|
-
_this
|
|
9695
|
-
|
|
9696
|
-
_defineProperty(_assertThisInitialized(_this), "multiSelectorRef", /*#__PURE__*/React__default.createRef());
|
|
9697
|
-
|
|
9698
|
-
_defineProperty(_assertThisInitialized(_this), "increaseLimit", function () {
|
|
9377
|
+
_this = _callSuper(this, LuxityGraphQLMultiselector, [props]);
|
|
9378
|
+
_defineProperty(_this, "multiSelectorRef", /*#__PURE__*/React__default.createRef());
|
|
9379
|
+
_defineProperty(_this, "increaseLimit", function () {
|
|
9699
9380
|
_this.setState(function (prevState) {
|
|
9700
9381
|
return {
|
|
9701
9382
|
limit: prevState.limit + _this.props.queryLimitIncrement
|
|
9702
9383
|
};
|
|
9703
9384
|
});
|
|
9704
9385
|
});
|
|
9705
|
-
|
|
9706
|
-
_defineProperty(_assertThisInitialized(_this), "onChange", function (selection) {
|
|
9386
|
+
_defineProperty(_this, "onChange", function (selection) {
|
|
9707
9387
|
_this.props.onChange(selection);
|
|
9708
9388
|
});
|
|
9709
|
-
|
|
9710
|
-
_defineProperty(_assertThisInitialized(_this), "onSearchChanged", function (event) {
|
|
9389
|
+
_defineProperty(_this, "onSearchChanged", function (event) {
|
|
9711
9390
|
event.preventDefault();
|
|
9712
9391
|
var searchText = event.target.value;
|
|
9713
9392
|
debounceBuilder$3(function () {
|
|
@@ -9716,22 +9395,21 @@
|
|
|
9716
9395
|
});
|
|
9717
9396
|
});
|
|
9718
9397
|
});
|
|
9719
|
-
|
|
9720
|
-
_defineProperty(_assertThisInitialized(_this), "render", function () {
|
|
9398
|
+
_defineProperty(_this, "render", function () {
|
|
9721
9399
|
var _this$state = _this.state,
|
|
9722
|
-
|
|
9723
|
-
|
|
9724
|
-
|
|
9400
|
+
limit = _this$state.limit,
|
|
9401
|
+
category = _this$state.category,
|
|
9402
|
+
nameFilter = _this$state.nameFilter;
|
|
9725
9403
|
var _this$props = _this.props,
|
|
9726
|
-
|
|
9727
|
-
|
|
9728
|
-
|
|
9729
|
-
|
|
9730
|
-
|
|
9731
|
-
|
|
9732
|
-
|
|
9733
|
-
|
|
9734
|
-
|
|
9404
|
+
title = _this$props.title,
|
|
9405
|
+
baseClass = _this$props.baseClass,
|
|
9406
|
+
getGraphQuery = _this$props.getGraphQuery,
|
|
9407
|
+
resultProcessor = _this$props.resultProcessor,
|
|
9408
|
+
itemRenderer = _this$props.itemRenderer,
|
|
9409
|
+
searchPlaceHolder = _this$props.searchPlaceHolder,
|
|
9410
|
+
graphApi = _this$props.graphApi,
|
|
9411
|
+
identifier = _this$props.identifier,
|
|
9412
|
+
requestInstance = _this$props.requestInstance;
|
|
9735
9413
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
9736
9414
|
className: baseClass
|
|
9737
9415
|
}, /*#__PURE__*/React__default.createElement(Title$4, {
|
|
@@ -9754,7 +9432,6 @@
|
|
|
9754
9432
|
itemRenderer: itemRenderer
|
|
9755
9433
|
})));
|
|
9756
9434
|
});
|
|
9757
|
-
|
|
9758
9435
|
_this.state = {
|
|
9759
9436
|
limit: props.baseQueryLimit,
|
|
9760
9437
|
category: props.category,
|
|
@@ -9762,12 +9439,11 @@
|
|
|
9762
9439
|
};
|
|
9763
9440
|
return _this;
|
|
9764
9441
|
}
|
|
9765
|
-
|
|
9766
|
-
_createClass(LuxityGraphQLMultiselector, [{
|
|
9442
|
+
_inherits(LuxityGraphQLMultiselector, _React$Component);
|
|
9443
|
+
return _createClass(LuxityGraphQLMultiselector, [{
|
|
9767
9444
|
key: "componentDidUpdate",
|
|
9768
9445
|
value: function componentDidUpdate(prevProps) {
|
|
9769
9446
|
var _this$multiSelectorRe;
|
|
9770
|
-
|
|
9771
9447
|
if (prevProps.category !== this.props.category && (_this$multiSelectorRe = this.multiSelectorRef) !== null && _this$multiSelectorRe !== void 0 && _this$multiSelectorRe.current) {
|
|
9772
9448
|
this.multiSelectorRef.current.emptySelected();
|
|
9773
9449
|
}
|
|
@@ -9780,14 +9456,10 @@
|
|
|
9780
9456
|
category: props.category
|
|
9781
9457
|
};
|
|
9782
9458
|
}
|
|
9783
|
-
|
|
9784
9459
|
return null;
|
|
9785
9460
|
}
|
|
9786
9461
|
}]);
|
|
9787
|
-
|
|
9788
|
-
return LuxityGraphQLMultiselector;
|
|
9789
9462
|
}(React__default.Component);
|
|
9790
|
-
|
|
9791
9463
|
LuxityGraphQLMultiselector.defaultProps = {
|
|
9792
9464
|
baseClass: '',
|
|
9793
9465
|
searchPlaceHolder: '',
|
|
@@ -9808,11 +9480,10 @@
|
|
|
9808
9480
|
return props.theme.colors.ntrlMin;
|
|
9809
9481
|
});
|
|
9810
9482
|
var UnselectedButton = themed(BaseButton);
|
|
9811
|
-
|
|
9812
9483
|
var ItemRenderer = function ItemRenderer(_ref) {
|
|
9813
9484
|
var item = _ref.item,
|
|
9814
|
-
|
|
9815
|
-
|
|
9485
|
+
onSelect = _ref.onSelect,
|
|
9486
|
+
selected = _ref.selected;
|
|
9816
9487
|
var props = {
|
|
9817
9488
|
onClick: function onClick(e) {
|
|
9818
9489
|
e.preventDefault();
|
|
@@ -9824,12 +9495,12 @@
|
|
|
9824
9495
|
|
|
9825
9496
|
var BrandSelector = function BrandSelector(_ref) {
|
|
9826
9497
|
var onChange = _ref.onChange,
|
|
9827
|
-
|
|
9828
|
-
|
|
9829
|
-
|
|
9830
|
-
|
|
9831
|
-
|
|
9832
|
-
|
|
9498
|
+
category = _ref.category,
|
|
9499
|
+
graphApi = _ref.graphApi,
|
|
9500
|
+
itemRenderer = _ref.itemRenderer,
|
|
9501
|
+
getGraphQuery = _ref.getGraphQuery,
|
|
9502
|
+
resultProcessor = _ref.resultProcessor,
|
|
9503
|
+
requestInstance = _ref.requestInstance;
|
|
9833
9504
|
return /*#__PURE__*/React__default.createElement(LuxityGraphQLMultiselector, {
|
|
9834
9505
|
baseQueryLimit: 16,
|
|
9835
9506
|
title: "Brands",
|
|
@@ -9846,7 +9517,6 @@
|
|
|
9846
9517
|
requestInstance: requestInstance
|
|
9847
9518
|
});
|
|
9848
9519
|
};
|
|
9849
|
-
|
|
9850
9520
|
BrandSelector.defaultProps = {
|
|
9851
9521
|
itemRenderer: ItemRenderer,
|
|
9852
9522
|
resultProcessor: function resultProcessor(result) {
|
|
@@ -9856,12 +9526,12 @@
|
|
|
9856
9526
|
|
|
9857
9527
|
var StyleSelector = function StyleSelector(_ref) {
|
|
9858
9528
|
var onChange = _ref.onChange,
|
|
9859
|
-
|
|
9860
|
-
|
|
9861
|
-
|
|
9862
|
-
|
|
9863
|
-
|
|
9864
|
-
|
|
9529
|
+
category = _ref.category,
|
|
9530
|
+
graphApi = _ref.graphApi,
|
|
9531
|
+
itemRenderer = _ref.itemRenderer,
|
|
9532
|
+
getGraphQuery = _ref.getGraphQuery,
|
|
9533
|
+
resultProcessor = _ref.resultProcessor,
|
|
9534
|
+
requestInstance = _ref.requestInstance;
|
|
9865
9535
|
return /*#__PURE__*/React__default.createElement(LuxityGraphQLMultiselector, {
|
|
9866
9536
|
title: "Styles",
|
|
9867
9537
|
queryId: "getStyles",
|
|
@@ -9878,7 +9548,6 @@
|
|
|
9878
9548
|
requestInstance: requestInstance
|
|
9879
9549
|
});
|
|
9880
9550
|
};
|
|
9881
|
-
|
|
9882
9551
|
StyleSelector.defaultProps = {
|
|
9883
9552
|
itemRenderer: ItemRenderer,
|
|
9884
9553
|
resultProcessor: function resultProcessor(result) {
|
|
@@ -9910,17 +9579,14 @@
|
|
|
9910
9579
|
ShoeSizeFadeContainer.defaultProps = {
|
|
9911
9580
|
childVisible: false
|
|
9912
9581
|
};
|
|
9913
|
-
|
|
9914
9582
|
var OpacityTransitionRender = function OpacityTransitionRender(_ref) {
|
|
9915
9583
|
var shoeSizeType = _ref.shoeSizeType,
|
|
9916
|
-
|
|
9584
|
+
children = _ref.children;
|
|
9917
9585
|
var prevShoeSizeType = functions.usePrevious(shoeSizeType);
|
|
9918
|
-
|
|
9919
9586
|
var _React$useState = React__default.useState(false),
|
|
9920
|
-
|
|
9921
|
-
|
|
9922
|
-
|
|
9923
|
-
|
|
9587
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
9588
|
+
childVisible = _React$useState2[0],
|
|
9589
|
+
setChildVisible = _React$useState2[1];
|
|
9924
9590
|
React__default.useEffect(function () {
|
|
9925
9591
|
if (prevShoeSizeType !== shoeSizeType) {
|
|
9926
9592
|
setChildVisible(false);
|
|
@@ -9933,30 +9599,25 @@
|
|
|
9933
9599
|
childVisible: childVisible
|
|
9934
9600
|
}, children);
|
|
9935
9601
|
};
|
|
9936
|
-
|
|
9937
9602
|
var WrappedShoeSizeSelector = function WrappedShoeSizeSelector(_ref2) {
|
|
9938
9603
|
var onChange = _ref2.onChange,
|
|
9939
|
-
|
|
9940
|
-
|
|
9941
|
-
|
|
9942
|
-
|
|
9943
|
-
|
|
9604
|
+
requestInstance = _ref2.requestInstance,
|
|
9605
|
+
graphApi = _ref2.graphApi,
|
|
9606
|
+
defaultShoeSizeType = _ref2.defaultShoeSizeType,
|
|
9607
|
+
getGraphQuery = _ref2.getGraphQuery;
|
|
9944
9608
|
var _useState = React.useState(defaultShoeSizeType),
|
|
9945
|
-
|
|
9946
|
-
|
|
9947
|
-
|
|
9948
|
-
|
|
9609
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
9610
|
+
shoeSizeType = _useState2[0],
|
|
9611
|
+
setShoeSizeType = _useState2[1];
|
|
9949
9612
|
var _useState3 = React.useState(defaultShoeSizeType),
|
|
9950
|
-
|
|
9951
|
-
|
|
9952
|
-
|
|
9953
|
-
|
|
9613
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
9614
|
+
transitionedTo = _useState4[0],
|
|
9615
|
+
setTransitionedTo = _useState4[1];
|
|
9954
9616
|
var triggerRequest = function triggerRequest() {
|
|
9955
9617
|
return requestInstance.post(graphApi, {
|
|
9956
9618
|
query: getGraphQuery()
|
|
9957
9619
|
});
|
|
9958
9620
|
};
|
|
9959
|
-
|
|
9960
9621
|
var shoeSizeTypeProps = {
|
|
9961
9622
|
name: 'shoe_size_type',
|
|
9962
9623
|
noWrap: true,
|
|
@@ -9980,15 +9641,12 @@
|
|
|
9980
9641
|
checked: shoeSizeType === shoeSizeTypes.eu.value
|
|
9981
9642
|
}]
|
|
9982
9643
|
};
|
|
9983
|
-
|
|
9984
9644
|
var handlePropOnChange = function handlePropOnChange(value) {
|
|
9985
9645
|
var payload = _objectSpread2(_objectSpread2({}, value), {}, {
|
|
9986
9646
|
shoe_size_type: shoeSizeType
|
|
9987
9647
|
});
|
|
9988
|
-
|
|
9989
9648
|
onChange(payload);
|
|
9990
9649
|
};
|
|
9991
|
-
|
|
9992
9650
|
var renderShoeSizeSelector = function renderShoeSizeSelector() {
|
|
9993
9651
|
var passedShoeSizes = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
9994
9652
|
return /*#__PURE__*/React__default.createElement(ShoeSizeSelector, {
|
|
@@ -9998,38 +9656,32 @@
|
|
|
9998
9656
|
}
|
|
9999
9657
|
});
|
|
10000
9658
|
};
|
|
10001
|
-
|
|
10002
9659
|
var getShoeSizeSelector = function getShoeSizeSelector() {
|
|
10003
9660
|
var euShoeSizes = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
|
|
10004
9661
|
var ukShoeShoes = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
10005
|
-
|
|
10006
9662
|
if (shoeSizeType === shoeSizeTypes.eu.value) {
|
|
10007
9663
|
return renderShoeSizeSelector(euShoeSizes);
|
|
10008
9664
|
}
|
|
10009
|
-
|
|
10010
9665
|
if (shoeSizeType === shoeSizeTypes.uk.value) {
|
|
10011
9666
|
return renderShoeSizeSelector(ukShoeShoes);
|
|
10012
9667
|
}
|
|
10013
|
-
|
|
10014
9668
|
return null;
|
|
10015
9669
|
};
|
|
10016
|
-
|
|
10017
9670
|
return /*#__PURE__*/React__default.createElement(LuxityPageReady, {
|
|
10018
9671
|
getRequestPromise: triggerRequest
|
|
10019
9672
|
}, /*#__PURE__*/React__default.createElement(TitleWrapper, null, /*#__PURE__*/React__default.createElement(InterestsSubheading, {
|
|
10020
9673
|
title: "Shoe Size Range"
|
|
10021
9674
|
}, /*#__PURE__*/React__default.createElement(RadioButtons$1, shoeSizeTypeProps))), /*#__PURE__*/React__default.createElement(LuxityPageReadyContext.Consumer, null, function (_ref3) {
|
|
10022
9675
|
var _ref3$data$data = _ref3.data.data,
|
|
10023
|
-
|
|
10024
|
-
|
|
10025
|
-
|
|
10026
|
-
|
|
9676
|
+
_ref3$data$data$luxit = _ref3$data$data.luxity_eu_shoe_sizes,
|
|
9677
|
+
luxity_eu_shoe_sizes = _ref3$data$data$luxit === void 0 ? [] : _ref3$data$data$luxit,
|
|
9678
|
+
_ref3$data$data$luxit2 = _ref3$data$data.luxity_uk_shoe_sizes,
|
|
9679
|
+
luxity_uk_shoe_sizes = _ref3$data$data$luxit2 === void 0 ? [] : _ref3$data$data$luxit2;
|
|
10027
9680
|
return /*#__PURE__*/React__default.createElement(OpacityTransitionRender, {
|
|
10028
9681
|
shoeSizeType: transitionedTo
|
|
10029
9682
|
}, getShoeSizeSelector(luxity_eu_shoe_sizes, luxity_uk_shoe_sizes));
|
|
10030
9683
|
}));
|
|
10031
9684
|
};
|
|
10032
|
-
|
|
10033
9685
|
WrappedShoeSizeSelector.defaultProps = {
|
|
10034
9686
|
onChange: function onChange() {
|
|
10035
9687
|
return false;
|
|
@@ -10052,7 +9704,6 @@
|
|
|
10052
9704
|
});
|
|
10053
9705
|
|
|
10054
9706
|
var _excluded$7 = ["title", "checked", "renderIcon", "onChange", "checkedValue", "unCheckedValue"];
|
|
10055
|
-
|
|
10056
9707
|
var _templateObject$K, _templateObject2$8, _templateObject3$3;
|
|
10057
9708
|
var Content = styled__default.div(_templateObject$K || (_templateObject$K = _taggedTemplateLiteral(["\n background-color: transparent;\n border: 1px solid ", ";\n transition: 200ms ease-in-out;\n display: flex;\n align-items: center;\n justify-content: space-between;\n padding: ", ";\n cursor: pointer;\n"])), function (props) {
|
|
10058
9709
|
return props.theme.colors.primary;
|
|
@@ -10071,36 +9722,32 @@
|
|
|
10071
9722
|
}, Content, InputText, function (props) {
|
|
10072
9723
|
return props.theme.colors.ntrlMin;
|
|
10073
9724
|
}, Content);
|
|
9725
|
+
|
|
10074
9726
|
/**
|
|
10075
9727
|
* CheckButton: Styled checkbox that resembles a button
|
|
10076
9728
|
* */
|
|
10077
|
-
|
|
10078
9729
|
var CheckButton = function CheckButton(props) {
|
|
10079
9730
|
var title = props.title,
|
|
10080
|
-
|
|
10081
|
-
|
|
10082
|
-
|
|
10083
|
-
|
|
10084
|
-
|
|
10085
|
-
|
|
10086
|
-
|
|
9731
|
+
checked = props.checked,
|
|
9732
|
+
renderIcon = props.renderIcon,
|
|
9733
|
+
onChange = props.onChange,
|
|
9734
|
+
checkedValue = props.checkedValue,
|
|
9735
|
+
unCheckedValue = props.unCheckedValue,
|
|
9736
|
+
restProps = _objectWithoutProperties(props, _excluded$7);
|
|
10087
9737
|
var _React$useState = React__default.useState(checked),
|
|
10088
|
-
|
|
10089
|
-
|
|
10090
|
-
|
|
10091
|
-
|
|
9738
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
9739
|
+
checkedState = _React$useState2[0],
|
|
9740
|
+
setCheck = _React$useState2[1];
|
|
10092
9741
|
var prevCheckState = functions.usePrevious(checkedState);
|
|
10093
9742
|
React__default.useEffect(function () {
|
|
10094
9743
|
if (prevCheckState !== checkedState) {
|
|
10095
9744
|
onChange(checkedState);
|
|
10096
9745
|
}
|
|
10097
9746
|
}, [checkedState, onChange, prevCheckState]);
|
|
10098
|
-
|
|
10099
9747
|
var handleInputChange = function handleInputChange(e) {
|
|
10100
9748
|
var targetChecked = e.target.checked;
|
|
10101
9749
|
setCheck(targetChecked);
|
|
10102
9750
|
};
|
|
10103
|
-
|
|
10104
9751
|
return /*#__PURE__*/React__default.createElement(StyledLabel, null, /*#__PURE__*/React__default.createElement("input", _extends({
|
|
10105
9752
|
defaultChecked: checked
|
|
10106
9753
|
}, restProps, {
|
|
@@ -10108,7 +9755,6 @@
|
|
|
10108
9755
|
onChange: handleInputChange
|
|
10109
9756
|
})), /*#__PURE__*/React__default.createElement(Content, null, /*#__PURE__*/React__default.createElement(InputText, null, title), renderIcon(checkedState)));
|
|
10110
9757
|
};
|
|
10111
|
-
|
|
10112
9758
|
CheckButton.defaultProps = {
|
|
10113
9759
|
title: '',
|
|
10114
9760
|
checked: false,
|
|
@@ -10122,29 +9768,24 @@
|
|
|
10122
9768
|
var CheckButton$1 = themed(CheckButton);
|
|
10123
9769
|
|
|
10124
9770
|
var MALE$1 = genders.MALE,
|
|
10125
|
-
|
|
10126
|
-
|
|
9771
|
+
FEMALE$1 = genders.FEMALE;
|
|
10127
9772
|
/**
|
|
10128
9773
|
* Stylized CheckboxButton for selecting gender
|
|
10129
9774
|
* */
|
|
10130
9775
|
var GenderCheckbox = function GenderCheckbox(_ref) {
|
|
10131
9776
|
var gender = _ref.gender,
|
|
10132
|
-
|
|
10133
|
-
|
|
10134
|
-
|
|
9777
|
+
checked = _ref.checked,
|
|
9778
|
+
onInputChange = _ref.onInputChange;
|
|
10135
9779
|
var getTitle = function getTitle() {
|
|
10136
9780
|
switch (gender) {
|
|
10137
9781
|
case MALE$1:
|
|
10138
9782
|
return 'Male';
|
|
10139
|
-
|
|
10140
9783
|
case FEMALE$1:
|
|
10141
9784
|
return 'Female';
|
|
10142
|
-
|
|
10143
9785
|
default:
|
|
10144
9786
|
return '';
|
|
10145
9787
|
}
|
|
10146
9788
|
};
|
|
10147
|
-
|
|
10148
9789
|
return /*#__PURE__*/React__default.createElement(CheckButton$1, {
|
|
10149
9790
|
onChange: onInputChange,
|
|
10150
9791
|
checked: checked,
|
|
@@ -10152,22 +9793,20 @@
|
|
|
10152
9793
|
title: getTitle()
|
|
10153
9794
|
});
|
|
10154
9795
|
};
|
|
10155
|
-
|
|
10156
9796
|
GenderCheckbox.defaultProps = {
|
|
10157
9797
|
name: ''
|
|
10158
9798
|
};
|
|
10159
9799
|
|
|
10160
9800
|
var MALE$2 = genders.MALE,
|
|
10161
|
-
|
|
10162
|
-
|
|
9801
|
+
FEMALE$2 = genders.FEMALE;
|
|
10163
9802
|
/**
|
|
10164
9803
|
* GenderSelector: specialized selector to pick genders for the Interest Component
|
|
10165
9804
|
* */
|
|
10166
9805
|
var GenderSelector = function GenderSelector(_ref) {
|
|
10167
9806
|
var gender = _ref.gender,
|
|
10168
|
-
|
|
10169
|
-
|
|
10170
|
-
|
|
9807
|
+
onChange = _ref.onChange,
|
|
9808
|
+
maleInputRef = _ref.maleInputRef,
|
|
9809
|
+
femaleInputRef = _ref.femaleInputRef;
|
|
10171
9810
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
10172
9811
|
className: "gender-selector"
|
|
10173
9812
|
}, /*#__PURE__*/React__default.createElement(InterestsSubheading, {
|
|
@@ -10192,7 +9831,6 @@
|
|
|
10192
9831
|
checkBoxButtonRef: femaleInputRef
|
|
10193
9832
|
})));
|
|
10194
9833
|
};
|
|
10195
|
-
|
|
10196
9834
|
GenderSelector.defaultProps = {
|
|
10197
9835
|
gender: null,
|
|
10198
9836
|
onChange: function onChange() {
|
|
@@ -10250,16 +9888,14 @@
|
|
|
10250
9888
|
return props.theme.marginPaddings[2];
|
|
10251
9889
|
});
|
|
10252
9890
|
var AddInterestButtonContainer = styled__default.div(_templateObject5$1 || (_templateObject5$1 = _taggedTemplateLiteral(["\n display: flex;\n\n #add-icon {\n margin-bottom: 1.5rem;\n\n svg {\n width: 15px;\n }\n }\n"])));
|
|
10253
|
-
|
|
10254
9891
|
var AddIcon = function AddIcon(_ref) {
|
|
10255
9892
|
var onClick = _ref.onClick,
|
|
10256
|
-
|
|
9893
|
+
id = _ref.id;
|
|
10257
9894
|
return /*#__PURE__*/React__default.createElement(IconWrapper, {
|
|
10258
9895
|
id: id,
|
|
10259
9896
|
onClick: onClick
|
|
10260
9897
|
}, /*#__PURE__*/React__default.createElement(SvgWrapper, null, /*#__PURE__*/React__default.createElement(Add, null)));
|
|
10261
9898
|
};
|
|
10262
|
-
|
|
10263
9899
|
var defaultState = {
|
|
10264
9900
|
category_type: null,
|
|
10265
9901
|
brands: [],
|
|
@@ -10272,41 +9908,30 @@
|
|
|
10272
9908
|
request: _objectSpread2({}, request),
|
|
10273
9909
|
isCategoriesShown: false
|
|
10274
9910
|
};
|
|
9911
|
+
|
|
10275
9912
|
/**
|
|
10276
9913
|
* Generates Interest UI and submits graph payloads as a highly specialised component
|
|
10277
9914
|
*/
|
|
10278
|
-
|
|
10279
9915
|
var AddInterest = /*#__PURE__*/function (_React$Component) {
|
|
10280
|
-
_inherits(AddInterest, _React$Component);
|
|
10281
|
-
|
|
10282
|
-
var _super = _createSuper(AddInterest);
|
|
10283
|
-
|
|
10284
9916
|
function AddInterest(props) {
|
|
10285
9917
|
var _this;
|
|
10286
|
-
|
|
10287
9918
|
_classCallCheck(this, AddInterest);
|
|
10288
|
-
|
|
10289
|
-
_this
|
|
10290
|
-
|
|
10291
|
-
_defineProperty(
|
|
10292
|
-
|
|
10293
|
-
_defineProperty(_assertThisInitialized(_this), "femaleCheckBoxRef", /*#__PURE__*/React__default.createRef());
|
|
10294
|
-
|
|
10295
|
-
_defineProperty(_assertThisInitialized(_this), "onCategoryChanged", function (categoryType) {
|
|
9919
|
+
_this = _callSuper(this, AddInterest, [props]);
|
|
9920
|
+
_defineProperty(_this, "maleCheckBoxRef", /*#__PURE__*/React__default.createRef());
|
|
9921
|
+
_defineProperty(_this, "femaleCheckBoxRef", /*#__PURE__*/React__default.createRef());
|
|
9922
|
+
_defineProperty(_this, "onCategoryChanged", function (categoryType) {
|
|
10296
9923
|
_this.setState({
|
|
10297
9924
|
category_type: categoryType,
|
|
10298
9925
|
brands: [],
|
|
10299
9926
|
styles: []
|
|
10300
9927
|
});
|
|
10301
9928
|
});
|
|
10302
|
-
|
|
10303
|
-
_defineProperty(_assertThisInitialized(_this), "onGenderChanged", function (isChecked, gender) {
|
|
9929
|
+
_defineProperty(_this, "onGenderChanged", function (isChecked, gender) {
|
|
10304
9930
|
return _this.setState(function (prevState) {
|
|
10305
9931
|
// current array of options
|
|
10306
9932
|
var gendersSelected = _toConsumableArray(prevState.gender);
|
|
10307
|
-
|
|
10308
|
-
|
|
10309
|
-
|
|
9933
|
+
var index;
|
|
9934
|
+
// check if the check box is checked or unchecked
|
|
10310
9935
|
if (isChecked) {
|
|
10311
9936
|
gendersSelected.push(gender);
|
|
10312
9937
|
} else {
|
|
@@ -10314,67 +9939,57 @@
|
|
|
10314
9939
|
index = gendersSelected.indexOf(gender);
|
|
10315
9940
|
gendersSelected.splice(index, 1);
|
|
10316
9941
|
}
|
|
10317
|
-
|
|
10318
9942
|
return {
|
|
10319
9943
|
gender: gendersSelected
|
|
10320
9944
|
};
|
|
10321
9945
|
});
|
|
10322
9946
|
});
|
|
10323
|
-
|
|
10324
|
-
_defineProperty(_assertThisInitialized(_this), "onBrandsChanged", function (brandsArray) {
|
|
9947
|
+
_defineProperty(_this, "onBrandsChanged", function (brandsArray) {
|
|
10325
9948
|
_this.setState({
|
|
10326
9949
|
brands: brandsArray.map(function (brand) {
|
|
10327
9950
|
return brand.id;
|
|
10328
9951
|
})
|
|
10329
9952
|
});
|
|
10330
9953
|
});
|
|
10331
|
-
|
|
10332
|
-
_defineProperty(_assertThisInitialized(_this), "onShoeSizesChanged", function (shoeSizes) {
|
|
9954
|
+
_defineProperty(_this, "onShoeSizesChanged", function (shoeSizes) {
|
|
10333
9955
|
_this.setState(_objectSpread2({}, shoeSizes));
|
|
10334
9956
|
});
|
|
10335
|
-
|
|
10336
|
-
_defineProperty(_assertThisInitialized(_this), "onPriceRangesChanged", function (priceRange) {
|
|
9957
|
+
_defineProperty(_this, "onPriceRangesChanged", function (priceRange) {
|
|
10337
9958
|
_this.setState(_objectSpread2({}, priceRange));
|
|
10338
9959
|
});
|
|
10339
|
-
|
|
10340
|
-
_defineProperty(_assertThisInitialized(_this), "onStylesChanged", function (stylesArray) {
|
|
9960
|
+
_defineProperty(_this, "onStylesChanged", function (stylesArray) {
|
|
10341
9961
|
_this.setState({
|
|
10342
9962
|
styles: stylesArray.map(function (style) {
|
|
10343
9963
|
return style.id;
|
|
10344
9964
|
})
|
|
10345
9965
|
});
|
|
10346
9966
|
});
|
|
10347
|
-
|
|
10348
|
-
_defineProperty(_assertThisInitialized(_this), "payloadIsValid", function () {
|
|
9967
|
+
_defineProperty(_this, "payloadIsValid", function () {
|
|
10349
9968
|
// price/shoe-size always have initial values as soon as category is set
|
|
10350
9969
|
var category_type = _this.state.category_type;
|
|
10351
9970
|
return category_type !== null;
|
|
10352
9971
|
});
|
|
10353
|
-
|
|
10354
|
-
_defineProperty(_assertThisInitialized(_this), "submitInterest", function () {
|
|
9972
|
+
_defineProperty(_this, "submitInterest", function () {
|
|
10355
9973
|
_this.setState({
|
|
10356
9974
|
request: _objectSpread2(_objectSpread2({}, request), {}, {
|
|
10357
9975
|
fetching: true
|
|
10358
9976
|
})
|
|
10359
9977
|
});
|
|
10360
|
-
|
|
10361
9978
|
var _this$state = _this.state,
|
|
10362
|
-
|
|
10363
|
-
|
|
10364
|
-
|
|
10365
|
-
|
|
10366
|
-
|
|
10367
|
-
|
|
10368
|
-
|
|
10369
|
-
|
|
10370
|
-
|
|
10371
|
-
|
|
9979
|
+
brands = _this$state.brands,
|
|
9980
|
+
min_shoe_size_id = _this$state.min_shoe_size_id,
|
|
9981
|
+
max_shoe_size_id = _this$state.max_shoe_size_id,
|
|
9982
|
+
shoe_size_type = _this$state.shoe_size_type,
|
|
9983
|
+
min_price = _this$state.min_price,
|
|
9984
|
+
max_price = _this$state.max_price,
|
|
9985
|
+
styles = _this$state.styles,
|
|
9986
|
+
category_type = _this$state.category_type,
|
|
9987
|
+
requestState = _this$state.request,
|
|
9988
|
+
gender = _this$state.gender;
|
|
10372
9989
|
var payloadGender = gender[0];
|
|
10373
|
-
|
|
10374
9990
|
if (gender.length > 1 || !gender.length) {
|
|
10375
9991
|
payloadGender = UNISEX$1;
|
|
10376
9992
|
}
|
|
10377
|
-
|
|
10378
9993
|
var basePayload = {
|
|
10379
9994
|
category_type: category_type,
|
|
10380
9995
|
brands: brands,
|
|
@@ -10389,27 +10004,21 @@
|
|
|
10389
10004
|
max_shoe_size_id: max_shoe_size_id,
|
|
10390
10005
|
shoe_size_type: shoe_size_type
|
|
10391
10006
|
} : {};
|
|
10392
|
-
|
|
10393
10007
|
var payload = _objectSpread2(_objectSpread2({}, basePayload), shoeSizesPayload);
|
|
10394
|
-
|
|
10395
10008
|
simpleRequest(_this.props.requestInstance, _this.props.addInterestApi, method.POST, payload, function () {
|
|
10396
10009
|
_this.setState({
|
|
10397
10010
|
request: _objectSpread2(_objectSpread2({}, request), {}, {
|
|
10398
10011
|
success: true
|
|
10399
10012
|
})
|
|
10400
10013
|
});
|
|
10401
|
-
|
|
10402
10014
|
_this.props.onSubmitSuccess(_objectSpread2({}, payload));
|
|
10403
10015
|
}, _this.handleRequestError);
|
|
10404
10016
|
});
|
|
10405
|
-
|
|
10406
|
-
_defineProperty(_assertThisInitialized(_this), "handleRequestError", function (_ref2) {
|
|
10017
|
+
_defineProperty(_this, "handleRequestError", function (_ref2) {
|
|
10407
10018
|
var data = _ref2.data;
|
|
10408
|
-
|
|
10409
10019
|
_this.setState({
|
|
10410
10020
|
request: _objectSpread2({}, request)
|
|
10411
10021
|
});
|
|
10412
|
-
|
|
10413
10022
|
var errorMessages = Object.keys(data).map(function (key) {
|
|
10414
10023
|
return data[key];
|
|
10415
10024
|
}).flat();
|
|
@@ -10419,34 +10028,30 @@
|
|
|
10419
10028
|
}, message);
|
|
10420
10029
|
}));
|
|
10421
10030
|
});
|
|
10422
|
-
|
|
10423
|
-
_defineProperty(_assertThisInitialized(_this), "resetState", function () {
|
|
10031
|
+
_defineProperty(_this, "resetState", function () {
|
|
10424
10032
|
_this.setState(_objectSpread2({}, defaultState));
|
|
10425
10033
|
});
|
|
10426
|
-
|
|
10427
|
-
_defineProperty(_assertThisInitialized(_this), "handleGenderChange", function (isChecked, gender) {
|
|
10034
|
+
_defineProperty(_this, "handleGenderChange", function (isChecked, gender) {
|
|
10428
10035
|
return _this.onGenderChanged(isChecked, gender);
|
|
10429
10036
|
});
|
|
10430
|
-
|
|
10431
|
-
_defineProperty(_assertThisInitialized(_this), "onAddInterestClick", function () {
|
|
10037
|
+
_defineProperty(_this, "onAddInterestClick", function () {
|
|
10432
10038
|
_this.setState(function (prevState) {
|
|
10433
10039
|
return _objectSpread2(_objectSpread2({}, prevState), {}, {
|
|
10434
10040
|
isCategoriesShown: true
|
|
10435
10041
|
});
|
|
10436
10042
|
});
|
|
10437
10043
|
});
|
|
10438
|
-
|
|
10439
|
-
_defineProperty(_assertThisInitialized(_this), "render", function () {
|
|
10044
|
+
_defineProperty(_this, "render", function () {
|
|
10440
10045
|
var _this$state2 = _this.state,
|
|
10441
|
-
|
|
10442
|
-
|
|
10046
|
+
category_type = _this$state2.category_type,
|
|
10047
|
+
fetching = _this$state2.request.fetching;
|
|
10443
10048
|
var _this$props = _this.props,
|
|
10444
|
-
|
|
10445
|
-
|
|
10446
|
-
|
|
10447
|
-
|
|
10448
|
-
|
|
10449
|
-
|
|
10049
|
+
requestInstance = _this$props.requestInstance,
|
|
10050
|
+
baseGraphApi = _this$props.baseGraphApi,
|
|
10051
|
+
getBrandsGraphQuery = _this$props.getBrandsGraphQuery,
|
|
10052
|
+
getStylesGraphQuery = _this$props.getStylesGraphQuery,
|
|
10053
|
+
getShoesGraphQuery = _this$props.getShoesGraphQuery,
|
|
10054
|
+
defaultShoeSizeType = _this$props.defaultShoeSizeType;
|
|
10450
10055
|
return /*#__PURE__*/React__default.createElement(React.Fragment, null, !_this.state.isCategoriesShown && /*#__PURE__*/React__default.createElement(AddInterestButtonContainer, {
|
|
10451
10056
|
onClick: _this.onAddInterestClick
|
|
10452
10057
|
}, /*#__PURE__*/React__default.createElement(AddInterestButton, null, "Add Interest"), /*#__PURE__*/React__default.createElement(AddIcon, {
|
|
@@ -10494,19 +10099,16 @@
|
|
|
10494
10099
|
type: "button",
|
|
10495
10100
|
onClick: function onClick() {
|
|
10496
10101
|
_this.submitInterest();
|
|
10497
|
-
|
|
10498
10102
|
_this.resetState();
|
|
10499
10103
|
}
|
|
10500
10104
|
}, fetching ? 'SAVING' : 'SAVE')))))));
|
|
10501
10105
|
});
|
|
10502
|
-
|
|
10503
10106
|
_this.state = _objectSpread2({}, defaultState);
|
|
10504
10107
|
return _this;
|
|
10505
10108
|
}
|
|
10506
|
-
|
|
10109
|
+
_inherits(AddInterest, _React$Component);
|
|
10507
10110
|
return _createClass(AddInterest);
|
|
10508
10111
|
}(React__default.Component);
|
|
10509
|
-
|
|
10510
10112
|
var AddInterest$1 = themed(AddInterest);
|
|
10511
10113
|
|
|
10512
10114
|
var _templateObject$M;
|
|
@@ -10517,7 +10119,6 @@
|
|
|
10517
10119
|
}, function (props) {
|
|
10518
10120
|
return props.theme.marginPaddings[1];
|
|
10519
10121
|
}, media.xs);
|
|
10520
|
-
|
|
10521
10122
|
var MyInterestTitleHeading = function MyInterestTitleHeading() {
|
|
10522
10123
|
return /*#__PURE__*/React__default.createElement(MyInterestTitleHeadingContainer, null, /*#__PURE__*/React__default.createElement("div", {
|
|
10523
10124
|
className: "heading-title-section"
|
|
@@ -10537,7 +10138,6 @@
|
|
|
10537
10138
|
className: "heading-title-empty"
|
|
10538
10139
|
}));
|
|
10539
10140
|
};
|
|
10540
|
-
|
|
10541
10141
|
var MyInterestTitleHeading$1 = themed(MyInterestTitleHeading);
|
|
10542
10142
|
|
|
10543
10143
|
var _templateObject$N;
|
|
@@ -10547,43 +10147,34 @@
|
|
|
10547
10147
|
var AccountIcon = themed(function () {
|
|
10548
10148
|
return /*#__PURE__*/React__default.createElement(SvgWrapper$2, null, /*#__PURE__*/React__default.createElement(Account, null));
|
|
10549
10149
|
});
|
|
10550
|
-
|
|
10551
10150
|
/**
|
|
10552
10151
|
* Page/View that controls the viewing and Adding of Luxity Interests
|
|
10553
10152
|
*/
|
|
10554
10153
|
var Interests = /*#__PURE__*/function (_React$Component) {
|
|
10555
|
-
_inherits(Interests, _React$Component);
|
|
10556
|
-
|
|
10557
|
-
var _super = _createSuper(Interests);
|
|
10558
|
-
|
|
10559
10154
|
function Interests(props) {
|
|
10560
10155
|
var _this;
|
|
10561
|
-
|
|
10562
10156
|
_classCallCheck(this, Interests);
|
|
10563
|
-
|
|
10564
|
-
_this
|
|
10565
|
-
|
|
10566
|
-
_defineProperty(_assertThisInitialized(_this), "setInterests", function (data) {
|
|
10157
|
+
_this = _callSuper(this, Interests, [props]);
|
|
10158
|
+
_defineProperty(_this, "setInterests", function (data) {
|
|
10567
10159
|
var interests = data.data.data.interests.data;
|
|
10568
|
-
|
|
10569
10160
|
_this.setState({
|
|
10570
10161
|
interests: interests
|
|
10571
10162
|
});
|
|
10572
10163
|
});
|
|
10573
|
-
|
|
10574
|
-
_defineProperty(
|
|
10164
|
+
// eslint-disable-next-line
|
|
10165
|
+
_defineProperty(_this, "onInterestSubmitSuccess", function (interestItem) {
|
|
10575
10166
|
// due to the fact that we dont get the Interest payload back - we have to re-request the list
|
|
10576
10167
|
_this.triggerInterestRequest().then(function (res) {
|
|
10577
10168
|
return _this.setInterests(res);
|
|
10578
|
-
});
|
|
10169
|
+
});
|
|
10170
|
+
|
|
10171
|
+
// UNCOMMENT WHEN Interest Items is returned as expected Object Shape
|
|
10579
10172
|
// this.setState(prevState => {
|
|
10580
10173
|
// const newInterests = [interestItem].concat(prevState.interests);
|
|
10581
10174
|
// return { ...prevState, interests: newInterests };
|
|
10582
10175
|
// });
|
|
10583
|
-
|
|
10584
10176
|
});
|
|
10585
|
-
|
|
10586
|
-
_defineProperty(_assertThisInitialized(_this), "onDeleteInterest", function (deletedItem) {
|
|
10177
|
+
_defineProperty(_this, "onDeleteInterest", function (deletedItem) {
|
|
10587
10178
|
_this.setState(function (prevState) {
|
|
10588
10179
|
var newInterests = prevState.interests.filter(function (item) {
|
|
10589
10180
|
return item.id !== deletedItem.id;
|
|
@@ -10593,41 +10184,38 @@
|
|
|
10593
10184
|
});
|
|
10594
10185
|
});
|
|
10595
10186
|
});
|
|
10596
|
-
|
|
10597
|
-
_defineProperty(_assertThisInitialized(_this), "triggerInterestRequest", function () {
|
|
10187
|
+
_defineProperty(_this, "triggerInterestRequest", function () {
|
|
10598
10188
|
var _this$props = _this.props,
|
|
10599
|
-
|
|
10600
|
-
|
|
10601
|
-
|
|
10189
|
+
requestInstance = _this$props.requestInstance,
|
|
10190
|
+
baseGraphApi = _this$props.baseGraphApi,
|
|
10191
|
+
interestQuery = _this$props.interestQuery;
|
|
10602
10192
|
return requestInstance.post("".concat(baseGraphApi, "?id=getInterests"), {
|
|
10603
10193
|
query: interestQuery
|
|
10604
10194
|
});
|
|
10605
10195
|
});
|
|
10606
|
-
|
|
10607
10196
|
_this.state = {
|
|
10608
10197
|
interests: []
|
|
10609
10198
|
};
|
|
10610
10199
|
return _this;
|
|
10611
10200
|
}
|
|
10612
|
-
|
|
10613
|
-
_createClass(Interests, [{
|
|
10201
|
+
_inherits(Interests, _React$Component);
|
|
10202
|
+
return _createClass(Interests, [{
|
|
10614
10203
|
key: "render",
|
|
10615
10204
|
value: function render() {
|
|
10616
10205
|
var _this2 = this;
|
|
10617
|
-
|
|
10618
10206
|
var interests = this.state.interests;
|
|
10619
10207
|
var _this$props2 = this.props,
|
|
10620
|
-
|
|
10621
|
-
|
|
10622
|
-
|
|
10623
|
-
|
|
10624
|
-
|
|
10625
|
-
|
|
10626
|
-
|
|
10627
|
-
|
|
10628
|
-
|
|
10629
|
-
|
|
10630
|
-
|
|
10208
|
+
addInterestApi = _this$props2.addInterestApi,
|
|
10209
|
+
requestInstance = _this$props2.requestInstance,
|
|
10210
|
+
baseGraphApi = _this$props2.baseGraphApi,
|
|
10211
|
+
getBrandsGraphQuery = _this$props2.getBrandsGraphQuery,
|
|
10212
|
+
getStylesGraphQuery = _this$props2.getStylesGraphQuery,
|
|
10213
|
+
getShoesGraphQuery = _this$props2.getShoesGraphQuery,
|
|
10214
|
+
deleteInterestApi = _this$props2.deleteInterestApi,
|
|
10215
|
+
setSchedule = _this$props2.setSchedule,
|
|
10216
|
+
getSchedule = _this$props2.getSchedule,
|
|
10217
|
+
interestsTitle = _this$props2.interestsTitle,
|
|
10218
|
+
defaultShoeSizeType = _this$props2.defaultShoeSizeType;
|
|
10631
10219
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
10632
10220
|
className: "interests"
|
|
10633
10221
|
}, /*#__PURE__*/React__default.createElement(Notifications__default, {
|
|
@@ -10678,10 +10266,7 @@
|
|
|
10678
10266
|
}))));
|
|
10679
10267
|
}
|
|
10680
10268
|
}]);
|
|
10681
|
-
|
|
10682
|
-
return Interests;
|
|
10683
10269
|
}(React__default.Component);
|
|
10684
|
-
|
|
10685
10270
|
Interests.defaultProps = {
|
|
10686
10271
|
interestsTitle: 'Interests',
|
|
10687
10272
|
defaultShoeSizeType: shoeSizeTypes.eu.value
|
|
@@ -11002,63 +10587,49 @@
|
|
|
11002
10587
|
}, function (props) {
|
|
11003
10588
|
return props.theme.colors.ntrlMin;
|
|
11004
10589
|
});
|
|
10590
|
+
|
|
11005
10591
|
/**
|
|
11006
10592
|
* Multiselector with a GraphQL flavour (TODO: to be revised to make it remote api agnostic)
|
|
11007
10593
|
*/
|
|
11008
|
-
|
|
11009
10594
|
var GraphQLDropdownSelector = /*#__PURE__*/function (_React$Component) {
|
|
11010
|
-
_inherits(GraphQLDropdownSelector, _React$Component);
|
|
11011
|
-
|
|
11012
|
-
var _super = _createSuper(GraphQLDropdownSelector);
|
|
11013
|
-
|
|
11014
10595
|
function GraphQLDropdownSelector(props) {
|
|
11015
10596
|
var _this;
|
|
11016
|
-
|
|
11017
10597
|
_classCallCheck(this, GraphQLDropdownSelector);
|
|
11018
|
-
|
|
11019
|
-
_this
|
|
11020
|
-
|
|
11021
|
-
_defineProperty(_assertThisInitialized(_this), "componentDidUpdate", function (prevProps) {
|
|
10598
|
+
_this = _callSuper(this, GraphQLDropdownSelector, [props]);
|
|
10599
|
+
_defineProperty(_this, "componentDidUpdate", function (prevProps) {
|
|
11022
10600
|
if (prevProps.graphQuery !== _this.props.graphQuery) {
|
|
11023
10601
|
_this.makeRequest();
|
|
11024
10602
|
}
|
|
11025
10603
|
});
|
|
11026
|
-
|
|
11027
|
-
_defineProperty(_assertThisInitialized(_this), "makeRequest", function () {
|
|
10604
|
+
_defineProperty(_this, "makeRequest", function () {
|
|
11028
10605
|
_this.pageReady.refreshPage();
|
|
11029
10606
|
});
|
|
11030
|
-
|
|
11031
|
-
_defineProperty(_assertThisInitialized(_this), "emptySelected", function () {
|
|
10607
|
+
_defineProperty(_this, "emptySelected", function () {
|
|
11032
10608
|
return _this.setState({
|
|
11033
10609
|
selected: [ALL_ITEM$1]
|
|
11034
10610
|
});
|
|
11035
10611
|
});
|
|
11036
|
-
|
|
11037
|
-
_defineProperty(_assertThisInitialized(_this), "setNewResults", function (res) {
|
|
10612
|
+
_defineProperty(_this, "setNewResults", function (res) {
|
|
11038
10613
|
var selectedIds = _this.state.selected.map(function (sel) {
|
|
11039
10614
|
return sel.value;
|
|
11040
10615
|
});
|
|
11041
|
-
|
|
11042
10616
|
var pagination = _this.props.resultProcessor(res);
|
|
11043
|
-
|
|
11044
10617
|
var allSelected = _this.state.selected.some(function (item) {
|
|
11045
10618
|
return item.value === ALL_ITEM$1.value;
|
|
11046
10619
|
});
|
|
11047
|
-
|
|
11048
10620
|
var newList = pagination.filter(function (newItem) {
|
|
11049
10621
|
return !selectedIds.includes(newItem.value);
|
|
11050
10622
|
});
|
|
11051
|
-
newList = allSelected ? newList : [ALL_ITEM$1].concat(_toConsumableArray(newList));
|
|
10623
|
+
newList = allSelected ? newList : [ALL_ITEM$1].concat(_toConsumableArray(newList));
|
|
11052
10624
|
|
|
10625
|
+
// eslint-disable-next-line react/no-unused-state
|
|
11053
10626
|
_this.setState({
|
|
11054
10627
|
list: newList,
|
|
11055
10628
|
pagination: pagination
|
|
11056
10629
|
});
|
|
11057
10630
|
});
|
|
11058
|
-
|
|
11059
|
-
_defineProperty(_assertThisInitialized(_this), "onAddItem", function (addSelectedItem) {
|
|
10631
|
+
_defineProperty(_this, "onAddItem", function (addSelectedItem) {
|
|
11060
10632
|
var newSelectedList;
|
|
11061
|
-
|
|
11062
10633
|
if (addSelectedItem.includes(ALL_ITEM$1)) {
|
|
11063
10634
|
newSelectedList = [ALL_ITEM$1];
|
|
11064
10635
|
} else {
|
|
@@ -11066,7 +10637,6 @@
|
|
|
11066
10637
|
return item.value !== ALL_ITEM$1.value;
|
|
11067
10638
|
});
|
|
11068
10639
|
}
|
|
11069
|
-
|
|
11070
10640
|
_this.setState(function (prevState) {
|
|
11071
10641
|
return _objectSpread2(_objectSpread2({}, prevState), {}, {
|
|
11072
10642
|
selected: newSelectedList
|
|
@@ -11077,19 +10647,17 @@
|
|
|
11077
10647
|
}));
|
|
11078
10648
|
});
|
|
11079
10649
|
});
|
|
11080
|
-
|
|
11081
|
-
_defineProperty(_assertThisInitialized(_this), "onIsLoading", function (flag) {
|
|
10650
|
+
_defineProperty(_this, "onIsLoading", function (flag) {
|
|
11082
10651
|
_this.setState({
|
|
11083
10652
|
isLoading: flag
|
|
11084
10653
|
});
|
|
11085
10654
|
});
|
|
11086
|
-
|
|
11087
|
-
_defineProperty(_assertThisInitialized(_this), "render", function () {
|
|
10655
|
+
_defineProperty(_this, "render", function () {
|
|
11088
10656
|
var _this$props = _this.props,
|
|
11089
|
-
|
|
11090
|
-
|
|
11091
|
-
|
|
11092
|
-
|
|
10657
|
+
baseClass = _this$props.baseClass,
|
|
10658
|
+
identifier = _this$props.identifier,
|
|
10659
|
+
triggerRequest = _this$props.triggerRequest,
|
|
10660
|
+
className = _this$props.className;
|
|
11093
10661
|
var list = _this.state.list;
|
|
11094
10662
|
return /*#__PURE__*/React__default.createElement(StyledMultiselector$1, null, /*#__PURE__*/React__default.createElement("div", {
|
|
11095
10663
|
"data-qe-id": identifier,
|
|
@@ -11114,7 +10682,6 @@
|
|
|
11114
10682
|
isSearchable: true
|
|
11115
10683
|
}))));
|
|
11116
10684
|
});
|
|
11117
|
-
|
|
11118
10685
|
_this.state = {
|
|
11119
10686
|
selected: [ALL_ITEM$1],
|
|
11120
10687
|
list: [],
|
|
@@ -11123,10 +10690,9 @@
|
|
|
11123
10690
|
};
|
|
11124
10691
|
return _this;
|
|
11125
10692
|
}
|
|
11126
|
-
|
|
10693
|
+
_inherits(GraphQLDropdownSelector, _React$Component);
|
|
11127
10694
|
return _createClass(GraphQLDropdownSelector);
|
|
11128
10695
|
}(React__default.Component);
|
|
11129
|
-
|
|
11130
10696
|
GraphQLDropdownSelector.defaultProps = {
|
|
11131
10697
|
baseClass: 'multiselector'
|
|
11132
10698
|
};
|
|
@@ -11136,43 +10702,33 @@
|
|
|
11136
10702
|
* Luxity flavoured GraphQLMultiselector with text Search, category and limit controls
|
|
11137
10703
|
*/
|
|
11138
10704
|
var LuxityGraphQLDropdownSelector = /*#__PURE__*/function (_React$Component) {
|
|
11139
|
-
_inherits(LuxityGraphQLDropdownSelector, _React$Component);
|
|
11140
|
-
|
|
11141
|
-
var _super = _createSuper(LuxityGraphQLDropdownSelector);
|
|
11142
|
-
|
|
11143
10705
|
function LuxityGraphQLDropdownSelector(props) {
|
|
11144
10706
|
var _this;
|
|
11145
|
-
|
|
11146
10707
|
_classCallCheck(this, LuxityGraphQLDropdownSelector);
|
|
11147
|
-
|
|
11148
|
-
_this
|
|
11149
|
-
|
|
11150
|
-
_defineProperty(_assertThisInitialized(_this), "multiSelectorRef", /*#__PURE__*/React__default.createRef());
|
|
11151
|
-
|
|
11152
|
-
_defineProperty(_assertThisInitialized(_this), "increaseLimit", function () {
|
|
10708
|
+
_this = _callSuper(this, LuxityGraphQLDropdownSelector, [props]);
|
|
10709
|
+
_defineProperty(_this, "multiSelectorRef", /*#__PURE__*/React__default.createRef());
|
|
10710
|
+
_defineProperty(_this, "increaseLimit", function () {
|
|
11153
10711
|
_this.setState(function (prevState) {
|
|
11154
10712
|
return {
|
|
11155
10713
|
limit: prevState.limit + _this.props.queryLimitIncrement
|
|
11156
10714
|
};
|
|
11157
10715
|
});
|
|
11158
10716
|
});
|
|
11159
|
-
|
|
11160
|
-
_defineProperty(_assertThisInitialized(_this), "onChange", function (selection) {
|
|
10717
|
+
_defineProperty(_this, "onChange", function (selection) {
|
|
11161
10718
|
_this.props.onChange(selection);
|
|
11162
10719
|
});
|
|
11163
|
-
|
|
11164
|
-
_defineProperty(_assertThisInitialized(_this), "render", function () {
|
|
10720
|
+
_defineProperty(_this, "render", function () {
|
|
11165
10721
|
var _this$state = _this.state,
|
|
11166
|
-
|
|
11167
|
-
|
|
10722
|
+
limit = _this$state.limit,
|
|
10723
|
+
query_arguments = _this$state.query_arguments;
|
|
11168
10724
|
var _this$props = _this.props,
|
|
11169
|
-
|
|
11170
|
-
|
|
11171
|
-
|
|
11172
|
-
|
|
11173
|
-
|
|
11174
|
-
|
|
11175
|
-
|
|
10725
|
+
title = _this$props.title,
|
|
10726
|
+
baseClass = _this$props.baseClass,
|
|
10727
|
+
getGraphQuery = _this$props.getGraphQuery,
|
|
10728
|
+
resultProcessor = _this$props.resultProcessor,
|
|
10729
|
+
graphApi = _this$props.graphApi,
|
|
10730
|
+
identifier = _this$props.identifier,
|
|
10731
|
+
requestInstance = _this$props.requestInstance;
|
|
11176
10732
|
return /*#__PURE__*/React__default.createElement("div", {
|
|
11177
10733
|
className: baseClass
|
|
11178
10734
|
}, /*#__PURE__*/React__default.createElement(InterestsSubheading, {
|
|
@@ -11191,19 +10747,17 @@
|
|
|
11191
10747
|
resultProcessor: resultProcessor
|
|
11192
10748
|
})));
|
|
11193
10749
|
});
|
|
11194
|
-
|
|
11195
10750
|
_this.state = {
|
|
11196
10751
|
limit: props.baseQueryLimit,
|
|
11197
10752
|
query_arguments: props.query_arguments
|
|
11198
10753
|
};
|
|
11199
10754
|
return _this;
|
|
11200
10755
|
}
|
|
11201
|
-
|
|
11202
|
-
_createClass(LuxityGraphQLDropdownSelector, [{
|
|
10756
|
+
_inherits(LuxityGraphQLDropdownSelector, _React$Component);
|
|
10757
|
+
return _createClass(LuxityGraphQLDropdownSelector, [{
|
|
11203
10758
|
key: "componentDidUpdate",
|
|
11204
10759
|
value: function componentDidUpdate(prevProps) {
|
|
11205
10760
|
var _this$multiSelectorRe;
|
|
11206
|
-
|
|
11207
10761
|
if (prevProps.query_arguments !== this.props.query_arguments && (_this$multiSelectorRe = this.multiSelectorRef) !== null && _this$multiSelectorRe !== void 0 && _this$multiSelectorRe.current) {
|
|
11208
10762
|
this.multiSelectorRef.current.emptySelected();
|
|
11209
10763
|
}
|
|
@@ -11216,14 +10770,10 @@
|
|
|
11216
10770
|
query_arguments: props.query_arguments
|
|
11217
10771
|
};
|
|
11218
10772
|
}
|
|
11219
|
-
|
|
11220
10773
|
return null;
|
|
11221
10774
|
}
|
|
11222
10775
|
}]);
|
|
11223
|
-
|
|
11224
|
-
return LuxityGraphQLDropdownSelector;
|
|
11225
10776
|
}(React__default.Component);
|
|
11226
|
-
|
|
11227
10777
|
LuxityGraphQLDropdownSelector.defaultProps = {
|
|
11228
10778
|
baseClass: '',
|
|
11229
10779
|
searchPlaceHolder: '',
|
|
@@ -11233,11 +10783,11 @@
|
|
|
11233
10783
|
|
|
11234
10784
|
var MaterialSelector = function MaterialSelector(_ref) {
|
|
11235
10785
|
var onChange = _ref.onChange,
|
|
11236
|
-
|
|
11237
|
-
|
|
11238
|
-
|
|
11239
|
-
|
|
11240
|
-
|
|
10786
|
+
brands = _ref.brands,
|
|
10787
|
+
graphApi = _ref.graphApi,
|
|
10788
|
+
getGraphQuery = _ref.getGraphQuery,
|
|
10789
|
+
resultProcessor = _ref.resultProcessor,
|
|
10790
|
+
requestInstance = _ref.requestInstance;
|
|
11241
10791
|
return /*#__PURE__*/React__default.createElement(LuxityGraphQLDropdownSelector, {
|
|
11242
10792
|
baseQueryLimit: 1000,
|
|
11243
10793
|
title: "Materials",
|
|
@@ -11252,12 +10802,11 @@
|
|
|
11252
10802
|
requestInstance: requestInstance
|
|
11253
10803
|
});
|
|
11254
10804
|
};
|
|
11255
|
-
|
|
11256
10805
|
MaterialSelector.defaultProps = {
|
|
11257
10806
|
resultProcessor: function resultProcessor(result) {
|
|
11258
10807
|
return result.data.data.luxity_materials.data.map(function (_ref2) {
|
|
11259
10808
|
var id = _ref2.id,
|
|
11260
|
-
|
|
10809
|
+
name = _ref2.name;
|
|
11261
10810
|
return {
|
|
11262
10811
|
label: name,
|
|
11263
10812
|
value: id
|