@licklist/design 0.60.0 → 0.61.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/dist/iframe/event/event-card/IframeEventCard.d.ts +2 -1
  2. package/dist/iframe/event/event-card/IframeEventCard.d.ts.map +1 -1
  3. package/dist/iframe/event/event-card/IframeEventCard.js +1 -1
  4. package/dist/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.js +1 -1
  5. package/dist/iframe/page/components/PageBody/components/LeftBlock/LeftBlock.d.ts.map +1 -1
  6. package/dist/iframe/page/components/PageBody/components/LeftBlock/LeftBlock.js +1 -1
  7. package/dist/iframe/page/components/PageBody/constants.d.ts +1 -1
  8. package/dist/iframe/page/components/PageBody/constants.d.ts.map +1 -1
  9. package/dist/iframe/page/components/PageBody/constants.js +1 -1
  10. package/dist/iframe/page/components/PageBody/hooks/useResizePageBody.js +1 -1
  11. package/dist/iframe/payment/payment-page/PaymentPage.js +1 -1
  12. package/dist/product-set/product-category/ProductCategoryControl.d.ts +1 -0
  13. package/dist/product-set/product-category/ProductCategoryControl.d.ts.map +1 -1
  14. package/dist/product-set/product-category/ProductCategoryControl.js +1 -1
  15. package/dist/static/manual-date-picker/ManualDatePicker.js +1 -1
  16. package/dist/static/manual-date-picker/constants/index.d.ts +4 -1
  17. package/dist/static/manual-date-picker/constants/index.d.ts.map +1 -1
  18. package/dist/static/manual-date-picker/constants/index.js +1 -1
  19. package/dist/static/manual-date-picker/utils/index.d.ts +4 -0
  20. package/dist/static/manual-date-picker/utils/index.d.ts.map +1 -1
  21. package/dist/static/manual-date-picker/utils/index.js +1 -1
  22. package/dist/styles/iframe-events/Card.scss +24 -8
  23. package/dist/styles/iframe-events/PoweredBy.scss +2 -2
  24. package/dist/styles/iframe-order-process/IframeOrderProcess.scss +0 -2
  25. package/dist/styles/iframe-page/Page.scss +1 -0
  26. package/dist/styles/iframe-page/PageBody.scss +32 -9
  27. package/dist/styles/iframe-page/PageHeader.scss +41 -39
  28. package/package.json +1 -1
  29. package/src/iframe/event/event-card/IframeEventCard.stories.tsx +1 -0
  30. package/src/iframe/event/event-card/IframeEventCard.tsx +7 -8
  31. package/src/iframe/order-process/components/CategoryProduct/components/NumberInput/NumberInput.tsx +1 -1
  32. package/src/iframe/page/components/PageBody/components/LeftBlock/LeftBlock.tsx +3 -1
  33. package/src/iframe/page/components/PageBody/constants.ts +1 -1
  34. package/src/iframe/page/components/PageBody/hooks/useResizePageBody.ts +3 -3
  35. package/src/iframe/payment/payment-page/PaymentPage.tsx +2 -2
  36. package/src/product-set/product-category/ProductCategoryControl.tsx +89 -27
  37. package/src/static/manual-date-picker/ManualDatePicker.tsx +3 -3
  38. package/src/static/manual-date-picker/constants/index.ts +6 -2
  39. package/src/static/manual-date-picker/utils/index.ts +11 -0
  40. package/src/styles/iframe-events/Card.scss +24 -8
  41. package/src/styles/iframe-events/PoweredBy.scss +2 -2
  42. package/src/styles/iframe-order-process/IframeOrderProcess.scss +0 -2
  43. package/src/styles/iframe-page/Page.scss +1 -0
  44. package/src/styles/iframe-page/PageBody.scss +32 -9
  45. package/src/styles/iframe-page/PageHeader.scss +41 -39
@@ -16,7 +16,8 @@ interface IframeEventCardProps {
16
16
  titleId?: string;
17
17
  descriptionId?: string;
18
18
  imageClassName?: string;
19
+ showMoreInfo?: boolean;
19
20
  }
20
- export declare function IframeEventCard({ title, type, cost, date, imageSrc, colour, goToDetails, description, isListView, className, shortDate, titleId, descriptionId, imageClassName, }: IframeEventCardProps): JSX.Element;
21
+ export declare function IframeEventCard({ title, type, cost, date, imageSrc, colour, goToDetails, description, isListView, className, shortDate, titleId, descriptionId, imageClassName, showMoreInfo, }: IframeEventCardProps): JSX.Element;
21
22
  export {};
22
23
  //# sourceMappingURL=IframeEventCard.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"IframeEventCard.d.ts","sourceRoot":"","sources":["../../../../src/iframe/event/event-card/IframeEventCard.tsx"],"names":[],"mappings":";AAKA,OAAO,EAAE,OAAO,EAAE,MAAM,2DAA2D,CAAC;AASpF,UAAU,oBAAoB;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,cAAc,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC,CAAC;IAC1C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,cAAc,CAAC,EAAE,MAAM,CAAC;CACzB;AAED,wBAAgB,eAAe,CAAC,EAC9B,KAAK,EACL,IAAI,EACJ,IAAI,EACJ,IAAI,EACJ,QAAQ,EACR,MAAM,EACN,WAAW,EACX,WAAW,EACX,UAAkB,EAClB,SAAS,EACT,SAAS,EACT,OAAO,EACP,aAAa,EACb,cAAc,GACf,EAAE,oBAAoB,eA6FtB"}
