filecat 7.19.0 → 7.20.1

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 (41) hide show
  1. package/build/dist/{1075.1b51ec4165a736f17167.js → 1075.d1c52b0474a02deca2a7.js} +1 -1
  2. package/build/dist/1636.f2a1d2c8cdfb4d88cd65.js +1 -0
  3. package/build/dist/2334.01508a16bdae8e884919.js +1 -0
  4. package/build/dist/2547.4594e21c13d748e832bd.js +1 -0
  5. package/build/dist/2674.9ee06a379b79d961ec80.js +1 -0
  6. package/build/dist/{3402.b6dc28d2f9bace7cde85.js → 3402.30e70a3fe5d2c355bae5.js} +1 -1
  7. package/build/dist/3528.f4bf3684610c3ce28c08.js +1 -0
  8. package/build/dist/3659.a257153b5a0947e81b3c.js +1 -0
  9. package/build/dist/4903.a4194ec784a0ff517e93.js +1 -0
  10. package/build/dist/6404.a22a232695feabc4ced4.js +1 -0
  11. package/build/dist/6805.d46e56ad021c3bdf31c3.js +1 -0
  12. package/build/dist/7181.2403d6d75f9d4ea6917d.js +1 -0
  13. package/build/dist/735.3ad00d641e954426413e.js +1 -0
  14. package/build/dist/8358.3390335b191e2d9c6d0f.js +1 -0
  15. package/build/dist/{8649.bc1338c32cdf89b1ef37.js → 8649.079b2b71e5ff82a51690.js} +1 -1
  16. package/build/dist/9857.2bc49ff0432a7ec15da5.js +1 -0
  17. package/build/dist/index.html +1 -1
  18. package/build/dist/main.b3a24ee626d321ee67fc.js +2 -0
  19. package/build/dist/{main.04042464d0cefb1813fa.js.LICENSE.txt → main.b3a24ee626d321ee67fc.js.LICENSE.txt} +2 -0
  20. package/build/main.js +1 -1
  21. package/package.json +2 -2
  22. package/build/dist/1636.b6a17252dfd0d22f09a7.js +0 -1
  23. package/build/dist/2626.05d1faa293e0a3318b9b.js +0 -1
  24. package/build/dist/2674.ce785310ebf36a69df86.js +0 -1
  25. package/build/dist/3528.fde2729943266724c34a.js +0 -1
  26. package/build/dist/3659.51d135c7d39971353f38.js +0 -1
  27. package/build/dist/4903.cac82807407e7342b5ad.js +0 -1
  28. package/build/dist/4946.c95d4f426146e0180172.js +0 -2
  29. package/build/dist/4946.c95d4f426146e0180172.js.LICENSE.txt +0 -1
  30. package/build/dist/6010.5400c344149450c83284.js +0 -1
  31. package/build/dist/6104.05cd833b0fa8c283023e.js +0 -1
  32. package/build/dist/6404.b92b1aa07125d981f50d.js +0 -1
  33. package/build/dist/6805.c5a415cdd8bcf6b813fe.js +0 -1
  34. package/build/dist/7181.76f4ac3d5107cd7966a3.js +0 -1
  35. package/build/dist/735.a026520268d567d61074.js +0 -1
  36. package/build/dist/8302.77e6bff8cda76307dc51.js +0 -1
  37. package/build/dist/8358.6c06132151ac5a4d5e1a.js +0 -1
  38. package/build/dist/892.866405af488ffd431596.js +0 -1
  39. package/build/dist/9299.a90b11a4eaf6fb241b97.js +0 -1
  40. package/build/dist/9334.8b01c2817e89e4e7b38a.js +0 -1
  41. package/build/dist/main.04042464d0cefb1813fa.js +0 -2
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "filecat",
3
- "version": "7.19.0",
3
+ "version": "7.20.1",
4
4
  "description": "A self-hosted Web File browser and lightweight server management tool.",
5
5
  "author": "xiaobaidadada",
6
6
  "repository": {
@@ -46,7 +46,7 @@
46
46
  "@xiaobaidadada/ssh2-prebuilt": "^1.16.0",
47
47
  "better-sqlite3": "^12.6.2",
48
48
  "node-libsmb2": "^1.1.1",
49
- "node-process-watcher": "^1.6.6"
49
+ "node-process-watcher": "^1.7.7"
50
50
  },
