@licklist/design 0.71.5-dev.9 → 0.71.5

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.
Files changed (174) hide show
  1. package/dist/affiliate/form/AffiliateForm.d.ts.map +1 -1
  2. package/dist/auth/Login/LoginComponent.js +1 -2
  3. package/dist/events/edit-event-modal/component/SaleDeadline/SaleDeadline.d.ts +1 -7
  4. package/dist/events/edit-event-modal/component/SaleDeadline/SaleDeadline.d.ts.map +1 -1
  5. package/dist/events/edit-event-modal/component/SaleDeadline/SaleDeadline.js +7 -10
  6. package/dist/events/edit-event-modal/component/SelectEventProductSet/component/EditEventProductSet.js +1 -4
  7. package/dist/events/edit-event-modal/hooks/useValidationOptions.d.ts +1 -0
  8. package/dist/events/edit-event-modal/hooks/useValidationOptions.d.ts.map +1 -1
  9. package/dist/events/edit-event-modal/hooks/useValidationOptions.js +6 -1
  10. package/dist/events/edit-event-modal/utils/getDefaultProductSet.js +1 -1
  11. package/dist/events/edit-recurrent-event-modal/EditRecurrentEventModal.d.ts.map +1 -1
  12. package/dist/events/edit-recurrent-event-modal/EditRecurrentEventModal.js +0 -1
  13. package/dist/events/event-statistic-modal/EventStatisticModal.d.ts +1 -2
  14. package/dist/events/event-statistic-modal/EventStatisticModal.d.ts.map +1 -1
  15. package/dist/events/event-statistic-modal/EventStatisticModal.js +2 -2
  16. package/dist/events/event-statistic-modal/hooks/useTableData.d.ts +1 -1
  17. package/dist/events/event-statistic-modal/hooks/useTableData.d.ts.map +1 -1
  18. package/dist/events/event-statistic-modal/hooks/useTableData.js +4 -5
  19. package/dist/events/event-statistic-modal/utils/index.d.ts +1 -1
  20. package/dist/events/event-statistic-modal/utils/index.d.ts.map +1 -1
  21. package/dist/events/event-statistic-modal/utils/index.js +13 -35
  22. package/dist/events/event-venue-map/EventVenueMap.d.ts.map +1 -1
  23. package/dist/events/event-venue-map/EventVenueMap.js +0 -1
  24. package/dist/events/event-venue-map/hooks/useCanvasSize.d.ts.map +1 -1
  25. package/dist/events/event-venue-map/hooks/useCanvasSize.js +4 -11
  26. package/dist/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.d.ts.map +1 -1
  27. package/dist/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.js +0 -13
  28. package/dist/iframe/page/components/PageBody/constants.d.ts +0 -1
  29. package/dist/iframe/page/components/PageBody/constants.d.ts.map +1 -1
  30. package/dist/iframe/page/components/PageBody/constants.js +1 -2
  31. package/dist/iframe/page/components/PageBody/hooks/useResizePageBody.d.ts.map +1 -1
  32. package/dist/iframe/page/components/PageBody/hooks/useResizePageBody.js +1 -6
  33. package/dist/iframe/payment/order-items-table/utils/paymentSummary.d.ts.map +1 -1
  34. package/dist/iframe/ryft/RyftPaymentForm.d.ts.map +1 -1
  35. package/dist/iframe/ryft/RyftPaymentForm.js +3 -4
  36. package/dist/iframe/ryft/utils/ryft-form.d.ts.map +1 -1
  37. package/dist/iframe/ryft/utils/ryft-form.js +5 -4
  38. package/dist/layout/DropDown.d.ts +1 -2
  39. package/dist/layout/DropDown.d.ts.map +1 -1
  40. package/dist/notification/email-template/control/EmailTemplateControl.d.ts.map +1 -1
  41. package/dist/notification/email-template/control/EmailTemplateControl.js +0 -3
  42. package/dist/product-set/control/ProductSetControl.d.ts +0 -2
  43. package/dist/product-set/control/ProductSetControl.d.ts.map +1 -1
  44. package/dist/product-set/control/ProductSetControl.js +0 -5
  45. package/dist/product-set/form/ProductCategoriesControl.d.ts.map +1 -1
  46. package/dist/product-set/form/ProductCategoriesControl.js +2 -49
  47. package/dist/product-set/form/ProductSetForm.d.ts +2 -6
  48. package/dist/product-set/form/ProductSetForm.d.ts.map +1 -1
  49. package/dist/product-set/form/ProductSetForm.js +2 -3
  50. package/dist/product-set/form/ProductZonesControl.d.ts.map +1 -1
  51. package/dist/product-set/form/ProductZonesControl.js +2 -0
  52. package/dist/product-set/form/ProductsControl.js +0 -2
  53. package/dist/product-set/form/SelectCategoryModal.d.ts +0 -12
  54. package/dist/product-set/form/SelectCategoryModal.d.ts.map +1 -1
  55. package/dist/product-set/form/SelectCategoryModal.js +1 -1
  56. package/dist/product-set/form/SubProductsControl.d.ts.map +1 -1
  57. package/dist/product-set/form/SubProductsControl.js +3 -0
  58. package/dist/product-set/form/VenueMapsControl.d.ts.map +1 -1
  59. package/dist/product-set/form/VenueMapsControl.js +3 -0
  60. package/dist/product-set/product/ProductControl.d.ts.map +1 -1
  61. package/dist/product-set/product/advanced-options/AdvancedOptions.js +0 -1
  62. package/dist/product-set/product/booking-management/ProductBookingManagementControl.d.ts.map +1 -1
  63. package/dist/product-set/product/booking-management/ProductBookingManagementControl.js +0 -6
  64. package/dist/product-set/product/deposit/ProductDepositControl.d.ts.map +1 -1
  65. package/dist/product-set/product/deposit/ProductDepositControl.js +0 -3
  66. package/dist/product-set/product/duration/ProductDurationControl.d.ts.map +1 -1
  67. package/dist/product-set/product/duration/ProductDurationControl.js +0 -6
  68. package/dist/product-set/product/price/ProductPriceControl.d.ts.map +1 -1
  69. package/dist/product-set/product/price/ProductPriceControl.js +0 -3
  70. package/dist/product-set/product/quantity/ProductQuantityConstantControl.d.ts.map +1 -1
  71. package/dist/product-set/product/quantity/ProductQuantityConstantControl.js +0 -6
  72. package/dist/product-set/product/quantity/ProductQuantityControl.d.ts.map +1 -1
  73. package/dist/product-set/product/quantity/ProductQuantityControl.js +0 -6
  74. package/dist/product-set/product/quantity/ProductQuantityRechargingControl.d.ts.map +1 -1
  75. package/dist/product-set/product/quantity/ProductQuantityRechargingControl.js +1 -4
  76. package/dist/product-set/product-category/ProductCategoryControl.d.ts +0 -1
  77. package/dist/product-set/product-category/ProductCategoryControl.d.ts.map +1 -1
  78. package/dist/product-set/product-category/ProductCategoryControl.js +1 -19
  79. package/dist/recurrence-input/RecurrenceEndInput.d.ts.map +1 -1
  80. package/dist/recurrence-input/RecurrenceEndInput.js +0 -3
  81. package/dist/recurring-date-picker-input/RecurrenceEndInput.d.ts.map +1 -1
  82. package/dist/resource/form/components/CapacityControl.d.ts.map +1 -1
  83. package/dist/resource/form/components/CapacityControl.js +0 -3
  84. package/dist/resource/form/components/SortControl.d.ts.map +1 -1
  85. package/dist/resource/form/components/SortControl.js +0 -3
  86. package/dist/sales/booking/results/components/ResultCard.d.ts.map +1 -1
  87. package/dist/sales/booking/results/components/ResultCard.js +2 -0
  88. package/dist/sales/coupon/control/CouponFormControl.d.ts.map +1 -1
  89. package/dist/sales/coupon/control/CouponFormControl.js +0 -21
  90. package/dist/setting/admin/PaymentFeeForm.d.ts.map +1 -1
  91. package/dist/setting/admin/PaymentFeeForm.js +1 -16
  92. package/dist/setting/dashboard/DashboardSettingForm.d.ts.map +1 -1
  93. package/dist/setting/dashboard/DashboardSettingForm.js +1 -4
  94. package/dist/snippet/snippet-template/preview/Preview.d.ts.map +1 -1
  95. package/dist/snippet/snippet-template/preview/Preview.js +0 -7
  96. package/dist/sortable-tree/SortableTreeItem.d.ts +1 -2
  97. package/dist/sortable-tree/SortableTreeItem.d.ts.map +1 -1
  98. package/dist/sortable-tree/SortableTreeItem.js +4 -10
  99. package/dist/static/CurrencyNumberInput.d.ts.map +1 -1
  100. package/dist/static/CurrencyNumberInput.js +0 -3
  101. package/dist/static/form-number-input/FormNumberInput.d.ts.map +1 -1
  102. package/dist/static/form-number-input/FormNumberInput.js +0 -3
  103. package/dist/static/number-input/NumberInput.d.ts.map +1 -1
  104. package/dist/static/number-input/NumberInput.js +0 -3
  105. package/dist/styles/availability-indicator/AvailabilityIndicator.scss +1 -1
  106. package/dist/styles/iframe-events/Calendar.scss +1 -1
  107. package/dist/styles/iframe-external-modal/IframeExternalModal.scss +2 -2
  108. package/dist/styles/product-set/ProductSetForm.scss +0 -22
  109. package/dist/styles/ryft-payment-form/RyftPaymentForm.scss +3 -1
  110. package/dist/styles/sales/BookingResults.scss +1 -1
  111. package/dist/zone/form/components/GameDurationControl.d.ts.map +1 -1
  112. package/dist/zone/form/components/GameDurationControl.js +0 -3
  113. package/dist/zone/form/components/SortControl.d.ts.map +1 -1
  114. package/dist/zone/form/components/SortControl.js +0 -3
  115. package/package.json +7 -9
  116. package/src/affiliate/form/AffiliateForm.tsx +0 -1
  117. package/src/auth/Login/LoginComponent.tsx +1 -1
  118. package/src/events/edit-event-modal/component/SaleDeadline/SaleDeadline.tsx +16 -42
  119. package/src/events/edit-event-modal/hooks/useValidationOptions.tsx +5 -0
  120. package/src/events/edit-event-modal/utils/getDefaultProductSet.ts +1 -1
  121. package/src/events/edit-recurrent-event-modal/EditRecurrentEventModal.tsx +1 -6
  122. package/src/events/event-statistic-modal/EventStatisticModal.tsx +1 -3
  123. package/src/events/event-statistic-modal/hooks/useTableData.tsx +3 -5
  124. package/src/events/event-statistic-modal/utils/index.ts +32 -69
  125. package/src/events/event-venue-map/EventVenueMap.tsx +0 -1
  126. package/src/events/event-venue-map/hooks/useCanvasSize.ts +1 -5
  127. package/src/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.tsx +0 -9
  128. package/src/iframe/page/components/PageBody/constants.ts +0 -1
  129. package/src/iframe/page/components/PageBody/hooks/useResizePageBody.ts +2 -11
  130. package/src/iframe/payment/order-items-table/utils/paymentSummary.tsx +0 -1
  131. package/src/iframe/ryft/RyftPaymentForm.tsx +8 -10
  132. package/src/iframe/ryft/utils/ryft-form.ts +5 -6
  133. package/src/layout/DropDown.tsx +1 -1
  134. package/src/notification/email-template/control/EmailTemplateControl.tsx +0 -1
  135. package/src/product-set/control/ProductSetControl.tsx +0 -5
  136. package/src/product-set/form/ProductCategoriesControl.tsx +1 -38
  137. package/src/product-set/form/ProductSetForm.tsx +2 -8
  138. package/src/product-set/form/ProductZonesControl.tsx +4 -1
  139. package/src/product-set/form/SelectCategoryModal.tsx +2 -2
  140. package/src/product-set/form/SubProductsControl.tsx +3 -0
  141. package/src/product-set/form/VenueMapsControl.tsx +3 -0
  142. package/src/product-set/product/ProductControl.tsx +1 -0
  143. package/src/product-set/product/advanced-options/AdvancedOptions.tsx +1 -1
  144. package/src/product-set/product/booking-management/ProductBookingManagementControl.tsx +0 -2
  145. package/src/product-set/product/deposit/ProductDepositControl.tsx +0 -1
  146. package/src/product-set/product/duration/ProductDurationControl.tsx +0 -2
  147. package/src/product-set/product/price/ProductPriceControl.tsx +0 -1
  148. package/src/product-set/product/quantity/ProductQuantityConstantControl.tsx +0 -2
  149. package/src/product-set/product/quantity/ProductQuantityControl.tsx +0 -2
  150. package/src/product-set/product/quantity/ProductQuantityRechargingControl.tsx +0 -1
  151. package/src/product-set/product-category/ProductCategoryControl.tsx +0 -17
  152. package/src/product-set/product-zone/ProductZoneControl.tsx +1 -1
  153. package/src/recurrence-input/RecurrenceEndInput.tsx +0 -1
  154. package/src/recurring-date-picker-input/RecurrenceEndInput.tsx +0 -1
  155. package/src/resource/form/components/CapacityControl.tsx +0 -1
  156. package/src/resource/form/components/SortControl.tsx +0 -1
  157. package/src/sales/booking/results/components/ResultCard.tsx +2 -0
  158. package/src/sales/coupon/control/CouponFormControl.tsx +0 -7
  159. package/src/setting/admin/PaymentFeeForm.tsx +0 -5
  160. package/src/setting/dashboard/DashboardSettingForm.tsx +0 -1
  161. package/src/snippet/snippet-template/preview/Preview.tsx +0 -6
  162. package/src/sortable-tree/SortableTreeItem.tsx +0 -6
  163. package/src/static/CurrencyNumberInput.tsx +0 -1
  164. package/src/static/form-number-input/FormNumberInput.tsx +0 -1
  165. package/src/static/number-input/NumberInput.tsx +0 -1
  166. package/src/styles/availability-indicator/AvailabilityIndicator.scss +1 -1
  167. package/src/styles/iframe-events/Calendar.scss +1 -1
  168. package/src/styles/iframe-external-modal/IframeExternalModal.scss +2 -2
  169. package/src/styles/product-set/ProductSetForm.scss +0 -22
  170. package/src/styles/ryft-payment-form/RyftPaymentForm.scss +3 -1
  171. package/src/styles/sales/BookingResults.scss +1 -1
  172. package/src/zone/form/components/GameDurationControl.tsx +0 -1
  173. package/src/zone/form/components/SortControl.tsx +0 -1
  174. package/yarn.lock +339 -394