1
+ {"version":3,"file":"IframeEventCard.d.ts","sourceRoot":"","sources":["../../../../src/iframe/event/event-card/IframeEventCard.tsx"],"names":[],"mappings":";AAKA,OAAO,EAAE,OAAO,EAAE,MAAM,2DAA2D,CAAC;AASpF,UAAU,oBAAoB;IAC5B,KAAK,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,EAAE,MAAM,CAAC;IACb,QAAQ,CAAC,EAAE,MAAM,CAAC;IAElB,cAAc,CAAC,EAAE,OAAO,CAAC,eAAe,CAAC,CAAC;IAC1C,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,IAAI,CAAC;IACzB,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,EAAE,MAAM,CAAC;IAClB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB;AAED,wBAAgB,eAAe,CAAC,EAC9B,KAAK,EACL,IAAI,EACJ,IAAI,EACJ,IAAI,EACJ,QAAQ,EACR,MAAM,EACN,WAAW,EACX,WAAW,EACX,UAAkB,EAClB,SAAS,EACT,SAAS,EACT,OAAO,EACP,aAAa,EACb,cAAc,EACd,YAAY,GACb,EAAE,oBAAoB,eA0FtB"}
@@ -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")),a=require("react-i18next"),r=require("react-bootstrap"),i=e(require("clsx")),c=require("react-intl"),l=require("../../../tiptap-editor/TipTapEditor.js"),s=require("../../../events/event-card/utils.js"),n=require("../../../assets/iframe/clock.svg.js"),m=require("../../../assets/iframe/calendar.svg.js"),d=require("../../../assets/iframe/ticket.svg.js");exports.IframeEventCard=function(e){var o=e.title,v=e.type,u=e.cost,p=e.date,f=e.imageSrc,E=e.colour,N=e.goToDetails,g=e.description,C=e.isListView,b=void 0!==C&&C,x=e.className,_=e.shortDate,w=e.titleId,T=e.descriptionId,q=e.imageClassName,y=c.useIntl().formatNumber,j=a.useTranslation("Design").t;return t.createElement(r.Card,{style:{"--card-colour":E},className:i("iframe-event-card",{"list-view":b},x),onClick:N?function(){N&&N()}:void 0},f&&t.createElement(r.Card.Img,{className:null!=q?q:"card-image",variant:"top",as:"div",style:{backgroundImage:'url("'.concat(f,'")')}}),t.createElement(r.Card.Body,{className:i("d-flex","flex-column",!f&&"no-image")},t.createElement(r.Card.Title,{className:"iframe-event-card__title",id:w},o),t.createElement("div",{className:"flex-grow-1 iframe-event-card__description"},t.createElement(r.Card.Text,{as:"div"},t.createElement("div",{className:"d-flex align-items-center mb-3"},t.createElement("div",{className:"icon-wrapper"},t.createElement(m.ReactComponent,null)),t.createElement("p",{className:"iframe-event-card__bold m-0 list-view-hided"},p),t.createElement("p",{className:"iframe-event-card__bold m-0 grid-view-hided"},_))),v&&t.createElement(r.Card.Text,{as:"div",className:"list-view-hided"},t.createElement("div",{className:"d-flex align-items-center mb-3"},t.createElement("div",{className:"icon-wrapper"},t.createElement(n.ReactComponent,null)),t.createElement("p",{className:"iframe-event-card__bold m-0"},v))),"number"==typeof u&&t.createElement(r.Card.Text,{as:"div"},t.createElement("div",{className:"d-flex align-items-center mb-3"},t.createElement("div",{className:"icon-wrapper"},t.createElement(d.ReactComponent,null)),t.createElement("p",{className:"iframe-event-card__bold m-0"},j("from")," ",y(u,{style:"currency",currency:"GBP"})))),g&&t.createElement(r.Card.Text,{as:"div",className:"list-view-hided"},t.createElement(l.TipTapEditor,{viewMode:!0,disabled:!0,content:s.formatContent(g,150),id:T})))))};
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")),a=require("react-i18next"),r=require("react-bootstrap"),i=e(require("clsx")),s=require("react-intl"),c=require("../../../tiptap-editor/TipTapEditor.js"),l=require("../../../events/event-card/utils.js"),n=require("../../../assets/iframe/clock.svg.js"),m=require("../../../assets/iframe/calendar.svg.js"),d=require("../../../assets/iframe/ticket.svg.js");exports.IframeEventCard=function(e){var o=e.title,u=e.type,v=e.cost,p=e.date,f=e.imageSrc,E=e.colour,N=e.goToDetails,g=e.description,C=e.isListView,x=void 0!==C&&C,w=e.className,T=e.shortDate,b=e.titleId,q=e.descriptionId,y=e.imageClassName,_=e.showMoreInfo,j=s.useIntl().formatNumber,I=a.useTranslation("Design").t;return t.createElement(r.Card,{style:{"--card-colour":E},className:i("iframe-event-card",{"list-view":x},w),onClick:N?function(){N&&N()}:void 0},_&&t.createElement("div",{className:"iframe-event-card__info-icon"},"i"),f&&t.createElement(r.Card.Img,{className:null!=y?y:"card-image",variant:"top",as:"div",style:{backgroundImage:'url("'.concat(f,'")')}}),t.createElement(r.Card.Body,{className:i("d-flex","flex-column",!f&&"no-image")},t.createElement(r.Card.Title,{className:"iframe-event-card__title",id:b},o),t.createElement("div",{className:"flex-grow-1 iframe-event-card__description"},t.createElement(r.Card.Text,{as:"div"},t.createElement("div",{className:"d-flex align-items-center mb-3"},t.createElement("div",{className:"icon-wrapper"},t.createElement(m.ReactComponent,null)),t.createElement("p",{className:"m-0 list-view-hided"},p),t.createElement("p",{className:"m-0 grid-view-hided"},T))),u&&t.createElement(r.Card.Text,{as:"div",className:"list-view-hided"},t.createElement("div",{className:"d-flex align-items-center mb-3"},t.createElement("div",{className:"icon-wrapper"},t.createElement(n.ReactComponent,null)),t.createElement("p",{className:"m-0"},u))),"number"==typeof v&&t.createElement(r.Card.Text,{as:"div"},t.createElement("div",{className:"d-flex align-items-center mb-3"},t.createElement("div",{className:"icon-wrapper"},t.createElement(d.ReactComponent,null)),t.createElement("p",{className:"m-0"},I("from")," ",j(v,{style:"currency",currency:"GBP"})))),g&&t.createElement(r.Card.Text,{as:"div",className:"list-view-hided"},t.createElement(c.TipTapEditor,{viewMode:!0,disabled:!0,content:l.formatContent(g,150),id:q})))))};
@@ -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),a=require("react-bootstrap"),r=e(require("clsx")),u=t.forwardRef((function(e,t){var u=e.className,o=void 0===u?"":u,l=e.value,i=e.onChange,c=e.onArrowDown,m=e.onArrowUp,b=e.min,d=e.max,p=e.placeholder,s=e.defaultValue,f=e.disabled,v=!l,y=d>0&&l===d,N=r("payment-number-input",o);return n.createElement("div",{className:N},n.createElement("button",{type:"button",onClick:function(){l&&(b>0&&(l||0)===b?c(0):m(l-1))},className:"payment-number-input__btn-down ".concat(v&&"disabled-number-input-button"),disabled:f},"−"),n.createElement(a.FormControl,{type:"number",onChange:function(e){return t=Number(e.target.value),void i(d>0&&t>d?d:b>0&&t&&t<b?b:t);var t},value:l,min:b,max:d,defaultValue:s,placeholder:p,height:"5rem",disabled:f,ref:t}),n.createElement("button",{type:"button",onClick:function(){d>0&&l===d||m(b>0&&(l||0)<b?b:(l||0)+1)},className:"payment-number-input__btn-up ".concat(y&&"disabled-number-input-button"),disabled:f},"+"))}));u.displayName="NumberInput",exports.NumberInput=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),a=require("react-bootstrap"),r=e(require("clsx")),u=t.forwardRef((function(e,t){var u=e.className,o=void 0===u?"":u,l=e.value,i=e.onChange,c=e.onArrowDown,m=e.onArrowUp,b=e.min,d=e.max,p=e.placeholder,s=e.defaultValue,f=e.disabled,v=!l,y=d>0&&l===d,N=r("payment-number-input",o);return n.createElement("div",{className:N},n.createElement("button",{type:"button",onClick:function(){l&&(b>0&&(l||0)===b?c(0):m(l-1))},className:"payment-number-input__btn-down ".concat(v&&"disabled-number-input-button"),disabled:f},"−"),n.createElement(a.FormControl,{type:"number",onChange:function(e){return t=Number(e.target.value),void i(d>0&&t>d?d:b>0&&t&&t<b?b:t);var t},value:l,min:0,max:d,defaultValue:s,placeholder:p,height:"5rem",disabled:f,ref:t}),n.createElement("button",{type:"button",onClick:function(){d>0&&l===d||m(b>0&&(l||0)<b?b:(l||0)+1)},className:"payment-number-input__btn-up ".concat(y&&"disabled-number-input-button"),disabled:f},"+"))}));u.displayName="NumberInput",exports.NumberInput=u;
@@ -1 +1 @@
1
- {"version":3,"file":"LeftBlock.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/page/components/PageBody/components/LeftBlock/LeftBlock.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,iBAAiB,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAM5E,MAAM,MAAM,cAAc,GAAG,iBAAiB,CAC5C;IACE,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B,GAAG,cAAc,CAAC,cAAc,CAAC,CACnC,CAAC;AAEF,eAAO,MAAM,SAAS,+EAOnB,cAAc,gBA6BhB,CAAC"}
1
+ {"version":3,"file":"LeftBlock.d.ts","sourceRoot":"","sources":["../../../../../../src/iframe/page/components/PageBody/components/LeftBlock/LeftBlock.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAE,iBAAiB,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAM5E,MAAM,MAAM,cAAc,GAAG,iBAAiB,CAC5C;IACE,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,iBAAiB,CAAC,EAAE,MAAM,CAAC;CAC5B,GAAG,cAAc,CAAC,cAAc,CAAC,CACnC,CAAC;AAEF,eAAO,MAAM,SAAS,+EAOnB,cAAc,gBA+BhB,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=require("tslib"),l=e(require("react")),a=e(require("clsx")),s=require("../../constants.js"),r=require("@licklist/plugins/dist/context/page/PageContext"),i=require("../../hooks/useResizePageBody.js");exports.LeftBlock=function(e){var n=e.pageTitle,c=e.children,o=e.className,u=e.component,d=e.childrenClassName,m=t.__rest(e,["pageTitle","children","className","component","childrenClassName"]),f=i.useResizePageBody(),g=f.leftBlockStyles,p=f.leftBlockContainerSizes;return l.createElement("div",t.__assign({className:a("left-block",o)},m),l.createElement("div",{className:"navigation"},n&&l.createElement(l.Fragment,null,"string"==typeof n?l.createElement("div",{className:"title"},n):n),u),l.createElement("div",{className:a("left-block-container",d),style:g,id:s.PAGE_LEFT_BLOCK_CONTAINER_ID},l.createElement(r.PageContextProvider,{leftBlockContainerSizes:p},c)))};
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("tslib"),l=e(require("react")),a=e(require("clsx")),i=require("../../constants.js"),s=require("@licklist/plugins/dist/context/page/PageContext"),n=require("../../hooks/useResizePageBody.js");exports.LeftBlock=function(e){var r=e.pageTitle,c=e.children,o=e.className,u=e.component,d=e.childrenClassName,m=t.__rest(e,["pageTitle","children","className","component","childrenClassName"]),f=n.useResizePageBody(),g=f.leftBlockStyles,p=f.leftBlockContainerSizes;return l.createElement("div",t.__assign({className:a("left-block",o)},m),l.createElement("div",{className:"navigation"},r&&l.createElement(l.Fragment,null,"string"==typeof r?l.createElement("div",{className:"title",id:"navigation-title"},r):r),u),l.createElement("div",{className:a("left-block-container",d),style:g,id:i.PAGE_LEFT_BLOCK_CONTAINER_ID},l.createElement(s.PageContextProvider,{leftBlockContainerSizes:p},c)))};
@@ -15,6 +15,6 @@ export declare const SEPARATOR_DEFAULT_WIDTH = 2;
15
15
  export declare const COLLAPSE_MARGIN = 36;
16
16
  export declare const PAGE_LEFT_BLOCK_CONTAINER_ID = "page-left-block-container";
17
17
  export declare const PAGE_CALENDAR_SELECT_WRAPPER = "calendar-select-wrapper";
18
- export declare const PAYMENT_LINK_PAGE_BODY = "payment_link_page_body";
18
+ export declare const PAGE_BODY_WITH_SCROLL = "page-body-with-scroll";
19
19
  export declare const PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE = 300;
20
20
  //# sourceMappingURL=constants.d.ts.map
@@ -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,CAAC;AAC7B,eAAO,MAAM,yBAAyB,8BAA8B,CAAC;AAErE,eAAO,MAAM,qBAAqB,QAAU,CAAC;AAE7C,eAAO,MAAM,2BAA2B,KAAK,CAAC;AAG9C,eAAO,MAAM,0BAA0B,MAAM,CAAC;AAI9C,eAAO,MAAM,0CAA0C,KAAK,CAAC;AAE7D,eAAO,MAAM,kBAAkB,+BAA+B,CAAC;AAC/D,eAAO,MAAM,oBAAoB,yBAAyB,CAAC;AAC3D,eAAO,MAAM,oBAAoB,iCAAiC,CAAC;AACnE,eAAO,MAAM,qBAAqB,0BAA0B,CAAC;AAE7D,eAAO,MAAM,mBAAmB,qBAAqB,CAAC;AACtD,eAAO,MAAM,4BAA4B,oCAAoC,CAAC;AAC9E,eAAO,MAAM,0BAA0B,kCAAkC,CAAC;AAC1E,eAAO,MAAM,uBAAuB,IAAI,CAAC;AACzC,eAAO,MAAM,eAAe,KAAK,CAAC;AAElC,eAAO,MAAM,4BAA4B,8BAA8B,CAAC;AACxE,eAAO,MAAM,4BAA4B,4BAA4B,CAAC;AACtE,eAAO,MAAM,sBAAsB,2BAA2B,CAAC;AAE/D,eAAO,MAAM,gCAAgC,MAAM,CAAC"}
1
+ {"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../../../src/iframe/page/components/PageBody/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,SAAS,MAAM,CAAC;AAC7B,eAAO,MAAM,yBAAyB,8BAA8B,CAAC;AAErE,eAAO,MAAM,qBAAqB,QAAU,CAAC;AAE7C,eAAO,MAAM,2BAA2B,KAAK,CAAC;AAG9C,eAAO,MAAM,0BAA0B,MAAM,CAAC;AAI9C,eAAO,MAAM,0CAA0C,KAAK,CAAC;AAE7D,eAAO,MAAM,kBAAkB,+BAA+B,CAAC;AAC/D,eAAO,MAAM,oBAAoB,yBAAyB,CAAC;AAC3D,eAAO,MAAM,oBAAoB,iCAAiC,CAAC;AACnE,eAAO,MAAM,qBAAqB,0BAA0B,CAAC;AAE7D,eAAO,MAAM,mBAAmB,qBAAqB,CAAC;AACtD,eAAO,MAAM,4BAA4B,oCAAoC,CAAC;AAC9E,eAAO,MAAM,0BAA0B,kCAAkC,CAAC;AAC1E,eAAO,MAAM,uBAAuB,IAAI,CAAC;AACzC,eAAO,MAAM,eAAe,KAAK,CAAC;AAElC,eAAO,MAAM,4BAA4B,8BAA8B,CAAC;AACxE,eAAO,MAAM,4BAA4B,4BAA4B,CAAC;AACtE,eAAO,MAAM,qBAAqB,0BAA0B,CAAC;AAE7D,eAAO,MAAM,gCAAgC,MAAM,CAAC"}
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.COLLAPSE_MARGIN=36,exports.DEFAULT_RIGHT_BLOCK_HEIGHT=132,exports.PAGE_CALENDAR_SELECT_WRAPPER="calendar-select-wrapper",exports.PAGE_LEFT_BLOCK_CONTAINER_ID="page-left-block-container",exports.PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE=300,exports.PAGE_RIGHT_BLOCK_BOTTOM_ID="page-right-block-bottom-block",exports.PAGE_RIGHT_BLOCK_CHILDREN_ID="page-right-block-children-block",exports.PAGE_RIGHT_BLOCK_ID="page-right-block",exports.PAYMENT_LINK_PAGE_BODY="payment_link_page_body",exports.RIGHT_BLOCK_COLLAPSE="RIGHT_BLOCK_COLLAPSE_CLICKED",exports.RIGHT_BLOCK_COLLAPSED="RIGHT_BLOCK_COLLAPSED",exports.RIGHT_BLOCK_EXPAND="RIGHT_BLOCK_EXPAND_CLICKED",exports.RIGHT_BLOCK_EXPANDED="RIGHT_BLOCK_EXPANDED",exports.RIGHT_BLOCK_RESIZED_EVENT="RIGHT_BLOCK_RESIZED_EVENT",exports.SEPARATOR_DEFAULT_WIDTH=2,exports.STANDARD_BODY_PADDING=97,exports.STANDARD_HEADER_FOOTER_SIZE=96,exports.TAB_WIDTH=768;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.COLLAPSE_MARGIN=36,exports.DEFAULT_RIGHT_BLOCK_HEIGHT=132,exports.PAGE_BODY_WITH_SCROLL="page-body-with-scroll",exports.PAGE_CALENDAR_SELECT_WRAPPER="calendar-select-wrapper",exports.PAGE_LEFT_BLOCK_CONTAINER_ID="page-left-block-container",exports.PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE=300,exports.PAGE_RIGHT_BLOCK_BOTTOM_ID="page-right-block-bottom-block",exports.PAGE_RIGHT_BLOCK_CHILDREN_ID="page-right-block-children-block",exports.PAGE_RIGHT_BLOCK_ID="page-right-block",exports.RIGHT_BLOCK_COLLAPSE="RIGHT_BLOCK_COLLAPSE_CLICKED",exports.RIGHT_BLOCK_COLLAPSED="RIGHT_BLOCK_COLLAPSED",exports.RIGHT_BLOCK_EXPAND="RIGHT_BLOCK_EXPAND_CLICKED",exports.RIGHT_BLOCK_EXPANDED="RIGHT_BLOCK_EXPANDED",exports.RIGHT_BLOCK_RESIZED_EVENT="RIGHT_BLOCK_RESIZED_EVENT",exports.SEPARATOR_DEFAULT_WIDTH=2,exports.STANDARD_BODY_PADDING=97,exports.STANDARD_HEADER_FOOTER_SIZE=96,exports.TAB_WIDTH=768;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("tslib"),n=require("react"),i=((e=n)&&"object"==typeof e&&"default"in e&&e.default,require("@licklist/plugins/dist/hooks/Media/useWindowDimensions")),r=require("../constants.js");exports.useResizePageBody=function(){var e=i.useWindowDimensions(),u=e.height,_=e.width,o=t.__read(n.useState(r.DEFAULT_RIGHT_BLOCK_HEIGHT),2),E=o[0],c=o[1],d=t.__read(n.useState({width:r.PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE,height:r.PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE}),2),s=d[0],f=d[1],L=n.useRef(void 0),A=n.useRef(!1),T=t.__read(n.useState(!1),2),a=T[0],D=T[1],I=t.__read(n.useState(!1),2),v=I[0],O=I[1],R=t.__read(n.useState(!1),2),l=R[0],B=R[1],h=t.__read(n.useState(!1),2),w=h[0],C=h[1],H=n.useMemo((function(){if(_>=r.TAB_WIDTH)return{};if(!v&&!w)return{};var e=document.getElementById(r.PAGE_CALENDAR_SELECT_WRAPPER),t=e?e.clientHeight:0,n=document.getElementById(r.PAYMENT_LINK_PAGE_BODY);return n&&n.scroll({top:-E,behavior:"smooth"}),{maxHeight:u-r.STANDARD_BODY_PADDING-E-r.STANDARD_HEADER_FOOTER_SIZE-t}}),[u,_,E,a,v,l,w]),P=new ResizeObserver((function(){var e=document.getElementById(r.PAGE_LEFT_BLOCK_CONTAINER_ID);if(e){if(_>=r.TAB_WIDTH&&!A)return A.current=!0,void f({width:e.clientWidth,height:e.clientHeight});A.current=!1,f((function(){var t=e.clientWidth<=e.clientHeight?e.clientWidth:e.clientHeight;return(!L.current||L.current&&t>L.current)&&(L.current=t),{width:e.clientWidth,height:L.current}}))}})),S=n.useMemo((function(){if(_>=r.TAB_WIDTH)return{};if(!v&&!w)return{};var e=.75*(u-r.STANDARD_BODY_PADDING-r.STANDARD_HEADER_FOOTER_SIZE),t=0,n=document.getElementById(r.PAGE_RIGHT_BLOCK_BOTTOM_ID);return n&&(t=r.SEPARATOR_DEFAULT_WIDTH+n.clientHeight),{maxHeight:e-t-r.COLLAPSE_MARGIN}}),[u,_,E,a,v,l,w]);return n.useEffect((function(){var e=function(e){var t=e.detail.height;c(t)};return window.addEventListener(r.RIGHT_BLOCK_RESIZED_EVENT,(function(t){return e(t)})),function(){window.removeEventListener(r.RIGHT_BLOCK_RESIZED_EVENT,(function(t){return e(t)}))}}),[]),n.useEffect((function(){var e=function(){D(!0),O(!1),B(!1),C(!1)};return window.addEventListener(r.RIGHT_BLOCK_EXPAND,e),function(){window.removeEventListener(r.RIGHT_BLOCK_EXPAND,e)}}),[]),n.useEffect((function(){var e=function(){D(!1),O(!0),B(!1),C(!1)};return window.addEventListener(r.RIGHT_BLOCK_EXPANDED,e),function(){window.removeEventListener(r.RIGHT_BLOCK_EXPANDED,e)}}),[]),n.useEffect((function(){var e=function(){D(!1),O(!1),B(!0),C(!1)};return window.addEventListener(r.RIGHT_BLOCK_COLLAPSE,e),function(){window.removeEventListener(r.RIGHT_BLOCK_COLLAPSE,e)}}),[]),n.useEffect((function(){var e=function(){D(!1),O(!1),B(!1),C(!0)};return window.addEventListener(r.RIGHT_BLOCK_COLLAPSED,e),function(){window.removeEventListener(r.RIGHT_BLOCK_COLLAPSED,e)}}),[]),n.useEffect((function(){var e=document.getElementById(r.PAGE_LEFT_BLOCK_CONTAINER_ID);if(e)return P.observe(e),function(){e&&P.unobserve(e)}}),[]),n.useEffect((function(){L.current=void 0}),[_]),{leftBlockStyles:H,rightBlockContentStyles:S,leftBlockContainerSizes:s}};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("tslib"),n=require("react"),i=((e=n)&&"object"==typeof e&&"default"in e&&e.default,require("@licklist/plugins/dist/hooks/Media/useWindowDimensions")),r=require("../constants.js");exports.useResizePageBody=function(){var e=i.useWindowDimensions(),u=e.height,_=e.width,o=t.__read(n.useState(r.DEFAULT_RIGHT_BLOCK_HEIGHT),2),E=o[0],c=o[1],d=t.__read(n.useState({width:r.PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE,height:r.PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE}),2),s=d[0],f=d[1],L=n.useRef(void 0),A=n.useRef(!1),T=t.__read(n.useState(!1),2),a=T[0],D=T[1],I=t.__read(n.useState(!1),2),v=I[0],O=I[1],R=t.__read(n.useState(!1),2),l=R[0],B=R[1],h=t.__read(n.useState(!1),2),C=h[0],H=h[1],w=n.useMemo((function(){if(_>=r.TAB_WIDTH)return{};if(!v&&!C)return{};var e=document.getElementById(r.PAGE_CALENDAR_SELECT_WRAPPER),t=e?e.clientHeight:0,n=document.getElementById(r.PAGE_BODY_WITH_SCROLL);return n&&n.scroll({top:-u,behavior:"smooth"}),{maxHeight:u-r.STANDARD_BODY_PADDING-E-r.STANDARD_HEADER_FOOTER_SIZE-t}}),[u,_,E,a,v,l,C]),S=new ResizeObserver((function(){var e=document.getElementById(r.PAGE_LEFT_BLOCK_CONTAINER_ID);if(e){if(_>=r.TAB_WIDTH&&!A)return A.current=!0,void f({width:e.clientWidth,height:e.clientHeight});A.current=!1,f((function(){var t=e.clientWidth<=e.clientHeight?e.clientWidth:e.clientHeight;return(!L.current||L.current&&t>L.current)&&(L.current=t),{width:e.clientWidth,height:L.current}}))}})),P=n.useMemo((function(){if(_>=r.TAB_WIDTH)return{};if(!v&&!C)return{};var e=.75*(u-r.STANDARD_BODY_PADDING-r.STANDARD_HEADER_FOOTER_SIZE),t=0,n=document.getElementById(r.PAGE_RIGHT_BLOCK_BOTTOM_ID);return n&&(t=r.SEPARATOR_DEFAULT_WIDTH+n.clientHeight),{maxHeight:e-t-r.COLLAPSE_MARGIN}}),[u,_,E,a,v,l,C]);return n.useEffect((function(){var e=function(e){var t=e.detail.height;c(t)};return window.addEventListener(r.RIGHT_BLOCK_RESIZED_EVENT,(function(t){return e(t)})),function(){window.removeEventListener(r.RIGHT_BLOCK_RESIZED_EVENT,(function(t){return e(t)}))}}),[]),n.useEffect((function(){var e=function(){D(!0),O(!1),B(!1),H(!1)};return window.addEventListener(r.RIGHT_BLOCK_EXPAND,e),function(){window.removeEventListener(r.RIGHT_BLOCK_EXPAND,e)}}),[]),n.useEffect((function(){var e=function(){D(!1),O(!0),B(!1),H(!1)};return window.addEventListener(r.RIGHT_BLOCK_EXPANDED,e),function(){window.removeEventListener(r.RIGHT_BLOCK_EXPANDED,e)}}),[]),n.useEffect((function(){var e=function(){D(!1),O(!1),B(!0),H(!1)};return window.addEventListener(r.RIGHT_BLOCK_COLLAPSE,e),function(){window.removeEventListener(r.RIGHT_BLOCK_COLLAPSE,e)}}),[]),n.useEffect((function(){var e=function(){D(!1),O(!1),B(!1),H(!0)};return window.addEventListener(r.RIGHT_BLOCK_COLLAPSED,e),function(){window.removeEventListener(r.RIGHT_BLOCK_COLLAPSED,e)}}),[]),n.useEffect((function(){var e=document.getElementById(r.PAGE_LEFT_BLOCK_CONTAINER_ID);if(e)return S.observe(e),function(){e&&S.unobserve(e)}}),[]),n.useEffect((function(){L.current=void 0}),[_]),{leftBlockStyles:w,rightBlockContentStyles:P,leftBlockContainerSizes:s}};
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("tslib"),r=require("react"),o=(e=r)&&"object"==typeof e&&"default"in e?e.default:e,a=require("react-router-dom"),n=require("../../../static/loader/LoaderIndicator.js"),l=require("react-i18next"),m=require("react-bootstrap");require("../../../static/index.js");var s=require("../../page/components/PageBody/constants.js");require("../../order-process/components/Timer/Timer.js"),require("../../order-process/components/NavigationSteps/NavigationSteps.js");var i=require("../../page/Page.js"),c=require("../../page/components/PageBody/PageBody.js");require("../../page/components/PageHeader/PageHeader.js"),require("../../order-process/components/NavigationFooter/NavigationFooter.js");var u=require("@licklist/plugins/dist/context/payment/PaymentSessionContext"),d=require("../../order-process/components/BookingSummary/components/SummaryTotal/components/SummaryTotalBlock.js"),p=require("../../ryft/RyftPaymentForm.js"),y=require("../../order-process/components/BookingSummary/utils/index.js"),g=require("../../order-process/components/BookingSummary/BookingSummary.js");require("../../order-process/components/PaymentCard/PaymentCard.js"),require("../../order-process/components/BookingSummaryFooter/BookingSummaryFooter.js"),require("../../order-process/components/ErrorModal/ErrorModal.js"),require("../../order-process/components/utils/useCategoryVerification.js"),require("../../order-process/components/CalendarStepsForm/CalendarStepsForm.js");var f=require("./PaymentTimer.js");exports.PaymentPage=function(e){var P=e.onCloseIframePayment,E=e.onFailIframePayment,B=e.data,k=e.isLoading,S=e.bookingSummaryProps,q=e.paymentMetadata,v=t.__rest(e,["onCloseIframePayment","onFailIframePayment","data","isLoading","bookingSummaryProps","paymentMetadata"]),j=l.useTranslation("Design").t,b=a.useLocation().search,x=r.useContext(u.PaymentSessionContext).isPaymentSessionExpired,F=Boolean(new URLSearchParams(b).get("isIframePayment"));if(r.useEffect((function(){F&&P&&window.addEventListener("beforeunload",(function(){P()}))}),[]),r.useEffect((function(){x&&F&&E&&E()}),[x]),k)return o.createElement(n.LoaderIndicator,{isLoaded:!1});if(null===B)return o.createElement(i.Page,null,o.createElement(c.PageBody,{leftBlock:o.createElement(c.PageBody.LeftBlock,null,o.createElement("div",{className:"d-flex h-100 w-100 justify-content-center align-items-center flex-column"},o.createElement("h6",null,j("linkNotActiveOrExpired")),o.createElement(m.Col,{xs:12,md:3},o.createElement(m.Button,{className:"mt-5 w-20",onClick:function(){window.location.href="https://booked.it/"}},j("backToSite")))))}));var T=y.cartSumByOrderProducts((null==S?void 0:S.formValues)&&Object.values(null==S?void 0:S.formValues)),C=T>(null==B?void 0:B.amount);return o.createElement(i.Page,{className:"payment_link"},o.createElement(c.PageBody,{id:s.PAYMENT_LINK_PAGE_BODY,leftBlock:o.createElement(c.PageBody.LeftBlock,null,o.createElement("div",{className:"d-flex align-items-center mb-5"},o.createElement(f.PaymentTimer,null)),o.createElement(p.RyftPaymentForm,t.__assign({},v))),rightBlock:o.createElement(c.PageBody.RightBlock,null,o.createElement(g.BookingSummary,t.__assign({},S,{isPaymentPage:!0,headerComponent:o.createElement(d.SummaryTotalBlock,{amount:q?q.total:T+((null==S?void 0:S.transactionFee)||0)}),footer:o.createElement("div",{className:"d-flex flex-column justify-content-between"},q?o.createElement(o.Fragment,null,o.createElement(d.SummaryTotalBlock,{label:j("total"),amount:q.total||0}),o.createElement(d.SummaryTotalBlock,{label:j("paidSum"),amount:q.paid||0}),o.createElement(d.SummaryTotalBlock,{label:j("remaining"),amount:q.total-q.paid||0})):o.createElement(o.Fragment,null,C&&o.createElement(d.SummaryTotalBlock,{label:j("total"),amount:T+((null==S?void 0:S.transactionFee)||0)}),o.createElement(d.SummaryTotalBlock,{label:j(C?"totalWithDiscount":"total"),amount:(null==B?void 0:B.amount)+((null==S?void 0:S.transactionFee)||0)})))})))}))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("tslib"),r=require("react"),o=(e=r)&&"object"==typeof e&&"default"in e?e.default:e,a=require("react-router-dom"),n=require("../../../static/loader/LoaderIndicator.js"),l=require("react-i18next"),m=require("react-bootstrap");require("../../../static/index.js");var s=require("../../page/components/PageBody/constants.js");require("../../order-process/components/Timer/Timer.js"),require("../../order-process/components/NavigationSteps/NavigationSteps.js");var i=require("../../page/Page.js"),c=require("../../page/components/PageBody/PageBody.js");require("../../page/components/PageHeader/PageHeader.js"),require("../../order-process/components/NavigationFooter/NavigationFooter.js");var u=require("@licklist/plugins/dist/context/payment/PaymentSessionContext"),d=require("../../order-process/components/BookingSummary/components/SummaryTotal/components/SummaryTotalBlock.js"),p=require("../../ryft/RyftPaymentForm.js"),y=require("../../order-process/components/BookingSummary/utils/index.js"),g=require("../../order-process/components/BookingSummary/BookingSummary.js");require("../../order-process/components/PaymentCard/PaymentCard.js"),require("../../order-process/components/BookingSummaryFooter/BookingSummaryFooter.js"),require("../../order-process/components/ErrorModal/ErrorModal.js"),require("../../order-process/components/utils/useCategoryVerification.js"),require("../../order-process/components/CalendarStepsForm/CalendarStepsForm.js");var f=require("./PaymentTimer.js");exports.PaymentPage=function(e){var P=e.onCloseIframePayment,E=e.onFailIframePayment,B=e.data,S=e.isLoading,k=e.bookingSummaryProps,q=e.paymentMetadata,v=t.__rest(e,["onCloseIframePayment","onFailIframePayment","data","isLoading","bookingSummaryProps","paymentMetadata"]),j=l.useTranslation("Design").t,b=a.useLocation().search,x=r.useContext(u.PaymentSessionContext).isPaymentSessionExpired,F=Boolean(new URLSearchParams(b).get("isIframePayment"));if(r.useEffect((function(){F&&P&&window.addEventListener("beforeunload",(function(){P()}))}),[]),r.useEffect((function(){x&&F&&E&&E()}),[x]),S)return o.createElement(n.LoaderIndicator,{isLoaded:!1});if(null===B)return o.createElement(i.Page,null,o.createElement(c.PageBody,{leftBlock:o.createElement(c.PageBody.LeftBlock,null,o.createElement("div",{className:"d-flex h-100 w-100 justify-content-center align-items-center flex-column"},o.createElement("h6",null,j("linkNotActiveOrExpired")),o.createElement(m.Col,{xs:12,md:3},o.createElement(m.Button,{className:"mt-5 w-20",onClick:function(){window.location.href="https://booked.it/"}},j("backToSite")))))}));var T=y.cartSumByOrderProducts((null==k?void 0:k.formValues)&&Object.values(null==k?void 0:k.formValues)),C=T>(null==B?void 0:B.amount);return o.createElement(i.Page,{className:"payment_link"},o.createElement(c.PageBody,{id:s.PAGE_BODY_WITH_SCROLL,leftBlock:o.createElement(c.PageBody.LeftBlock,null,o.createElement("div",{className:"d-flex align-items-center mb-5"},o.createElement(f.PaymentTimer,null)),o.createElement(p.RyftPaymentForm,t.__assign({},v))),rightBlock:o.createElement(c.PageBody.RightBlock,null,o.createElement(g.BookingSummary,t.__assign({},k,{isPaymentPage:!0,headerComponent:o.createElement(d.SummaryTotalBlock,{amount:q?q.total:T+((null==k?void 0:k.transactionFee)||0)}),footer:o.createElement("div",{className:"d-flex flex-column justify-content-between"},q?o.createElement(o.Fragment,null,o.createElement(d.SummaryTotalBlock,{label:j("total"),amount:q.total||0}),o.createElement(d.SummaryTotalBlock,{label:j("paidSum"),amount:q.paid||0}),o.createElement(d.SummaryTotalBlock,{label:j("remaining"),amount:q.total-q.paid||0})):o.createElement(o.Fragment,null,C&&o.createElement(d.SummaryTotalBlock,{label:j("total"),amount:T+((null==k?void 0:k.transactionFee)||0)}),o.createElement(d.SummaryTotalBlock,{label:j(C?"totalWithDiscount":"total"),amount:(null==B?void 0:B.amount)+((null==k?void 0:k.transactionFee)||0)})))})))}))};
@@ -9,6 +9,7 @@ export interface ProductCategoryControlValues extends FormValues {
9
9
  name: string;
10
10
  minSubItems: number | null;
11
11
  maxSubItems: number | null;
12
+ overallQuantity?: number | null;
12
13
  quantityType: QuantityType;
13
14
  type: CategoryType;
14
15
  isTimeRelated: boolean;
@@ -1 +1 @@
1
- {"version":3,"file":"ProductCategoryControl.d.ts","sourceRoot":"","sources":["../../../src/product-set/product-category/ProductCategoryControl.tsx"],"names":[],"mappings":";AAKA,OAAO,EAAE,UAAU,EAAE,MAAM,8DAA8D,CAAC;AAE1F,OAAO,EACL,YAAY,EACZ,YAAY,EAKb,MAAM,kEAAkE,CAAC;AAC1E,OAAO,EAAE,IAAI,EAAE,MAAM,wDAAwD,CAAC;AAG9E,OAAO,EAAE,gBAAgB,EAAmB,MAAM,UAAU,CAAC;AAI7D,MAAM,WAAW,4BAA6B,SAAQ,UAAU;IAC9D,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,YAAY,EAAE,YAAY,CAAC;IAC3B,IAAI,EAAE,YAAY,CAAC;IACnB,aAAa,EAAE,OAAO,CAAC;IACvB,eAAe,EAAE,OAAO,CAAC;IACzB,SAAS,EAAE,OAAO,CAAC;IACnB,aAAa,EAAE,OAAO,CAAC;IACvB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,oBAAoB,EAAE,OAAO,CAAC;IAC9B,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,MAAM,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC;IACpB,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;CACrB;AAED,MAAM,WAAW,2BAA4B,SAAQ,gBAAgB;IACnE,SAAS,EAAE,OAAO,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IAErB,oBAAoB,EAAE,CAAC,IAAI,EAAE,GAAG,KAAK,IAAI,CAAC;IAC1C,SAAS,EAAE,MAAM,CAAC;IAClB,oBAAoB,EAAE,MAAM,CAAC;IAC7B,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAQD,wBAAgB,sBAAsB,CAAC,EACrC,SAAS,EACT,YAAY,EACZ,oBAAoB,EACpB,oBAAoB,EACpB,SAAS,EACT,UAAkB,GACnB,EAAE,2BAA2B,eAue7B"}
1
+ {"version":3,"file":"ProductCategoryControl.d.ts","sourceRoot":"","sources":["../../../src/product-set/product-category/ProductCategoryControl.tsx"],"names":[],"mappings":";AAKA,OAAO,EAAE,UAAU,EAAE,MAAM,8DAA8D,CAAC;AAE1F,OAAO,EACL,YAAY,EACZ,YAAY,EAKb,MAAM,kEAAkE,CAAC;AAC1E,OAAO,EAAE,IAAI,EAAE,MAAM,wDAAwD,CAAC;AAG9E,OAAO,EAAE,gBAAgB,EAAmB,MAAM,UAAU,CAAC;AAI7D,MAAM,WAAW,4BAA6B,SAAQ,UAAU;IAC9D,EAAE,EAAE,MAAM,CAAC;IACX,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,WAAW,EAAE,MAAM,GAAG,IAAI,CAAC;IAC3B,eAAe,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAChC,YAAY,EAAE,YAAY,CAAC;IAC3B,IAAI,EAAE,YAAY,CAAC;IACnB,aAAa,EAAE,OAAO,CAAC;IACvB,eAAe,EAAE,OAAO,CAAC;IACzB,SAAS,EAAE,OAAO,CAAC;IACnB,aAAa,EAAE,OAAO,CAAC;IACvB,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B,oBAAoB,EAAE,OAAO,CAAC;IAC9B,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,MAAM,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC;IACpB,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;CACrB;AAED,MAAM,WAAW,2BAA4B,SAAQ,gBAAgB;IACnE,SAAS,EAAE,OAAO,CAAC;IACnB,YAAY,EAAE,MAAM,CAAC;IAErB,oBAAoB,EAAE,CAAC,IAAI,EAAE,GAAG,KAAK,IAAI,CAAC;IAC1C,SAAS,EAAE,MAAM,CAAC;IAClB,oBAAoB,EAAE,MAAM,CAAC;IAC7B,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAQD,wBAAgB,sBAAsB,CAAC,EACrC,SAAS,EACT,YAAY,EACZ,oBAAoB,EACpB,oBAAoB,EACpB,SAAS,EACT,UAAkB,GACnB,EAAE,2BAA2B,eAoiB7B"}
@@ -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("tslib"),n=require("react"),a=e(n),r=require("react-i18next"),o=require("react-bootstrap"),l=require("react-hook-form"),c=e(require("@licklist/plugins/dist/services/Form/HookFormService")),m=require("@react-aria/utils"),i=require("../../static/switch/Switch.js"),u=require("../../static/switch/BooleanSwitch.js"),s=require("../../assets/dashboard/increment.svg.js");require("../../static/index.js");var d=require("../form/context.js"),E=require("@licklist/core/dist/DataMapper/Product/ProductCategoryDataMapper"),p=[E.CATEGORY_TYPE_TICKETS,E.CATEGORY_TYPE_FIXED_DURATION,E.CATEGORY_TYPE_GAME];exports.ProductCategoryControl=function(e){var v,I,C,b,f=e.isLoading,h=e.categoryName,g=e.onCategoryNameChange,F=e.productCategoryIndex,x=e.stepIndex,y=e.isOverride,T=void 0!==y&&y,S=l.useFormContext(),k=S.control,G=S.formState.errors,N=S.register,w=S.clearErrors,_=S.setValue,q=S.getValues,R=S.watch,A=S.trigger,P=r.useTranslation("Design").t,Y=t.__read(n.useState(!1),2),D=Y[0],L=Y[1],O="steps.".concat(x,".productCategories.").concat(F),V=l.useWatch({name:O}),B=R("".concat(O,".maxSubItems"))||0,M=R("".concat(O,".minSubItems"))||0,j=R("".concat(O,".allowDeposits")),z=p.includes(V.type),U=null===(b=null===(C=null===(I=null===(v=null==G?void 0:G.steps)||void 0===v?void 0:v[x])||void 0===I?void 0:I.productCategories)||void 0===C?void 0:C[F])||void 0===b?void 0:b.products,H=m.useId(),K=m.useId(),X=m.useId(),Q=m.useId(),W=m.useId(),J=m.useId(),Z=m.useId(),$=m.useId(),ee=m.useId(),te=m.useId(),ne=m.useId(),ae=n.useContext(d.ProductSetLoadingContext),re=ae.providerHasBookingManagement,oe=ae.zones,le=void 0===oe?[]:oe,ce=n.useCallback((function(){return L((function(e){return!e}))}),[]);n.useEffect((function(){A("".concat(O,".maxSubItems"))}),[M,O]),n.useEffect((function(){A("".concat(O,".minSubItems"))}),[B,O]);var me=V.type===E.CATEGORY_TYPE_FIXED_DURATION||V.type===E.CATEGORY_TYPE_GAME;return a.createElement(a.Fragment,null,a.createElement(o.Col,{md:12,xl:!0,className:"p-0"},a.createElement(o.Form.Group,{controlId:K},a.createElement(o.Form.Label,null,P("nameOfTheCategory")),a.createElement(o.Form.Control,t.__assign({},N("".concat(O,".name"),{required:P("Validation:fieldRequired",{attribute:P("name")}),validate:function(){return(null==U?void 0:U.type)===c.manualErrorType&&w("".concat(O,".products")),!0}}),{value:h,onChange:g,isInvalid:c.isInvalid("".concat(O,".name"),G),placeholder:P("name"),disabled:f||T})),a.createElement(o.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(O,".name"),G))),a.createElement(o.Form.Group,{controlId:W},a.createElement(l.Controller,{control:k,name:"".concat(O,".quantityType"),render:function(e){var t=e.field;return a.createElement(o.Form.Group,{className:"d-flex flex-column flex-grow-1 align-items-start"},a.createElement(o.Form.Label,null,P("quantityType")),a.createElement(i.Switch,{name:t.name,options:E.QUANTITY_TYPES.map((function(e){return{key:e,id:e,value:P(e)}})),value:t.value,onChange:t.onChange,disabled:f||T}))}})),a.createElement(o.Row,null,a.createElement(o.Col,{md:6,sm:6,xs:6},a.createElement(o.Form.Group,{controlId:X},a.createElement(o.Form.Label,null,P("minItems")),a.createElement(o.InputGroup,{hasValidation:!0},a.createElement(o.InputGroup.Prepend,{className:"arrow-up-btn",onClick:function(){var e=Number(q("".concat(O,".minSubItems"))||0);_("".concat(O,".minSubItems"),e+1,{shouldValidate:!0})}},a.createElement(o.InputGroup.Text,{className:"py-0 px-3"},a.createElement(s.ReactComponent,null))),a.createElement(l.Controller,{render:function(e){var t=e.field,n=t.value,r=t.onChange,l=t.name,m=t.ref;return a.createElement(o.Form.Control,{ref:m,type:"number",min:0,step:1,value:null===n?"":n,onChange:r,isInvalid:c.isInvalid("".concat(O,".minSubItems"),G),disabled:f||T,name:l})},control:k,name:"".concat(O,".minSubItems"),rules:{min:{value:0,message:P("Validation:fieldMinNumber",{attribute:P("minItems"),min:0})},max:B?{value:Number(B),message:P("Validation:fieldMaxNumber",{attribute:P("minItems"),max:P("maxItems")})}:void 0}}),a.createElement(o.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(O,".minSubItems"),G))))),a.createElement(o.Col,{md:6,sm:6,xs:6},a.createElement(o.Form.Group,{controlId:Q},a.createElement(o.Form.Label,null,P("maxItems")),a.createElement(o.InputGroup,{hasValidation:!0},a.createElement(o.InputGroup.Prepend,{className:"arrow-up-btn",onClick:function(){var e=Number(q("".concat(O,".maxSubItems"))||0);_("".concat(O,".maxSubItems"),e+1,{shouldValidate:!0})}},a.createElement(o.InputGroup.Text,{className:"py-0 px-3"},a.createElement(s.ReactComponent,null))),a.createElement(l.Controller,{render:function(e){var t=e.field,n=t.value,r=t.onChange,l=t.name,m=t.ref;return a.createElement(o.Form.Control,{ref:m,type:"number",step:1,name:l,value:null===n?"":n,onChange:r,isInvalid:c.isInvalid("".concat(O,".maxSubItems"),G),disabled:f||T})},control:k,name:"".concat(O,".maxSubItems"),rules:{min:{value:Number(M),message:P("Validation:fieldGreaterMinNumber",{attribute:P("maxItems"),min:P("minItems")})}}}),a.createElement(o.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(O,".maxSubItems"),G)))))),me&&a.createElement(o.Row,null,a.createElement(o.Col,null,a.createElement(o.Form.Group,{controlId:ee},a.createElement(o.Form.Label,null,P("Design:zone")),a.createElement(l.Controller,{control:k,name:"".concat(O,".zoneId"),render:function(e){var n=e.field;return a.createElement(o.Form.Control,t.__assign({as:"select",disabled:T,isInvalid:c.isInvalid("".concat(O,".zoneId"),G)},n),a.createElement("option",{value:null},P("Design:choose")),le.map((function(e){return a.createElement("option",{key:e.id,value:e.id},e.name)})))},rules:{required:{value:re,message:P("Validation:fieldRequired",{attribute:P("zone")})}}}),a.createElement(o.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(O,".zoneId"),G)))))),a.createElement(o.Col,{md:12,xl:!0,className:"p-0"},a.createElement(o.Form.Group,{controlId:H,className:"custom-checkbox"},a.createElement(o.Form.Check,{custom:!0,type:"checkbox",name:H,disabled:f,id:"check-api"},a.createElement(o.Form.Check.Input,{checked:D,onChange:ce,disabled:T,type:"checkbox"}),a.createElement(o.Form.Check.Label,null,P("showAdvancedOptions")))),a.createElement(o.Collapse,{in:D},a.createElement("div",null,z&&a.createElement(o.Form.Group,{controlId:$,className:"advanced-switch-container"},a.createElement(o.Form.Label,null,P("hasTicket")),a.createElement("div",null,a.createElement(l.Controller,{render:function(e){var t=e.field,n=t.name,r=t.value,o=t.onChange;return a.createElement(u.BooleanSwitch,{name:n,value:Boolean(r),onChange:o,disabled:V.type===E.CATEGORY_TYPE_TICKETS})},control:k,name:"".concat(O,".hasTicket")}))),V.hasTicket&&a.createElement(o.Form.Group,{controlId:Z,className:"advanced-switch-container"},a.createElement(o.Form.Label,null,P("collectUserInfo")),a.createElement("div",null,a.createElement(l.Controller,{render:function(e){var t=e.field,n=t.name,r=t.value,o=t.onChange;return a.createElement(u.BooleanSwitch,{name:n,value:Boolean(r),onChange:o,disabled:f||T})},control:k,name:"".concat(O,".collectUserInfo")}))),!V.hasTicket&&a.createElement(o.Form.Group,{controlId:J,className:"advanced-switch-container"},a.createElement(a.Fragment,null,a.createElement(o.Form.Label,null,P("isTimeRelated")),a.createElement("div",null,a.createElement(l.Controller,{render:function(e){var t=e.field,n=t.name,r=t.value,o=t.onChange;return a.createElement(u.BooleanSwitch,{name:n,value:Boolean(r),onChange:o,disabled:f||T})},control:k,name:"".concat(O,".isTimeRelated")})))),a.createElement(o.Form.Group,{controlId:te,className:"advanced-switch-container"},a.createElement(o.Form.Label,null,P("allowDeposits")),a.createElement("div",null,a.createElement(l.Controller,{render:function(e){var t=e.field,n=t.name,r=t.value,o=t.onChange;return a.createElement(u.BooleanSwitch,{name:n,value:Boolean(r),onChange:o,disabled:f||T})},control:k,name:"".concat(O,".allowDeposits")}))),j&&a.createElement(o.Form.Group,{controlId:ne,className:"deposit-days"},a.createElement(o.Form.Label,null,P("depositDays")),a.createElement(l.Controller,{render:function(e){var t=e.field,n=t.value,r=t.onChange,l=t.name,m=t.ref;return a.createElement(o.Form.Control,{ref:m,type:"number",min:0,step:1,value:n,onChange:r,isInvalid:c.isInvalid("".concat(O,".remainderExpireAfter"),G),disabled:f||T,name:l})},control:k,name:"".concat(O,".remainderExpireAfter")}),a.createElement(o.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(O,".remainderExpireAfter"),G)))))))};
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("tslib"),n=require("react"),a=e(n),r=require("react-i18next"),l=require("react-bootstrap"),o=require("react-hook-form"),c=e(require("@licklist/plugins/dist/services/Form/HookFormService")),m=require("@react-aria/utils"),i=require("../../static/switch/Switch.js"),u=require("../../static/switch/BooleanSwitch.js"),s=require("../../assets/dashboard/increment.svg.js");require("../../static/index.js");var d=require("../form/context.js"),E=require("@licklist/core/dist/DataMapper/Product/ProductCategoryDataMapper"),p=[E.CATEGORY_TYPE_TICKETS,E.CATEGORY_TYPE_FIXED_DURATION,E.CATEGORY_TYPE_GAME];exports.ProductCategoryControl=function(e){var v,I,C,b,f=e.isLoading,g=e.categoryName,h=e.onCategoryNameChange,F=e.productCategoryIndex,y=e.stepIndex,x=e.isOverride,T=void 0!==x&&x,G=o.useFormContext(),k=G.control,N=G.formState.errors,S=G.register,w=G.clearErrors,_=G.setValue,q=G.getValues,R=G.watch,A=G.trigger,P=r.useTranslation("Design").t,D=t.__read(n.useState(!1),2),L=D[0],V=D[1],Y="steps.".concat(y,".productCategories.").concat(F),O=o.useWatch({name:Y}),B=R("".concat(Y,".maxSubItems"))||0,M=R("".concat(Y,".minSubItems"))||0,Q=R("".concat(Y,".allowDeposits")),j=p.includes(O.type),z=null===(b=null===(C=null===(I=null===(v=null==N?void 0:N.steps)||void 0===v?void 0:v[y])||void 0===I?void 0:I.productCategories)||void 0===C?void 0:C[F])||void 0===b?void 0:b.products,U=m.useId(),H=m.useId(),K=m.useId(),X=m.useId(),W=m.useId(),J=m.useId(),Z=m.useId(),$=m.useId(),ee=m.useId(),te=m.useId(),ne=m.useId(),ae=m.useId(),re=n.useContext(d.ProductSetLoadingContext),le=re.providerHasBookingManagement,oe=re.zones,ce=void 0===oe?[]:oe,me=n.useCallback((function(){return V((function(e){return!e}))}),[]);n.useEffect((function(){A("".concat(Y,".maxSubItems"))}),[M,Y]),n.useEffect((function(){A("".concat(Y,".minSubItems"))}),[B,Y]);var ie=O.type===E.CATEGORY_TYPE_FIXED_DURATION||O.type===E.CATEGORY_TYPE_GAME;return a.createElement(a.Fragment,null,a.createElement(l.Col,{md:12,xl:!0,className:"p-0"},a.createElement(l.Form.Group,{controlId:H},a.createElement(l.Form.Label,null,P("nameOfTheCategory")),a.createElement(l.Form.Control,t.__assign({},S("".concat(Y,".name"),{required:P("Validation:fieldRequired",{attribute:P("name")}),validate:function(){return(null==z?void 0:z.type)===c.manualErrorType&&w("".concat(Y,".products")),!0}}),{value:g,onChange:h,isInvalid:c.isInvalid("".concat(Y,".name"),N),placeholder:P("name"),disabled:f||T})),a.createElement(l.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(Y,".name"),N))),a.createElement(l.Form.Group,{controlId:W},a.createElement(o.Controller,{control:k,name:"".concat(Y,".quantityType"),render:function(e){var t=e.field;return a.createElement(l.Form.Group,{className:"d-flex flex-column flex-grow-1 align-items-start"},a.createElement(l.Form.Label,null,P("quantityType")),a.createElement(i.Switch,{name:t.name,options:E.QUANTITY_TYPES.map((function(e){return{key:e,id:e,value:P(e)}})),value:t.value,onChange:t.onChange,disabled:f||T}))}})),a.createElement(l.Row,null,a.createElement(l.Col,{md:6,sm:6,xs:6},a.createElement(l.Form.Group,{controlId:K},a.createElement(l.Form.Label,null,P("minItems")),a.createElement(l.InputGroup,{hasValidation:!0},a.createElement(l.InputGroup.Prepend,{className:"arrow-up-btn",onClick:function(){var e=Number(q("".concat(Y,".minSubItems"))||0);_("".concat(Y,".minSubItems"),e+1,{shouldValidate:!0})}},a.createElement(l.InputGroup.Text,{className:"py-0 px-3"},a.createElement(s.ReactComponent,null))),a.createElement(o.Controller,{render:function(e){var t=e.field,n=t.value,r=t.onChange,o=t.name,m=t.ref;return a.createElement(l.Form.Control,{ref:m,type:"number",min:0,step:1,value:null===n?"":n,onChange:r,isInvalid:c.isInvalid("".concat(Y,".minSubItems"),N),disabled:f||T,name:o})},control:k,name:"".concat(Y,".minSubItems"),rules:{min:{value:0,message:P("Validation:fieldMinNumber",{attribute:P("minItems"),min:0})},max:B?{value:Number(B),message:P("Validation:fieldMaxNumber",{attribute:P("minItems"),max:P("maxItems")})}:void 0}}),a.createElement(l.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(Y,".minSubItems"),N))))),a.createElement(l.Col,{md:6,sm:6,xs:6},a.createElement(l.Form.Group,{controlId:X},a.createElement(l.Form.Label,null,P("maxItems")),a.createElement(l.InputGroup,{hasValidation:!0},a.createElement(l.InputGroup.Prepend,{className:"arrow-up-btn",onClick:function(){var e=Number(q("".concat(Y,".maxSubItems"))||0);_("".concat(Y,".maxSubItems"),e+1,{shouldValidate:!0})}},a.createElement(l.InputGroup.Text,{className:"py-0 px-3"},a.createElement(s.ReactComponent,null))),a.createElement(o.Controller,{render:function(e){var t=e.field,n=t.value,r=t.onChange,o=t.name,m=t.ref;return a.createElement(l.Form.Control,{ref:m,type:"number",step:1,name:o,value:null===n?"":n,onChange:r,isInvalid:c.isInvalid("".concat(Y,".maxSubItems"),N),disabled:f||T})},control:k,name:"".concat(Y,".maxSubItems"),rules:{min:{value:Number(M),message:P("Validation:fieldGreaterMinNumber",{attribute:P("maxItems"),min:P("minItems")})}}}),a.createElement(l.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(Y,".maxSubItems"),N)))))),a.createElement(l.Row,null,a.createElement(l.Col,{md:6,sm:6,xs:6},a.createElement(l.Form.Group,{controlId:te},a.createElement(l.Form.Label,null,P("Design:overallQuantity")),a.createElement(l.InputGroup,{hasValidation:!0},a.createElement(l.InputGroup.Prepend,{className:"arrow-up-btn",onClick:function(){var e=Number(q("".concat(Y,".overallQuantity"))||0);_("".concat(Y,".overallQuantity"),e+1,{shouldValidate:!0})}},a.createElement(l.InputGroup.Text,{className:"py-0 px-3"},a.createElement(s.ReactComponent,null))),a.createElement(o.Controller,{control:k,name:"".concat(Y,".overallQuantity"),render:function(e){var n=e.field;return a.createElement(l.Form.Control,t.__assign({min:0,step:1,type:"number",disabled:T,isInvalid:c.isInvalid("".concat(Y,".overallQuantity"),N)},n))},rules:{min:{value:0,message:P("Validation:fieldMinNumber",{attribute:P("overallQuantity"),min:0})}}}),a.createElement(l.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(Y,".overallQuantity"),N)))))),ie&&a.createElement(a.Fragment,null,a.createElement(l.Row,null,a.createElement(l.Col,null,a.createElement(l.Form.Group,{controlId:ee},a.createElement(l.Form.Label,null,P("Design:zone")),a.createElement(o.Controller,{control:k,name:"".concat(Y,".zoneId"),render:function(e){var n=e.field;return a.createElement(l.Form.Control,t.__assign({as:"select",disabled:T,isInvalid:c.isInvalid("".concat(Y,".zoneId"),N)},n),a.createElement("option",{value:null},P("Design:choose")),ce.map((function(e){return a.createElement("option",{key:e.id,value:e.id},e.name)})))},rules:{required:{value:le,message:P("Validation:fieldRequired",{attribute:P("zone")})}}}),a.createElement(l.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(Y,".zoneId"),N))))))),a.createElement(l.Col,{md:12,xl:!0,className:"p-0"},a.createElement(l.Form.Group,{controlId:U,className:"custom-checkbox"},a.createElement(l.Form.Check,{custom:!0,type:"checkbox",name:U,disabled:f,id:"check-api"},a.createElement(l.Form.Check.Input,{checked:L,onChange:me,disabled:T,type:"checkbox"}),a.createElement(l.Form.Check.Label,null,P("showAdvancedOptions")))),a.createElement(l.Collapse,{in:L},a.createElement("div",null,j&&a.createElement(l.Form.Group,{controlId:$,className:"advanced-switch-container"},a.createElement(l.Form.Label,null,P("hasTicket")),a.createElement("div",null,a.createElement(o.Controller,{render:function(e){var t=e.field,n=t.name,r=t.value,l=t.onChange;return a.createElement(u.BooleanSwitch,{name:n,value:Boolean(r),onChange:l,disabled:O.type===E.CATEGORY_TYPE_TICKETS})},control:k,name:"".concat(Y,".hasTicket")}))),O.hasTicket&&a.createElement(l.Form.Group,{controlId:Z,className:"advanced-switch-container"},a.createElement(l.Form.Label,null,P("collectUserInfo")),a.createElement("div",null,a.createElement(o.Controller,{render:function(e){var t=e.field,n=t.name,r=t.value,l=t.onChange;return a.createElement(u.BooleanSwitch,{name:n,value:Boolean(r),onChange:l,disabled:f||T})},control:k,name:"".concat(Y,".collectUserInfo")}))),!O.hasTicket&&a.createElement(l.Form.Group,{controlId:J,className:"advanced-switch-container"},a.createElement(a.Fragment,null,a.createElement(l.Form.Label,null,P("isTimeRelated")),a.createElement("div",null,a.createElement(o.Controller,{render:function(e){var t=e.field,n=t.name,r=t.value,l=t.onChange;return a.createElement(u.BooleanSwitch,{name:n,value:Boolean(r),onChange:l,disabled:f||T})},control:k,name:"".concat(Y,".isTimeRelated")})))),a.createElement(l.Form.Group,{controlId:ne,className:"advanced-switch-container"},a.createElement(l.Form.Label,null,P("allowDeposits")),a.createElement("div",null,a.createElement(o.Controller,{render:function(e){var t=e.field,n=t.name,r=t.value,l=t.onChange;return a.createElement(u.BooleanSwitch,{name:n,value:Boolean(r),onChange:l,disabled:f||T})},control:k,name:"".concat(Y,".allowDeposits")}))),Q&&a.createElement(l.Form.Group,{controlId:ae,className:"deposit-days"},a.createElement(l.Form.Label,null,P("depositDays")),a.createElement(o.Controller,{render:function(e){var t=e.field,n=t.value,r=t.onChange,o=t.name,m=t.ref;return a.createElement(l.Form.Control,{ref:m,type:"number",min:0,step:1,value:n,onChange:r,isInvalid:c.isInvalid("".concat(Y,".remainderExpireAfter"),N),disabled:f||T,name:o})},control:k,name:"".concat(Y,".remainderExpireAfter")}),a.createElement(l.Form.Control.Feedback,{type:"invalid"},c.getErrors("".concat(Y,".remainderExpireAfter"),N)))))))};
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("react"),a=(e=t)&&"object"==typeof e&&"default"in e?e.default:e,r=require("react-i18next"),n=require("react-bootstrap"),l=require("./constants/index.js");exports.ManualDatePicker=function(e){var t=e.isDisabled,o=e.day,i=e.setDay,u=e.month,c=e.setMonth,s=e.year,m=e.setYear,d=e.isRequred,v=void 0!==d&&d,p=r.useTranslation(["Validation","Design"]).t;return a.createElement(a.Fragment,null,a.createElement("div",{className:"custom-date-field-picker mr-4"},a.createElement(n.Form.Group,null,a.createElement(n.Form.Control,{value:o,as:"select",isInvalid:v&&!o,onChange:function(e){var t=e.target.value;i(t?Number(t):void 0)},disabled:t},a.createElement("option",{value:""},p("Design:dayShort")),l.DAYS_ARRAY.map((function(e){return a.createElement("option",{key:e,value:e},e)}))))),a.createElement("div",{className:"custom-date-field-picker mr-4"},a.createElement(n.Form.Group,null,a.createElement(n.Form.Control,{value:u,as:"select",isInvalid:v&&!u,onChange:function(e){var t=e.target.value;return c(t?Number(t):void 0)},disabled:t},a.createElement("option",{value:""},p("Design:monthShort")),l.MONTHS_ARRAY.map((function(e){return a.createElement("option",{key:e,value:e},e)}))))),a.createElement("div",{className:"custom-date-field-picker"},a.createElement(n.Form.Group,null,a.createElement(n.Form.Control,{value:s,as:"select",isInvalid:v&&!s,onChange:function(e){var t=e.target.value;return m(t?Number(t):void 0)},disabled:t},a.createElement("option",{value:""},p("Design:yearShort")),l.YEARS_ARRAY.map((function(e){return a.createElement("option",{key:e,value:e},e)}))))))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e,t=require("react"),a=(e=t)&&"object"==typeof e&&"default"in e?e.default:e,r=require("react-i18next"),n=require("react-bootstrap"),l=require("./constants/index.js");exports.ManualDatePicker=function(e){var t=e.isDisabled,o=e.day,i=e.setDay,u=e.month,c=e.setMonth,s=e.year,m=e.setYear,d=e.isRequred,v=void 0!==d&&d,p=r.useTranslation(["Validation","Design"]).t;return a.createElement(a.Fragment,null,a.createElement("div",{className:"custom-date-field-picker mr-4"},a.createElement(n.Form.Group,null,a.createElement(n.Form.Control,{value:o,as:"select",isInvalid:v&&!o,onChange:function(e){var t=e.target.value;i(t?Number(t):void 0)},disabled:t},a.createElement("option",{value:""},p("Design:dayShort")),l.DAYS_ARRAY.map((function(e){return a.createElement("option",{key:e,value:e},e)}))))),a.createElement("div",{className:"custom-date-field-picker mr-4"},a.createElement(n.Form.Group,null,a.createElement(n.Form.Control,{value:u,as:"select",isInvalid:v&&!u,onChange:function(e){var t=e.target.value;return c(t?Number(t):void 0)},disabled:t},a.createElement("option",{value:""},p("Design:monthShort")),l.MONTHS_ARRAY.map((function(e){return a.createElement("option",{key:e.key,value:e.value},e.key)}))))),a.createElement("div",{className:"custom-date-field-picker"},a.createElement(n.Form.Group,null,a.createElement(n.Form.Control,{value:s,as:"select",isInvalid:v&&!s,onChange:function(e){var t=e.target.value;return m(t?Number(t):void 0)},disabled:t},a.createElement("option",{value:""},p("Design:yearShort")),l.YEARS_ARRAY.map((function(e){return a.createElement("option",{key:e,value:e},e)}))))))};
@@ -1,4 +1,7 @@
1
1
  export declare const DAYS_ARRAY: number[];
2
- export declare const MONTHS_ARRAY: number[];
2
+ export declare const MONTHS_ARRAY: {
3
+ key: string;
4
+ value: number;
5
+ }[];
3
6
  export declare const YEARS_ARRAY: number[];
4
7
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/static/manual-date-picker/constants/index.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,UAAU,UAA+B,CAAC;AACvD,eAAO,MAAM,YAAY,UAA+B,CAAC;AACzD,eAAO,MAAM,WAAW,UAAuB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/static/manual-date-picker/constants/index.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,UAAU,UAA+B,CAAC;AACvD,eAAO,MAAM,YAAY;;;GAA+B,CAAC;AACzD,eAAO,MAAM,WAAW,UAAuB,CAAC"}
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../utils/index.js"),r=e.generateDatesArray(1,31,1),t=e.generateDatesArray(1,12,1),s=e.generateYearsArray();exports.DAYS_ARRAY=r,exports.MONTHS_ARRAY=t,exports.YEARS_ARRAY=s;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../utils/index.js"),r=e.generateDatesArray(1,31,1),t=e.generateMonthsOptionsArray(),s=e.generateYearsArray();exports.DAYS_ARRAY=r,exports.MONTHS_ARRAY=t,exports.YEARS_ARRAY=s;
@@ -1,4 +1,8 @@
1
1
  export declare const generateDatesArray: (start: number, end: number, step: number) => number[];
