import{defineProperty as t}from"../../_virtual/_rollupPluginBabelHelpers.js";import{jsxs as e,jsx as o}from"react/jsx-runtime";import{forwardRef as s,useRef as r}from"react";import n from"classnames";import{BEMClass as i}from"../../helpers/bem-helper.js";import{NOOP as a}from"../../utils/function-utils.js";import p from"../../hooks/useMergeRefs.js";import{StepsHeader as m}from"./StepsHeader.js";import{StepsType as d,STEPS_CSS_BASE_CLASS as c}from"./StepsConstants.js";import"./Steps.scss.js";var u=i(c),v=s((function(s,i){var v,l=s.className,f=s.id,j=s.steps,g=void 0===j?[]:j,B=s.activeStepIndex,P=void 0===B?0:B,b=s.type,h=void 0===b?d.GALLERY:b,y=s.onChangeActiveStep,S=void 0===y?a:y,x=s.isOnPrimary,H=void 0!==x&&x,C=s.areNavigationButtonsHidden,O=void 0!==C&&C,I=s.isContentOnTop,N=void 0!==I&&I,k=s.backButtonProps,A=void 0===k?{}:k,L=s.nextButtonProps,R=void 0===L?{}:L,_=s.areButtonsIconsHidden,E=void 0!==_&&_,G=r(null),M=p({refs:[i,G]});return e("div",Object.assign({ref:M,className:n(c,l,(v={},t(v,u({state:"on-primary"}),H),t(v,u({state:"content-on-top"}),N),t(v,u({state:"content-on-bottom"}),!N),v)),id:f},{children:[N&&g[P],o(m,{onChangeActiveStep:S,type:h,activeStepIndex:P,stepsCount:g.length,areNavigationButtonsHidden:O,isOnPrimary:H,backButtonProps:A,nextButtonProps:R,areButtonsIconsHidden:E}),!N&&g[P]]}))}));Object.assign(v,{types:d});var l=v;export{l as default};
