Steps-CJeFnYiU.js 1.5 KB

1
  1. import{w as R,v as E,ai as U,bd as j,y as d,dZ as F,f as l,dq as L,bP as T,s as _,t as q,aF as z,z as K,D as O,K as W}from"./index-BPRWoLf4.js";function Z(e){var a,r=e.className,u=e.style,f=e.steps,n=e.status,h=e.mode,C=e.iconPosition,V=e.labelPlacement,w=e.progressDot,c=e.data,I=e.source,N=e.render,x=e.mobileUI,b=R(I,c,"| raw"),p=(Array.isArray(b)?b:void 0)||f||[],s=E(n)?R(n,c,"| raw"):n,v=function(t){return typeof t=="string"?W(t,c):t&&N("inner",t)},i=(a=U(e))!==null&&a!==void 0?a:0,y=typeof i=="string"&&isNaN(+i)?j(i,c)||i:+i,S=p.findIndex(function(t){return t.value&&t.value===y}),P=S!==-1?S:y,D=p.map(function(t,m){var o=A(t,m);return d(d({},t),{status:o,title:v(t.title),subTitle:v(t.subTitle),description:v(t.description)})});function A(t,m){var o;if(typeof s=="string")m===P&&(o=s||n||F.process);else if(typeof s=="object"){var g=t.value;g&&s[g]&&(o=s[g])}return o}return l.createElement(L,{current:P,steps:D,className:r,style:u,status:s,mode:h,iconPosition:C,progressDot:w,labelPlacement:V,mobileUI:x})}var $=T()(function(e){_(a,e);function a(){return e!==null&&e.apply(this,arguments)||this}return a.prototype.render=function(){var r=this.props,u=r.config;r.deferLoad,r.loading,r.updateConfig;var f=q(r,["config","deferLoad","loading","updateConfig"]),n=z(u)?u:null;return l.createElement(Z,d({},f,n))},a}(l.Component)),G=function(e){_(a,e);function a(){return e!==null&&e.apply(this,arguments)||this}return a.prototype.render=function(){return l.createElement($,d({},this.props))},a=K([O({type:"steps"})],a),a}(l.Component);export{Z as StepsCmpt,G as StepsRenderer};