2
+ export declare const generateMonthsOptionsArray: () => {
3
+ key: string;
4
+ value: number;
5
+ }[];
2
6
  export declare const generateYearsArray: () => number[];
3
7
  export declare const dateToSqlDate: (day: number, month: number, year: number) => string;
4
8
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/static/manual-date-picker/utils/index.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,kBAAkB,UAAW,MAAM,OAAO,MAAM,QAAQ,MAAM,aAIxE,CAAC;AAEJ,eAAO,MAAM,kBAAkB,gBAQ9B,CAAC;AAEF,eAAO,MAAM,aAAa,QAAS,MAAM,SAAS,MAAM,QAAQ,MAAM,WAUrE,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/static/manual-date-picker/utils/index.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,kBAAkB,UAAW,MAAM,OAAO,MAAM,QAAQ,MAAM,aAIxE,CAAC;AAEJ,eAAO,MAAM,0BAA0B;;;GASnC,CAAC;AAEL,eAAO,MAAM,kBAAkB,gBAQ9B,CAAC;AAEF,eAAO,MAAM,aAAa,QAAS,MAAM,SAAS,MAAM,QAAQ,MAAM,WAUrE,CAAC"}
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.dateToSqlDate=function(r,t,e){var n=function(r){return r<10?"0".concat(r):r};return"".concat(e,"-").concat(n(t),"-").concat(n(r))},exports.generateDatesArray=function(r,t,e){return Array.from({length:(t-r)/e+1},(function(r,t){return 1+t*e}))},exports.generateYearsArray=function(){var r=(new Date).getFullYear()-100;return Array.from({length:100},(function(t,e){return r+e+1})).sort((function(r,t){return t-r}))};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.dateToSqlDate=function(r,t,e){var n=function(r){return r<10?"0".concat(r):r};return"".concat(e,"-").concat(n(t),"-").concat(n(r))},exports.generateDatesArray=function(r,t,e){return Array.from({length:(t-r)/e+1},(function(r,t){return 1+t*e}))},exports.generateMonthsOptionsArray=function(){return Array.from({length:12},(function(r,t){var e=t+1,n=String(e);return e<10&&(n="0".concat(n)),{key:n,value:e}}))},exports.generateYearsArray=function(){var r=(new Date).getFullYear()-100;return Array.from({length:100},(function(t,e){return r+e+1})).sort((function(r,t){return t-r}))};
@@ -1,4 +1,5 @@
1
1
  @import "../snippet-templates/snippetVariables";
