
管理员
站长
- UID
- 1
- 积分
- 224400
- 余额
- 13 R
- Moe币
- 84881
- 在线时间
- 279 小时
- 注册时间
- 2025-12-28
- 最后登录
- 2026-11-9
|
|
xt:_i18n("", "导出", "d3wgy9"),onClick:function(e){return _._handleClickExportBtn(c,a,e)}},t[r.QUIT]={text:_i18n("", "放弃", "7vtvqj"),onClick:function(){return _._handleClickQuitBtn(c,n)}},t[r.CONTINUE]={text:_i18n("", "继续", "aixrhq"),onClick:function(){return _._handleClickContinueBtn(c,i)}},t[r.CONFIRM]={text:_i18n("", "我知道了", "8v9k15"),onClick:function(){return _._handleClickQuitBtn(c,n)}},t);return{left:d.map((function(e){return p[e]})),right:s.map((function(e){return p[e]}))}},e.prototype.show=function(e){return Object(n.__awaiter)(this,void 0,void 0,(function(){var t,_,i,a,d,s,p,h,w,b,f;return Object(n.__generator)(this,(function(g){return t=e.type,_=e.onQuit,i=e.onContinue,a=e.onCopy,d=e.onExport,s=e.recoverFailHandleMethod,p=function(e,t){var _;return void 0===t&&(t="none"),((_={})[o.DATA_CONFLICT]={title:_i18n("", "同步存在风险", "6q1pff"),content:{none:_i18n("", "同步冲突。「继续」可能会覆盖他人编辑内容,同步后可通过历史版本查看其他版本的编辑内容。「放弃」将清空离线编辑内容。", "8356ar"),copy:_i18n("", "同步冲突。「继续」可能会覆盖他人编辑内容,同步后可通过历史版本查看其他版本的编辑内容。「放弃」将清空离线编辑内容。为避免数据丢失,可通过「复制」全文粘贴至本地文档备份。", "cqlmaj"),export:_i18n("", "同步冲突。「继续」可能会覆盖他人编辑内容,同步后可通过历史版本查看其他版本的编辑内容。「放弃」将清空离线编辑内容。为避免数据丢失,可通过「导出」将全文创建至新文档备份。", "arzwlx")}[t||"none"],actions:{left:"copy"===t&&[r.COPY]||"export"===t&&[r.EXPORT]||[],right:[r.QUIT,r.CONTINUE]}},_[o.RECOVER_ERROR]={title:_i18n("", "同步存在异常", "prn6s"),content:{none:_i18n("", "离线编辑内容无法同步,即将为你打开最新版本文件。", "czpdej"),copy:_i18n("", "离线编辑内容无法同步。「放弃」将取消内容同步。为避免内容丢失,可通过「复制」全文粘贴至本地文档备份。", "b3l30v"),export:_i18n("", "离线编辑内容无法同步。「放弃」将取消内容同步。如需避免内容丢失,可通过「导出」将全文创建至新文档备份。", "3193wo")}[t||"none"],actions:{left:[],right:"copy"===t&&[r.QUIT,r.COPY]||"export"===t&&[r.QUIT,r.EXPORT]||[r.CONFIRM]}},_[o.NO_PERMISSION]={title:_i18n("", "同步存在异常", "9t9soy"),content:_i18n("", "文件权限变更导致离线编辑内容无法同步。", "4y81rq"),actions:{left:[],right:[r.QUIT]}},_[o.TIMEOUT]={title:_i18n("", "同步耗时较久,继续同步?", "84k2eo"),content:{none:_i18n("", "同步成功后可通过历史版本查看其他版本的编辑内容。「放弃」将取消内容同步。", "ad2hdj"),copy:_i18n("", "同步成功后可通过历史版本 查看其他版本的编辑内容。「放弃」将取消内容同步。如需避免内容丢失,可通过「复制」全文粘贴至本地文档备份。", "4y1hw2"),export:_i18n("", "同步成功后可通过历史版本查看其他版本的编辑内容。「放弃」将取消内容同步。如需避免内容丢失,可通过「导出」将全文创建至新文档备份。", "djdly0")}[t||"none"],actions:{left:"copy"===t&&[r.COPY]||"export"===t&&[r.EXPORT]||[],right:[r.QUIT,r.CONTINUE]}},_[o.CLIENT_ERROR]={title:_i18n("", "同步存在异常", "9psn8p"),content:{none:_i18n("", "网络异常,离线编辑内容无法同步,即将为你打开最新版本文件。", "dna5wd"),copy:_i18n("", "网络异常请稍后重试,「放弃」将取消内容同步。如需避免内容丢失,可通过「复制」全文粘贴至本地文档备份。", "bdmcnb"),export:_i18n("", "网络异常请稍后重试,「放弃」将取消内容同步。如需避免内容丢失,可通过「导出」将全文创建至新文档备份。", "c8e8ue")}[t||"none"],actions:{left:[],right:"copy"===t&&[r.QUIT,r.COPY]||"export"===t&&[r.QUIT,r.EXPORT]||[r.CONFIRM]}},_)[e]}(t,s)||{},h=p.title,w=p.content,b=p.actions,this.container||(this.container=document.createElement("div"),document.body.appendChild(this.container)),f={title:h,content:w,visible:!0,actions:this._getFooterActions({actions:b,onQuit:_,onContinue:i,onCopy:a,onExport:d,type:t})},c.a.render(l.a.createElement(m,Object(n.__assign)({},f)),this.container),u(t),[2]}))}))},e.prototype.close=function(){return Object(n.__awaiter)(this,void 0,void 0,(function(){return Object(n.__generator)(this,(function(e){return c.a.unmountComponentAtNode(this.container),this.container.parentNode&&this.container.parentNode.removeChild(this.container),this.container=null,[2]}))}))},e.prototype.showExportSuccessDialog=function(e){var t=_i18n("", "新文档创建成功", "bmbhry"),_=_i18n("", "新文档 {0} 创建成功。「刷新」将重新进入当前文档,「打开」将为你打开新创建的文档。", "c40k6l").replace("{0}",e.newFileName),o=_i18n("", "打开", "dlywb9"),r=_i18n("", "刷新", "afo2z9");window.Confirm({title:t,text:_,okBtnText:o,cancelBtnText:r,maskClosable:!1,closable:!1,onCancel:function(){window.location.reload()},onOk:function(){location.replace(e.newFileUrl)}})},e}()},a8c3:function(e,t,_){"use strict";_.r(t);var o=_("ef68"),r=_("1bd7"),n=_.n(r),i=_("c289"),l=_("731d"),a=Object(l.a)("loading",!1,(function(e){var t=Math.random().toString(36).slice(-6);return n.a.createElement("svg",{width:e.size,height:e.size,viewBox:"0 0 16 16",fill:"none",strokeWidth:e.strokeWidth},n.a.createElement("g",{id:"group-0",stroke:e.colors&&"string"!=typeof e.colors&&e.colors[0]||"string"==typeof e.colors&&e.colors||"#0A6CFF",fill:e.colors&&"string"!=typeof e.colors&&e.colors[0]||"string"==typeof e.colors&&e.colors||"#0A6CFF"},n.a.createElement("path",{d:"M8 14C9.09286 14 10.1175 13.7078 11 13.1973",strokeLinecap:e.strokeLinecap,strokeLinejoin:e.strokeLinejoin,fill:"none",vectorEffect:"non-scaling-stroke"})),n.a.createElement("g",{id:"group-1",stroke:"url(#paint0_linear_852_247_"+t+")",fill:"url(#paint0_linear_852_247_"+t+")"},n.a.createElement("path",{d:"M8 2C11.3137 2 14 4.6863 14 7.99996C14 10.2208 12.7934 12.1598 11 13.1973",strokeLinejoin:e.strokeLinejoin,fill:"none",vectorEffect:"non-scaling-stroke"}),n.a.createElement("defs",null,n.a.createElement("linearGradient",{id:"paint0_linear_852_247_"+t,x1:"8",y1:"12",x2:"8",y2:"3",gradientUnits:"userSpaceOnUse"},n.a.createElement("stop",{stopColor:"#0063F4"}),n.a.createElement("stop",{offset:"1",stopColor:"#0063F4",stopOpacity:"0.5"})))),n.a.createElement("g",{id:"group-2",stroke:"url(#paint1_linear_852_247_"+t+")",fill:"url(#paint1_linear_852_247_"+t+")"},n.a.createElement("path",{d:"M8 2C4.68629 2 2 4.6863 2 8C2 11.3137 4.68629 14 8 14",strokeLinejoin:e.strokeLinejoin,fill:"none",vectorEffect:"non-scaling-stroke"}),n.a.createElement("defs",null,n.a.createElement("linearGradient",{id:"paint1_linear_852_247_"+t,x1:"7.5",y1:"14",x2:"8",y2:"3",gradientUnits:"userSpaceOnUse"},n.a.createElement("stop",{stopColor:"#0063F4",stopOpacity:"0"}),n.a.createElement("stop",{offset:"1",stopColor:"#0063F4",stopOpacity:"0.5"})))))})),c=_("1e80");t.default=function(e){var t=e.title,_=void 0===t?"":t,l=e.content,d=void 0===l?"":l,s=e.visible,p=void 0!==s&&s,m=e.actions,h=void 0===m?{left:[],right:[]}:m,u=n.a.createElement("div",{className:"recover-error-dialog-content"},d,h.left.length>0&&n.a.createElement("div",{className:"buttons"},h.left.map((function(e){var t=e.text,_=e.onClick,o=n.a.useState(!1),r=o[0],l=o[1],c={setLoading:function(e){return l(e)}};return n.a.createElement(i.a,{className:"recover-error-dialog-button",key:t,isSystem:!0,onClick:function(){return _&&_(c)},disabled:r},r&&n.a.createElement(a,{size:16}),t)})))),w=n.a.useState(!1),b=w[0],f=w[1],g={setLoading:function(e){return f(e)}},k=Object(r.useMemo)((function(){var e=h.right.length,t=e>1,_=e>0;if(!_&&!t)return null;var o=t?h.right[0].text:"",r=t?h.right[0].onClick:function(){},i=_?h.right[h.right.length-1].text:"",l=_?h.right[h.right.length-1].onClick:function(){};return{cancelBtnText:o,onCancel:r,okBtnText:n.a.createElement(n.a.Fragment,null,b&&n.a.createElement(a,{size:16}),i),onOk:function(){return l&&l(g)},okDisabled:b}}),[h.right,b]);return p?n.a.createElement(c.a,Object(o.__assign)({className:"recover-error-dialog",title:_},k),u):null}},c289:function(e,t,_){"use strict";var o=_("134e"),r=_.n(o),n=_("6b8d"),i=_.n(n),l=_("6633"),a=_.n(l),c=_("7eda"),d=_.n(c),s=_("5689"),p=_.n(s),m=_("1bd7"),h=_.n(m),u=_("182d"),w=_("a07e"),b=_.n(w),f=_("e8d1"),g=_.n(f),k=(_("9945"),_("2c4e")),v=window._isHybrid&&window.__INJECT__&&window.__INJECT__.isSupportLongOffline,y={},x=function(e){function t(e){i()(this,t);var _=d()(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return _.state={onLine:window.navigator.onLine},_.checkOnline=function(){if(window.__WPSENV__.store){var e=window.__WPSENV__.store.getState().public.network.connected;_.setState({onLine:e})}},_.refWrap=h.a.createRef(),_.handleOnline=_.handleOnline.bind(_),_}return p()(t,e),a()(t,[{key:"componentDidMount",value:function(){this.state.onLine||(this.checkOnline(),window.addEventListener("online",this.handleOnline),window.addEventListener(k.default.names.network.ON_CONNECTED,this.handleOnline))}},{key:"componentWillUnmount",value:function(){window.removeEventListener("online",this.handleOnline),window.removeEventListener(k.default.names.network.ON_CONNECTED,this.handleOnline)}},{key:"handleOnline",value:function(){this.setState({onLine:!0})}},{key:"getTypeName",value:function(e,t,_){var o=this.state.onLine,r="icons-"+t+"-"+_;return e||o||y[r]||v?(y[r]=!0,r):""}},{key:"getElement",value:function(){return this.refWrap.current}},{key:"render",value:function(){var e,t=this.props,_=t.iconType,o=t.className,r=t.onClick,n=_.split(" "),i=g()(n,3),l=i[0],a=i[1],c=i[2],d=null;"loading"!==a&&(d=this.getTypeName(c,l,a.toLowerCase()));var s=h.a.classNames((e={icons:1},b()(e,"icons-"+l,1),b()(e,d,!!d),e),o);return h.a.createElement("i",{ref:this.refWrap,className:s,onClick:r},"loading"===a&&h.a.createElement("i",{className:"icons-loading"}))}}]),t}(m.PureComponent);var C=fu |
|