- Node.js backend server - Frontend application - Backup script - Project specification Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 line
9.7 KiB
JavaScript
1 line
9.7 KiB
JavaScript
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[888],{1118:function(e,r,t){(window.__NEXT_P=window.__NEXT_P||[]).push(["/_app",function(){return t(4926)}])},8846:function(e,r,t){"use strict";t.d(r,{N:function(){return c},W:function(){return l}});var o=t(5893),n=t(7294),s=t(9415);let i=(0,n.createContext)(null);function l(e){let{children:r}=e,[t,l]=(0,n.useState)(null),c=(0,n.useCallback)(e=>new Promise(r=>{l({title:e.title||"请确认操作",description:e.description||"",confirmText:e.confirmText||"确认",cancelText:e.cancelText||"取消",tone:e.tone||"danger",resolve:r})}),[]),a=(0,n.useCallback)(e=>{l(r=>(null==r||r.resolve(e),null))},[]),d=(0,n.useMemo)(()=>({confirm:c}),[c]);return(0,o.jsxs)(i.Provider,{value:d,children:[r,t?(0,o.jsx)("div",{className:"modal-overlay modal-overlay--center",onClick:()=>a(!1),children:(0,o.jsxs)("div",{className:"confirm-card",onClick:e=>e.stopPropagation(),role:"dialog","aria-modal":"true","aria-labelledby":"confirm-title",children:[(0,o.jsx)("div",{className:"confirm-card__icon confirm-card__icon--".concat(t.tone),children:(0,o.jsx)(s.J,{name:"danger"===t.tone?"trash":"info",size:18})}),(0,o.jsxs)("div",{className:"confirm-card__body",children:[(0,o.jsx)("h2",{id:"confirm-title",children:t.title}),t.description?(0,o.jsx)("p",{children:t.description}):null]}),(0,o.jsxs)("div",{className:"confirm-card__actions",children:[(0,o.jsx)("button",{type:"button",className:"btn btn-secondary",onClick:()=>a(!1),children:t.cancelText}),(0,o.jsx)("button",{type:"button",className:"btn ".concat("danger"===t.tone?"btn-danger":"btn-primary"),onClick:()=>a(!0),children:t.confirmText})]})]})}):null]})}function c(){let e=(0,n.useContext)(i);if(!e)throw Error("useConfirm must be used within ConfirmProvider");return e}},5546:function(e,r,t){"use strict";t.d(r,{V:function(){return l},p:function(){return c}});var o=t(5893),n=t(7294),s=t(9415);let i=(0,n.createContext)(null);function l(e){let{children:r}=e,[t,l]=(0,n.useState)([]),c=(0,n.useRef)(new Map),a=(0,n.useCallback)(e=>{let r=c.current.get(e);r&&(clearTimeout(r),c.current.delete(e)),l(r=>r.filter(r=>r.id!==e))},[]),d=(0,n.useCallback)(function(e){var r;let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o="".concat(Date.now(),"-").concat(Math.random()),n={id:o,message:e,tone:t.tone||"info"};l(e=>[...e,n]);let s=setTimeout(()=>a(o),null!==(r=t.duration)&&void 0!==r?r:2600);return c.current.set(o,s),o},[a]),u=(0,n.useMemo)(()=>({showToast:d,removeToast:a}),[d,a]);return(0,o.jsxs)(i.Provider,{value:u,children:[r,(0,o.jsx)("div",{className:"toast-stack","aria-live":"polite","aria-atomic":"true",children:t.map(e=>(0,o.jsxs)("div",{className:"toast toast--".concat(e.tone),children:[(0,o.jsx)("span",{className:"toast__icon",children:(0,o.jsx)(s.J,{name:"success"===e.tone?"check":"error"===e.tone?"close":"info",size:16})}),(0,o.jsx)("span",{className:"toast__message",children:e.message}),(0,o.jsx)("button",{type:"button",className:"icon-button icon-button--ghost toast__close","aria-label":"关闭提示",onClick:()=>a(e.id),children:(0,o.jsx)(s.J,{name:"close",size:16})})]},e.id))})]})}function c(){let e=(0,n.useContext)(i);if(!e)throw Error("useToast must be used within ToastProvider");return e}},9415:function(e,r,t){"use strict";t.d(r,{J:function(){return i}});var o=t(5893),n=t(7294);let s={home:(0,o.jsx)("path",{d:"M3 10.5 12 3l9 7.5V20a1 1 0 0 1-1 1h-5.5v-6h-5v6H4a1 1 0 0 1-1-1v-9.5Z",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),chart:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M4 20h16",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M7 16v-4",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M12 16V8",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M17 16v-7",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]}),repeat:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M17 3l4 4-4 4",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),(0,o.jsx)("path",{d:"M3 7h18",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M7 21l-4-4 4-4",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),(0,o.jsx)("path",{d:"M21 17H3",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]}),tags:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M11 4H5a2 2 0 0 0-2 2v6l8.5 8.5a2.1 2.1 0 0 0 3 0l6-6a2.1 2.1 0 0 0 0-3L12 4Z",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinejoin:"round"}),(0,o.jsx)("circle",{cx:"7.5",cy:"8.5",r:"1.2",fill:"currentColor"})]}),settings:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M12 8.5A3.5 3.5 0 1 0 12 15.5A3.5 3.5 0 1 0 12 8.5Z",fill:"none",stroke:"currentColor",strokeWidth:"1.8"}),(0,o.jsx)("path",{d:"M19.4 15a1 1 0 0 0 .2 1.1l.1.1a2 2 0 0 1-2.8 2.8l-.1-.1a1 1 0 0 0-1.1-.2 1 1 0 0 0-.6.9V20a2 2 0 0 1-4 0v-.2a1 1 0 0 0-.6-.9 1 1 0 0 0-1.1.2l-.1.1a2 2 0 1 1-2.8-2.8l.1-.1a1 1 0 0 0 .2-1.1 1 1 0 0 0-.9-.6H4a2 2 0 0 1 0-4h.2a1 1 0 0 0 .9-.6 1 1 0 0 0-.2-1.1l-.1-.1a2 2 0 1 1 2.8-2.8l.1.1a1 1 0 0 0 1.1.2 1 1 0 0 0 .6-.9V4a2 2 0 0 1 4 0v.2a1 1 0 0 0 .6.9 1 1 0 0 0 1.1-.2l.1-.1a2 2 0 1 1 2.8 2.8l-.1.1a1 1 0 0 0-.2 1.1 1 1 0 0 0 .9.6H20a2 2 0 0 1 0 4h-.2a1 1 0 0 0-.4 1Z",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"})]}),search:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("circle",{cx:"11",cy:"11",r:"6.5",fill:"none",stroke:"currentColor",strokeWidth:"1.8"}),(0,o.jsx)("path",{d:"m16 16 4.5 4.5",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]}),plus:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M12 5v14",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M5 12h14",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]}),chevronLeft:(0,o.jsx)("path",{d:"m14.5 6-5 6 5 6",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),chevronRight:(0,o.jsx)("path",{d:"m9.5 6 5 6-5 6",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),close:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M6 6l12 12",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M18 6 6 18",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]}),trash:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M4 7h16",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M9 4h6",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M7 7l1 12a1 1 0 0 0 1 .9h6a1 1 0 0 0 1-.9l1-12",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),(0,o.jsx)("path",{d:"M10 11v5",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"M14 11v5",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]}),logout:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M10 5H6a2 2 0 0 0-2 2v10a2 2 0 0 0 2 2h4",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),(0,o.jsx)("path",{d:"M14 8l5 4-5 4",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),(0,o.jsx)("path",{d:"M19 12H9",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]}),download:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M12 4v10",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"m8 10 4 4 4-4",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),(0,o.jsx)("path",{d:"M5 19h14",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]}),upload:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M12 20V10",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("path",{d:"m8 14 4-4 4 4",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),(0,o.jsx)("path",{d:"M5 5h14",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]}),check:(0,o.jsx)("path",{d:"m5 12 4.2 4.2L19 7",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",strokeLinejoin:"round"}),info:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("circle",{cx:"12",cy:"12",r:"9",fill:"none",stroke:"currentColor",strokeWidth:"1.8"}),(0,o.jsx)("path",{d:"M12 10v5",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"}),(0,o.jsx)("circle",{cx:"12",cy:"7.25",r:"1",fill:"currentColor"})]}),spinner:(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)("path",{d:"M12 3a9 9 0 1 1-6.36 2.64",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round",opacity:"0.28"}),(0,o.jsx)("path",{d:"M5.64 5.64A9 9 0 0 1 12 3",fill:"none",stroke:"currentColor",strokeWidth:"1.8",strokeLinecap:"round"})]})};function i(e){let{name:r,size:t=20,className:o="",title:i}=e;return(0,n.createElement)("svg",{viewBox:"0 0 24 24",width:t,height:t,className:o,"aria-hidden":i?void 0:"true",role:i?"img":"presentation",fill:"none"},i?(0,n.createElement)("title",null,i):null,s[r]||s.info)}},4926:function(e,r,t){"use strict";t.r(r),t.d(r,{default:function(){return i}});var o=t(5893);t(3434);var n=t(5546),s=t(8846);function i(e){let{Component:r,pageProps:t}=e;return(0,o.jsx)(s.W,{children:(0,o.jsx)(n.V,{children:(0,o.jsx)(r,{...t})})})}},3434:function(){}},function(e){var r=function(r){return e(e.s=r)};e.O(0,[774,179],function(){return r(1118),r(3079)}),_N_E=e.O()}]); |