2
+ @import "../themes//bookedit/variables";
2
3
 
3
4
  .iframe-event-card {
4
5
  position: relative;
@@ -18,12 +19,27 @@
18
19
  background-size: cover;
19
20
  background-position: center;
20
21
  cursor: pointer;
21
- border: 1px solid transparent;
22
22
  border-radius: 0.5rem;
23
23
  }
24
24
 
25
25
  .card-body {
26
- padding: 0.5rem 0 0.875rem;
26
+ padding: 0.5rem 0 0.875rem 0;
27
+
28
+ @include media-breakpoint-down(sm) {
29
+ padding: 1rem 0;
30
+ }
31
+ }
32
+
33
+ &__info-icon {
34
+ position: absolute;
35
+ right: 1rem;
36
+ top: 1rem;
37
+ background-color: "#ffffff";
38
+ border-radius: 1.5rem;
39
+ padding: 0 0.5rem;
40
+ font-size: 0.75rem;
41
+ font-weight: $white;
42
+ border: 1px solid $black;
27
43
  }
28
44
 
29
45
  &__title {
@@ -33,7 +49,7 @@
33
49
  line-height: 1.25rem;
34
50
  cursor: pointer;
35
51
  margin-bottom: 0.5rem;
36
- font-size: 1.125rem;
52
+ font-size: 0.95rem;
37
53
  }
