most-box 0.0.2 → 0.0.6
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.
- package/LICENSE +21 -21
- package/README.md +222 -156
- package/electron/main.js +67 -0
- package/out/404/index.html +15 -0
- package/out/404.html +15 -0
- package/out/__next.__PAGE__.txt +11 -0
- package/out/__next._full.txt +21 -0
- package/out/__next._head.txt +5 -0
- package/out/__next._index.txt +7 -0
- package/out/__next._tree.txt +4 -0
- package/out/_next/static/alUUgRz4oMlw4EtULOYfV/_buildManifest.js +11 -0
- package/out/_next/static/alUUgRz4oMlw4EtULOYfV/_clientMiddlewareManifest.js +1 -0
- package/out/_next/static/alUUgRz4oMlw4EtULOYfV/_ssgManifest.js +1 -0
- package/out/_next/static/chunks/00s106sbq8t9v.js +1 -0
- package/out/_next/static/chunks/0174xh3wfsjm1.js +2 -0
- package/out/_next/static/chunks/01xlw8hd842-c.js +1 -0
- package/out/_next/static/chunks/02ou_44kkb5dz.js +1 -0
- package/out/_next/static/chunks/02pr2b_eos3~h.js +1 -0
- package/out/_next/static/chunks/03~yq9q893hmn.js +1 -0
- package/out/_next/static/chunks/07lsjkarm1p9f.css +1 -0
- package/out/_next/static/chunks/0_-ccbcyh_o30.css +1 -0
- package/out/_next/static/chunks/0_b839~4.q324.js +1 -0
- package/out/_next/static/chunks/0_sna3wdypbzr.js +1 -0
- package/out/_next/static/chunks/0_wia9ofmsi1c.css +2 -0
- package/out/_next/static/chunks/0byj66sc-9o0g.js +1 -0
- package/out/_next/static/chunks/0bzupvr5gt3k9.js +31 -0
- package/out/_next/static/chunks/0d3shmwh5_nmn.js +1 -0
- package/out/_next/static/chunks/0du450zbk4kq_.js +1 -0
- package/out/_next/static/chunks/0e_h0d3ekzks8.css +1 -0
- package/out/_next/static/chunks/0ho~log~~-jwp.css +1 -0
- package/out/_next/static/chunks/0ibjp~7qzxfjv.js +5 -0
- package/out/_next/static/chunks/0imvn_arv36xt.css +1 -0
- package/out/_next/static/chunks/0j9~17180dl8j.js +1 -0
- package/out/_next/static/chunks/0ji.28mehrvdp.js +1 -0
- package/out/_next/static/chunks/0jl~j62iz2uvr.js +1 -0
- package/out/_next/static/chunks/0nct0fubs64d-.js +1 -0
- package/out/_next/static/chunks/0n~dq4kpx9xxx.js +1 -0
- package/out/_next/static/chunks/0pqt~8bl3ukh4.js +4 -0
- package/out/_next/static/chunks/0q7ck9f.90_i9.js +1 -0
- package/out/_next/static/chunks/0qub_r0x_r-e9.css +1 -0
- package/out/_next/static/chunks/0rr4gwjp9z~9a.js +1 -0
- package/out/_next/static/chunks/0ry.po.a~iu4p.js +1 -0
- package/out/_next/static/chunks/0slwj0c46k5cu.js +1 -0
- package/out/_next/static/chunks/0sorqk.oc6b7j.css +1 -0
- package/out/_next/static/chunks/11dalasm30arx.js +1 -0
- package/out/_next/static/chunks/turbopack-0a_g3u0ud~jb8.js +1 -0
- package/out/_not-found/__next._full.txt +20 -0
- package/out/_not-found/__next._head.txt +5 -0
- package/out/_not-found/__next._index.txt +7 -0
- package/out/_not-found/__next._not-found.__PAGE__.txt +9 -0
- package/out/_not-found/__next._not-found.txt +5 -0
- package/out/_not-found/__next._tree.txt +2 -0
- package/out/_not-found/index.html +15 -0
- package/out/_not-found/index.txt +20 -0
- package/out/app/__next._full.txt +20 -0
- package/out/app/__next._head.txt +5 -0
- package/out/app/__next._index.txt +7 -0
- package/out/app/__next._tree.txt +2 -0
- package/out/app/__next.app.__PAGE__.txt +9 -0
- package/out/app/__next.app.txt +5 -0
- package/out/app/index.html +15 -0
- package/out/app/index.txt +20 -0
- package/out/changelog/__next._full.txt +22 -0
- package/out/changelog/__next._head.txt +5 -0
- package/out/changelog/__next._index.txt +7 -0
- package/out/changelog/__next._tree.txt +3 -0
- package/out/changelog/__next.changelog.__PAGE__.txt +10 -0
- package/out/changelog/__next.changelog.txt +5 -0
- package/out/changelog/index.html +15 -0
- package/out/changelog/index.txt +22 -0
- package/out/chat/__next._full.txt +21 -0
- package/out/chat/__next._head.txt +5 -0
- package/out/chat/__next._index.txt +7 -0
- package/out/chat/__next._tree.txt +3 -0
- package/out/chat/__next.chat.__PAGE__.txt +9 -0
- package/out/chat/__next.chat.txt +6 -0
- package/out/chat/index.html +15 -0
- package/out/chat/index.txt +21 -0
- package/out/docs/__next._full.txt +22 -0
- package/out/docs/__next._head.txt +5 -0
- package/out/docs/__next._index.txt +7 -0
- package/out/docs/__next._tree.txt +3 -0
- package/out/docs/__next.docs.__PAGE__.txt +10 -0
- package/out/docs/__next.docs.txt +5 -0
- package/out/docs/getting-started/__next._full.txt +22 -0
- package/out/docs/getting-started/__next._head.txt +5 -0
- package/out/docs/getting-started/__next._index.txt +7 -0
- package/out/docs/getting-started/__next._tree.txt +3 -0
- package/out/docs/getting-started/__next.docs.getting-started.__PAGE__.txt +10 -0
- package/out/docs/getting-started/__next.docs.getting-started.txt +5 -0
- package/out/docs/getting-started/__next.docs.txt +5 -0
- package/out/docs/getting-started/index.html +15 -0
- package/out/docs/getting-started/index.txt +22 -0
- package/out/docs/index.html +15 -0
- package/out/docs/index.txt +22 -0
- package/out/download/__next._full.txt +34 -0
- package/out/download/__next._head.txt +5 -0
- package/out/download/__next._index.txt +7 -0
- package/out/download/__next._tree.txt +4 -0
- package/out/download/__next.download.__PAGE__.txt +16 -0
- package/out/download/__next.download.txt +5 -0
- package/out/download/index.html +15 -0
- package/out/download/index.txt +34 -0
- package/out/favicon.ico +0 -0
- package/out/fonts/jetbrains-mono-latin-400-normal.woff2 +0 -0
- package/out/fonts/jetbrains-mono-latin-500-normal.woff2 +0 -0
- package/out/fonts/jetbrains-mono-latin-600-normal.woff2 +0 -0
- package/out/fonts/jetbrains-mono-latin-700-normal.woff2 +0 -0
- package/out/index.html +15 -0
- package/out/index.txt +21 -0
- package/out/lottery/__next._full.txt +21 -0
- package/out/lottery/__next._head.txt +5 -0
- package/out/lottery/__next._index.txt +7 -0
- package/out/lottery/__next._tree.txt +3 -0
- package/out/lottery/__next.lottery.__PAGE__.txt +9 -0
- package/out/lottery/__next.lottery.txt +6 -0
- package/out/lottery/index.html +15 -0
- package/out/lottery/index.txt +21 -0
- package/out/ping/__next._full.txt +21 -0
- package/out/ping/__next._head.txt +5 -0
- package/out/ping/__next._index.txt +7 -0
- package/out/ping/__next._tree.txt +4 -0
- package/out/ping/__next.ping.__PAGE__.txt +10 -0
- package/out/ping/__next.ping.txt +5 -0
- package/out/ping/index.html +15 -0
- package/out/ping/index.txt +21 -0
- package/out/pwa-512x512.png +0 -0
- package/out/web3/__next._full.txt +21 -0
- package/out/web3/__next._head.txt +5 -0
- package/out/web3/__next._index.txt +7 -0
- package/out/web3/__next._tree.txt +3 -0
- package/out/web3/__next.web3.__PAGE__.txt +9 -0
- package/out/web3/__next.web3.txt +6 -0
- package/out/web3/ed25519/__next._full.txt +20 -0
- package/out/web3/ed25519/__next._head.txt +5 -0
- package/out/web3/ed25519/__next._index.txt +7 -0
- package/out/web3/ed25519/__next._tree.txt +3 -0
- package/out/web3/ed25519/__next.web3.ed25519.__PAGE__.txt +6 -0
- package/out/web3/ed25519/__next.web3.ed25519.txt +5 -0
- package/out/web3/ed25519/__next.web3.txt +6 -0
- package/out/web3/ed25519/index.html +1 -0
- package/out/web3/ed25519/index.txt +20 -0
- package/out/web3/index.html +15 -0
- package/out/web3/index.txt +21 -0
- package/out/web3/tools/__next._full.txt +20 -0
- package/out/web3/tools/__next._head.txt +5 -0
- package/out/web3/tools/__next._index.txt +7 -0
- package/out/web3/tools/__next._tree.txt +3 -0
- package/out/web3/tools/__next.web3.tools.__PAGE__.txt +6 -0
- package/out/web3/tools/__next.web3.tools.txt +5 -0
- package/out/web3/tools/__next.web3.txt +6 -0
- package/out/web3/tools/index.html +1 -0
- package/out/web3/tools/index.txt +20 -0
- package/package.json +162 -48
- package/public/fonts/jetbrains-mono-latin-400-normal.woff2 +0 -0
- package/public/fonts/jetbrains-mono-latin-500-normal.woff2 +0 -0
- package/public/fonts/jetbrains-mono-latin-600-normal.woff2 +0 -0
- package/public/fonts/jetbrains-mono-latin-700-normal.woff2 +0 -0
- package/public/pwa-512x512.png +0 -0
- package/server/cli.js +3 -0
- package/server/index.js +963 -0
- package/{src → server/src}/config.js +51 -39
- package/{src → server/src}/core/cid.js +157 -146
- package/{src → server/src}/index.js +1950 -1201
- package/server/src/utils/api.js +68 -0
- package/server/src/utils/avatar.js +11 -0
- package/{src → server/src}/utils/errors.js +70 -66
- package/server/src/utils/mostWallet.js +42 -0
- package/server/src/utils/mp.js +117 -0
- package/{src → server/src}/utils/security.js +173 -169
- package/server/src/utils/userIdentity.js +93 -0
- package/build.mjs +0 -40
- package/cli.js +0 -2
- package/public/app.css +0 -1519
- package/public/app.jsx +0 -1543
- package/public/bundle.css +0 -1
- package/public/bundle.js +0 -107
- package/public/error-boundary.jsx +0 -50
- package/public/index.html +0 -16
- package/public/index.jsx +0 -20
- package/server.js +0 -698
|
@@ -1,50 +0,0 @@
|
|
|
1
|
-
import React from 'react'
|
|
2
|
-
|
|
3
|
-
export class ErrorBoundary extends React.Component {
|
|
4
|
-
constructor(props) {
|
|
5
|
-
super(props)
|
|
6
|
-
this.state = { hasError: false, error: null }
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
static getDerivedStateFromError(error) {
|
|
10
|
-
return { hasError: true, error }
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
componentDidCatch(error, info) {
|
|
14
|
-
console.error('[ErrorBoundary]', error, info)
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
handleReload = () => {
|
|
18
|
-
window.location.reload()
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
render() {
|
|
22
|
-
if (this.state.hasError) {
|
|
23
|
-
return (
|
|
24
|
-
<div style={{
|
|
25
|
-
display: 'flex', flexDirection: 'column', alignItems: 'center',
|
|
26
|
-
justifyContent: 'center', minHeight: '100vh', padding: 32,
|
|
27
|
-
background: '#f8fafc', fontFamily: 'system-ui'
|
|
28
|
-
}}>
|
|
29
|
-
<h1 style={{ fontSize: 20, fontWeight: 600, marginBottom: 8, color: '#1e293b' }}>
|
|
30
|
-
出错了
|
|
31
|
-
</h1>
|
|
32
|
-
<p style={{ color: '#64748b', marginBottom: 24, textAlign: 'center', maxWidth: 400 }}>
|
|
33
|
-
发生了意外错误,请尝试重新加载页面
|
|
34
|
-
</p>
|
|
35
|
-
<button
|
|
36
|
-
onClick={this.handleReload}
|
|
37
|
-
style={{
|
|
38
|
-
padding: '10px 24px', borderRadius: 8, border: 'none',
|
|
39
|
-
background: '#3b82f6', color: '#fff', fontSize: 14,
|
|
40
|
-
cursor: 'pointer'
|
|
41
|
-
}}
|
|
42
|
-
>
|
|
43
|
-
重新加载
|
|
44
|
-
</button>
|
|
45
|
-
</div>
|
|
46
|
-
)
|
|
47
|
-
}
|
|
48
|
-
return this.props.children
|
|
49
|
-
}
|
|
50
|
-
}
|
package/public/index.html
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
<!doctype html>
|
|
2
|
-
<html lang="zh-CN" data-theme="light">
|
|
3
|
-
|
|
4
|
-
<head>
|
|
5
|
-
<meta charset="UTF-8" />
|
|
6
|
-
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
|
|
7
|
-
<title>MostBox 文件管理</title>
|
|
8
|
-
<link rel="stylesheet" href="./bundle.css" />
|
|
9
|
-
</head>
|
|
10
|
-
|
|
11
|
-
<body>
|
|
12
|
-
<div id="root"></div>
|
|
13
|
-
<script type="module" src="./bundle.js"></script>
|
|
14
|
-
</body>
|
|
15
|
-
|
|
16
|
-
</html>
|
package/public/index.jsx
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { createRoot } from 'react-dom/client'
|
|
2
|
-
import React from 'react'
|
|
3
|
-
import App from './app.jsx'
|
|
4
|
-
import { ErrorBoundary } from './error-boundary.jsx'
|
|
5
|
-
import './app.css'
|
|
6
|
-
|
|
7
|
-
window.onerror = (message, source, lineno, colno, error) => {
|
|
8
|
-
console.error('[Global Error]', { message, source, lineno, colno, error })
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
window.onunhandledrejection = (event) => {
|
|
12
|
-
console.error('[Unhandled Promise Rejection]', event.reason)
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
const root = createRoot(document.getElementById('root'))
|
|
16
|
-
root.render(
|
|
17
|
-
<ErrorBoundary>
|
|
18
|
-
<App />
|
|
19
|
-
</ErrorBoundary>
|
|
20
|
-
)
|