Liferay.Loader.define("@liferay/analytics-settings-web@5.0.51/js/pages/wizard/WizardPage",["module","exports","require","@frontend-taglib-clay$clayui/multi-step-nav","liferay!frontend-js-react-web$react","../../App","./AttributesStep","./ConnectStep","./PeopleStep","./PropertyStep"],(function(e,t,r){window;{Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.ESteps=void 0;var a=_interopRequireDefault(r("@frontend-taglib-clay$clayui/multi-step-nav")),n=function _interopRequireWildcard(e){if(e&&e.__esModule)return e;if(null===e||"object"!=typeof e&&"function"!=typeof e)return{default:e};var t=_getRequireWildcardCache();if(t&&t.has(e))return t.get(e);var r={},a=Object.defineProperty&&Object.getOwnPropertyDescriptor;for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var o=a?Object.getOwnPropertyDescriptor(e,n):null;o&&(o.get||o.set)?Object.defineProperty(r,n,o):r[n]=e[n]}r.default=e,t&&t.set(e,r);return r}(r("liferay!frontend-js-react-web$react")),o=r("../../App"),i=_interopRequireDefault(r("./AttributesStep")),l=_interopRequireDefault(r("./ConnectStep")),u=_interopRequireDefault(r("./PeopleStep")),c=_interopRequireDefault(r("./PropertyStep"));function _getRequireWildcardCache(){if("function"!=typeof WeakMap)return null;var e=new WeakMap;return _getRequireWildcardCache=function _getRequireWildcardCache(){return e},e}function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}function ownKeys(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,a)}return r}function _objectSpread(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ownKeys(Object(r),!0).forEach((function(t){_defineProperty(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ownKeys(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function _defineProperty(e,t,r){return t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}let e;t.ESteps=e,function(e){e[e.ConnectAC=0]="ConnectAC",e[e.Property=1]="Property",e[e.People=2]="People",e[e.Attributes=3]="Attributes"}(e||(t.ESteps=e={}));const p=[{Component:l.default,available:!0,key:e.ConnectAC,title:Liferay.Language.get("connect")},{Component:c.default,available:!1,key:e.Property,title:Liferay.Language.get("property")},{Component:u.default,available:!1,key:e.People,title:Liferay.Language.get("people")},{Component:i.default,available:!1,key:e.Attributes,title:Liferay.Language.get("attributes")}];var _default=()=>{const[t,r]=(0,n.useState)(e.ConnectAC),[i,l]=(0,n.useState)(p),u=(0,o.useDispatch)();return n.default.createElement("div",{className:"sheet-lg"},n.default.createElement(a.default,{indicatorLabel:"top"},i.map((({available:e,key:o,title:i},l)=>n.default.createElement(a.default.Item,{active:o===t,complete:t>o,expand:l+1!==p.length,key:o},l<p.length-1&&n.default.createElement(a.default.Divider,null),n.default.createElement(a.default.Indicator,{complete:t>o&&o!==t,label:1+l,onClick:()=>e&&r(o),subTitle:i}))))),i.map((({Component:e,key:a})=>n.default.createElement("div",{key:a},a===t&&n.default.createElement(e,{onCancel:()=>{u({payload:o.EPageView.Default,type:o.Events.ChangePageView}),Liferay.Util.openToast({message:Liferay.Language.get("dxp-has-successfully-connected-to-analytics-cloud,-complete-your-set-up-in-the-instance-scope-menu"),type:"info"})},onChangeStep:e=>{const t=i.map((t=>e===t.key?_objectSpread(_objectSpread({},t),{},{available:!0}):t));l(t),r(e)}})))))};t.default=_default}}));
//# sourceMappingURL=WizardPage.js.map