38
54
 
39
55
  &__label {
@@ -82,7 +98,8 @@
82
98
  color: $snippet-elements-button-color;
83
99
  border: none;
84
100
  background-color: $snippet-elements-button-background-color;
85
- box-shadow: 0 0 0 $input-btn-focus-width $snippet-elements-button-background-color;
101
+ box-shadow: 0 0 0 $input-btn-focus-width
102
+ $snippet-elements-button-background-color;
86
103
  }
87
104
 
88
105
  &:disabled {
@@ -95,14 +112,14 @@
95
112
  &:focus,
96
113
  &.focus {
97
114
  &:not(:disabled) {
98
- opacity: .7;
115
+ opacity: 0.7;
99
116
  }
100
117
  }
101
118
 
102
119
  &:active,
103
120
  &.active {
104
121
  &:not(:disabled) {
105
- opacity: .8;
122
+ opacity: 0.8;
106
123
  }
107
124
  }
108
125
  }
@@ -123,7 +140,7 @@
123
140
  }
124
141
 
125
142
  .card-text {
126
- font-size: 0.875rem;
143
+ font-size: 0.82rem;
127
144
  }
128
145
 
129
146
  &.event-info {
@@ -202,7 +219,6 @@
202
219
 
203
220
  @media (max-width: 576px) {
204
221
  &.list-view {
205
-
206
222
  .card-image {
207
223
  margin-right: 0.5rem;
208
224
  }
@@ -3,7 +3,7 @@
3
3
  display: flex;
4
4
  align-items: center;
5
5
  justify-content: space-between;
6
- padding: 0 0.75rem;
6
+ padding: 0 0.75rem 0 2rem;
7
7
  height: 2rem;
8
8
  width: 100%;
9
9
  font-size: 0.75rem;
@@ -27,4 +27,4 @@
27
27
  color: $blue;
28
28
  }
29
29
  }
30
- }
30
+ }
@@ -57,8 +57,6 @@
57
57
 
