1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6219],{57768:function(e,t,i){"use strict";var n=i(85893),r=i(25675),a=function(e){var t=e.title,i=e.leftIcon,a=e.disabled,c=e.onClick,l=e.buttonClasses,s=void 0===l?"":l;return(0,n.jsx)("div",{className:"fc-button-ghost ".concat(s),children:(0,n.jsxs)("button",{onClick:c,disabled:a,children:[i&&(0,n.jsx)("div",{className:"fc-button-ghost-icon",children:(0,n.jsx)(r.default,{src:i,width:13,height:13,alt:""})}),t]})})};a.defaultProps={disabled:!1},t.Z=a},23259:function(e,t,i){"use strict";var n=i(85893),r=function(e){var t=e.title,i=e.disabled,r=e.onClick,a=e.buttonStyle,c=e.buttonClasses;return(0,n.jsx)("div",{className:"fc-button-primary ".concat(c),children:(0,n.jsx)("button",{onClick:r,disabled:i,style:a,children:t})})};r.defaultProps={disabled:!1},t.Z=r},57466:function(e,t,i){"use strict";var n=i(85893),r=i(26265),a=i(67294),c=i(25675),l=i(42517),s=i(5152),o=i(19755),d=i.n(o),u=i(61645),h=i(33271);i(49467),i(59699);function m(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function p(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?m(Object(i),!0).forEach((function(t){(0,r.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):m(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var g=(0,s.default)((function(){return i.e(2568).then(i.t.bind(i,12568,23))}),{ssr:!1,loadableGenerated:{webpack:function(){return[12568]},modules:["..\\components\\carousel\\cms-gallery-carousel-action.tsx -> react-owl-carousel"]}}),v={loop:!1,autoplay:!1,mouseDrag:!0,nav:!1,dots:!0,video:!0,merge:!0,autoplayHoverPause:!1,items:1,lazyLoad:!0},x=function(e){(0,l.$G)(["common"]).t;var t=e.item,i=(e.lang,e.section),r=(0,a.useState)(!0),s=r[0],o=r[1],m=t.length>1,x=p(p({},v),{mouseDrag:m}),j=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if(f(),""===t)d()(".cms-gallery_".concat(i," .owl-item.active")).find("video").prop("controls",!0),d()(".cms-gallery_".concat(i," .owl-item.active")).find("video")[0].play(),d()(".cms-gallery_".concat(i," .owl-item.active #video_preview_").concat(e)).hide(),d()(".cms-gallery_".concat(i," .owl-item.active #video_playback_").concat(e)).show();else{d()(".cms-gallery_".concat(i," .owl-item.active #static-widget_").concat(e)).hide();var n=d()(".cms-gallery_".concat(i," .owl-item.active #youtube_data_").concat(e)).attr("data-youtube");d()(".cms-gallery_".concat(i," .owl-item.active #youtube_").concat(e)).prop("src",n),d()(".cms-gallery_".concat(i," .owl-item.active #youtube_preview_").concat(e)).hide(),d()(".cms-gallery_".concat(i," .owl-item.active #youtube_playback_").concat(e)).show();var r=d()(".cms-gallery_".concat(i," .owl-item.active #youtube_").concat(e)).height();d()(".cms-gallery_".concat(i,".owl-carousel")).css("height",r),d()(".cms-gallery_".concat(i," .owl-stage-outer")).css("height",r)}d()(".button_"+e).hide()},f=function(){d()(".gallery-playback").show(),d()(".video-container").hide(),d()("video").each((function(){d()(this).get(0).pause(),d()(this).prop("controls",!1)})),d()(".yt-video").length>0&&d()(".yt-video").each((function(){d()(this)[0].contentWindow.postMessage('{"event":"command","func":"pauseVideo","args":""}',"*")}))};function b(e){f();var t=0;d()(".cms-gallery_".concat(i," .owl-item.active")).each((function(){var e=parseInt(d()(this).height());t=d()(this).find(".youtube-video").length>0?d()(this).find(".youtube-video").height():t>=e?t:e})),d()(".cms-gallery_".concat(i,".owl-carousel")).css("height",t),d()(".cms-gallery_".concat(i," .owl-stage-outer")).css("height",t)}var y=function(e,t){var r,a,l,s,o,d=(e||!1).OpenNewWindow,h=p(p({},e),{Id:"".concat(i,"_").concat(t)});return 1===h.Type?(null===(r=h.PrimaryTagline)||void 0===r?void 0:r.length)>0||(null===(a=h.SecondaryTagline)||void 0===a?void 0:a.length)>0||h.ActionText.length>0?(0,n.jsx)("div",{className:"item",style:{position:"relative"},children:(0,n.jsxs)("a",{target:1==d?"_blank":"_self",href:(null===(l=h.ActionUrl)||void 0===l?void 0:l.length)>0?h.ActionUrl:"#",children:[(0,n.jsx)("img",{src:h.ImageUrl,alt:""}),(0,n.jsx)("div",{className:"static-widget",children:(0,n.jsxs)("div",{className:"static-widget-button-action",children:[(null===(s=h.PrimaryTagline)||void 0===s?void 0:s.length)>0&&(0,n.jsx)("h4",{children:h.PrimaryTagline}),(null===(o=h.SecondaryTagline)||void 0===o?void 0:o.length)>0&&(0,n.jsx)("p",{dangerouslySetInnerHTML:{__html:h.SecondaryTagline}}),h.ActionText.length>0&&(0,n.jsxs)("span",{children:[h.ActionText,"\xa0\xa0\xa0\xa0",(0,n.jsx)("i",{className:"fa fa-chevron-right"})]})]})})]})},h.Id):(0,n.jsx)("div",{className:"item",style:{position:"relative"},children:(0,n.jsx)("img",{src:h.ImageUrl,alt:""})},h.Id):2===h.Type?(0,n.jsxs)("div",{className:"item item-video",children:[(0,n.jsxs)("div",{style:{position:"relative",textAlign:"center"}
1,className:"item-video-container gallery-playback",id:"video_preview_".concat(h.Id),children:[(0,n.jsx)("img",{src:h.ImageUrl,alt:""}),(0,n.jsx)("div",{className:"centered",children:(0,n.jsx)("button",{className:"button_".concat(h.Id," gallery-playback"),onClick:function(){j(h.Id)},children:(0,n.jsx)(c.default,{src:u.Z,width:90,height:90,quality:100})})})]}),(0,n.jsx)("div",{className:"video-container",id:"video_playback_".concat(h.Id),children:(0,n.jsx)("video",{autoPlay:!1,id:"video_".concat(h.Id),preload:"none",poster:h.ImageUrl,children:(0,n.jsx)("source",{src:h.VideoUrl,type:"video/mp4"})})})]},h.Id):3===h.Type?(0,n.jsxs)("div",{className:"youtube-video",style:{position:"relative"},children:[(0,n.jsxs)("div",{className:"youtube-preview",id:"youtube_preview_".concat(h.YoutubeId),children:[(0,n.jsx)("img",{src:h.ImageUrl,alt:""}),(0,n.jsx)("div",{className:"static-widget",id:"static-widget_".concat(h.YoutubeId),children:(0,n.jsx)("div",{className:"centered",children:(0,n.jsx)("button",{className:"button_".concat(h.YoutubeId," gallery-playback"),onClick:function(){j(h.YoutubeId,"Youtube")},children:(0,n.jsx)(c.default,{src:u.Z,width:90,height:90,quality:100})})})})]}),(0,n.jsx)("div",{className:"youtube-playback",id:"youtube_playback_".concat(h.YoutubeId),children:(0,n.jsx)("div",{className:"owl-video-wrapper",id:"youtube_data_".concat(h.YoutubeId),"data-youtube":"https://www.youtube.com/embed/".concat(h.YoutubeId,"?autoplay=1&enablejsapi=1&version=3"),children:(0,n.jsx)("iframe",{src:"",allow:"autoplay",id:"youtube_".concat(h.YoutubeId),className:"yt-video"})})})]},h.YoutubeId):void 0};return(0,n.jsx)(n.Fragment,{children:null!=t&&(0,n.jsx)(n.Fragment,{children:(0,n.jsxs)("div",{className:"slider",style:{position:"relative"},children:[s&&(0,n.jsx)("div",{style:{display:"flex",justifyContent:"center",position:"absolute",width:"100%",height:"100%",backgroundColor:"rgb(255, 255, 255,0.8)",zIndex:100},children:(0,n.jsx)(h.Z,{})}),(0,n.jsx)(g,p(p({onInitialized:function(e){setTimeout((function(){b(),o(!1)}),1500)},onTranslated:function(e){b()},className:"owl-carousel owl-theme cms-gallery_".concat(i)},x),{},{id:"cms_gallery_slider",children:t.length>0&&(0,n.jsx)(n.Fragment,{children:t.map((function(e,t){return(0,n.jsx)(a.Fragment,{children:y(e,t)},t)}))})}))]})})})};t.Z=a.memo(x)},57324:function(e,t,i){"use strict";i.d(t,{Z:function(){return o}});var n=i(85893),r=i(25675),a=i(41664),c=i(42517),l={src:"/_next/static/image/public/images/svg/icons-16-px-arrow-outline-right.ab1513f89d41ef62ba5dd3d13c030729.svg",height:16,width:16},s=i(67294),o=function(e){(0,c.$G)(["common"]).t;var t=e.items;return(0,n.jsx)("div",{className:"fc-breadcrumb",children:(null===t||void 0===t?void 0:t.length)>0&&(0,n.jsx)(n.Fragment,{children:t.map((function(e,i){var c;return(0,n.jsxs)(s.Fragment,{children:[(null===(c=e.link)||void 0===c?void 0:c.length)>0?(0,n.jsx)(n.Fragment,{children:"NONE"!=e.link?(0,n.jsx)(a.default,{href:e.link,passHref:!0,children:(0,n.jsx)("a",{children:e.title})}):(0,n.jsx)("a",{style:{cursor:"default"},children:e.title})}):(0,n.jsx)("span",{children:e.title}),i!==t.length-1&&(0,n.jsx)(r.default,{src:l,width:16,height:16,alt:""})]},i)}))})})}},75204:function(e,t,i){"use strict";i.d(t,{Z:function(){return l}});var n=i(85893),r=i(25675),a=i(67294),c={src:"/_next/static/image/public/images/svg/icons-16-px-check.ba7f52c46def65917594ac9bd0aff2e2.svg",height:16,width:16},l=function(e){var t=e.label,i=e.value,l=e.onChange,s=e.action,o=(0,a.useState)(i),d=o[0],u=o[1];return(0,a.useEffect)((function(){!0===s&&u(!1)}
1),[s]),(0,n.jsxs)("div",{className:"fc-input-checkbox-container",onClick:function(){u((function(e){return!e})),l&&l(!d)},children:[(0,n.jsx)("div",{className:"fc-input-checkbox-control",children:(0,n.jsx)("div",{className:"fc-input-checkbox-control-square ".concat(d?"active":""),children:d&&(0,n.jsx)(r.default,{src:c,width:16,height:16,alt:""})})}),(0,n.jsx)("label",{children:t})]})}},90723:function(e,t,i){"use strict";var n=i(85893),r=i(67294);t.Z=function(e){var t=e.label,i=e.value,a=e.isChecked,c=e.onChange,l=(0,r.useState)(i);l[0],l[1];(0,r.useEffect)((function(){}),[]);return(0,n.jsx)("div",{className:"fc-input-radio",children:(0,n.jsx)("div",{className:"fc-input-radio-control",children:(0,n.jsxs)("div",{className:"fc-input-radio-control-item",onClick:function(){return function(e){c&&c(e)}(i)},children:[(0,n.jsx)("div",{className:"fc-input-radio-control-item-circle ".concat(a?"active":""),children:a&&(0,n.jsx)("div",{className:"fc-input-radio-control-item-circle-inner"})}),(0,n.jsx)("label",{children:t})]})})})}},42298:function(e,t,i){"use strict";i.d(t,{f:function(){return s}});var n=i(26265),r=i(85893),a=(i(67294),i(24561));function c(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function l(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?c(Object(i),!0).forEach((function(t){(0,n.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):c(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var s=function(e){return(0,r.jsx)("div",{className:"cms-loader-placeholder ".concat(e.className),children:(0,r.jsxs)(a.ZP,l(l({height:"500",backgroundColor:"#dadada",foregroundColor:"#fafafa",viewBox:"0 0 300 150"},e),{},{children:[(0,r.jsx)("rect",{x:"0",y:"15",rx:"4",ry:"4",width:"300",height:"10"}),(0,r.jsx)("rect",{x:"0",y:"30",rx:"2",ry:"2",width:"300",height:"150"})]}))})}},2281:function(e,t,i){"use strict";i.r(t),i.d(t,{__N_SSP:function(){return yt},default:function(){return Nt}});var n=i(85893),r=i(67294),a=i(11163),c=i(42517),l=i(86337),s=i(39704),o=(i(72276),i(23259)),d=i(809),u=i.n(d),h=i(26265),m=i(92447),p=i(64121),g=i(11752),v=i(9008),x=i(25675),j=i(7145),f=i.n(j),b=i(12698),y=i(73944),N=i(68641),w=i(46730),_=i(58533),P=i(33271),S={src:"/_next/static/image/public/images/svg/icons-24-px-chevron-left.8c975ee2523e6c3fda605847065aa333.svg",height:24,width:24},k={src:"/_next/static/image/public/images/svg/icons-24-px-chevron-right.bc14c0c0ea2b04afc736d08753a7106d.svg",height:24,width:24},D=i(4247),I=i(57324),C=i(58964),A={src:"/_next/static/image/public/images/svg/icons-24-px-discount.5afc03f55ecddb6110fd699268429c80.svg",height:24,width:24},T={src:"/_next/static/image/public/images/svg/icons-24-px-delivery.922faec0125aee2328112139a33b4984.svg",height:24,width:24},O=function(e){var t=e.item;return(0,n.jsxs)("div",{className:"fc-promotion-label",children:[(0,n.jsxs)("div",{className:"fc-promotion-label-image",children:[(0,n.jsx)("div",{className:"fc-promotion-label-image-bg",children:(0,n.jsx)(x.default,{src:C.Z,width:56,height:56,alt:""})}),(0,n.jsx)("div",{className:"fc-promotion-label-image-icon",children:!0===t.IsDeliveryType?(0,n.jsx)(x.default,{src:T,width:24,height:24,alt:""}):(0,n.jsx)(x.default,{src:A,width:24,height:24,alt:""})})]}),(0,n.jsx)("div",{className:"fc-promotion-label-text",children:(0,n.jsx)("div",{className:"fc-promotion-label-text-title",children:t.Title})})]})},M=i(68264),F=i(6453),L=function(e){var t=e.quantity,i=e.onAddClick,r=e.onSubtractClick,a=e.customClass;return(0,n.jsxs)("div",{className:"fc-quantity-control ".concat(a),children:[(0,n.jsx)("div",{className:"fc-quantity-control-button",onClick:r,children:(0,n.jsx)(x.default,{src:F.Z,width:24,height:24,alt:""})}),(0,n.jsx)("div",{className:"fc-quantity-control-text",children:t}),(0,n.jsx)("div",{className:"fc-quantity-control-button",onClick:i,children:(0,n.jsx)(x.default,{src:M.Z,width:24,height:24,alt:""})})]})},Z=i(16882),R=function(e){(0,c.$G)(["common"]).t;var t=e.item,i=e.webLocale,r="zh-HK"==i.lang?"/":"/".concat(i.lang,"/");return(0,n.jsxs)("a",{href:"".concat(r).concat(t.Slug),className:"fc-today-item-link",children:[(0,n.jsx)("div",{className:"fc-today-item-image",children:(0,n.jsx)("img",{src:t.Thumbnail,alt:t.Title})}),(0,n.jsxs)("div",{className:"fc-today-item-info-container",children:[(0,n.jsx)("div",{className:"fc-today-item-title",children:t.Title}),(0,n.jsx)("div",{className:"fc-today-item-description",children:t.Summary})]})]})},U=(i(49467),i(5152)),E=i(19755),B=i.n(E),H=i(61645),q=i(57580),z=i(85518),Y=(i(50276),function(e){var t=e.image,i=(e.onClick,(0,r.useState)(t)),a=i[0];
1i[1];return(0,n.jsx)(r.Fragment,{children:"MOBILE"!==z.vO.toUpperCase()?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("span",{className:"iiz__btn iiz__hint",children:(0,n.jsx)("a",{className:"button-enlarge",title:"Enlarge",onClick:function(){e.onClick(a)}})}),(0,n.jsx)(q.Z,{src:a,zoomSrc:a,className:"inner-zoom-wrap",zoomType:"hover",zoomPreload:!0,hasSpacer:!0,fullscreenOnMobile:!1,hideHint:!0})]}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("span",{className:"iiz__btn iiz__hint",children:(0,n.jsx)("a",{className:"button-enlarge",title:"Enlarge",onClick:function(){e.onClick(a)}})}),(0,n.jsx)("img",{src:a,alt:""})]})})}),G=i(57314),W=i.n(G);i(4231);function V(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function $(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?V(Object(i),!0).forEach((function(t){(0,h.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):V(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var K=(0,U.default)((function(){return i.e(2568).then(i.t.bind(i,12568,23))}),{ssr:!1,loadableGenerated:{webpack:function(){return[12568]},modules:["..\\components\\carousel\\product-gallery-carousel.tsx -> react-owl-carousel"]}}),Q={loop:!1,autoplay:!1,nav:!0,mouseDrag:!1,touchDrag:!1,pullDrag:!1,video:!0,videoWidth:!1,videoHeight:!1,autoplayHoverPause:!1,items:1,responsive:{0:{items:1,autoplay:!1}}},X={loop:!1,autoplay:!1,margin:10,nav:!0,mouseDrag:!1,touchDrag:!1,pullDrag:!1,responsiveRefreshRate:100,slideBy:4,responsive:{320:{items:3,slideBy:1,autoplay:!1,loop:!1,stagePadding:0},768:{items:5,slideBy:4,autoplay:!1,stagePadding:0}}},J=function(e){(0,c.$G)(["common"]).t;var t=e.item,i=(e.lang,e.goToMedia),a=(0,r.useState)(!1),l=a[0],s=a[1],o=(0,r.useState)(""),d=o[0],u=o[1],h=i;(0,r.useEffect)((function(){var e=!0;return!0===e&&null!=t&&(null===t||void 0===t?void 0:t.length)>0&&s(!0),function(){e=!1}}),[t]),(0,r.useEffect)((function(){return!0===l&&B()(document).on("click","#product_gallery_thumb_slider .owl-item",(function(e){e.preventDefault();var t=B()("#product_gallery_slider"),i=B()(this).index();t.data("owl.carousel").to(i,100,!0)})),function(){!1}}),[l]),(0,r.useEffect)((function(){var e=!0;return null!=h&&!0===e&&m(i.MediaId),function(){e=!1,h=null}}),[h]);var m=function(e){null!=e&&void 0!=e&&(v(),B()('#product_gallery_thumb_slider [data-id="'+e+'"]').click())};var p=function(e){null!=e&&B()("#product_gallery_thumb_slider .owl-item").trigger("to.owl.carousel",e)},g=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";try{if(console.log("type",t),v(),""===t)B()("#product_gallery_slider .owl-item.active").find("video").prop("controls",!0),B()("#product_gallery_slider .owl-item.active").find("video")[0].play(),!0,!1;else{!1,!0,B()(".static-widget_"+e).hide();var i=B()("#product_gallery_slider .owl-item.active .youtube_data_"+e).attr("data-youtube"),n="https://www.youtube.com/embed/"+i;B()("#product_gallery_slider .owl-item.active .youtube_"+e).prop("src",n),B()(".youtube_preview_"+e).hide(),B()(".youtube_playback_"+e).show()}B()(".button_"+e).hide()}catch(r){console.log(r)}},v=function(){B()(".yt-video").length>0&&B()(".yt-video").each((function(){B()(this)[0].contentWindow.postMessage('{"event":"command","func":"pauseVideo","args":""}',"*")})),B()("video").trigger("pause"),B()(".gallery-playback").show()};return(0,n.jsx)(n.Fragment,{children:null!=t&&(null===t||void 0===t?void 0:t.length)>0&&!0===l&&(0,n.jsxs)(n.Fragment,{children:[""!==d&&(0,n.jsx)(W(),{onClose:function(){u("")},image:d,title:""}),(0,n.jsx)("div",{className:"slider",children:(0,n.jsx)(K,$($({onTranslated:function(e){v()},onInitialized:function(e){B()("#product_gallery_slider").find(".owl-item").eq(0).addClass("current")},onChanged:function(e){!function(e){var t=e.item.count,i=e.item.index;i<0?i=t-1:i>t&&(i=0);var n=B()("#product_gallery_thumb_slider");n.find(".owl-item").removeClass("current").eq(i).addClass("current");var r=n.find(".owl-item.active").length-1,a=n.find(".owl-item.active").first().index();i>n.find(".owl-item.active").last().index()&&p(i),i<a&&p(i-r)}(e)},className:"slider-items owl-carousel"},Q),{},{id:"product_gallery_slider",children:t.length>0&&(0,n.jsx)(n.Fragment,{children:t.map((function(e){return function(e){return 1===e.Type?(0,n.jsx)("div",{className:"item",children:(0,n.jsx)("div",{className:"fc-gallery-item-image",style:{position:"relative"},children:(0,n.jsx)(Y,{image:e.ImageUrl,onClick:function(e){u(e)}})})},e.Id):2===e.Type?(0,n.jsx)("div",{className:"item item-video",children:(0,n.jsxs)("div",{style:{position:"relative",textAlign:"center"},children:[(0,n.jsx)("div",{className:"centered",children:(0,n.jsx)("button",{className:"button_".concat(e.Id," gallery-playback featured-player"),onClick:function(){g(e.Id)},children:(0,n.jsx)("img",{src:"/images/svg/play-circle-regular.svg",style:{width:90,height:90},alt:"",width:"90",height:"90"})})}),(0,n.jsx)("div",{className:"video-container",children:(0,n.jsx)("video",{autoPlay:!1,id:"video_".concat(e.Id),preload:"none",poster:e.ImageUrl,children:(0,n.jsx)("source",{src:e.VideoUrl,type:"video/mp4"})})})]})},e.Id):3===e.Type?(0,n.jsxs)("div",{className:"youtube-video",style:{position:"relative"},children:[(0,n.jsxs)("div",{className:"youtube-preview youtube_preview_".concat(e.Id),children:[(0,n.jsx)("div",{className:"fc-gallery-item-image",children:(0,n.jsx)("img",{src:e.ImageUrl,alt:""})}),(0,n.jsx)("div",{className:"static-widget_".concat(e.Id),children:(0,n.jsx)("div",{className:"centered",children:(0,n.jsx)("button",{className:"button_".concat(e.Id," gallery-playback featured-player"),onClick:function(){g(e.Id,"Youtube")},children:(0,n.jsx)("img",{src:"/images/svg/play-circle-regular.svg",style:{width:90,height:90},alt:"",width:"90",height:"90"})})})})]}),(0,n.jsx)("div",{className:"youtube-playback youtube_playback_".concat(e.Id),children:(0,n.jsx)("div",{className:"owl-video-wrapper youtube_data_".concat(e.Id),"data-youtube":"".concat(e.VideoUrl,"?autoplay=0&enablejsapi=1&version=3"),children:(0,n.jsx)("iframe",{src:"",className:"yt-video youtube_".concat(e.Id)})})})]},e.Id):void 0}(e)}))})}))}),(0,n.jsx)("div",{className:"slider-thumb-navigator",children:(0,n.jsx)(K,$($({onInitialized:function(e){B()("#product_gallery_thumb_slider").find(".owl-item").eq(0).addClass("current")},className:"slider-items owl.carousel"},X),{},{id:"product_gallery_thumb_slider",children:t.length>0&&(0,n.jsx)(n.Fragment,{children:t.map((function(e,t){return(0,n.jsx)(r.Fragment,{children:1===e.Type?(0,n.jsx)("div",{className:"item","data-id":e.Id,children:(0,n.jsx)("div",{className:"fc-gallery-item-image",children:(0,n.jsx)("img",{src:e.ImageUrl,alt:""})})},e.Id):(0,n.jsx)("div",{className:"item-video","data-id":e.Id,children:(0,n.jsxs)("div",{style:{position:"relative"},children:[(0,n.jsx)("div",{className:"centered",children:(0,n.jsx)("button",{className:"gallery-playback",children:(0,n.jsx)(x.default,{src:H.Z,width:48,height:48,quality:100})})}),(0,n.jsx)("img",{src:e.ImageUrl,alt:e.ImageUrl})]})},e.Id)},e.Id)}))})}))})]})})},ee=r.memo(J),te=i(66437),ie=i(16573),ne=i(1020),re=i(12834),ae=i(69275),ce=i(46616),le=i(87385),se=i(24561);function oe(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function de(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};
1t%2?oe(Object(i),!0).forEach((function(t){(0,h.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):oe(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var ue=function(e){return(0,n.jsxs)(se.ZP,de(de({speed:2,viewBox:"0 0 1120 550",className:"product-details-placeholder",height:600,backgroundColor:"#d9d9d9",foregroundColor:"#ededed",width:e.width},e),{},{children:[(0,n.jsx)("rect",{x:"20",y:"30",rx:"0",ry:"0",width:"450",height:"400"}),(0,n.jsx)("rect",{x:"20",y:"450",rx:"5",ry:"5",width:"60",height:"60"}),(0,n.jsx)("rect",{x:"90",y:"450",rx:"5",ry:"5",width:"60",height:"60"}),(0,n.jsx)("rect",{x:"160",y:"450",rx:"5",ry:"5",width:"60",height:"60"}),(0,n.jsx)("rect",{x:"230",y:"450",rx:"5",ry:"5",width:"60",height:"60"}),(0,n.jsx)("rect",{x:"510",y:"30",rx:"10",ry:"10",width:"420",height:"28"}),(0,n.jsx)("rect",{x:"510",y:"80",rx:"10",ry:"10",width:"315",height:"26"}),(0,n.jsx)("rect",{x:"510",y:"130",rx:"10",ry:"10",width:"233",height:"24"}),(0,n.jsx)("rect",{x:"510",y:"180",rx:"0",ry:"0",width:"420",height:"200"}),(0,n.jsx)("rect",{x:"510",y:"390",rx:"60",ry:"60",width:"60",height:"60"}),(0,n.jsx)("rect",{x:"590",y:"400",rx:"8",ry:"8",width:"150",height:"40"})]}))},he=function(e){return(0,n.jsxs)(se.ZP,de(de({speed:2,viewBox:"0 0 420 700",className:"mobile-product-details-placeholder",height:700,backgroundColor:"#d9d9d9",foregroundColor:"#ededed",width:e.width},e),{},{children:[(0,n.jsx)("rect",{x:"0",y:"0",rx:"0",ry:"0",width:"420",height:"400"}),(0,n.jsx)("rect",{x:"30",y:"420",rx:"5",ry:"5",width:"80",height:"80"}),(0,n.jsx)("rect",{x:"125",y:"420",rx:"5",ry:"5",width:"80",height:"80"}),(0,n.jsx)("rect",{x:"220",y:"420",rx:"5",ry:"5",width:"80",height:"80"}),(0,n.jsx)("rect",{x:"315",y:"420",rx:"5",ry:"5",width:"80",height:"80"}),(0,n.jsx)("rect",{x:"20",y:"520",rx:"10",ry:"10",width:"380",height:"26"}),(0,n.jsx)("rect",{x:"60",y:"560",rx:"10",ry:"10",width:"315",height:"20"}),(0,n.jsx)("rect",{x:"140",y:"600",rx:"20",ry:"20",width:"20",height:"20"}),(0,n.jsx)("rect",{x:"200",y:"600",rx:"20",ry:"20",width:"20",height:"20"}),(0,n.jsx)("rect",{x:"260",y:"600",rx:"20",ry:"20",width:"20",height:"20"})]}))},me=function(e){return(0,n.jsx)("div",{className:"product-cat-placeholder",children:(0,n.jsxs)(se.ZP,de(de({speed:2,viewBox:"0 0 1200 300",height:300,backgroundColor:"#d9d9d9",foregroundColor:"#ededed",width:e.width},e),{},{children:[(0,n.jsx)("rect",{x:"20",y:"30",rx:"0",ry:"0",width:"140",height:"140"}),(0,n.jsx)("rect",{x:"180",y:"30",rx:"0",ry:"0",width:"140",height:"140"}),(0,n.jsx)("rect",{x:"340",y:"30",rx:"0",ry:"0",width:"140",height:"140"}),(0,n.jsx)("rect",{x:"500",y:"30",rx:"0",ry:"0",width:"140",height:"140"}),(0,n.jsx)("rect",{x:"660",y:"30",rx:"0",ry:"0",width:"140",height:"140"}),(0,n.jsx)("rect",{x:"820",y:"30",rx:"0",ry:"0",width:"140",height:"140"}),(0,n.jsx)("rect",{x:"980",y:"30",rx:"0",ry:"0",width:"140",height:"140"}),(0,n.jsx)("rect",{x:"1140",y:"30",rx:"0",ry:"0",width:"140",height:"140"})]}))})},pe=function(e){return(0,n.jsx)("div",{className:"mobile-product-cat-placeholder",children:(0,n.jsxs)(se.ZP,de(de({speed:2,height:300,viewBox:"0 0 400 300",backgroundColor:"#d9d9d9",foregroundColor:"#ededed",width:e.width},e),{},{children:[(0,n.jsx)("rect",{x:"20",y:"30",rx:"0",ry:"0",width:"165",height:"165"}),(0,n.jsx)("rect",{x:"215",y:"30",rx:"0",ry:"0",width:"165",height:"165"})]}))})},ge=function(){return(0,n.jsxs)("div",{className:"more-content-loader-placeholder",children:[(0,n.jsx)(ve,{}),(0,n.jsx)(xe,{}),(0,n.jsx)(je,{}),(0,n.jsx)(fe,{}),(0,n.jsx)(be,{})]})},ve=function(){return(0,n.jsxs)(se.ZP,{width:600,height:60,backgroundColor:"#ababab",foregroundColor:"#fafafa",children:[(0,n.jsx)("rect",{x:"70",y:"15",rx:"5",ry:"5",width:"450",height:"15"}),(0,n.jsx)("rect",{x:"70",y:"39",rx:"5",ry:"5",width:"260",height:"9"})]})},xe=function(){return(0,n.jsxs)(se.ZP,{width:600,height:60,backgroundColor:"#bfbfbf",foregroundColor:"#fafafa",children:[(0,n.jsx)("rect",{x:"70",y:"15",rx:"5",ry:"5",width:"450",height:"15"}),(0,n.jsx)("rect",{x:"70",y:"39",rx:"5",ry:"5",width:"260",height:"9"})]})},je=function(){return(0,n.jsxs)(se.ZP,{width:600,height:60,backgroundColor:"#dadada",foregroundColor:"#fafafa",children:[(0,n.jsx)("rect",{x:"70",y:"15",rx:"5",ry:"5",width:"450",height:"15"}),(0,n.jsx)("rect",{x:"70",y:"39",rx:"5",ry:"5",width:"260",height:"9"})]})},fe=function(){return(0,n.jsxs)(se.ZP,{width:600,height:60,backgroundColor:"#ececec",foregroundColor:"#fafafa",children:[(0,n.jsx)("rect",{x:"70",y:"15",rx:"5",ry:"5",width:"450",height:"15"}),(0,n.jsx)("rect",{x:"70",y:"39",rx:"5",ry:"5",width:"260",height:"9"})]})},be=function(){return(0,n.jsxs)(se.ZP,{width:500,height:60,backgroundColor:"#f7f7f7",foregroundColor:"#fafafa",children:[(0,n.jsx)("rect",{x:"70",y:"15",rx:"5",ry:"5",width:"450",height:"15"}),(0,n.jsx)("rect",{x:"70",y:"39",rx:"5",ry:"5",width:"260",height:"9"})]})},ye=(0,g.default)().publicRuntimeConfig,Ne=ye.currencySymbol,we=function(e){var t,i=(0,c.$G)(["common"]).t,a=e.item,l=e.webLocale,s=(0,r.useState)(null),o=s[0],d=s[1],u="zh-HK"==l.lang?"/":"/".concat(l.lang,"/");return(0,r.useEffect)((function(){var e=null;if(null!=a.Promotions&&a.Promotions.length>0){var t=a.Promotions.filter((function(e){var t;return!1===e.IsDeliveryType&&(null===(t=e.TeaserForListing)||void 0===t?void 0:t.length)>0&&null!=e.TeaserForListing}));null!=t&&t.length>0&&(e=t[0])}d(e)}
1),[a]),(0,n.jsxs)("a",{href:"".concat(u).concat(a.Slug),className:"fc-product-item-link",children:[(0,n.jsxs)("div",{className:"fc-product-item-image square",children:[(0,n.jsx)("img",{src:a.ImageUrl,alt:""}),((null===(t=a.Labels)||void 0===t?void 0:t.length)>0||!0===a.ShowOutOfStock)&&(0,n.jsxs)("div",{className:"fc-product-item-badge-container",children:[!0===a.ShowOutOfStock&&(0,n.jsx)("div",{className:"fc-product-item-badge fc-product-item-badge-new",style:{backgroundColor:"#DC0000",color:"#fff}"},children:i("product:msg_item_out_of_stock")}),a.Labels.map((function(e){return(0,n.jsx)("div",{className:"fc-product-item-badge fc-product-item-badge-new",style:{backgroundColor:"#".concat(e.bgcolor),color:"#".concat(e.textcolor)},children:e.Name},e.Id)}))]}),null!=o&&null!=(null===o||void 0===o?void 0:o.TeaserForListing)&&(null===o||void 0===o?void 0:o.TeaserForListing.length)>0&&(0,n.jsx)("div",{className:"fc-product-item-promotion-text",children:o.TeaserForListing})]}),(0,n.jsxs)("div",{className:"fc-product-item-info-container related-products",children:[(0,n.jsx)("div",{className:"fc-product-item-name",children:a.Name}),(0,n.jsx)("div",{className:"fc-product-item-price-container",style:{flexDirection:"column"},children:(0,n.jsx)(n.Fragment,{children:a.DiscountMethod!==ye.discountMethod.none&&null!=a.ProPriceFrom&&1==a.DisplayDiscountedPrice?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("div",{className:"fc-product-item-price-red-text",children:[Ne,(0,Z.x)(a.ProPriceFrom<0?0:a.ProPriceFrom)+(a.ProPriceTo>0&&a.ProPriceFrom!==a.ProPriceTo?" - "+Ne+(0,Z.x)(a.ProPriceTo):"")]}),(0,n.jsx)(n.Fragment,{children:a.ProPriceFrom>0&&a.ProPriceTo>0&&(0,n.jsxs)("div",{className:"fc-product-item-price-text",children:[null!=a.PriceFrom&&(0,n.jsxs)("span",{className:"fc-product-item-price-text-strike",children:[Ne,(0,Z.x)(a.PriceFrom)+(a.PriceTo>0&&a.PriceFrom!==a.PriceTo?" - "+Ne+(0,Z.x)(a.PriceTo):"")]}),""!==a.PromotionUp2Label&&null!==a.PromotionUp2Label&&(0,n.jsx)("span",{className:"fc-product-item-price-text-discount-percentage",children:a.PromotionUp2Label})]})})]}):(0,n.jsxs)("div",{className:"fc-product-item-price-red-text",children:[Ne,(0,Z.x)(a.PriceFrom)+(a.PriceTo>0&&a.PriceTo!==a.PriceFrom?" - "+Ne+(0,Z.x)(a.PriceTo):"")]})})})]})]})},_e=i(38135),Pe=i(2283),Se={src:"/_next/static/image/public/images/svg/icons-24-px-star-full.bcb8b79efc389a6b44f9617b326b0531.svg",height:48,width:48},ke={src:"/_next/static/image/public/images/icons-16-px-star-filled.3ff89c0be81d580f68b0366dcfa68203.png",height:20,width:20,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAMAAADz0U65AAAAXVBMVEXAqnS4oG+3oG22oG+1oGy0oGy1n2yzqzC1nmuznmqynWaznmq5o3C3oG23onK0nm62oG+1oG21oGy3om21oGy1n2y0n2u0n2u0n2u0n2u0n2u0n2u0n2u0n2uznmqXmt5iAAAAHXRSTlMAAAAAAAAAAAAAAAUGCAwNDxASFDFYlKq0ub3l+BZuVTAAAABCSURBVHjaBUCFDYAwACsMmLvr/2cSXARKgVy46ZfzR29oK3oXViPWudasESyMc0ZgkLzsXbjE61tKzb8gzjyPceQHeSYDqQXg0yUAAAAASUVORK5CYII="},De={src:"/_next/static/image/public/images/icons-16-px-star-outline.c615bee64860a3e421c587a44bf557fa.png",height:20,width:20,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAA1UlEQVR4nB2PzU4CQRCEq2bYsJigcePPu3k0nkDCyatGr548eDObjQefAMVXUhMMkLAkw3RTy1z666ma7hp+N1MYgNPjAdabbSHE8KhM/6sWQcx5M4GVv/D2HASudAcHPjj4Q9heHAxlziGCIYHpVbocxRhuRYyWOX+fnOVsneAka1W4+7UKYwxjftYjIPBS8rTfr+6Zdmht+aR9LzT/4awe9dTsCD6ArPSyG7Fw+KPC9DhrbqWj0tg3mZ67RnyndTeyLvilb+qcKKS5pbVYWAwVMgiXewspVT0mRyUMAAAAAElFTkSuQmCC"},Ie=function(e){var t=(0,r.useState)([]),i=t[0],a=t[1],c=e.rating;return(0,r.useEffect)((function(){for(var e=[],t=0;t<5;t++)t<c?e.push((0,n.jsx)(x.default,{src:ke,width:20,height:20,alt:""},t)):e.push((0,n.jsx)(x.default,{src:De,width:20,height:20,alt:""},t));a(e)}),[c]),(0,n.jsx)("div",{className:"fc-rating-bar",children:i})},Ce=i(30381),Ae=i.n(Ce),Te=function(e){var t,i=e.item,r=e.onImageClick;return(0,n.jsxs)("div",{className:"fc-review-item",children:[(0,n.jsx)("div",{className:"fc-review-item-rating-container",children:(0,n.jsx)(Ie,{rating:i.Rating})}),(0,n.jsxs)("div",{className:"fc-review-item-comment-container",children:[(0,n.jsx)("div",{className:"fc-review-item-comment",children:i.Description}),(0,n.jsx)("div",{className:"fc-review-item-author",children:i.NickName}),(null===i||void 0===i||null===(t=i.Images)||void 0===t?void 0:t.length)>0&&(0,n.jsx)("div",{className:"fc-review-item-product",children:(0,n.jsx)("ul",{children:null===i||void 0===i?void 0:i.Images.map((function(e,t){return(0,n.jsx)("li",{children:(0,n.jsx)("a",{href:"javascript:;",onClick:function(){r(e)},children:(0,n.jsx)("img",{src:e})})})}))})})]}),(0,n.jsxs)("div",{className:"fc-review-item-date-container",children:[(0,n.jsx)("div",{className:"fc-review-item-author",children:i.NickName}),(0,n.jsx)("div",{className:"fc-review-item-date",children:Ae()(i.SubmitDate).format("YYYY-MM-DD")})]})]})};function Oe(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Me(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};
1t%2?Oe(Object(i),!0).forEach((function(t){(0,h.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Oe(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var Fe,Le=(0,g.default)().publicRuntimeConfig,Ze=Le.productStatus,Re=Le.currencySymbol,Ue=Le.currencySymbolText,Ee=function(e){var t,i,l,d,h,g,j,C=e.pageProps,A=e.isLogin,T=e.publicTokenData,M=e.privateTokenData,F=e.webLocale,U=e.preference,E=e.urlSlug,B=(0,a.useRouter)(),q=(0,c.$G)(["common","product"]).t,z=(0,s.I0)(),Y=(0,_e.X)("_afid",""),G=(0,p.Z)(Y,1)[0],V=(0,r.useState)(1),$=V[0],K=V[1],Q=(0,r.useState)(),X=Q[0],J=Q[1],se=(0,r.useState)([]),oe=se[0],de=se[1],me=(0,r.useState)(0),pe=me[0],ve=me[1],xe=(0,r.useState)(0),je=xe[0],fe=xe[1],be=(0,r.useState)(null),ye=be[0],Ne=be[1],ke=(0,r.useState)(""),De=ke[0],Ie=ke[1],Ce=(0,r.useState)(!1),Ae=Ce[0],Oe=Ce[1],Fe=(0,r.useState)(!0),Ee=Fe[0],Be=Fe[1],He=(0,r.useState)(!1),qe=He[0],ze=He[1],Ye=(0,r.useState)(null),Ge=Ye[0],We=Ye[1],Ve=(0,r.useState)(null),$e=Ve[0],Ke=Ve[1],Qe=(0,r.useState)([]),Xe=Qe[0],Je=Qe[1],et=(0,r.useState)([]),tt=(et[0],et[1]),it=(0,r.useState)([]),nt=it[0],rt=it[1],at=(0,r.useState)([]),ct=at[0],lt=at[1],st=(0,r.useState)(null),ot=st[0],dt=st[1],ut=(0,r.useState)(!1),ht=ut[0],mt=ut[1],pt=(0,r.useState)(null),gt=pt[0],vt=pt[1],xt=(0,r.useState)(null),jt=xt[0],ft=xt[1],bt=(0,r.useState)(null),yt=bt[0],Nt=bt[1],wt=(0,r.useState)(null),_t=wt[0],Pt=wt[1],St=(0,r.useState)(!0),kt=St[0],Dt=St[1],It=(0,r.useState)(null),Ct=It[0],At=It[1],Tt=(0,r.useState)(""),Ot=Tt[0],Mt=Tt[1],Ft=(0,r.useState)(1),Lt=(Ft[0],Ft[1]),Zt=(0,r.useState)(null),Rt=Zt[0],Ut=Zt[1],Et=(0,r.useState)([]),Bt=Et[0],Ht=Et[1],qt=(0,r.useState)({PageNumber:1,TotalPerPage:3,ProductId:0}),zt=qt[0],Yt=qt[1],Gt=(0,r.useState)(!1),Wt=(Gt[0],Gt[1]);(0,r.useEffect)((function(){function e(){return(e=(0,m.Z)(u().mark((function e(){var t,i;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=Me(Me({},U),{ProductId:C.productData.Id,Channel:0}),e.next=4,z((0,b.FF)(T,t));case 4:null!=(i=e.sent)&&""!=i&&Je(i),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(0),console.log(e.t0);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})))).apply(this,arguments)}function t(){return(t=(0,m.Z)(u().mark((function e(){var t,i,n;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=Me(Me({},U),{ProductId:C.productData.Id,Afid:G}),e.next=4,z((0,b.jX)(T,t));case 4:null!=(i=e.sent)&&""!=i&&(n=i.sort((function(){return Math.random()-Math.random()})).slice(0,4),rt(n)),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(0),console.log(e.t0);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})))).apply(this,arguments)}function i(){return(i=(0,m.Z)(u().mark((function e(){var t,i;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=Me(Me({},U),{ProductId:C.productData.Id}),e.next=4,z((0,b.fx)(T,t));case 4:null!=(i=e.sent)&&""!=i&<(i),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(0),console.log(e.t0);case 11:case"end":return e.stop()}}),e,null,[[0,8]])})))).apply(this,arguments)}function n(){return(n=(0,m.Z)(u().mark((function e(){var t,i,n,r;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,Ht([]),Ut(null),t=Me(Me({},U),{Afid:G,Channel:0,Slug:E}),e.next=6,z((0,Pe.v8)(T,t,localStorage.getItem("_deliveryLoc")));case 6:return i=e.sent,We(i.product),n=f()(zt,{ProductId:{$set:i.product.Id}}),Yt(n),e.next=12,z((0,b.mk)(T,n));case 12:r=e.sent,Wt(!0),Ut(r),Ht(null===r||void 0===r?void 0:r.ReviewItems),Lt(r.DataTotalPage),Be(!1),e.next=24;break;case 20:e.prev=20,e.t0=e.catch(0),Be(!1),console.log(e.t0);case 24:case"end":return e.stop()}}),e,null,[[0,20]])})))).apply(this,arguments)}var r=!0;if(!0===r&&null!=T&&null!=T&&(At(null),null!=C.productData)){var a,c,l,s,o;!function(){n.apply(this,arguments)}();var d=[];if((null===(a=C.productData.Categories)||void 0===a?void 0:a.length)>0){var h=C.productData.Categories[0].Name,p=null==C.productData.MenuCategorySlug?"NONE":"/".concat(C.productData.MenuCategorySlug);d=[{title:q("home"),link:"/"},{title:h,link:p},{title:C.productData.Name,link:"/".concat(C.productData.Slug)}]}else d=[{title:q("home"),link:"/"},{title:C.productData.Name,link:"/".concat(C.productData.Slug)}];if(de(d),Ke(C.productData),function(){e.apply(this,arguments)}(),function(){t.apply(this,arguments)}(),function(){i.apply(this,arguments)}(),tt(C.productReviewData),Pt((null===(c=C.productData.Categories)||void 0===c?void 0:c.length)>0?C.productData.Categories[0]:null),(null===(l=C.productData.Attributes)||void 0===l?void 0:l.length)>0||""!=(null===(s=C.productData)||void 0===s?void 0:s.Ingredient)){var g,v,x=[];if(null!=(null===(g=C.productData)||void 0===g?void 0:g.Ingredient)){var j,y={title:q("product:ingredients").toUpperCase(),content:ei(null===(j=C.productData)||void 0===j?void 0:j.Ingredient)};x.push(y)}(null===(v=C.productData.Attributes)||void 0===v?void 0:v.length)>0&&null!=C.productData.Attributes&&C.productData.Attributes.map((function(e){var t={title:e.AttributeName,content:ei(e.Name)};x.push(t)})),dt(x)}var N;N=C.productData.ImageUrlSet,1===(null===(o=C.productData.AvailableUOMs)||void 0===o?void 0:o.length)&&At(C.productData.AvailableUOMs[0]),N.length>0&&ft(N)}return function(){r=!1}}),[C.productData,T,G]);var Vt=(0,r.useCallback)((0,m.Z)(u().mark((function e(){var t,i,n;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,ze(!0),t=f()(zt,{PageNumber:{$set:zt.PageNumber+1}}),Yt(t),e.next=6,z((0,b.mk)(T,t));case 6:i=e.sent,n=Bt.concat(null===i||void 0===i?void 0:i.ReviewItems),Ht(n),ze(!1),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(0),ze(!1);case 15:case"end":return e.stop()}}),e,null,[[0,12]])}))),[T,Bt]);(0,r.useEffect)((function(){var e,t,i=!0;if(!0===i&&null!=$e&&(void 0!=(null===(e=$e.AvailableUOMs)||void 0===e?void 0:e.length)&&1===(null===(t=$e.AvailableUOMs)||void 0===t?void 0:t.length))){var n=$e.AvailableUOMs;K(1),fe(n[0].Price),J(n[0].Id),ve(n[0].Price),Ne(n[0])}return function(){i=!1}}),[$e]);var $t=function(e){var t=1;(t="add"===e?$+1:$-1)<1&&(t=1);var i=t*parseFloat(je);K(t),ve(i)};
1(0,r.useEffect)((function(){""!=De&&Oe(!0)}),[De]);var Kt=function(){var e=(0,m.Z)(u().mark((function e(){var t,i,n,r,a;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t={product_id:C.productData.Id,qty:$,uom_id:X},i=T,!0===A&&null!=M&&(i=M),e.next=5,z((0,y.e1)(t,i,"",U.CultureId,localStorage.getItem("_deliveryLoc")));case 5:n=e.sent,mt(!1),vt(null),null!=n?!0===(null===n||void 0===n?void 0:n.isError)?300===(null===n||void 0===n?void 0:n.errorCode)?(r=null===n||void 0===n?void 0:n.error,mt(!0),vt("".concat(r," ").concat(q("product:msg_error_items_left"),"<br />").concat(q("product:msg_have_add_more_available_qty_to_cart")))):(mt(!0),vt("".concat(q("product:msg_unable_add_cart")))):(a={items:[{id:C.productData.Code,name:C.productData.Name,list_name:"Search Results",brand:C.productData.MerchantName,category:C.productData.Categories[0].Name,variant:null===ye||void 0===ye?void 0:ye.Name,list_position:1,quantity:$,price:(0,Z.x)(pe).toString()}]},Xt(a),Qt("AddToCart")):(mt(!0),vt("".concat(q("product:msg_unable_add_cart"))));case 9:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),Qt=function(e){null!=window.fbq&&window.fbq("track",e)},Xt=function(e){},Jt=function(){var e=(0,m.Z)(u().mark((function e(){var t,i;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t={product_id:C.productData.Id,qty:$,uom_id:X},i=T,!0===A&&(i=M),e.next=5,z((0,y.Wu)(t,i,U.CultureId,localStorage.getItem("_deliveryLoc")));case 5:e.sent;case 7:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),ei=function(e){return null!=e?e.toString():""};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(v.default,{children:[(0,n.jsx)("title",{children:"".concat(C.productData.Name," | Bee Cheng Hiang | Asia's Famous Bakkwa")}),"zh-CH"===B.locale&&(0,n.jsx)("meta",{name:"robots",content:"noindex,nofollow"}),(0,n.jsx)("meta",{name:"description",content:null===C.productData.MetaDescription?"":C.productData.MetaDescription}),(0,n.jsx)("meta",{name:"keywords",content:null===C.productData.MetaKeyword?"":C.productData.MetaKeyword}),(0,n.jsx)("meta",{property:"og:title",content:C.productData.MetaTitle}),(0,n.jsx)("meta",{property:"og:type",content:"website"}),(0,n.jsx)("meta",{property:"og:url",content:"".concat(Le.baseURL).concat(C.productData.Slug)}),(0,n.jsx)("meta",{property:"og:description",content:null===C.productData.MetaDescription?"":C.productData.MetaDescription}),(0,n.jsx)("meta",{property:"og:image",itemprop:"image",content:null===C.productData.ImageUrl?"".concat(Le.baseURL,"images/BCH-sLogo.jpg"):C.productData.ImageUrl}),(0,n.jsx)("meta",{property:"twitter:url",content:"".concat(Le.baseURL).concat(C.productData.Slug)}),(0,n.jsx)("meta",{property:"twitter:title",content:C.productData.MetaTitle}),(0,n.jsx)("meta",{property:"twitter:description",content:null===C.productData.MetaDescription?"":C.productData.MetaDescription}),(0,n.jsx)("meta",{property:"twitter:image",content:null===C.productData.ImageUrl?"".concat(Le.baseURL,"images/BCH-sLogo.jpg"):C.productData.ImageUrl}),(0,n.jsx)("meta",{property:"og:type",content:"product"})]}),"zh-HK"===B.locale&&(0,n.jsxs)("div",{typeof:"schema:Product",children:[(0,n.jsx)("div",{property:"schema:name",content:C.productData.Name}),(0,n.jsx)("div",{property:"schema:description",content:null===C.productData.MetaDescription?C.productData.Name:C.productData.MetaDescription}),(0,n.jsx)("div",{rel:"schema:image",resource:"".concat(null===C.productData.ImageUrl||""===C.productData.ImageUrl?"".concat(Le.baseURL,"images/BCH-sLogo.jpg"):C.productData.ImageUrl)}),(0,n.jsx)("div",{rel:"schema:brand",children:(0,n.jsx)("div",{typeof:"schema:Brand",children:(0,n.jsx)("div",{property:"schema:name",content:C.productData.BrandName})})}),(0,n.jsx)("div",{rel:"schema:offers",children:(0,n.jsxs)("div",{typeof:"schema:Offer",children:[(0,n.jsx)("div",{property:"schema:price",content:"".concat(C.productData.PriceFrom.toFixed(2))}),parseInt(C.productData.Status)===Ze.inActive?(0,n.jsx)("div",{property:"schema:availability",content:"https://schema.org/OutOfStock"}):(0,n.jsx)("div",{property:"schema:availability",content:"https://schema.org/InStock"}),(0,n.jsx)("div",{property:"schema:priceCurrency",content:Ue})]})})]}),!0===Ee&&null===Ge?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(ue,{width:"100%"}),(0,n.jsx)(he,{width:"100%"}),(0,n.jsx)(ge,{})]}):(0,n.jsxs)("div",{className:"product-detail",children:[null!==Ge&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:"fullwidth-container",children:(0,n.jsxs)("div",{className:"container",children:[(0,n.jsx)("div",{className:"breadcrumb-container",children:(0,n.jsx)(I.Z,{items:oe})}),(0,n.jsxs)("div",{className:"product-detail-info-container",children:[(null===jt||void 0===jt?void 0:jt.length)>0&&(0,n.jsx)("div",{className:"product-detail-gallery-container",children:(0,n.jsx)(ee,{item:jt,goToMedia:ye})}),(0,n.jsxs)("div",{className:"product-detail-action-container",children:[(0,n.jsx)("h1",{className:"product-detail-product-name",children:Ge.Name}),(null===(t=Ge.Labels)||void 0===t?void 0:t.length)>0&&(0,n.jsx)("div",{className:"product-detail-product-badge-container",children:Ge.Labels.map((function(e){if(!e.Name.toLowerCase().includes("out of stock"))return(0,n.jsx)("div",{className:"product-item-badge",style:{backgroundColor:"#".concat(e.bgcolor),color:"#".concat(e.textcolor)},children:e.Name},e.Id)}))}),parseInt(Ge.Status)===Ze.Active&&(0,n.jsxs)(n.Fragment,{children:[!0===Ge.CanSellShowPrice?(0,n.jsx)(r.Fragment,{children:Ge.DiscountMethod!==Le.discountMethod.none&&null!=Ge.ProPriceFrom&&1==Ge.DisplayDiscountedPrice?(0,n.jsxs)(r.Fragment,{children:[(0,n.jsxs)("div",{className:"product-detail-product-sale-price",children:[Ge.DiscountMethod!==Le.discountMethod.percentage&&(0,n.jsx)(n.Fragment,{}),Re,(0,Z.x)(Ge.ProPriceFrom<0?0:Ge.ProPriceFrom)+(Ge.ProPriceTo>0&&Ge.ProPriceFrom!==Ge.ProPriceTo?" - "+Re+(0,Z.x)(Ge.ProPriceTo):"")]}),(0,n.jsx)(r.Fragment,{children:1==Ge.DisplayDiscountedPrice?(0,n.jsx)(n.Fragment,{children:Ge.ProPriceFrom>0&&Ge.ProPriceTo>0?(0,n.jsxs)("div",{className:"product-detail-product-price",children:[null!=Ge.PriceFrom&&(0,n.jsx)("span",{className:"product-detail-product-price-text",children:(0,n.jsxs)(n.Fragment,{children:[Re,(0,Z.x)(Ge.PriceFrom)+(Ge.PriceTo>0&&Ge.PriceFrom!==Ge.PriceTo?" - "+Re+(0,Z.x)(Ge.PriceTo):"")]})}),""!==Ge.PromotionUp2Label&&null!==Ge.PromotionUp2Label&&(0,n.jsx)("span",{className:"product-detail-product-discount-percentage",children:Ge.PromotionUp2Label})]}):(0,n.jsx)("div",{style:{marginBottom:10}})}):(0,n.jsx)("div",{style:{marginBottom:10}})})]}):(0,n.jsxs)("div",{className:"product-detail-product-sale-price",style:{marginBottom:15},children:[Re,(0,Z.x)(Ge.PriceFrom)+(Ge.PriceTo>0&&Ge.PriceTo!==Ge.PriceFrom?" - "+Re+(0,Z.x)(Ge.PriceTo):"")]})}):(0,n.jsx)(r.Fragment,{}),(null===(i=Ge.Promotions)||void 0===i?void 0:i.length)>0&&(0,n.jsx)("div",{className:"product-detail-promo-container",children:Ge.Promotions.filter((function(e){return!0===e.IsMatch})).map((function(e){if(!1===e.IsDeliveryType&&null!=(null===e||void 0===e?void 0:e.Title)&&(null===e||void 0===e?void 0:e.Title.length)>0)return(0,n.jsx)(O,{item:e},e.Id)}))}),!0===Ge.CanSellShowAdd2Cart?(0,n.jsx)(n.Fragment,{children:(null===(l=Ge.AvailableUOMs)||void 0===l?void 0:l.length)>0&&(0,n.jsxs)("div",{className:"product-detail-variation-container",children:[(null===(d=Ge.AvailableUOMs)||void 0===d?void 0:d.length)>0&&(0,n.jsx)(n.Fragment,{children:(null===(h=Ge.AvailableUOMs)||void 0===h?void 0:h.length)>1&&(0,n.jsxs)("div",{className:"product-detail-variation-row",style:{flexWrap:"wrap"},children:[(0,n.jsx)("label",{children:q("product:label_select_variation")}),function(e){if(e.length>0)return(0,n.jsx)("ul",{className:"product-detail-variation-option-list",children:e.map((function(e,t){var i=[],r=e.ProPrice>0?e.ProPrice:e.Price;return e.Id===X&&i.push("option-selected"),!0===e.StockAvailable&&(!0===e.FreeSell||e.AvaliableQty>0),(0,n.jsxs)("li",{className:i.join(" "),onClick:function(){!0===e.StockAvailable&&(!0===e.FreeSell||e.AvaliableQty>0)?Dt(!0):Dt(!1),K(1),fe(e.Price),J(e.Id),ve(e.Price),Ne(e)},children:[e.Name,(0,n.jsxs)("div",{className:"tooltips",children:[(0,n.jsx)("div",{className:"triangle"}),(0,n.jsx)("div",{className:"tooltips-container",children:(0,n.jsxs)("span",{children:[Re,(0,Z.x)(r)]})})]})]},e.Id)}))})}(Ge.AvailableUOMs),!0===ht&&null===ye&&(0,n.jsx)(n.Fragment,{children:(0,n.jsx)("div",{className:"error-variance-selection",style:{justifyContent:"center"},children:(0,n.jsx)("span",{children:q("product:msg_please_select_variation")})})})]})}),(0,n.jsxs)("div",{className:"product-detail-variation-row",children:[(0,n.jsx)("label",{children:q("product:label_quantity")}),(0,n.jsx)("div",{className:"product-detail-variation-row-right",children:(0,n.jsx)(L,{quantity:$,onAddClick:function(){return $t("add")},onSubtractClick:function(){return $t("subtract")}})})]}),!0===ht&&null!==ye&&null!=gt&&(0,n.jsxs)("div",{className:"product-detail-variation-row",style:{marginTop:-20},children:[(0,n.jsx)("label",{}),(0,n.jsx)("div",{className:"error-variance-selection",children:(0,n.jsx)("span",{style:{textAlign:"center"},dangerouslySetInnerHTML:{__html:gt}})})]}),(0,n.jsxs)("div",{className:"product-detail-variation-row",children:[(0,n.jsx)("label",{children:"\xa0"}),null!=Ct?(0,n.jsx)(n.Fragment,{children:!0===Ct.StockAvailable&&(!0===Ct.FreeSell||Ct.AvaliableQty>0)?(0,n.jsxs)("div",{children:[(0,n.jsx)(o.Z,{title:q("product:btn_add_to_cart"),onClick:function(){pe>0&&null!=X?(Kt(),mt(!1)):mt(!0)}}),(0,n.jsxs)("div",{className:"product-detail-add-buy-later",children:[(0,n.jsx)(x.default,{src:D.Z,width:20,height:20,alt:""}),(0,n.jsx)("a",{onClick:function(){null!=X?(mt(!1),Jt()):mt(!0)},children:q("product:add_to_buy_later")})]})]}):(0,n.jsx)("div",{children:(0,n.jsx)(o.Z,{disabled:!0,title:q("product:msg_item_out_of_stock"),onClick:function(){}})})}):(0,n.jsx)(n.Fragment,{children:!0===kt?(0,n.jsxs)("div",{children:[(0,n.jsx)(o.Z,{title:q("product:btn_add_to_cart"),onClick:function(){pe>0&&null!=X?(Kt(),mt(!1)):mt(!0)}}),(0,n.jsxs)("div",{className:"product-detail-add-buy-later",children:[(0,n.jsx)(x.default,{src:D.Z,width:20,height:20,alt:""}),(0,n.jsx)("a",{onClick:function(){null!=X?(mt(!1),Jt()):mt(!0)},children:q("product:add_to_buy_later")})]})]}):(0,n.jsx)("div",{children:(0,n.jsx)(o.Z,{disabled:!0,title:q("product:msg_item_out_of_stock"),onClick:function(){}})})})]}),(0,n.jsxs)("div",{className:"product-detail-variation-row social-share",style:{marginTop:-10},children:[(0,n.jsx)("label",{}),(0,n.jsx)("div",{className:"product-detail-variation-row-right",children:(0,n.jsxs)("div",{className:"product-detail-variation-row-social-container",children:[(0,n.jsxs)("label",{style:{width:"auto",marginRight:5},children:[q("product:label_share"),":"]}),(0,n.jsxs)("div",{children:[(0,n.jsx)(ie.Z,{url:"".concat(Le.baseURL).concat(Ge.Slug),children:(0,n.jsx)(ne.Z,{size:32,round:!0})}),(0,n.jsx)(re.Z,{url:"".concat(Le.baseURL).concat(Ge.Slug),separator:" :: ",title:Ge.MetaTitle,children:(0,n.jsx)(ae.Z,{size:32,round:!0})}),(0,n.jsx)(ce.Z,{url:"".concat(Le.baseURL).concat(Ge.Slug),title:Ge.MetaTitle,children:(0,n.jsx)(le.Z,{size:32,round:!0})})]})]})})]})]})}):(0,n.jsxs)("div",{className:"product-detail-variation-container",children:[(0,n.jsxs)("div",{className:"product-detail-variation-row",style:{flexWrap:"wrap"},children:[(0,n.jsx)("label",{}),(0,n.jsx)("div",{className:"error-variance-selection",style:{justifyContent:"flex-start"},children:void 0!==(null===(g=Ge.NoSellReason)||void 0===g?void 0:g.length)&&""!==(null===(j=Ge.NoSellReason)||void 0===j?void 0:j.length)&&(0,n.jsx)("span",{children:Ge.NoSellReason})})]}),(0,n.jsxs)("div",{className:"product-detail-variation-row social-share",style:{marginTop:-10},children:[(0,n.jsx)("label",{}),(0,n.jsx)("div",{className:"product-detail-variation-row-right",children:(0,n.jsxs)("div",{className:"product-detail-variation-row-social-container",children:[(0,n.jsxs)("label",{style:{width:"auto",marginRight:5},children:[q("product:label_share"),":"]}),(0,n.jsxs)("div",{children:[(0,n.jsx)(ie.Z,{url:"".concat(Le.baseURL).concat(C.productData.Slug),children:(0,n.jsx)(ne.Z,{size:32,round:!0})}),(0,n.jsx)(re.Z,{url:"".concat(Le.baseURL).concat(C.productData.Slug),separator:" :: ",title:C.productData.MetaTitle,children:(0,n.jsx)(ae.Z,{size:32,round:!0})}),(0,n.jsx)(ce.Z,{url:"".concat(Le.baseURL).concat(C.productData.Slug),title:C.productData.MetaTitle,children:(0,n.jsx)(le.Z,{size:32,round:!0})})]})]})})]})]}),(0,n.jsxs)("div",{className:"product-detail-fulfill-container",children:[(0,n.jsx)("div",{className:"product-detail-fulfill-logo",children:(0,n.jsx)(x.default,{src:Ge.MerchantLogo,layout:"fill",objectFit:"contain",quality:100,alt:Ge.MerchantName})}),(0,n.jsxs)("div",{className:"product-detail-fulfill-text",children:[(0,n.jsx)("div",{className:"product-detail-fulfill-label",children:q("product:fulfilled_by")}),(0,n.jsx)("div",{className:"product-detail-fulfill-name",children:Ge.MerchantName})]})]})]})]})]})]})}),(0,n.jsx)("div",{className:"product-detail-description-container",children:(0,n.jsxs)("div",{className:"container",children:[(0,n.jsx)("h2",{children:q("product:product_description")}),(0,n.jsx)("div",{className:"product-detail-description-text",dangerouslySetInnerHTML:{__html:ei(Ge.Description)}}),null!=Xe&&(null===Xe||void 0===Xe?void 0:Xe.length)>0&&(0,n.jsx)("div",{className:"product-detail-slide-container",children:(0,n.jsx)(w.Slide,{autoplay:!1,indicators:!1,arrows:(null===Xe||void 0===Xe?void 0:Xe.length)>1,infinite:(null===Xe||void 0===Xe?void 0:Xe.length)>1,prevArrow:(0,n.jsx)("div",{className:"slide-nav",children:(0,n.jsx)(x.default,{src:S,width:24,height:24,alt:"Prev"})}),nextArrow:(0,n.jsx)("div",{className:"slide-nav",children:(0,n.jsx)(x.default,{src:k,width:24,height:24,alt:"Next"})}),canSwipe:!1,duration:5e3,children:Xe.map((function(e,t){var i=e.Type,r=e.ClickUrl,a=e.PrimaryTagline,c=e.SecondaryTagline,l=e.ImageUrl,s=(e.VideoUrl,e.CallToActionText);return 0===i?(0,n.jsx)("div",{className:"each-slide",children:(0,n.jsx)("div",{style:{backgroundImage:"url(".concat(l,")")},children:(0,n.jsxs)("div",{className:"bannerActionCtr",children:[(null===a||void 0===a?void 0:a.length)>0&&(0,n.jsx)("h3",{children:a}),(null===c||void 0===c?void 0:c.length)>0&&(0,n.jsx)("h4",{children:c}),r.length>0&&s.length>0&&(0,n.jsxs)("a",{href:r,children:[s,"\xa0\xa0\xa0\xa0",(0,n.jsx)("i",{className:"fa fa-chevron-right"})]})]})})},t):(0,n.jsx)("div",{className:"each-slide",children:(0,n.jsx)("div",{style:{backgroundImage:"url(".concat(l,")")},children:(0,n.jsx)("div",{className:"bannerActionCtr",children:(0,n.jsx)("button",{className:"gallery-playback",onClick:function(){Ie("https://commondatastorage.googleapis.com/gtv-videos-bucket/sample/BigBuckBunny.mp4")},children:(0,n.jsx)(x.default,{src:H.Z,width:50,height:50,quality:100})})})})},t)}))})}),null!=ot&&function(e){var t=[];e.map((function(e,i){var n={title:e.title,content:e.content};t.push(n)}));for(var i=3-e.length,r=0;r<i;r++){t.push({title:null,content:null})}t.length;return e.length>0?(0,n.jsx)("div",{className:"product-detail-tips-container three-cols",children:t.map((function(e,t){return(0,n.jsx)("div",{className:"product-detail-tips-card ".concat(null===e.title?"empty":""),children:null!=e.title&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:"product-detail-tips-title",children:e.title}),(0,n.jsx)("div",{className:"product-detail-tips-description",dangerouslySetInnerHTML:{__html:ei(e.content)}})]})},t)}))}):(0,n.jsx)(n.Fragment,{})}(ot)]})}),1===Ge.MerchantId&&1===(null===_t||void 0===_t?void 0:_t.CategoryId)&&(0,n.jsx)("div",{className:"product-detail-ingredient-container",children:(0,n.jsxs)("div",{className:"container",children:[(0,n.jsx)("h3",{children:q("product:premium_quality_ingredients")}),(0,n.jsxs)("ul",{className:"product-detail-ingredient-list",children:[(0,n.jsxs)("li",{children:[(0,n.jsx)("div",{className:"product-detail-ingredient-list-title",children:q("product:label_no")}),(0,n.jsx)("div",{className:"product-detail-ingredient-list-text",children:q("product:artificial_preservatives")})]}),(0,n.jsxs)("li",{children:[(0,n.jsx)("div",{className:"product-detail-ingredient-list-title",children
1:q("product:label_no")}),(0,n.jsx)("div",{className:"product-detail-ingredient-list-text",children:q("product:meat_tenderiser")})]}),(0,n.jsxs)("li",{children:[(0,n.jsx)("div",{className:"product-detail-ingredient-list-title",children:q("product:label_no")}),(0,n.jsx)("div",{className:"product-detail-ingredient-list-text",children:q("product:flavourings")})]}),(0,n.jsxs)("li",{children:[(0,n.jsx)("div",{className:"product-detail-ingredient-list-title",children:q("product:label_no")}),(0,n.jsx)("div",{className:"product-detail-ingredient-list-text",children:q("product:colourings")})]}),(0,n.jsxs)("li",{children:[(0,n.jsx)("div",{className:"product-detail-ingredient-list-title",children:q("product:label_no")}),(0,n.jsx)("div",{className:"product-detail-ingredient-list-text",children:q("product:MSG_added")})]})]})]})})]}),(null===Rt||void 0===Rt?void 0:Rt.Count)>0&&(0,n.jsx)("div",{className:"product-detail-reviews-fullwidth-container",children:(0,n.jsxs)("div",{className:"container",children:[(0,n.jsx)("h1",{children:q("product:reviews")}),(0,n.jsxs)("div",{className:"product-detail-reviews-summary",children:[(0,n.jsx)("div",{style:{marginTop:-8},children:(0,n.jsx)(x.default,{src:Se,width:48,height:48,alt:""})}),(0,n.jsx)("div",{className:"product-detail-reviews-average",children:null===Rt||void 0===Rt?void 0:Rt.RatingSummary}),(0,n.jsxs)("div",{className:"product-detail-reviews-total",style:{textTransform:"lowercase"},children:["/ ",null===Rt||void 0===Rt?void 0:Rt.RatingAll," (",null===Rt||void 0===Rt?void 0:Rt.Count," ",(null===Rt||void 0===Rt?void 0:Rt.Count)>1?q("product:reviews"):q("product:review"),")"]})]}),(null===Bt||void 0===Bt?void 0:Bt.length)>0&&(0,n.jsx)(_.Z,{dataLength:null===Bt||void 0===Bt?void 0:Bt.length,next:function(){},hasMore:!1,loader:(0,n.jsx)(P.Z,{}),children:(0,n.jsx)("div",{className:"product-detail-reviews-container",children:Bt.map((function(e){return(0,n.jsx)(Te,{item:e,onImageClick:function(e){Mt(e)}},e.Id)}))})}),qe?(0,n.jsx)(P.Z,{}):(0,n.jsx)("div",{className:"product-detail-reviews-load-more",children:(0,n.jsx)("a",{onClick:(0,m.Z)(u().mark((function e(){return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Vt();case 2:case"end":return e.stop()}}),e)}))),children:q("product:load_more_reviews")})})]})}),null!=nt&&(null===nt||void 0===nt?void 0:nt.length)>0&&(0,n.jsx)("div",{className:"product-detail-related-product-container",children:(0,n.jsxs)("div",{className:"container",children:[(0,n.jsx)("h1",{children:q("product:you_may_also_like")}),(0,n.jsx)("ul",{className:"product-listing-list",children:nt.map((function(e){return(0,n.jsx)("li",{className:e.isLarge?"large":"",children:(0,n.jsx)(we,{item:e,webLocale:F})},e.Id)}))})]})}),null!=ct&&(null===ct||void 0===ct?void 0:ct.length)>0&&(0,n.jsx)("div",{className:"product-detail-today-container",children:(0,n.jsxs)("div",{className:"container",children:[(0,n.jsx)("h1",{children:Ge.MerchantName+" "+q("product:today")}),(0,n.jsx)("ul",{className:"today-list",children:ct.map((function(e){return(0,n.jsx)("li",{children:(0,n.jsx)(R,{item:e,webLocale:F})},e.Slug)}))})]})})]}),null!==yt&&(0,n.jsx)(te.Z,{customStyle:N.fW,isOpen:!0,onRequestClose:function(){Nt(null)},title:q("common:alert_heading_info"),children:(0,n.jsxs)("div",{className:"message-modal-container",children:[(0,n.jsx)("p",{children:yt}),(0,n.jsx)("div",{style:{marginTop:40},children:(0,n.jsx)(o.Z,{buttonStyle:{textTransform:"uppercase"},title:q("btn_ok"),onClick:function(){Nt(null)}})})]})}),(0,n.jsx)(te.Z,{customStyle:N.RS,isOpen:Ae,customBodyStyle:{height:"100%",padding:0},modalParentClassName:"product-banner-vModal",onRequestClose:function(){Ie(""),Oe(!1)},showTitle:!1,title:"",children:(0,n.jsx)("div",{className:"video-modal-container",children:""!=De&&(0,n.jsx)("video",{autoPlay:!1,controls:!0,className:"product-banner-video",children:(0,n.jsx)("source",{src:De,type:"video/mp4"})})})}),""!==Ot&&(0,n.jsx)(W(),{onClose:function(){Mt("")},image:Ot,title:""})]})},Be=i(96486),He=i.n(Be),qe=i(57466),ze=i(42298),Ye=(0,g.default)().publicRuntimeConfig,Ge=function(e){var t=e.pageProps,i=(e.webLocale,(0,a.useRouter)()),l=(0,c.$G)(["common","cms"]).t,o=((0,s.I0)(),(0,r.useState)([])),d=o[0],u=o[1],h=(0,r.useState)(null),m=h[0],p=h[1],g=(0,r.useState)(null),x=g[0],j=g[1],b=(0,r.useState)(null),y=(b[0],b[1]),w=(0,r.useState)([]),_=w[0],P=w[1],S=(0,r.useState)(!1),k=S[0],D=S[1],C=(0,r.useState)(null),A=C[0],T=C[1],O=(0,r.useState)(!0),M=O[0],F=O[1];(0,r.useEffect)((function(){var e=!0;if(!0===e){if(null!=t.pageData){var i=[{title:l("home"),link:"/"},{title:t.pageData.Title,link:"/".concat(t.pageData.Slug)}];u(i),p(t.pageData),y(t.careerData)}F(!1)}return function(){e=!1}}),[t.pageData]);var L=function(){return null!=t.careerData?t.careerData.map((function(e){var t;return(0,n.jsxs)("div",{className:"job-list-container",children:[(0,n.jsxs)("div",{className:"job-item-toggle ".concat(_.includes(e.Type)?"active":""),onClick:function(){return Z(e.Type)},children:[(0,n.jsx)("label",{children:e.TypeName}),(0,n.jsx)("div",{className:"job-item-toggle-value",children:(0,n.jsxs)("span",{className:"ttl-jobs",children:[e.Careers.length," ",l("cms:label_positions")]})})]}),(0,n.jsx)("div",{className:"job-item-toggle-body ".concat(_.includes(e.Type)?"active":""),children:(null===(t=e.Careers)||void 0===t?void 0:t.length)>0&&(0,n.jsx)(n.Fragment,{children:e.Careers.map((function(e){return(0,n.jsx)("div",{className:"job-data-row",children:(0,n.jsx)("h4",{onClick:function(){T(e)},children:e.Title})},e.Id)}))})})]},e.Type)})):null};(0,r.useEffect)((function(){D(null!==A)}),[A]);var Z=function(e){var t=[];t=_.includes(e)?_.filter((function(t){return t!==e})):f()(_,{$push:[e]}),P(t)},R=function(e){return e.toString()},U=function(e,t){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";if(null!=e.data&&e.data.length>0){if(1===e.type)return(0,n.jsx)(n.Fragment,{children:e.data.map((function(e,r){var a=e.WebLayout,c=e.SectionHeader,l=e.SectionContent,s=e.Media,o=e.Position,d="".concat(t,"_").concat(r,"_").concat(o);if(void 0!==s&&null!==s||(s=[]),0===a){var u="TIMELINE"===i?"layout-timeline-row right-align":"layout-contentL-mediaR";return(0,n.jsxs)("div",{className:"".concat(u," ").concat(s.length>1?"gallery":""),children:[(0,n.jsxs)("div",{className:"col",children:["NA"!=c&&(0,n.jsx)("h3",{children:c}),l.length>0&&(0,n.jsx)("div",{className:"body",dangerouslySetInnerHTML:{__html:R(l)}})]}),"TIMELINE"===i&&(0,n.jsx)("div",{className:"col sp-line",children:(0,n.jsx)("div",{className:"t-line"})}),(0,n.jsx)("div",{className:"col media",children:(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:s,section:d},d)})}),(0,n.jsx)("div",{style:{clear:"both"}})]},d)}if(1===a){var h="TIMELINE"===i?"layout-timeline-row":"layout-contentR-mediaL";return(0,n.jsxs)("div",{className:"".concat(h," ").concat(s.length>1?"gallery":""),children:[(0,n.jsx)("div",{className:"col",children:(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:s,section:d},d)})}),"TIMELINE"===i&&(0,n.jsx)("div",{className:"col sp-line",children:(0,n.jsx)("div",{className:"t-line"})}),(0,n.jsxs)("div",{className:"col",children:["NA"!=c&&(0,n.jsx)("h3",{children:c}),l.length>0&&(0,n.jsx)("div",{className:"body",dangerouslySetInnerHTML:{__html:R(l)}})]}),(0,n.jsx)("div",{style:{clear:"both"}})]},d)}return 2===a?(0,n.jsxs)("div",{className:"layout-contentTop-mediaBottom",children:[(0,n.jsxs)("div",{className:"content-body",children:["NA"!=c&&(0,n.jsx)("h3",{children:c}),l.length>0&&(0,n.jsx)("div",{className:"body",dangerouslySetInnerHTML:{__html:R(l)}})]}),(0,n.jsx)("div",{className:"content-media",children:(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:s,section:d},d)})})]},d):3===a?(0,n.jsxs)("div",{className:"layout-contentTop-mediaMiddle-contentBottom",children:["NA"!=c&&(0,n.jsx)("h3",{children:c}),(0,n.jsx)("div",{className:"content-media",children:(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:s,section:d},d)})}),l.length>0&&(0,n.jsx)("div",{className:"content-body",children:(0,n.jsx)("div",{className:"body",dangerouslySetInnerHTML:{__html:R(l)}})})]},d):4===a?(0,n.jsx)("div",{className:"layout-content-only ".concat("CAREER_DATA"===c?"career":""),children:(0,n.jsxs)("div",{className:"content-body",children:["NA"!=c&&(0,n.jsx)("h3",{children:c}),l.length>0&&(0,n.jsx)("div",{className:"body",dangerouslySetInnerHTML:{__html:R(l)}})]})},d):5===a?(0,n.jsx)("div",{className:"layout-content-media-only-fluid ".concat("CAREER_DATA"===c?"career":""),children:"CAREER_DATA"===c?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:"content-body",children:(0,n.jsx)("div",{className:"body",dangerouslySetInnerHTML:{__html:R(l)}})}),L()]}):(0,n.jsxs)(n.Fragment,{children:["NA"!=c&&(0,n.jsx)("h3",{children:c}),s.length>0&&(0,n.jsx)("div",{className:"content-media",children:(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:s,section:d},d)})})]})},d):6===a?(0,n.jsx)("div",{className:"layout-content-media-only-half",children:(0,n.jsxs)("div",{className:"content-image",children:["NA"!=c&&(0,n.jsx)("h3",{children:c}),s.length>0&&(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:s,section:d},d)})]})},d):void 0}))});if(7===e.layout){if(e.data.length>0)return(0,n.jsx)(n.Fragment,{children:e.data.map((function(e,r){var a="".concat(t,"_").concat(r,"_").concat(e.length);if(2==e.length){var c="TIMELINE"===i?"layout-timeline-row":"layout-contentR-mediaL",l=[],s=[];return l=void 0===e[0].Media||null===e[0].Media?[]:e[0].Media,s=void 0===e[1].Media||null===e[1].Media?[]:e[1].Media,(0,n.jsxs)("div",{className:c,children:[(0,n.jsxs)("div",{className:"col",children:[l.length>0&&(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:l,section:a},a)}),"NA"!=e[0].SectionHeader&&(0,n.jsx)("h3",{children:e[0].SectionHeader}),e[0].SectionContent.length>0&&(0,n.jsx)("div",{className:"body",dangerouslySetInnerHTML:{__html:R(e[0].SectionContent)}})]}),"TIMELINE"===i&&(0,n.jsx)("div",{className:"col sp-line"}),(0,n.jsxs)("div",{className:"col",children:[s.length>0&&(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:s,section:a},a)}),"NA"!=e[1].SectionHeader&&(0,n.jsx)("h3",{children:e[1].SectionHeader}),e[1].SectionContent.length>0&&(0,n.jsx)("div",{className:"body",dangerouslySetInnerHTML:{__html:R(e[1].SectionContent)}})]}),(0,n.jsx)("div",{style:{clear:"both"}})]},r)}var o="TIMELINE"===i?"layout-timeline-row":"layout-contentR-mediaL two-cols-half",d=[];return d=void 0===e[0].Media||null===e[0].Media?[]:e[0].Media,(0,n.jsx)("div",{className:o,children:(0,n.jsxs)("div",{className:"col",children:[d.length>0&&(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:d,section:a},a)}),"NA"!=e[0].SectionHeader&&(0,n.jsx)("h3",{children:e[0].SectionHeader}),e[0].SectionContent.length>0&&(0,n.jsx)("div",{className:"body",dangerouslySetInnerHTML:{__html:R(e[0].SectionContent)}})]})},r)}))})}else if(8===e.layout&&e.data.length>0)return(0,n.jsx)(n.Fragment,{children:e.data.map((function(e,r){var a="".concat(t,"_media_layout_8_").concat(r,"_").concat(e.length);if(2==e.length){var c="TIMELINE"===i?"layout-timeline-row":"layout-content-media-only-2cols";return(0,n.jsx)("div",{className:c,children:(0,n.jsxs)("div",{className:"row",children:[(0,n.jsx)("div",{className:"col",children:(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:e[0].Media,section:a},a)})}),"TIMELINE"===i&&(0,n.jsx)("div",{className:"col sp-line"}),(0,n.jsx)("div",{className:"col",children:(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:e[1].Media,section:a},a)})})]})},r)}var l="TIMELINE"===i?"layout-timeline-row":"layout-content-media-only-2cols two-cols-half";return(0,n.jsx)("div",{className:l,children:(0,n.jsx)("div",{className:"row",children:(0,n.jsx)("div",{className:"col",children:(0,n.jsx)("div",{className:"cms-gallery-slide-container",children:(0,n.jsx)(qe.Z,{item:e[0].Media,section:a},a)})})})},r)}))})}};return(0,r.useEffect)((function(){var e=!0;if(!0===e&&null!=m){var i=[],n=t.pageData.Sections.filter((function(e){return 7!=e.WebLayout&&8!=e.WebLayout}));if((n=He().sortBy(n,(function(e){return e.Position}))).length>0){var r={id:n[0].Position,data:n,type:1,layout:0};i.push(r)}var a=t.pageData.Sections.filter((function(e){return 7==e.WebLayout}));a=He().sortBy(a,(function(e){return e.Position}));var c=He().chunk(a,2);if(a.length>0){var l={id:a[0].Position,data:c,type:2,layout:7};i.push(l)}var s=t.pageData.Sections.filter((function(e){return 8==e.WebLayout}));s=He().sortBy(s,(function(e){return e.Position}));var o=He().chunk(s,2);if(s.length>0){var d={id:s[0].Position,data:o,type:2,layout:8};i.push(d)}i.length>0&&(i=He().sortBy(i,(function(e){return e.id}))),j(i)}return function(){e=!1}}),[t.pageData,m]),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(v.default,{children:[(0,n.jsx)("title",{children:"".concat(t.pageData.MetaTitle," | Bee Cheng Hiang | Asia's Famous Bakkwa")}),"zh-CH"===i.locale&&(0,n.jsx)("meta",{name:"robots",content:"noindex,nofollow"}),(0,n.jsx)("meta",{name:"description",content:t.pageData.MetaDescription}),(0,n.jsx)("meta",{name:"keywords",content:t.pageData.MetaKeyword}),(0,n.jsx)("meta",{name:"title",content:"".concat(t.pageData.MetaTitle," | Bee Cheng Hiang | Asia's Famous Bakkwa")}),(0,n.jsx)("meta",{property:"og:type",content:"website"}),(0,n.jsx)("meta",{property:"og:url",content:"".concat(Ye.baseURL).concat(t.pageData.Slug)}),(0,n.jsx)("meta",{property:"og:description",content:null===t.pageData.MetaDescription?"":t.pageData.MetaDescription}),(0,n.jsx)("meta",{property:"og:image",content:"".concat(Ye.baseURL,"images/BCH-sLogo.jpg")}
1),(0,n.jsx)("meta",{property:"twitter:url",content:"".concat(Ye.baseURL).concat(t.pageData.Slug)}),(0,n.jsx)("meta",{property:"twitter:title",content:t.pageData.MetaTitle},"title"),(0,n.jsx)("meta",{property:"twitter:description",content:null===t.pageData.MetaDescription?"":t.pageData.MetaDescription}),(0,n.jsx)("meta",{property:"twitter:image",content:"".concat(Ye.baseURL,"images/BCH-sLogo.jpg")})]}),(0,n.jsx)("div",{className:"container cms-page",children:!0===M?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(ze.f,{width:"100%"}),(0,n.jsx)(ge,{})]}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("div",{className:"cms-page-breadcrumb",children:(0,n.jsx)("div",{className:"breadcrumb-container",children:(0,n.jsx)(I.Z,{items:d})})}),(0,n.jsx)("div",{className:"cms-page-header",children:(0,n.jsx)("h1",{children:"STANDARD"===t.pageTemplate?t.pageData.Title:"Bee Cheng Hiang Milestone"})}),(0,n.jsxs)("div",{className:"cms-page-content",children:["STANDARD"===t.pageTemplate&&(0,n.jsx)(n.Fragment,{children:(null===x||void 0===x?void 0:x.length)>0&&(0,n.jsx)(n.Fragment,{children:x.map((function(e,i){return(0,n.jsx)(r.Fragment,{children:U(e,i,t.pageTemplate)},i)}))})}),"TIMELINE"===t.pageTemplate&&(0,n.jsx)(n.Fragment,{children:(0,n.jsx)("div",{className:"layout-timeline",children:(null===x||void 0===x?void 0:x.length)>0&&(0,n.jsx)(n.Fragment,{children:x.map((function(e,i){return(0,n.jsx)(r.Fragment,{children:U(e,i,t.pageTemplate)},i)}))})})})]})]})}),null!=A&&(0,n.jsx)(te.Z,{customStyle:N.xt,isOpen:k,modalParentClassName:"job-details-modal",onRequestClose:function(){T(null)},title:A.Title,children:null!=A&&(0,n.jsxs)("div",{className:"job-details-modal-container",children:[null!=A.From&&(0,n.jsxs)("div",{className:"job-date",children:[(0,n.jsx)("span",{className:"j-label",children:l("cms:label_posted_date")}),(0,n.jsxs)("span",{className:"j-value",children:[":\xa0\xa0",Ae()(A.From).format("YYYY-MM-DD")]})]}),null!=A.To&&(0,n.jsxs)("div",{className:"job-date",children:[(0,n.jsx)("span",{className:"j-label",children:l("cms:label_closing_date")}),(0,n.jsxs)("span",{className:"j-value",children:[":\xa0\xa0",Ae()(A.To).format("YYYY-MM-DD")]})]}),null!=A.Description&&(0,n.jsx)("div",{className:"job-details-content",dangerouslySetInnerHTML:{__html:A.Description}}),null!=A.Responsibilities&&A.Responsibilities.length>0&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("h5",{children:l("cms:job_section_responsibilities")}),(0,n.jsx)("div",{className:"job-details-content",dangerouslySetInnerHTML:{__html:A.Responsibilities}})]}),null!=A.Requirements&&A.Requirements.length>0&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)("h5",{children:l("cms:job_section_requirements")}),(0,n.jsx)("div",{className:"job-details-content",dangerouslySetInnerHTML:{__html:A.Requirements}})]})]})})]})},We=function(e){var t=e.item,i=e.webLocale,r="zh-HK"==i.lang?"/".concat(t.Slug,"/"):"/".concat(i.lang,"/").concat(t.Slug,"/");return(0,n.jsx)("a",{href:r,className:"fc-category-item-link",children:(0,n.jsx)("div",{className:"fc-category-item-image",children:(0,n.jsx)("img",{src:t.Image,className:"cat-image",alt:t.NameWeb})})})},Ve=i(57768),$e=i(90723),Ke=i(75204),Qe=i(94398);function Xe(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function Je(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?Xe(Object(i),!0).forEach((function(t){(0,h.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):Xe(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}!function(e){e.Right="to right",e.Left="to left",e.Down="to bottom",e.Up="to top"}(Fe||(Fe={}));var et=function(e){var t=e.values,i=e.colors,n=e.min,r=e.max,a=e.direction,c=void 0===a?Fe.Right:a,l=e.rtl,s=void 0!==l&&l;s&&c===Fe.Right?c=Fe.Left:s&&Fe.Left&&(c=Fe.Right);var o=t.slice(0).sort((function(e,t){return e-t})).map((function(e){return(e-n)/(r-n)*100})).reduce((function(e,t,n){return"".concat(e,", ").concat(i[n]," ").concat(t,"%, ").concat(i[n+1]," ").concat(t,"%")}),"");return"linear-gradient(".concat(c,", ").concat(i[0]," 0%").concat(o,", ").concat(i[i.length-1]," 100%)")},tt=function(e){var t=e.step,i=e.min,r=e.max,a=e.values,c=e.onCh
1ange,l=function(e){c&&c(e)};return(0,n.jsxs)("div",{className:"fc-range-slider",children:[null!=a[0]&&(0,n.jsx)("div",{className:"fc-range-slider-min",children:a[0]}),(0,n.jsx)(Qe.Range,{step:t,min:i,max:r,values:a,onChange:function(e){return l(e)},renderTrack:function(e){var t=e.props,c=e.children;return(0,n.jsx)("div",{onMouseDown:t.onMouseDown,onTouchStart:t.onTouchStart,style:Je(Je({},t.style),{},{height:"36px",display:"flex",width:"100%"}),children:(0,n.jsx)("div",{ref:t.ref,style:{height:"5px",width:"100%",borderRadius:"2px",background:et({values:a,colors:["#ccc","#d92c27","#ccc"],min:i,max:r,rtl:!1}),alignSelf:"center"},children:c})})},renderThumb:function(e){var t=e.props;return(0,n.jsx)("div",Je(Je({},t),{},{className:"fc-range-slider-thumb"}))}}),null!=a[1]&&(0,n.jsx)("div",{className:"fc-range-slider-max",children:a[1]})]})},it={src:"/_next/static/image/public/images/svg/icons-16-px-sort.5e5bca0d711e59aeed40302d1c4dab9e.svg",height:16,width:16},nt={src:"/_next/static/image/public/images/svg/icons-16-px-filter.82280f432e552c92e56486bf266d4cb3.svg",height:16,width:16},rt={src:"/_next/static/image/public/images/svg/icons-16-px-arrow-outline-down.e0c44941175c777df63f77d6bc44e2c4.svg",height:16,width:16},at=i(46066),ct=i(99129);function lt(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function st(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};t%2?lt(Object(i),!0).forEach((function(t){(0,h.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):lt(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var ot=(0,g.default)().publicRuntimeConfig,dt=ot.currencySymbol,ut=function(e){var t,i,a,l=(0,c.$G)(["common"]).t,d=(0,s.I0)(),h=(0,r.useState)(!1),p=h[0],g=h[1],v=(0,r.useState)(null),x=v[0],j=v[1],f=(0,r.useState)(0),b=f[0],w=f[1],_=(0,r.useState)(1),P=_[0],S=_[1],k=(0,r.useState)([]),D=k[0],I=k[1],C=(0,r.useState)(),A=C[0],T=C[1],O=(0,r.useState)(0),M=O[0],F=O[1],R=(0,r.useState)(null),U=R[0],E=R[1],B=(0,r.useState)(null),H=B[0],q=B[1],z=(0,r.useState)(!1),Y=z[0],G=z[1],W=(0,r.useState)(!0),V=W[0],$=W[1],K=(0,r.useState)(!1),Q=K[0],X=K[1],J=(0,r.useState)(null),ee=(J[0],J[1]),ie=e.item,ne=e.webLocale,re=(e.onClick,e.isLogin),ae=e.privateTokenData,ce=e.publicTokenData,le=e.preference,se=(0,r.useState)(null),oe=se[0],de=se[1],ue="zh-HK"==ne.lang?"/":"/".concat(ne.lang,"/");(0,r.useEffect)((function(){var e=null;if(null!=ie.Promotions&&ie.Promotions.length>0){var t=ie.Promotions.filter((function(e){var t;return!1===e.IsDeliveryType&&(null===(t=e.TeaserForListing)||void 0===t?void 0:t.length)>0&&null!=e.TeaserForListing}));null!=t&&t.length>0&&(e=t[0])}de(e)}),[ie]);var he=function(){var e=(0,m.Z)(u().mark((function e(t){var i,n,r,a,c;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(null==t){e.next=12;break}return pe("AddToCart"),i={items:[{id:ie.Code,name:ie.Name,list_name:"Search Results",brand:ie.MerchantName,category:ie.Categories[0].Name,variant:null===t||void 0===t?void 0:t.Name,list_position:1,quantity:P,price:(0,Z.x)(null!=(null===t||void 0===t?void 0:t.ProPrice)?null===t||void 0===t?void 0:t.ProPrice:null===t||void 0===t?void 0:t.Price).toString()}]},ge(i),n={product_id:ie.Id,qty:P,uom_id:null===t||void 0===t?void 0:t.Id},r=ce,!0===re&&null!=ae&&(r=ae),a={selectedUOM:t,qty:P,productId:ie.Id},e.next=10,d((0,y.e1)(n,r,"",le.CultureId,localStorage.getItem("_deliveryLoc")));case 10:null!=(c=e.sent)&&0==(null===c||void 0===c?void 0:c.isError)?(st(st({},a),{sError:!1,errorMessage:"",itemDBId:null===c||void 0===c?void 0:c.itemDBId}),g(!1),I(null),X(!1)):(st(st({},a),{sError:!0,errorMessage:null===c||void 0===c?void 0:c.error,itemDBId:0}),g(!1),I(null),X(!1));case 12:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}();(0,r.useEffect)((function(){var e=!0;return!0===e&&(null===D||void 0===D?void 0:D.length)>
10&&1===(null===D||void 0===D?void 0:D.length)&&!0===Q&&he(D[0]),function(){e=!1}}),[D,Q]);var me=function(){var e=(0,m.Z)(u().mark((function e(){var t,i,n,r,a,c;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t={product_id:ie.Id,qty:P,uom_id:A},i=ce,!0===re&&null!=ae&&(i=ae),n={selectedUOM:U,qty:P,productId:ie.Id},G(!1),ee(null),e.next=8,d((0,y.e1)(t,i,"",le.CultureId,localStorage.getItem("_deliveryLoc")));case 8:null!=(r=e.sent)&&0==(null===r||void 0===r?void 0:r.isError)?(pe("AddToCart"),a={items:[{id:ie.Code,name:ie.Name,list_name:"Search Results",brand:ie.MerchantName,category:ie.Categories[0].Name,variant:null===U||void 0===U?void 0:U.Name,list_position:1,quantity:P,price:(0,Z.x)(b).toString()}]},ge(a),st(st({},n),{sError:!1,errorMessage:"",itemDBId:null===r||void 0===r?void 0:r.itemDBId}),g(!1),I(null),X(!1)):(300===(null===r||void 0===r?void 0:r.errorCode)?(c=null===r||void 0===r?void 0:r.error,G(!0),ee("".concat(c," ").concat(l("product:msg_error_items_left"),"<br />").concat(l("product:msg_have_add_more_available_qty_to_cart")))):(G(!0),ee("".concat(l("product:msg_unable_add_cart")))),st(st({},n),{sError:!0,errorMessage:null===r||void 0===r?void 0:r.error,itemDBId:0}),g(!1),I(null),X(!1)),S(1),E(null),T(null),w(0);case 14:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),pe=function(e){null!=window.fbq&&window.fbq("track",e)},ge=function(e){},ve=function(e){var t=1;(t="add"===e?P+1:P-1)<1&&(t=1);var i=t*parseFloat(M);S(t),w(i)};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("div",{className:"fc-product-item-link",children:[(0,n.jsx)("a",{href:"".concat(ue).concat(ie.Slug),children:(0,n.jsxs)("div",{className:"fc-product-item-image square",children:[(0,n.jsx)("img",{src:ie.ImageUrl,alt:""}),((null===(t=ie.Labels)||void 0===t?void 0:t.length)>0||!0===ie.ShowOutOfStock)&&(0,n.jsxs)("div",{className:"fc-product-item-badge-container",children:[!0===ie.ShowOutOfStock&&(0,n.jsx)("div",{className:"fc-product-item-badge fc-product-item-badge-new",style:{backgroundColor:"#DC0000",color:"#fff}"},children:l("product:msg_item_out_of_stock")}),ie.Labels.map((function(e){return(0,n.jsx)("div",{className:"fc-product-item-badge fc-product-item-badge-new",style:{backgroundColor:"#".concat(e.bgcolor),color:"#".concat(e.textcolor)},children:e.Name},e.Id)}))]}),null!=oe&&null!=(null===oe||void 0===oe?void 0:oe.TeaserForListing)&&(null===oe||void 0===oe?void 0:oe.TeaserForListing.length)>0&&(0,n.jsx)("div",{className:"fc-product-item-promotion-text",children:oe.TeaserForListing})]})}),(0,n.jsxs)("div",{className:"fc-product-item-info-container",children:[(0,n.jsxs)("a",{href:"".concat(ue).concat(ie.Slug),children:[(0,n.jsx)("div",{className:"fc-product-item-name",children:ie.Name}),(0,n.jsx)("div",{className:"fc-product-item-price-container",style:{flexDirection:"column"},children:!0===ie.CanSellShowPrice?(0,n.jsx)(n.Fragment,{children:ie.DiscountMethod!==ot.discountMethod.none&&null!=ie.ProPriceFrom&&1==ie.DisplayDiscountedPrice?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)("div",{className:"fc-product-item-price-red-text",children:[dt,(0,Z.x)(ie.ProPriceFrom<0?0:ie.ProPriceFrom)+(ie.ProPriceTo>0&&ie.ProPriceFrom!==ie.ProPriceTo?" - "+dt+(0,Z.x)(ie.ProPriceTo):"")]}),(0,n.jsx)(n.Fragment,{children:ie.ProPriceFrom>0&&ie.ProPriceTo>0&&(0,n.jsxs)("div",{className:"fc-product-item-price-text",children:[null!=ie.PriceFrom&&(0,n.jsxs)("span",{className:"fc-product-item-price-text-strike",children:[dt,(0,Z.x)(ie.PriceFrom)+(ie.PriceTo>0&&ie.PriceFrom!==ie.PriceTo?" - "+dt+(0,Z.x)(ie.PriceTo):"")]}),""!==ie.PromotionUp2Label&&null!==ie.PromotionUp2Label&&(0,n.jsx)("span",{className:"fc-product-item-price-text-discount-percentage",children:ie.PromotionUp2Label})]})})]}):(0,n.jsxs)("div",{className:"fc-product-item-price-red-text",children:[dt,(0,Z.x)(ie.PriceFrom)+(ie.PriceTo>0&&ie.PriceTo!==ie.PriceFrom?" - "+dt+(0,Z.x)(ie.PriceTo):"")]})}):(0,n.jsx)(n.Fragment,{children:void 0!==(null===(i=ie.NoSellReason)||void 0===i?void 0:i.length)&&""!==(null===(a=ie.NoSellReason)||void 0===a?void 0:a.length)&&(0,n.jsx)("div",{className:"fc-product-item-price-red-text",style:{textAlign:"center"},children:ie.NoSellReason})})})]}),(0,n.jsx)("div",{className:"fc-product-item-action",children:!0===ie.CanSellShowAdd2Cart?(0,n.jsx)(Ve.Z,{disabled:ie.ShowOutOfStock,title:!0===ie.ShowOutOfStock?l("product:msg_item_out_of_stock"):l("product:btn_add_to_cart"),onClick:function(){G(!1),j(null),I(null===ie||void 0===ie?void 0:ie.AvailableUOMs);var e=ie.AvailableUOMs;void 0!=(null===e||void 0===e?void 0:e.length)&&(null===e||void 0===e?void 0:e.length)>1?(X(!1),g(!0)):(X(!0),g(!1))}}):(0,n.jsx)(n.Fragment,{})})]})]}),null!==H&&(0,n.jsx)(te.Z,{customStyle:N.fW,isOpen:!0,onRequestClose:function(){q(null)},title:l("common:alert_heading_info"),children:(0,n.jsxs)("div",{className:"message-modal-container",children:[(0,n.jsx)("p",{children:H}),(0,n.jsx)("div",{style:{marginTop:40},children:(0,n.jsx)(o.Z,{buttonStyle:{textTransform:"uppercase"},title:l("btn_ok"),onClick:function(){q(null)}})})]})}),(0,n.jsx)(te.Z,{customStyle:N.RB,isOpen:p,modalParentClassName:"product-uom-vModal",onRequestClose:function(){g(!1),I(null)},showTitle:!0,title:l("product:header_select_variation"),children:(0,n.jsx)("div",{className:"product-listing-modal-select-uom-container",children:(0,n.jsx)("div",{className:"product-detail",style:{width:"100%"},children:(0,n.jsxs)("div",{className:"product-detail-variation-container",children:[(null===D||void 0===D?void 0:D.length)>0&&(0,n.jsxs)(n.Fragment,{children:[(null===D||void 0===D?void 0:D.length)>1&&(0,n.jsxs)("div",{className:"product-detail-variation-row",style:{flexWrap:"wrap",justifyContent:"center"},children:[function(e){if(e.length>0)return(0,n.jsx)("ul",{className:"product-detail-variation-option-list",children:e.map((function(e,t){var i=["list-mode"],r=e.ProPrice>0?e.ProPrice:e.Price;return e.Id===A&&i.push("option-selected"),!0===e.StockAvailable&&(!0===e.FreeSell||e.AvaliableQty>0),(0,n.jsxs)("li",{className:i.join(" "),onClick:function(){!0===e.StockAvailable&&(!0===e.FreeSell||e.AvaliableQty>0)?$(!0):$(!1),S(1),F(e.Price),T(e.Id),w(e.Price),E(e)},children:[e.Name,(0,n.jsxs)("div",{className:"tooltips",children:[(0,n.jsx)("div",{className:"triangle"}),(0,n.jsx)("div",{className:"tooltips-container",children:(0,n.jsxs)("span",{children:[dt,(0,Z.x)(r)]})})]})]},e.Id)}))})}(D),!0===Y&&0===b&&(0,n.jsx)("div",{className:"error-variance-selection",children:(0,n.jsx)("span",{style:{textAlign:"center"},children:l("product:msg_please_select_variation")})})]}),(0,n.jsxs)("div",{className:"product-detail-variation-row",style:{flexDirection:"column"},children:[(0,n.jsx)("label",{style:{marginBottom:"15px"},children:l("product:label_quantity")}),(0,n.jsx)("div",{className:"product-detail-variation-row-right",children:(0,n.jsx)(L,{customClass:"full-width",quantity:P,onAddClick:function(){return ve("add")},onSubtractClick:function(){return ve("subtract")}})})]})]}),null!=x?(0,n.jsx)(n.Fragment,{children:!0===x.StockAvailable&&(!0===x.FreeSell||x.AvaliableQty>0)?(0,n.jsx)("div",{children:(0,n.jsx)(o.Z,{title:l("product:btn_add_to_cart"),onClick:function(){b>0&&null!=A?(me(),G(!1)):G(!0)}})}):(0,n.jsx)("div",{children:(0,n.jsx)(o.Z,{disabled:!0,title:l("product:msg_item_out_of_stock"),onClick:function(){}})})}):(0,n.jsx)(n.Fragment,{children:!0===V?(0,n.jsx)("div",{style:{marginTop:50},children:(0,n.jsx)(o.Z,{title:l("product:btn_add_to_cart"),onClick:function(){b>0&&null!=A?(me(),G(!1)):G(!0)}})}):(0,n.jsx)("div",{children:(0,n.jsx)(o.Z,{disabled:!0,title:l("product:msg_item_out_of_stock"),onClick:function(){}})})})]})})})})]})};function ht(e,t){var i=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),i.push.apply(i,n)}return i}function mt(e){for(var t=1;t<arguments.length;t++){var i=null!=arguments[t]?arguments[t]:{};
1t%2?ht(Object(i),!0).forEach((function(t){(0,h.Z)(e,t,i[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(i)):ht(Object(i)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(i,t))}))}return e}var pt=(0,g.default)().publicRuntimeConfig,gt=1,vt=2,xt=3,jt=4,ft=5,bt=function(e){var t,i,l=e.pageProps,d=e.preference,h=e.webLocale,g=e.publicTokenData,j=e.isLogin,y=e.privateTokenData,N=(e.urlSlug,(0,a.useRouter)()),w=(0,c.$G)(["common","product"]).t,S=(0,s.I0)(),k=(0,ct.Z)(),D=(k.winheight,k.winwidth),C=(0,s.v9)((function(e){return e.settings})).settings.currentMenuId,A=(0,_e.X)("_afid",""),T=(0,p.Z)(A,1)[0],O=(0,r.useState)(null),M=(O[0],O[1]),F=(0,r.useState)([]),L=F[0],Z=F[1],R=(0,r.useState)(!0),U=R[0],E=R[1],B=(0,r.useState)(null),H=(B[0],B[1]),q=(0,r.useState)(0),z=q[0],Y=q[1],G=(0,r.useState)(!0),W=G[0],V=G[1],$=(0,r.useState)(!1),K=$[0],Q=$[1],X=(0,r.useState)(!1),J=X[0],ee=X[1],ie=(0,r.useState)([]),ne=(ie[0],ie[1],(0,r.useState)(l.settingsAttributeData)),re=ne[0],ae=(ne[1],(0,r.useState)(l.settingsUOMsData)),ce=ae[0],le=(ae[1],(0,r.useState)(l.settingsBrandsData)),se=(le[0],le[1],(0,r.useState)(l.defaultFilterParams)),oe=se[0],de=se[1],ue=(0,r.useState)([]),he=ue[0],ve=ue[1],xe=(0,r.useState)(!1),je=xe[0],fe=xe[1],be=(0,r.useState)(!1),ye=be[0],Ne=be[1],we=(0,r.useState)(!1),Se=we[0],ke=we[1],De=(0,r.useState)(gt),Ie=De[0],Ce=De[1],Ae=(0,r.useState)([l.defaultFilterParams.PriceFrom,l.defaultFilterParams.PriceTo]),Te=Ae[0],Oe=Ae[1],Me=(0,r.useState)(l.defaultFilterParams.Attributes),Fe=Me[0],Le=Me[1],Ze=(0,r.useState)(l.defaultFilterParams.UOMIds),Re=Ze[0],Ue=Ze[1],Ee=(0,r.useState)(""),Be=Ee[0],He=Ee[1],qe=(0,r.useState)(null),Ye=qe[0],Ge=qe[1],Qe=(0,r.useState)(null),Xe=Qe[0],Je=Qe[1];(0,r.useEffect)((function(){var e=!0;return!0===e&&D>0&&Y(D),function(){e=!1}}),[D]),(0,r.useEffect)((function(){var e=!0;if(!0===e){var t="zh-HK"==h.lang?"/":"/".concat(h.lang,"/");if(null!=l){var i,n=[{title:w("home"),link:t},{title:null===(i=l.menuData)||void 0===i?void 0:i.NameWeb,link:"".concat(t).concat(l.menuData.Slug,"/")}];Z(n),M(l.defaultCategoryData)}He(t),et(),Q(!0);var r=f()(l.defaultFilterParams,{Afid:{$set:T}});de(r),ot(r)}return function(){e=!1}}),[l,g,h,T]);var et=(0,r.useCallback)((0,m.Z)(u().mark((function e(){var t,i,n;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(C>0)){e.next=15;break}return t=null,e.next=4,localStorage.getItem("web_menu");case 4:if(null!==(i=e.sent)&&0!==(null===i||void 0===i?void 0:i.length)){e.next=10;break}return e.next=8,st(C);case 8:e.next=15;break;case 10:return e.next=12,lt();case 12:t=e.sent,n=t.find((function(e){return e.Id===C})),Ge(n);case 15:V(!1);case 16:case"end":return e.stop()}}),e)}))),[Be,C,g,d]),lt=function(){var e=(0,m.Z)(u().mark((function e(){var t,i;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,localStorage.getItem("web_menu");case 3:if(!(void 0!=(t=e.sent)||(null===t||void 0===t?void 0:t.length)>0)){e.next=7;break}return i=JSON.parse(t),e.abrupt("return",i);case 7:e.next=12;break;case 9:return e.prev=9,e.t0=e.catch(0),e.abrupt("return",null);case 12:case"end":return e.stop()}}),e,null,[[0,9]])})));return function(){return e.apply(this,arguments)}}(),st=function(){var e=(0,m.Z)(u().mark((function e(t){var i,n,r;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(e.prev=0,null==g||null==d){e.next=7;break}return e.next=4,S((0,Pe.hi)(g,d));case 4:null!=(i=e.sent)&&(n=i.find((function(e){return e.Id===t})),Ge(n),r=JSON.stringify(i),window.localStorage.setItem("web_menu",r)),V(!1);case 7:e.next=12;break;case 9:e.prev=9,e.t0=e.catch(0),console.log(e.t0);case 12:case"end":return e.stop()}}),e,null,[[0,9]])})));return function(t){return e.apply(this,arguments)}}(),ot=(0,r.useCallback)(function(){var e=(0,m.Z)(u().mark((function e(t){var i;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,S((0,b.jw)(g,d,t,localStorage.getItem("_deliveryLoc")));case 3:i=e.sent,ve(i),Q(!1),e.next=12;break;case 8:e.prev=8,e.t0=e.catch(0),Q(!1),H(e.t0.message);case 12:case"end":return e.stop()}}),e,null,[[0,8]])})));return function(t){return e.apply(this,arguments)}}(),[g,d,T]),dt=function(){ke((function(e){return!e}))},ht=function(){Ne((function(e){return!e}))},bt=function(e){Q(!0),ve([]),Ce(e),Ne(!1);var t=f()(oe,{PageNumber:{$set:l.defaultFilterParams.PageNumber},SortBy:{$set:e}});de(t),setTimeout((function(){yt(t)}),1500)},yt=function(){var e=(0,m.Z)(u().mark((function e(t){var i;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return H(null),E(!1),Q(!0),e.prev=3,e.next=6,S((0,b.jw)(l.tokenParams,d,t,localStorage.getItem("_deliveryLoc")));case 6:i=e.sent,ve(i),i.length>0?E(!0):E(!1),Q(!1),e.next=16;break;case 12:e.prev=12,e.t0=e.catch(3),Q(!1),H(e.t0.message);case 16:case"end":return e.stop()}}),e,null,[[3,12]])})));return function(t){return e.apply(this,arguments)}}(),Nt=function(e,t,i){if("BRANDS"===i)return(0,n.jsx)("li",{children:(0,n.jsx)(Ke.Z,{label:e.Name,value:!1,onChange:function(){console.log("Selected",e)}})},t);
1if("UOM"===i){var r=Re.findIndex((function(t){return t.Id===e.Id}));return(0,n.jsx)("li",{children:(0,n.jsx)(Ke.Z,{action:je,label:e.Name,value:r>-1,onChange:function(){var t,i={Id:e.Id,Name:e.Name},n=Re,r=Re.findIndex((function(t){return t.Id===e.Id}));r>-1?n.splice(r,1):n=n.concat(i);var a=[];(null===(t=n)||void 0===t?void 0:t.length)>0&&n.map((function(e){a.push(e.Id)}));var c=f()(oe,{UOMIds:{$set:a}});de(c),Ue(n),fe(!1)}})},t)}var a;return(0,n.jsxs)("div",{className:"product-listing-modal-filter-by-section",children:[(0,n.jsx)("div",{className:"product-listing-modal-filter-by-section-header",children:e.Name}),(0,n.jsx)("ul",{className:"product-listing-modal-filter-by-section-checkbox-list",children:(null===(a=e.Options)||void 0===a?void 0:a.length)>0&&e.Options.map((function(e,t){var i=Fe.findIndex((function(t){return t.attributeId!==e.AttributeId&&t.Id===e.Id}));return(0,n.jsx)("li",{children:(0,n.jsx)(Ke.Z,{label:e.Name,value:i>-1,action:je,onChange:function(){var t,i=[],n=Fe.filter((function(t){return t.attributeId!==e.AttributeId})),r={AttributeId:e.AttributeId,Id:e.Id,Name:e.Name},a=Fe.findIndex((function(t){return t.attributeId!==e.AttributeId&&t.Id===e.Id}));a>-1?n.splice(a,1):n=n.concat(r),(null===(t=n)||void 0===t?void 0:t.length)>0&&n.map((function(e){i.push({Id:e.Id,AttributeId:e.AttributeId,Name:e.Name})}));var c=f()(oe,{Attributes:{$set:i}});de(c),Le(n),fe(!1)}})},t)}))})]},t)};(0,r.useEffect)((function(){var e=!0;return 1==e&&(Je(null),Fe.length>=1&&Re.length>=1?Je(w("product:multiple")):(1===Fe.length?Je(Fe[0].Name):Fe.length>1&&Je(w("product:multiple")),1===Re.length?Je(Re[0].Name):Re.length>1&&Je(w("product:multiple")))),function(){e=!1}}),[Fe,Re]);var wt,_t=(0,r.useCallback)((0,m.Z)(u().mark((function e(){var t,i,n;return u().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return Q(!0),ee(!0),t=f()(oe,{PageNumber:{$set:oe.PageNumber+1}}),E(!1),e.prev=4,e.next=7,S((0,b.jw)(l.tokenParams,d,t,localStorage.getItem("_deliveryLoc")));case 7:i=e.sent,de(t),n=he.concat(i),ve(n),i.length>0?E(!0):E(!1),Q(!1),e.next=19;break;case 15:e.prev=15,e.t0=e.catch(4),Q(!1),H(e.t0.message);case 19:return e.prev=19,ee(!1),e.finish(19);case 22:case"end":return e.stop()}}),e,null,[[4,15,19,22]])}))),[he]);return(0,n.jsxs)(r.Fragment,{children:[(0,n.jsxs)(v.default,{children:["zh-CH"===N.locale&&(0,n.jsx)("meta",{name:"robots",content:"noindex,nofollow"}),(0,n.jsx)("link",{rel:"stylesheet",type:"text/css",href:"/vendor/css/slick.min.css"}),(0,n.jsx)("link",{rel:"stylesheet",type:"text/css",href:"/vendor/css/slick-theme.min.css"}),(0,n.jsx)("title",{children:"".concat(null===(t=l.menuData)||void 0===t?void 0:t.NameWeb," | Bee Cheng Hiang | Asia's Famous Bakkwa")}),(0,n.jsx)("meta",{name:"description",content:l.menuData.MetaDescription}),(0,n.jsx)("meta",{name:"keywords",content:l.menuData.MetaKeyword}),(0,n.jsx)("meta",{name:"title",content:"".concat(l.menuData.MetaTitle," | Bee Cheng Hiang | Asia's Famous Bakkwa")}),(0,n.jsx)("meta",{property:"og:type",content:"website"}),(0,n.jsx)("meta",{property:"og:url",content:"".concat(pt.baseURL).concat(l.menuData.Slug)}),(0,n.jsx)("meta",{property:"og:description",content:null===l.menuData.MetaDescription?"":l.menuData.MetaDescription}),(0,n.jsx)("meta",{property:"og:image",content:"".concat(pt.baseURL,"images/BCH-sLogo.jpg")}
1),(0,n.jsx)("meta",{property:"twitter:url",content:"".concat(pt.baseURL).concat(l.menuData.Slug)}),(0,n.jsx)("meta",{property:"twitter:title",content:l.menuData.MetaTitle},"title"),(0,n.jsx)("meta",{property:"twitter:description",content:null===l.menuData.MetaDescription?"":l.menuData.MetaDescription}),(0,n.jsx)("meta",{property:"twitter:image",content:"".concat(pt.baseURL,"images/BCH-sLogo.jpg")})]}),!0===W?(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(me,{width:"100%"}),(0,n.jsx)(pe,{width:"100%"}),(0,n.jsx)(ze.f,{className:"category",width:"100%"}),(0,n.jsx)(ge,{})]}):(0,n.jsxs)(n.Fragment,{children:[null!=Ye&&(0,n.jsx)(n.Fragment,{children:(null===(i=Ye.SubMenuList)||void 0===i?void 0:i.length)>0&&(0,n.jsx)("div",{className:"product-listing-category-list-container",children:(0,n.jsx)("div",{className:"container",children:(wt=Ye.SubMenuList,(0,n.jsx)("div",{className:"categories-item-list",children:(0,n.jsx)(at.Z,mt(mt({},{className:"center",infinite:!1,centerPadding:"0",slidesToShow:8,swipeToSlide:!1,draggable:!1,variableWidth:!0,responsive:[{breakpoint:768,settings:{slidesToShow:4,slidesToScroll:4,infinite:!1,draggable:!0}},{breakpoint:480,settings:{slidesToShow:2,slidesToScroll:2,infinite:!1,draggable:!0}}]}),{},{children:wt.filter((function(e){return null!=e.NameWeb})).map((function(e){return(0,n.jsx)("div",{className:"item-wraper",style:{width:130},children:(0,n.jsx)(We,{item:e,webLocale:h})},e.Id)}))}))}))})})}),null!=l.menuData&&z>0&&(0,n.jsxs)("div",{className:"container main-section-container",children:[(0,n.jsx)("div",{className:"breadcrumb-container",children:(0,n.jsx)(I.Z,{items:L})}),""!=l.menuData.BannerAppMobile&&""!=l.menuData.BannerWeb&&(0,n.jsx)("div",{className:"product-listing-category-info",children:(0,n.jsx)("div",{className:"product-listing-category-info-image",children:z<768?(0,n.jsx)("img",{src:l.menuData.BannerAppMobile,alt:l.menuData.BannerPrimaryTagline}):(0,n.jsx)("img",{src:l.menuData.BannerWeb,alt:l.menuData.BannerPrimaryTagline})})}),(0,n.jsxs)("div",{className:"product-listing-filter-container",children:[(0,n.jsxs)("div",{className:"product-listing-filter-button",onClick:ht,children:[(0,n.jsxs)("div",{className:"product-listing-filter-left-col",children:[(0,n.jsx)("div",{className:"product-listing-filter-icon",children:(0,n.jsx)(x.default,{src:it,width:16,height:16,alt:"Sort By"})}),(0,n.jsxs)("div",{children:[(0,n.jsx)("label",{children:w("product:label_sort_by")}),(0,n.jsx)("div",{className:"product-listing-filter-text",children:function(e){switch(e){case gt:return w("product:label_popularity");case vt:return w("product:label_highest_unit_price");case xt:return w("product:label_lowest_unit_price");case jt:return w("product:label_a_z");case ft:return w("product:label_z_a");default:return e}}(Ie)})]})]}),(0,n.jsx)("div",{children:(0,n.jsx)(x.default,{src:rt,width:16,height:16,alt:""})})]}),(0,n.jsxs)("div",{className:"product-listing-filter-button",onClick:dt,children:[(0,n.jsxs)("div",{className:"product-listing-filter-left-col",children:[(0,n.jsx)("div",{className:"product-listing-filter-icon",children:(0,n.jsx)(x.default,{src:nt,width:16,height:16,alt:"Sort By"})}),(0,n.jsxs)("div",{children:[(0,n.jsx)("label",{children:w("product:label_filter_by")}),(0,n.jsx)("div",{className:"product-listing-filter-text",children:null!=Xe?(0,n.jsx)(n.Fragment,{children:Xe}):(0,n.jsx)(n.Fragment,{children:w("product:none")})})]})]}),(0,n.jsx)("div",{children:(0,n.jsx)(x.default,{src:rt,width:16,height:16,alt:""})})]})]}),K&&(0,n.jsx)("div",{style:{height:100,marginTop:-10},children:(0,n.jsx)(P.Z,{})}),(null===he||void 0===he?void 0:he.length)>0&&(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(_.Z,{dataLength:null===he||void 0===he?void 0:he.length,next:function(){_t()},hasMore:U,loader:(0,n.jsx)(P.Z,{}),endMessage:0==J?(0,n.jsx)("h4",{className:"product-listing-end-load-message",children:w("product:msg_load_end")}):(0,n.jsx)(n.Fragment,{}),children:(0,n.jsx)("ul",{className:"product-listing-list",children:he.map((function(e){return(0,n.jsx)("li",{className:e.isLarge?"large":"",children:(0,n.jsx)(ut,{item:e,webLocale:h,preference:d,isLogin:j,publicTokenData:g,privateTokenData:y}
1)},e.Id)}))})}),J&&(0,n.jsx)("div",{style:{height:100},children:(0,n.jsx)(P.Z,{})})]})]})]}),(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(te.Z,{isOpen:ye,onRequestClose:ht,title:w("product:header_sort_by"),children:(0,n.jsx)("div",{className:"product-listing-modal-sort-by-container",children:(0,n.jsxs)("ul",{className:"product-listing-modal-sort-by-list",children:[(0,n.jsx)("li",{children:(0,n.jsx)($e.Z,{label:w("product:label_popularity"),value:gt,isChecked:Ie===gt,onChange:function(e){return bt(e)}})}),(0,n.jsx)("li",{children:(0,n.jsx)($e.Z,{label:w("product:label_highest_unit_price"),value:vt,isChecked:Ie===vt,onChange:function(e){return bt(e)}})}),(0,n.jsx)("li",{children:(0,n.jsx)($e.Z,{label:w("product:label_lowest_unit_price"),value:xt,isChecked:Ie===xt,onChange:function(e){return bt(e)}})}),(0,n.jsx)("li",{children:(0,n.jsx)($e.Z,{label:w("product:label_a_z"),value:jt,isChecked:Ie===jt,onChange:function(e){return bt(e)}})}),(0,n.jsx)("li",{children:(0,n.jsx)($e.Z,{label:w("product:label_z_a"),value:ft,isChecked:Ie===ft,onChange:function(e){return bt(e)}})})]})})}),(0,n.jsx)(te.Z,{isOpen:Se,onRequestClose:dt,title:w("product:header_filter_by"),shouldCloseOnOverlayClick:!1,children:(0,n.jsxs)("div",{className:"product-listing-modal-filter-by-container",children:[(0,n.jsxs)("div",{className:"product-listing-modal-filter-by-section",children:[(0,n.jsxs)("div",{className:"product-listing-modal-filter-by-section-header",children:[w("product:price_range")," ($)"]}),(0,n.jsx)("div",{children:(0,n.jsx)(tt,{step:1,min:0,max:9999999,values:Te,onChange:function(e){return function(e){var t=f()(oe,{PriceFrom:{$set:e[0]},PriceTo:{$set:e[1]}});de(t),Oe(e),fe(!1)}(e)}})})]}),re.length>0&&(0,n.jsx)(n.Fragment,{children:re.map((function(e,t){return Nt(e,t,"ATTRIBUTE")}))}),ce.length>0&&(0,n.jsxs)("div",{className:"product-listing-modal-filter-by-section",children:[(0,n.jsx)("div",{className:"product-listing-modal-filter-by-section-header",children:w("product:uom")}),(0,n.jsx)("ul",{className:"product-listing-modal-filter-by-section-checkbox-list",children:ce.map((function(e,t){return Nt(e,t,"UOM")}))})]}),(0,n.jsxs)("div",{className:"product-listing-modal-filter-by-button-container",children:[(0,n.jsx)("div",{className:"product-listing-modal-filter-by-button-left",children:(0,n.jsx)(Ve.Z,{title:w("product:btn_reset"),onClick:function(){var e=f()(oe,{UOMIds:{$set:[]},PriceFrom:{$set:l.defaultFilterParams.PriceFrom},PriceTo:{$set:l.defaultFilterParams.PriceTo},Attributes:{$set:[]}});de(e),Le([]),Ue([]),Oe([l.defaultFilterParams.PriceFrom,l.defaultFilterParams.PriceTo]),fe(!0)}})}),(0,n.jsx)("div",{className:"product-listing-modal-filter-by-button-right",children:(0,n.jsx)(o.Z,{title:w("product:btn_apply"),onClick:function(){Q(!0),ve([]),ke(!1);var e=f()(oe,{PageNumber:{$set:l.defaultFilterParams.PageNumber}});setTimeout((function(){yt(e),Q(!1)}),1500)}})})]})]})})]})]})},yt=!0,Nt=function(e){var t=e.preferenceParams,i=e.pageProps,d=(e._nextI18Next,e.isSomethingWrong),u=e.slugType,h=e.privateAccessToken,m=e.IsLoggedIn,p=e.tokenParams,g=e.siteLangs,v=e.urlSlug,x=(0,a.useRouter)(),j=(0,c.$G)(["common","product","cms"]).t,f=((0,s.I0)(),(0,r.useContext)(l.n)),b=(0,r.useState)(null),y=(b[0],b[1]),N=(0,r.useState)(null),w=(N[0],N[1]);return(0,r.useEffect)((function(){var e=!0;if(!0===e&&null!=f.webAccessData&&null!=i){var t=f.webAccessData;y(t),w(h)}return function(){e=!1}}),[f,i]),!0===d?(0,n.jsx)("div",{style:{marginTop:20},children:(0,n.jsx)("div",{className:"container",children:(0,n.jsxs)("div",{className:"error-page-container",children:[(0,n.jsx)("h1",{children:j("header_page_not_found")}),(0,n.jsxs)("div",{className:"error-page-content",children:[(0,n.jsx)("p",{children:j("message_page_not_found")}),(0,n.jsx)(o.Z,{title:j("home"),onClick:function(){x.replace("/")}})]})]})})}):(0,n.jsxs)(n.Fragment,{children:["product"===u&&(0,n.jsx)(Ee,{pageProps:i,webLocale:g,preference:t,urlSlug:v,isLogin:m,publicTokenData:p,privateTokenData:h}),"page"===u&&(0,n.jsx)(Ge,{pageProps:i,webLocale:g}),"category"===u&&(0,n.jsx)(bt,{pageProps:i,webLocale:g,urlSlug:v,publicTokenData:p,preference:t,isLogin:m,privateTokenData:h})]})}},16882:function(e,t,i){"use strict";i.d(t,{x:function(){return n}});var n=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:2,i=null!=t?t:2;if(null===e||void 0===e)return e;var n=Math.abs(e).toFixed(i),r="",a=0,c=String(n).indexOf(".");if(-1!==c){for(var l=String(n).substring(c+1,n.length),s=(n=((n=String(n).split(".")[0])||0).toString()).length-1;s>=0;s--)a++,r=n.charAt(s)+r,a%3||0==s||(r=","+r);r=r+"."+l}
1else r=(n||0).toString().replace(/(\d)(?=(?:\d{3})+$)/g,"$1,");return e>=0?r:"-"+r}},44008:function(e,t,i){(window.__NEXT_P=window.__NEXT_P||[]).push(["/[slug]",function(){return i(2281)}])},58964:function(e,t){"use strict";t.Z={src:"/_next/static/image/public/images/bch-promovoucher.085cedd1b8798987f69a42f3689e50d4.png",height:113,width:114,blurDataURL:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAICAYAAADED76LAAAAhElEQVR4nH2OMRKAIBADE9+nhWPrt/QVjoVWPkytBPeQ2oOZQG4v4GMeV8u9lG/JDcoq1Vg6A9gBWhr4drRp1PLtYxoX2wPAg0MCJ1CKOV8BbAAdkykcNAICiQvADCB3eCk8lF4pk1SABXfAfgB5IjMI9X2lAPWTIoEpABQhzn8AZ/b1AvdGRAh1jDP7AAAAAElFTkSuQmCC"}},68264:function(e,t){"use strict";t.Z={src:"/_next/static/image/public/images/svg/icons-16-px-add.69d1eca8be2ca53b70fe39deb1cd89eb.svg",height:24,width:24}},4247:function(e,t){"use strict";t.Z={src:"/_next/static/image/public/images/svg/icons-16-px-bookmark-outline.6c53cca878565c910ad08d694ba461b2.svg",height:20,width:20}},6453:function(e,t){"use strict";t.Z={src:"/_next/static/image/public/images/svg/icons-16-px-subtract.8a1837f35fc2827487b558fa10057bca.svg",height:24,width:24}},61645:function(e,t){"use strict";t.Z={src:"/_next/static/image/public/images/svg/play-circle-regular.4870a5c2103de9f63742b6812b8aaaa6.svg",height:512,width:512}}},function(e){e.O(0,[9774,571,9756,4985,4398,7070,3858,2888,179],(function(){return t=44008,e(e.s=t);var t}));var t=e.O();_N_E=t}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.