@licklist/design 0.44.494 → 0.44.496
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/dist/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.d.ts +1 -0
- package/dist/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.d.ts.map +1 -1
- package/dist/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.js +1 -1
- package/dist/iframe/order-process/components/CategoryProduct/components/ProductQuantityInput/ProductQuantityInput.d.ts.map +1 -1
- package/dist/iframe/order-process/components/CategoryProduct/components/ProductQuantityInput/ProductQuantityInput.js +1 -1
- package/dist/sales/manual-booking/select-menu/SelectMenu.js +1 -1
- package/package.json +1 -1
- package/src/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.tsx +3 -0
- package/src/iframe/order-process/components/CategoryProduct/components/ProductQuantityInput/ProductQuantityInput.tsx +3 -2
- package/src/sales/manual-booking/select-menu/SelectMenu.tsx +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NumberInput.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAI1C,UAAU,gBAAgB;IACxB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACpC,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,eAAO,MAAM,WAAW,
|
|
1
|
+
{"version":3,"file":"NumberInput.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAI1C,UAAU,gBAAgB;IACxB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IAClC,SAAS,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACpC,WAAW,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACtC,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,OAAO,CAAC;CACpB;AAED,eAAO,MAAM,WAAW,2FAqEvB,CAAC"}
|
package/dist/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(exports,"__esModule",{value:!0});var t=require("react"),n=e(t),r=require("react-bootstrap"),a=e(require("clsx")),u=t.forwardRef((function(e,t){var u=e.className,o=void 0===u?"":u,
|
|
1
|
+
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(exports,"__esModule",{value:!0});var t=require("react"),n=e(t),r=require("react-bootstrap"),a=e(require("clsx")),u=t.forwardRef((function(e,t){var u=e.className,o=void 0===u?"":u,l=e.value,i=e.onChange,d=e.onArrowDown,m=e.onArrowUp,c=e.min,p=e.max,b=e.placeholder,s=e.defaultValue,f=e.disabled,v=a("payment-number-input",o);return n.createElement("div",{className:v},n.createElement("button",{type:"button",onClick:function(){void 0!==c&&l>c&&d(l-1),void 0===c&&m(l-1)},className:"payment-number-input__btn-down",disabled:f},"−"),n.createElement(r.FormControl,{type:"number",onChange:function(e){return i(Number(e.target.value))},value:l,min:c,max:p,defaultValue:s,placeholder:b,height:"5rem",disabled:f,ref:t}),n.createElement("button",{type:"button",onClick:function(){void 0!==p&&l<p&&m(l+1),void 0===p&&m(l+1)},className:"payment-number-input__btn-up",disabled:f},"+"))}));u.displayName="NumberInput",exports.NumberInput=u;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProductQuantityInput.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/order-process/components/CategoryProduct/components/ProductQuantityInput/ProductQuantityInput.tsx"],"names":[],"mappings":";AAIA,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAE/E,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAEnE,UAAU,aAAa;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,kBAAkB,EAAE,MAAM,CAAC;IAC3B,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,UAAU,yBAAyB;IACjC,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,eAAe,CAAC;IAC1B,WAAW,EAAE,kBAAkB,CAAC,WAAW,CAAC,CAAC;IAC7C,QAAQ,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,IAAI,CAAC;IACzC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,GAAG,EAAE,WAAW,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,aAAa,CAAC;CAC5B;AAED,eAAO,MAAM,oBAAoB,sFAS9B,yBAAyB,
|
|
1
|
+
{"version":3,"file":"ProductQuantityInput.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/order-process/components/CategoryProduct/components/ProductQuantityInput/ProductQuantityInput.tsx"],"names":[],"mappings":";AAIA,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,kBAAkB,EAAE,MAAM,iBAAiB,CAAC;AAE/E,OAAO,EAAE,OAAO,EAAE,eAAe,EAAE,MAAM,yBAAyB,CAAC;AAEnE,UAAU,aAAa;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,kBAAkB,EAAE,MAAM,CAAC;IAC3B,OAAO,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACxB,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED,UAAU,yBAAyB;IACjC,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,eAAe,CAAC;IAC1B,WAAW,EAAE,kBAAkB,CAAC,WAAW,CAAC,CAAC;IAC7C,QAAQ,EAAE,CAAC,KAAK,EAAE,aAAa,KAAK,IAAI,CAAC;IACzC,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,GAAG,EAAE,WAAW,CAAC;IACjB,OAAO,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,aAAa,CAAC;CAC5B;AAED,eAAO,MAAM,oBAAoB,sFAS9B,yBAAyB,gBAiF3B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(exports,"__esModule",{value:!0});var t=e(require("react")),
|
|
1
|
+
"use strict";function e(e){return e&&"object"==typeof e&&"default"in e?e.default:e}Object.defineProperty(exports,"__esModule",{value:!0});var t=e(require("react")),n=require("react-i18next"),i=require("react-bootstrap"),r=e(require("clsx")),o=require("../NumberInput/NumberInput.js");exports.ProductQuantityInput=function(e){var u=e.product,a=e.category,d=e.onChange,c=e.clearErrors,l=e.ref,s=e.productInfo,p=e.invalid,m=e.deposit,y=n.useTranslation("Design").t;return u.isSoldOut?t.createElement("div",{className:"iframe-event__sold-out-wrapper"},y("Design:soldOut")):1===(null==u?void 0:u.maxAmount)?t.createElement(i.Button,{ref:l,disabled:u.isSoldOut,className:r("iframe-event__".concat((null==s?void 0:s.quantity)?"unselect-product":"select-product"),p&&"error"),onClick:function(){d({id:u.id,name:u.name,deposit:m,price:u.price,productsCategoryId:a.id,quantity:(null==s?void 0:s.quantity)?0:1})}},y("Design:".concat((null==s?void 0:s.quantity)?"unselect":"select"))):t.createElement(o.NumberInput,{ref:l,onChange:function(e){d({id:u.id,name:u.name,deposit:m,price:u.price,productsCategoryId:a.id,quantity:e||null}),c("".concat(u.id))},onArrowDown:function(){d({id:u.id,name:u.name,deposit:m,price:u.price,productsCategoryId:a.id,quantity:(null==s?void 0:s.quantity)-1||0}),c("".concat(u.id))},onArrowUp:function(){var e;d({id:u.id,name:u.name,deposit:m,price:u.price,productsCategoryId:a.id,quantity:(null!==(e=null==s?void 0:s.quantity)&&void 0!==e?e:0)+1}),c("".concat(u.id))},min:0,placeholder:"0",disabled:u.isSoldOut,value:null==s?void 0:s.quantity,className:r(p&&"error")})};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("react"),r=(e=t)&&"object"==typeof e&&"default"in e?e.default:e;require("../../../static/loader/LoaderIndicator.js");var a=require("../../../static/loader/BlockLoader.js"),n=require("react-i18next"),l=require("react-bootstrap");require("../../../static/loader/ButtonLoader.js"),require("../../../static/loader/SnippetLoader.js"),require("../../../static/loader/PaymentLoader.js");var o=require("./components/MenuButton.js");exports.SelectMenu=function(e){var t=e.isLoading,
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("react"),r=(e=t)&&"object"==typeof e&&"default"in e?e.default:e;require("../../../static/loader/LoaderIndicator.js");var a=require("../../../static/loader/BlockLoader.js"),n=require("react-i18next"),l=require("react-bootstrap");require("../../../static/loader/ButtonLoader.js"),require("../../../static/loader/SnippetLoader.js"),require("../../../static/loader/PaymentLoader.js");var o=require("./components/MenuButton.js");exports.SelectMenu=function(e){var t=e.isLoading,s=void 0!==t&&t,u=e.menus,c=e.onSelectMenu,i=n.useTranslation(["App","Sale"]).t;return s?r.createElement("div",null,r.createElement("div",{className:"loader-container"},r.createElement(a.BlockLoader,null))):r.createElement("div",null,u&&u.length||s?r.createElement(r.Fragment,null,!s&&r.createElement(l.Form.Label,{className:"bold-text"},i("Design:productSets")),r.createElement("div",{className:"menu-list-manual-booking"},null==u?void 0:u.map((function(e){return r.createElement(o.MenuButton,{key:e.id,menu:e,onSelectMenu:c})})))):r.createElement("div",{className:"no-results-content"},r.createElement("span",{className:"no-results-found"},i("App:noResultsFoundForSelectedDate"))))};
|
package/package.json
CHANGED
package/src/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.tsx
CHANGED
|
@@ -10,6 +10,7 @@ interface NumberInputProps {
|
|
|
10
10
|
onArrowDown?: (value: number) => void;
|
|
11
11
|
min?: number;
|
|
12
12
|
max?: number;
|
|
13
|
+
placeholder?: string;
|
|
13
14
|
defaultValue?: number;
|
|
14
15
|
disabled?: boolean;
|
|
15
16
|
}
|
|
@@ -24,6 +25,7 @@ export const NumberInput = forwardRef<HTMLInputElement, NumberInputProps>(
|
|
|
24
25
|
onArrowUp,
|
|
25
26
|
min,
|
|
26
27
|
max,
|
|
28
|
+
placeholder,
|
|
27
29
|
defaultValue,
|
|
28
30
|
disabled,
|
|
29
31
|
},
|
|
@@ -66,6 +68,7 @@ export const NumberInput = forwardRef<HTMLInputElement, NumberInputProps>(
|
|
|
66
68
|
min={min}
|
|
67
69
|
max={max}
|
|
68
70
|
defaultValue={defaultValue}
|
|
71
|
+
placeholder={placeholder}
|
|
69
72
|
height="5rem"
|
|
70
73
|
disabled={disabled}
|
|
71
74
|
ref={ref}
|
|
@@ -83,7 +83,7 @@ export const ProductQuantityInput = ({
|
|
|
83
83
|
deposit,
|
|
84
84
|
price: product.price,
|
|
85
85
|
productsCategoryId: category.id,
|
|
86
|
-
quantity: val,
|
|
86
|
+
quantity: val || null,
|
|
87
87
|
});
|
|
88
88
|
clearErrors(`${product.id}` as const);
|
|
89
89
|
}}
|
|
@@ -110,8 +110,9 @@ export const ProductQuantityInput = ({
|
|
|
110
110
|
clearErrors(`${product.id}` as const);
|
|
111
111
|
}}
|
|
112
112
|
min={0}
|
|
113
|
+
placeholder="0"
|
|
113
114
|
disabled={product.isSoldOut}
|
|
114
|
-
value={productInfo?.quantity
|
|
115
|
+
value={productInfo?.quantity}
|
|
115
116
|
className={clsx(invalid && "error")}
|
|
116
117
|
/>
|
|
117
118
|
);
|
|
@@ -39,7 +39,7 @@ export const SelectMenu = ({
|
|
|
39
39
|
) : (
|
|
40
40
|
<>
|
|
41
41
|
{!isLoading && (
|
|
42
|
-
<Form.Label className="bold-text">{t("
|
|
42
|
+
<Form.Label className="bold-text">{t("Design:productSets")}</Form.Label>
|
|
43
43
|
)}
|
|
44
44
|
|
|
45
45
|
<div className="menu-list-manual-booking">
|