58
58
  .payment-booking-summary {
59
59
  transition: $color-transition;
60
- background-color: transparent;
61
- border: 1px solid transparent;
62
60
  border-radius: $iframe-border-radius;
63
61
  font-weight: 400;
64
62
  font-size: 0.875rem;
@@ -21,6 +21,7 @@
21
21
 
22
22
  @include media-breakpoint-down(sm) {
23
23
  height: 100svh;
24
+ min-width: auto;
24
25
  }
25
26
 
26
27
  .header-block {
@@ -13,9 +13,6 @@
13
13
  .left-block {
14
14
  flex: 1;
15
15
  align-items: stretch;
16
- border-radius: 0.5rem;
17
- border-bottom-left-radius: 0;
18
- border-bottom-right-radius: 0;
19
16
  padding: 1rem;
20
17
  background-color: $snippet-page-body-left-block-background-color;
21
18
  border: 0;
@@ -34,7 +31,6 @@
34
31
  display: flex;
35
32
  align-items: flex-start;
36
33
  justify-content: space-between;
37
-
38
34
  .title {
39
35
  color: $snippet-elements-body-color;
40
36
  margin: 0;
@@ -65,7 +61,7 @@
65
61
  overflow-x: hidden;
66
62
  scrollbar-width: thin;
67
63
  .iframe-event-card {
68
- border-bottom: 2px solid $separator-color;
64
+ border-bottom: 1px solid $separator-color;
69
65
  }
70
66
 
71
67
  @include media-breakpoint-down(sm) {
@@ -114,7 +110,7 @@
114
110
  }
115
111
 
116
112
  .collapse {
117
- max-height: calc(100vh - 19rem);
113
+ max-height: calc(100vh - 15rem);
118
114
  transition: none 0s ease 0s;
119
115
 
120
116
  &.show {
@@ -124,7 +120,7 @@
124
120
  }
125
121
 
126
122
  @include media-breakpoint-down(sm) {
127
- max-height: 7.5rem;
123
+ max-height: 100%;
128
124
  }
129
125
  }
130
126
  .collapse-with-people-input {
@@ -150,8 +146,14 @@
150
146
  }
151
147
 
152
148
  .iframe-event-card {
153
- background-color: transparent;
154
- border-color: transparent;
149
+ border: none;
150
+
151
+ .card-image {
152
+ border-radius: 0;
153
+ }
154
+ .card-body {
155
+ padding-left: 1rem;
156
+ }
155
157
  }
156
158
 
157
159
  .price {
@@ -261,3 +263,24 @@
261
263
  }
262
264
  }
263
265
  }
266
+
267
+ .event-list-page-body {
268
+ overflow: auto;
269
+ .left-block {
270
+ .navigation {
271
+ font-size: 1.125rem;
272
+ font-weight: 500;
273
+ padding-bottom: 2.625rem;
274
+ display: flex;
275
+ align-items: flex-start;
276
+ justify-content: space-between;
277
+ margin-top: 0.125rem;
278
+
279
+ .title {
280
+ position: absolute;
281
+ color: $snippet-elements-body-color;
282
+ margin: 0;
283
+ }
284
+ }
285
+ }
286
+ }
@@ -20,55 +20,57 @@ $base-height: 2.5rem;
20
20
  transition: $color-transition;
21
21
  border: 0;
22
22
  }
23
+ }
24
+ }
23
25
 
