@regenbio/regenbio-components-react 1.4.19 → 1.4.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/build/index.js +1 -1
  2. package/package.json +1 -1
package/build/index.js CHANGED
@@ -25,4 +25,4 @@
25
25
  }
26
26
  }
27
27
  }
28
- `}))),TFe=e=>{const{setTableLoading:t,responsive:n,styles:r,tableLoading:a,restProps:i,actionRef:o}=(e=>{const[t,n]=(0,u.useState)(),[r,a]=(0,u.useState)(!1),i=(0,u.useRef)(void 0),{request:o,loading:c,columns:s,...l}=e,{styles:f}=CFe();return(0,u.useImperativeHandle)(e.actionRef,(()=>({startLoading:()=>{a(!0)},finishLoading:()=>{a(!1)},...i.current}))),(0,u.useEffect)((()=>{n(e.responsive)}),[e.responsive]),(0,u.useEffect)((()=>{e.loadChange&&e.loadChange.call(void 0,r)}),[r]),{setTableLoading:a,responsive:t,styles:f,tableLoading:r,restProps:l,actionRef:i}})(e);return(0,l.jsx)(EFe,{tableClassName:r.customTable,scroll:{x:1300},rowKey:"guid",search:{labelWidth:120},loading:a,columns:e.columns.map((e=>{const t={...e};return t.fixed=!n&&t.fixed,e})),request:async(n,r,a)=>{let i;t(!0);try{i=await e.request.call(void 0,n,r,a)}finally{t(!1)}return i},...i,actionRef:o},"dragTable"+n)},LFe=f().forwardRef((({fieldProps:e,children:t,params:n,proFieldProps:r,mode:a,valueEnum:i,request:o,options:c,...s},f)=>{const d={options:c,mode:a||"multiple",labelInValue:!0,showSearch:!0,suffixIcon:null,autoClearSearchValue:!0,optionLabelProp:"label",...e},h=(0,u.useContext)($Pe.FieldContext);return(0,l.jsx)($Pe.ProFormField,{valueEnum:vBe(i),params:n,valueType:"select",filedConfig:{customLightMode:!0},fieldProps:{getPopupContainer:h.getPopupContainer,...d},ref:f,proFieldProps:r,...s,children:t})})),AFe=f().forwardRef((({widthControl:e,children:t,params:n,proFieldProps:r,mode:a,valueEnum:i,request:o,...c},s)=>{const{setKeywords:f,onFuzzy:d,start:p,loading:m,context:g,data:y,intl:b,keywords:w}=(({widthControl:e,children:t,params:n,proFieldProps:r,mode:a,valueEnum:i,request:o,userType:c,...s})=>{const{intl:l}=v(),f=(0,u.useContext)($Pe.FieldContext),[d,h]=(0,u.useState)([]),[p,m]=(0,u.useState)(),[g,y]=(0,u.useState)(!1),[b,w]=(0,u.useState)(!1),x=async e=>{y(!0);const t=f.formRef?.current?.getFieldValue(s.name);let n;n=H.isNotNull(t)?await o(e,Array.isArray(t)?t:[t],void 0,c):await o(e,[],void 0,c),1===n.code?h(n.data):h([]),y(!1)};return(0,u.useEffect)((()=>{(async()=>{w(!0),await x(null),w(!1)})()}),[]),(0,u.useEffect)((()=>{if(e){const e=document.getElementsByClassName("ant-form-item-control");for(const t of e){const e=t.getElementsByClassName("ant-col ant-form-item-control");for(const t of e)t.style.maxWidth="none"}}}),[b,e]),{setKeywords:m,onFuzzy:x,start:b,loading:g,context:f,data:d,intl:l,keywords:p}})({widthControl:e,children:t,params:n,proFieldProps:r,mode:a,valueEnum:i,request:o,...c});return(0,l.jsx)($Pe.ProFormField,{valueEnum:vBe(i),params:n,valueType:"select",filedConfig:{customLightMode:!0},fieldProps:p?{value:null,loading:m,mode:a,getPopupContainer:g.getPopupContainer,defaultActiveFirstOption:!1,labelRender:e=>e.title,optionRender:e=>{const t=e.data;return(0,l.jsxs)(h.Space,{children:[(0,l.jsx)(h.Avatar,{size:"default",src:c.avatarPreview(t.avatar),children:t.name[0]}),(0,l.jsxs)(h.Space,{direction:"vertical",size:0,children:[(0,l.jsxs)("span",{children:[(0,l.jsx)("span",{children:t.name}),t.alias&&(0,l.jsx)("span",{children:"("+t.alias+")"})]}),(0,l.jsx)("span",{style:{fontSize:"0.875rem"},children:t.phone})]})]})},options:(y||[]).map((e=>({...e,value:e.guid,label:e.name,title:(0,l.jsxs)(h.Space,{children:[(0,l.jsx)(h.Avatar,{size:"small",src:c.avatarPreview(e.avatar),children:e.name[0]}),(0,l.jsx)("span",{children:(0,l.jsx)("span",{children:e.name})})]})}))),dropdownRender:e=>(0,l.jsxs)(l.Fragment,{children:[e,(0,l.jsx)(h.Divider,{style:{marginTop:"0.5rem",marginBottom:"0.5rem",marginLeft:"0rem",marginRight:"0rem"}}),(0,l.jsxs)(h.Space.Compact,{style:{width:"100%"},children:[(0,l.jsx)(h.Input,{placeholder:b.formatMessage({id:"components.user-selector.placeholder",defaultMessage:"请输入关键字"}),value:w,onChange:e=>{f(e.target.value)}}),(0,l.jsx)(h.Button,{loading:m,type:"primary",onClick:()=>{d(w)},children:b.formatMessage({id:"components.user-selector.search",defaultMessage:"搜索"})})]})]})}:{loading:m,mode:a,getPopupContainer:g.getPopupContainer,defaultActiveFirstOption:!1,labelRender:e=>e.label,optionRender:e=>{const t=e.data;return(0,l.jsxs)(h.Space,{children:[(0,l.jsx)(h.Avatar,{size:"default",src:c.avatarPreview(t.avatar),children:t.name[0]}),(0,l.jsxs)(h.Space,{direction:"vertical",size:0,children:[(0,l.jsxs)("span",{children:[(0,l.jsx)("span",{children:t.name}),t.alias&&(0,l.jsx)("span",{children:"("+t.alias+")"})]}),(0,l.jsx)("span",{style:{fontSize:"0.875rem"},children:t.phone})]})]})},options:(y||[]).map((e=>({...e,value:e.guid,label:(0,l.jsxs)(h.Space,{children:[(0,l.jsx)(h.Avatar,{size:"small",src:c.avatarPreview(e.avatar),children:e.name[0]}),(0,l.jsx)("span",{children:(0,l.jsx)("span",{children:e.name})})]}),title:e.name}))),dropdownRender:e=>(0,l.jsxs)(l.Fragment,{children:[e,(0,l.jsx)(h.Divider,{style:{marginTop:"0.5rem",marginBottom:"0.5rem",marginLeft:"0rem",marginRight:"0rem"}}),(0,l.jsxs)(h.Space.Compact,{style:{width:"100%"},children:[(0,l.jsx)(h.Input,{placeholder:b.formatMessage({id:"components.user-selector.placeholder",defaultMessage:"请输入关键字"}),value:w,onChange:e=>{f(e.target.value)}}),(0,l.jsx)(h.Button,{loading:m,type:"primary",onClick:()=>{d(w)},children:b.formatMessage({id:"components.user-selector.search",defaultMessage:"搜索"})})]})]})},ref:s,proFieldProps:r,...c,children:t})})),PFe=LFe,RFe=AFe;RFe.SearchSelect=PFe,RFe.displayName="ProFormComponent";const jFe=RFe,HFe=e=>{const{intl:t,globalFunctions:n,inputRef:r}=(()=>{const{intl:e,globalFunctions:t}=v();return{intl:e,globalFunctions:t,inputRef:(0,u.useRef)(null)}})();return(0,l.jsxs)(d.ProCard,{style:{width:"100%"},bodyStyle:{padding:10},bordered:!0,onClick:()=>{r&&r.current.focus()},children:[(0,l.jsx)(h.Input.TextArea,{showCount:!0,autoSize:!0,maxLength:e.maxLength,ref:r,variant:"borderless",placeholder:e.placeholder,onChange:t=>{e.onInputChange.call(void 0,t.target.value)}}),(0,l.jsx)(h.Upload,{maxCount:e.maxFile,action:n.getUploadUrl.call(void 0,e.configCode),listType:"picture",defaultFileList:e.defaultFileList,headers:{Authorization:e.accessToken},onRemove:t=>{e.onFileRemove.call(void 0,t)},onChange:({file:t})=>{t&&e.onFileChange.call(void 0,t)},children:(0,l.jsx)(h.Tooltip,{title:t.formatMessage({id:"components.attachment-text.appendix",defaultMessage:"点击上传附件"}),children:(0,l.jsx)(h.Button,{type:"text",icon:(0,l.jsx)(ige,{})})})})]})},BFe=lVe,VFe=e=>{const{mode:t,loading:n,initialState:r,headerHeight:a,token:i}=(()=>{const{initialState:e}=v(),t="mix"!==e.settings.layout?0:e?.settings?.token?.header?.heightLayoutHeader??56,{token:n}=h.theme.useToken(),[r,a]=(0,u.useState)(Wt.getThemeMode()),[i,o]=(0,u.useState)(!0);return(0,u.useEffect)((()=>{const e=e=>{e="light"===e?"light":"realDark",Wt.setThemeMode(e),a(void 0),setTimeout((()=>{a(e)}),1)};return setTimeout((()=>{o(!1)}),800),Bt.eventEmitter.on(Nt.THEME_MODE,e),()=>{Bt.eventEmitter.off(Nt.THEME_MODE,e)}}),[]),{mode:r,loading:i,initialState:e,headerHeight:t,token:n}})();return t&&(0,l.jsx)(h.Watermark,{content:e.watermark,children:(0,l.jsx)(BFe,{onResize:t=>{e.onResponsive?.call(void 0,t.width<(e.responsiveWidth??i.screenSM)),e.onResize?.call(void 0,t)},children:(0,l.jsx)("div",{ref:e.scrollbarsRef,style:{height:0===a?"100vh":`calc(100vh - ${a}px)`,overflow:"auto"},children:(0,l.jsxs)(d.PageContainer,{...e,children:[(0,l.jsx)(d.ProCard,{ghost:!(!1!==e.animate&&e.loadDuringAnimate&&n||e.loading),className:!1===e.animate?"":`animate__animated animate__${e.animate??"fadeInRight"} animate__fast`,loading:!1!==e.animate&&e.loadDuringAnimate&&n||e.loading,children:e.children}),r?.currentTheme?.copyright&&(0,l.jsx)(d.DefaultFooter,{copyright:r?.currentTheme?.copyright,links:r?.currentTheme?.links.map(((e,t)=>({key:`${t}`,title:e.key,href:e.value,blankTarget:!0}))),style:{background:"none"}})]})})})})},NFe=e=>{const{isChild:t}=(e=>{const[t,n]=(0,u.useState)(!0);return(0,u.useLayoutEffect)((()=>{n(!e.location.endsWith(e.path))}),[e.location]),{isChild:t}})(e);return t?e.children:e.home};var IFe=n(8365),FFe=n(1552),DFe=n(5072),$Fe=n.n(DFe),WFe=n(7825),qFe=n.n(WFe),UFe=n(7659),GFe=n.n(UFe),KFe=n(5056),YFe=n.n(KFe),XFe=n(540),ZFe=n.n(XFe),QFe=n(1113),JFe=n.n(QFe),eDe=n(2795),tDe={};tDe.styleTagTransform=JFe(),tDe.setAttributes=YFe(),tDe.insert=GFe().bind(null,"head"),tDe.domAPI=qFe(),tDe.insertStyleElement=ZFe(),$Fe()(eDe.A,tDe),eDe.A&&eDe.A.locals&&eDe.A.locals;const nDe=new FFe.Converter({tables:!0,simplifiedAutoLink:!0,strikethrough:!0,tasklists:!0}),rDe=e=>{const{intl:t,selectedTab:n,setSelectedTab:r}=(()=>{const{intl:e}=v(),[t,n]=(0,u.useState)("write");return{intl:e,selectedTab:t,setSelectedTab:n}})();return(0,l.jsx)(IFe.default,{childProps:{writeButton:{style:{color:"black",paddingRight:4,paddingLeft:4}},previewButton:{style:{color:"black",paddingRight:4,paddingLeft:4}},textArea:{style:{color:"black",minHeight:"400px"}}},value:e.value,onChange:e.onChange,selectedTab:n,onTabChange:r,l18n:{write:t.formatMessage({id:"components.markdown-editor.write",defaultMessage:"编辑"}),preview:t.formatMessage({id:"components.markdown-editor.preview",defaultMessage:"预览"}),uploadingImage:t.formatMessage({id:"components.markdown-editor.uploading-image",defaultMessage:"上传图片"}),pasteDropSelect:t.formatMessage({id:"components.markdown-editor.paste-drop-select",defaultMessage:"粘贴下拉选择"})},generateMarkdownPreview:e=>Promise.resolve(nDe.makeHtml(e))})},aDe=f().forwardRef(((e,t)=>(0,l.jsx)(d.ProFormUploadButton,{...e,ref:t}))),iDe=e=>{const{intl:t,globalFunctions:n,value:r,onFileChange:a}=(e=>{const{intl:t,globalFunctions:n}=v(),[r,a]=(0,u.useState)([]),i=(0,u.useCallback)((({file:t,fileList:r})=>{t&&("done"===t.status?t.response&&1===t.response.code?(e.afterSuccess?.call(void 0),console.log(1,t),e.onChange?.call(void 0,[{uid:t.response.data.guid,name:t.name,status:"done",url:n.getPreviewUrl.call(void 0,t.response.data.guid)}])):e.afterFail?.call(void 0,t.response.message):"removed"===t.status||0===r.length?e.onChange?.call(void 0,void 0):e.onChange?.call(void 0,r))}),[e.afterSuccess,e.onChange,e.afterFail,n]);return(0,u.useEffect)((()=>{e.purity&&$t.isNotNullAndUndefined(e.value)&&e.value.length>0?a([{uid:e.value,status:"done",url:n.getPreviewUrl.call(void 0,e.value)}]):a([])}),[e.value]),{intl:t,globalFunctions:n,value:r,onFileChange:i}})(e);return(0,l.jsx)(aDe,{title:t.formatMessage({id:"components.single-image-uploader.upload-button",defaultMessage:"单击上传"}),name:e.name,label:e.label,rules:e.rules,max:1,fieldProps:{name:"file",fileList:r,listType:"picture-card",headers:{Authorization:e.headers?.accessToken,Language:e.headers?.locale,"Client-Id":e.headers?.clientId},onChange:a},action:n.getUploadUrl.call(void 0,e.fileCode)})},oDe=e=>(0,l.jsx)($Pe.ProForm.Item,{name:e.name,style:{marginBottom:0},getValueFromEvent:t=>e.purity?t&&t.length>0?t[0].uid:void 0:t,children:(0,l.jsx)(iDe,{...e})}),cDe=e=>e.childrenRender?e.childrenRender(e.children,e.messageHolder,e.notificationHolder,e.globalState):e.children,sDe=e=>{const[t,n]=h.message.useMessage(),[r,a]=h.notification.useNotification();return(0,u.useEffect)((()=>{const e=({level:e,content:n})=>t[e](n),n=({level:e,config:t})=>r[e](t);return Bt.eventEmitter.on(Nt.MESSAGE,e),Bt.eventEmitter.on(Nt.NOTIFICATION,n),()=>{Bt.eventEmitter.off(Nt.MESSAGE,e),Bt.eventEmitter.off(Nt.NOTIFICATION,n)}}),[e]),{messageHolder:n,notificationHolder:a}},lDe=(e,t)=>e.map((({path:e,guid:n,icon:r,children:a,hideStatus:i,i18n:o,...c})=>{const s=o.filter((e=>e.locale===t));let u;return u=s.length>0?s[0].name:o[0].name,{...c,name:u,hideInMenu:0===i,icon:r&&(0,l.jsx)(FPe,{name:r}),children:a&&lDe(a,t),key:n,path:e}})),uDe=(e,t,n)=>{e&&t&&e.forEach((e=>{t.includes(e.key)&&!e.hideInMenu&&n.push(e),e.children&&uDe(e.children,t,n)}))},fDe=(e,t)=>{const n=Wt.getQuickMethod(t),r=[];return uDe(e,n,r),r.map(((e,t)=>({key:t,icon:e.icon,title:e.name,url:e.path})))},dDe=async e=>{const t=async()=>{let t;try{t=await e.getUserInitDetail.call(void 0)}catch(t){return void vDe.executeLogout(e.history,e.loginLoadPath)}if(1===t.code&&t.data){const n=t.data;return n.menuList&&(n.menuList=lDe(n.menuList,e.getLocale.call(void 0))),n.avatar&&(n.avatar=e.getPreviewUrl.call(void 0,n.avatar)),n}vDe.executeLogout(e.history,e.loginLoadPath)},n=async()=>{const t=await e.getCurrentThemeDetail.call(void 0);if(1===t.code&&t.data){if(t.data.favicons){const n=document.querySelector("link[rel*='icon']")||document.createElement("link");n.type="image/x-icon",n.rel="shortcut icon",n.href=e.getPreviewUrl.call(void 0,t.data.favicons),document.getElementsByTagName("head")[0].appendChild(n)}return t.data}},{location:r}=e.history,a=Wt.getThemeMode(),i=e.defaultSettings;return i.navTheme=a,r.pathname.endsWith(e.loginLoadPath)?{settings:i,currentTheme:await n(),fetchUserInfo:t,fetchThemeInfo:n}:{settings:i,currentUser:await t(),currentTheme:await n(),fetchUserInfo:t,fetchThemeInfo:n}},hDe=e=>{const{messageHolder:t,notificationHolder:n}=sDe(),{layout:r,splitMenus:a,title:i,logo:o,...c}=e.globalState.initialState?.settings??{},s=window.__POWERED_BY_QIANKUN__?"side":r;return(0,u.useEffect)((()=>{const t=Wt.getThemeMode();e.globalState.initialState?.settings.navTheme&&e.globalState.initialState?.settings.navTheme!==t&&e.setInitialState.call(void 0,(n=>{const r=(0,D.cloneDeep)(e.globalState.initialState.settings);return r.navTheme=t,{...n,settings:r}}));const n=t=>{e.setInitialState.call(void 0,(n=>{const r=(0,D.cloneDeep)(e.globalState.initialState.settings);return r.navTheme=t,{...n,settings:r}}))};return Bt.eventEmitter.on(Nt.THEME_MODE,n),()=>{Bt.eventEmitter.off(Nt.THEME_MODE,n)}}),[e.globalState.initialState?.settings.navTheme]),{menu:{locale:!1,request:()=>e.globalState.initialState.currentUser.menuList},actionsRender:()=>window.__POWERED_BY_QIANKUN__?[]:[...e.headerOperations??[],(0,l.jsx)(qt,{},"theme"),f().cloneElement(e.selectLang,{key:"localeChange"})],avatarProps:{src:e.globalState.initialState?.currentUser?.avatar,title:f().cloneElement(e.avatarName,{key:"avatarName"}),render:(t,n)=>f().cloneElement(e.avatarDropdown,{key:"avatarDropdown"},n)},footerRender:void 0,onPageChange:t=>{e.globalState.initialState?.currentUser||t.pathname.endsWith(e.loginLoadPath)||e.history.push(e.loginLoadPath)},bgLayoutImgList:[{src:e.globalState.globalFunctions.getPreviewUrl(e.globalState.initialState?.currentTheme?.backgroundImg),bottom:0,left:0,height:"100%"}],appList:fDe(e.globalState.initialState?.currentUser?.menuList,e.clientId),links:[],menuHeaderRender:void 0,childrenRender:r=>(0,l.jsx)(cDe,{...e,currentLayout:s,messageHolder:t,notificationHolder:n,children:r}),layout:s,splitMenus:!window.__POWERED_BY_QIANKUN__&&a,title:e.globalState.initialState?.currentTheme?.title??i,logo:e.globalState.globalFunctions.getPreviewUrl(e.globalState.initialState?.currentTheme?.icon)??o,...c}};var pDe=n(7186);const vDe={convertPageParam:async(e,t,n,r)=>{const a={...t};void 0!==a.current&&(a.pageNum=a.current,a.current=void 0),n&&(a.sort=n),a.filter=r;for(const e in a)Array.isArray(a[e])&&(a[e]=String(a[e]));const i=await e(a);return 1===i.code?{data:i.data,success:!0,total:i.total}:{data:i.message,success:!1,total:i.total}},downloadFile:(e,t)=>{if(!e)return;const n=document.createElement("a");n.href=e,n.download=t,document.body.appendChild(n),n.click(),document.body.removeChild(n)},executeLogout:(e,t)=>{const{search:n,pathname:r}=window.location,a=new URL(window.location.href).searchParams.get("redirect");window.location.pathname.endsWith(t)||a||e.replace({pathname:t,search:(0,pDe.stringify)({redirect:r+n})})},getOAuth2Url:(e,t,n,r,a)=>{const i=new URL(`${n}/authorization/oauth2/authorize?`);for(const e in r)"client_secret"!==e&&i.searchParams.set(e,r[e]);let o;const c=new URL(window.location.href);return c.searchParams.delete("code"),c.searchParams.delete("state"),a&&c.searchParams.set("redirect",a),o=c.toString(),i.searchParams.set("redirect_uri",o),i.searchParams.set("state",JSON.stringify({locale:e,theme:t})),i.toString()},getExternalAuthUrl:(e,t,n,r,a,i)=>{const o=new URL(e),c=new URL(window.location.href);return c.search="",c.pathname=a,o.searchParams.set("redirect_uri",c.toString()),o.searchParams.set("state",JSON.stringify({locale:t,theme:n,external_guid:r,user_guid:i})),o.toString().replace(/%3A/g,":")},getExternalAuthUrl4Auth:function(e,t,n,r,a){const i=new URL(t),o=new URL(e);return i.searchParams.set("redirect_uri",o.toString()),i.searchParams.set("state",JSON.stringify({locale:n,theme:r,external_guid:a})),i.toString().replace(/%3A/g,":")}},mDe=e=>{const{intl:t,initialState:n}=v(),[r,a]=(0,u.useState)(void 0),i=async()=>{const t=await(n?.fetchUserInfo?.call(void 0));t&&(0,TBe.flushSync)((()=>{e.setInitialState.call(void 0,(e=>({...e,currentUser:t})))}));const r=await(n?.fetchThemeInfo?.call(void 0));r&&(0,TBe.flushSync)((()=>{e.setInitialState.call(void 0,(e=>({...e,currentTheme:r})))}))},o=async(t,n)=>{if(1===t.code){if(L.getDb().delete(),Wt.setToken(t.data),await i(),window.__POWERED_BY_QIANKUN__){const{pathname:t}=window.location,r=t.replace(e.loginLoadPath,"");r&&n.redirect.startsWith(r)&&(n.redirect=n.redirect.replace(new RegExp(`^${r}`),""))}e.onFinish.call(void 0,n.redirect,void 0)}else a(t.message)},c=(e,t)=>{const n=document.createElement("script");n.src=e,n.async=!0,n.onload=t,document.body.appendChild(n)};return(0,u.useEffect)((()=>{(async()=>{const t=(()=>{const t=e.searchParams.get("code"),n=e.searchParams.get("state"),r=e.searchParams.get("redirect")??"/";let a=null,i=null,o=null,c=null;if(n){let e;try{e=JSON.parse(n)}catch{e=null}e&&(a=e.locale,i=e.theme,o=e.external_guid,c=e.user_guid)}return{code:t,state:n,redirect:r,locale:a,theme:i,externalGuid:o,userGuid:c}})();t.locale&&e.setLocale.call(void 0,t.locale,!1),t.theme&&Wt.setThemeMode("realDark"===t.theme?"realDark":"light"),t.code?t.externalGuid&&t.userGuid?(async t=>{const n=new URL(window.location.href);n.search="";const r=await e.bindExternalData.call(void 0,{guid:t.externalGuid,code:t.code,redirectUrl:n.toString()}),a=Wt.getBeforeExternalBindPathname();if(1===r.code){await i();const t=r.data.i18n.filter((t=>e.locale===t.locale));e.onFinish.call(void 0,void 0!==a?a:"/user-center",{external:t[0].title,externalBindResult:!0})}else e.onFinish.call(void 0,void 0!==a?a:"/user-center",{external:r.message,externalBindResult:!1})})(t):(async t=>{let n;if(t.externalGuid){const r=new URL(window.location.href),a=new URLSearchParams;r.searchParams.has("redirect")&&a.set("redirect",r.searchParams.get("redirect")),r.search=a.toString(),n=await e.getTokenByCode.call(void 0,{code:t.code,external_guid:t.externalGuid,external_redirect_uri:encodeURIComponent(r.toString())})}else n=await e.getTokenByCode.call(void 0,{code:t.code});await o(n,t)})(t):(t=>{if(Wt.getActiveLogout())return Wt.removeToken(),void(window.location.href=vDe.getOAuth2Url(e.locale,Wt.getThemeMode(),e.gatewayUrl,e.clientConfig,t.redirect));if(!e.externalIntegrationConfig||e.externalIntegrationConfig.length<1)return Wt.removeToken(),void(window.location.href=vDe.getOAuth2Url(e.locale,Wt.getThemeMode(),e.gatewayUrl,e.clientConfig,t.redirect));for(const n of e.externalIntegrationConfig)"feishu"===n.platform&&c("https://lf1-cdn-tos.bytegoofy.com/goofy/lark/op/h5-js-sdk-1.5.26.js",(()=>{window.h5sdk&&window.tt.requestAccess?window.tt.requestAccess({appID:n.appId,scopeList:[],success:async({code:r})=>{const a=new URL(window.location.href);a.search="";const i=await e.getTokenByCode.call(void 0,{code:r,external_client_id:n.appId,external_redirect_uri:a.toString(),platform:n.platform});await o(i,t)},fail:({errString:e})=>{a(e)}}):window.location.href=vDe.getOAuth2Url(e.locale,Wt.getThemeMode(),e.gatewayUrl,e.clientConfig,t.redirect)}))})(t)})()}),[]),{setExceptionMsg:a,exceptionMsg:r,intl:t}},gDe=h.Result,yDe=e=>{const{setExceptionMsg:t,exceptionMsg:n,intl:r}=mDe(e);return(0,l.jsx)(l.Fragment,{children:void 0===n?(0,l.jsx)(h.Spin,{percent:"auto",size:"large"}):(0,l.jsx)(gDe,{status:"500",title:n,extra:(0,l.jsx)(h.Button,{type:"primary",onClick:()=>{t(void 0),window.location.href=vDe.getOAuth2Url(e.locale,Wt.getThemeMode(),e.gatewayUrl,e.clientConfig)},children:r.formatMessage({id:"components.auth-frame.operation.back-auth",defaultMessage:"返回授权页面"})})})})},bDe=e=>{const{setCurrent:t,setLoading:n,steps:r,mailStep:a,externalStep:i,current:o,loading:c,externalBind:s}=(e=>{const{intl:t}=v(),[n,r]=(0,u.useState)(!1),[a,i]=(0,u.useState)({}),[o,c]=(0,u.useState)([]),[s,f]=(0,u.useState)(0),[d,h]=(0,u.useState)(),[p,m]=(0,u.useState)(),[g,y]=(0,u.useState)();return(0,u.useEffect)((()=>{(async()=>{const n=await e.getUserForceBind.call(void 0),r=[];1===n.code?(n.data&&(n.data.mailForce&&(r.push({title:t.formatMessage({id:"components.bind-frame.title.mail-force",defaultMessage:"绑定邮箱"}),icon:(0,l.jsx)(yG,{})}),h(r.length-1)),n.data.passwordForce&&(r.push({title:t.formatMessage({id:"components.bind-frame.title.password-force",defaultMessage:"重置密码"}),icon:(0,l.jsx)(Jhe,{})}),m(r.length-1)),n.data.externalForceList&&n.data.externalForceList.length>0&&(r.push({title:t.formatMessage({id:"components.bind-frame.title.external-force",defaultMessage:"绑定外部授权"}),icon:(0,l.jsx)(s0,{})}),y(r.length-1),i(n.data.externalForceList))),c(r)):i([]),r.length<1&&e.onFinish.call(void 0)})()}),[]),{setCurrent:f,setLoading:r,steps:o,mailStep:d,externalStep:g,current:s,loading:n,externalBind:a}})(e);return(0,l.jsx)(l.Fragment,{children:r&&r.length>0?(0,l.jsxs)(AQ,{style:{maxWidth:"36rem"},hoverable:!e.responsive,bordered:!e.responsive,children:[(0,l.jsx)(h.Steps,{size:"small",items:r,current:o}),(0,l.jsx)(h.Divider,{dashed:!0}),void 0!==a&&a===o&&(0,l.jsx)(l.Fragment,{children:f().cloneElement(e.mailBindFrame,{key:"mail-bind-frame",onFinish:n=>{o+1>=r.length?e.onFinish.call(void 0):t(o+1)}})}),void 0!==i&&i===o&&(0,l.jsx)(h.Spin,{spinning:c,children:f().cloneElement(e.externalAuthFrame,{key:"external-auth-frame",externalFilterList:s,onLoadChange:e=>{n(e)}})})]}):(0,l.jsx)(h.Spin,{percent:"auto",size:"large"})})},wDe={setScale:(e,t=2)=>{const n=Math.pow(10,t);return Math.round(e*n)/n}},xDe={randomStr:e=>{let t="";for(let n=0;n<e;n++)t+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"[Math.floor(62*Math.random())];return t}},MDe={fromUnicode:e=>e.replace(/\\u([\dA-Fa-f]{4})/g,((e,t)=>String.fromCharCode(parseInt(t,16)))),toUnicode:e=>encodeURIComponent(e).replace(/%/g,"\\u").replace(/\\u([0-9a-fA-F]{2})/g,((e,t)=>"\\u00"+t))},kDe={generateUploadFile:(e,t,n,r)=>{if(e[t]&&e[n])return[{uid:e[n],name:e[t],status:"done",url:r.call(void 0,e[n])}]}},ODe=()=>{const{getLocale:e,globalFunctions:t}=v(),n=async n=>{const r=L.getDb();r.version(1).stores({sys_dict:"++id, type, name, enName, value, color, sort"});let a=await r.sys_dict.where("type").equals(n).sortBy("sort");if(0===a.length){const e=await(t?.getDictDataByType.call(void 0,n));1===e.code&&(a=e.data,a.length>0&&r.sys_dict.bulkPut(a.map((e=>({...e,type:n})))))}return a.map((t=>{const r=t.i18n.filter((t=>t.locale===e()));let a;return a=r.length>0?r[0].name:t.i18n[0].name,{type:n,label:a,value:t.value,color:t.color,sort:t.sort}}))};return{getDataByType:n,getTagDataByType:async e=>(await n(e)).map((e=>({label:(0,l.jsx)(h.Tag,{style:{maxWidth:"100%"},bordered:!0,color:e.color,children:(0,l.jsx)(h.Typography.Text,{ellipsis:{tooltip:e.label},children:e.label})}),value:isNaN(Number(e.value))?e.value:Number(e.value),title:e.label})))}},zDe=()=>({info:e=>Bt.pushMessageEvent("info",e),success:e=>Bt.pushMessageEvent("success",e),error:e=>Bt.pushMessageEvent("error",e),warning:e=>Bt.pushMessageEvent("warning",e),loading:e=>Bt.pushMessageEvent("loading",e)}),_De=()=>({info:e=>Bt.pushNotificationEvent("info",e),success:e=>Bt.pushNotificationEvent("success",e),error:e=>Bt.pushNotificationEvent("error",e),warning:e=>Bt.pushNotificationEvent("warning",e),loading:e=>Bt.pushNotificationEvent("loading",e)}),SDe={outlinedConstants:["StepBackwardOutlined","StepForwardOutlined","FastBackwardOutlined","FastForwardOutlined","ShrinkOutlined","ArrowsAltOutlined","DownOutlined","UpOutlined","LeftOutlined","RightOutlined","CaretUpOutlined","CaretDownOutlined","CaretLeftOutlined","CaretRightOutlined","UpCircleOutlined","DownCircleOutlined","LeftCircleOutlined","RightCircleOutlined","DoubleRightOutlined","DoubleLeftOutlined","VerticalLeftOutlined","VerticalRightOutlined","VerticalAlignTopOutlined","VerticalAlignMiddleOutlined","VerticalAlignBottomOutlined","ForwardOutlined","BackwardOutlined","RollbackOutlined","EnterOutlined","RetweetOutlined","SwapOutlined","SwapLeftOutlined","SwapRightOutlined","ArrowUpOutlined","ArrowDownOutlined","ArrowLeftOutlined","ArrowRightOutlined","PlayCircleOutlined","UpSquareOutlined","DownSquareOutlined","LeftSquareOutlined","RightSquareOutlined","LoginOutlined","LogoutOutlined","MenuFoldOutlined","MenuUnfoldOutlined","BorderBottomOutlined","BorderHorizontalOutlined","BorderInnerOutlined","BorderOuterOutlined","BorderLeftOutlined","BorderRightOutlined","BorderTopOutlined","BorderVerticleOutlined","PicCenterOutlined","PicLeftOutlined","PicRightOutlined","RadiusBottomleftOutlined","RadiusBottomrightOutlined","RadiusUpleftOutlined","RadiusUprightOutlined","FullscreenOutlined","FullscreenExitOutlined","QuestionOutlined","QuestionCircleOutlined","PlusOutlined","PlusCircleOutlined","PauseOutlined","PauseCircleOutlined","MinusOutlined","MinusCircleOutlined","PlusSquareOutlined","MinusSquareOutlined","InfoOutlined","InfoCircleOutlined","ExclamationOutlined","ExclamationCircleOutlined","CloseOutlined","CloseCircleOutlined","CloseSquareOutlined","CheckOutlined","CheckCircleOutlined","CheckSquareOutlined","ClockCircleOutlined","WarningOutlined","IssuesCloseOutlined","StopOutlined","EditOutlined","FormOutlined","CopyOutlined","ScissorOutlined","DeleteOutlined","SnippetsOutlined","DiffOutlined","HighlightOutlined","AlignCenterOutlined","AlignLeftOutlined","AlignRightOutlined","BgColorsOutlined","BoldOutlined","ItalicOutlined","UnderlineOutlined","StrikethroughOutlined","RedoOutlined","UndoOutlined","ZoomInOutlined","ZoomOutOutlined","FontColorsOutlined","FontSizeOutlined","LineHeightOutlined","DashOutlined","SmallDashOutlined","SortAscendingOutlined","SortDescendingOutlined","DragOutlined","OrderedListOutlined","UnorderedListOutlined","RadiusSettingOutlined","ColumnWidthOutlined","ColumnHeightOutlined","AreaChartOutlined","PieChartOutlined","BarChartOutlined","DotChartOutlined","LineChartOutlined","RadarChartOutlined","HeatMapOutlined","FallOutlined","RiseOutlined","StockOutlined","BoxPlotOutlined","FundOutlined","SlidersOutlined","AndroidOutlined","AppleOutlined","WindowsOutlined","IeOutlined","ChromeOutlined","GithubOutlined","AliwangwangOutlined","DingdingOutlined","WeiboSquareOutlined","WeiboCircleOutlined","TaobaoCircleOutlined","Html5Outlined","WeiboOutlined","TwitterOutlined","WechatOutlined","WhatsAppOutlined","YoutubeOutlined","AlipayCircleOutlined","TaobaoOutlined","DingtalkOutlined","SkypeOutlined","QqOutlined","MediumWorkmarkOutlined","GitlabOutlined","MediumOutlined","LinkedinOutlined","GooglePlusOutlined","DropboxOutlined","FacebookOutlined","CodepenOutlined","CodeSandboxOutlined","AmazonOutlined","GoogleOutlined","CodepenCircleOutlined","AlipayOutlined","AntDesignOutlined","AntCloudOutlined","AliyunOutlined","ZhihuOutlined","SlackOutlined","SlackSquareOutlined","BehanceOutlined","BehanceSquareOutlined","DribbbleOutlined","DribbbleSquareOutlined","InstagramOutlined","YuqueOutlined","AlibabaOutlined","YahooOutlined","RedditOutlined","SketchOutlined","AccountBookOutlined","AimOutlined","AlertOutlined","ApartmentOutlined","ApiOutlined","AppstoreAddOutlined","AppstoreOutlined","AudioOutlined","AudioMutedOutlined","AuditOutlined","BankOutlined","BarcodeOutlined","BarsOutlined","BellOutlined","BlockOutlined","BookOutlined","BorderOutlined","BorderlessTableOutlined","BranchesOutlined","BugOutlined","BuildOutlined","BulbOutlined","CalculatorOutlined","CalendarOutlined","CameraOutlined","CarOutlined","CarryOutOutlined","CiCircleOutlined","CiOutlined","ClearOutlined","CloudDownloadOutlined","CloudOutlined","CloudServerOutlined","CloudSyncOutlined","CloudUploadOutlined","ClusterOutlined","CodeOutlined","CoffeeOutlined","CommentOutlined","CompassOutlined","CompressOutlined","ConsoleSqlOutlined","ContactsOutlined","ContainerOutlined","ControlOutlined","CopyrightOutlined","CreditCardOutlined","CrownOutlined","CustomerServiceOutlined","DashboardOutlined","DatabaseOutlined","DeleteColumnOutlined","DeleteRowOutlined","DeliveredProcedureOutlined","DeploymentUnitOutlined","DesktopOutlined","DisconnectOutlined","DislikeOutlined","DollarOutlined","DownloadOutlined","EllipsisOutlined","EnvironmentOutlined","EuroCircleOutlined","EuroOutlined","ExceptionOutlined","ExpandAltOutlined","ExpandOutlined","ExperimentOutlined","ExportOutlined","EyeOutlined","EyeInvisibleOutlined","FieldBinaryOutlined","FieldNumberOutlined","FieldStringOutlined","FieldTimeOutlined","FileAddOutlined","FileDoneOutlined","FileExcelOutlined","FileExclamationOutlined","FileOutlined","FileGifOutlined","FileImageOutlined","FileJpgOutlined","FileMarkdownOutlined","FilePdfOutlined","FilePptOutlined","FileProtectOutlined","FileSearchOutlined","FileSyncOutlined","FileTextOutlined","FileUnknownOutlined","FileWordOutlined","FileZipOutlined","FilterOutlined","FireOutlined","FlagOutlined","FolderAddOutlined","FolderOutlined","FolderOpenOutlined","FolderViewOutlined","ForkOutlined","FormatPainterOutlined","FrownOutlined","FunctionOutlined","FundProjectionScreenOutlined","FundViewOutlined","FunnelPlotOutlined","GatewayOutlined","GifOutlined","GiftOutlined","GlobalOutlined","GoldOutlined","GroupOutlined","HddOutlined","HeartOutlined","HistoryOutlined","HolderOutlined","HomeOutlined","HourglassOutlined","IdcardOutlined","ImportOutlined","InboxOutlined","InsertRowAboveOutlined","InsertRowBelowOutlined","InsertRowLeftOutlined","InsertRowRightOutlined","InsuranceOutlined","InteractionOutlined","KeyOutlined","LaptopOutlined","LayoutOutlined","LikeOutlined","LineOutlined","LinkOutlined","Loading3QuartersOutlined","LoadingOutlined","LockOutlined","MacCommandOutlined","MailOutlined","ManOutlined","MedicineBoxOutlined","MehOutlined","MenuOutlined","MergeCellsOutlined","MessageOutlined","MobileOutlined","MoneyCollectOutlined","MonitorOutlined","MoreOutlined","NodeCollapseOutlined","NodeExpandOutlined","NodeIndexOutlined","NotificationOutlined","NumberOutlined","OneToOneOutlined","PaperClipOutlined","PartitionOutlined","PayCircleOutlined","PercentageOutlined","PhoneOutlined","PictureOutlined","PlaySquareOutlined","PoundCircleOutlined","PoundOutlined","PoweroffOutlined","PrinterOutlined","ProfileOutlined","ProjectOutlined","PropertySafetyOutlined","PullRequestOutlined","PushpinOutlined","QrcodeOutlined","ReadOutlined","ReconciliationOutlined","RedEnvelopeOutlined","ReloadOutlined","RestOutlined","RobotOutlined","RocketOutlined","RotateLeftOutlined","RotateRightOutlined","SafetyCertificateOutlined","SafetyOutlined","SaveOutlined","ScanOutlined","ScheduleOutlined","SearchOutlined","SecurityScanOutlined","SelectOutlined","SendOutlined","SettingOutlined","ShakeOutlined","ShareAltOutlined","ShopOutlined","ShoppingCartOutlined","ShoppingOutlined","SisternodeOutlined","SkinOutlined","SmileOutlined","SolutionOutlined","SoundOutlined","SplitCellsOutlined","StarOutlined","SubnodeOutlined","SwitcherOutlined","SyncOutlined","TableOutlined","TabletOutlined","TagOutlined","TagsOutlined","TeamOutlined","ThunderboltOutlined","ToTopOutlined","ToolOutlined","TrademarkCircleOutlined","TrademarkOutlined","TransactionOutlined","TranslationOutlined","TrophyOutlined","UngroupOutlined","UnlockOutlined","UploadOutlined","UsbOutlined","UserAddOutlined","UserDeleteOutlined","UserOutlined","UserSwitchOutlined","UsergroupAddOutlined","UsergroupDeleteOutlined","VerifiedOutlined","VideoCameraAddOutlined","VideoCameraOutlined","WalletOutlined","WifiOutlined","WomanOutlined"]},EDe={"components.data-table.pagination.total":"总","components.file-tag.operation.preview-pdf":"预览PDF","components.file-tag.operation.download":"下载","components.user-card.unknown":"未知用户","components.user-card.is-me":"(我)","components.user-card.phone":"手机号码","components.user-card.email":"邮箱地址","components.user-card.sex":"性别","components.user-card.status":"状态","components.user-card.role":"角色","components.user-selector.placeholder":"请输入关键字","components.user-selector.search":"搜索","components.attachment-text.appendix":"点击上传附件","components.markdown-editor.write":"编辑","components.markdown-editor.preview":"预览","components.markdown-editor.uploading-image":"上传图片","components.markdown-editor.paste-drop-select":"粘贴下拉选择","components.single-image-uploader.upload-button":"单击上传","components.auth-frame.operation.back-auth":"返回授权页面","components.bind-frame.title.mail-force":"绑定邮箱","components.bind-frame.title.password-force":"重置密码","components.bind-frame.title.external-force":"绑定外部授权","components.constants.status-list.enable":"启用","components.constants.status-list.disable":"停用","components.constants.sex-list.secret":"保密","components.constants.sex-list.male":"男","components.constants.sex-list.female":"女"},CDe={"components.data-table.pagination.total":"Total","components.file-tag.operation.preview-pdf":"Preview PDF","components.file-tag.operation.download":"Download","components.user-card.unknown":"Unknown user","components.user-card.is-me":"(Me)","components.user-card.phone":"Phone number","components.user-card.email":"Email address","components.user-card.sex":"Gender","components.user-card.status":"Status","components.user-card.role":"Role","components.user-selector.placeholder":"Please enter keywords","components.user-selector.search":"Search","components.attachment-text.appendix":"Click to upload attachment","components.markdown-editor.write":"Edit","components.markdown-editor.preview":"Preview","components.markdown-editor.uploading-image":"Upload image","components.markdown-editor.paste-drop-select":"Paste drop-down selection","components.single-image-uploader.upload-button":"Click Upload","components.auth-frame.operation.back-auth":"Return to Authorization Page","components.bind-frame.title.mail-force":"Bind Email","components.bind-frame.title.password-force":"Reset Password","components.bind-frame.title.external-force":"Bind External Authorization","components.constants.status-list.enable":"Enable","components.constants.status-list.disable":"disable","components.constants.sex-list.secret":"Secret","components.constants.sex-list.male":"Male","components.constants.sex-list.female":"female"},TDe={RbDataTable:W,RbActionBarItem:U,RbActionBar:G,RbThemeSetter:qt,RbDataChart:_U,RbFileTag:lG,RbUserCard:jQ,RbIconRender:FPe,RbHtmlRender:DPe,RbDragTable:TFe,RbUserSelector:jFe,RbAttachmentText:HFe,RbPageContainer:VFe,RbRouteWrapper:NFe,RbMarkdownConverter:nDe,RbMarkdownEditor:rDe,RbSingleImageUploader:oDe,RbAuthFrame:yDe,RbBindFrame:bDe,RbGlobalContext:p}})(),module.exports=r})();
28
+ `}))),TFe=e=>{const{setTableLoading:t,responsive:n,styles:r,tableLoading:a,restProps:i,actionRef:o}=(e=>{const[t,n]=(0,u.useState)(),[r,a]=(0,u.useState)(!1),i=(0,u.useRef)(void 0),{request:o,loading:c,columns:s,...l}=e,{styles:f}=CFe();return(0,u.useImperativeHandle)(e.actionRef,(()=>({startLoading:()=>{a(!0)},finishLoading:()=>{a(!1)},...i.current}))),(0,u.useEffect)((()=>{n(e.responsive)}),[e.responsive]),(0,u.useEffect)((()=>{e.loadChange&&e.loadChange.call(void 0,r)}),[r]),{setTableLoading:a,responsive:t,styles:f,tableLoading:r,restProps:l,actionRef:i}})(e);return(0,l.jsx)(EFe,{tableClassName:r.customTable,scroll:{x:1300},rowKey:"guid",search:{labelWidth:120},loading:a,columns:e.columns.map((e=>{const t={...e};return t.fixed=!n&&t.fixed,e})),request:async(n,r,a)=>{let i;t(!0);try{i=await e.request.call(void 0,n,r,a)}finally{t(!1)}return i},...i,actionRef:o},"dragTable"+n)},LFe=f().forwardRef((({fieldProps:e,children:t,params:n,proFieldProps:r,mode:a,valueEnum:i,request:o,options:c,...s},f)=>{const d={options:c,mode:a||"multiple",labelInValue:!0,showSearch:!0,suffixIcon:null,autoClearSearchValue:!0,optionLabelProp:"label",...e},h=(0,u.useContext)($Pe.FieldContext);return(0,l.jsx)($Pe.ProFormField,{valueEnum:vBe(i),params:n,valueType:"select",filedConfig:{customLightMode:!0},fieldProps:{getPopupContainer:h.getPopupContainer,...d},ref:f,proFieldProps:r,...s,children:t})})),AFe=f().forwardRef((({widthControl:e,children:t,params:n,proFieldProps:r,mode:a,valueEnum:i,request:o,...c},s)=>{const{setKeywords:f,onFuzzy:d,start:p,loading:m,context:g,data:y,intl:b,keywords:w}=(({widthControl:e,children:t,params:n,proFieldProps:r,mode:a,valueEnum:i,request:o,userType:c,...s})=>{const{intl:l}=v(),f=(0,u.useContext)($Pe.FieldContext),[d,h]=(0,u.useState)([]),[p,m]=(0,u.useState)(),[g,y]=(0,u.useState)(!1),[b,w]=(0,u.useState)(!1),x=async e=>{y(!0);const t=f.formRef?.current?.getFieldValue(s.name);let n;n=H.isNotNull(t)?await o(e,Array.isArray(t)?t:[t],void 0,c):await o(e,[],void 0,c),1===n.code?h(n.data):h([]),y(!1)};return(0,u.useEffect)((()=>{(async()=>{w(!0),await x(null),w(!1)})()}),[]),(0,u.useEffect)((()=>{if(e){const e=document.getElementsByClassName("ant-form-item-control");for(const t of e){const e=t.getElementsByClassName("ant-col ant-form-item-control");for(const t of e)t.style.maxWidth="none"}}}),[b,e]),{setKeywords:m,onFuzzy:x,start:b,loading:g,context:f,data:d,intl:l,keywords:p}})({widthControl:e,children:t,params:n,proFieldProps:r,mode:a,valueEnum:i,request:o,...c});return(0,l.jsx)($Pe.ProFormField,{valueEnum:vBe(i),params:n,valueType:"select",filedConfig:{customLightMode:!0},fieldProps:p?{value:null,loading:m,mode:a,getPopupContainer:g.getPopupContainer,defaultActiveFirstOption:!1,labelRender:e=>e.title,optionRender:e=>{const t=e.data;return(0,l.jsxs)(h.Space,{children:[(0,l.jsx)(h.Avatar,{size:"default",src:c.avatarPreview(t.avatar),children:t.name[0]}),(0,l.jsxs)(h.Space,{direction:"vertical",size:0,children:[(0,l.jsxs)("span",{children:[(0,l.jsx)("span",{children:t.name}),t.alias&&(0,l.jsx)("span",{children:"("+t.alias+")"})]}),(0,l.jsx)("span",{style:{fontSize:"0.875rem"},children:t.phone})]})]})},options:(y||[]).map((e=>({...e,value:e.guid,label:e.name,title:(0,l.jsxs)(h.Space,{children:[(0,l.jsx)(h.Avatar,{size:"small",src:c.avatarPreview(e.avatar),children:e.name[0]}),(0,l.jsx)("span",{children:(0,l.jsx)("span",{children:e.name})})]})}))),dropdownRender:e=>(0,l.jsxs)(l.Fragment,{children:[e,(0,l.jsx)(h.Divider,{style:{marginTop:"0.5rem",marginBottom:"0.5rem",marginLeft:"0rem",marginRight:"0rem"}}),(0,l.jsxs)(h.Space.Compact,{style:{width:"100%"},children:[(0,l.jsx)(h.Input,{placeholder:b.formatMessage({id:"components.user-selector.placeholder",defaultMessage:"请输入关键字"}),value:w,onChange:e=>{f(e.target.value)}}),(0,l.jsx)(h.Button,{loading:m,type:"primary",onClick:()=>{d(w)},children:b.formatMessage({id:"components.user-selector.search",defaultMessage:"搜索"})})]})]})}:{loading:m,mode:a,getPopupContainer:g.getPopupContainer,defaultActiveFirstOption:!1,labelRender:e=>e.label,optionRender:e=>{const t=e.data;return(0,l.jsxs)(h.Space,{children:[(0,l.jsx)(h.Avatar,{size:"default",src:c.avatarPreview(t.avatar),children:t.name[0]}),(0,l.jsxs)(h.Space,{direction:"vertical",size:0,children:[(0,l.jsxs)("span",{children:[(0,l.jsx)("span",{children:t.name}),t.alias&&(0,l.jsx)("span",{children:"("+t.alias+")"})]}),(0,l.jsx)("span",{style:{fontSize:"0.875rem"},children:t.phone})]})]})},options:(y||[]).map((e=>({...e,value:e.guid,label:(0,l.jsxs)(h.Space,{children:[(0,l.jsx)(h.Avatar,{size:"small",src:c.avatarPreview(e.avatar),children:e.name[0]}),(0,l.jsx)("span",{children:(0,l.jsx)("span",{children:e.name})})]}),title:e.name}))),dropdownRender:e=>(0,l.jsxs)(l.Fragment,{children:[e,(0,l.jsx)(h.Divider,{style:{marginTop:"0.5rem",marginBottom:"0.5rem",marginLeft:"0rem",marginRight:"0rem"}}),(0,l.jsxs)(h.Space.Compact,{style:{width:"100%"},children:[(0,l.jsx)(h.Input,{placeholder:b.formatMessage({id:"components.user-selector.placeholder",defaultMessage:"请输入关键字"}),value:w,onChange:e=>{f(e.target.value)}}),(0,l.jsx)(h.Button,{loading:m,type:"primary",onClick:()=>{d(w)},children:b.formatMessage({id:"components.user-selector.search",defaultMessage:"搜索"})})]})]})},ref:s,proFieldProps:r,...c,children:t})})),PFe=LFe,RFe=AFe;RFe.SearchSelect=PFe,RFe.displayName="ProFormComponent";const jFe=RFe,HFe=e=>{const{intl:t,globalFunctions:n,inputRef:r}=(()=>{const{intl:e,globalFunctions:t}=v();return{intl:e,globalFunctions:t,inputRef:(0,u.useRef)(null)}})();return(0,l.jsxs)(d.ProCard,{style:{width:"100%"},bodyStyle:{padding:10},bordered:!0,onClick:()=>{r&&r.current.focus()},children:[(0,l.jsx)(h.Input.TextArea,{showCount:!0,autoSize:!0,maxLength:e.maxLength,ref:r,variant:"borderless",placeholder:e.placeholder,onChange:t=>{e.onInputChange.call(void 0,t.target.value)}}),(0,l.jsx)(h.Upload,{maxCount:e.maxFile,action:n.getUploadUrl.call(void 0,e.configCode),listType:"picture",defaultFileList:e.defaultFileList,headers:{Authorization:e.accessToken},onRemove:t=>{e.onFileRemove.call(void 0,t)},onChange:({file:t})=>{t&&e.onFileChange.call(void 0,t)},children:(0,l.jsx)(h.Tooltip,{title:t.formatMessage({id:"components.attachment-text.appendix",defaultMessage:"点击上传附件"}),children:(0,l.jsx)(h.Button,{type:"text",icon:(0,l.jsx)(ige,{})})})})]})},BFe=lVe,VFe=e=>{const{mode:t,loading:n,initialState:r,headerHeight:a,token:i}=(()=>{const{initialState:e}=v(),t="mix"!==e.settings.layout?0:e?.settings?.token?.header?.heightLayoutHeader??56,{token:n}=h.theme.useToken(),[r,a]=(0,u.useState)(Wt.getThemeMode()),[i,o]=(0,u.useState)(!0);return(0,u.useEffect)((()=>{const e=e=>{e="light"===e?"light":"realDark",Wt.setThemeMode(e),a(void 0),setTimeout((()=>{a(e)}),1)};return setTimeout((()=>{o(!1)}),800),Bt.eventEmitter.on(Nt.THEME_MODE,e),()=>{Bt.eventEmitter.off(Nt.THEME_MODE,e)}}),[]),{mode:r,loading:i,initialState:e,headerHeight:t,token:n}})();return t&&(0,l.jsx)(h.Watermark,{content:e.watermark,children:(0,l.jsx)(BFe,{onResize:t=>{e.onResponsive?.call(void 0,t.width<(e.responsiveWidth??i.screenSM)),e.onResize?.call(void 0,t)},children:(0,l.jsx)("div",{ref:e.scrollbarsRef,style:{height:0===a?"100vh":`calc(100vh - ${a}px)`,overflow:"auto"},children:(0,l.jsxs)(d.PageContainer,{...e,children:[(0,l.jsx)(d.ProCard,{ghost:!(!1!==e.animate&&e.loadDuringAnimate&&n||e.loading),className:!1===e.animate?"":`animate__animated animate__${e.animate??"fadeInRight"} animate__fast`,loading:!1!==e.animate&&e.loadDuringAnimate&&n||e.loading,children:e.children}),r?.currentTheme?.copyright&&(0,l.jsx)(d.DefaultFooter,{copyright:r?.currentTheme?.copyright,links:r?.currentTheme?.links.map(((e,t)=>({key:`${t}`,title:e.key,href:e.value,blankTarget:!0}))),style:{background:"none"}})]})})})})},NFe=e=>{const{isChild:t}=(e=>{const[t,n]=(0,u.useState)(!0);return(0,u.useLayoutEffect)((()=>{n(!e.location.endsWith(e.path))}),[e.location]),{isChild:t}})(e);return t?e.children:e.home};var IFe=n(8365),FFe=n(1552),DFe=n(5072),$Fe=n.n(DFe),WFe=n(7825),qFe=n.n(WFe),UFe=n(7659),GFe=n.n(UFe),KFe=n(5056),YFe=n.n(KFe),XFe=n(540),ZFe=n.n(XFe),QFe=n(1113),JFe=n.n(QFe),eDe=n(2795),tDe={};tDe.styleTagTransform=JFe(),tDe.setAttributes=YFe(),tDe.insert=GFe().bind(null,"head"),tDe.domAPI=qFe(),tDe.insertStyleElement=ZFe(),$Fe()(eDe.A,tDe),eDe.A&&eDe.A.locals&&eDe.A.locals;const nDe=new FFe.Converter({tables:!0,simplifiedAutoLink:!0,strikethrough:!0,tasklists:!0}),rDe=e=>{const{intl:t,selectedTab:n,setSelectedTab:r}=(()=>{const{intl:e}=v(),[t,n]=(0,u.useState)("write");return{intl:e,selectedTab:t,setSelectedTab:n}})();return(0,l.jsx)(IFe.default,{childProps:{writeButton:{style:{color:"black",paddingRight:4,paddingLeft:4}},previewButton:{style:{color:"black",paddingRight:4,paddingLeft:4}},textArea:{style:{color:"black",minHeight:"400px"}}},value:e.value,onChange:e.onChange,selectedTab:n,onTabChange:r,l18n:{write:t.formatMessage({id:"components.markdown-editor.write",defaultMessage:"编辑"}),preview:t.formatMessage({id:"components.markdown-editor.preview",defaultMessage:"预览"}),uploadingImage:t.formatMessage({id:"components.markdown-editor.uploading-image",defaultMessage:"上传图片"}),pasteDropSelect:t.formatMessage({id:"components.markdown-editor.paste-drop-select",defaultMessage:"粘贴下拉选择"})},generateMarkdownPreview:e=>Promise.resolve(nDe.makeHtml(e))})},aDe=f().forwardRef(((e,t)=>(0,l.jsx)(d.ProFormUploadButton,{...e,ref:t}))),iDe=e=>{const{intl:t,globalFunctions:n,value:r,onFileChange:a}=(e=>{const{intl:t,globalFunctions:n}=v(),[r,a]=(0,u.useState)([]),i=(0,u.useCallback)((({file:t,fileList:r})=>{t&&("done"===t.status?t.response&&1===t.response.code?(e.afterSuccess?.call(void 0),console.log(1,t),e.onChange?.call(void 0,[{uid:t.response.data.guid,name:t.name,status:"done",url:n.getPreviewUrl.call(void 0,t.response.data.guid)}])):e.afterFail?.call(void 0,t.response.message):"removed"===t.status||0===r.length?e.onChange?.call(void 0,void 0):e.onChange?.call(void 0,r))}),[e.afterSuccess,e.onChange,e.afterFail,n]);return(0,u.useEffect)((()=>{e.purity?$t.isNotNullAndUndefined(e.value)&&e.value.length>0?a([{uid:e.value,status:"done",url:n.getPreviewUrl.call(void 0,e.value)}]):a([]):a(e.value)}),[e.value]),{intl:t,globalFunctions:n,value:r,onFileChange:i}})(e);return(0,l.jsx)(aDe,{title:t.formatMessage({id:"components.single-image-uploader.upload-button",defaultMessage:"单击上传"}),name:e.name,label:e.label,rules:e.rules,max:1,fieldProps:{name:"file",fileList:r,listType:"picture-card",headers:{Authorization:e.headers?.accessToken,Language:e.headers?.locale,"Client-Id":e.headers?.clientId},onChange:a},action:n.getUploadUrl.call(void 0,e.fileCode)})},oDe=e=>(0,l.jsx)($Pe.ProForm.Item,{name:e.name,style:{marginBottom:0},getValueFromEvent:t=>e.purity?t&&t.length>0?t[0].uid:void 0:t,children:(0,l.jsx)(iDe,{...e})}),cDe=e=>e.childrenRender?e.childrenRender(e.children,e.messageHolder,e.notificationHolder,e.globalState):e.children,sDe=e=>{const[t,n]=h.message.useMessage(),[r,a]=h.notification.useNotification();return(0,u.useEffect)((()=>{const e=({level:e,content:n})=>t[e](n),n=({level:e,config:t})=>r[e](t);return Bt.eventEmitter.on(Nt.MESSAGE,e),Bt.eventEmitter.on(Nt.NOTIFICATION,n),()=>{Bt.eventEmitter.off(Nt.MESSAGE,e),Bt.eventEmitter.off(Nt.NOTIFICATION,n)}}),[e]),{messageHolder:n,notificationHolder:a}},lDe=(e,t)=>e.map((({path:e,guid:n,icon:r,children:a,hideStatus:i,i18n:o,...c})=>{const s=o.filter((e=>e.locale===t));let u;return u=s.length>0?s[0].name:o[0].name,{...c,name:u,hideInMenu:0===i,icon:r&&(0,l.jsx)(FPe,{name:r}),children:a&&lDe(a,t),key:n,path:e}})),uDe=(e,t,n)=>{e&&t&&e.forEach((e=>{t.includes(e.key)&&!e.hideInMenu&&n.push(e),e.children&&uDe(e.children,t,n)}))},fDe=(e,t)=>{const n=Wt.getQuickMethod(t),r=[];return uDe(e,n,r),r.map(((e,t)=>({key:t,icon:e.icon,title:e.name,url:e.path})))},dDe=async e=>{const t=async()=>{let t;try{t=await e.getUserInitDetail.call(void 0)}catch(t){return void vDe.executeLogout(e.history,e.loginLoadPath)}if(1===t.code&&t.data){const n=t.data;return n.menuList&&(n.menuList=lDe(n.menuList,e.getLocale.call(void 0))),n.avatar&&(n.avatar=e.getPreviewUrl.call(void 0,n.avatar)),n}vDe.executeLogout(e.history,e.loginLoadPath)},n=async()=>{const t=await e.getCurrentThemeDetail.call(void 0);if(1===t.code&&t.data){if(t.data.favicons){const n=document.querySelector("link[rel*='icon']")||document.createElement("link");n.type="image/x-icon",n.rel="shortcut icon",n.href=e.getPreviewUrl.call(void 0,t.data.favicons),document.getElementsByTagName("head")[0].appendChild(n)}return t.data}},{location:r}=e.history,a=Wt.getThemeMode(),i=e.defaultSettings;return i.navTheme=a,r.pathname.endsWith(e.loginLoadPath)?{settings:i,currentTheme:await n(),fetchUserInfo:t,fetchThemeInfo:n}:{settings:i,currentUser:await t(),currentTheme:await n(),fetchUserInfo:t,fetchThemeInfo:n}},hDe=e=>{const{messageHolder:t,notificationHolder:n}=sDe(),{layout:r,splitMenus:a,title:i,logo:o,...c}=e.globalState.initialState?.settings??{},s=window.__POWERED_BY_QIANKUN__?"side":r;return(0,u.useEffect)((()=>{const t=Wt.getThemeMode();e.globalState.initialState?.settings.navTheme&&e.globalState.initialState?.settings.navTheme!==t&&e.setInitialState.call(void 0,(n=>{const r=(0,D.cloneDeep)(e.globalState.initialState.settings);return r.navTheme=t,{...n,settings:r}}));const n=t=>{e.setInitialState.call(void 0,(n=>{const r=(0,D.cloneDeep)(e.globalState.initialState.settings);return r.navTheme=t,{...n,settings:r}}))};return Bt.eventEmitter.on(Nt.THEME_MODE,n),()=>{Bt.eventEmitter.off(Nt.THEME_MODE,n)}}),[e.globalState.initialState?.settings.navTheme]),{menu:{locale:!1,request:()=>e.globalState.initialState.currentUser.menuList},actionsRender:()=>window.__POWERED_BY_QIANKUN__?[]:[...e.headerOperations??[],(0,l.jsx)(qt,{},"theme"),f().cloneElement(e.selectLang,{key:"localeChange"})],avatarProps:{src:e.globalState.initialState?.currentUser?.avatar,title:f().cloneElement(e.avatarName,{key:"avatarName"}),render:(t,n)=>f().cloneElement(e.avatarDropdown,{key:"avatarDropdown"},n)},footerRender:void 0,onPageChange:t=>{e.globalState.initialState?.currentUser||t.pathname.endsWith(e.loginLoadPath)||e.history.push(e.loginLoadPath)},bgLayoutImgList:[{src:e.globalState.globalFunctions.getPreviewUrl(e.globalState.initialState?.currentTheme?.backgroundImg),bottom:0,left:0,height:"100%"}],appList:fDe(e.globalState.initialState?.currentUser?.menuList,e.clientId),links:[],menuHeaderRender:void 0,childrenRender:r=>(0,l.jsx)(cDe,{...e,currentLayout:s,messageHolder:t,notificationHolder:n,children:r}),layout:s,splitMenus:!window.__POWERED_BY_QIANKUN__&&a,title:e.globalState.initialState?.currentTheme?.title??i,logo:e.globalState.globalFunctions.getPreviewUrl(e.globalState.initialState?.currentTheme?.icon)??o,...c}};var pDe=n(7186);const vDe={convertPageParam:async(e,t,n,r)=>{const a={...t};void 0!==a.current&&(a.pageNum=a.current,a.current=void 0),n&&(a.sort=n),a.filter=r;for(const e in a)Array.isArray(a[e])&&(a[e]=String(a[e]));const i=await e(a);return 1===i.code?{data:i.data,success:!0,total:i.total}:{data:i.message,success:!1,total:i.total}},downloadFile:(e,t)=>{if(!e)return;const n=document.createElement("a");n.href=e,n.download=t,document.body.appendChild(n),n.click(),document.body.removeChild(n)},executeLogout:(e,t)=>{const{search:n,pathname:r}=window.location,a=new URL(window.location.href).searchParams.get("redirect");window.location.pathname.endsWith(t)||a||e.replace({pathname:t,search:(0,pDe.stringify)({redirect:r+n})})},getOAuth2Url:(e,t,n,r,a)=>{const i=new URL(`${n}/authorization/oauth2/authorize?`);for(const e in r)"client_secret"!==e&&i.searchParams.set(e,r[e]);let o;const c=new URL(window.location.href);return c.searchParams.delete("code"),c.searchParams.delete("state"),a&&c.searchParams.set("redirect",a),o=c.toString(),i.searchParams.set("redirect_uri",o),i.searchParams.set("state",JSON.stringify({locale:e,theme:t})),i.toString()},getExternalAuthUrl:(e,t,n,r,a,i)=>{const o=new URL(e),c=new URL(window.location.href);return c.search="",c.pathname=a,o.searchParams.set("redirect_uri",c.toString()),o.searchParams.set("state",JSON.stringify({locale:t,theme:n,external_guid:r,user_guid:i})),o.toString().replace(/%3A/g,":")},getExternalAuthUrl4Auth:function(e,t,n,r,a){const i=new URL(t),o=new URL(e);return i.searchParams.set("redirect_uri",o.toString()),i.searchParams.set("state",JSON.stringify({locale:n,theme:r,external_guid:a})),i.toString().replace(/%3A/g,":")}},mDe=e=>{const{intl:t,initialState:n}=v(),[r,a]=(0,u.useState)(void 0),i=async()=>{const t=await(n?.fetchUserInfo?.call(void 0));t&&(0,TBe.flushSync)((()=>{e.setInitialState.call(void 0,(e=>({...e,currentUser:t})))}));const r=await(n?.fetchThemeInfo?.call(void 0));r&&(0,TBe.flushSync)((()=>{e.setInitialState.call(void 0,(e=>({...e,currentTheme:r})))}))},o=async(t,n)=>{if(1===t.code){if(L.getDb().delete(),Wt.setToken(t.data),await i(),window.__POWERED_BY_QIANKUN__){const{pathname:t}=window.location,r=t.replace(e.loginLoadPath,"");r&&n.redirect.startsWith(r)&&(n.redirect=n.redirect.replace(new RegExp(`^${r}`),""))}e.onFinish.call(void 0,n.redirect,void 0)}else a(t.message)},c=(e,t)=>{const n=document.createElement("script");n.src=e,n.async=!0,n.onload=t,document.body.appendChild(n)};return(0,u.useEffect)((()=>{(async()=>{const t=(()=>{const t=e.searchParams.get("code"),n=e.searchParams.get("state"),r=e.searchParams.get("redirect")??"/";let a=null,i=null,o=null,c=null;if(n){let e;try{e=JSON.parse(n)}catch{e=null}e&&(a=e.locale,i=e.theme,o=e.external_guid,c=e.user_guid)}return{code:t,state:n,redirect:r,locale:a,theme:i,externalGuid:o,userGuid:c}})();t.locale&&e.setLocale.call(void 0,t.locale,!1),t.theme&&Wt.setThemeMode("realDark"===t.theme?"realDark":"light"),t.code?t.externalGuid&&t.userGuid?(async t=>{const n=new URL(window.location.href);n.search="";const r=await e.bindExternalData.call(void 0,{guid:t.externalGuid,code:t.code,redirectUrl:n.toString()}),a=Wt.getBeforeExternalBindPathname();if(1===r.code){await i();const t=r.data.i18n.filter((t=>e.locale===t.locale));e.onFinish.call(void 0,void 0!==a?a:"/user-center",{external:t[0].title,externalBindResult:!0})}else e.onFinish.call(void 0,void 0!==a?a:"/user-center",{external:r.message,externalBindResult:!1})})(t):(async t=>{let n;if(t.externalGuid){const r=new URL(window.location.href),a=new URLSearchParams;r.searchParams.has("redirect")&&a.set("redirect",r.searchParams.get("redirect")),r.search=a.toString(),n=await e.getTokenByCode.call(void 0,{code:t.code,external_guid:t.externalGuid,external_redirect_uri:encodeURIComponent(r.toString())})}else n=await e.getTokenByCode.call(void 0,{code:t.code});await o(n,t)})(t):(t=>{if(Wt.getActiveLogout())return Wt.removeToken(),void(window.location.href=vDe.getOAuth2Url(e.locale,Wt.getThemeMode(),e.gatewayUrl,e.clientConfig,t.redirect));if(!e.externalIntegrationConfig||e.externalIntegrationConfig.length<1)return Wt.removeToken(),void(window.location.href=vDe.getOAuth2Url(e.locale,Wt.getThemeMode(),e.gatewayUrl,e.clientConfig,t.redirect));for(const n of e.externalIntegrationConfig)"feishu"===n.platform&&c("https://lf1-cdn-tos.bytegoofy.com/goofy/lark/op/h5-js-sdk-1.5.26.js",(()=>{window.h5sdk&&window.tt.requestAccess?window.tt.requestAccess({appID:n.appId,scopeList:[],success:async({code:r})=>{const a=new URL(window.location.href);a.search="";const i=await e.getTokenByCode.call(void 0,{code:r,external_client_id:n.appId,external_redirect_uri:a.toString(),platform:n.platform});await o(i,t)},fail:({errString:e})=>{a(e)}}):window.location.href=vDe.getOAuth2Url(e.locale,Wt.getThemeMode(),e.gatewayUrl,e.clientConfig,t.redirect)}))})(t)})()}),[]),{setExceptionMsg:a,exceptionMsg:r,intl:t}},gDe=h.Result,yDe=e=>{const{setExceptionMsg:t,exceptionMsg:n,intl:r}=mDe(e);return(0,l.jsx)(l.Fragment,{children:void 0===n?(0,l.jsx)(h.Spin,{percent:"auto",size:"large"}):(0,l.jsx)(gDe,{status:"500",title:n,extra:(0,l.jsx)(h.Button,{type:"primary",onClick:()=>{t(void 0),window.location.href=vDe.getOAuth2Url(e.locale,Wt.getThemeMode(),e.gatewayUrl,e.clientConfig)},children:r.formatMessage({id:"components.auth-frame.operation.back-auth",defaultMessage:"返回授权页面"})})})})},bDe=e=>{const{setCurrent:t,setLoading:n,steps:r,mailStep:a,externalStep:i,current:o,loading:c,externalBind:s}=(e=>{const{intl:t}=v(),[n,r]=(0,u.useState)(!1),[a,i]=(0,u.useState)({}),[o,c]=(0,u.useState)([]),[s,f]=(0,u.useState)(0),[d,h]=(0,u.useState)(),[p,m]=(0,u.useState)(),[g,y]=(0,u.useState)();return(0,u.useEffect)((()=>{(async()=>{const n=await e.getUserForceBind.call(void 0),r=[];1===n.code?(n.data&&(n.data.mailForce&&(r.push({title:t.formatMessage({id:"components.bind-frame.title.mail-force",defaultMessage:"绑定邮箱"}),icon:(0,l.jsx)(yG,{})}),h(r.length-1)),n.data.passwordForce&&(r.push({title:t.formatMessage({id:"components.bind-frame.title.password-force",defaultMessage:"重置密码"}),icon:(0,l.jsx)(Jhe,{})}),m(r.length-1)),n.data.externalForceList&&n.data.externalForceList.length>0&&(r.push({title:t.formatMessage({id:"components.bind-frame.title.external-force",defaultMessage:"绑定外部授权"}),icon:(0,l.jsx)(s0,{})}),y(r.length-1),i(n.data.externalForceList))),c(r)):i([]),r.length<1&&e.onFinish.call(void 0)})()}),[]),{setCurrent:f,setLoading:r,steps:o,mailStep:d,externalStep:g,current:s,loading:n,externalBind:a}})(e);return(0,l.jsx)(l.Fragment,{children:r&&r.length>0?(0,l.jsxs)(AQ,{style:{maxWidth:"36rem"},hoverable:!e.responsive,bordered:!e.responsive,children:[(0,l.jsx)(h.Steps,{size:"small",items:r,current:o}),(0,l.jsx)(h.Divider,{dashed:!0}),void 0!==a&&a===o&&(0,l.jsx)(l.Fragment,{children:f().cloneElement(e.mailBindFrame,{key:"mail-bind-frame",onFinish:n=>{o+1>=r.length?e.onFinish.call(void 0):t(o+1)}})}),void 0!==i&&i===o&&(0,l.jsx)(h.Spin,{spinning:c,children:f().cloneElement(e.externalAuthFrame,{key:"external-auth-frame",externalFilterList:s,onLoadChange:e=>{n(e)}})})]}):(0,l.jsx)(h.Spin,{percent:"auto",size:"large"})})},wDe={setScale:(e,t=2)=>{const n=Math.pow(10,t);return Math.round(e*n)/n}},xDe={randomStr:e=>{let t="";for(let n=0;n<e;n++)t+="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789"[Math.floor(62*Math.random())];return t}},MDe={fromUnicode:e=>e.replace(/\\u([\dA-Fa-f]{4})/g,((e,t)=>String.fromCharCode(parseInt(t,16)))),toUnicode:e=>encodeURIComponent(e).replace(/%/g,"\\u").replace(/\\u([0-9a-fA-F]{2})/g,((e,t)=>"\\u00"+t))},kDe={generateUploadFile:(e,t,n,r)=>{if(e[t]&&e[n])return[{uid:e[n],name:e[t],status:"done",url:r.call(void 0,e[n])}]}},ODe=()=>{const{getLocale:e,globalFunctions:t}=v(),n=async n=>{const r=L.getDb();r.version(1).stores({sys_dict:"++id, type, name, enName, value, color, sort"});let a=await r.sys_dict.where("type").equals(n).sortBy("sort");if(0===a.length){const e=await(t?.getDictDataByType.call(void 0,n));1===e.code&&(a=e.data,a.length>0&&r.sys_dict.bulkPut(a.map((e=>({...e,type:n})))))}return a.map((t=>{const r=t.i18n.filter((t=>t.locale===e()));let a;return a=r.length>0?r[0].name:t.i18n[0].name,{type:n,label:a,value:t.value,color:t.color,sort:t.sort}}))};return{getDataByType:n,getTagDataByType:async e=>(await n(e)).map((e=>({label:(0,l.jsx)(h.Tag,{style:{maxWidth:"100%"},bordered:!0,color:e.color,children:(0,l.jsx)(h.Typography.Text,{ellipsis:{tooltip:e.label},children:e.label})}),value:isNaN(Number(e.value))?e.value:Number(e.value),title:e.label})))}},zDe=()=>({info:e=>Bt.pushMessageEvent("info",e),success:e=>Bt.pushMessageEvent("success",e),error:e=>Bt.pushMessageEvent("error",e),warning:e=>Bt.pushMessageEvent("warning",e),loading:e=>Bt.pushMessageEvent("loading",e)}),_De=()=>({info:e=>Bt.pushNotificationEvent("info",e),success:e=>Bt.pushNotificationEvent("success",e),error:e=>Bt.pushNotificationEvent("error",e),warning:e=>Bt.pushNotificationEvent("warning",e),loading:e=>Bt.pushNotificationEvent("loading",e)}),SDe={outlinedConstants:["StepBackwardOutlined","StepForwardOutlined","FastBackwardOutlined","FastForwardOutlined","ShrinkOutlined","ArrowsAltOutlined","DownOutlined","UpOutlined","LeftOutlined","RightOutlined","CaretUpOutlined","CaretDownOutlined","CaretLeftOutlined","CaretRightOutlined","UpCircleOutlined","DownCircleOutlined","LeftCircleOutlined","RightCircleOutlined","DoubleRightOutlined","DoubleLeftOutlined","VerticalLeftOutlined","VerticalRightOutlined","VerticalAlignTopOutlined","VerticalAlignMiddleOutlined","VerticalAlignBottomOutlined","ForwardOutlined","BackwardOutlined","RollbackOutlined","EnterOutlined","RetweetOutlined","SwapOutlined","SwapLeftOutlined","SwapRightOutlined","ArrowUpOutlined","ArrowDownOutlined","ArrowLeftOutlined","ArrowRightOutlined","PlayCircleOutlined","UpSquareOutlined","DownSquareOutlined","LeftSquareOutlined","RightSquareOutlined","LoginOutlined","LogoutOutlined","MenuFoldOutlined","MenuUnfoldOutlined","BorderBottomOutlined","BorderHorizontalOutlined","BorderInnerOutlined","BorderOuterOutlined","BorderLeftOutlined","BorderRightOutlined","BorderTopOutlined","BorderVerticleOutlined","PicCenterOutlined","PicLeftOutlined","PicRightOutlined","RadiusBottomleftOutlined","RadiusBottomrightOutlined","RadiusUpleftOutlined","RadiusUprightOutlined","FullscreenOutlined","FullscreenExitOutlined","QuestionOutlined","QuestionCircleOutlined","PlusOutlined","PlusCircleOutlined","PauseOutlined","PauseCircleOutlined","MinusOutlined","MinusCircleOutlined","PlusSquareOutlined","MinusSquareOutlined","InfoOutlined","InfoCircleOutlined","ExclamationOutlined","ExclamationCircleOutlined","CloseOutlined","CloseCircleOutlined","CloseSquareOutlined","CheckOutlined","CheckCircleOutlined","CheckSquareOutlined","ClockCircleOutlined","WarningOutlined","IssuesCloseOutlined","StopOutlined","EditOutlined","FormOutlined","CopyOutlined","ScissorOutlined","DeleteOutlined","SnippetsOutlined","DiffOutlined","HighlightOutlined","AlignCenterOutlined","AlignLeftOutlined","AlignRightOutlined","BgColorsOutlined","BoldOutlined","ItalicOutlined","UnderlineOutlined","StrikethroughOutlined","RedoOutlined","UndoOutlined","ZoomInOutlined","ZoomOutOutlined","FontColorsOutlined","FontSizeOutlined","LineHeightOutlined","DashOutlined","SmallDashOutlined","SortAscendingOutlined","SortDescendingOutlined","DragOutlined","OrderedListOutlined","UnorderedListOutlined","RadiusSettingOutlined","ColumnWidthOutlined","ColumnHeightOutlined","AreaChartOutlined","PieChartOutlined","BarChartOutlined","DotChartOutlined","LineChartOutlined","RadarChartOutlined","HeatMapOutlined","FallOutlined","RiseOutlined","StockOutlined","BoxPlotOutlined","FundOutlined","SlidersOutlined","AndroidOutlined","AppleOutlined","WindowsOutlined","IeOutlined","ChromeOutlined","GithubOutlined","AliwangwangOutlined","DingdingOutlined","WeiboSquareOutlined","WeiboCircleOutlined","TaobaoCircleOutlined","Html5Outlined","WeiboOutlined","TwitterOutlined","WechatOutlined","WhatsAppOutlined","YoutubeOutlined","AlipayCircleOutlined","TaobaoOutlined","DingtalkOutlined","SkypeOutlined","QqOutlined","MediumWorkmarkOutlined","GitlabOutlined","MediumOutlined","LinkedinOutlined","GooglePlusOutlined","DropboxOutlined","FacebookOutlined","CodepenOutlined","CodeSandboxOutlined","AmazonOutlined","GoogleOutlined","CodepenCircleOutlined","AlipayOutlined","AntDesignOutlined","AntCloudOutlined","AliyunOutlined","ZhihuOutlined","SlackOutlined","SlackSquareOutlined","BehanceOutlined","BehanceSquareOutlined","DribbbleOutlined","DribbbleSquareOutlined","InstagramOutlined","YuqueOutlined","AlibabaOutlined","YahooOutlined","RedditOutlined","SketchOutlined","AccountBookOutlined","AimOutlined","AlertOutlined","ApartmentOutlined","ApiOutlined","AppstoreAddOutlined","AppstoreOutlined","AudioOutlined","AudioMutedOutlined","AuditOutlined","BankOutlined","BarcodeOutlined","BarsOutlined","BellOutlined","BlockOutlined","BookOutlined","BorderOutlined","BorderlessTableOutlined","BranchesOutlined","BugOutlined","BuildOutlined","BulbOutlined","CalculatorOutlined","CalendarOutlined","CameraOutlined","CarOutlined","CarryOutOutlined","CiCircleOutlined","CiOutlined","ClearOutlined","CloudDownloadOutlined","CloudOutlined","CloudServerOutlined","CloudSyncOutlined","CloudUploadOutlined","ClusterOutlined","CodeOutlined","CoffeeOutlined","CommentOutlined","CompassOutlined","CompressOutlined","ConsoleSqlOutlined","ContactsOutlined","ContainerOutlined","ControlOutlined","CopyrightOutlined","CreditCardOutlined","CrownOutlined","CustomerServiceOutlined","DashboardOutlined","DatabaseOutlined","DeleteColumnOutlined","DeleteRowOutlined","DeliveredProcedureOutlined","DeploymentUnitOutlined","DesktopOutlined","DisconnectOutlined","DislikeOutlined","DollarOutlined","DownloadOutlined","EllipsisOutlined","EnvironmentOutlined","EuroCircleOutlined","EuroOutlined","ExceptionOutlined","ExpandAltOutlined","ExpandOutlined","ExperimentOutlined","ExportOutlined","EyeOutlined","EyeInvisibleOutlined","FieldBinaryOutlined","FieldNumberOutlined","FieldStringOutlined","FieldTimeOutlined","FileAddOutlined","FileDoneOutlined","FileExcelOutlined","FileExclamationOutlined","FileOutlined","FileGifOutlined","FileImageOutlined","FileJpgOutlined","FileMarkdownOutlined","FilePdfOutlined","FilePptOutlined","FileProtectOutlined","FileSearchOutlined","FileSyncOutlined","FileTextOutlined","FileUnknownOutlined","FileWordOutlined","FileZipOutlined","FilterOutlined","FireOutlined","FlagOutlined","FolderAddOutlined","FolderOutlined","FolderOpenOutlined","FolderViewOutlined","ForkOutlined","FormatPainterOutlined","FrownOutlined","FunctionOutlined","FundProjectionScreenOutlined","FundViewOutlined","FunnelPlotOutlined","GatewayOutlined","GifOutlined","GiftOutlined","GlobalOutlined","GoldOutlined","GroupOutlined","HddOutlined","HeartOutlined","HistoryOutlined","HolderOutlined","HomeOutlined","HourglassOutlined","IdcardOutlined","ImportOutlined","InboxOutlined","InsertRowAboveOutlined","InsertRowBelowOutlined","InsertRowLeftOutlined","InsertRowRightOutlined","InsuranceOutlined","InteractionOutlined","KeyOutlined","LaptopOutlined","LayoutOutlined","LikeOutlined","LineOutlined","LinkOutlined","Loading3QuartersOutlined","LoadingOutlined","LockOutlined","MacCommandOutlined","MailOutlined","ManOutlined","MedicineBoxOutlined","MehOutlined","MenuOutlined","MergeCellsOutlined","MessageOutlined","MobileOutlined","MoneyCollectOutlined","MonitorOutlined","MoreOutlined","NodeCollapseOutlined","NodeExpandOutlined","NodeIndexOutlined","NotificationOutlined","NumberOutlined","OneToOneOutlined","PaperClipOutlined","PartitionOutlined","PayCircleOutlined","PercentageOutlined","PhoneOutlined","PictureOutlined","PlaySquareOutlined","PoundCircleOutlined","PoundOutlined","PoweroffOutlined","PrinterOutlined","ProfileOutlined","ProjectOutlined","PropertySafetyOutlined","PullRequestOutlined","PushpinOutlined","QrcodeOutlined","ReadOutlined","ReconciliationOutlined","RedEnvelopeOutlined","ReloadOutlined","RestOutlined","RobotOutlined","RocketOutlined","RotateLeftOutlined","RotateRightOutlined","SafetyCertificateOutlined","SafetyOutlined","SaveOutlined","ScanOutlined","ScheduleOutlined","SearchOutlined","SecurityScanOutlined","SelectOutlined","SendOutlined","SettingOutlined","ShakeOutlined","ShareAltOutlined","ShopOutlined","ShoppingCartOutlined","ShoppingOutlined","SisternodeOutlined","SkinOutlined","SmileOutlined","SolutionOutlined","SoundOutlined","SplitCellsOutlined","StarOutlined","SubnodeOutlined","SwitcherOutlined","SyncOutlined","TableOutlined","TabletOutlined","TagOutlined","TagsOutlined","TeamOutlined","ThunderboltOutlined","ToTopOutlined","ToolOutlined","TrademarkCircleOutlined","TrademarkOutlined","TransactionOutlined","TranslationOutlined","TrophyOutlined","UngroupOutlined","UnlockOutlined","UploadOutlined","UsbOutlined","UserAddOutlined","UserDeleteOutlined","UserOutlined","UserSwitchOutlined","UsergroupAddOutlined","UsergroupDeleteOutlined","VerifiedOutlined","VideoCameraAddOutlined","VideoCameraOutlined","WalletOutlined","WifiOutlined","WomanOutlined"]},EDe={"components.data-table.pagination.total":"总","components.file-tag.operation.preview-pdf":"预览PDF","components.file-tag.operation.download":"下载","components.user-card.unknown":"未知用户","components.user-card.is-me":"(我)","components.user-card.phone":"手机号码","components.user-card.email":"邮箱地址","components.user-card.sex":"性别","components.user-card.status":"状态","components.user-card.role":"角色","components.user-selector.placeholder":"请输入关键字","components.user-selector.search":"搜索","components.attachment-text.appendix":"点击上传附件","components.markdown-editor.write":"编辑","components.markdown-editor.preview":"预览","components.markdown-editor.uploading-image":"上传图片","components.markdown-editor.paste-drop-select":"粘贴下拉选择","components.single-image-uploader.upload-button":"单击上传","components.auth-frame.operation.back-auth":"返回授权页面","components.bind-frame.title.mail-force":"绑定邮箱","components.bind-frame.title.password-force":"重置密码","components.bind-frame.title.external-force":"绑定外部授权","components.constants.status-list.enable":"启用","components.constants.status-list.disable":"停用","components.constants.sex-list.secret":"保密","components.constants.sex-list.male":"男","components.constants.sex-list.female":"女"},CDe={"components.data-table.pagination.total":"Total","components.file-tag.operation.preview-pdf":"Preview PDF","components.file-tag.operation.download":"Download","components.user-card.unknown":"Unknown user","components.user-card.is-me":"(Me)","components.user-card.phone":"Phone number","components.user-card.email":"Email address","components.user-card.sex":"Gender","components.user-card.status":"Status","components.user-card.role":"Role","components.user-selector.placeholder":"Please enter keywords","components.user-selector.search":"Search","components.attachment-text.appendix":"Click to upload attachment","components.markdown-editor.write":"Edit","components.markdown-editor.preview":"Preview","components.markdown-editor.uploading-image":"Upload image","components.markdown-editor.paste-drop-select":"Paste drop-down selection","components.single-image-uploader.upload-button":"Click Upload","components.auth-frame.operation.back-auth":"Return to Authorization Page","components.bind-frame.title.mail-force":"Bind Email","components.bind-frame.title.password-force":"Reset Password","components.bind-frame.title.external-force":"Bind External Authorization","components.constants.status-list.enable":"Enable","components.constants.status-list.disable":"disable","components.constants.sex-list.secret":"Secret","components.constants.sex-list.male":"Male","components.constants.sex-list.female":"female"},TDe={RbDataTable:W,RbActionBarItem:U,RbActionBar:G,RbThemeSetter:qt,RbDataChart:_U,RbFileTag:lG,RbUserCard:jQ,RbIconRender:FPe,RbHtmlRender:DPe,RbDragTable:TFe,RbUserSelector:jFe,RbAttachmentText:HFe,RbPageContainer:VFe,RbRouteWrapper:NFe,RbMarkdownConverter:nDe,RbMarkdownEditor:rDe,RbSingleImageUploader:oDe,RbAuthFrame:yDe,RbBindFrame:bDe,RbGlobalContext:p}})(),module.exports=r})();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@regenbio/regenbio-components-react",
3
- "version": "1.4.19",
3
+ "version": "1.4.20",
4
4
  "publishConfig": {
5
5
  "access": "public"
6
6
  },