@@ -1 +1 @@
1
- {"version":3,"file":"AffiliateForm.d.ts","sourceRoot":"","sources":["../../../src/affiliate/form/AffiliateForm.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAE,MAAM,4DAA4D,CAAA;AAEtF,OAAO,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA;AAGpE,MAAM,WAAW,kBAAkB;IACjC,aAAa,CAAC,EAAE,SAAS,GAAG,IAAI,CAAA;IAChC,YAAY,EAAE,CAAC,MAAM,EAAE,mBAAmB,KAAK,IAAI,CAAA;IACnD,YAAY,EAAE,oBAAoB,CAAA;IAClC,SAAS,EAAE,OAAO,CAAA;CACnB;AAED,eAAO,MAAM,aAAa,8DAKvB,kBAAkB,4CA+FpB,CAAA"}
1
+ {"version":3,"file":"AffiliateForm.d.ts","sourceRoot":"","sources":["../../../src/affiliate/form/AffiliateForm.tsx"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAE,MAAM,4DAA4D,CAAA;AAEtF,OAAO,EAAE,mBAAmB,EAAE,oBAAoB,EAAE,MAAM,UAAU,CAAA;AAGpE,MAAM,WAAW,kBAAkB;IACjC,aAAa,CAAC,EAAE,SAAS,GAAG,IAAI,CAAA;IAChC,YAAY,EAAE,CAAC,MAAM,EAAE,mBAAmB,KAAK,IAAI,CAAA;IACnD,YAAY,EAAE,oBAAoB,CAAA;IAClC,SAAS,EAAE,OAAO,CAAA;CACnB;AAED,eAAO,MAAM,aAAa,8DAKvB,kBAAkB,4CA8FpB,CAAA"}
@@ -203,10 +203,9 @@ var LoginComponent = function(param) {
203
203
  var _useState = _sliced_to_array(useState(false), 2), isLoading = _useState[0], setIsLoading = _useState[1];
204
204
  var userApiService = useUserApi(request);
205
205
  var handleError = function(error) {
206
- var _error_response_data, _error_response;
207
206
  notification.danger({
208
207
  title: 'Error',
209
- message: (error === null || error === void 0 ? void 0 : (_error_response = error.response) === null || _error_response === void 0 ? void 0 : (_error_response_data = _error_response.data) === null || _error_response_data === void 0 ? void 0 : _error_response_data.message) || error.message
208
+ message: error.message
210
209
  });
211
210
  };
212
211
  var storeSecrets = function(secrets) {
@@ -1,10 +1,4 @@
1
- export declare const SALE_DEADLINE_NAME_CATEGORY = "saleDeadlineCategory";
2
- export declare const SALE_DEADLINE_NAME = "saleDeadline";
3
- export declare const DEADLINE_NAME: readonly ["saleDeadlineCategory", "saleDeadline"];
4
- export type DeadLineNameType = (typeof DEADLINE_NAME)[number];
5
- export declare const SaleDeadline: ({ disabled, onlyBefore, deadLineCategory, }: {
1
+ export declare const SaleDeadline: ({ disabled }: {
6
2
  disabled?: boolean;
7
- onlyBefore?: boolean;
8
- deadLineCategory?: string;
9
3
  }) => import("react/jsx-runtime").JSX.Element;
10
4
  //# sourceMappingURL=SaleDeadline.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"SaleDeadline.d.ts","sourceRoot":"","sources":["../../../../../src/events/edit-event-modal/component/SaleDeadline/SaleDeadline.tsx"],"names":[],"mappings":"AAWA,eAAO,MAAM,2BAA2B,yBAAyB,CAAA;AACjE,eAAO,MAAM,kBAAkB,iBAAiB,CAAA;AAWhD,eAAO,MAAM,aAAa,mDAGhB,CAAA;AAEV,MAAM,MAAM,gBAAgB,GAAG,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,CAAC,CAAA;AAQ7D,eAAO,MAAM,YAAY,gDAItB;IACD,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB,gBAAgB,CAAC,EAAE,MAAM,CAAA;CAC1B,4CA8JA,CAAA"}
1
+ {"version":3,"file":"SaleDeadline.d.ts","sourceRoot":"","sources":["../../../../../src/events/edit-event-modal/component/SaleDeadline/SaleDeadline.tsx"],"names":[],"mappings":"AAwBA,eAAO,MAAM,YAAY,iBAA0B;IAAE,QAAQ,CAAC,EAAE,OAAO,CAAA;CAAE,4CAwJxE,CAAA"}
@@ -56,8 +56,6 @@ function _unsupported_iterable_to_array(o, minLen) {
56
56
  }
57
57
  var SALE_DEADLINE_BEFORE_TYPE = 'before';
58
58
  var SALE_DEADLINE_AFTER_TYPE = 'after';
59
- var SALE_DEADLINE_NAME_CATEGORY = 'saleDeadlineCategory';
60
- var SALE_DEADLINE_NAME = 'saleDeadline';
61
59
  var SALE_DEADLINES_EVENT_START_TYPES = [
62
60
  {
63
61
  type: SALE_DEADLINE_BEFORE_TYPE
@@ -67,16 +65,15 @@ var SALE_DEADLINES_EVENT_START_TYPES = [
67
65
  }
68
66
  ];
69
67
  var SaleDeadline = function(param) {
70
- var _param_disabled = param.disabled, disabled = _param_disabled === void 0 ? false : _param_disabled, _param_onlyBefore = param.onlyBefore, onlyBefore = _param_onlyBefore === void 0 ? false : _param_onlyBefore, deadLineCategory = param.deadLineCategory;
71
- var _errors_root;
68
+ var _param_disabled = param.disabled, disabled = _param_disabled === void 0 ? false : _param_disabled;
69
+ var _errors_saleDeadline;
72
70
  var t = useTranslation([
73
71
  'Design'
74
72
  ]).t;
75
73
  var _useFormContext = useFormContext(), control = _useFormContext.control, watch = _useFormContext.watch, errors = _useFormContext.formState.errors;
76
74
  var _useState = _sliced_to_array(useState(SALE_DEADLINE_BEFORE_TYPE), 2), deadlineType = _useState[0], setDeadlineType = _useState[1];
77
- var saleDeadline = watch(deadLineCategory || SALE_DEADLINE_NAME);
75
+ var saleDeadline = watch('saleDeadline');
78
76
  useEffect(function() {
79
- if (onlyBefore) return;
80
77
  if (saleDeadline > 0) {
81
78
  setDeadlineType(SALE_DEADLINE_AFTER_TYPE);
82
79
  }
@@ -92,11 +89,11 @@ var SaleDeadline = function(param) {
92
89
  }),
93
90
  /*#__PURE__*/ jsx(Form.Control.Feedback, {
94
91
  type: "invalid",
95
- children: (_errors_root = errors.root) === null || _errors_root === void 0 ? void 0 : _errors_root.message
92
+ children: (_errors_saleDeadline = errors.saleDeadline) === null || _errors_saleDeadline === void 0 ? void 0 : _errors_saleDeadline.message
96
93
  }),
97
94
  /*#__PURE__*/ jsx(Controller, {
98
95
  control: control,
99
- name: deadLineCategory || SALE_DEADLINE_NAME,
96
+ name: "saleDeadline",
100
97
  render: function(param) {
101
98
  var _param_field = param.field, value = _param_field.value, onChange = _param_field.onChange, _param_fieldState = param.fieldState, invalid = _param_fieldState.invalid, error = _param_fieldState.error;
102
99
  var changeValueByType = function(type) {
@@ -127,7 +124,7 @@ var SaleDeadline = function(param) {
127
124
  };
128
125
  return /*#__PURE__*/ jsxs(Fragment, {
129
126
  children: [
130
- !onlyBefore && /*#__PURE__*/ jsx(Form.Group, {
127
+ /*#__PURE__*/ jsx(Form.Group, {
131
128
  className: "d-flex flex-column flex-grow-1 align-items-start",
132
129
  children: /*#__PURE__*/ jsx(Switch, {
133
130
  name: "sale-deadline",
@@ -214,4 +211,4 @@ var SaleDeadline = function(param) {
214
211
  });
215
212
  };
216
213
 
217
- export { SALE_DEADLINE_NAME, SALE_DEADLINE_NAME_CATEGORY, SaleDeadline };
214
+ export { SaleDeadline };
@@ -22,7 +22,7 @@ import 'react-bootstrap/Col';
22
22
  import 'react-bootstrap/InputGroup';
23
23
  import 'react-bootstrap/Row';
24
24
  import '@licklist/plugins/dist/services/Form/FormErrorService';
25
- import '@licklist/plugins/dist/utils/error';
25
+ import '@licklist/plugins';
26
26
  import { ProductSetContextProvider } from '../../../../../product-set/form/context.js';
27
27
  import { getFilteredTemplates } from '../../../../../product-set/utils/index.js';
28
28
  import 'react-bootstrap/Button';
@@ -33,7 +33,6 @@ import '@licklist/core/dist/DataMapper/Product/ProductCategoryDataMapper';
33
33
  import 'react-bootstrap/Collapse';
34
34
  import '@licklist/plugins/dist/hooks/Media/useImages';
35
35
  import '@licklist/core/dist/DataMapper/Media/ImageDataMapper';
36
- import '@licklist/plugins';
37
36
  import '@licklist/plugins/dist/context/app/hooks/useNotification';
38
37
  import '../../../../../static/index.js';
39
38
  import '../../../../../tiptap-editor/TipTapEditor.js';
@@ -64,7 +63,6 @@ import '@tanstack/react-table';
64
63
  import '../../../../../iframe/payment/order-items-table/hooks/useTableData.js';
65
64
  import '@licklist/plugins/dist/context/payment/PaymentSessionContext';
66
65
  import 'react-bootstrap/Alert';
67
- import '@licklist/core/dist/DataMapper/Order/PaymentSessionOrderDataMapper';
68
66
  import '@licklist/plugins/dist/hooks/Ryft/useRyftPayment';
69
67
  import '@licklist/plugins/dist';
70
68
  import '../../../../../iframe/order-process/components/BookingSummary/BookingSummary.js';
@@ -77,7 +75,6 @@ import '../../../../../sortable-tree/SortableTree.js';
77
75
  import '@dnd-kit/core';
78
76
  import '@dnd-kit/sortable';
79
77
  import '@dnd-kit/utilities';
80
- import '@licklist/core/dist/Services/Event/EventService';
81
78
  import 'framer-motion';
82
79
  import '../../../../../product-set/tabs/ProductSetTabs.js';
83
80
  import { getDefaultValues } from '../../../utils/getDefaultProductSet.js';
@@ -1,6 +1,7 @@
1
1
  export declare const useValidationOptions: () => {
2
2
  start: {
3
3
  required: string;
4
+ validate: (value: any) => string | true;
4
5
  };
5
6
  end: {
6
7
  required: string;
@@ -1 +1 @@
1
- {"version":3,"file":"useValidationOptions.d.ts","sourceRoot":"","sources":["../../../../src/events/edit-event-modal/hooks/useValidationOptions.tsx"],"names":[],"mappings":"AAIA,eAAO,MAAM,oBAAoB;;kBASrB,MAAM;;;kBAMN,MAAM;;;CAWjB,CAAA"}
1
+ {"version":3,"file":"useValidationOptions.d.ts","sourceRoot":"","sources":["../../../../src/events/edit-event-modal/hooks/useValidationOptions.tsx"],"names":[],"mappings":"AAIA,eAAO,MAAM,oBAAoB;;kBASrB,MAAM;;;;kBAWN,MAAM;;;CAWjB,CAAA"}
@@ -16,7 +16,12 @@ var useValidationOptions = function() {
16
16
  start: {
17
17
  required: t('Validation:fieldRequired', {
18
18
  attribute: t('start')
19
- })
19
+ }),
20
+ // TODO: uncomment when event splitting is implemented
21
+ // and extract into plugins
22
+ validate: function(value) {
23
+ return DateTime.fromISO(value).diffNow().toMillis() > 0 || t('Validation:fieldValidEventStart');
24
+ }
20
25
  },
21
26
  end: {
22
27
  required: t('Validation:fieldRequired', {
@@ -112,7 +112,6 @@ var getDefaultValues = function(productSet, hasNoRecurrences) {
112
112
  relyOnPeopleType: (_productSet_relyOnPeopleType = productSet === null || productSet === void 0 ? void 0 : productSet.relyOnPeopleType) !== null && _productSet_relyOnPeopleType !== void 0 ? _productSet_relyOnPeopleType : null,
113
113
  thankYouPageUrl: (_productSet_thankYouPageUrl = productSet === null || productSet === void 0 ? void 0 : productSet.thankYouPageUrl) !== null && _productSet_thankYouPageUrl !== void 0 ? _productSet_thankYouPageUrl : '',
114
114
  fieldSetId: productSet === null || productSet === void 0 ? void 0 : productSet.fieldSetId,
115
- saleDeadline: productSet === null || productSet === void 0 ? void 0 : productSet.saleDeadline,
116
115
  emailTemplates: (productSet === null || productSet === void 0 ? void 0 : productSet.mailTemplates) && (productSet === null || productSet === void 0 ? void 0 : (_productSet_mailTemplates = productSet.mailTemplates) === null || _productSet_mailTemplates === void 0 ? void 0 : _productSet_mailTemplates.length) > 0 ? getFilteredTemplates(productSet === null || productSet === void 0 ? void 0 : productSet.mailTemplates) : undefined,
117
116
  smsTemplates: (productSet === null || productSet === void 0 ? void 0 : productSet.smsTemplates) && (productSet === null || productSet === void 0 ? void 0 : (_productSet_smsTemplates = productSet.smsTemplates) === null || _productSet_smsTemplates === void 0 ? void 0 : _productSet_smsTemplates.length) > 0 ? getFilteredTemplates(productSet === null || productSet === void 0 ? void 0 : productSet.smsTemplates) : undefined,
118
117
  steps: (_productSet_steps_map = productSet === null || productSet === void 0 ? void 0 : (_productSet_steps = productSet.steps) === null || _productSet_steps === void 0 ? void 0 : _productSet_steps.map(function(_param) {
@@ -136,6 +135,7 @@ var getDefaultValues = function(productSet, hasNoRecurrences) {
136
135
  subProducts: subProducts === null || subProducts === void 0 ? void 0 : subProducts.map(function(_param) {
137
136
  var subProducts = _extends({}, _object_destructuring_empty(_param));
138
137
  return _object_spread_props(_object_spread({}, subProducts), {
138
+ originalProductId: null,
139
139
  productCategoryId: undefined
140
140
  });
141
141
  }),
@@ -1 +1 @@
1
- {"version":3,"file":"EditRecurrentEventModal.d.ts","sourceRoot":"","sources":["../../../src/events/edit-recurrent-event-modal/EditRecurrentEventModal.tsx"],"names":[],"mappings":"AAKA,eAAO,MAAM,eAAe,cAAc,CAAA;AAC1C,eAAO,MAAM,8BAA8B,2BAA2B,CAAA;AACtE,eAAO,MAAM,eAAe,cAAc,CAAA;AAE1C,QAAA,MAAM,KAAK,+DAID,CAAA;AAEV,eAAO,MAAM,2BAA2B,cAAkB,CAAA;AAE1D,eAAO,MAAM,yBAAyB;;;;CAIrC,CAAA;AAED,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,KAAK,CAAC,CAAC,MAAM,CAAC,CAAA;AAEvD,MAAM,MAAM,6BAA6B,GAAG;IAC1C,IAAI,EAAE,kBAAkB,CAAA;CACzB,CAAA;AAED,MAAM,MAAM,4BAA4B,GAAG;IACzC,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,MAAM,EAAE,OAAO,CAAA;IACf,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,CAAC,MAAM,EAAE,6BAA6B,KAAK,IAAI,CAAA;CAC1D,CAAA;AAED,eAAO,MAAM,uBAAuB,mDAMjC,4BAA4B,4CAgF9B,CAAA"}
1
+ {"version":3,"file":"EditRecurrentEventModal.d.ts","sourceRoot":"","sources":["../../../src/events/edit-recurrent-event-modal/EditRecurrentEventModal.tsx"],"names":[],"mappings":"AAKA,eAAO,MAAM,eAAe,cAAc,CAAA;AAC1C,eAAO,MAAM,8BAA8B,2BAA2B,CAAA;AACtE,eAAO,MAAM,eAAe,cAAc,CAAA;AAE1C,QAAA,MAAM,KAAK,+DAID,CAAA;AAEV,eAAO,MAAM,2BAA2B,cAAkB,CAAA;AAE1D,eAAO,MAAM,yBAAyB;;;;CAIrC,CAAA;AAED,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,KAAK,CAAC,CAAC,MAAM,CAAC,CAAA;AAEvD,MAAM,MAAM,6BAA6B,GAAG;IAC1C,IAAI,EAAE,kBAAkB,CAAA;CACzB,CAAA;AAED,MAAM,MAAM,4BAA4B,GAAG;IACzC,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,MAAM,EAAE,OAAO,CAAA;IACf,MAAM,EAAE,MAAM,IAAI,CAAA;IAClB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,CAAC,MAAM,EAAE,6BAA6B,KAAK,IAAI,CAAA;CAC1D,CAAA;AAED,eAAO,MAAM,uBAAuB,mDAMjC,4BAA4B,4CA2E9B,CAAA"}
@@ -51,7 +51,6 @@ var EditRecurrentEventModal = function(param) {
51
51
  /*#__PURE__*/ jsx(Button, {
52
52
  variant: "danger",
53
53
  className: "btn-sm rounded",
54
- disabled: disabled,
55
54
  onClick: onHide,
56
55
  children: /*#__PURE__*/ jsx(FaTimes, {
57
56
  size: 16
@@ -6,7 +6,6 @@ export type EventStatisticModalProps = {
6
6
  date?: Event['startAt'] | null;
7
7
  eventStatistic?: EventStatistic | null;
8
8
  title?: string;
9
- eventId?: string;
10
9
  };
11
- export declare const EventStatisticModal: ({ isOpen, setIsOpen, date, eventStatistic, title, eventId, }: EventStatisticModalProps) => import("react/jsx-runtime").JSX.Element;
10
+ export declare const EventStatisticModal: ({ isOpen, setIsOpen, date, eventStatistic, title, }: EventStatisticModalProps) => import("react/jsx-runtime").JSX.Element;
12
11
  //# sourceMappingURL=EventStatisticModal.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"EventStatisticModal.d.ts","sourceRoot":"","sources":["../../../src/events/event-statistic-modal/EventStatisticModal.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,kEAAkE,CAAA;AACjG,OAAO,EAAE,KAAK,EAAE,MAAM,yDAAyD,CAAA;AAK/E,MAAM,MAAM,wBAAwB,GAAG;IACrC,MAAM,EAAE,OAAO,CAAA;IACf,SAAS,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;IACnC,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,GAAG,IAAI,CAAA;IAC9B,cAAc,CAAC,EAAE,cAAc,GAAG,IAAI,CAAA;IACtC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,OAAO,CAAC,EAAE,MAAM,CAAA;CACjB,CAAA;AAED,eAAO,MAAM,mBAAmB,iEAO7B,wBAAwB,4CAiD1B,CAAA"}
1
+ {"version":3,"file":"EventStatisticModal.d.ts","sourceRoot":"","sources":["../../../src/events/event-statistic-modal/EventStatisticModal.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,cAAc,EAAE,MAAM,kEAAkE,CAAA;AACjG,OAAO,EAAE,KAAK,EAAE,MAAM,yDAAyD,CAAA;AAK/E,MAAM,MAAM,wBAAwB,GAAG;IACrC,MAAM,EAAE,OAAO,CAAA;IACf,SAAS,EAAE,CAAC,KAAK,EAAE,OAAO,KAAK,IAAI,CAAA;IACnC,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC,GAAG,IAAI,CAAA;IAC9B,cAAc,CAAC,EAAE,cAAc,GAAG,IAAI,CAAA;IACtC,KAAK,CAAC,EAAE,MAAM,CAAA;CACf,CAAA;AAED,eAAO,MAAM,mBAAmB,wDAM7B,wBAAwB,4CAiD1B,CAAA"}
@@ -18,9 +18,9 @@ import '@tanstack/react-table';
18
18
  import { useTableData } from './hooks/useTableData.js';
19
19
 
20
20
  var EventStatisticModal = function(param) {
21
- var isOpen = param.isOpen, setIsOpen = param.setIsOpen, date = param.date, eventStatistic = param.eventStatistic, title = param.title, eventId = param.eventId;
21
+ var isOpen = param.isOpen, setIsOpen = param.setIsOpen, date = param.date, eventStatistic = param.eventStatistic, title = param.title;
22
22
  var t = useTranslation('Design').t;
23
- var data = useTableData(date, eventStatistic, eventId);
23
+ var data = useTableData(date, eventStatistic);
24
24
  var handleClose = function() {
25
25
  setIsOpen(false);
26
26
  };
@@ -1,5 +1,5 @@
1
1
  import { EventStatistic } from '@licklist/core/dist/DataMapper/Provider/EventStatisticDataMapper';
2
2
  import { Event } from '@licklist/core/dist/DataMapper/Provider/EventDataMapper';
3
3
  import { StaticTableData } from '../../../table';
4
- export declare const useTableData: (date: Event["startAt"] | null, eventStatistic: EventStatistic | null, eventId: string) => StaticTableData[];
4
+ export declare const useTableData: (date: Event["startAt"] | null, eventStatistic: EventStatistic | null) => StaticTableData[];
5
5
  //# sourceMappingURL=useTableData.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"useTableData.d.ts","sourceRoot":"","sources":["../../../../src/events/event-statistic-modal/hooks/useTableData.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,cAAc,EAAE,MAAM,kEAAkE,CAAA;AACjG,OAAO,EAAE,KAAK,EAAE,MAAM,yDAAyD,CAAA;AAE/E,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAA;AAEhD,eAAO,MAAM,YAAY,SACjB,KAAK,CAAC,SAAS,CAAC,GAAG,IAAI,kBACb,cAAc,GAAG,IAAI,WAC5B,MAAM,sBA8EhB,CAAA"}
1
+ {"version":3,"file":"useTableData.d.ts","sourceRoot":"","sources":["../../../../src/events/event-statistic-modal/hooks/useTableData.tsx"],"names":[],"mappings":"AAKA,OAAO,EAAE,cAAc,EAAE,MAAM,kEAAkE,CAAA;AACjG,OAAO,EAAE,KAAK,EAAE,MAAM,yDAAyD,CAAA;AAE/E,OAAO,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAA;AAEhD,eAAO,MAAM,YAAY,SACjB,KAAK,CAAC,SAAS,CAAC,GAAG,IAAI,kBACb,cAAc,GAAG,IAAI,sBA6EtC,CAAA"}
@@ -52,7 +52,7 @@ function _unsupported_iterable_to_array(o, minLen) {
52
52
  if (n === "Map" || n === "Set") return Array.from(n);
53
53
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
54
54
  }
55
- var useTableData = function(date, eventStatistic, eventId) {
55
+ var useTableData = function(date, eventStatistic) {
56
56
  var t = useTranslation('Design').t;
57
57
  var formatNumber = useIntl().formatNumber;
58
58
  var _useState = _sliced_to_array(useState([]), 2), tableRows = _useState[0], setTableRows = _useState[1];
@@ -70,12 +70,12 @@ var useTableData = function(date, eventStatistic, eventId) {
70
70
  }
71
71
  return t(key);
72
72
  };
73
- var transformStatisticToTableRows = function(date, statistic, eventId) {
73
+ var transformStatisticToTableRows = function(date, statistic) {
74
74
  if (!statistic) {
75
75
  return [];
76
76
  }
77
77
  var tableDataRows = [];
78
- convertEventStatisticToTableData(date, statistic, eventId).forEach(function(param) {
78
+ convertEventStatisticToTableData(date, statistic).forEach(function(param) {
79
79
  var name = param.name, quantity = param.quantity, total = param.total, isBold = param.isBold, isHeader = param.isHeader, key = param.key;
80
80
  var formattedTotal = !Object.keys(TRANSLATION_KEYS).includes(String(total)) ? formatNumber(Number(total), {
81
81
  style: 'currency',
@@ -102,11 +102,10 @@ var useTableData = function(date, eventStatistic, eventId) {
102
102
  return tableDataRows;
103
103
  };
104
104
  useEffect(function() {
105
- setTableRows(transformStatisticToTableRows(date, eventStatistic, eventId));
105
+ setTableRows(transformStatisticToTableRows(date, eventStatistic));
106
106
  // eslint-disable-next-line react-hooks/exhaustive-deps
107
107
  }, [
108
108
  date,
109
- eventId,
110
109
  eventStatistic
111
110
  ]);
112
111
  return tableRows;
@@ -16,6 +16,6 @@ type TableDataRecord = {
16
16
  _total: number;
17
17
  };
18
18
  };
19
- export declare const convertEventStatisticToTableData: (date: string, eventStatistic: EventStatistic, eventId: string) => TableDataRecord[];
19
+ export declare const convertEventStatisticToTableData: (date: string, eventStatistic: EventStatistic) => TableDataRecord[];
20
20
  export {};
21
21
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/events/event-statistic-modal/utils/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,kEAAkE,CAAA;AAKjG,eAAO,MAAM,gBAAgB;;;;CAI5B,CAAA;AAED,KAAK,eAAe,GAAG;IACrB,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,MAAM,CAAA;IACX,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,QAAQ,EAAE,MAAM,CAAA;IAChB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE;QACT,aAAa,EAAE,MAAM,CAAA;QACrB,MAAM,EAAE,MAAM,CAAA;KACf,CAAA;CACF,CAAA;AAED,eAAO,MAAM,gCAAgC,SACrC,MAAM,kBACI,cAAc,WACrB,MAAM,sBA+IhB,CAAA"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/events/event-statistic-modal/utils/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,EAAE,MAAM,kEAAkE,CAAA;AAIjG,eAAO,MAAM,gBAAgB;;;;CAI5B,CAAA;AAED,KAAK,eAAe,GAAG;IACrB,IAAI,EAAE,MAAM,CAAA;IACZ,GAAG,EAAE,MAAM,CAAA;IACX,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,MAAM,CAAC,EAAE,OAAO,CAAA;IAChB,QAAQ,EAAE,MAAM,CAAA;IAChB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,CAAC,EAAE;QACT,aAAa,EAAE,MAAM,CAAA;QACrB,MAAM,EAAE,MAAM,CAAA;KACf,CAAA;CACF,CAAA;AAED,eAAO,MAAM,gCAAgC,SACrC,MAAM,kBACI,cAAc,sBA4G/B,CAAA"}
@@ -1,6 +1,5 @@
1
1
  import { DateTime } from 'luxon';
2
2
  import { DATE_FORMAT, DATE_TIME_FULL_FORMAT } from '@licklist/core/dist/Config';
3
- import { max } from 'lodash';
4
3
 
5
4
  function _array_like_to_array(arr, len) {
6
5
  if (len == null || len > arr.length) len = arr.length;
@@ -32,7 +31,7 @@ var TRANSLATION_KEYS = {
32
31
  total: 'total',
33
32
  totalPerCategory: 'totalPerCategory'
34
33
  };
35
- var convertEventStatisticToTableData = function(date, eventStatistic, eventId) {
34
+ var convertEventStatisticToTableData = function(date, eventStatistic) {
36
35
  var _Object_keys;
37
36
  var totalAmount = 0;
38
37
  var totalQuantity = 0;
@@ -49,18 +48,10 @@ var convertEventStatisticToTableData = function(date, eventStatistic, eventId) {
49
48
  return eventStatistic === null || eventStatistic === void 0 ? void 0 : eventStatistic.productCategorySummary[day];
50
49
  }).flat().sort(function(prev, next) {
51
50
  return prev.categoryName === next.categoryName ? 0 : prev.categoryName > next.categoryName ? 1 : -1;
52
- })// use statistic only for event or for override this event
53
- .filter(function(item) {
54
- return item.eventId === Number(eventId) || (item === null || item === void 0 ? void 0 : item.originalEventId) === Number(eventId);
55
- }).forEach(function(param, _, selfCategory) {
51
+ }).forEach(function(param) {
56
52
  var totalPerCategory = param.totalPerCategory, _param_productsSummary = param.productsSummary, productsSummary = _param_productsSummary === void 0 ? [] : _param_productsSummary, categoryName = param.categoryName, eventId = param.eventId;
57
53
  var quantity = 0;
58
54
  totalAmount += totalPerCategory || 0;
59
- var allProductSummaryAtCategory = selfCategory.filter(function(category) {
60
- return category.categoryName === categoryName;
61
- }).flatMap(function(categorySummary) {
62
- return categorySummary.productsSummary;
63
- });
64
55
  if (!summaryMap.has("".concat(categoryName))) {
65
56
  summaryMap.set("".concat(categoryName), {
66
57
  name: categoryName,
@@ -71,37 +62,24 @@ var convertEventStatisticToTableData = function(date, eventStatistic, eventId) {
71
62
  total: TRANSLATION_KEYS.total
72
63
  });
73
64
  }
74
- productsSummary === null || productsSummary === void 0 ? void 0 : productsSummary.forEach(function(productSummary, productIndex) {
75
- quantity += productSummary.productsSold;
65
+ productsSummary === null || productsSummary === void 0 ? void 0 : productsSummary.forEach(function(param) {
66
+ var productsSold = param.productsSold, name = param.name, totalQuantity = param.totalQuantity, total = param.total;
67
+ quantity += productsSold;
76
68
  var _summaryMap_get;
77
- var existingProduct = (_summaryMap_get = summaryMap.get("".concat(categoryName, ".").concat(productSummary.name))) !== null && _summaryMap_get !== void 0 ? _summaryMap_get : {
69
+ var existingProduct = (_summaryMap_get = summaryMap.get("".concat(categoryName, ".").concat(name))) !== null && _summaryMap_get !== void 0 ? _summaryMap_get : {
78
70
  metadata: {
79
71
  _productsSold: 0,
80
72
  _total: 0
81
73
  }
82
74
  };
83
- var overrides = allProductSummaryAtCategory.filter(function(summary) {
84
- return summary.originalProductId === productSummary.id;
85
- });
86
- var highestOverrideTotalQuantity = overrides.reduce(function(acc, override) {
87
- if (!override.totalQuantity) return acc;
88
- if (override.totalQuantity > (acc || 0)) {
89
- return override.totalQuantity;
90
- }
91
- return acc;
92
- }, null);
93
- var totalQuantity = (productSummary.totalQuantity || highestOverrideTotalQuantity) && max([
94
- productSummary.totalQuantity,
95
- highestOverrideTotalQuantity
96
- ]);
97
- summaryMap.set("".concat(categoryName, ".").concat(productSummary.name), {
98
- name: productSummary.name,
99
- key: "".concat(eventId, ".").concat(categoryName).concat(productIndex).concat(productSummary.name),
100
- quantity: totalQuantity ? "".concat(existingProduct.metadata._productsSold + productSummary.productsSold, " / ").concat(totalQuantity) : String(existingProduct.metadata._productsSold + productSummary.productsSold),
101
- total: String(existingProduct.metadata._total + productSummary.total),
75
+ summaryMap.set("".concat(categoryName, ".").concat(name), {
76
+ name: name,
77
+ key: "".concat(eventId, ".").concat(categoryName, ".").concat(name),
78
+ quantity: totalQuantity ? "".concat(existingProduct.metadata._productsSold + productsSold, " / ").concat(totalQuantity) : String(existingProduct.metadata._productsSold + productsSold),
79
+ total: String(existingProduct.metadata._total + total),
102
80
  metadata: {
103
- _productsSold: existingProduct.metadata._productsSold + productSummary.productsSold,
104
- _total: existingProduct.metadata._total + productSummary.total
81
+ _productsSold: existingProduct.metadata._productsSold + productsSold,
82
+ _total: existingProduct.metadata._total + total
105
83
  }
106
84
  });
107
85
  });
@@ -1 +1 @@
1
- {"version":3,"file":"EventVenueMap.d.ts","sourceRoot":"","sources":["../../../src/events/event-venue-map/EventVenueMap.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAE,MAAM,kDAAkD,CAAA;AACxE,OAAO,EAAE,YAAY,EAAE,MAAM,+DAA+D,CAAA;AAC5F,OAAO,EAAE,OAAO,EAAE,MAAM,0DAA0D,CAAA;AAClF,OAAO,EAAE,wBAAwB,EAAE,MAAM,8CAA8C,CAAA;AACvF,OAAO,EAAY,WAAW,EAAE,MAAM,uBAAuB,CAAA;AAG7D,MAAM,MAAM,wBAAwB,GAAG;IACrC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,YAAY,CAAC,EAAE,CAAC,OAAO,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;IACzC,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,mBAAmB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC9B,0BAA0B,CAAC,EAAE,MAAM,EAAE,CAAA;CACtC,CAAA;AAED,MAAM,MAAM,kBAAkB,GAAG;IAC/B,GAAG,EAAE,MAAM,CAAA;IACX,MAAM,CAAC,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,CAAA;IACzB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,KAAK,IAAI,CAAA;IAClD,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,EAAE,CAAA;IAC7B,aAAa,CAAC,EAAE,OAAO,CAAC,YAAY,CAAC,EAAE,CAAA;IACvC,qBAAqB,CAAC,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,CAAC,EAAE,KAAK,IAAI,CAAA;IACjE,eAAe,CAAC,EAAE,wBAAwB,EAAE,CAAA;CAC7C,GAAG,wBAAwB,CAAA;AAE5B,eAAO,MAAM,aAAa;SAXnB,MAAM;aACF,OAAO,CAAC,KAAK,CAAC,EAAE;WAClB,MAAM;qBACI,CAAC,KAAK,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,KAAK,IAAI;eACvC,OAAO;eACP,OAAO,CAAC,OAAO,CAAC,EAAE;oBACb,OAAO,CAAC,YAAY,CAAC,EAAE;4BACf,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,CAAC,EAAE,KAAK,IAAI;sBAC/C,wBAAwB,EAAE;0EAkD7C,CAAA"}
1
+ {"version":3,"file":"EventVenueMap.d.ts","sourceRoot":"","sources":["../../../src/events/event-venue-map/EventVenueMap.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,EAAE,MAAM,kDAAkD,CAAA;AACxE,OAAO,EAAE,YAAY,EAAE,MAAM,+DAA+D,CAAA;AAC5F,OAAO,EAAE,OAAO,EAAE,MAAM,0DAA0D,CAAA;AAClF,OAAO,EAAE,wBAAwB,EAAE,MAAM,8CAA8C,CAAA;AACvF,OAAO,EAAY,WAAW,EAAE,MAAM,uBAAuB,CAAA;AAG7D,MAAM,MAAM,wBAAwB,GAAG;IACrC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,YAAY,CAAC,EAAE,CAAC,OAAO,CAAC,EAAE,MAAM,KAAK,IAAI,CAAA;IACzC,YAAY,CAAC,EAAE,OAAO,CAAA;IACtB,mBAAmB,CAAC,EAAE,MAAM,EAAE,CAAA;IAC9B,0BAA0B,CAAC,EAAE,MAAM,EAAE,CAAA;CACtC,CAAA;AAED,MAAM,MAAM,kBAAkB,GAAG;IAC/B,GAAG,EAAE,MAAM,CAAA;IACX,MAAM,CAAC,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,CAAA;IACzB,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,cAAc,CAAC,EAAE,CAAC,KAAK,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,KAAK,IAAI,CAAA;IAClD,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,QAAQ,CAAC,EAAE,OAAO,CAAC,OAAO,CAAC,EAAE,CAAA;IAC7B,aAAa,CAAC,EAAE,OAAO,CAAC,YAAY,CAAC,EAAE,CAAA;IACvC,qBAAqB,CAAC,EAAE,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,CAAC,EAAE,KAAK,IAAI,CAAA;IACjE,eAAe,CAAC,EAAE,wBAAwB,EAAE,CAAA;CAC7C,GAAG,wBAAwB,CAAA;AAE5B,eAAO,MAAM,aAAa;SAXnB,MAAM;aACF,OAAO,CAAC,KAAK,CAAC,EAAE;WAClB,MAAM;qBACI,CAAC,KAAK,EAAE,OAAO,CAAC,KAAK,CAAC,EAAE,KAAK,IAAI;eACvC,OAAO;eACP,OAAO,CAAC,OAAO,CAAC,EAAE;oBACb,OAAO,CAAC,YAAY,CAAC,EAAE;4BACf,CAAC,MAAM,EAAE,OAAO,CAAC,YAAY,CAAC,EAAE,KAAK,IAAI;sBAC/C,wBAAwB,EAAE;0EAiD7C,CAAA"}
@@ -58,7 +58,6 @@ function _object_spread_props(target, source) {
58
58
  }
59
59
  var EventVenueMap = /*#__PURE__*/ forwardRef(function(param, ref) {
60
60
  var url = param.url, points = param.points, _param_editMode = param.editMode, editMode = _param_editMode === void 0 ? false : _param_editMode, name = param.name, onPointsChange = param.onPointsChange, products = param.products, pointProducts = param.pointProducts, onPointProductsChange = param.onPointProductsChange, width = param.width, height = param.height, onPointClick = param.onPointClick, _param_usedInIframe = param.usedInIframe, usedInIframe = _param_usedInIframe === void 0 ? false : _param_usedInIframe, _param_choosedProductUuids = param.choosedProductUuids, choosedProductUuids = _param_choosedProductUuids === void 0 ? [] : _param_choosedProductUuids, _param_errorOnChoosedProductUuids = param.errorOnChoosedProductUuids, errorOnChoosedProductUuids = _param_errorOnChoosedProductUuids === void 0 ? [] : _param_errorOnChoosedProductUuids, soldOutProducts = param.soldOutProducts;
61
- // TODO fix often updating of canvasSizes, which leads to flashing poingts
62
61
  var canvasSizes = useCanvasSize({
63
62
  width: width,
64
63
  height: height
@@ -1 +1 @@
1
- {"version":3,"file":"useCanvasSize.d.ts","sourceRoot":"","sources":["../../../../src/events/event-venue-map/hooks/useCanvasSize.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,eAAe,GAAG;IAC5B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB,CAAA;AAED,eAAO,MAAM,aAAa,wDAGvB,eAAe;;;CAcjB,CAAA"}
1
+ {"version":3,"file":"useCanvasSize.d.ts","sourceRoot":"","sources":["../../../../src/events/event-venue-map/hooks/useCanvasSize.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,eAAe,GAAG;IAC5B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,MAAM,CAAC,EAAE,MAAM,CAAA;CAChB,CAAA;AAED,eAAO,MAAM,aAAa,wDAGvB,eAAe;;;CAUjB,CAAA"}
@@ -3,17 +3,7 @@ import { useWindowDimensions } from '@licklist/plugins/dist/hooks/Media/useWindo
3
3
 
4
4
  var useCanvasSize = function(param) {
5
5
  var componentWidth = param.width, componentHeight = param.height;
6
- // TODO Fix often updating of width and height
7
6
  var _useWindowDimensions = useWindowDimensions(), width = _useWindowDimensions.width, height = _useWindowDimensions.height;
8
- // eslint-disable-next-line react-hooks/exhaustive-deps
9
- var memoizedDimensions = useMemo(function() {
10
- return {
11
- width: width,
12
- height: height
13
- };
14
- }, [
15
- width
16
- ]);
17
7
  var memoedComponentParameters = useMemo(function() {
18
8
  if (!componentWidth && !componentHeight) return null;
19
9
  return {
@@ -24,7 +14,10 @@ var useCanvasSize = function(param) {
24
14
  componentWidth,
25
15
  componentHeight
26
16
  ]);
27
- return memoedComponentParameters || memoizedDimensions;
17
+ return memoedComponentParameters || {
18
+ width: width,
19
+ height: height
20
+ };
28
21
  };
29
22
 
30
23
  export { useCanvasSize };
@@ -1 +1 @@
1
- {"version":3,"file":"NumberInput.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.tsx"],"names":[],"mappings":"AAIA,UAAU,gBAAgB;IACxB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACjC,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACnC,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACrC,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAED,eAAO,MAAM,WAAW,+GAyGvB,CAAA"}
1
+ {"version":3,"file":"NumberInput.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.tsx"],"names":[],"mappings":"AAIA,UAAU,gBAAgB;IACxB,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB,KAAK,EAAE,MAAM,CAAA;IACb,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACjC,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACnC,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACrC,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAED,eAAO,MAAM,WAAW,+GAgGvB,CAAA"}
@@ -54,9 +54,6 @@ var NumberInput = /*#__PURE__*/ forwardRef(function(param, ref) {
54
54
  onChange: function(e) {
55
55
  return handleChangeValue(Number(e.target.value));
56
56
  },
57
- onWheel: function(event) {
58
- return event.currentTarget.blur();
59
- },
60
57
  value: value,
61
58
  min: 0,
62
59
  max: max,
@@ -69,16 +66,6 @@ var NumberInput = /*#__PURE__*/ forwardRef(function(param, ref) {
69
66
  /*#__PURE__*/ jsx("button", {
70
67
  type: "button",
71
68
  onClick: handleArrowUpClick,
72
- onWheel: function(event) {
73
- return event.currentTarget.blur();
74
- },
75
- onFocus: function(event) {
76
- return event.target.addEventListener('wheel', function(event) {
77
- return event.preventDefault();
78
- }, {
79
- passive: false
80
- });
81
- },
82
69
  className: "payment-number-input__btn-up ".concat(plusButtonGreyedOut && 'disabled-number-input-button'),
83
70
  disabled: disabled,
84
71
  children: "+"
@@ -1,5 +1,4 @@
1
1
  export declare const TAB_WIDTH = 768;
2
- export declare const MOBILE_WIDTH = 480;
3
2
  export declare const RIGHT_BLOCK_RESIZED_EVENT = "RIGHT_BLOCK_RESIZED_EVENT";
4
3
  export declare const STANDARD_BODY_PADDING: number;
5
4
  export declare const STANDARD_HEADER_FOOTER_SIZE = 96;
@@ -1 +1 @@
1
- {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/iframe/page/components/PageBody/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,MAAM,CAAA;AAC5B,eAAO,MAAM,YAAY,MAAM,CAAA;AAC/B,eAAO,MAAM,yBAAyB,8BAA8B,CAAA;AAEpE,eAAO,MAAM,qBAAqB,QAAU,CAAA;AAE5C,eAAO,MAAM,2BAA2B,KAAK,CAAA;AAG7C,eAAO,MAAM,0BAA0B,MAAM,CAAA;AAI7C,eAAO,MAAM,0CAA0C,KAAK,CAAA;AAE5D,eAAO,MAAM,kBAAkB,+BAA+B,CAAA;AAC9D,eAAO,MAAM,oBAAoB,yBAAyB,CAAA;AAC1D,eAAO,MAAM,oBAAoB,iCAAiC,CAAA;AAClE,eAAO,MAAM,qBAAqB,0BAA0B,CAAA;AAE5D,eAAO,MAAM,mBAAmB,qBAAqB,CAAA;AACrD,eAAO,MAAM,4BAA4B,oCAAoC,CAAA;AAC7E,eAAO,MAAM,0BAA0B,kCAAkC,CAAA;AACzE,eAAO,MAAM,uBAAuB,IAAI,CAAA;AACxC,eAAO,MAAM,eAAe,KAAK,CAAA;AAEjC,eAAO,MAAM,4BAA4B,8BAA8B,CAAA;AACvE,eAAO,MAAM,4BAA4B,4BAA4B,CAAA;AACrE,eAAO,MAAM,qBAAqB,0BAA0B,CAAA;AAE5D,eAAO,MAAM,gCAAgC,MAAM,CAAA"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/iframe/page/components/PageBody/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,MAAM,CAAA;AAC5B,eAAO,MAAM,yBAAyB,8BAA8B,CAAA;AAEpE,eAAO,MAAM,qBAAqB,QAAU,CAAA;AAE5C,eAAO,MAAM,2BAA2B,KAAK,CAAA;AAG7C,eAAO,MAAM,0BAA0B,MAAM,CAAA;AAI7C,eAAO,MAAM,0CAA0C,KAAK,CAAA;AAE5D,eAAO,MAAM,kBAAkB,+BAA+B,CAAA;AAC9D,eAAO,MAAM,oBAAoB,yBAAyB,CAAA;AAC1D,eAAO,MAAM,oBAAoB,iCAAiC,CAAA;AAClE,eAAO,MAAM,qBAAqB,0BAA0B,CAAA;AAE5D,eAAO,MAAM,mBAAmB,qBAAqB,CAAA;AACrD,eAAO,MAAM,4BAA4B,oCAAoC,CAAA;AAC7E,eAAO,MAAM,0BAA0B,kCAAkC,CAAA;AACzE,eAAO,MAAM,uBAAuB,IAAI,CAAA;AACxC,eAAO,MAAM,eAAe,KAAK,CAAA;AAEjC,eAAO,MAAM,4BAA4B,8BAA8B,CAAA;AACvE,eAAO,MAAM,4BAA4B,4BAA4B,CAAA;AACrE,eAAO,MAAM,qBAAqB,0BAA0B,CAAA;AAE5D,eAAO,MAAM,gCAAgC,MAAM,CAAA"}
@@ -1,5 +1,4 @@
1
1
  var TAB_WIDTH = 768;
2
- var MOBILE_WIDTH = 480;
3
2
  var RIGHT_BLOCK_RESIZED_EVENT = 'RIGHT_BLOCK_RESIZED_EVENT';
4
3
  // The sum of paddings in PageBody + header for first block
5
4
  var STANDARD_BODY_PADDING = 48 + 49;
@@ -21,4 +20,4 @@ var PAGE_CALENDAR_SELECT_WRAPPER = 'calendar-select-wrapper';
21
20
  var PAGE_BODY_WITH_SCROLL = 'page-body-with-scroll';
22
21
  var PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE = 300;
23
22
 
24
- export { COLLAPSE_MARGIN, DEFAULT_RIGHT_BLOCK_HEIGHT, MOBILE_WIDTH, PAGE_BODY_WITH_SCROLL, PAGE_CALENDAR_SELECT_WRAPPER, PAGE_LEFT_BLOCK_CONTAINER_ID, PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE, PAGE_RIGHT_BLOCK_BOTTOM_ID, PAGE_RIGHT_BLOCK_CHILDREN_ID, PAGE_RIGHT_BLOCK_ID, RIGHT_BLOCK_COLLAPSE, RIGHT_BLOCK_COLLAPSED, RIGHT_BLOCK_EXPAND, RIGHT_BLOCK_EXPANDED, RIGHT_BLOCK_RESIZED_EVENT, SEPARATOR_DEFAULT_WIDTH, STANDARD_BODY_PADDING, STANDARD_HEADER_FOOTER_SIZE, TAB_WIDTH };
23
+ export { COLLAPSE_MARGIN, DEFAULT_RIGHT_BLOCK_HEIGHT, PAGE_BODY_WITH_SCROLL, PAGE_CALENDAR_SELECT_WRAPPER, PAGE_LEFT_BLOCK_CONTAINER_ID, PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE, PAGE_RIGHT_BLOCK_BOTTOM_ID, PAGE_RIGHT_BLOCK_CHILDREN_ID, PAGE_RIGHT_BLOCK_ID, RIGHT_BLOCK_COLLAPSE, RIGHT_BLOCK_COLLAPSED, RIGHT_BLOCK_EXPAND, RIGHT_BLOCK_EXPANDED, RIGHT_BLOCK_RESIZED_EVENT, SEPARATOR_DEFAULT_WIDTH, STANDARD_BODY_PADDING, STANDARD_HEADER_FOOTER_SIZE, TAB_WIDTH };
@@ -1 +1 @@
1
- {"version":3,"file":"useResizePageBody.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/page/components/PageBody/hooks/useResizePageBody.ts"],"names":[],"mappings":"AAuBA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;eAMnB,MAAM;gBACL,MAAM;;CAmPjB,CAAA"}
1
+ {"version":3,"file":"useResizePageBody.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/page/components/PageBody/hooks/useResizePageBody.ts"],"names":[],"mappings":"AAsBA,eAAO,MAAM,iBAAiB;;;;;;;;;;;;eAMnB,MAAM;gBACL,MAAM;;CA2OjB,CAAA"}
@@ -1,6 +1,6 @@
1
1
  import { useState, useRef, useMemo, useEffect } from 'react';
2
2
  import { useWindowDimensions } from '@licklist/plugins/dist/hooks/Media/useWindowDimensions';
3
- import { DEFAULT_RIGHT_BLOCK_HEIGHT, PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE, TAB_WIDTH, PAGE_CALENDAR_SELECT_WRAPPER, PAGE_BODY_WITH_SCROLL, MOBILE_WIDTH, STANDARD_BODY_PADDING, STANDARD_HEADER_FOOTER_SIZE, PAGE_LEFT_BLOCK_CONTAINER_ID, PAGE_RIGHT_BLOCK_BOTTOM_ID, SEPARATOR_DEFAULT_WIDTH, COLLAPSE_MARGIN, RIGHT_BLOCK_RESIZED_EVENT, RIGHT_BLOCK_EXPAND, RIGHT_BLOCK_EXPANDED, RIGHT_BLOCK_COLLAPSE, RIGHT_BLOCK_COLLAPSED } from '../constants.js';
3
+ import { DEFAULT_RIGHT_BLOCK_HEIGHT, PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE, TAB_WIDTH, PAGE_CALENDAR_SELECT_WRAPPER, PAGE_BODY_WITH_SCROLL, STANDARD_BODY_PADDING, STANDARD_HEADER_FOOTER_SIZE, PAGE_LEFT_BLOCK_CONTAINER_ID, PAGE_RIGHT_BLOCK_BOTTOM_ID, SEPARATOR_DEFAULT_WIDTH, COLLAPSE_MARGIN, RIGHT_BLOCK_RESIZED_EVENT, RIGHT_BLOCK_EXPAND, RIGHT_BLOCK_EXPANDED, RIGHT_BLOCK_COLLAPSE, RIGHT_BLOCK_COLLAPSED } from '../constants.js';
4
4
 
5
5
  function _array_like_to_array(arr, len) {
6
6
  if (len == null || len > arr.length) len = arr.length;
@@ -73,11 +73,6 @@ var useResizePageBody = function() {
73
73
  behavior: 'smooth'
74
74
  });
75
75
  }
76
- if (width <= MOBILE_WIDTH && Boolean(CALENDAR_WRAPPER_HEIGHT)) {
77
- return {
78
- maxHeight: height - STANDARD_BODY_PADDING - rightBlockHeight - CALENDAR_WRAPPER_HEIGHT
79
- };
80
- }
81
76
  return {
82
77
  maxHeight: height - STANDARD_BODY_PADDING - rightBlockHeight - STANDARD_HEADER_FOOTER_SIZE - CALENDAR_WRAPPER_HEIGHT
83
78
  };
@@ -1 +1 @@
1
- {"version":3,"file":"paymentSummary.d.ts","sourceRoot":"","sources":["../../../../../src/iframe/payment/order-items-table/utils/paymentSummary.tsx"],"names":[],"mappings":"AACA,OAAO,EAGL,oBAAoB,EAEpB,WAAW,EAEZ,MAAM,UAAU,CAAA;AA4FjB,eAAO,MAAM,oBAAoB,oEAK9B,oBAAoB,KAAG,WAAW,EAUpC,CAAA"}
1
+ {"version":3,"file":"paymentSummary.d.ts","sourceRoot":"","sources":["../../../../../src/iframe/payment/order-items-table/utils/paymentSummary.tsx"],"names":[],"mappings":"AACA,OAAO,EAGL,oBAAoB,EAEpB,WAAW,EAEZ,MAAM,UAAU,CAAA;AA2FjB,eAAO,MAAM,oBAAoB,oEAK9B,oBAAoB,KAAG,WAAW,EAUpC,CAAA"}
@@ -1 +1 @@
1
- {"version":3,"file":"RyftPaymentForm.d.ts","sourceRoot":"","sources":["../../../src/iframe/ryft/RyftPaymentForm.tsx"],"names":[],"mappings":"AAaA,OAAO,EAEL,sBAAsB,EACvB,MAAM,kDAAkD,CAAA;AACzD,OAAO,EAAE,uBAAuB,EAAE,MAAM,0EAA0E,CAAA;AAKlH,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAW/C,CAAA;AAED,MAAM,MAAM,qBAAqB,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAA;AAOzD,MAAM,WAAW,oBAAoB;IAEnC,SAAS,EAAE,GAAG,CAAA;IACd,eAAe,EAAE,OAAO,CAAA;IACxB,kBAAkB,CAAC,EAAE,OAAO,CAAA;IAC5B,qBAAqB,CAAC,EAAE,MAAM,IAAI,CAAA;IAClC,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,QAAQ,EAAE,CACR,SAAS,EAAE,MAAM,IAAI,EACrB,SAAS,EAAE,CAAC,KAAK,CAAC,EAAE,MAAM,KAAK,IAAI,KAChC,OAAO,CAAC,IAAI,CAAC,CAAA;IAClB,QAAQ,EAAE,MAAM,OAAO,CAAC,sBAAsB,CAAC,CAAA;IAC/C,aAAa,CAAC,EAAE,MAAM,IAAI,CAAA;IAC1B,uBAAuB,CAAC,EAAE,uBAAuB,CAAA;CAClD;AAED,eAAO,MAAM,eAAe,8JAUzB,oBAAoB,4CAqLtB,CAAA"}
1
+ {"version":3,"file":"RyftPaymentForm.d.ts","sourceRoot":"","sources":["../../../src/iframe/ryft/RyftPaymentForm.tsx"],"names":[],"mappings":"AAOA,OAAO,EAML,sBAAsB,EACvB,MAAM,kDAAkD,CAAA;AACzD,OAAO,EAAE,uBAAuB,EAAE,MAAM,0EAA0E,CAAA;AAKlH,eAAO,MAAM,YAAY,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAW/C,CAAA;AAED,MAAM,MAAM,qBAAqB,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAA;AAOzD,MAAM,WAAW,oBAAoB;IAEnC,SAAS,EAAE,GAAG,CAAA;IACd,eAAe,EAAE,OAAO,CAAA;IACxB,kBAAkB,CAAC,EAAE,OAAO,CAAA;IAC5B,qBAAqB,CAAC,EAAE,MAAM,IAAI,CAAA;IAClC,iBAAiB,CAAC,EAAE,OAAO,CAAA;IAC3B,QAAQ,EAAE,CACR,SAAS,EAAE,MAAM,IAAI,EACrB,SAAS,EAAE,CAAC,KAAK,CAAC,EAAE,MAAM,KAAK,IAAI,KAChC,OAAO,CAAC,IAAI,CAAC,CAAA;IAClB,QAAQ,EAAE,MAAM,OAAO,CAAC,sBAAsB,CAAC,CAAA;IAC/C,aAAa,CAAC,EAAE,MAAM,IAAI,CAAA;IAC1B,uBAAuB,CAAC,EAAE,uBAAuB,CAAA;CAClD;AAED,eAAO,MAAM,eAAe,8JAUzB,oBAAoB,4CAqLtB,CAAA"}
@@ -5,8 +5,7 @@ import { useForm } from 'react-hook-form';
5
5
  import Button from 'react-bootstrap/Button';
6
6
  import { useHistory } from 'react-router-dom';
7
7
  import Alert from 'react-bootstrap/Alert';
8
- import { STATUS_PENDING_ACTION, STATUS_APPROVED, STATUS_CAPTURED, STATUS_PENDING_PAYMENT } from '@licklist/core/dist/DataMapper/Order/PaymentSessionOrderDataMapper';
9
- import { useRyftPayment } from '@licklist/plugins/dist/hooks/Ryft/useRyftPayment';
8
+ import { useRyftPayment, RYFT_STATUS_PENDING_ACTION, RYFT_STATUS_APPROVED, RYFT_STATUS_CAPTURED, RYFT_STATUS_PENDING_PAYMENT } from '@licklist/plugins/dist/hooks/Ryft/useRyftPayment';
10
9
  import '../../static/index.js';
11
10
  import { injectComponentsInRyftForm } from './utils/ryft-form.js';
12
11
  import { ButtonLoader } from '../../static/loader/ButtonLoader.js';
@@ -257,7 +256,7 @@ var RyftPaymentForm = function(param) {
257
256
  setRyftError('unknown_error');
258
257
  }
259
258
  if ('requiredAction' in paymentSession) {
260
- if (paymentSession.status !== STATUS_PENDING_ACTION || !((_paymentSession_requiredAction = paymentSession.requiredAction) === null || _paymentSession_requiredAction === void 0 ? void 0 : _paymentSession_requiredAction.url)) {
259
+ if (paymentSession.status !== RYFT_STATUS_PENDING_ACTION || !((_paymentSession_requiredAction = paymentSession.requiredAction) === null || _paymentSession_requiredAction === void 0 ? void 0 : _paymentSession_requiredAction.url)) {
261
260
  redirectOnFailAttempt(paymentSession);
262
261
  return [
263
262
  2
@@ -266,7 +265,7 @@ var RyftPaymentForm = function(param) {
266
265
  window.location.href = paymentSession.requiredAction.url;
267
266
  setReferrerBeforePayment();
268
267
  }
269
- if (paymentSession.status === STATUS_APPROVED || paymentSession.status === STATUS_CAPTURED || paymentSession.status === STATUS_PENDING_PAYMENT) {
268
+ if (paymentSession.status === RYFT_STATUS_APPROVED || paymentSession.status === RYFT_STATUS_CAPTURED || paymentSession.status === RYFT_STATUS_PENDING_PAYMENT) {
270
269
  redirectOnFailAttempt(paymentSession);
271
270
  return [
272
271
  2
@@ -1 +1 @@
1
- {"version":3,"file":"ryft-form.d.ts","sourceRoot":"","sources":["../../../../src/iframe/ryft/utils/ryft-form.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AACzC,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAA;AAEzD,UAAU,0BACR,SAAQ,IAAI,CACV,oBAAoB,EACpB,uBAAuB,GAAG,oBAAoB,CAC/C;IACD,CAAC,EAAE,SAAS,CAAC,MAAM,EAAE,CAAC,CAAA;IACtB,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,+BAA+B,CAAC,EAAE,OAAO,CAAA;CAC1C;AAED,eAAO,MAAM,0BAA0B,wGAMpC,0BAA0B,SA8E5B,CAAA"}
1
+ {"version":3,"file":"ryft-form.d.ts","sourceRoot":"","sources":["../../../../src/iframe/ryft/utils/ryft-form.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAA;AACzC,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAA;AAEzD,UAAU,0BACR,SAAQ,IAAI,CACV,oBAAoB,EACpB,uBAAuB,GAAG,oBAAoB,CAC/C;IACD,CAAC,EAAE,SAAS,CAAC,MAAM,EAAE,CAAC,CAAA;IACtB,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB,+BAA+B,CAAC,EAAE,OAAO,CAAA;CAC1C;AAED,eAAO,MAAM,0BAA0B,wGAMpC,0BAA0B,SA6E5B,CAAA"}
@@ -39,17 +39,17 @@ var injectComponentsInRyftForm = function(param) {
39
39
  divider.id = 'mobile-pay-divider';
40
40
  container.id = 'mobile-pay-divider-container';
41
41
  container.append(dividerText, divider);
42
- var payIframe = document.getElementById('ryft-pay-iframe');
42
+ var payIframe = document.getElementById("ryft-pay-iframe");
43
43
  if (payIframe) {
44
44
  var formBox = document.getElementById('form-disable-box');
45
45
  if (formBox) {
46
- formBox.style.display = isDisableButton ? 'block' : 'none';
46
+ formBox.style.display = isDisableButton ? "block" : "none";
47
47
  }
48
48
  var googleButton = document.getElementById('gpay-button-online-api-id');
49
- var appleButton = document.getElementById('ryft-pay-apple-pay-button');
49
+ var appleButton = document.getElementById("ryft-pay-apple-pay-button");
50
50
  if (googleButton) {
51
51
  googleButton.disabled = isDisableButton;
52
- googleButton.style.opacity = !isDisableButton ? '1' : '0.6';
52
+ googleButton.style.opacity = isDisableButton ? '1' : '0.6';
53
53
  }
54
54
  if (appleButton) {
55
55
  appleButton.disabled = isDisableButton;
@@ -60,6 +60,7 @@ var injectComponentsInRyftForm = function(param) {
60
60
  var applePayButton = document.createElement('button');
61
61
  applePayButton.id = 'apple-pay';
62
62
  applePayButton.type = 'button';
63
+ applePayButton.style.opacity = !isDisableButton ? '1' : '0.6';
63
64
  applePayButton.className = 'bg-dark btn btn-primary apple-pay-button';
64
65
  applePayButton.textContent = t('Events:payWithApple');
65
66
  applePayButton.onclick = onApplePayButtonClick;