24
- .button-wrapper {
25
- background-color: $snippet-page-header-steps-close-button-background-color;
26
- height: $base-height;
26
+ .iframe-page {
27
+ .button-wrapper {
28
+ background-color: $snippet-page-header-steps-close-button-background-color;
29
+ height: $base-height;
30
+ width: $base-height;
31
+ border-radius: $base-height;
32
+ transition: $color-transition;
33
+
34
+ .close-button {
35
+ font-size: 1.25rem;
27
36
  width: $base-height;
28
- border-radius: $base-height;
37
+ height: $base-height;
38
+ display: flex;
39
+ align-items: center;
40
+ justify-content: center;
41
+ color: $snippet-page-header-steps-close-button-border-color;
29
42
  transition: $color-transition;
30
43
 
31
- .close-button {
32
- font-size: 1.25rem;
33
- width: $base-height;
34
- height: $base-height;
35
- display: flex;
36
- align-items: center;
37
- justify-content: center;
38
- color: $snippet-page-header-steps-close-button-border-color;
39
- transition: $color-transition;
40
-
41
- &:hover {
42
- cursor: pointer;
43
- }
44
+ &:hover {
45
+ cursor: pointer;
44
46
  }
47
+ }
45
48
 
46
- &.close-button {
47
- margin-left: 1rem;
48
- }
49
+ &.close-button {
50
+ margin-left: 1rem;
51
+ }
49
52
 
50
- .back-button {
51
- font-size: 2rem;
52
- width: $base-height;
53
- height: $base-height;
54
- display: flex;
55
- align-items: center;
56
- justify-content: center;
57
- font-weight: lighter;
58
- color: $snippet-page-header-steps-close-button-border-color;
59
- transition: $color-transition;
53
+ .back-button {
54
+ font-size: 2rem;
55
+ width: $base-height;
56
+ height: $base-height;
57
+ display: flex;
58
+ align-items: center;
59
+ justify-content: center;
60
+ font-weight: lighter;
61
+ color: $snippet-page-header-steps-close-button-border-color;
62
+ transition: $color-transition;
60
63
 
61
- &:hover {
62
- cursor: pointer;
63
- }
64
+ &:hover {
65
+ cursor: pointer;
64
66
  }
67
+ }
65
68
 
66
- &.back-button {
67
- display: flex;
68
- align-items: center;
69
- justify-content: center;
70
- margin-right: 1rem;
71
- }
69
+ &.back-button {
70
+ display: flex;
71
+ align-items: center;
72
+ justify-content: center;
73
+ margin-right: 1rem;
72
74
  }
73
75
  }
74
76
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@licklist/design",
3
- "version": "0.60.0",
3
+ "version": "0.61.1",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "git+ssh://git@bitbucket.org/artelogicsoft/licklist_design.git"
@@ -16,6 +16,7 @@ export function Default() {
16
16
  return (
17
17
  <div>
18
18
  <IframeEventCard
19
+ showMoreInfo
19
20
  imageSrc={
20
21
  showImage
21
22
  ? // eslint-disable-next-line max-len
@@ -29,6 +29,7 @@ interface IframeEventCardProps {
29
29
  titleId?: string;
30
30
  descriptionId?: string;
31
31
  imageClassName?: string;
32
+ showMoreInfo?: boolean;
32
33
  }
33
34
 
34
35
  export function IframeEventCard({
@@ -46,6 +47,7 @@ export function IframeEventCard({
46
47
  titleId,
47
48
  descriptionId,
48
49
  imageClassName,
50
+ showMoreInfo,
49
51
  }: IframeEventCardProps) {
50
52
  const { formatNumber } = useIntl();
51
53
  const { t } = useTranslation("Design");
@@ -70,6 +72,7 @@ export function IframeEventCard({
70
72
  )}
71
73
  onClick={goToDetails ? onClick : undefined}
72
74
  >
75
+ {showMoreInfo && <div className="iframe-event-card__info-icon">i</div>}
73
76
  {imageSrc && (
74
77
  <Card.Img
75
78
  className={imageClassName ?? "card-image"}
@@ -91,12 +94,8 @@ export function IframeEventCard({
91
94
  <div className="icon-wrapper">
92
95
  <CalendarSvg />
93
96
  </div>
94
- <p className="iframe-event-card__bold m-0 list-view-hided">
95
- {date}
96
- </p>
97
- <p className="iframe-event-card__bold m-0 grid-view-hided">
98
- {shortDate}
99
- </p>
97
+ <p className="m-0 list-view-hided">{date}</p>
98
+ <p className="m-0 grid-view-hided">{shortDate}</p>
100
99
  </div>
101
100
  </Card.Text>
102
101
 
@@ -106,7 +105,7 @@ export function IframeEventCard({
106
105
  <div className="icon-wrapper">
107
106
  <ClockSvg />
108
107
  </div>
109
- <p className="iframe-event-card__bold m-0">{type}</p>
108
+ <p className="m-0">{type}</p>
110
109
  </div>
111
110
  </Card.Text>
112
111
  )}
@@ -117,7 +116,7 @@ export function IframeEventCard({
117
116
  <div className="icon-wrapper">
118
117
  <TicketSvg />
119
118
  </div>
120
- <p className="iframe-event-card__bold m-0">
119
+ <p className="m-0">
121
120
  {t("from")}{" "}
122
121
  {formatNumber(cost, { style: "currency", currency: "GBP" })}
123
122
  </p>
@@ -90,7 +90,7 @@ export const NumberInput = forwardRef<HTMLInputElement, NumberInputProps>(
90
90
  type="number"
91
91
  onChange={(e) => handleChangeValue(Number(e.target.value))}
92
92
  value={value}
93
- min={min}
93
+ min={0}
94
94
  max={max}
95
95
  defaultValue={defaultValue}
96
96
  placeholder={placeholder}
@@ -28,7 +28,9 @@ export const LeftBlock = ({
28
28
  {pageTitle && (
29
29
  <>
30
30
  {typeof pageTitle === "string" ? (
31
- <div className="title">{pageTitle}</div>
31
+ <div className="title" id="navigation-title">
32
+ {pageTitle}
33
+ </div>
32
34
  ) : (
33
35
  pageTitle
34
36
  )}
@@ -25,6 +25,6 @@ export const COLLAPSE_MARGIN = 36;
25
25
 
26
26
  export const PAGE_LEFT_BLOCK_CONTAINER_ID = "page-left-block-container";
27
27
  export const PAGE_CALENDAR_SELECT_WRAPPER = "calendar-select-wrapper";
28
- export const PAYMENT_LINK_PAGE_BODY = "payment_link_page_body";
28
+ export const PAGE_BODY_WITH_SCROLL = "page-body-with-scroll";
29
29
 
30
30
  export const PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE = 300;
@@ -16,7 +16,7 @@ import {
16
16
  PAGE_LEFT_BLOCK_CONTAINER_ID,
17
17
  PAGE_LEFT_BLOCK_MAP_DEFAULT_SIZE,
18
18
  PAGE_CALENDAR_SELECT_WRAPPER,
19
- PAYMENT_LINK_PAGE_BODY,
19
+ PAGE_BODY_WITH_SCROLL,
20
20
  } from "../constants";
21
21
  import { ChangeRightBlockHeightEvent } from "../types";
22
22
 
@@ -52,10 +52,10 @@ export const useResizePageBody = () => {
52
52
  ? calenderWrapper.clientHeight
53
53
  : 0;
54
54
 
55
- const paymentLinkPageBody = document.getElementById(PAYMENT_LINK_PAGE_BODY);
55
+ const paymentLinkPageBody = document.getElementById(PAGE_BODY_WITH_SCROLL);
56
56
  if (paymentLinkPageBody) {
57
57
  paymentLinkPageBody.scroll({
58
- top: -rightBlockHeight,
58
+ top: -height,
59
59
  behavior: "smooth",
60
60
  });
61
61
  }
@@ -16,7 +16,7 @@ import { PaymentTimer } from "./PaymentTimer";
16
16
  import { Page, PageBody } from "../../page";
17
17
  import { BookingSummary } from "../../order-process";
18
18
  import { cartSumByOrderProducts } from "../../order-process/components/BookingSummary/utils";
19
- import { PAYMENT_LINK_PAGE_BODY } from "../../page/components/PageBody/constants";
19
+ import { PAGE_BODY_WITH_SCROLL } from "../../page/components/PageBody/constants";
20
20
 
21
21
  export interface PaymentMetadata {
22
22
  total: number;
@@ -126,7 +126,7 @@ export const PaymentPage = ({
126
126
  onCloseButtonClick={isIframePayment ? onGoBack : undefined}
127
127
  /> */}
128
128
  <PageBody
129
- id={PAYMENT_LINK_PAGE_BODY}
129
+ id={PAGE_BODY_WITH_SCROLL}
130
130
  leftBlock={
131
131
  <PageBody.LeftBlock>
132
132
  <div className="d-flex align-items-center mb-5">
@@ -26,6 +26,7 @@ export interface ProductCategoryControlValues extends FormValues {
26
26
  name: string;
27
27
  minSubItems: number | null;
28
28
  maxSubItems: number | null;
29
+ overallQuantity?: number | null;
29
30
  quantityType: QuantityType;
30
31
  type: CategoryType;
31
32
  isTimeRelated: boolean;
@@ -102,6 +103,7 @@ export function ProductCategoryControl({
102
103
  const collectUserInfoId = useId();
103
104
  const hasTicketId = useId();
104
105
  const zoneId = useId();
106
+ const overallQuantityId = useId();
105
107
 
106
108
  const allowDepositsId = useId();
107
109
  const remainderExpireAfterId = useId();
@@ -127,7 +129,7 @@ export function ProductCategoryControl({
127
129
  // eslint-disable-next-line react-hooks/exhaustive-deps
128
130
  }, [maxSubItems, fieldNamePrefix]);
129
131
 
130
- const shouldShowZoneSelect =
132
+ const isZoneCategory =
131
133
  category.type === CATEGORY_TYPE_FIXED_DURATION ||
132
134
  category.type === CATEGORY_TYPE_GAME;
133
135
 
@@ -327,51 +329,111 @@ export function ProductCategoryControl({
327
329
  </Form.Group>
328
330
  </Col>
329
331
  </Row>
330
-
331
- {shouldShowZoneSelect && (
332
- <Row>
333
- <Col>
334
- <Form.Group controlId={zoneId}>
335
- <Form.Label>{t("Design:zone")}</Form.Label>
332
+ <Row>
333
+ <Col md={6} sm={6} xs={6}>
334
+ <Form.Group controlId={overallQuantityId}>
335
+ <Form.Label>{t("Design:overallQuantity")}</Form.Label>
336
+ <InputGroup hasValidation>
337
+ <InputGroup.Prepend
338
+ className="arrow-up-btn"
339
+ onClick={() => {
340
+ const currentOverallCapacity = Number(
341
+ getValues(`${fieldNamePrefix}.overallQuantity`) || 0
342
+ );
343
+ setValue(
344
+ `${fieldNamePrefix}.overallQuantity`,
345
+ currentOverallCapacity + 1,
346
+ { shouldValidate: true }
347
+ );
348
+ }}
349
+ >
350
+ <InputGroup.Text className="py-0 px-3">
351
+ <IncrementIcon />
352
+ </InputGroup.Text>
353
+ </InputGroup.Prepend>
336
354
  <Controller
337
355
  control={control}
338
- name={`${fieldNamePrefix}.zoneId`}
356
+ name={`${fieldNamePrefix}.overallQuantity`}
339
357
  render={({ field }) => (
340
358
  <Form.Control
341
- as="select"
359
+ min={0}
360
+ step={1}
361
+ type="number"
342
362
  disabled={isOverride}
343
363
  isInvalid={HookFormService.isInvalid<ProductSetFormValues>(
344
- `${fieldNamePrefix}.zoneId`,
364
+ `${fieldNamePrefix}.overallQuantity`,
345
365
  errors
346
366
  )}
347
367
  {...field}
348
- >
349
- <option value={null}>{t("Design:choose")}</option>
350
- {zones.map((zone) => (
351
- <option key={zone.id} value={zone.id}>
352
- {zone.name}
353
- </option>
354
- ))}
355
- </Form.Control>
368
+ />
356
369
  )}
357
370
  rules={{
358
- required: {
359
- value: providerHasBookingManagement,
360
- message: t("Validation:fieldRequired", {
361
- attribute: t("zone"),
362
- }),
371
+ min: {
372
+ value: 0,
373
+ message: t("Validation:fieldMinNumber", {
374
+ attribute: t("overallQuantity"),
375
+ min: 0,
376
+ }) as string,
363
377
  },
364
378
  }}
365
379
  />
366
380
  <Form.Control.Feedback type="invalid">
367
381
  {HookFormService.getErrors<ProductSetFormValues>(
368
- `${fieldNamePrefix}.zoneId`,
382
+ `${fieldNamePrefix}.overallQuantity`,
369
383
  errors
370
384
  )}
371
385
  </Form.Control.Feedback>
372
- </Form.Group>
373
- </Col>
374
- </Row>
386
+ </InputGroup>
387
+ </Form.Group>
388
+ </Col>
389
+ </Row>
390
+
391
+ {isZoneCategory && (
392
+ <>
393
+ <Row>
394
+ <Col>
395
+ <Form.Group controlId={zoneId}>
396
+ <Form.Label>{t("Design:zone")}</Form.Label>
397
+ <Controller
398
+ control={control}
399
+ name={`${fieldNamePrefix}.zoneId`}
400
+ render={({ field }) => (
401
+ <Form.Control
402
+ as="select"
403
+ disabled={isOverride}
404
+ isInvalid={HookFormService.isInvalid<ProductSetFormValues>(
405
+ `${fieldNamePrefix}.zoneId`,
406
+ errors
407
+ )}
408
+ {...field}
409
+ >
410
+ <option value={null}>{t("Design:choose")}</option>
411
+ {zones.map((zone) => (
412
+ <option key={zone.id} value={zone.id}>
413
+ {zone.name}
414
+ </option>
415
+ ))}
416
+ </Form.Control>
417
+ )}
418
+ rules={{
419
+ required: {
420
+ value: providerHasBookingManagement,
421
+ message: t("Validation:fieldRequired", {
422
+ attribute: t("zone"),
423
+ }),
424
+ },
425
+ }}
426
+ />
427
+ <Form.Control.Feedback type="invalid">
428
+ {HookFormService.getErrors<ProductSetFormValues>(
429
+ `${fieldNamePrefix}.zoneId`,
430
+ errors
431
+ )}
432
+ </Form.Control.Feedback>
433
+ </Form.Group>
434
+ </Col>
435
+ </Row>
436
+ </>
375
437
  )}
376
438
  </Col>
377
439
 
@@ -61,9 +61,9 @@ export const ManualDatePicker = ({
61
61
  disabled={isDisabled}
62
62
  >
63
63
  <option value="">{t("Design:monthShort")}</option>
64
- {MONTHS_ARRAY.map((key) => (
65
- <option key={key} value={key}>
66
- {key}
64
+ {MONTHS_ARRAY.map((object) => (
65
+ <option key={object.key} value={object.value}>
66
+ {object.key}
67
67
  </option>
68
68
  ))}
69
69
  </Form.Control>
@@ -1,5 +1,9 @@
1
- import { generateDatesArray, generateYearsArray } from "../utils";
1
+ import {
2
+ generateDatesArray,
3
+ generateMonthsOptionsArray,
4
+ generateYearsArray,
5
+ } from "../utils";
2
6
 
3
7
  export const DAYS_ARRAY = generateDatesArray(1, 31, 1);
4
- export const MONTHS_ARRAY = generateDatesArray(1, 12, 1);
8
+ export const MONTHS_ARRAY = generateMonthsOptionsArray();
5
9
  export const YEARS_ARRAY = generateYearsArray();
@@ -4,6 +4,17 @@ export const generateDatesArray = (start: number, end: number, step: number) =>
4
4
  (_, index) => 1 + index * step
5
5
  );
6
6
 
7
+ export const generateMonthsOptionsArray = () =>
8
+ Array.from({ length: 12 }, (_, index) => {
9
+ const value = index + 1;
10
+ let key = String(value);
11
+ if (value < 10) {
12
+ key = `0${key}`;
13
+ }
14
+
15
+ return { key, value };
16
+ });
17
+
7
18
  export const generateYearsArray = () => {
8
19
  const currentYear = new Date().getFullYear();
9
20
  const ageBackYear = currentYear - 100;
@@ -1,4 +1,5 @@
1
1
  @import "../snippet-templates/snippetVariables";
2
+ @import "../themes//bookedit/variables";
2
3
 
3
4
  .iframe-event-card {
4
5
  position: relative;
@@ -18,12 +19,27 @@
18
19
  background-size: cover;
19
20
  background-position: center;
20
21
  cursor: pointer;
21
- border: 1px solid transparent;
22
22
  border-radius: 0.5rem;
23
23
  }
24
24
 
25
25
  .card-body {
26
- padding: 0.5rem 0 0.875rem;
26
+ padding: 0.5rem 0 0.875rem 0;
27
+
28
+ @include media-breakpoint-down(sm) {
29
+ padding: 1rem 0;
30
+ }
31
+ }
32
+
33
+ &__info-icon {
34
+ position: absolute;
35
+ right: 1rem;
36
+ top: 1rem;
37
+ background-color: "#ffffff";
38
+ border-radius: 1.5rem;
39
+ padding: 0 0.5rem;
40
+ font-size: 0.75rem;
41
+ font-weight: $white;
42
+ border: 1px solid $black;
27
43
  }
28
44
 
29
45
  &__title {
@@ -33,7 +49,7 @@
33
49
  line-height: 1.25rem;
34
50
  cursor: pointer;
35
51
  margin-bottom: 0.5rem;
36
- font-size: 1.125rem;
52
+ font-size: 0.95rem;
37
53
  }
38
54
 
39
55
  &__label {
@@ -82,7 +98,8 @@
82
98
  color: $snippet-elements-button-color;
83
99
  border: none;
84
100
  background-color: $snippet-elements-button-background-color;
85
- box-shadow: 0 0 0 $input-btn-focus-width $snippet-elements-button-background-color;
101
+ box-shadow: 0 0 0 $input-btn-focus-width
102
+ $snippet-elements-button-background-color;
86
103
  }
87
104
 
88
105
  &:disabled {
@@ -95,14 +112,14 @@
95
112
  &:focus,
96
113
  &.focus {
97
114
  &:not(:disabled) {
98
- opacity: .7;
115
+ opacity: 0.7;
99
116
  }
100
117
  }
101
118
 
102
119
  &:active,
103
120
  &.active {
104
121
  &:not(:disabled) {
105
- opacity: .8;
122
+ opacity: 0.8;
106
123
  }
107
124
  }
108
125
  }
@@ -123,7 +140,7 @@
123
140
  }
124
141
 
125
142
  .card-text {
126
- font-size: 0.875rem;
143
+ font-size: 0.82rem;
127
144
  }
128
145
 
129
146
  &.event-info {
@@ -202,7 +219,6 @@
202
219
 
203
220
  @media (max-width: 576px) {
204
221
  &.list-view {
205
-
206
222
  .card-image {
207
223
  margin-right: 0.5rem;
208
224
  }
@@ -3,7 +3,7 @@
3
3
  display: flex;
4
4
  align-items: center;
5
5
  justify-content: space-between;
6
- padding: 0 0.75rem;
6
+ padding: 0 0.75rem 0 2rem;
7
7
  height: 2rem;
8
8
  width: 100%;
9
9
  font-size: 0.75rem;
@@ -27,4 +27,4 @@
27
27
  color: $blue;
28
28
  }
29
29
  }
30
- }
30
+ }
@@ -57,8 +57,6 @@
57
57
 
58
58
  .payment-booking-summary {
59
59
  transition: $color-transition;
60
- background-color: transparent;
61
- border: 1px solid transparent;
62
60
  border-radius: $iframe-border-radius;
63
61
  font-weight: 400;
64
62
  font-size: 0.875rem;
@@ -21,6 +21,7 @@
21
21
 
22
22
  @include media-breakpoint-down(sm) {
23
23
  height: 100svh;
24
+ min-width: auto;
24
25
  }
25
26
 
26
27
  .header-block {
@@ -13,9 +13,6 @@
13
13
  .left-block {
14
14
  flex: 1;
15
15
  align-items: stretch;
16
- border-radius: 0.5rem;
17
- border-bottom-left-radius: 0;
18
- border-bottom-right-radius: 0;
19
16
  padding: 1rem;
20
17
  background-color: $snippet-page-body-left-block-background-color;
21
18
  border: 0;
@@ -34,7 +31,6 @@
34
31
  display: flex;
35
32
  align-items: flex-start;
36
33
  justify-content: space-between;
37
-
38
34
  .title {
39
35
  color: $snippet-elements-body-color;
40
36
  margin: 0;
@@ -65,7 +61,7 @@
65
61
  overflow-x: hidden;
66
62
  scrollbar-width: thin;
67
63
  .iframe-event-card {
68
- border-bottom: 2px solid $separator-color;
64
+ border-bottom: 1px solid $separator-color;
69
65
  }
70
66
 
71
67
  @include media-breakpoint-down(sm) {
@@ -114,7 +110,7 @@
114
110
  }
115
111
 
116
112
  .collapse {
117
- max-height: calc(100vh - 19rem);
113
+ max-height: calc(100vh - 15rem);
118
114
  transition: none 0s ease 0s;
119
115
 
120
116
  &.show {
@@ -124,7 +120,7 @@
124
120
  }
125
121
 
126
122
  @include media-breakpoint-down(sm) {
127
- max-height: 7.5rem;
123
+ max-height: 100%;
128
124
  }
129
125
  }
130
126
  .collapse-with-people-input {
@@ -150,8 +146,14 @@
150
146
  }
151
147
 
152
148
  .iframe-event-card {
153
- background-color: transparent;
154
- border-color: transparent;
149
+ border: none;
150
+
151
+ .card-image {
152
+ border-radius: 0;
153
+ }
154
+ .card-body {
155
+ padding-left: 1rem;
156
+ }
155
157
  }
156
158
 
157
159
  .price {
@@ -261,3 +263,24 @@
261
263
  }
262
264
  }
263
265
  }
266
+
267
+ .event-list-page-body {
268
+ overflow: auto;
269
+ .left-block {
270
+ .navigation {
271
+ font-size: 1.125rem;
272
+ font-weight: 500;
273
+ padding-bottom: 2.625rem;
274
+ display: flex;
275
+ align-items: flex-start;
276
+ justify-content: space-between;
277
+ margin-top: 0.125rem;
278
+
279
+ .title {
280
+ position: absolute;
281
+ color: $snippet-elements-body-color;
282
+ margin: 0;
283
+ }
284
+ }
285
+ }
286
+ }
@@ -20,55 +20,57 @@ $base-height: 2.5rem;
20
20
  transition: $color-transition;
21
21
  border: 0;
22
22
  }
23
+ }
24
+ }
23
25
 
24
- .button-wrapper {
25
- background-color: $snippet-page-header-steps-close-button-background-color;
26
- height: $base-height;
26
+ .iframe-page {
27
+ .button-wrapper {
28
+ background-color: $snippet-page-header-steps-close-button-background-color;
29
+ height: $base-height;
30
+ width: $base-height;
31
+ border-radius: $base-height;
32
+ transition: $color-transition;
33
+
34
+ .close-button {
35
+ font-size: 1.25rem;
27
36
  width: $base-height;
28
- border-radius: $base-height;
37
+ height: $base-height;
38
+ display: flex;
39
+ align-items: center;
40
+ justify-content: center;
41
+ color: $snippet-page-header-steps-close-button-border-color;
29
42
  transition: $color-transition;
30
43
 
31
- .close-button {
32
- font-size: 1.25rem;
33
- width: $base-height;
34
- height: $base-height;
35
- display: flex;
36
- align-items: center;
37
- justify-content: center;
38
- color: $snippet-page-header-steps-close-button-border-color;
39
- transition: $color-transition;
40
-
41
- &:hover {
42
- cursor: pointer;
43
- }
44
+ &:hover {
45
+ cursor: pointer;
44
46
  }
47
+ }
45
48
 
46
- &.close-button {
47
- margin-left: 1rem;
48
- }
49
+ &.close-button {
50
+ margin-left: 1rem;
51
+ }
49
52
 
50
- .back-button {
51
- font-size: 2rem;
52
- width: $base-height;
53
- height: $base-height;
54
- display: flex;
55
- align-items: center;
56
- justify-content: center;
57
- font-weight: lighter;
58
- color: $snippet-page-header-steps-close-button-border-color;
59
- transition: $color-transition;
53
+ .back-button {
54
+ font-size: 2rem;
55
+ width: $base-height;
56
+ height: $base-height;
57
+ display: flex;
58
+ align-items: center;
59
+ justify-content: center;
60
+ font-weight: lighter;
61
+ color: $snippet-page-header-steps-close-button-border-color;
62
+ transition: $color-transition;
60
63
 
61
- &:hover {
62
- cursor: pointer;
63
- }
64
+ &:hover {
65
+ cursor: pointer;
64
66
  }
67
+ }
65
68
 
66
- &.back-button {
67
- display: flex;
68
- align-items: center;
69
- justify-content: center;
70
- margin-right: 1rem;
71
- }
69
+ &.back-button {
70
+ display: flex;
71
+ align-items: center;
72
+ justify-content: center;
73
+ margin-right: 1rem;
72
74
  }
73
75
  }
74
76
  }