51
51
  "devDependencies": {
52
52
  "@aws-sdk/client-s3": "^3.1141.0",
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[1636],{88062(e,n,s){s.d(n,{A:()=>c});s(96540),s(47022);var o=s(74848);function t(e){return(0,o.jsx)("div",{className:"black-tip",onClick:()=>{e.click&&e.click(e)},onContextMenu:n=>{n.stopPropagation(),n.nativeEvent.stopImmediatePropagation(),e.onContextMenu&&e.onContextMenu(n,e)},children:e.name})}const i=e=>(0,o.jsxs)("li",{children:[e.click?(0,o.jsx)(t,{...e.node,name:e.render?e.render(e.node):e.node.name,click:e.click,onContextMenu:e.onContextMenu}):(0,o.jsx)("div",{children:e.render?e.render(e.node):e.node.name}),e.node.children&&e.node.children.length>0&&(0,o.jsx)("ul",{children:e.node.children.map((n,s)=>(0,o.jsx)(i,{node:n,click:e.click,onContextMenu:e.onContextMenu,render:e.render},s))})]}),c=e=>(0,o.jsx)("div",{className:"card-tree-view",children:(0,o.jsx)("ul",{children:e.list&&e.list.map((n,s)=>(0,o.jsx)(i,{node:n,click:e.click,onContextMenu:e.onContextMenu,render:e.render},s))})})},81636(e,n,s){s.r(n),s.d(n,{default:()=>w});var o=s(22022),t=s(96540),i=s(34843),c=s(82893),r=s(92275),l=s(14944),d=s(70447),a=s(85997),u=s(4412),x=s(75725),f=s(47071),h=s(34289),m=s(88062),j=s(97856),v=(s(62042),s(15629),s(74848));const k=t.lazy(()=>s.e(3233).then(s.bind(s,85614)));let p,_;function w(e){const{t:n}=(0,o.Bd)(),[s,w]=(0,i.fp)(c.AG.workflow_realtime_show),[g,C]=(0,t.useState)([]),[y,M]=(0,t.useState)([]),[b,q]=(0,t.useState)(!1),[S,F]=(0,t.useState)(void 0),[N,$]=(0,t.useState)([]),A=e=>{for(const n of e){if(null==n.code&&n?.extra_data?.running_type===f.rl.running)n.name=(0,v.jsxs)("div",{children:[(0,v.jsx)(d.fq,{running:!0}),n.name]});else if(0===n.code)n.name=(0,v.jsxs)("div",{children:[(0,v.jsx)(d.fq,{success:!0}),n.name]});else{if(!(n.code<1)){delete n.children;continue}n.name=(0,v.jsxs)("div",{children:[(0,v.jsx)(d.fq,{success:!1}),n.name]})}n.children&&A(n.children)}};(0,t.useEffect)(()=>(q(!1),p=void 0,_=void 0,(async()=>{const e=new f.v3;e.filename_path=`${(0,h.GG)("file",(0,h.vX)())}${s.filename}`,l.ws.addMsg(r.HK.workflow_realtime_one_rsq,e=>{if(e.context.list&&e.context.list.length>0){const n=e.context.list;A(n),$(n)}e.context.new_log&&B(e.context.new_log)}),l.ws.sendData(r.HK.workflow_realtime_one_req,e)})(),async()=>{l.ws.removeMsg(r.HK.workflow_realtime_one_rsq),_&&(_.dispose(),_=null)}),[]);const B=async e=>{_||await new Promise(e=>{p=e,q(!0),(async()=>{const e=new j.Terminal({fontFamily:"Monaco, Menlo, Consolas, 'Courier New', monospace",theme:{background:"#FFFFFF",foreground:"#000000",cursor:"#000000",selectionBackground:"#a6d2ff"},cursorBlink:!0,cursorStyle:"bar",scrollback:1e3,scrollSensitivity:1,tabStopWidth:4,convertEol:!0});_=e,F(e)})()}),e&&_.write(e)};return(0,v.jsxs)("div",{children:[(0,v.jsxs)(u.aZ,{position:"right",children:[S&&(0,v.jsx)(a.rA,{icon:"print",title:"打印日志",onClick:()=>{q(!b)}}),(0,v.jsx)(a.rA,{icon:"close",title:n("关闭"),onClick:()=>{w({open:!1})}})]}),(0,v.jsx)(x.jW,{isFull:!0,more:!0,children:(0,v.jsx)(x.NN,{children:(0,v.jsx)(m.A,{list:N,click:e=>{}})})}),(0,v.jsx)("div",{style:{display:b?"":"none"},children:(0,v.jsx)(k,{show:!0,terminal:S,init:()=>{p&&(p(1),p=void 0)}})})]})}},15629(e,n,s){s.d(n,{W:()=>r,Y:()=>l});s(96540);var o=s(70447),t=s(47071),i=s(22022),c=s(74848);function r({item:e}){const{t:n}=(0,i.Bd)();let s,r;return null!=e.code?s=0===e.code:e.extra_data?.running_type===t.rl.running&&(r=!0),(0,c.jsxs)("div",{children:[(0,c.jsx)(o.fq,{success:s,running:r}),n(s?"成功":"失败")]})}const l=(e,n,s)=>{if(n)for(const s of n??[]){let n;const t=[];s["use-yml"]?(l(t,void 0,s.use_job_children_list),n=`${s["use-yml"]} ;${s.duration??-1}`):s.runs?n=JSON.stringify(s.runs):s.run?n=s.run:s["run-js"]?n=s["run-js"]:s.sleep&&(n=`sleep ${s.sleep}`),n=(0,c.jsxs)("div",{children:[(0,c.jsx)(o.fq,{success:void 0===s.code?void 0:0===s.code})," ",n+" ;"+(s.duration??"")]}),e.push({name:n,children:t,extra_data:{code:s.code,context:s.message}})}else if(s)for(const n of s??[]){const s=(0,c.jsxs)("div",{children:[(0,c.jsx)(o.fq,{success:void 0===n.code?void 0:0===n.code}),"$",n.name]});e.push({name:s,extra_data:{code:n.code,is_job:!0,job_data:n}})}}}}]);
@@ -1 +0,0 @@
1
- (self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[2626],{62718(n,o,e){"use strict";e.d(o,{A:()=>b});var t=e(31601),r=e.n(t),a=e(76314),l=e.n(a),i=e(4417),s=e.n(i),d=new URL(e(60840),e.b),c=l()(r()),m=s()(d);c.push([n.id,`.markdown-body {\n --base-size-16: 1rem;\n --base-size-24: 1.5rem;\n --base-size-4: 0.25rem;\n --base-size-40: 2.5rem;\n --base-size-8: 0.5rem;\n --base-text-weight-medium: 500;\n --base-text-weight-normal: 400;\n --base-text-weight-semibold: 600;\n --fontStack-monospace: ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace;\n --fontStack-sansSerif: -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji";\n --fgColor-accent: Highlight;\n}\n@media (prefers-color-scheme: dark) {\n .markdown-body, [data-theme="dark"] {\n /*dark */\n color-scheme: dark;\n --fgColor-accent: #4493f8;\n --bgColor-attention-muted: #bb800926;\n --bgColor-default: #0d1117;\n --bgColor-muted: #151b23;\n --bgColor-neutral-muted: #656c7633;\n --borderColor-accent-emphasis: #1f6feb;\n --borderColor-attention-emphasis: #9e6a03;\n --borderColor-danger-emphasis: #da3633;\n --borderColor-default: #3d444d;\n --borderColor-done-emphasis: #8957e5;\n --borderColor-success-emphasis: #238636;\n --color-prettylights-syntax-brackethighlighter-angle: #9198a1;\n --color-prettylights-syntax-brackethighlighter-unmatched: #f85149;\n --color-prettylights-syntax-carriage-return-bg: #b62324;\n --color-prettylights-syntax-carriage-return-text: #f0f6fc;\n --color-prettylights-syntax-comment: #9198a1;\n --color-prettylights-syntax-constant: #79c0ff;\n --color-prettylights-syntax-constant-other-reference-link: #a5d6ff;\n --color-prettylights-syntax-entity: #d2a8ff;\n --color-prettylights-syntax-entity-tag: #7ee787;\n --color-prettylights-syntax-keyword: #ff7b72;\n --color-prettylights-syntax-markup-bold: #f0f6fc;\n --color-prettylights-syntax-markup-changed-bg: #5a1e02;\n --color-prettylights-syntax-markup-changed-text: #ffdfb6;\n --color-prettylights-syntax-markup-deleted-bg: #67060c;\n --color-prettylights-syntax-markup-deleted-text: #ffdcd7;\n --color-prettylights-syntax-markup-heading: #1f6feb;\n --color-prettylights-syntax-markup-ignored-bg: #1158c7;\n --color-prettylights-syntax-markup-ignored-text: #f0f6fc;\n --color-prettylights-syntax-markup-inserted-bg: #033a16;\n --color-prettylights-syntax-markup-inserted-text: #aff5b4;\n --color-prettylights-syntax-markup-italic: #f0f6fc;\n --color-prettylights-syntax-markup-list: #f2cc60;\n --color-prettylights-syntax-meta-diff-range: #d2a8ff;\n --color-prettylights-syntax-storage-modifier-import: #f0f6fc;\n --color-prettylights-syntax-string: #a5d6ff;\n --color-prettylights-syntax-string-regexp: #7ee787;\n --color-prettylights-syntax-sublimelinter-gutter-mark: #3d444d;\n --color-prettylights-syntax-variable: #ffa657;\n --fgColor-attention: #d29922;\n --fgColor-danger: #f85149;\n --fgColor-default: #f0f6fc;\n --fgColor-done: #ab7df8;\n --fgColor-muted: #9198a1;\n --fgColor-success: #3fb950;\n --borderColor-muted: #3d444db3;\n --color-prettylights-syntax-invalid-illegal-bg: var(--bgColor-danger-muted);\n --color-prettylights-syntax-invalid-illegal-text: var(--fgColor-danger);\n --focus-outlineColor: var(--borderColor-accent-emphasis);\n --borderColor-neutral-muted: var(--borderColor-muted);\n }\n}\n@media (prefers-color-scheme: light) {\n .markdown-body, [data-theme="light"] {\n /*light */\n color-scheme: light;\n --fgColor-danger: #d1242f;\n --bgColor-attention-muted: #fff8c5;\n --bgColor-muted: #f6f8fa;\n --bgColor-neutral-muted: #818b981f;\n --borderColor-accent-emphasis: #0969da;\n --borderColor-attention-emphasis: #9a6700;\n --borderColor-danger-emphasis: #cf222e;\n --borderColor-default: #d1d9e0;\n --borderColor-done-emphasis: #8250df;\n --borderColor-success-emphasis: #1a7f37;\n --color-prettylights-syntax-brackethighlighter-angle: #59636e;\n --color-prettylights-syntax-brackethighlighter-unmatched: #82071e;\n --color-prettylights-syntax-carriage-return-bg: #cf222e;\n --color-prettylights-syntax-carriage-return-text: #f6f8fa;\n --color-prettylights-syntax-comment: #59636e;\n --color-prettylights-syntax-constant: #0550ae;\n --color-prettylights-syntax-constant-other-reference-link: #0a3069;\n --color-prettylights-syntax-entity: #6639ba;\n --color-prettylights-syntax-entity-tag: #0550ae;\n --color-prettylights-syntax-invalid-illegal-text: var(--fgColor-danger);\n --color-prettylights-syntax-keyword: #cf222e;\n --color-prettylights-syntax-markup-changed-bg: #ffd8b5;\n --color-prettylights-syntax-markup-changed-text: #953800;\n --color-prettylights-syntax-markup-deleted-bg: #ffebe9;\n --color-prettylights-syntax-markup-deleted-text: #82071e;\n --color-prettylights-syntax-markup-heading: #0550ae;\n --color-prettylights-syntax-markup-ignored-bg: #0550ae;\n --color-prettylights-syntax-markup-ignored-text: #d1d9e0;\n --color-prettylights-syntax-markup-inserted-bg: #dafbe1;\n --color-prettylights-syntax-markup-inserted-text: #116329;\n --color-prettylights-syntax-markup-list: #3b2300;\n --color-prettylights-syntax-meta-diff-range: #8250df;\n --color-prettylights-syntax-string: #0a3069;\n --color-prettylights-syntax-string-regexp: #116329;\n --color-prettylights-syntax-sublimelinter-gutter-mark: #818b98;\n --color-prettylights-syntax-variable: #953800;\n --fgColor-accent: #0969da;\n --fgColor-attention: #9a6700;\n --fgColor-done: #8250df;\n --fgColor-muted: #59636e;\n --fgColor-success: #1a7f37;\n --bgColor-default: #ffffff;\n --borderColor-muted: #d1d9e0b3;\n --color-prettylights-syntax-invalid-illegal-bg: var(--bgColor-danger-muted);\n --color-prettylights-syntax-markup-bold: #1f2328;\n --color-prettylights-syntax-markup-italic: #1f2328;\n --color-prettylights-syntax-storage-modifier-import: #1f2328;\n --fgColor-default: #1f2328;\n --focus-outlineColor: var(--borderColor-accent-emphasis);\n --borderColor-neutral-muted: var(--borderColor-muted);\n }\n}\n\n.markdown-body {\n /** CSS default easing. Use for hover state changes and micro-interactions. */\n /** Accelerating motion. Use for elements exiting the viewport (moving off-screen). */\n /** Smooth acceleration and deceleration. Use for elements moving or morphing within the viewport. */\n /** Decelerating motion. Use for elements entering the viewport or appearing on screen. */\n /** Constant motion with no acceleration. Use for continuous animations like progress bars or loaders. */\n -ms-text-size-adjust: 100%;\n -webkit-text-size-adjust: 100%;\n margin: 0;\n font-weight: var(--base-text-weight-normal, 400);\n color: var(--fgColor-default);\n background-color: var(--bgColor-default);\n font-family: var(--fontStack-sansSerif, -apple-system, BlinkMacSystemFont, "Segoe UI", "Noto Sans", Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji");\n font-size: 16px;\n line-height: 1.5;\n word-wrap: break-word;\n}\n\n.markdown-body a {\n text-decoration: underline;\n text-underline-offset: .2rem;\n}\n\n.markdown-body .octicon {\n display: inline-block;\n fill: currentColor;\n vertical-align: text-bottom;\n}\n\n.markdown-body h1:hover .anchor .octicon-link:before,\n.markdown-body h2:hover .anchor .octicon-link:before,\n.markdown-body h3:hover .anchor .octicon-link:before,\n.markdown-body h4:hover .anchor .octicon-link:before,\n.markdown-body h5:hover .anchor .octicon-link:before,\n.markdown-body h6:hover .anchor .octicon-link:before {\n width: 16px;\n height: 16px;\n content: ' ';\n display: inline-block;\n background-color: currentColor;\n -webkit-mask-image: url(${m});\n mask-image: url(${m});\n}\n\n.markdown-body details,\n.markdown-body figcaption,\n.markdown-body figure {\n display: block;\n}\n\n.markdown-body summary {\n display: list-item;\n}\n\n.markdown-body [hidden] {\n display: none !important;\n}\n\n.markdown-body a {\n background-color: rgba(0,0,0,0);\n color: var(--fgColor-accent);\n text-decoration: none;\n}\n\n.markdown-body abbr[title] {\n border-bottom: none;\n -webkit-text-decoration: underline dotted;\n text-decoration: underline dotted;\n}\n\n.markdown-body b,\n.markdown-body strong {\n font-weight: var(--base-text-weight-semibold, 600);\n}\n\n.markdown-body dfn {\n font-style: italic;\n}\n\n.markdown-body h1 {\n margin: .67em 0;\n font-weight: var(--base-text-weight-semibold, 600);\n padding-bottom: .3em;\n font-size: 2em;\n border-bottom: 1px solid var(--borderColor-muted);\n}\n\n.markdown-body mark {\n background-color: var(--bgColor-attention-muted);\n color: var(--fgColor-default);\n}\n\n.markdown-body small {\n font-size: 90%;\n}\n\n.markdown-body sub,\n.markdown-body sup {\n font-size: 75%;\n line-height: 0;\n position: relative;\n vertical-align: baseline;\n}\n\n.markdown-body sub {\n bottom: -0.25em;\n}\n\n.markdown-body sup {\n top: -0.5em;\n}\n\n.markdown-body img {\n border-style: none;\n max-width: 100%;\n box-sizing: content-box;\n}\n\n.markdown-body code,\n.markdown-body kbd,\n.markdown-body pre,\n.markdown-body samp {\n font-family: monospace;\n font-size: 1em;\n}\n\n.markdown-body figure {\n margin: 1em var(--base-size-40);\n}\n\n.markdown-body hr {\n box-sizing: content-box;\n overflow: hidden;\n background: rgba(0,0,0,0);\n border-bottom: 1px solid var(--borderColor-muted);\n height: .25em;\n padding: 0;\n margin: var(--base-size-24) 0;\n background-color: var(--borderColor-default);\n border: 0;\n}\n\n.markdown-body input {\n font: inherit;\n margin: 0;\n overflow: visible;\n font-family: inherit;\n font-size: inherit;\n line-height: inherit;\n}\n\n.markdown-body [type=button],\n.markdown-body [type=reset],\n.markdown-body [type=submit] {\n -webkit-appearance: button;\n appearance: button;\n}\n\n.markdown-body [type=checkbox],\n.markdown-body [type=radio] {\n box-sizing: border-box;\n padding: 0;\n}\n\n.markdown-body [type=number]::-webkit-inner-spin-button,\n.markdown-body [type=number]::-webkit-outer-spin-button {\n height: auto;\n}\n\n.markdown-body [type=search]::-webkit-search-cancel-button,\n.markdown-body [type=search]::-webkit-search-decoration {\n -webkit-appearance: none;\n appearance: none;\n}\n\n.markdown-body ::-webkit-input-placeholder {\n color: inherit;\n opacity: .54;\n}\n\n.markdown-body ::-webkit-file-upload-button {\n -webkit-appearance: button;\n appearance: button;\n font: inherit;\n}\n\n.markdown-body a:hover {\n text-decoration: underline;\n}\n\n.markdown-body ::placeholder {\n color: var(--fgColor-muted);\n opacity: 1;\n}\n\n.markdown-body hr::before {\n display: table;\n content: "";\n}\n\n.markdown-body hr::after {\n display: table;\n clear: both;\n content: "";\n}\n\n.markdown-body table {\n border-spacing: 0;\n border-collapse: collapse;\n display: block;\n width: max-content;\n max-width: 100%;\n overflow: auto;\n font-variant: tabular-nums;\n}\n\n.markdown-body td,\n.markdown-body th {\n padding: 0;\n}\n\n.markdown-body details summary {\n cursor: pointer;\n}\n\n.markdown-body a:focus,\n.markdown-body [role=button]:focus,\n.markdown-body input[type=radio]:focus,\n.markdown-body input[type=checkbox]:focus {\n outline: 2px solid var(--focus-outlineColor);\n outline-offset: -2px;\n box-shadow: none;\n}\n\n.markdown-body a:focus:not(:focus-visible),\n.markdown-body [role=button]:focus:not(:focus-visible),\n.markdown-body input[type=radio]:focus:not(:focus-visible),\n.markdown-body input[type=checkbox]:focus:not(:focus-visible) {\n outline: solid 1px rgba(0,0,0,0);\n}\n\n.markdown-body a:focus-visible,\n.markdown-body [role=button]:focus-visible,\n.markdown-body input[type=radio]:focus-visible,\n.markdown-body input[type=checkbox]:focus-visible {\n outline: 2px solid var(--focus-outlineColor);\n outline-offset: -2px;\n box-shadow: none;\n}\n\n.markdown-body a:not([class]):focus,\n.markdown-body a:not([class]):focus-visible,\n.markdown-body input[type=radio]:focus,\n.markdown-body input[type=radio]:focus-visible,\n.markdown-body input[type=checkbox]:focus,\n.markdown-body input[type=checkbox]:focus-visible {\n outline-offset: 0;\n}\n\n.markdown-body kbd {\n display: inline-block;\n padding: var(--base-size-4);\n font: 11px var(--fontStack-monospace, ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace);\n line-height: 10px;\n color: var(--fgColor-default);\n vertical-align: middle;\n background-color: var(--bgColor-muted);\n border: solid 1px var(--borderColor-neutral-muted);\n border-bottom-color: var(--borderColor-neutral-muted);\n border-radius: 6px;\n box-shadow: inset 0 -1px 0 var(--borderColor-neutral-muted);\n}\n\n.markdown-body h1,\n.markdown-body h2,\n.markdown-body h3,\n.markdown-body h4,\n.markdown-body h5,\n.markdown-body h6 {\n margin-top: var(--base-size-24);\n margin-bottom: var(--base-size-16);\n font-weight: var(--base-text-weight-semibold, 600);\n line-height: 1.25;\n}\n\n.markdown-body h2 {\n font-weight: var(--base-text-weight-semibold, 600);\n padding-bottom: .3em;\n font-size: 1.5em;\n border-bottom: 1px solid var(--borderColor-muted);\n}\n\n.markdown-body h3 {\n font-weight: var(--base-text-weight-semibold, 600);\n font-size: 1.25em;\n}\n\n.markdown-body h4 {\n font-weight: var(--base-text-weight-semibold, 600);\n font-size: 1em;\n}\n\n.markdown-body h5 {\n font-weight: var(--base-text-weight-semibold, 600);\n font-size: .875em;\n}\n\n.markdown-body h6 {\n font-weight: var(--base-text-weight-semibold, 600);\n font-size: .85em;\n color: var(--fgColor-muted);\n}\n\n.markdown-body p {\n margin-top: 0;\n margin-bottom: 10px;\n}\n\n.markdown-body blockquote {\n margin: 0;\n padding: 0 1em;\n color: var(--fgColor-muted);\n border-left: .25em solid var(--borderColor-default);\n}\n\n.markdown-body ul,\n.markdown-body ol {\n margin-top: 0;\n margin-bottom: 0;\n padding-left: 2em;\n}\n\n.markdown-body ol ol,\n.markdown-body ul ol {\n list-style-type: lower-roman;\n}\n\n.markdown-body ul ul ol,\n.markdown-body ul ol ol,\n.markdown-body ol ul ol,\n.markdown-body ol ol ol {\n list-style-type: lower-alpha;\n}\n\n.markdown-body dd {\n margin-left: 0;\n}\n\n.markdown-body tt,\n.markdown-body code,\n.markdown-body samp {\n font-family: var(--fontStack-monospace, ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace);\n font-size: 12px;\n}\n\n.markdown-body pre {\n margin-top: 0;\n margin-bottom: 0;\n font-family: var(--fontStack-monospace, ui-monospace, SFMono-Regular, SF Mono, Menlo, Consolas, Liberation Mono, monospace);\n font-size: 12px;\n word-wrap: normal;\n}\n\n.markdown-body .octicon {\n display: inline-block;\n overflow: visible !important;\n vertical-align: text-bottom;\n fill: currentColor;\n}\n\n.markdown-body input::-webkit-outer-spin-button,\n.markdown-body input::-webkit-inner-spin-button {\n margin: 0;\n appearance: none;\n}\n\n.markdown-body .mr-2 {\n margin-right: var(--base-size-8, 8px) !important;\n}\n\n.markdown-body::before {\n display: table;\n content: "";\n}\n\n.markdown-body::after {\n display: table;\n clear: both;\n content: "";\n}\n\n.markdown-body>*:first-child {\n margin-top: 0 !important;\n}\n\n.markdown-body>*:last-child {\n margin-bottom: 0 !important;\n}\n\n.markdown-body a:not([href]) {\n color: inherit;\n text-decoration: none;\n}\n\n.markdown-body .absent {\n color: var(--fgColor-danger);\n}\n\n.markdown-body .anchor {\n float: left;\n padding-right: var(--base-size-4);\n margin-left: -20px;\n line-height: 1;\n}\n\n.markdown-body .anchor:focus {\n outline: none;\n}\n\n.markdown-body p,\n.markdown-body blockquote,\n.markdown-body ul,\n.markdown-body ol,\n.markdown-body dl,\n.markdown-body table,\n.markdown-body pre,\n.markdown-body details {\n margin-top: 0;\n margin-bottom: var(--base-size-16);\n}\n\n.markdown-body blockquote>:first-child {\n margin-top: 0;\n}\n\n.markdown-body blockquote>:last-child {\n margin-bottom: 0;\n}\n\n.markdown-body h1 .octicon-link,\n.markdown-body h2 .octicon-link,\n.markdown-body h3 .octicon-link,\n.markdown-body h4 .octicon-link,\n.markdown-body h5 .octicon-link,\n.markdown-body h6 .octicon-link {\n color: var(--fgColor-default);\n vertical-align: middle;\n visibility: hidden;\n}\n\n.markdown-body h1:hover .anchor,\n.markdown-body h2:hover .anchor,\n.markdown-body h3:hover .anchor,\n.markdown-body h4:hover .anchor,\n.markdown-body h5:hover .anchor,\n.markdown-body h6:hover .anchor {\n text-decoration: none;\n}\n\n.markdown-body h1:hover .anchor .octicon-link,\n.markdown-body h2:hover .anchor .octicon-link,\n.markdown-body h3:hover .anchor .octicon-link,\n.markdown-body h4:hover .anchor .octicon-link,\n.markdown-body h5:hover .anchor .octicon-link,\n.markdown-body h6:hover .anchor .octicon-link {\n visibility: visible;\n}\n\n.markdown-body h1 tt,\n.markdown-body h1 code,\n.markdown-body h2 tt,\n.markdown-body h2 code,\n.markdown-body h3 tt,\n.markdown-body h3 code,\n.markdown-body h4 tt,\n.markdown-body h4 code,\n.markdown-body h5 tt,\n.markdown-body h5 code,\n.markdown-body h6 tt,\n.markdown-body h6 code {\n padding: 0 .2em;\n font-size: inherit;\n}\n\n.markdown-body summary h1,\n.markdown-body summary h2,\n.markdown-body summary h3,\n.markdown-body summary h4,\n.markdown-body summary h5,\n.markdown-body summary h6 {\n display: inline-block;\n}\n\n.markdown-body summary h1 .anchor,\n.markdown-body summary h2 .anchor,\n.markdown-body summary h3 .anchor,\n.markdown-body summary h4 .anchor,\n.markdown-body summary h5 .anchor,\n.markdown-body summary h6 .anchor {\n margin-left: -40px;\n}\n\n.markdown-body summary h1,\n.markdown-body summary h2 {\n padding-bottom: 0;\n border-bottom: 0;\n}\n\n.markdown-body ul.no-list,\n.markdown-body ol.no-list {\n padding: 0;\n list-style-type: none;\n}\n\n.markdown-body ol[type="a s"] {\n list-style-type: lower-alpha;\n}\n\n.markdown-body ol[type="A s"] {\n list-style-type: upper-alpha;\n}\n\n.markdown-body ol[type="i s"] {\n list-style-type: lower-roman;\n}\n\n.markdown-body ol[type="I s"] {\n list-style-type: upper-roman;\n}\n\n.markdown-body ol[type="1"] {\n list-style-type: decimal;\n}\n\n.markdown-body div>ol:not([type]) {\n list-style-type: decimal;\n}\n\n.markdown-body ul ul,\n.markdown-body ul ol,\n.markdown-body ol ol,\n.markdown-body ol ul {\n margin-top: 0;\n margin-bottom: 0;\n}\n\n.markdown-body li>p {\n margin-top: var(--base-size-16);\n}\n\n.markdown-body li+li {\n margin-top: .25em;\n}\n\n.markdown-body dl {\n padding: 0;\n}\n\n.markdown-body dl dt {\n padding: 0;\n margin-top: var(--base-size-16);\n font-size: 1em;\n font-style: italic;\n font-weight: var(--base-text-weight-semibold, 600);\n}\n\n.markdown-body dl dd {\n padding: 0 var(--base-size-16);\n margin-bottom: var(--base-size-16);\n}\n\n.markdown-body table th {\n font-weight: var(--base-text-weight-semibold, 600);\n}\n\n.markdown-body table th,\n.markdown-body table td {\n padding: 6px 13px;\n border: 1px solid var(--borderColor-default);\n}\n\n.markdown-body table td>:last-child {\n margin-bottom: 0;\n}\n\n.markdown-body table tr {\n background-color: var(--bgColor-default);\n border-top: 1px solid var(--borderColor-muted);\n}\n\n.markdown-body table tr:nth-child(2n) {\n background-color: var(--bgColor-muted);\n}\n\n.markdown-body table img {\n background-color: rgba(0,0,0,0);\n}\n\n.markdown-body img[align=right] {\n padding-left: 20px;\n}\n\n.markdown-body img[align=left] {\n padding-right: 20px;\n}\n\n.markdown-body .emoji {\n max-width: none;\n vertical-align: text-top;\n background-color: rgba(0,0,0,0);\n}\n\n.markdown-body span.frame {\n display: block;\n overflow: hidden;\n}\n\n.markdown-body span.frame>span {\n display: block;\n float: left;\n width: auto;\n padding: 7px;\n margin: 13px 0 0;\n overflow: hidden;\n border: 1px solid var(--borderColor-default);\n}\n\n.markdown-body span.frame span img {\n display: block;\n float: left;\n}\n\n.markdown-body span.frame span span {\n display: block;\n padding: 5px 0 0;\n clear: both;\n color: var(--fgColor-default);\n}\n\n.markdown-body span.align-center {\n display: block;\n overflow: hidden;\n clear: both;\n}\n\n.markdown-body span.align-center>span {\n display: block;\n margin: 13px auto 0;\n overflow: hidden;\n text-align: center;\n}\n\n.markdown-body span.align-center span img {\n margin: 0 auto;\n text-align: center;\n}\n\n.markdown-body span.align-right {\n display: block;\n overflow: hidden;\n clear: both;\n}\n\n.markdown-body span.align-right>span {\n display: block;\n margin: 13px 0 0;\n overflow: hidden;\n text-align: right;\n}\n\n.markdown-body span.align-right span img {\n margin: 0;\n text-align: right;\n}\n\n.markdown-body span.float-left {\n display: block;\n float: left;\n margin-right: 13px;\n overflow: hidden;\n}\n\n.markdown-body span.float-left span {\n margin: 13px 0 0;\n}\n\n.markdown-body span.float-right {\n display: block;\n float: right;\n margin-left: 13px;\n overflow: hidden;\n}\n\n.markdown-body span.float-right>span {\n display: block;\n margin: 13px auto 0;\n overflow: hidden;\n text-align: right;\n}\n\n.markdown-body code,\n.markdown-body tt {\n padding: .2em .4em;\n margin: 0;\n font-size: 85%;\n white-space: break-spaces;\n background-color: var(--bgColor-neutral-muted);\n border-radius: 6px;\n}\n\n.markdown-body code br,\n.markdown-body tt br {\n display: none;\n}\n\n.markdown-body del code {\n text-decoration: inherit;\n}\n\n.markdown-body samp {\n font-size: 85%;\n}\n\n.markdown-body pre code {\n font-size: 100%;\n}\n\n.markdown-body pre>code {\n padding: 0;\n margin: 0;\n word-break: normal;\n white-space: pre;\n background: rgba(0,0,0,0);\n border: 0;\n}\n\n.markdown-body .highlight {\n margin-bottom: var(--base-size-16);\n}\n\n.markdown-body .highlight pre {\n margin-bottom: 0;\n word-break: normal;\n}\n\n.markdown-body .highlight pre,\n.markdown-body pre {\n padding: var(--base-size-16);\n overflow: auto;\n font-size: 85%;\n line-height: 1.45;\n color: var(--fgColor-default);\n background-color: var(--bgColor-muted);\n border-radius: 6px;\n}\n\n.markdown-body pre code,\n.markdown-body pre tt {\n display: inline;\n padding: 0;\n margin: 0;\n overflow: visible;\n line-height: inherit;\n word-wrap: normal;\n background-color: rgba(0,0,0,0);\n border: 0;\n}\n\n.markdown-body .csv-data td,\n.markdown-body .csv-data th {\n padding: 5px;\n overflow: hidden;\n font-size: 12px;\n line-height: 1;\n text-align: left;\n white-space: nowrap;\n}\n\n.markdown-body .csv-data .blob-num {\n padding: 10px var(--base-size-8) 9px;\n text-align: right;\n background: var(--bgColor-default);\n border: 0;\n}\n\n.markdown-body .csv-data tr {\n border-top: 0;\n}\n\n.markdown-body .csv-data th {\n font-weight: var(--base-text-weight-semibold, 600);\n background: var(--bgColor-muted);\n border-top: 0;\n}\n\n.markdown-body [data-footnote-ref]::before {\n content: "[";\n}\n\n.markdown-body [data-footnote-ref]::after {\n content: "]";\n}\n\n.markdown-body .footnotes {\n font-size: 12px;\n color: var(--fgColor-muted);\n border-top: 1px solid var(--borderColor-default);\n}\n\n.markdown-body .footnotes ol {\n padding-left: var(--base-size-16);\n}\n\n.markdown-body .footnotes ol ul {\n display: inline-block;\n padding-left: var(--base-size-16);\n margin-top: var(--base-size-16);\n}\n\n.markdown-body .footnotes li {\n position: relative;\n}\n\n.markdown-body .footnotes li:target::before {\n position: absolute;\n top: calc(var(--base-size-8)*-1);\n right: calc(var(--base-size-8)*-1);\n bottom: calc(var(--base-size-8)*-1);\n left: calc(var(--base-size-24)*-1);\n pointer-events: none;\n content: "";\n border: 2px solid var(--borderColor-accent-emphasis);\n border-radius: 6px;\n}\n\n.markdown-body .footnotes li:target {\n color: var(--fgColor-default);\n}\n\n.markdown-body .footnotes .data-footnote-backref g-emoji {\n font-family: monospace;\n}\n\n.markdown-body .pl-c {\n color: var(--color-prettylights-syntax-comment);\n}\n\n.markdown-body .pl-c1,\n.markdown-body .pl-s .pl-v {\n color: var(--color-prettylights-syntax-constant);\n}\n\n.markdown-body .pl-e,\n.markdown-body .pl-en {\n color: var(--color-prettylights-syntax-entity);\n}\n\n.markdown-body .pl-smi,\n.markdown-body .pl-s .pl-s1 {\n color: var(--color-prettylights-syntax-storage-modifier-import);\n}\n\n.markdown-body .pl-ent {\n color: var(--color-prettylights-syntax-entity-tag);\n}\n\n.markdown-body .pl-k {\n color: var(--color-prettylights-syntax-keyword);\n}\n\n.markdown-body .pl-s,\n.markdown-body .pl-pds,\n.markdown-body .pl-s .pl-pse .pl-s1,\n.markdown-body .pl-sr,\n.markdown-body .pl-sr .pl-cce,\n.markdown-body .pl-sr .pl-sre,\n.markdown-body .pl-sr .pl-sra {\n color: var(--color-prettylights-syntax-string);\n}\n\n.markdown-body .pl-v,\n.markdown-body .pl-smw {\n color: var(--color-prettylights-syntax-variable);\n}\n\n.markdown-body .pl-bu {\n color: var(--color-prettylights-syntax-brackethighlighter-unmatched);\n}\n\n.markdown-body .pl-ii {\n color: var(--color-prettylights-syntax-invalid-illegal-text);\n background-color: var(--color-prettylights-syntax-invalid-illegal-bg);\n}\n\n.markdown-body .pl-c2 {\n color: var(--color-prettylights-syntax-carriage-return-text);\n background-color: var(--color-prettylights-syntax-carriage-return-bg);\n}\n\n.markdown-body .pl-sr .pl-cce {\n font-weight: bold;\n color: var(--color-prettylights-syntax-string-regexp);\n}\n\n.markdown-body .pl-ml {\n color: var(--color-prettylights-syntax-markup-list);\n}\n\n.markdown-body .pl-mh,\n.markdown-body .pl-mh .pl-en,\n.markdown-body .pl-ms {\n font-weight: bold;\n color: var(--color-prettylights-syntax-markup-heading);\n}\n\n.markdown-body .pl-mi {\n font-style: italic;\n color: var(--color-prettylights-syntax-markup-italic);\n}\n\n.markdown-body .pl-mb {\n font-weight: bold;\n color: var(--color-prettylights-syntax-markup-bold);\n}\n\n.markdown-body .pl-md {\n color: var(--color-prettylights-syntax-markup-deleted-text);\n background-color: var(--color-prettylights-syntax-markup-deleted-bg);\n}\n\n.markdown-body .pl-mi1 {\n color: var(--color-prettylights-syntax-markup-inserted-text);\n background-color: var(--color-prettylights-syntax-markup-inserted-bg);\n}\n\n.markdown-body .pl-mc {\n color: var(--color-prettylights-syntax-markup-changed-text);\n background-color: var(--color-prettylights-syntax-markup-changed-bg);\n}\n\n.markdown-body .pl-mi2 {\n color: var(--color-prettylights-syntax-markup-ignored-text);\n background-color: var(--color-prettylights-syntax-markup-ignored-bg);\n}\n\n.markdown-body .pl-mdr {\n font-weight: bold;\n color: var(--color-prettylights-syntax-meta-diff-range);\n}\n\n.markdown-body .pl-ba {\n color: var(--color-prettylights-syntax-brackethighlighter-angle);\n}\n\n.markdown-body .pl-sg {\n color: var(--color-prettylights-syntax-sublimelinter-gutter-mark);\n}\n\n.markdown-body .pl-corl {\n text-decoration: underline;\n color: var(--color-prettylights-syntax-constant-other-reference-link);\n}\n\n.markdown-body [role=button]:focus:not(:focus-visible),\n.markdown-body [role=tabpanel][tabindex="0"]:focus:not(:focus-visible),\n.markdown-body button:focus:not(:focus-visible),\n.markdown-body summary:focus:not(:focus-visible),\n.markdown-body a:focus:not(:focus-visible) {\n outline: none;\n box-shadow: none;\n}\n\n.markdown-body [tabindex="0"]:focus:not(:focus-visible),\n.markdown-body details-dialog:focus:not(:focus-visible) {\n outline: none;\n}\n\n.markdown-body g-emoji {\n display: inline-block;\n min-width: 1ch;\n font-family: "Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol";\n font-size: 1em;\n font-style: normal !important;\n font-weight: var(--base-text-weight-normal, 400);\n line-height: 1;\n vertical-align: -0.075em;\n}\n\n.markdown-body g-emoji img {\n width: 1em;\n height: 1em;\n}\n\n.markdown-body a:has(>p,>div,>pre,>blockquote) {\n display: block;\n}\n\n.markdown-body a:has(>p,>div,>pre,>blockquote):not(:has(.snippet-clipboard-content,>pre)) {\n width: fit-content;\n}\n\n.markdown-body a:has(>p,>div,>pre,>blockquote):has(.snippet-clipboard-content,>pre):focus-visible {\n outline: 2px solid var(--focus-outlineColor);\n outline-offset: 2px;\n}\n\n.markdown-body .task-list-item {\n list-style-type: none;\n}\n\n.markdown-body .task-list-item label {\n font-weight: var(--base-text-weight-normal, 400);\n}\n\n.markdown-body .task-list-item.enabled label {\n cursor: pointer;\n}\n\n.markdown-body .task-list-item+.task-list-item {\n margin-top: var(--base-size-4);\n}\n\n.markdown-body .task-list-item .handle {\n display: none;\n}\n\n.markdown-body .task-list-item-checkbox {\n margin: 0 .2em .25em -1.4em;\n vertical-align: middle;\n}\n\n.markdown-body ul:dir(rtl) .task-list-item-checkbox {\n margin: 0 -1.6em .25em .2em;\n}\n\n.markdown-body ol:dir(rtl) .task-list-item-checkbox {\n margin: 0 -1.6em .25em .2em;\n}\n\n.markdown-body .contains-task-list:hover .task-list-item-convert-container,\n.markdown-body .contains-task-list:focus-within .task-list-item-convert-container {\n display: block;\n width: auto;\n height: 24px;\n overflow: visible;\n clip-path: none;\n}\n\n.markdown-body ::-webkit-calendar-picker-indicator {\n filter: invert(50%);\n}\n\n.markdown-body .markdown-alert {\n padding: var(--base-size-8) var(--base-size-16);\n margin-bottom: var(--base-size-16);\n color: inherit;\n border-left: .25em solid var(--borderColor-default);\n}\n\n.markdown-body .markdown-alert>:first-child {\n margin-top: 0;\n}\n\n.markdown-body .markdown-alert>:last-child {\n margin-bottom: 0;\n}\n\n.markdown-body .markdown-alert .markdown-alert-title {\n display: flex;\n font-weight: var(--base-text-weight-medium, 500);\n align-items: center;\n line-height: 1;\n}\n\n.markdown-body .markdown-alert.markdown-alert-note {\n border-left-color: var(--borderColor-accent-emphasis);\n}\n\n.markdown-body .markdown-alert.markdown-alert-note .markdown-alert-title {\n color: var(--fgColor-accent);\n}\n\n.markdown-body .markdown-alert.markdown-alert-important {\n border-left-color: var(--borderColor-done-emphasis);\n}\n\n.markdown-body .markdown-alert.markdown-alert-important .markdown-alert-title {\n color: var(--fgColor-done);\n}\n\n.markdown-body .markdown-alert.markdown-alert-warning {\n border-left-color: var(--borderColor-attention-emphasis);\n}\n\n.markdown-body .markdown-alert.markdown-alert-warning .markdown-alert-title {\n color: var(--fgColor-attention);\n}\n\n.markdown-body .markdown-alert.markdown-alert-tip {\n border-left-color: var(--borderColor-success-emphasis);\n}\n\n.markdown-body .markdown-alert.markdown-alert-tip .markdown-alert-title {\n color: var(--fgColor-success);\n}\n\n.markdown-body .markdown-alert.markdown-alert-caution {\n border-left-color: var(--borderColor-danger-emphasis);\n}\n\n.markdown-body .markdown-alert.markdown-alert-caution .markdown-alert-title {\n color: var(--fgColor-danger);\n}\n\n.markdown-body>*:first-child>.heading-element:first-child {\n margin-top: 0 !important;\n}\n\n.markdown-body .highlight pre:has(+.zeroclipboard-container) {\n min-height: 52px;\n}\n\n`,""]);const b=c},32046(n,o,e){"use strict";e.d(o,{A:()=>i});var t=e(31601),r=e.n(t),a=e(76314),l=e.n(a)()(r());l.push([n.id,"pre code.hljs {\n display: block;\n overflow-x: auto;\n padding: 1em\n}\ncode.hljs {\n padding: 3px 5px\n}\n/*!\n Theme: GitHub Dark\n Description: Dark theme as seen on github.com\n Author: github.com\n Maintainer: @Hirse\n Updated: 2021-05-15\n\n Outdated base version: https://github.com/primer/github-syntax-dark\n Current colors taken from GitHub's CSS\n*/\n.hljs {\n color: #c9d1d9;\n background: #0d1117\n}\n.hljs-doctag,\n.hljs-keyword,\n.hljs-meta .hljs-keyword,\n.hljs-template-tag,\n.hljs-template-variable,\n.hljs-type,\n.hljs-variable.language_ {\n /* prettylights-syntax-keyword */\n color: #ff7b72\n}\n.hljs-title,\n.hljs-title.class_,\n.hljs-title.class_.inherited__,\n.hljs-title.function_ {\n /* prettylights-syntax-entity */\n color: #d2a8ff\n}\n.hljs-attr,\n.hljs-attribute,\n.hljs-literal,\n.hljs-meta,\n.hljs-number,\n.hljs-operator,\n.hljs-variable,\n.hljs-selector-attr,\n.hljs-selector-class,\n.hljs-selector-id {\n /* prettylights-syntax-constant */\n color: #79c0ff\n}\n.hljs-regexp,\n.hljs-string,\n.hljs-meta .hljs-string {\n /* prettylights-syntax-string */\n color: #a5d6ff\n}\n.hljs-built_in,\n.hljs-symbol {\n /* prettylights-syntax-variable */\n color: #ffa657\n}\n.hljs-comment,\n.hljs-code,\n.hljs-formula {\n /* prettylights-syntax-comment */\n color: #8b949e\n}\n.hljs-name,\n.hljs-quote,\n.hljs-selector-tag,\n.hljs-selector-pseudo {\n /* prettylights-syntax-entity-tag */\n color: #7ee787\n}\n.hljs-subst {\n /* prettylights-syntax-storage-modifier-import */\n color: #c9d1d9\n}\n.hljs-section {\n /* prettylights-syntax-markup-heading */\n color: #1f6feb;\n font-weight: bold\n}\n.hljs-bullet {\n /* prettylights-syntax-markup-list */\n color: #f2cc60\n}\n.hljs-emphasis {\n /* prettylights-syntax-markup-italic */\n color: #c9d1d9;\n font-style: italic\n}\n.hljs-strong {\n /* prettylights-syntax-markup-bold */\n color: #c9d1d9;\n font-weight: bold\n}\n.hljs-addition {\n /* prettylights-syntax-markup-inserted */\n color: #aff5b4;\n background-color: #033a16\n}\n.hljs-deletion {\n /* prettylights-syntax-markup-deleted */\n color: #ffdcd7;\n background-color: #67060c\n}\n.hljs-char.escape_,\n.hljs-link,\n.hljs-params,\n.hljs-property,\n.hljs-punctuation,\n.hljs-tag {\n /* purposely ignored */\n \n}",""]);const i=l},69428(n){var o=!0,e=!1,t=!1;function r(n,o,e){var t=n.attrIndex(o),r=[o,e];t<0?n.attrPush(r):n.attrs[t]=r}function a(n,o){for(var e=n[o].level-1,t=o-1;t>=0;t--)if(n[t].level===e)return t;return-1}function l(n,o){return"inline"===n[o].type&&function(n){return"paragraph_open"===n.type}(n[o-1])&&function(n){return"list_item_open"===n.type}(n[o-2])&&function(n){return 0===n.content.indexOf("[ ] ")||0===n.content.indexOf("[x] ")||0===n.content.indexOf("[X] ")}(n[o])}function i(n,r){if(n.children.unshift(function(n,e){var t=new e("html_inline","",0),r=o?' disabled="" ':"";0===n.content.indexOf("[ ] ")?t.content='<input class="task-list-item-checkbox"'+r+'type="checkbox">':0!==n.content.indexOf("[x] ")&&0!==n.content.indexOf("[X] ")||(t.content='<input class="task-list-item-checkbox" checked=""'+r+'type="checkbox">');return t}(n,r)),n.children[1].content=n.children[1].content.slice(3),n.content=n.content.slice(3),e)if(t){n.children.pop();var a="task-item-"+Math.ceil(1e7*Math.random()-1e3);n.children[0].content=n.children[0].content.slice(0,-1)+' id="'+a+'">',n.children.push(function(n,o,e){var t=new e("html_inline","",0);return t.content='<label class="task-list-item-label" for="'+o+'">'+n+"</label>",t.attrs=[{for:o}],t}(n.content,a,r))}else n.children.unshift(function(n){var o=new n("html_inline","",0);return o.content="<label>",o}(r)),n.children.push(function(n){var o=new n("html_inline","",0);return o.content="</label>",o}(r))}n.exports=function(n,s){s&&(o=!s.enabled,e=!!s.label,t=!!s.labelAfter),n.core.ruler.after("inline","github-task-lists",function(n){for(var e=n.tokens,t=2;t<e.length;t++)l(e,t)&&(i(e[t],n.Token),r(e[t-2],"class","task-list-item"+(o?"":" enabled")),r(e[a(e,t-2)],"class","contains-task-list"))})}},3775(n,o,e){"use strict";var t=e(85072),r=e.n(t),a=e(97825),l=e.n(a),i=e(77659),s=e.n(i),d=e(55056),c=e.n(d),m=e(10540),b=e.n(m),p=e(41113),h=e.n(p),y=e(62718),k={};k.styleTagTransform=h(),k.setAttributes=c(),k.insert=s().bind(null,"head"),k.domAPI=l(),k.insertStyleElement=b();r()(y.A,k),y.A&&y.A.locals&&y.A.locals},72411(n,o,e){"use strict";var t=e(85072),r=e.n(t),a=e(97825),l=e.n(a),i=e(77659),s=e.n(i),d=e(55056),c=e.n(d),m=e(10540),b=e.n(m),p=e(41113),h=e.n(p),y=e(32046),k={};k.styleTagTransform=h(),k.setAttributes=c(),k.insert=s().bind(null,"head"),k.domAPI=l(),k.insertStyleElement=b();r()(y.A,k),y.A&&y.A.locals&&y.A.locals},53995(n,o,e){"use strict";e.d(o,{A:()=>i});const t={grinning:"😀",smiley:"😃",smile:"😄",grin:"😁",laughing:"😆",satisfied:"😆",sweat_smile:"😅",joy:"😂",wink:"😉",blush:"😊",innocent:"😇",heart_eyes:"😍",kissing_heart:"😘",kissing:"😗",kissing_closed_eyes:"😚",kissing_smiling_eyes:"😙",yum:"😋",stuck_out_tongue:"😛",stuck_out_tongue_winking_eye:"😜",stuck_out_tongue_closed_eyes:"😝",neutral_face:"😐",expressionless:"😑",no_mouth:"😶",smirk:"😏",unamused:"😒",relieved:"😌",pensive:"😔",sleepy:"😪",sleeping:"😴",mask:"😷",dizzy_face:"😵",sunglasses:"😎",confused:"😕",worried:"😟",open_mouth:"😮",hushed:"😯",astonished:"😲",flushed:"😳",frowning:"😦",anguished:"😧",fearful:"😨",cold_sweat:"😰",disappointed_relieved:"😥",cry:"😢",sob:"😭",scream:"😱",confounded:"😖",persevere:"😣",disappointed:"😞",sweat:"😓",weary:"😩",tired_face:"😫",rage:"😡",pout:"😡",angry:"😠",smiling_imp:"😈",smiley_cat:"😺",smile_cat:"😸",joy_cat:"😹",heart_eyes_cat:"😻",smirk_cat:"😼",kissing_cat:"😽",scream_cat:"🙀",crying_cat_face:"😿",pouting_cat:"😾",heart:"❤️",hand:"✋",raised_hand:"✋",v:"✌️",point_up:"☝️",fist_raised:"✊",fist:"✊",monkey_face:"🐵",cat:"🐱",cow:"🐮",mouse:"🐭",coffee:"☕",hotsprings:"♨️",anchor:"⚓",airplane:"✈️",hourglass:"⌛",watch:"⌚",sunny:"☀️",star:"⭐",cloud:"☁️",umbrella:"☔",zap:"⚡",snowflake:"❄️",sparkles:"✨",black_joker:"🃏",mahjong:"🀄",phone:"☎️",telephone:"☎️",envelope:"✉️",pencil2:"✏️",black_nib:"✒️",scissors:"✂️",wheelchair:"♿",warning:"⚠️",aries:"♈",taurus:"♉",gemini:"♊",cancer:"♋",leo:"♌",virgo:"♍",libra:"♎",scorpius:"♏",sagittarius:"♐",capricorn:"♑",aquarius:"♒",pisces:"♓",heavy_multiplication_x:"✖️",heavy_plus_sign:"➕",heavy_minus_sign:"➖",heavy_division_sign:"➗",bangbang:"‼️",interrobang:"⁉️",question:"❓",grey_question:"❔",grey_exclamation:"❕",exclamation:"❗",heavy_exclamation_mark:"❗",wavy_dash:"〰️",recycle:"♻️",white_check_mark:"✅",ballot_box_with_check:"☑️",heavy_check_mark:"✔️",x:"❌",negative_squared_cross_mark:"❎",curly_loop:"➰",loop:"➿",part_alternation_mark:"〽️",eight_spoked_asterisk:"✳️",eight_pointed_black_star:"✴️",sparkle:"❇️",copyright:"©️",registered:"®️",tm:"™️",information_source:"ℹ️",m:"Ⓜ️",black_circle:"⚫",white_circle:"⚪",black_large_square:"⬛",white_large_square:"⬜",black_medium_square:"◼️",white_medium_square:"◻️",black_medium_small_square:"◾",white_medium_small_square:"◽",black_small_square:"▪️",white_small_square:"▫️"},r={angry:[">:(",">:-("],blush:[':")',':-")'],broken_heart:["</3","<\\3"],confused:[":/",":-/"],cry:[":'(",":'-(",":,(",":,-("],frowning:[":(",":-("],heart:["<3"],imp:["]:(","]:-("],innocent:["o:)","O:)","o:-)","O:-)","0:)","0:-)"],joy:[":')",":'-)",":,)",":,-)",":'D",":'-D",":,D",":,-D"],kissing:[":*",":-*"],laughing:["x-)","X-)"],neutral_face:[":|",":-|"],open_mouth:[":o",":-o",":O",":-O"],rage:[":@",":-@"],smile:[":D",":-D"],smiley:[":)",":-)"],smiling_imp:["]:)","]:-)"],sob:[":,'(",":,'-(",";(",";-("],stuck_out_tongue:[":P",":-P"],sunglasses:["8-)","B-)"],sweat:[",:(",",:-("],sweat_smile:[",:)",",:-)"],unamused:[":s",":-S",":z",":-Z",":$",":-$"],wink:[";)",";-)"]};function a(n,o){return n[o].content}function l(n,o){const e=function(n){let o=n.defs;n.enabled.length&&(o=Object.keys(o).reduce((e,t)=>(n.enabled.indexOf(t)>=0&&(e[t]=o[t]),e),{}));const e=Object.keys(n.shortcuts).reduce((e,t)=>o[t]?Array.isArray(n.shortcuts[t])?(n.shortcuts[t].forEach(n=>{e[n]=t}),e):(e[n.shortcuts[t]]=t,e):e,{}),t=Object.keys(o);let r;r=0===t.length?"^$":t.map(n=>`:${n}:`).concat(Object.keys(e)).sort().reverse().map(n=>n.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")).join("|");const a=RegExp(r),l=RegExp(r,"g");return{defs:o,shortcuts:e,scanRE:a,replaceRE:l}}(Object.assign({},{defs:{},shortcuts:{},enabled:[]},o||{}));n.renderer.rules.emoji=a,n.core.ruler.after("linkify","emoji",function(n,o,e,t,r){const a=n.utils.arrayReplaceAt,l=n.utils.lib.ucmicro,i=new RegExp([l.Z.source,l.P.source,l.Cc.source].join("|"));function s(n,t,a){let l=0;const s=[];if(n.replace(r,function(t,r,d){let c;if(Object.prototype.hasOwnProperty.call(e,t)){if(c=e[t],r>0&&!i.test(d[r-1]))return;if(r+t.length<d.length&&!i.test(d[r+t.length]))return}else c=t.slice(1,-1);if(r>l){const o=new a("text","",0);o.content=n.slice(l,r),s.push(o)}const m=new a("emoji","",0);m.markup=c,m.content=o[c],s.push(m),l=r+t.length}),l<n.length){const o=new a("text","",0);o.content=n.slice(l),s.push(o)}return s}return function(n){let o;const e=n.tokens;let r=0;for(let l=0,i=e.length;l<i;l++){if("inline"!==e[l].type)continue;let i=e[l].children;for(let d=i.length-1;d>=0;d--)o=i[d],"link_open"!==o.type&&"link_close"!==o.type||"auto"===o.info&&(r-=o.nesting),"text"===o.type&&0===r&&t.test(o.content)&&(e[l].children=i=a(i,d,s(o.content,o.level,n.Token)))}}}(n,e.defs,e.shortcuts,e.scanRE,e.replaceRE))}function i(n,o){const e={defs:t,shortcuts:r,enabled:[]};l(n,Object.assign({},e,o||{}))}},8263(n,o,e){"use strict";function t(n,o,e,t){const r=Number(n[o].meta.id+1).toString();let a="";return"string"==typeof t.docId&&(a=`-${t.docId}-`),a+r}function r(n,o){let e=Number(n[o].meta.id+1).toString();return n[o].meta.subId>0&&(e+=`:${n[o].meta.subId}`),`[${e}]`}function a(n,o,e,t,r){const a=r.rules.footnote_anchor_name(n,o,e,t,r),l=r.rules.footnote_caption(n,o,e,t,r);let i=a;return n[o].meta.subId>0&&(i+=`:${n[o].meta.subId}`),`<sup class="footnote-ref"><a href="#fn${a}" id="fnref${i}">${l}</a></sup>`}function l(n,o,e){return(e.xhtmlOut?'<hr class="footnotes-sep" />\n':'<hr class="footnotes-sep">\n')+'<section class="footnotes">\n<ol class="footnotes-list">\n'}function i(){return"</ol>\n</section>\n"}function s(n,o,e,t,r){let a=r.rules.footnote_anchor_name(n,o,e,t,r);return n[o].meta.subId>0&&(a+=`:${n[o].meta.subId}`),`<li id="fn${a}" class="footnote-item">`}function d(){return"</li>\n"}function c(n,o,e,t,r){let a=r.rules.footnote_anchor_name(n,o,e,t,r);return n[o].meta.subId>0&&(a+=`:${n[o].meta.subId}`),` <a href="#fnref${a}" class="footnote-backref">↩︎</a>`}function m(n){const o=n.helpers.parseLinkLabel,e=n.utils.isSpace;n.renderer.rules.footnote_ref=a,n.renderer.rules.footnote_block_open=l,n.renderer.rules.footnote_block_close=i,n.renderer.rules.footnote_open=s,n.renderer.rules.footnote_close=d,n.renderer.rules.footnote_anchor=c,n.renderer.rules.footnote_caption=r,n.renderer.rules.footnote_anchor_name=t,n.block.ruler.before("reference","footnote_def",function(n,o,t,r){const a=n.bMarks[o]+n.tShift[o],l=n.eMarks[o];if(a+4>l)return!1;if(91!==n.src.charCodeAt(a))return!1;if(94!==n.src.charCodeAt(a+1))return!1;let i;for(i=a+2;i<l;i++){if(32===n.src.charCodeAt(i))return!1;if(93===n.src.charCodeAt(i))break}if(i===a+2)return!1;if(i+1>=l||58!==n.src.charCodeAt(++i))return!1;if(r)return!0;i++,n.env.footnotes||(n.env.footnotes={}),n.env.footnotes.refs||(n.env.footnotes.refs={});const s=n.src.slice(a+2,i-2);n.env.footnotes.refs[`:${s}`]=-1;const d=new n.Token("footnote_reference_open","",1);d.meta={label:s},d.level=n.level++,n.tokens.push(d);const c=n.bMarks[o],m=n.tShift[o],b=n.sCount[o],p=n.parentType,h=i,y=n.sCount[o]+i-(n.bMarks[o]+n.tShift[o]);let k=y;for(;i<l;){const o=n.src.charCodeAt(i);if(!e(o))break;9===o?k+=4-k%4:k++,i++}n.tShift[o]=i-h,n.sCount[o]=k-y,n.bMarks[o]=h,n.blkIndent+=4,n.parentType="footnote",n.sCount[o]<n.blkIndent&&(n.sCount[o]+=n.blkIndent),n.md.block.tokenize(n,o,t,!0),n.parentType=p,n.blkIndent-=4,n.tShift[o]=m,n.sCount[o]=b,n.bMarks[o]=c;const u=new n.Token("footnote_reference_close","",-1);return u.level=--n.level,n.tokens.push(u),!0},{alt:["paragraph","reference"]}),n.inline.ruler.after("image","footnote_inline",function(n,e){const t=n.posMax,r=n.pos;if(r+2>=t)return!1;if(94!==n.src.charCodeAt(r))return!1;if(91!==n.src.charCodeAt(r+1))return!1;const a=r+2,l=o(n,r+1);if(l<0)return!1;if(!e){n.env.footnotes||(n.env.footnotes={}),n.env.footnotes.list||(n.env.footnotes.list=[]);const o=n.env.footnotes.list.length,e=[];n.md.inline.parse(n.src.slice(a,l),n.md,n.env,e);n.push("footnote_ref","",0).meta={id:o},n.env.footnotes.list[o]={content:n.src.slice(a,l),tokens:e}}return n.pos=l+1,n.posMax=t,!0}),n.inline.ruler.after("footnote_inline","footnote_ref",function(n,o){const e=n.posMax,t=n.pos;if(t+3>e)return!1;if(!n.env.footnotes||!n.env.footnotes.refs)return!1;if(91!==n.src.charCodeAt(t))return!1;if(94!==n.src.charCodeAt(t+1))return!1;let r;for(r=t+2;r<e;r++){if(32===n.src.charCodeAt(r))return!1;if(10===n.src.charCodeAt(r))return!1;if(93===n.src.charCodeAt(r))break}if(r===t+2)return!1;if(r>=e)return!1;r++;const a=n.src.slice(t+2,r-1);if(void 0===n.env.footnotes.refs[`:${a}`])return!1;if(!o){let o;n.env.footnotes.list||(n.env.footnotes.list=[]),n.env.footnotes.refs[`:${a}`]<0?(o=n.env.footnotes.list.length,n.env.footnotes.list[o]={label:a,count:0},n.env.footnotes.refs[`:${a}`]=o):o=n.env.footnotes.refs[`:${a}`];const e=n.env.footnotes.list[o].count;n.env.footnotes.list[o].count++;n.push("footnote_ref","",0).meta={id:o,subId:e,label:a}}return n.pos=r,n.posMax=e,!0}),n.core.ruler.after("inline","footnote_tail",function(n){let o,e,t,r=!1;const a={};if(!n.env.footnotes)return;if(n.tokens=n.tokens.filter(function(n){return"footnote_reference_open"===n.type?(r=!0,e=[],t=n.meta.label,!1):"footnote_reference_close"===n.type?(r=!1,a[":"+t]=e,!1):(r&&e.push(n),!r)}),!n.env.footnotes.list)return;const l=n.env.footnotes.list;n.tokens.push(new n.Token("footnote_block_open","",1));for(let e=0,t=l.length;e<t;e++){const t=new n.Token("footnote_open","",1);if(t.meta={id:e,label:l[e].label},n.tokens.push(t),l[e].tokens){o=[];const t=new n.Token("paragraph_open","p",1);t.block=!0,o.push(t);const r=new n.Token("inline","",0);r.children=l[e].tokens,r.content=l[e].content,o.push(r);const a=new n.Token("paragraph_close","p",-1);a.block=!0,o.push(a)}else l[e].label&&(o=a[`:${l[e].label}`]);let r;o&&(n.tokens=n.tokens.concat(o)),r="paragraph_close"===n.tokens[n.tokens.length-1].type?n.tokens.pop():null;const i=l[e].count>0?l[e].count:1;for(let o=0;o<i;o++){const t=new n.Token("footnote_anchor","",0);t.meta={id:e,subId:o,label:l[e].label},n.tokens.push(t)}r&&n.tokens.push(r),n.tokens.push(new n.Token("footnote_close","",-1))}n.tokens.push(new n.Token("footnote_block_close","",-1))})}e.d(o,{A:()=>m})},18569(n,o,e){"use strict";e.d(o,{A:()=>a});const t=/\\([ \\!"#$%&'()*+,./:;<=>?@[\]^_`{|}~-])/g;function r(n,o){const e=n.posMax,r=n.pos;if(126!==n.src.charCodeAt(r))return!1;if(o)return!1;if(r+2>=e)return!1;n.pos=r+1;let a=!1;for(;n.pos<e;){if(126===n.src.charCodeAt(n.pos)){a=!0;break}n.md.inline.skipToken(n)}if(!a||r+1===n.pos)return n.pos=r,!1;const l=n.src.slice(r+1,n.pos);if(l.match(/(^|[^\\])(\\\\)*\s/))return n.pos=r,!1;n.posMax=n.pos,n.pos=r+1;n.push("sub_open","sub",1).markup="~";n.push("text","",0).content=l.replace(t,"$1");return n.push("sub_close","sub",-1).markup="~",n.pos=n.posMax+1,n.posMax=e,!0}function a(n){n.inline.ruler.after("emphasis","sub",r)}},77979(n,o,e){"use strict";e.d(o,{A:()=>a});const t=/\\([ \\!"#$%&'()*+,./:;<=>?@[\]^_`{|}~-])/g;function r(n,o){const e=n.posMax,r=n.pos;if(94!==n.src.charCodeAt(r))return!1;if(o)return!1;if(r+2>=e)return!1;n.pos=r+1;let a=!1;for(;n.pos<e;){if(94===n.src.charCodeAt(n.pos)){a=!0;break}n.md.inline.skipToken(n)}if(!a||r+1===n.pos)return n.pos=r,!1;const l=n.src.slice(r+1,n.pos);if(l.match(/(^|[^\\])(\\\\)*\s/))return n.pos=r,!1;n.posMax=n.pos,n.pos=r+1;n.push("sup_open","sup",1).markup="^";n.push("text","",0).content=l.replace(t,"$1");return n.push("sup_close","sup",-1).markup="^",n.pos=n.posMax+1,n.posMax=e,!0}function a(n){n.inline.ruler.after("emphasis","sup",r)}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[2674],{92674(e,t,n){n.r(t),n.d(t,{default:()=>P});var a=n(96540),i=n(82893),s=n(34843),o=n(85997),l=n(57952),r=n(47022),c=n(34251),d=n(74848);function u(e){{const[t,n]=(0,a.useState)(!1),[i,s]=(0,a.useState)([]),l=e=>{s(e)},p=async()=>{"folder"===e.type?(t||!e.click||i||await e.click(e,l,e.pre_path),n(!t)):e.click&&await e.click(e,l,e.pre_path)},h=async(t=!1)=>{"folder"!==e.type||t?e.fatherNowToggleExpansion&&e.fatherNowToggleExpansion():await e.click(e,l,e.pre_path)};return(0,a.useEffect)(()=>{s(e.children)},[e.children]),(0,d.jsxs)("div",{className:"studio-item",children:[(0,d.jsxs)("div",{onClick:p,onContextMenu:t=>{t.stopPropagation(),t.nativeEvent.stopImmediatePropagation(),e.handleContextMenu&&e.handleContextMenu(t,e.name,e.pre_path,e.type===r.Iw.folder,h)},className:"studio-item-title"+(e.active_path===e.pre_path?" studio-item-title--active":""),children:[(0,d.jsx)("i",{className:"material-icons studio-item-title-tag","data-icon":t?"arrow_drop_down":"arrow_right",children:"file"==e.type?"":t?"arrow_drop_down":"arrow_right"}),(0,d.jsx)("span",{className:"file-icons",children:(0,d.jsx)("span",{"data-type":(0,c.uL)(e.name),"data-dir":"folder"===e.type,"aria-label":e.name,children:(0,d.jsx)(o.In,{icon:"",aria_label:e.name})})}),(0,d.jsx)("span",{className:"studio-item-name",children:e.name})]}),t&&i&&(0,d.jsx)("div",{style:{marginLeft:20},children:i.map((t,n)=>(0,d.jsx)(a.Fragment,{children:(0,d.jsx)(u,{type:t.type,size:t.size,click:e.click,name:t.name,children:t.children,pre_path:`${e.pre_path}${t.name}${t.type===r.Iw.folder?"/":""}`,handleContextMenu:e.handleContextMenu,active_path:e.active_path,fatherNowToggleExpansion:h},n)},n))})]})}}n(61443);function p(e){return(0,d.jsx)("div",{children:e.list.map((t,n)=>(0,d.jsx)(u,{pre_path:`${e.pre_path}${t.name}${t.type===r.Iw.folder?"/":""}`,name:t.name,type:t.type,handleContextMenu:e.handleContextMenu,fatherNowToggleExpansion:e.fatherNowToggleExpansion,active_path:e.active_path,children:t.children,click:e.click,size:t.size},n))})}var h=n(14284),m=n(34289),f=n(53459),v=n(78247),_=n(62042),x=n(2543),y=n(89824),w=n(22022),j=n(88815),g=n(52671),k=n(23430),C=n(99214);const S=a.lazy(()=>Promise.all([n.e(2543),n.e(4091)]).then(n.bind(n,84091))),b=a.lazy(()=>Promise.all([n.e(4946),n.e(1384),n.e(892),n.e(9334),n.e(1075),n.e(1142)]).then(n.bind(n,71142))),N=a.lazy(()=>n.e(4877).then(n.bind(n,64877))),E=a.lazy(()=>Promise.all([n.e(4946),n.e(2626),n.e(892),n.e(9334),n.e(6104)]).then(n.bind(n,69857))),A=a.lazy(()=>Promise.all([n.e(3140),n.e(5744)]).then(n.bind(n,16575))),M=a.lazy(()=>Promise.all([n.e(8725),n.e(2728),n.e(2130),n.e(5602),n.e(8781),n.e(6404)]).then(n.bind(n,35304))),I=a.lazy(()=>n.e(892).then(n.bind(n,20892))),$=a.lazy(()=>Promise.all([n.e(1922),n.e(4935)]).then(n.bind(n,24935)));function R(e){return(0,c.uL)(e)===r.Iw.excel}function P(e){const[t,n]=(0,a.useState)([]),[u,P]=(0,a.useState)(""),[z,G]=(0,a.useState)(""),[U,D]=(0,a.useState)(!1),[F,L]=(0,a.useState)({path:"",name:""}),[T,B]=(0,a.useState)(""),[K,W]=(0,s.fp)(i.AG.confirm),[H,X]=(0,a.useState)(!1),[V,Y]=(0,s.fp)(i.AG.fileShellShow),[Z,q]=(0,s.fp)(i.AG.file_shell_hidden),J=(0,a.useRef)(null),O=(0,a.useRef)(null),[Q,ee]=(0,a.useState)(!1),[te,ne]=(0,a.useState)(16),[ae,ie]=(0,s.fp)(i.AG.showPrompt),{t:se}=(0,w.Bd)(),oe=(0,g.Zp)(),le=(re=F.name,(0,c.uL)(re)===r.Iw.md);var re;const ce=function(e){return(0,c.uL)(e)===r.Iw.excalidraw}(F.name),de=function(e){return(0,c.uL)(e)===r.Iw.mind}(F.name),ue=function(e){return(0,c.uL)(e)===r.Iw.timeline}(F.name),pe=R(F.name),he=(0,a.useRef)(null),me=(0,a.useRef)(null),fe=(0,a.useRef)(null),ve=(0,a.useRef)(null),_e=(0,a.useRef)(null),xe=(0,a.useRef)(null),[ye,we]=(0,a.useState)([]),[je,ge]=(0,a.useState)(-1),[ke,Ce]=(0,a.useState)("folder"),[Se,be]=(0,a.useState)(!0),[Ne,Ee]=(0,a.useState)(!1),Ae=(0,C.oT)(),[Me]=(0,g.ok)(),Ie="1"===Me.get("chat_open"),[$e,Re]=(0,s.fp)(i.AG.studio_chat_width),Pe=(0,a.useRef)(null),[ze,Ge]=(0,a.useState)(!1),[Ue,De]=(0,a.useState)(void 0),[Fe,Le]=(0,s.fp)(i.AG.ai_chat_session_by_cwd),Te=(0,g.zy)();let Be=Te.pathname.split("/").filter(Boolean).pop();Be=decodeURIComponent(Be);const{check_user_auth:Ke}=(0,v.MH)(),[We]=(0,s.fp)(i.AG.user_base_info),He=Ke(k.oV.ai_agent_page);(0,a.useEffect)(()=>{We?.user_data&&Ie&&!He&&Ae("chat_open",null)},[Ie,He,We]);const Xe=(0,m.GG)("file",Be);const Ve=async()=>{const e=(0,m.GG)("file",Be);P(e),L({path:e,name:(0,m.mH)(e)});const t=await h.$M.post("studio/get/item",{path:e});if(t.code===f.m.Success){const e=[],a=[];for(const n of t.data.list)"folder"===n.type?e.push(n):"file"===n.type&&a.push(n);n([...e,...a])}},Ye=(e,t)=>e===t||e.startsWith(t+"/");(0,a.useEffect)(()=>{G(""),X(!1),Ve()},[Te]);const Ze=async(e,t)=>{if(!R(e)){const e=await h.$M.get(`${encodeURIComponent(t)}`);G(e.data),v.xK.set_value_temp(e.data)}L({path:t,name:e}),B(t),Ce("folder"),Ee(!1)},qe=(e,t)=>{e.size>j.o5?W({open:!0,handle:()=>{Ze(e.name,t),W({open:!1,handle:null}),X(!1)},title:"超过20MB了还要打开吗?"}):Ze(e.name,t)};function Je(){me.current?.save()}const Oe=e=>{if(e.ctrlKey&&"s"===e.key){if(e.preventDefault(),le||ce||de||ue||pe)return;H&&Je()}};(0,a.useEffect)(()=>(document.addEventListener("keydown",Oe),()=>{document.removeEventListener("keydown",Oe)}),[H,le,ce,de,ue,pe]);const Qe=(0,a.useCallback)(x.throttle(e=>{const t=parseFloat(getComputedStyle(O.current).fontSize),n=window.innerWidth/t-4,a=e.clientX/t,i=2.25+J.current.offsetWidth/t;a<=n&&a>=i&&ne(parseFloat(a.toFixed(2)))},32),[]),et=()=>{ee(!1),O.current.removeEventListener("pointermove",Qe)},tt=(0,a.useCallback)(x.throttle(e=>{const t=Pe.current;if(!t)return;const n=parseFloat(getComputedStyle(t).fontSize),a=t.parentElement.getBoundingClientRect().right-e.clientX,i=.7*t.parentElement.getBoundingClientRect().width,s=Math.min(Math.max(a,320),i);Re(parseFloat((s/n).toFixed(2)))},32),[]),nt=()=>{Ge(!1),document.removeEventListener("pointermove",tt)},at=[{r:se("创建文件"),v:"创建文件"},{r:se("创建目录"),v:"创建目录"},{r:se("重命名"),v:"重命名"},{r:se("删除"),v:"删除"}],it=[{r:se("重命名"),v:"重命名"},{r:se("删除"),v:"删除"}],st=(e,t,n,a,i)=>{e.preventDefault();const s=new c.ik;s.path=n,s.filename=t,s.x=e.clientX,s.y=e.clientY,s.items=a?at:it,i===Ve&&(s.items=s.items.slice(0,2)),s.type=a?r.Iw.studio_folder:r.Iw.studio_file;const o=e=>{i(e)};s.textClick=e=>{switch(e){case"创建文件":ie({show:!0,type:y.PromptEnum.FileNew,overlay:!0,data:{dir:n,call:o}});break;case"创建目录":ie({show:!0,type:y.PromptEnum.DirNew,overlay:!0,data:{dir:n,call:o}});break;case"删除":if(H&&(F.path===n||F.path.includes(n))){const e=()=>{o(a),X(!1),L({}),G(""),v.xK.set_value_temp("")};ie({show:!0,type:y.PromptEnum.FilesDelete,overlay:!0,data:{path:n,call:e,filename:t}});break}ie({show:!0,type:y.PromptEnum.FilesDelete,overlay:!0,data:{path:n,filename:t,call:a?()=>{o(!0)}:o}});break;case"重命名":ie({show:!0,type:y.PromptEnum.FileRename,overlay:!0,data:{path:n,dir:(0,m.Yp)(n),call:(e,t)=>{((e,t)=>{if(T&&Ye(T,e)){const n=t+T.slice(e.length);B(n),L({path:n,name:(0,m.mH)(n)})}const n=(0,m.oW)((0,m.GG)("file",Be));if(Ye(n,e)){const a=t+n.slice(e.length);return void oe(`/file/${encodeURIComponent(a)}`,{replace:!0})}Ve()})(e,t)},filename:t}})}},ie({show:!0,type:y.PromptEnum.FileMenu,overlay:!1,data:s})};const ot=le&&"outline"===ke;return(0,d.jsxs)("div",{className:"studio studio--file",children:[(0,d.jsxs)(l.A,{ignore_tags:!0,left_children:[(0,d.jsx)(o.rA,{title:"取消",icon:"close",onClick:()=>{Y({show:!1,path:""}),q(void 0),oe(-1)}},1),(0,d.jsx)("div",{children:F.name},2)],children:[(0,d.jsx)("title",{children:F.name}),(0,d.jsx)(o.rA,{title:"侧边栏",icon:"list",onClick:()=>be(e=>!e),selected:Se}),le&&[Ne?(0,d.jsx)(o.rA,{title:se("保存"),icon:"save",onClick:()=>he.current?.save()},"save"):null,(0,d.jsx)(o.rA,{icon:"source"===he.current?.mode()?"edit":"code",title:"source"===he.current?.mode()?se("实时编辑模式"):se("源码模式"),onClick:()=>he.current?.toggle_mode()},"mode"),(0,d.jsx)(o.rA,{title:se("导出PDF"),icon:"print",onClick:()=>he.current?.export_pdf()},"pdf")],!le&&(0,c.zr)(F.name)&&(0,d.jsx)(o.rA,{title:"格式化",icon:"data_object",onClick:function(){v.xK.get_editor()?.formatCode()}}),(0,d.jsx)(o.rA,{icon:"terminal",title:"shell",onClick:function(){!0!==Z&&!1!==Z?V.show?Y({show:!1,path:""}):(Y({show:!0,path:(0,m.GG)("file",Be)}),q(!1)):q(!Z)}}),Ke(k.oV.ai_agent_page)&&(0,d.jsx)(o.rA,{title:se("AI 聊天"),icon:"smart_toy",selected:Ie,onClick:()=>Ae("chat_open",!Ie?"1":null)}),le?Ne?(0,d.jsx)(o.rA,{title:se("保存"),icon:"save",onClick:()=>he.current?.save()}):null:ce?(0,d.jsx)(o.rA,{title:se("保存"),icon:"save",onClick:()=>fe.current?.save()}):de?(0,d.jsx)(o.rA,{title:se("保存"),icon:"save",onClick:()=>ve.current?.save()}):ue?(0,d.jsx)(o.rA,{title:se("保存"),icon:"save",onClick:()=>_e.current?.save()}):pe?(0,d.jsx)(o.rA,{title:se("保存"),icon:"save",onClick:()=>xe.current?.save()}):H?(0,d.jsx)(o.rA,{title:"保存",icon:"save",onClick:Je}):null]}),(0,d.jsxs)("div",{className:"studio-body",ref:O,children:[(0,d.jsxs)("div",{className:"studio-nav",style:{display:Se?void 0:"none",width:te-1+"em"},onContextMenu:e=>{st(e,F.name,(0,m.GG)("file",Be),!0,Ve)},children:[(0,d.jsx)("div",{className:"studio-nav-outline",style:{display:ot?void 0:"none"},children:(0,d.jsx)(N,{items:ye,active_pos:je,on_click:e=>he.current?.goto_heading(e)})}),(0,d.jsx)("div",{className:"studio-nav-folder",style:{display:ot?"none":void 0},children:(0,d.jsx)(p,{pre_path:u,list:t,click:async(e,t,n)=>{if("folder"===e.type){const e=await h.$M.post("studio/get/item",{path:`${n}`});if(e.code===f.m.Success){const n=[],a=[];for(const t of e.data.list)"folder"===t.type?n.push(t):"file"===t.type&&a.push(t);t([...n,...a])}}else{if(H)return void W({open:!0,handle:()=>{W({open:!1,handle:null}),X(!1),qe(e,n)},title:"确定不保存就切换吗?"});qe(e,n)}},active_path:T,handleContextMenu:st,fatherNowToggleExpansion:Ve})}),le&&(0,d.jsx)("div",{className:"studio-nav-switch",children:(0,d.jsx)(o.rA,{icon:ot?"folder":"list",title:se(ot?"文件目录":"大纲"),onClick:()=>Ce(ot?"folder":"outline")})})]}),Se&&(0,d.jsx)("div",{className:"studio__divider",ref:J,onPointerDown:()=>{ee(!0),O.current.addEventListener("pointermove",Qe)},onPointerUp:et}),Q&&(0,d.jsx)("div",{className:"shell__overlay",onPointerUp:et}),le?(0,d.jsx)("div",{className:"studio-editor studio-editor--md",children:(0,d.jsx)(a.Suspense,{fallback:null,children:(0,d.jsx)(b,{pane:{path:T,url:h.$M.getDownloadUrl(encodeURIComponent(T)),name:F.name,on_dirty:Ee,on_outline:(e,t)=>{we(e),ge(t)},register:e=>{he.current=e}}})})},T):ce?(0,d.jsx)("div",{className:"studio-editor studio-editor--draw",children:(0,d.jsx)(a.Suspense,{fallback:null,children:(0,d.jsx)(A,{reset_key:T,url:h.$M.getDownloadUrl(encodeURIComponent(T)),save_path:T,on_dirty:X,on_saved:()=>X(!1),register:e=>{fe.current=e}})})},T):de?(0,d.jsx)("div",{className:"studio-editor studio-editor--mind",children:(0,d.jsx)(a.Suspense,{fallback:null,children:(0,d.jsx)(M,{reset_key:T,url:h.$M.getDownloadUrl(encodeURIComponent(T)),on_dirty:X,on_saved:()=>X(!1),register:e=>{ve.current=e},on_save:async e=>(await h.$M.post(`save/${encodeURIComponent(T)}`,{context:e})).code===f.m.Success})})},T):ue?(0,d.jsx)("div",{className:"studio-editor studio-editor--timeline",children:(0,d.jsx)(a.Suspense,{fallback:null,children:(0,d.jsx)(I,{reset_key:T,url:h.$M.getDownloadUrl(encodeURIComponent(T)),on_dirty:X,register:e=>{_e.current=e},on_save:async e=>(await h.$M.post(`save/${encodeURIComponent(T)}`,{context:e})).code===f.m.Success})})},T):pe?(0,d.jsx)("div",{className:"studio-editor studio-editor--excel",children:(0,d.jsx)(a.Suspense,{fallback:null,children:(0,d.jsx)($,{url:h.$M.getDownloadUrl(encodeURIComponent(T)),save_path:T,on_dirty:X,bind_save:e=>{xe.current={save:e}}})})},T):(0,d.jsx)("div",{className:"studio-editor",children:F.name&&(0,d.jsx)(a.Suspense,{fallback:null,children:(0,d.jsx)(S,{name:F.name,on_dirty:X,register:e=>{me.current=e},save:async e=>{const t={context:v.xK.get_editor_value()},n=await h.$M.post(`save/${encodeURIComponent(T)}`,t);return n.code===f.m.Success||e||(0,_.zN)(se("保存失败")),n.code===f.m.Success}})})},T),Ie&&(0,d.jsxs)(a.Fragment,{children:[(0,d.jsx)("div",{className:"studio__divider studio__divider--chat",ref:Pe,onPointerDown:e=>{e.preventDefault(),Ge(!0),document.addEventListener("pointermove",tt),document.addEventListener("pointerup",nt,{once:!0})}}),(0,d.jsx)("div",{className:"studio-chat-panel",style:{width:`${$e}em`},children:(0,d.jsx)(a.Suspense,{fallback:null,children:(0,d.jsx)(E,{inline_header:!0,sync_url:!1,file_cwd_path:Xe,session_id:Ue??(lt=Xe,i.AG.get_ai_chat_session(Fe,lt)),on_session_change:e=>{De(e),((e,t)=>{Le({...Fe,[e]:t})})(Xe,e)}})})})]})]})]});var lt}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[3528],{48890(e,t,s){s.d(t,{Kw:()=>a,Tt:()=>i});var a=s(80952),i=(s(82327),s(1766),s(24854),s(90008),s(90846),s(40975),s(44286),s(30766),s(14973),s(69687),s(1234),s(47507),s(87268),s(34678),s(24522));const n=`https://gcore.jsdelivr.net/npm/ace-builds@${a.version}/src-min-noconflict/`;a.config.set("basePath",n),a.config.set("modePath",n),a.config.set("themePath",n),a.config.set("workerPath",n)},53528(e,t,s){s.r(t),s.d(t,{default:()=>q});var a=s(96540),i=s(14284),n=s(62042),c=s(22022),l=s(85997),o=s(61443),r=s(57952),d=s(52671),h=s(34289),m=s(87361),_=s(2543),g=s(34251),p=s(47022),u=s(74848);const f={M:{label:"M",cls:"mod"},A:{label:"A",cls:"add"},D:{label:"D",cls:"del"},R:{label:"R",cls:"ren"},C:{label:"C",cls:"ren"},U:{label:"U",cls:"conf"},"?":{label:"?",cls:"untracked"}};function x(e){const t=e.lastIndexOf("/");return-1===t?e:e.substring(t+1)}function j(e){const t={type:"folder",name:"",full_path:"",children:[]};for(const s of e){const e=s.path.split("/").filter(Boolean);let a=t;for(let t=0;t<e.length;t++){const i=e[t],n=t===e.length-1;let c=a.children.find(e=>e.name===i);c||(c={type:n?"file":"folder",name:i,full_path:a.full_path?`${a.full_path}/${i}`:i,children:[]},a.children.push(c)),n&&(c.data=s.data),a=c}}const s=e=>{e.sort((e,t)=>e.type!==t.type?"folder"===e.type?-1:1:e.name.localeCompare(t.name));for(const t of e)t.children.length&&s(t.children)};return s(t.children),t.children}function N(e){const{t}=(0,c.Bd)(),{file:s,staged:a,status:i,selected:n,active:o,leaf:r}=e,d=f[i]??{label:i,cls:"mod"},h=r?s.path.substring(0,s.path.lastIndexOf("/")):"";return(0,u.jsxs)("div",{className:"git-file"+(o?" git-file--active":""),children:[(0,u.jsx)("input",{type:"checkbox",checked:n.has(s.path),onChange:()=>e.on_toggle(s.path),onClick:e=>e.stopPropagation()}),(0,u.jsx)("span",{className:"file-icons",children:(0,u.jsx)("span",{"data-type":(0,g.uL)(s.path),"data-dir":!1,"aria-label":s.path,children:(0,u.jsx)(l.In,{icon:"",aria_label:s.path})})}),(0,u.jsx)("span",{className:"git-file__name",title:s.oldPath?`${s.oldPath} → ${s.path}`:s.path,onClick:()=>e.on_view_diff(s,a),children:r?x(s.path):s.path}),(0,u.jsx)("span",{className:`git-file__badge git-file__badge--${d.cls}`,children:d.label}),h&&(0,u.jsx)("span",{className:"git-file__dir",title:h,children:h}),(0,u.jsxs)("span",{className:"git-file__ops",children:[(0,u.jsx)(l.rA,{icon:"format_list_numbered",title:t("逐行归属"),onClick:()=>e.on_view_blame(s)}),(0,u.jsx)(l.rA,{icon:a?"remove":"add",title:t(a?"取消暂存":"暂存"),onClick:()=>e.on_stage_one(s,a)})]})]})}function v(e){const{node:t,staged:s,file_map:i,prefix:n}=e,[c,o]=(0,a.useState)(!0),r=n?`${n}/${t.name}`:t.name;if("file"===t.type){const t=i.get(r);if(!t)return null;const a=s?t.conflicted?"U":t.index:t.untracked?"?":t.conflicted?"U":t.worktree;return(0,u.jsx)(N,{file:t,staged:s,status:a,selected:e.selected,active:e.active_path===t.path,leaf:!0,on_toggle:e.on_toggle,on_view_diff:e.on_view_diff,on_stage_one:e.on_stage_one,on_view_blame:e.on_view_blame})}return(0,u.jsxs)("div",{className:"git-tree__folder",children:[(0,u.jsxs)("div",{className:"git-tree__dir",onClick:()=>o(!c),children:[(0,u.jsx)("i",{className:"material-icons git-tree__arrow","data-icon":c?"arrow_drop_down":"arrow_right",children:c?"arrow_drop_down":"arrow_right"}),(0,u.jsx)("span",{className:"file-icons",children:(0,u.jsx)("span",{"data-type":p.Iw.folder,"data-dir":!0,"aria-label":t.name,children:(0,u.jsx)(l.In,{icon:"",aria_label:t.name})})}),(0,u.jsx)("span",{className:"git-tree__dir-name",children:t.name})]}),c&&(0,u.jsx)("div",{className:"git-tree__children",children:t.children?.map((t,a)=>(0,u.jsx)(v,{node:t,staged:s,file_map:i,prefix:r,selected:e.selected,active_path:e.active_path,on_toggle:e.on_toggle,on_view_diff:e.on_view_diff,on_stage_one:e.on_stage_one,on_view_blame:e.on_view_blame},a))})]})}function y(e){const{t}=(0,c.Bd)(),{title:s,files:i,staged:n,selected:l}=e,o=(0,a.useMemo)(()=>i.map(e=>e.path),[i]),r=o.filter(e=>l.has(e)).length,d=i.length>0&&r===i.length,h=r>0&&!d,m=(0,a.useMemo)(()=>{const e=new Map;for(const t of i)e.set(t.path,t);return e},[i]),_=(0,a.useMemo)(()=>e.tree_mode?function(e){const t=j(e.map(e=>({path:e.path,data:e}))),s=e=>({type:e.type,name:e.name,size:0,children:e.children.length?e.children.map(s):void 0});return t.map(s)}(i):[],[i,e.tree_mode]);return 0===i.length?null:(0,u.jsxs)("div",{className:"git-section",children:[(0,u.jsxs)("div",{className:"git-section__header",children:[(0,u.jsx)("input",{type:"checkbox",checked:d,ref:e=>{e&&(e.indeterminate=h)},onChange:()=>e.on_toggle_all(o,!d)}),(0,u.jsxs)("span",{className:"git-section__title",children:[s," (",i.length,")"]}),(0,u.jsx)("span",{className:"git-section__action",onClick:()=>e.on_stage_section(i,n),children:t(n?"全部取消暂存":"全部暂存")})]}),e.tree_mode?(0,u.jsx)("div",{className:"git-tree",children:_.map((t,s)=>(0,u.jsx)(v,{node:t,staged:n,file_map:m,prefix:"",selected:e.selected,active_path:e.active_path,on_toggle:e.on_toggle,on_view_diff:e.on_view_diff,on_stage_one:e.on_stage_one,on_view_blame:e.on_view_blame},s))}):i.map(t=>(0,u.jsx)(N,{file:t,staged:n,status:e.status_of(t),selected:e.selected,active:e.active_path===t.path,leaf:!0,on_toggle:e.on_toggle,on_view_diff:e.on_view_diff,on_stage_one:e.on_stage_one,on_view_blame:e.on_view_blame},t.path+(n?"_s":"_w")))]})}function b(e){const{t}=(0,c.Bd)(),{files:s}=e,[i,n]=(0,a.useState)(!1),o=s.filter(e=>e.staged),r=s.filter(e=>e.untracked||" "!==e.worktree),d={selected:e.selected,on_toggle:e.on_toggle,on_toggle_all:e.on_toggle_all,active_path:e.active_path,tree_mode:i,on_view_diff:e.on_view_diff,on_stage_section:e.on_stage_section,on_stage_one:e.on_stage_one,on_view_blame:e.on_view_blame};return(0,u.jsxs)("div",{className:"git-change-list",children:[(0,u.jsx)("div",{className:"git-change-toolbar",children:(0,u.jsx)(l.rA,{icon:"account_tree",title:t("树形展示"),selected:i,onClick:()=>n(!i)})}),(0,u.jsx)(y,{title:t("已暂存的更改"),files:o,staged:!0,status_of:e=>e.conflicted?"U":e.index,...d}),(0,u.jsx)(y,{title:t("更改"),files:r,staged:!1,status_of:e=>e.untracked?"?":e.conflicted?"U":e.worktree,...d}),0===s.length&&(0,u.jsx)("div",{className:"git-change-empty",children:t("没有已更改的文件")})]})}var w=s(48890);function k({valueA:e,valueB:t,mode:s="split",theme:i,filename:n}){const c=(0,a.useRef)(null),l=(0,a.useRef)(null),o=(0,a.useMemo)(()=>n&&w.Tt.getModeForPath(n).mode||"ace/mode/text",[n]);return(0,a.useEffect)(()=>{const a=c.current;if(!a)return;const n=w.Kw.require("ace/ext/diff"),r={valueA:e??"",valueB:t??"",diffProvider:new n.DiffProvider},d="inline"===s,h=d?new n.InlineDiffView({...r,inline:"a"},a):new n.SplitDiffView(r);d||(h.container=a,a.appendChild(h.editorA.container),a.appendChild(h.editorB.container)),i&&h.setTheme(i),h.editorA?.session.setMode(o),h.editorB?.session.setMode(o),h.onInput(),h.foldUnchanged();const m=requestAnimationFrame(()=>{h.editorA?.resize(!0),h.editorB?.resize(!0)});return l.current=h,()=>{cancelAnimationFrame(m);try{h.destroy()}catch(e){}l.current=null,a.innerHTML=""}},[e,t,s,i,o]),(0,u.jsx)("div",{className:"ace-diff",ref:c})}const S={text:"",binary:!1,exists:!1};function C({dir_path:e,file:t,left_ref:s,right_ref:n,mode:l="unified"}){const{t:o}=(0,c.Bd)(),[r,d]=(0,a.useState)(S),[h,m]=(0,a.useState)(S),[_,g]=(0,a.useState)(!1),[p,f]=(0,a.useState)(""),x=(0,a.useRef)(0);return(0,a.useEffect)(()=>{const a=++x.current;g(!0),f("");const c=s=>i.TU.post("file_content",{path:e,file:t,ref:s});Promise.all([c(s),c(n)]).then(([e,t])=>{a===x.current&&(d(0===e.code?e.data:S),m(0===t.code?t.data:S))}).catch(e=>{a===x.current&&(f("string"==typeof e?e:e?.message||""),d(S),m(S))}).finally(()=>{a===x.current&&g(!1)})},[e,t,s,n]),_?(0,u.jsx)("div",{className:"git-diff-empty",children:(0,u.jsx)("span",{children:o("加载中")})}):p?(0,u.jsx)("div",{className:"git-diff-empty",children:(0,u.jsx)("span",{children:p})}):r.binary||h.binary?(0,u.jsx)("div",{className:"git-diff-empty",children:(0,u.jsx)("span",{children:o("二进制文件无法比较")})}):r.text===h.text?(0,u.jsx)("div",{className:"git-diff-empty",children:(0,u.jsx)("span",{children:o("无差异")})}):(0,u.jsx)(k,{valueA:r.text??"",valueB:h.text??"",mode:"split"===l?"split":"inline",filename:t})}function z({dir_path:e,entries:t,is_search:s,has_more:o,loading_more:r,active_hash:d,on_select:h,on_scroll_bottom:m,on_search_result:_}){const{t:g}=(0,c.Bd)(),[p,f]=(0,a.useState)(!1),[x,j]=(0,a.useState)(""),[N,v]=(0,a.useState)(""),[y,b]=(0,a.useState)(!1),{rows:w,width:k}=function(e){const t=[],s=[];let a=1;for(const i of e){let e=t.indexOf(i.hash);e<0&&(e=t.indexOf(null),e<0&&(e=t.length,t.push(null)));const n=i.parents||[],c=[];for(const s of n)s&&t.forEach((a,i)=>{i!==e&&a===s&&(c.push(i),t[i]=null)});const l=[];t.forEach((t,s)=>{null===t||s===e||c.includes(s)||l.push(s)}),t[e]=n[0]??null;const o=[e];for(const e of n.slice(1)){let s=t.indexOf(e);s<0&&(s=t.indexOf(null),s<0&&(s=t.length,t.push(null)),t[s]=e),o.push(s)}for(;t.length&&null===t[t.length-1];)t.pop();s.push({column:e,pass_through:l,out_edges:o,merge_in:c}),a=Math.max(a,t.length,e+1,...o.map(e=>e+1))}return{rows:s,width:a}}(s?[]:t),S=async()=>{if(x.trim()||N.trim()){b(!0);try{const t=await i.TU.post("search_commit",{path:e,keyword:x.trim(),author:N.trim(),maxCount:100});0===t.code?_(t.data||[]):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}finally{b(!1)}}else(0,n.zN)(g("请输入搜索条件"))},C=(e,t,s)=>{const a=39,i=12,n=s?i:-2,c=e=>16*e+8,l=c(e.column),o=[];for(const t of e.pass_through)o.push((0,u.jsx)("line",{x1:c(t),y1:n,x2:c(t),y2:41,className:"git-log__graph-edge"},`p${t}`));for(const[t,a]of e.merge_in.entries()){const e=c(a);s||o.push((0,u.jsx)("path",{fill:"none",d:`M ${e} -2 C ${e} 19.5 ${l} 19.5 ${l} 12`,className:"git-log__graph-edge"},`m${t}`))}for(const[t,s]of e.out_edges.entries())if(s===e.column)o.push((0,u.jsx)("line",{x1:l,y1:n,x2:l,y2:41,className:"git-log__graph-edge"},`o${t}`));else{const e=c(s);o.push((0,u.jsx)("path",{fill:"none",d:`M ${l} 12 C ${l} 25.5 ${e} 25.5 ${e} 39`,className:"git-log__graph-edge"},`o${t}`))}return(0,u.jsx)("div",{className:"git-log__graph",children:(0,u.jsxs)("svg",{width:16*k,height:a,overflow:"visible",children:[o,(0,u.jsx)("circle",{cx:l,cy:i,r:3.5,className:"git-log__graph-dot"+(t?" git-log__graph-dot--unpushed":"")})]})})};return(0,u.jsxs)("div",{className:"git-log-wrap",children:[(0,u.jsxs)("div",{className:"git-log-search",children:[(0,u.jsx)(l.rA,{icon:"search",title:g("搜索提交"),onClick:()=>{p?(j(""),v(""),_(null),f(!1)):f(!0)}}),p&&(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)("input",{className:"input input--block",autoFocus:!0,value:x,placeholder:g("提交信息关键词"),onChange:e=>j(e.target.value),onKeyDown:e=>"Enter"===e.key&&S()}),(0,u.jsx)("input",{className:"input input--block",value:N,placeholder:g("作者"),onChange:e=>v(e.target.value),onKeyDown:e=>"Enter"===e.key&&S()}),(0,u.jsx)(l.rA,{icon:"check",title:g("搜索"),onClick:S})]})]}),(0,u.jsxs)("div",{className:"git-log",onScroll:m,children:[y&&(0,u.jsx)("div",{className:"git-change-empty",children:g("加载中")}),!y&&0===t.length&&(0,u.jsx)("div",{className:"git-change-empty",children:g("暂无提交记录")}),!y&&t.map((e,t)=>(0,u.jsxs)("div",{className:`git-log__entry${d===e.hash?" git-log__entry--active":""}${e.unpushed?" git-log__entry--unpushed":""}`,onClick:()=>h(e.hash),children:[!s&&C(w[t],!!e.unpushed,0===t),(0,u.jsxs)("div",{className:"git-log__main",children:[(0,u.jsxs)("div",{className:"git-log__row",children:[e.unpushed&&(0,u.jsx)("span",{className:"git-log__unpushed",title:g("未推送")}),(0,u.jsx)("span",{className:"git-log__hash",children:e.hash}),(e.refs||[]).map(e=>(0,u.jsx)("span",{className:"git-log__ref"+(e.includes("HEAD")?" git-log__ref--head":""),children:e.replace("HEAD -> ","")},e)),(0,u.jsx)("span",{className:"git-log__msg",title:e.message,children:e.message})]}),(0,u.jsxs)("div",{className:"git-log__meta",children:[e.author," · ",e.date]})]})]},e.hash)),!y&&!s&&r&&(0,u.jsx)("div",{className:"git-log__more",children:g("加载中")}),!y&&!s&&!r&&!o&&t.length>0&&(0,u.jsx)("div",{className:"git-log__more",children:g("已到底部")})]})]})}var A=s(45907);function $({nodes:e,selected:t,on_select:s}){const[i,n]=(0,a.useState)(new Set),c=e=>e.map(e=>{if("folder"===e.type){const t=!i.has(e.full_path);return(0,u.jsxs)("div",{children:[(0,u.jsxs)("div",{className:"git-commit-tree__dir",onClick:()=>{return t=e.full_path,void n(e=>{const s=new Set(e);return s.has(t)?s.delete(t):s.add(t),s});var t},children:[(0,u.jsx)("i",{className:"material-icons git-tree__arrow",children:t?"arrow_drop_down":"arrow_right"}),(0,u.jsx)("span",{className:"file-icons",children:(0,u.jsx)("span",{"data-type":p.Iw.folder,"data-dir":!0,"aria-label":e.name,children:(0,u.jsx)(l.In,{icon:"",aria_label:e.name})})}),(0,u.jsx)("span",{className:"git-commit-tree__dir-name",children:e.name})]}),t&&(0,u.jsx)("div",{className:"git-commit-tree__children",children:c(e.children)})]},e.full_path)}const a=e.data;return(0,u.jsxs)("div",{className:"git-commit-file git-commit-file--leaf"+(t===e.full_path?" git-commit-file--active":""),onClick:()=>s(e.full_path),title:e.full_path,children:[(0,u.jsx)("span",{className:"file-icons",children:(0,u.jsx)("span",{"data-type":(0,g.uL)(e.name),"aria-label":e.name,children:(0,u.jsx)(l.In,{icon:"",aria_label:e.name})})}),(0,u.jsx)("span",{className:"git-commit-file__name",children:e.name}),a&&null!==a.additions&&(0,u.jsxs)("span",{className:"git-commit-file__stat",children:[(0,u.jsxs)("span",{className:"git-stat--add",children:["+",a.additions]}),(0,u.jsxs)("span",{className:"git-stat--del",children:["-",a.deletions]})]})]},e.full_path)});return(0,u.jsx)(u.Fragment,{children:c(e)})}function U({dir_path:e,hash:t,on_close:s,on_changed:o}){const{t:r}=(0,c.Bd)(),d=(0,A.y)(),[h,m]=(0,a.useState)(null),[_,g]=(0,a.useState)(null),[p,f]=(0,a.useState)("unified"),[x,N]=(0,a.useState)(!1),[v,y]=(0,a.useState)(!1);(0,a.useEffect)(()=>{t&&(g(null),y(!1),w())},[t,e]);const b=(0,a.useMemo)(()=>j((h?.files??[]).map(e=>({path:e.path,data:e}))),[h]),w=async()=>{try{const s=await i.TU.post("commit_detail",{path:e,hash:t});0===s.code?m(s.data):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}};if(!h)return(0,u.jsx)("div",{className:"git-card git-card--diff",children:(0,u.jsx)("div",{className:"git-change-empty",children:r("加载中")})});return(0,u.jsxs)("div",{className:"git-card git-card--diff",children:[(0,u.jsxs)("div",{className:"git-commit-meta",children:[(0,u.jsxs)("div",{className:"git-commit-meta__row",children:[(0,u.jsx)("span",{className:"git-commit-meta__hash",children:h.short_hash}),(0,u.jsx)("span",{className:"git-commit-meta__subject",title:h.subject,children:h.subject}),_&&(0,u.jsx)(l.rA,{icon:"compare_arrows",title:r("与工作区对比"),onClick:()=>{_?y(!0):(0,n.zN)(r("请先选择文件"))}}),(0,u.jsx)(l.rA,{icon:"undo",title:r("撤销提交"),onClick:()=>{d({title:r("撤销提交"),sub_title:`${r("将生成一个反向提交来撤销")} ${h.short_hash} ?`,confirm_fun:async()=>{try{const s=await i.TU.post("revert",{path:e,hash:t});0===s.code?((0,n.SK)(r("已撤销")),o?.()):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}}})}}),(0,u.jsx)(l.rA,{icon:"content_cut",title:r("摘取提交"),onClick:()=>{d({title:r("摘取提交"),sub_title:`${r("将该提交应用到当前分支")} ${h.short_hash} ?`,confirm_fun:async()=>{try{const s=await i.TU.post("cherry_pick",{path:e,hash:t});0===s.code?((0,n.SK)(r("摘取成功")),o?.()):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}}})}}),(0,u.jsx)(l.rA,{icon:"close",title:r("关闭"),onClick:s})]}),(0,u.jsxs)("div",{className:"git-commit-meta__sub",children:[h.author," <",h.email,"> · ",h.date]})]}),(0,u.jsxs)("div",{className:"git-commit-body",children:[(0,u.jsxs)("div",{className:"git-commit-files",children:[(0,u.jsxs)("div",{className:"git-commit-file__count",children:[r("全部文件")," (",h.files.length,")"]}),(0,u.jsx)($,{nodes:b,selected:_,on_select:e=>{g(e),y(!1)}})]}),(0,u.jsxs)("div",{className:"git-commit-diff",children:[(0,u.jsxs)("div",{className:"git-diff-header",children:[(0,u.jsx)("span",{className:"git-diff-header__badge",children:v?r("与工作区对比"):`${r("提交")} ${h.short_hash}`}),(0,u.jsx)("span",{className:"git-diff-header__path",title:_??"",children:_??`${r("全部文件")} (${h.files.length})`}),(0,u.jsxs)("div",{className:"git-diff-header__modes",children:[(0,u.jsx)(l.rA,{icon:"view_agenda",title:r("单栏"),selected:"unified"===p,onClick:()=>f("unified")}),(0,u.jsx)(l.rA,{icon:"view_column",title:r("并排"),selected:"split"===p,onClick:()=>f("split")})]})]}),_?v?(0,u.jsx)(C,{dir_path:e,file:_,left_ref:t,right_ref:"worktree",mode:p}):(0,u.jsx)(C,{dir_path:e,file:_,left_ref:`${t}^`,right_ref:t,mode:p}):(0,u.jsx)("div",{className:"git-diff-empty",children:(0,u.jsx)("span",{children:r("请选择文件查看改动")})})]})]})]})}function T(e){let t=0;for(let s=0;s<e.length;s++)t+=e.charCodeAt(s);return`hsl(${t%360}, 55%, 45%)`}function K({dir_path:e,file:t,on_close:s}){const{t:o}=(0,c.Bd)(),[r,d]=(0,a.useState)([]),[h,m]=(0,a.useState)(!1);(0,a.useEffect)(()=>{t&&_()},[t,e]);const _=async()=>{m(!0);try{const s=await i.TU.post("blame",{path:e,file:t});0===s.code?d(s.data||[]):((0,n.zN)(s.message),d([]))}catch(e){(0,n.zN)(e?.message),d([])}finally{m(!1)}};return(0,u.jsxs)("div",{className:"git-card git-card--diff",children:[(0,u.jsxs)("div",{className:"git-diff-header",children:[(0,u.jsx)("span",{className:"git-diff-header__badge",children:o("逐行归属")}),(0,u.jsx)("span",{className:"git-diff-header__path",title:t,children:t}),(0,u.jsx)("div",{className:"git-diff-header__modes",children:(0,u.jsx)(l.rA,{icon:"close",title:o("关闭"),onClick:s})})]}),h&&(0,u.jsx)("div",{className:"git-change-empty",children:o("加载中")}),!h&&0===r.length&&(0,u.jsx)("div",{className:"git-change-empty",children:o("无法读取该文件的归属信息")}),!h&&r.length>0&&(0,u.jsx)("div",{className:"git-blame",children:r.map((e,t)=>(0,u.jsxs)("div",{className:"git-blame__row",children:[(0,u.jsx)("span",{className:"git-blame__hash",title:e.hash,children:e.hash}),(0,u.jsx)("span",{className:"git-blame__author",style:{color:T(e.author)},title:`${e.author} · ${e.date}`,children:e.author}),(0,u.jsx)("span",{className:"git-blame__date",children:e.date}),(0,u.jsx)("span",{className:"git-blame__num",children:e.line_num}),(0,u.jsx)("span",{className:"git-blame__code",children:e.text||" "})]},t))})]})}function E({current:e,branches:t,on_checkout:s,on_create:i,on_delete:n,on_merge:o,ahead:r,behind:d}){const{t:h}=(0,c.Bd)(),m=(0,A.y)(),[_,g]=(0,a.useState)(!1),[p,f]=(0,a.useState)(""),x=()=>{const e=p.trim();e&&(i(e),f(""),g(!1))};return(0,u.jsxs)("div",{className:"git-branch-row",children:[(0,u.jsxs)("span",{className:"git-branch__name",children:[h("分支"),": ",e]}),(r>0||d>0)&&(0,u.jsxs)("span",{className:"git-branch__counts",children:[r>0&&(0,u.jsxs)("span",{className:"git-ahead",title:h("领先上游"),children:["↑",r]}),d>0&&(0,u.jsxs)("span",{className:"git-behind",title:h("落后上游"),children:["↓",d]})]}),(0,u.jsx)("div",{className:"git-branch__list",children:t.map(t=>{const a=t===e;return(0,u.jsxs)("div",{className:"git-branch-chip"+(a?" git-branch-chip--current":""),onClick:()=>!a&&s(t),title:a?h("当前分支"):`${h("切换到")} ${t}`,children:[t,!a&&(0,u.jsxs)("span",{className:"git-branch-chip__ops",children:[(0,u.jsx)("span",{className:"git-branch-chip__op",title:h("合并到此分支"),onClick:e=>{e.stopPropagation(),o(t)},children:"⇥"}),(0,u.jsx)("span",{className:"git-branch-chip__op",title:h("删除分支"),onClick:e=>{var s;e.stopPropagation(),s=t,m({title:h("删除分支"),sub_title:`${h("确认删除分支")} ${s} ?`,confirm_fun:()=>n(s,!1)})},children:"×"})]})]},t)})}),_?(0,u.jsxs)("span",{className:"git-branch-new",children:[(0,u.jsx)("input",{className:"input input--block",autoFocus:!0,value:p,placeholder:h("新分支名"),onChange:e=>f(e.target.value),onKeyDown:e=>{"Enter"===e.key&&x(),"Escape"===e.key&&(g(!1),f(""))}}),(0,u.jsx)(l.rA,{icon:"check",title:h("确定"),onClick:x}),(0,u.jsx)(l.rA,{icon:"close",title:h("取消"),onClick:()=>{g(!1),f("")}})]}):(0,u.jsx)(l.rA,{icon:"add",title:h("新建分支"),onClick:()=>g(!0)})]})}function B(e){const{t}=(0,c.Bd)(),{dir_path:s,user_config:r,proxy_config:d}=e,[h,m]=(0,a.useState)(!1),[_,g]=(0,a.useState)(r.name),[p,f]=(0,a.useState)(r.email),[x,j]=(0,a.useState)(!1),[N,v]=(0,a.useState)(d?.global.http||""),[y,b]=(0,a.useState)(d?.global.https||""),[w,k]=(0,a.useState)(d?.local.http||""),[S,C]=(0,a.useState)(d?.local.https||"");return(0,u.jsxs)(u.Fragment,{children:[(0,u.jsxs)("div",{className:"git-config-row",children:[(0,u.jsx)("span",{className:"git-config__label",children:t("用户配置")}),h?(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(o.Sm,{maxWidth:"15rem",value:_,placeholder:"user.name",handleInputChange:e=>g(e)}),(0,u.jsx)(o.Sm,{maxWidth:"15rem",value:p,placeholder:"user.email",handleInputChange:e=>f(e)}),(0,u.jsx)(l.rA,{icon:"check",title:t("保存"),onClick:async()=>{try{const a=await i.TU.post("set_user_config",{path:s,name:_,email:p});0===a.code?((0,n.SK)(t("用户配置已保存")),m(!1),e.on_user_config_saved({name:_,email:p})):(0,n.zN)(a.message)}catch(e){(0,n.zN)(e?.message)}}}),(0,u.jsx)(l.rA,{icon:"close",title:t("取消"),onClick:()=>m(!1)})]}):(0,u.jsxs)(u.Fragment,{children:[(0,u.jsxs)("span",{className:"git-config__value",children:[r.name," / ",r.email]}),(0,u.jsx)(l.rA,{icon:"edit",title:t("编辑"),onClick:()=>{g(r.name),f(r.email),m(!0)}})]})]}),(0,u.jsxs)("div",{className:"git-config-row",children:[(0,u.jsx)("span",{className:"git-config__label",children:t("代理配置")}),x?(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)(o.Sm,{maxWidth:"15rem",value:N,placeholder:"global http",handleInputChange:e=>v(e)}),(0,u.jsx)(o.Sm,{maxWidth:"15rem",value:y,placeholder:"global https",handleInputChange:e=>b(e)}),(0,u.jsx)(o.Sm,{maxWidth:"15rem",value:w,placeholder:"local http",handleInputChange:e=>k(e)}),(0,u.jsx)(o.Sm,{maxWidth:"15rem",value:S,placeholder:"local https",handleInputChange:e=>C(e)}),(0,u.jsx)(l.rA,{icon:"check",title:t("保存"),onClick:async()=>{const a=[{scope:"global",type:"http",value:N},{scope:"global",type:"https",value:y},{scope:"local",type:"http",value:w},{scope:"local",type:"https",value:S}];try{for(const e of a)await i.TU.post("set_proxy",{path:s,...e});(0,n.SK)(t("代理配置已保存")),j(!1),e.on_proxy_saved({global:{http:N,https:y},local:{http:w,https:S}})}catch(e){(0,n.zN)(e?.message)}}}),(0,u.jsx)(l.rA,{icon:"close",title:t("取消"),onClick:()=>j(!1)})]}):(0,u.jsxs)(u.Fragment,{children:[(0,u.jsx)("span",{className:"git-config__value",children:(()=>{if(!d)return"-";const e=d.global;if(e.http||e.https)return`global ${e.http||e.https}`;const t=d.local;return t.http||t.https?`local ${t.http||t.https}`:"-"})()}),(0,u.jsx)(l.rA,{icon:"edit",title:t("编辑"),onClick:()=>{v(d?.global.http||""),b(d?.global.https||""),k(d?.local.http||""),C(d?.local.https||""),j(!0)}})]})]})]})}function F({dir_path:e,target_hash:t,on_changed:s}){const{t:o}=(0,c.Bd)(),r=(0,A.y)(),[d,h]=(0,a.useState)([]),[m,_]=(0,a.useState)(!1),[g,p]=(0,a.useState)(""),[f,x]=(0,a.useState)(""),[j,N]=(0,a.useState)(!1);(0,a.useEffect)(()=>{v()},[e]);const v=async()=>{try{const t=await i.TU.post("tags",{path:e});0===t.code&&h(t.data||[])}catch(e){}};return(0,u.jsxs)("div",{className:"git-sub-panel",children:[(0,u.jsxs)("div",{className:"git-sub-panel__header",children:[(0,u.jsxs)("span",{className:"git-sub-panel__title",children:[o("标签")," (",d.length,")"]}),(0,u.jsx)(l.rA,{icon:"add",title:o("新建标签"),onClick:()=>_(!m)})]}),m&&(0,u.jsxs)("div",{className:"git-sub-panel__form",children:[(0,u.jsx)("input",{className:"input input--block",autoFocus:!0,value:g,placeholder:o("标签名"),onChange:e=>p(e.target.value)}),(0,u.jsx)("input",{className:"input input--block",value:f,placeholder:o("备注"),onChange:e=>x(e.target.value)}),(0,u.jsxs)("div",{className:"git-sub-panel__form-actions",children:[(0,u.jsx)("span",{className:"git-sub-panel__hint",children:t?`${o("基于提交")} ${t}`:o("基于当前提交")}),(0,u.jsx)(l.rA,{icon:"check",title:o("保存"),onClick:async()=>{const a=g.trim();if(a){N(!0);try{const c=await i.TU.post("tag_create",{path:e,name:a,message:f.trim(),hash:t});0===c.code?((0,n.SK)(o("标签创建成功")),p(""),x(""),_(!1),await v(),s()):(0,n.zN)(c.message)}catch(e){(0,n.zN)(e?.message)}finally{N(!1)}}else(0,n.zN)(o("请输入标签名"))}}),(0,u.jsx)(l.rA,{icon:"close",title:o("取消"),onClick:()=>{_(!1),p(""),x("")}})]})]}),(0,u.jsxs)("div",{className:"git-sub-panel__list",children:[0===d.length&&(0,u.jsx)("div",{className:"git-change-empty",children:o("暂无标签")}),d.map(t=>(0,u.jsxs)("div",{className:"git-sub-item",children:[(0,u.jsx)("span",{className:"git-sub-item__name",title:t.name,children:t.name}),(0,u.jsx)("span",{className:"git-sub-item__desc",title:t.message,children:t.message}),(0,u.jsx)("span",{className:"git-sub-item__meta",children:t.date}),(0,u.jsxs)("span",{className:"git-sub-item__ops",children:[(0,u.jsx)(l.rA,{icon:"upload",title:o("推送到远程"),onClick:()=>(async t=>{try{const s=await i.TU.post("tag_push",{path:e,name:t});0===s.code?(0,n.SK)(o("标签推送成功")):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}})(t.name)}),(0,u.jsx)(l.rA,{icon:"delete",title:o("删除标签"),onClick:()=>{return s=t.name,void r({title:o("删除标签"),sub_title:`${o("确认删除标签")} ${s} ?`,confirm_fun:async()=>{try{const t=await i.TU.post("tag_delete",{path:e,name:s});0===t.code?((0,n.SK)(o("标签删除成功")),await v()):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}}});var s}})]})]},t.name))]})]})}function I({dir_path:e,on_changed:t}){const{t:s}=(0,c.Bd)(),o=(0,A.y)(),[r,d]=(0,a.useState)([]),[h,m]=(0,a.useState)(!1);(0,a.useEffect)(()=>{h&&_()},[e,h]);const _=async()=>{try{const t=await i.TU.post("stash_list",{path:e});0===t.code&&d(t.data||[])}catch(e){}},g=async(a,c)=>{try{const l=await i.TU.post("stash_apply",{path:e,ref:a,pop:c});0===l.code?((0,n.SK)(s(c?"已恢复并删除记录":"已应用")),await _(),t()):(0,n.zN)(l.message)}catch(e){(0,n.zN)(e?.message)}};return(0,u.jsxs)("div",{className:"git-stash",children:[(0,u.jsx)("div",{className:"git-sub-panel__header",children:(0,u.jsxs)("span",{className:"git-sub-panel__title",onClick:()=>m(!h),style:{cursor:"pointer"},children:[s("暂存工作区记录")," ",h?"▾":"▸"]})}),h&&(0,u.jsxs)("div",{className:"git-sub-panel__list",children:[0===r.length&&(0,u.jsx)("div",{className:"git-change-empty",children:s("暂无记录")}),r.map(t=>(0,u.jsxs)("div",{className:"git-sub-item",children:[(0,u.jsx)("span",{className:"git-sub-item__name",title:t.message,children:t.message}),(0,u.jsx)("span",{className:"git-sub-item__meta",children:t.date}),(0,u.jsxs)("span",{className:"git-sub-item__ops",children:[(0,u.jsx)(l.rA,{icon:"play_arrow",title:s("应用"),onClick:()=>g(t.ref,!1)}),(0,u.jsx)(l.rA,{icon:"unarchive",title:s("恢复并删除"),onClick:()=>g(t.ref,!0)}),(0,u.jsx)(l.rA,{icon:"delete",title:s("删除"),onClick:()=>{return a=t.ref,void o({title:s("删除记录"),sub_title:`${s("确认删除")} ${a} ?`,confirm_fun:async()=>{try{const t=await i.TU.post("stash_drop",{path:e,ref:a});0===t.code?((0,n.SK)(s("已删除")),await _()):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}}});var a}})]})]},t.ref))]})]})}function M({dir_path:e,current_branch:t,on_checkout:s,on_compare:r}){const{t:d}=(0,c.Bd)(),h=(0,A.y)(),[m,_]=(0,a.useState)([]),[g,p]=(0,a.useState)([]),[f,x]=(0,a.useState)(!1),[j,N]=(0,a.useState)(!1),[v,y]=(0,a.useState)(null),[b,w]=(0,a.useState)("");(0,a.useEffect)(()=>{f&&k()},[e,f]);const k=async()=>{try{const t=await i.TU.post("remote_branches",{path:e});0===t.code&&(_(t.data?.branches||[]),p(t.data?.remotes||[]))}catch(e){}},S=async t=>{N(!0);try{const s=await i.TU.post("fetch",{path:e,prune:t});0===s.code?((0,n.SK)(d("拉取完成")),await k()):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}finally{N(!1)}},C=async()=>{const t=v;if(t&&b.trim()){N(!0);try{const a=await i.TU.post("remote_branch_rename",{path:e,branch:t,new_name:b.trim()});0===a.code?((0,n.SK)(d("重命名成功")),y(null),await k(),s()):(0,n.zN)(a.message)}catch(e){(0,n.zN)(e?.message)}finally{N(!1)}}};return(0,u.jsxs)("div",{className:"git-remote",children:[(0,u.jsxs)("div",{className:"git-sub-panel__header",children:[(0,u.jsxs)("span",{className:"git-sub-panel__title",onClick:()=>x(!f),children:[d("远程分支")," (",m.length,") ",f?"▾":"▸"]}),(0,u.jsx)(l.rA,{icon:"cloud_download",title:d("拉取远程信息"),onClick:()=>S(!1)}),(0,u.jsx)(l.rA,{icon:"cleaning_services",title:d("拉取并清理已删除分支"),onClick:()=>S(!0)})]}),f&&(0,u.jsxs)("div",{className:"git-sub-panel__list",children:[0===g.length&&(0,u.jsx)("div",{className:"git-change-empty",children:d("未配置远程仓库")}),m.map(c=>(0,u.jsxs)(a.Fragment,{children:[(0,u.jsxs)("div",{className:"git-sub-item",children:[(0,u.jsx)("span",{className:"git-sub-item__name",title:c.name,children:c.name}),(0,u.jsx)("span",{className:"git-sub-item__meta",children:c.date}),(0,u.jsxs)("span",{className:"git-sub-item__ops",children:[(0,u.jsx)(l.rA,{icon:"call_split",title:d("签出到本地"),onClick:()=>(async t=>{N(!0);try{const a=await i.TU.post("checkout_remote",{path:e,branch:t});0===a.code?((0,n.SK)(d("切换分支成功")),s()):(0,n.zN)(a.message)}catch(e){(0,n.zN)(e?.message)}finally{N(!1)}})(c.name)}),(0,u.jsx)(l.rA,{icon:"compare_arrows",title:d("与当前分支比较"),onClick:()=>r(c.name)}),(0,u.jsx)(l.rA,{icon:"merge",title:d("合并到当前分支"),onClick:()=>(async a=>{h({title:d("合并到当前分支"),sub_title:`${d("将")} ${a} ${d("合并到")} ${t} ?`,confirm_fun:async()=>{try{const t=await i.TU.post("merge",{path:e,branch:a});0===t.code?((0,n.SK)(d("合并成功")),s()):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}}})})(c.name)}),(0,u.jsx)(l.rA,{icon:"drive_file_rename_outline",title:d("重命名"),onClick:()=>(e=>{const t=e.indexOf("/"),s=t>=0?e.substring(t+1):e;w(s),y(e)})(c.name)}),(0,u.jsx)(l.rA,{icon:"delete",title:d("删除"),onClick:()=>{return t=c.name,void h({title:d("删除远程分支"),sub_title:`${d("确认删除远程分支")} ${t} ? ${d("该分支会从远程仓库删除")}`,confirm_fun:async()=>{try{const s=await i.TU.post("remote_branch_delete",{path:e,branch:t});0===s.code?((0,n.SK)(d("删除成功")),await k()):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}}});var t}})]})]}),v===c.name&&(0,u.jsxs)("div",{className:"git-remote__rename",children:[(0,u.jsx)(o.Sm,{value:b,width:"12rem",handleInputChange:e=>w(e)}),(0,u.jsx)(l.rA,{icon:"check",title:d("确定"),onClick:C}),(0,u.jsx)(l.rA,{icon:"close",title:d("取消"),onClick:()=>y(null)})]})]},c.name))]})]})}function P({dir_path:e,branch:t,current_branch:s,on_close:o}){const{t:r}=(0,c.Bd)(),[d,h]=(0,a.useState)([]),[m,_]=(0,a.useState)(null),[g,p]=(0,a.useState)("unified"),[f,x]=(0,a.useState)(!0);(0,a.useEffect)(()=>{_(null),N()},[e,t,s]);const N=async()=>{x(!0);try{const a=await i.TU.post("diff_files",{path:e,from:s,to:t});0===a.code?h(a.data||[]):(0,n.zN)(a.message)}catch(e){(0,n.zN)(e?.message)}finally{x(!1)}},v=(0,a.useMemo)(()=>j(d.map(e=>({path:e.path,data:e}))),[d]);return(0,u.jsxs)("div",{className:"git-card git-card--diff",children:[(0,u.jsxs)("div",{className:"git-diff-header",children:[(0,u.jsx)("span",{className:"git-diff-header__badge",children:r("分支比较")}),(0,u.jsxs)("span",{className:"git-diff-header__path",title:`${s} ↔ ${t}`,children:[s," ↔ ",t]}),m&&(0,u.jsxs)("div",{className:"git-diff-header__modes",children:[(0,u.jsx)(l.rA,{icon:"view_agenda",title:r("单栏"),selected:"unified"===g,onClick:()=>p("unified")}),(0,u.jsx)(l.rA,{icon:"view_column",title:r("并排"),selected:"split"===g,onClick:()=>p("split")})]}),(0,u.jsx)(l.rA,{icon:"close",title:r("关闭"),onClick:o})]}),(0,u.jsxs)("div",{className:"git-commit-body",children:[(0,u.jsxs)("div",{className:"git-commit-files",children:[(0,u.jsxs)("div",{className:"git-commit-file__count",children:[r("全部文件")," (",d.length,")"]}),(0,u.jsx)($,{nodes:v,selected:m,on_select:_})]}),(0,u.jsx)("div",{className:"git-commit-diff",children:f?(0,u.jsx)("div",{className:"git-diff-empty",children:(0,u.jsx)("span",{children:r("加载中")})}):m?(0,u.jsx)(C,{dir_path:e,file:m,left_ref:s,right_ref:t,mode:g}):(0,u.jsx)("div",{className:"git-diff-empty",children:(0,u.jsx)("span",{children:r("请选择文件查看改动")})})})]})]})}function D({dir_path:e,on_resolved:t}){const{t:s}=(0,c.Bd)(),o=(0,A.y)(),[r,d]=(0,a.useState)([]),[h,m]=(0,a.useState)("");(0,a.useEffect)(()=>{_()},[e]);const _=async()=>{try{const t=await i.TU.post("conflicts",{path:e});0===t.code&&(d(t.data?.files||[]),m(t.data?.state||""))}catch(e){}},g=async(a,c)=>{try{const l=await i.TU.post("resolve",{path:e,file:a,side:c});0===l.code?((0,n.SK)(s("已解决冲突")),await _(),t()):(0,n.zN)(l.message)}catch(e){(0,n.zN)(e?.message)}};return 0===r.length?null:(0,u.jsxs)("div",{className:"git-card git-conflict",children:[(0,u.jsxs)("div",{className:"git-sub-panel__header",children:[(0,u.jsxs)("span",{className:"git-sub-panel__title",children:[s("冲突")," (",r.length,")",h&&(0,u.jsx)("span",{className:"git-conflict__state",children:h})]}),(0,u.jsx)(l.rA,{icon:"done_all",title:s("标记全部已解决"),onClick:async()=>{try{const a=await i.TU.post("conflict_action",{path:e,action:"merge_continue"});0===a.code?((0,n.SK)(s("合并已完成")),t()):(0,n.zN)(a.message)}catch(e){(0,n.zN)(e?.message)}}}),(0,u.jsx)(l.rA,{icon:"undo",title:s("放弃合并"),onClick:()=>{const a="rebase"===h?"rebase_abort":"cherry-pick"===h?"cherry_pick_abort":"revert"===h?"revert_abort":"merge_abort";o({title:s("放弃合并"),sub_title:s("确认放弃当前合并并恢复到操作前状态"),confirm_fun:async()=>{try{const c=await i.TU.post("conflict_action",{path:e,action:a});0===c.code?((0,n.SK)(s("已放弃合并")),t()):(0,n.zN)(c.message)}catch(e){(0,n.zN)(e?.message)}}})}})]}),r.map(e=>(0,u.jsxs)("div",{className:"git-sub-item",children:[(0,u.jsx)("span",{className:"git-sub-item__name",title:e,children:e}),(0,u.jsxs)("span",{className:"git-sub-item__ops",children:[(0,u.jsx)(l.rA,{icon:"person",title:s("采用我方版本"),onClick:()=>g(e,"ours")}),(0,u.jsx)(l.rA,{icon:"group",title:s("采用对方版本"),onClick:()=>g(e,"theirs")}),(0,u.jsx)(l.rA,{icon:"check",title:s("标记已解决"),onClick:()=>g(e,"resolved")})]})]},e))]})}function R({dir_path:e,on_changed:t}){const{t:s}=(0,c.Bd)(),o=(0,A.y)(),[r,d]=(0,a.useState)([]),[h,m]=(0,a.useState)(!1);(0,a.useEffect)(()=>{h&&_()},[e,h]);const _=async()=>{try{const t=await i.TU.post("reflog",{path:e,maxCount:100});0===t.code&&d(t.data||[])}catch(e){}};return(0,u.jsxs)("div",{className:"git-reflog",children:[(0,u.jsx)("div",{className:"git-sub-panel__header",children:(0,u.jsxs)("span",{className:"git-sub-panel__title",onClick:()=>m(!h),style:{cursor:"pointer"},children:[s("操作历史")," (",r.length,") ",h?"▾":"▸"]})}),h&&(0,u.jsxs)("div",{className:"git-sub-panel__list",children:[0===r.length&&(0,u.jsx)("div",{className:"git-change-empty",children:s("暂无记录")}),r.map(a=>(0,u.jsxs)("div",{className:"git-sub-item",children:[(0,u.jsx)("span",{className:"git-sub-item__name",title:a.message,children:a.selector}),(0,u.jsx)("span",{className:"git-sub-item__desc",title:a.message,children:a.message}),(0,u.jsx)("span",{className:"git-sub-item__meta",children:a.date}),(0,u.jsxs)("span",{className:"git-sub-item__ops",children:[(0,u.jsx)(l.rA,{icon:"undo",title:s("回退到此处"),onClick:()=>{return c=a,void o({title:s("回退到此处"),sub_title:`${c.selector} · ${c.message}`,confirm_fun:async()=>{try{const a=await i.TU.post("reset_commit",{path:e,hash:c.selector,mode:"mixed"});0===a.code?((0,n.SK)(s("已回退")),await _(),t()):(0,n.zN)(a.message)}catch(e){(0,n.zN)(e?.message)}}});var c}}),(0,u.jsx)(l.rA,{icon:"delete_forever",title:s("强制回退(丢弃改动)"),onClick:()=>{return c=a,void o({title:s("强制回退(丢弃改动)"),sub_title:`${s("此操作将永久丢弃未提交的改动")}:${c.selector} · ${c.message}`,confirm_fun:async()=>{try{const a=await i.TU.post("reset_commit",{path:e,hash:c.selector,mode:"hard"});0===a.code?((0,n.SK)(s("已强制回退")),await _(),t()):(0,n.zN)(a.message)}catch(e){(0,n.zN)(e?.message)}}});var c}})]})]},a.selector))]})]})}function W({items:e,on_read:t,on_save:s,on_delete:i}){const{t:n}=(0,c.Bd)(),[r,d]=(0,a.useState)(null),[h,m]=(0,a.useState)(""),[_,g]=(0,a.useState)(!1);(0,a.useEffect)(()=>{r&&!e.some(e=>e.name===r)&&d(null)},[e,r]);const p=async()=>{if(r){g(!0);try{await s(r,h)}finally{g(!1)}}};return(0,u.jsx)("div",{className:"hook-editor",children:(0,u.jsxs)("div",{className:"hook-editor__list",children:[e.map(e=>(0,u.jsxs)(a.Fragment,{children:[(0,u.jsxs)("div",{className:"hook-item"+(r===e.name?" hook-item--editing":""),children:[(0,u.jsx)("span",{className:"hook-item__dot"+(e.enabled?" hook-item__dot--on":"")}),(0,u.jsx)("span",{className:"hook-item__name",children:e.name}),(0,u.jsxs)("span",{className:"hook-item__ops",children:[(0,u.jsx)(l.rA,{icon:r===e.name?"expand_less":"edit",title:n("编辑"),onClick:()=>(async e=>{if(r!==e){g(!0);try{m(await t(e)),d(e)}finally{g(!1)}}else d(null)})(e.name)}),e.enabled&&(0,u.jsx)(l.rA,{icon:"block",title:n("停用钩子"),onClick:()=>(async e=>{g(!0);try{await i(e)}finally{g(!1)}})(e.name)})]})]}),r===e.name&&(0,u.jsxs)("div",{className:"hook-item__editor",children:[(0,u.jsxs)("div",{className:"hook-item__editor-bar",children:[(0,u.jsx)("span",{className:"hook-item__editor-name",children:e.name}),(0,u.jsx)(l.rA,{icon:"check",title:n("保存并启用"),onClick:p}),(0,u.jsx)(l.rA,{icon:"close",title:n("取消"),onClick:()=>d(null)})]}),(0,u.jsx)(o.Z2,{className:"hook-item__text",value:h,spellCheck:!1,disabled:_,onChange:e=>m(e.target.value)})]})]},e.name)),0===e.length&&(0,u.jsx)("div",{className:"git-change-empty",children:n("暂无记录")})]})})}function H({dir_path:e}){const{t}=(0,c.Bd)(),s=(0,A.y)(),[l,o]=(0,a.useState)([]),[r,d]=(0,a.useState)(!1);(0,a.useEffect)(()=>{r&&h()},[e,r]);const h=async()=>{try{const t=await i.TU.post("hooks",{path:e});0===t.code&&o(t.data||[])}catch(e){}};return(0,u.jsxs)("div",{className:"git-hook",children:[(0,u.jsx)("div",{className:"git-sub-panel__header",children:(0,u.jsxs)("span",{className:"git-sub-panel__title",onClick:()=>d(!r),children:[t("钩子")," ",r?"▾":"▸"]})}),r&&(0,u.jsx)(W,{items:l,on_read:async t=>{try{const s=await i.TU.post("hook_read",{path:e,name:t});if(0===s.code)return s.data?.content||"";(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}return""},on_save:async(s,a)=>{try{const c=await i.TU.post("hook_save",{path:e,name:s,content:a});0===c.code?((0,n.SK)(t("已保存并启用")),await h()):(0,n.zN)(c.message)}catch(e){(0,n.zN)(e?.message)}},on_delete:async a=>{s({title:t("停用钩子"),sub_title:`${t("确认删除并停用")} ${a} ?`,confirm_fun:async()=>{try{const s=await i.TU.post("hook_delete",{path:e,name:a});0===s.code?((0,n.SK)(t("已停用")),await h()):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}}})}})]})}function O({dir_path:e,on_info_loaded:t,on_changed:s}){const{t:o}=(0,c.Bd)(),[r,d]=(0,a.useState)(null),[h,m]=(0,a.useState)([]),[_,g]=(0,a.useState)(!1),[p,f]=(0,a.useState)(!1);(0,a.useEffect)(()=>{x(),j()},[e]);const x=async()=>{try{const s=await i.TU.post("repo_info",{path:e});0===s.code&&(d(s.data),t(s.data))}catch(e){}},j=async()=>{try{const t=await i.TU.post("submodules",{path:e});0===t.code&&m(t.data||[])}catch(e){}},N=e=>o("uninitialized"===e?"未初始化":"modified"===e?"与记录不一致":"正常");return(0,u.jsxs)("div",{className:"git-repo-panel",children:[(0,u.jsxs)("div",{className:"git-config-row",children:[(0,u.jsx)("span",{className:"git-config__label",children:o("远程地址")}),(0,u.jsx)("span",{className:"git-config__value",title:r?.remote_url,children:r?.remote_url||o("未配置")})]}),(0,u.jsxs)("div",{className:"git-config-row",children:[(0,u.jsx)("span",{className:"git-config__label",children:o("当前提交")}),(0,u.jsxs)("span",{className:"git-config__value",children:[r?.head_hash||"",r&&(r.ahead>0||r.behind>0)&&(0,u.jsxs)("span",{className:"git-repo-panel__counts",children:[r.ahead>0&&(0,u.jsxs)("span",{className:"git-ahead",children:["↑",r.ahead]}),r.behind>0&&(0,u.jsxs)("span",{className:"git-behind",children:["↓",r.behind]})]})]})]}),(0,u.jsxs)("div",{className:"git-sub-panel__header",children:[(0,u.jsxs)("span",{className:"git-sub-panel__title",onClick:()=>g(!_),style:{cursor:"pointer"},children:[o("子模块")," (",h.length,") ",_?"▾":"▸"]}),h.length>0&&(0,u.jsx)(l.rA,{icon:"sync",title:o("初始化并更新子模块"),onClick:async()=>{f(!0);try{const t=await i.TU.post("submodule_update",{path:e});0===t.code?((0,n.SK)(o("子模块更新完成")),await j(),s()):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}finally{f(!1)}}})]}),_&&(0,u.jsxs)("div",{className:"git-sub-panel__list",children:[0===h.length&&(0,u.jsx)("div",{className:"git-change-empty",children:o("无子模块")}),h.map(e=>(0,u.jsxs)("div",{className:"git-sub-item",children:[(0,u.jsx)("span",{className:"git-sub-item__name",title:e.path,children:e.path}),(0,u.jsx)("span",{className:"git-sub-item__desc",title:e.desc,children:e.desc}),(0,u.jsx)("span",{className:`git-sub-item__meta git-sub-status--${e.status}`,children:N(e.status)})]},e.path))]})]})}function L({dir_path:e,on_changed:t}){const{t:s}=(0,c.Bd)(),o=(0,d.Zp)(),[r,h]=(0,a.useState)([]),[_,g]=(0,a.useState)([]),[p,f]=(0,a.useState)("none"),[x,j]=(0,a.useState)(""),[N,v]=(0,a.useState)(""),[y,b]=(0,a.useState)(!1);(0,a.useEffect)(()=>{w(),k()},[e]);const w=async()=>{try{const t=await i.TU.post("repos",{path:e});0===t.code&&h(t.data||[])}catch(e){}},k=async()=>{try{const t=await i.TU.post("dirs",{path:e});0===t.code&&g(t.data?.dirs||[])}catch(e){}},S=async()=>{const a=x.trim();if(a){b(!0);try{const c=await i.TU.post("init",{path:`${e}/${a}`.replace(/\/+/g,"/")});0===c.code?((0,n.SK)(s("仓库初始化成功")),f("none"),j(""),await w(),await k(),t()):(0,n.zN)(c.message)}catch(e){(0,n.zN)(e?.message)}finally{b(!1)}}else(0,n.zN)(s("请输入目录名"))},C=async()=>{const a=x.trim();if(a)if(N.trim()){b(!0);try{const c=await i.TU.post("clone",{target:`${e}/${a}`.replace(/\/+/g,"/"),url:N.trim()});0===c.code?((0,n.SK)(s("克隆成功")),f("none"),j(""),v(""),await w(),await k(),t()):(0,n.zN)(c.message)}catch(e){(0,n.zN)(e?.message)}finally{b(!1)}}else(0,n.zN)(s("请输入仓库地址"));else(0,n.zN)(s("请输入目录名"))};return(0,u.jsxs)("div",{className:"git-repo-manager",children:[(0,u.jsxs)("div",{className:"git-repo-manager__header",children:[(0,u.jsxs)("span",{className:"git-sub-panel__title",children:[s("仓库")," (",r.length,")"]}),(0,u.jsx)(l.rA,{icon:"add",title:s("初始化仓库"),selected:"init"===p,onClick:()=>{f("init"===p?"none":"init"),j("")}}),(0,u.jsx)(l.rA,{icon:"cloud_download",title:s("克隆仓库"),selected:"clone"===p,onClick:()=>{f("clone"===p?"none":"clone"),j("")}})]}),"none"!==p&&(0,u.jsxs)("div",{className:"git-sub-panel__form",children:[(0,u.jsx)("input",{className:"input input--block",autoFocus:!0,value:x,placeholder:s("目录名"),onChange:e=>j(e.target.value),onKeyDown:e=>"Enter"===e.key&&("init"===p?S():C())}),"clone"===p&&(0,u.jsx)("input",{className:"input input--block",value:N,placeholder:s("仓库地址"),onChange:e=>v(e.target.value),onKeyDown:e=>"Enter"===e.key&&C()}),(0,u.jsxs)("div",{className:"git-sub-panel__form-actions",children:[(0,u.jsx)("span",{className:"git-sub-panel__hint",children:`${e}/${x||"..."}`.replace(/\/+/g,"/")}),(0,u.jsx)(l.rA,{icon:"check",title:s("保存"),onClick:"init"===p?S:C}),(0,u.jsx)(l.rA,{icon:"close",title:s("取消"),onClick:()=>{f("none"),j(""),v("")}})]}),_.length>0&&(0,u.jsx)("div",{className:"git-repo-manager__dirs",children:_.map(e=>(0,u.jsx)("span",{className:"git-repo-manager__dir",onClick:()=>j(e),children:e},e))})]}),(0,u.jsxs)("div",{className:"git-sub-panel__list",children:[0===r.length&&(0,u.jsx)("div",{className:"git-change-empty",children:s("当前目录下没有仓库")}),r.map(t=>(0,u.jsxs)("div",{className:"git-sub-item",children:[(0,u.jsx)("span",{className:"git-sub-item__name",title:t.name,children:t.name}),(0,u.jsx)("span",{className:"git-sub-item__meta",children:t.branch}),(0,u.jsx)("span",{className:"git-sub-item__ops",children:(0,u.jsx)(l.rA,{icon:"login",title:s("进入"),onClick:()=>{return s=t,void o(`${m.o.git_page}/${e}/${s.name}/`.replace(/\/+/g,"/"));var s}})})]},t.path))]})]})}const Z=100;function q(){const{t:e}=(0,c.Bd)(),t=(0,A.y)(),s=(0,d.Zp)();let g=decodeURIComponent((0,h.GG)(m.o.git_page,(0,h.vX)()));g=g.replace(/\/+$/,"");const[p,f]=(0,a.useState)([]),[x,j]=(0,a.useState)([]),[N,v]=(0,a.useState)(!1),[y,w]=(0,a.useState)(!1),k=(0,a.useRef)(!1),[S,$]=(0,a.useState)({current:"",branches:[]}),[T,W]=(0,a.useState)(""),[q,G]=(0,a.useState)(new Set),[V,X]=(0,a.useState)("status"),[J,Q]=(0,a.useState)(!1),[Y,ee]=(0,a.useState)(20),[te,se]=(0,a.useState)(!1),ae=(0,a.useRef)(null),ie=(0,a.useRef)(null),[ne,ce]=(0,a.useState)(null),[le,oe]=(0,a.useState)("unified"),[re,de]=(0,a.useState)({name:"",email:""}),[he,me]=(0,a.useState)(null),[_e,ge]=(0,a.useState)(0),[pe,ue]=(0,a.useState)(null),[fe,xe]=(0,a.useState)(null),[je,Ne]=(0,a.useState)(!1);(0,a.useEffect)(()=>{g&&ye().then(e=>{e&&(be(),we(),ke(),Se(),ve())})},[g]);const ve=async()=>{try{const e=await i.TU.post("conflicts",{path:g});0===e.code&&ge((e.data?.files||[]).length)}catch(e){}},ye=async()=>{try{Q(!0);const e=await i.TU.post("status",{path:g});return 0===e.code&&(f(e.data||[]),Ne(!1),!0)}catch(e){const t="string"==typeof e?e:e?.message;return t&&t.includes("not a git repository")&&Ne(!0),!1}finally{Q(!1)}},be=async()=>{try{const e=await i.TU.post("log",{path:g,maxCount:Z,skip:0});if(0===e.code){const t=e.data||[];j(t),v(t.length>=Z)}}catch(e){}},we=async()=>{try{const e=await i.TU.post("branches",{path:g});0===e.code&&$(e.data||{current:"",branches:[]})}catch(e){}},ke=async()=>{try{const e=await i.TU.post("get_user_config",{path:g});0===e.code&&de(e.data)}catch(e){}},Se=async()=>{try{const e=await i.TU.post("get_proxy",{path:g});0===e.code&&me(e.data)}catch(e){}},Ce=async(t,s)=>{t.untracked?(0,n.zN)(e("未跟踪文件无差异")):ce({kind:"working",path:t.path,staged:s})},ze=async()=>{const e=p.filter(e=>!e.staged);try{Q(!0);const t=await i.TU.post("add",{path:g,files:e.map(e=>e.path)});if(0!==t.code)return void(0,n.zN)(t.message)}catch(e){return void(0,n.zN)(e?.message)}finally{Q(!1)}await Ae(!1)},Ae=async t=>{try{Q(!0);const s=await i.TU.post("commit",{path:g,message:T.trim(),allChanged:t});0===s.code?((0,n.SK)(e("提交成功")),W(""),ce(null),await ye(),be()):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}finally{Q(!1)}},$e=async(t=!1)=>{try{Q(!0);const s=await i.TU.post("push",{path:g,force:t});0===s.code?(0,n.SK)(e("推送成功")):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}finally{Q(!1)}},Ue=async()=>{ce(null),await ye(),be(),we()},Te=(0,a.useCallback)(_.throttle(e=>{const t=parseFloat(getComputedStyle(ie.current).fontSize),s=window.innerWidth/t-4,a=e.clientX/t,i=2.25+ae.current.offsetWidth/t;a<=s&&a>=i&&ee(parseFloat(a.toFixed(2)))},32),[]),Ke=()=>{se(!1),ie.current.removeEventListener("pointermove",Te)},Ee=g.split("/").filter(Boolean).pop()||g;return(0,u.jsxs)("div",{className:"studio",children:[(0,u.jsx)(r.A,{ignore_tags:!0,left_children:[(0,u.jsx)(l.rA,{title:e("取消"),icon:"close",onClick:()=>s(-1)},"close"),(0,u.jsx)("span",{children:Ee},"title")],children:(0,u.jsx)(l.rA,{icon:"refresh",title:e("刷新"),onClick:()=>{ye(),be(),we(),ke(),Se()}})}),je?(0,u.jsx)("div",{className:"studio-body",children:(0,u.jsx)("div",{className:"studio-editor",children:(0,u.jsx)("div",{className:"git-main",children:(0,u.jsx)("div",{className:"git-card",children:(0,u.jsx)(L,{dir_path:g,on_changed:()=>{Ne(!1),ye(),be(),we()}})})})})}):(0,u.jsxs)("div",{className:"studio-body",ref:ie,children:[(0,u.jsxs)("div",{className:"studio-nav studio-nav--git",style:{width:Y-1+"em"},children:[(0,u.jsx)("div",{className:"menu git-menu not-select-div",children:(0,u.jsx)("div",{className:"wrapper",children:(0,u.jsxs)("ul",{children:[(0,u.jsxs)("li",{className:"status"===V?"active":"",onClick:()=>X("status"),children:[e("变更")," (",p.length,")"]}),(0,u.jsxs)("li",{className:"log"===V?"active":"",onClick:()=>X("log"),children:[e("提交记录")," (",x.length,")"]})]})})}),"status"===V&&(0,u.jsx)("div",{className:"git-scroll",children:(0,u.jsx)(b,{files:p,selected:q,on_toggle:e=>{const t=new Set(q);t.has(e)?t.delete(e):t.add(e),G(t)},on_toggle_all:(e,t)=>{const s=new Set(q);for(const a of e)t?s.add(a):s.delete(a);G(s)},active_path:"working"===ne?.kind?ne.path:null,on_view_diff:Ce,on_stage_section:async(t,s)=>{if(0===t.length)return;const a=t.map(e=>e.path);try{const t=s?await i.TU.post("reset",{path:g,files:a}):await i.TU.post("add",{path:g,files:a});0===t.code?((0,n.SK)(e(s?"已取消暂存":"已暂存")),await ye()):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}},on_stage_one:async(e,t)=>{try{const s=t?await i.TU.post("reset",{path:g,files:[e.path]}):await i.TU.post("add",{path:g,files:[e.path]});0===s.code?(await ye(),"working"===ne?.kind&&ne.path===e.path&&Ce(e,!t)):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}},on_view_blame:e=>{ce({kind:"blame",file:e.path})}})}),"log"===V&&(0,u.jsx)("div",{className:"git-scroll",children:(0,u.jsx)(z,{dir_path:g,entries:pe??x,is_search:null!==pe,has_more:N,loading_more:y,active_hash:"commit"===ne?.kind?ne.hash:null,on_select:e=>{ce({kind:"commit",hash:e})},on_scroll_bottom:e=>{if(null!==pe)return;const t=e.currentTarget;t.scrollHeight-t.scrollTop-t.clientHeight<200&&(async()=>{if(!k.current&&N){k.current=!0,w(!0);try{const e=await i.TU.post("log",{path:g,maxCount:Z,skip:x.length});if(0===e.code){const t=e.data||[];j(e=>[...e,...t]),v(t.length>=Z)}}catch(e){}finally{k.current=!1,w(!1)}}})()},on_search_result:e=>{ue(e),null===e&&be()}})})]}),(0,u.jsx)("div",{className:"studio__divider",ref:ae,onPointerDown:()=>{se(!0),ie.current.addEventListener("pointermove",Te)},onPointerUp:Ke}),te&&(0,u.jsx)("div",{className:"shell__overlay",onPointerUp:Ke}),(0,u.jsx)("div",{className:"studio-editor",children:(0,u.jsxs)("div",{className:"git-main",children:[(0,u.jsx)(D,{dir_path:g,on_resolved:Ue}),(0,u.jsxs)("div",{className:"git-card",children:[(0,u.jsx)(E,{current:S.current,branches:S.branches,on_checkout:async t=>{try{Q(!0);const s=await i.TU.post("checkout",{path:g,branch:t});0===s.code?((0,n.SK)(e("切换分支成功")),await Ue()):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}finally{Q(!1)}},on_create:async t=>{try{Q(!0);const s=await i.TU.post("branch_create",{path:g,name:t});0===s.code?((0,n.SK)(e("分支创建成功")),await Ue()):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}finally{Q(!1)}},on_delete:async(t,s)=>{try{Q(!0);const a=await i.TU.post("branch_delete",{path:g,name:t,force:s});0===a.code?((0,n.SK)(e("分支删除成功")),await Ue()):(0,n.zN)(a.message)}catch(e){(0,n.zN)(e?.message)}finally{Q(!1)}},on_merge:async t=>{try{Q(!0);const s=await i.TU.post("merge",{path:g,branch:t});0===s.code?((0,n.SK)(e("合并成功")),await Ue()):(0,n.zN)(s.message)}catch(e){(0,n.zN)(e?.message)}finally{Q(!1)}},ahead:fe?.ahead,behind:fe?.behind}),(0,u.jsx)(M,{dir_path:g,current_branch:S.current,on_checkout:Ue,on_compare:e=>ce({kind:"remote",branch:e})}),(0,u.jsx)(o.Z2,{placeholder:e("git_msg"),value:T,onChange:e=>W(e.target.value),rows:3}),(0,u.jsxs)("div",{className:"git-btn-row",children:[(0,u.jsx)(l.rA,{icon:"check",title:e("提交"),onClick:async()=>{if(!T.trim())return void(0,n.zN)(e("请输入提交信息"));if(0===p.filter(e=>e.staged).length){return 0===p.filter(e=>!e.staged).length?void(0,n.zN)(e("没有可提交的更改")):void t({title:e("提交"),sub_title:e("存在未暂存的改动,是否一并暂存并提交?"),confirm_fun:ze})}await Ae(!1)}}),(0,u.jsx)(l.rA,{icon:"edit_note",title:e("修改最后一次提交"),onClick:async()=>{try{Q(!0);const t=await i.TU.post("commit_amend",{path:g,message:T});0===t.code?((0,n.SK)(e("已修改最后一次提交")),W(""),ce(null),await ye(),be()):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}finally{Q(!1)}}}),(0,u.jsx)(l.rA,{icon:"download",title:e("拉取"),onClick:async()=>{try{Q(!0);const t=await i.TU.post("pull",{path:g});0===t.code?((0,n.SK)(e("拉取成功")),await ye(),be()):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}finally{Q(!1)}}}),(0,u.jsx)(l.rA,{icon:"upload",title:e("推送"),onClick:()=>$e(!1)}),(0,u.jsx)(l.rA,{icon:"keyboard_double_arrow_up",title:e("强制推送"),onClick:()=>$e(!0)}),(0,u.jsx)("span",{className:"git-btn-gap"}),(0,u.jsx)(l.rA,{icon:"inventory_2",title:e("暂存工作区"),onClick:async()=>{try{const t=await i.TU.post("stash",{path:g});0===t.code?((0,n.SK)(e("暂存工作区成功")),ce(null),await ye()):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}}}),(0,u.jsx)(l.rA,{icon:"unarchive",title:e("恢复工作区"),onClick:async()=>{try{const t=await i.TU.post("stash_pop",{path:g});0===t.code?((0,n.SK)(e("恢复工作区成功")),await ye()):(0,n.zN)(t.message)}catch(e){(0,n.zN)(e?.message)}}})]}),(0,u.jsx)(I,{dir_path:g,on_changed:Ue}),(0,u.jsx)(F,{dir_path:g,target_hash:"commit"===ne?.kind?ne.hash:void 0,on_changed:Ue}),(0,u.jsx)(R,{dir_path:g,on_changed:Ue})]}),ne?"commit"===ne.kind?(0,u.jsx)(U,{dir_path:g,hash:ne.hash,on_close:()=>ce(null),on_changed:Ue}):"blame"===ne.kind?(0,u.jsx)(K,{dir_path:g,file:ne.file,on_close:()=>ce(null)}):"remote"===ne.kind?(0,u.jsx)(P,{dir_path:g,branch:ne.branch,current_branch:S.current,on_close:()=>ce(null)}):(0,u.jsxs)("div",{className:"git-card git-card--diff",children:[(0,u.jsxs)("div",{className:"git-diff-header",children:[(0,u.jsx)("span",{className:"git-diff-header__badge",children:ne.staged?e("已暂存"):e("未暂存")}),(0,u.jsx)("span",{className:"git-diff-header__path",title:ne.path,children:ne.path}),(0,u.jsxs)("div",{className:"git-diff-header__modes",children:[(0,u.jsx)(l.rA,{icon:"view_agenda",title:e("单栏"),selected:"unified"===le,onClick:()=>oe("unified")}),(0,u.jsx)(l.rA,{icon:"view_column",title:e("并排"),selected:"split"===le,onClick:()=>oe("split")}),(0,u.jsx)(l.rA,{icon:"close",title:e("关闭"),onClick:()=>ce(null)})]})]}),ne.staged?(0,u.jsx)(C,{dir_path:g,file:ne.path,left_ref:"HEAD",right_ref:"staged",mode:le}):(0,u.jsx)(C,{dir_path:g,file:ne.path,left_ref:"HEAD",right_ref:"worktree",mode:le})]}):(0,u.jsx)("div",{className:"git-card git-card--placeholder",children:e("点击左侧文件查看差异")}),(0,u.jsxs)("div",{className:"git-card",children:[(0,u.jsx)(B,{dir_path:g,user_config:re,proxy_config:he,on_user_config_saved:de,on_proxy_saved:me}),(0,u.jsx)(O,{dir_path:g,on_info_loaded:xe,on_changed:Ue}),(0,u.jsx)(H,{dir_path:g})]})]})})]})]})}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[3659],{22081(e,n,t){t.d(n,{A:()=>r});var s=t(96540),a=t(16349),i=t(74848);const r=({percentage:e})=>{const n=(0,s.useRef)(null),[t,r]=(0,s.useState)(null);return(0,s.useEffect)(()=>{const t=n.current.getContext("2d"),s=new a.Ay(t,{type:"doughnut",data:{labels:["use","left"],datasets:[{data:[e,100-e],backgroundColor:["#007bff","#f0f0f0"],borderWidth:0}]},options:{plugins:{legend:{display:!1},tooltip:{enabled:!1}},elements:{arc:{borderWidth:0}}}});return r(s),()=>{s.destroy()}},[]),(0,s.useEffect)(()=>{t&&(t.data.datasets[0].data=[e,100-e],t.update())},[e]),(0,i.jsx)("div",{style:{width:"8rem",overflow:"hidden"},children:(0,i.jsx)("canvas",{ref:n})})}},88062(e,n,t){t.d(n,{A:()=>r});t(96540),t(47022);var s=t(74848);function a(e){return(0,s.jsx)("div",{className:"black-tip",onClick:()=>{e.click&&e.click(e)},onContextMenu:n=>{n.stopPropagation(),n.nativeEvent.stopImmediatePropagation(),e.onContextMenu&&e.onContextMenu(n,e)},children:e.name})}const i=e=>(0,s.jsxs)("li",{children:[e.click?(0,s.jsx)(a,{...e.node,name:e.render?e.render(e.node):e.node.name,click:e.click,onContextMenu:e.onContextMenu}):(0,s.jsx)("div",{children:e.render?e.render(e.node):e.node.name}),e.node.children&&e.node.children.length>0&&(0,s.jsx)("ul",{children:e.node.children.map((n,t)=>(0,s.jsx)(i,{node:n,click:e.click,onContextMenu:e.onContextMenu,render:e.render},t))})]}),r=e=>(0,s.jsx)("div",{className:"card-tree-view",children:(0,s.jsx)("ul",{children:e.list&&e.list.map((n,t)=>(0,s.jsx)(i,{node:n,click:e.click,onContextMenu:e.onContextMenu,render:e.render},t))})})},63659(e,n,t){t.r(n),t.d(n,{default:()=>N});var s=t(22022),a=t(96540),i=t(34843),r=t(82893),o=t(92275),d=t(14944),c=(t(14284),t(70447)),l=t(85997),u=t(62042),x=t(4412),h=t(75725),p=(t(22081),t(77481)),j=t(61443),m=t(47071),f=t(34289),v=t(88062),w=t(97856),_=t(88815),g=t(15629),k=t(74848);const y=a.lazy(()=>t.e(3233).then(t.bind(t,85614)));let b,C,S=-1;function N(e){const{t:n}=(0,s.Bd)(),[t,N]=(0,i.fp)(r.AG.workflow_show),[M,A]=(0,a.useState)([]),[F,$]=(0,a.useState)([]),[E,G]=(0,a.useState)(!1),[W,P]=(0,a.useState)(void 0),[q,z]=(0,a.useState)([]),[B,I]=(0,a.useState)(-1),[J,X]=(0,a.useState)(10),[O,D]=(0,a.useState)(0),[H,K]=(0,a.useState)(0),[Z,T]=(0,a.useState)(""),[V,Y]=(0,a.useState)(!1),R=[n("序号"),n("运行名称"),n("状态"),n("运行时长"),n("日期"),n("操作")],L=[n("名称"),n("状态"),n("cwd"),n("运行时长"),n("操作")],Q=async e=>{const n=new m._;n.page_num=e??B,n.page_size=J,n.dir_path=`${(0,f.GG)("file",(0,f.vX)())}`;const t=await d.ws.sendData(o.HK.workflow_get,n);if(!t)return;const s=t.context;s&&(A(s.list.map(e=>{const n="string"==typeof e.meta?JSON.parse(e.meta):e.meta;return n.index=e.index,n})),D(s.total),K((0,_.gw)(s.total,J)))};(0,a.useEffect)(()=>(G(!1),b=void 0,C=void 0,S=-1,Q(),async()=>{C&&(C.dispose(),C=null)}),[]);const U=async e=>{const n=e.steps,t=[];(0,g.Y)(t,n??[]),z(t)},ee=async e=>{C||await new Promise(e=>{b=e,G(!0),(async()=>{const e=new w.Terminal({fontFamily:"Monaco, Menlo, Consolas, 'Courier New', monospace",theme:{background:"#FFFFFF",foreground:"#000000",cursor:"#000000",selectionBackground:"#a6d2ff"},cursorBlink:!0,cursorStyle:"bar",scrollback:1e3,scrollSensitivity:1,tabStopWidth:4,convertEol:!0});C=e,P(e)})()}),e&&(C.reset(),C.write(e))};return(0,k.jsxs)("div",{children:[(0,k.jsxs)(x.aZ,{position:"right",children:[W&&(0,k.jsx)(l.rA,{icon:"print",title:"打印日志",onClick:()=>{G(!E)}}),(0,k.jsx)(l.rA,{icon:"close",title:n("关闭"),onClick:()=>{N(!1)}})]}),(0,k.jsx)(h.jW,{isFull:!0,more:!0,children:(0,k.jsx)(h.NN,{children:(0,k.jsx)(h.xh,{children:(0,k.jsxs)(h.fI,{children:[(0,k.jsx)(h.VP,{children:(0,k.jsx)(c.uF,{self_title:(0,k.jsx)("span",{className:" div-row ",children:(0,k.jsx)("h2",{children:n("历史记录")})}),rightTopCom:(0,k.jsx)("div",{className:" div-row ",children:(0,k.jsx)(j.Sm,{disabled:V,value:Z,placeholder:"搜索运行名称(支持正则)",handleInputChange:e=>{T(Z)},handlerEnter:e=>{(async e=>{const n=new m._;n.search_name=e,n.dir_path=`${(0,f.GG)("file",(0,f.vX)())}`,Y(!0);const t=await d.ws.sendData(o.HK.workflow_search_by_run_name,n);if(!t)return;const s=t.context;A(s.list.map(e=>{const n="string"==typeof e.meta?JSON.parse(e.meta):e.meta;return n.index=e.index,n})),D(s.total),K((0,_.gw)(s.total,J)),I(0),Y(!1)})(e)}})}),rightBottomCom:(0,k.jsxs)("span",{className:" div-row ",children:[(0,k.jsxs)("span",{children:[Math.abs(B),"/",H]}),(0,k.jsx)(j.Sm,{placeholder:`max page ${H}`,handleInputChange:e=>{S=parseInt(e)},handlerEnter:()=>{if(S<1||S>H)return void(0,u.zN)("illegal page num");const e=0-S;I(e),Q(e)}}),(0,k.jsx)(l.rA,{icon:"navigate_before",onClick:()=>{const e=B+1;e>-1?(0,u.zN)("max page num"):(I(e),Q(e))},title:"上一页"}),(0,k.jsx)(l.rA,{icon:"navigate_next",onClick:()=>{const e=B-1;Math.abs(e)>H?(0,u.zN)("min page num"):(I(e),Q(e))},title:"下一页"})]}),children:(0,k.jsx)(p.X,{headers:R,rows:M.map((e,t)=>{let s;s=e.is_running?(0,k.jsxs)("div",{children:[(0,k.jsx)(c.fq,{}),n("正在运行")]}):(0,k.jsxs)("div",{children:[(0,k.jsx)(c.fq,{success:e.is_success}),e.is_success?n("成功"):n("失败")]});const a=[(0,k.jsx)("p",{children:e.index}),(0,k.jsx)("p",{style:{wordWrap:"break-word"},children:e["run-name"]}),s,(0,k.jsx)("span",{children:e.duration}),(0,k.jsx)("span",{children:e.timestamp}),(0,k.jsx)("div",{children:(0,k.jsx)(l.rA,{icon:"details",title:n("详情"),onClick:()=>{(async e=>{if(e.is_running)return;z([]);const n=new m._;n.index=e.index,n.dir_path=`${(0,f.GG)("file",(0,f.vX)())}`;const t=(await d.ws.sendData(o.HK.workflow_get,n)).context,s="string"==typeof t.one_data.data?JSON.parse(t.one_data.data):t.one_data.data;$(s.all_jobs)})(e)}})})];return a}),width:"10rem"})})}),(0,k.jsxs)(h.VP,{children:[(0,k.jsx)(c.Zp,{title:n("Job"),children:(0,k.jsx)(p.X,{headers:L,rows:F.map((e,t)=>[(0,k.jsx)("p",{children:e.name}),(0,k.jsx)(g.W,{item:e}),(0,k.jsx)(c.xP,{children:String(e.cwd)}),(0,k.jsx)("span",{children:e.duration}),(0,k.jsxs)("div",{children:[(0,k.jsx)(l.rA,{icon:"details",title:n("详情"),onClick:()=>{U(e)}}),!!e.message&&(0,k.jsx)(l.rA,{icon:"print",title:n("日志"),onClick:()=>{ee(e.message)}})]})]),width:"10rem"})}),(0,k.jsx)(c.Zp,{title:"Step",children:(0,k.jsx)(v.A,{list:q,click:e=>{(async e=>{if(e?.extra_data?.is_job)await U(e.extra_data.job_data);else if(e?.extra_data?.context)ee(e.extra_data.context);else{if(!e?.extra_data.code)return;ee(e.extra_data.code??"")}})(e)}})})]})]})})})}),(0,k.jsx)("div",{style:{display:E?"":"none"},children:(0,k.jsx)(y,{show:!0,terminal:W,init:()=>{b&&(b(1),b=void 0)}})})]})}},15629(e,n,t){t.d(n,{W:()=>o,Y:()=>d});t(96540);var s=t(70447),a=t(47071),i=t(22022),r=t(74848);function o({item:e}){const{t:n}=(0,i.Bd)();let t,o;return null!=e.code?t=0===e.code:e.extra_data?.running_type===a.rl.running&&(o=!0),(0,r.jsxs)("div",{children:[(0,r.jsx)(s.fq,{success:t,running:o}),n(t?"成功":"失败")]})}const d=(e,n,t)=>{if(n)for(const t of n??[]){let n;const a=[];t["use-yml"]?(d(a,void 0,t.use_job_children_list),n=`${t["use-yml"]} ;${t.duration??-1}`):t.runs?n=JSON.stringify(t.runs):t.run?n=t.run:t["run-js"]?n=t["run-js"]:t.sleep&&(n=`sleep ${t.sleep}`),n=(0,r.jsxs)("div",{children:[(0,r.jsx)(s.fq,{success:void 0===t.code?void 0:0===t.code})," ",n+" ;"+(t.duration??"")]}),e.push({name:n,children:a,extra_data:{code:t.code,context:t.message}})}else if(t)for(const n of t??[]){const t=(0,r.jsxs)("div",{children:[(0,r.jsx)(s.fq,{success:void 0===n.code?void 0:0===n.code}),"$",n.name]});e.push({name:t,extra_data:{code:n.code,is_job:!0,job_data:n}})}}}}]);
@@ -1 +0,0 @@
1
- "use strict";(self.webpackChunkfilecat=self.webpackChunkfilecat||[]).push([[4903],{64903(e,t,n){n.r(t),n.d(t,{default:()=>f});var c=n(96540),i=n(34843),l=n(82893),s=n(85997),o=n(57952),a=(n(62042),n(21499),n(40505),n(22022)),d=(n(99214),n(74848));const r=c.lazy(()=>Promise.all([n.e(4946),n.e(2626),n.e(892),n.e(9334),n.e(6010)]).then(n.bind(n,34299)));function f(e){const{t}=(0,a.Bd)(),[n,c]=(0,i.fp)(l.AG.markdown);if(n.context)return(0,d.jsxs)("div",{id:"md-container",children:[(0,d.jsx)(o.A,{ignore_tags:!0,left_children:[(0,d.jsx)(s.rA,{title:t("取消"),icon:"close",onClick:function(){c({context:"",filename:""}),n?.close?.()}},1),(0,d.jsx)("title",{children:n.filename},2)]}),(0,d.jsx)("div",{className:"md-context ",children:(0,d.jsx)(r,{context:n.context})})]})}}}]);