Liferay.Loader.define("commerce-frontend-js@4.0.52/components/quantity_selector/QuantitySelector",["module","exports","require","liferay!frontend-js-react-web$classnames","liferay!frontend-js-react-web$prop-types","liferay!frontend-js-react-web$react","./InputQuantitySelector","./ListQuantitySelector"],(function(e,t,r){window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var n=u(r("liferay!frontend-js-react-web$classnames")),a=(u(r("liferay!frontend-js-react-web$prop-types")),function(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=l();if(t&&t.has(e))return t.get(e);var r={},n=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var a in e)if(Object.prototype.hasOwnProperty.call(e,a)){var o=n?Object.getOwnPropertyDescriptor(e,a):null;o&&(o.get||o.set)?Object.defineProperty(r,a,o):r[a]=e[a]}r.default=e,t&&t.set(e,r);return r}(r("liferay!frontend-js-react-web$react"))),o=u(r("./InputQuantitySelector")),i=u(r("./ListQuantitySelector"));function l(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return l=function(){return e},e}function u(e){return e&&e.__esModule?e:{default:e}}const e=(0,a.forwardRef)((({alignment:e,allowedQuantities:t,disabled:r,max:l,min:u,name:f,onUpdate:c,quantity:s,size:d,step:p},y)=>{const m=(0,a.useRef)(),b=(null==t?void 0:t.length)>0?i.default:o.default;return a.default.createElement(b,{alignment:e,allowedQuantities:t,className:(0,n.default)({["form-control-".concat(d)]:d,"quantity-selector":!0}),disabled:r,max:l,min:u,name:f,onUpdate:c,quantity:s,ref:y||m,step:p})}));e.defaultProps={disabled:!1};var f=e;t.default=f}}));
//# sourceMappingURL=QuantitySelector.js.map