@yuku123/z-graph-component 0.0.0-stage → 0.1.0
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/dist/GraphApp-C6N6khIq.js +1514 -0
- package/dist/index.js +11 -0
- package/dist/pages.js +2176 -0
- package/dist/z-graph-component.css +1 -0
- package/package.json +44 -4
- package/README.md +0 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
*{box-sizing:border-box}html,body,#root{margin:0;padding:0;height:100%;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,PingFang SC,Microsoft YaHei,sans-serif;background:#0f172a;color:#e2e8f0}a{color:#93c5fd}button{font:inherit;color:inherit;background:#1e293b;border:1px solid #334155;padding:6px 14px;border-radius:6px;cursor:pointer;transition:background .15s}button:hover{background:#334155}button:disabled{opacity:.5;cursor:not-allowed}button.primary{background:#3b82f6;border-color:#3b82f6}button.primary:hover{background:#2563eb}button.danger{background:#ef4444;border-color:#ef4444}button.danger:hover{background:#dc2626}input,select,textarea{font:inherit;color:#e2e8f0;background:#1e293b;border:1px solid #334155;padding:6px 10px;border-radius:6px}textarea{resize:vertical}input:focus,select:focus,textarea:focus{outline:none;border-color:#3b82f6}.layout{display:grid;grid-template-columns:220px 1fr;height:100%}.sidebar{background:#0b1220;border-right:1px solid #1e293b;padding:16px;display:flex;flex-direction:column;gap:16px}.sidebar .brand{display:flex;align-items:center;gap:10px;font-weight:700;font-size:18px;color:#f8fafc}.sidebar .brand img{width:32px;height:32px}.sidebar nav{display:flex;flex-direction:column;gap:4px}.sidebar nav button{text-align:left;background:transparent;border:none;padding:8px 12px;border-radius:6px}.sidebar nav button:hover{background:#1e293b}.sidebar nav button.active{background:#1e3a8a;color:#bfdbfe}.sidebar .server-box{background:#1e293b;border:1px solid #334155;border-radius:6px;padding:10px}.sidebar .server-box label{font-size:12px;color:#94a3b8}.sidebar .server-box input{width:100%;margin-top:4px}.main{display:flex;flex-direction:column;overflow:hidden}.main header{padding:16px 24px;border-bottom:1px solid #1e293b;display:flex;justify-content:space-between;align-items:center;background:#0b1220}.main header h1{margin:0;font-size:18px}.main header .status{font-size:13px;color:#94a3b8}.main .content{flex:1;overflow:auto;padding:20px 24px}.card{background:#0b1220;border:1px solid #1e293b;border-radius:8px;padding:16px;margin-bottom:16px}.card h2{margin-top:0;font-size:16px;color:#f8fafc}.card .muted{color:#94a3b8;font-size:13px}.kpi-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(180px,1fr));gap:12px;margin-bottom:16px}.kpi{background:#0b1220;border:1px solid #1e293b;border-radius:8px;padding:14px 16px;display:flex;align-items:center;gap:12px}.kpi-icon{width:40px;height:40px;border-radius:8px;display:flex;align-items:center;justify-content:center;font-weight:700;font-size:16px;flex-shrink:0}.kpi-content{display:flex;flex-direction:column}.kpi-value{font-size:24px;font-weight:600;color:#f8fafc}.kpi-label{font-size:12px;color:#94a3b8;text-transform:uppercase;letter-spacing:.05em}.row-2{display:grid;grid-template-columns:1fr 1fr;gap:16px;margin-bottom:16px}@media(max-width:960px){.row-2{grid-template-columns:1fr}}.action-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px;margin-top:12px}.action-card{background:#1e293b;border:1px solid #334155;border-top:3px solid;border-radius:6px;padding:12px;cursor:default}.action-title{font-size:14px;font-weight:600;color:#f8fafc}.action-desc{font-size:12px;color:#94a3b8;margin-top:4px}.chip-list{display:flex;flex-wrap:wrap;gap:6px}.chip{display:inline-flex;align-items:center;padding:4px 10px;border-radius:4px;font-size:12px;background:#1e293b;border:1px solid #334155;color:#e2e8f0;cursor:pointer;transition:all .15s}.chip:hover{background:#334155}.chip.tag-chip{border-color:#3b82f6;color:#93c5fd}.chip.edge-chip{border-color:#34d399;color:#6ee7b7}.chip.ddl-chip{border-color:#a78bfa;color:#c4b5fd}.chip.ddl-chip:hover{background:#3b2f6b}pre.error{color:#fca5a5;margin:0;white-space:pre-wrap;word-break:break-all}pre.results{color:#93c5fd;margin:0;white-space:pre-wrap;word-break:break-all}.history-panel{margin-top:10px;border:1px solid #334155;border-radius:6px;max-height:240px;overflow-y:auto}.history-item{display:flex;align-items:center;justify-content:space-between;padding:6px 10px;cursor:pointer;border-bottom:1px solid #1e293b;transition:background .1s}.history-item:last-child{border-bottom:none}.history-item:hover{background:#1e293b}.history-cypher{flex:1;font-size:12px;color:#93c5fd;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.history-meta{display:flex;gap:6px;align-items:center;margin-left:8px;flex-shrink:0}.toolbar{display:flex;gap:8px;flex-wrap:wrap;align-items:center}.tabs{display:flex;gap:8px;border-bottom:1px solid #1e293b;margin-bottom:16px}.tabs button{background:transparent;border:none;padding:10px 16px;border-bottom:2px solid transparent;border-radius:0;color:#94a3b8}.tabs button:hover{color:#e2e8f0}.tabs button.active{color:#93c5fd;border-bottom-color:#3b82f6}table{width:100%;border-collapse:collapse;font-size:13px}th,td{text-align:left;padding:8px 12px;border-bottom:1px solid #1e293b}th{color:#94a3b8;font-weight:500}tr:hover{background:#111827}td.mono,code.mono{font-family:SFMono-Regular,Menlo,Consolas,monospace}.editor{display:grid;grid-template-rows:auto 1fr auto;gap:12px;height:100%}.editor textarea{min-height:200px;font-family:SFMono-Regular,Menlo,Consolas,monospace;font-size:13px;line-height:1.5}.editor .editor-toolbar{display:flex;gap:8px}.results{background:#0b1220;border:1px solid #1e293b;border-radius:8px;padding:12px;max-height:400px;overflow:auto;font-family:SFMono-Regular,Menlo,Consolas,monospace;font-size:13px}.results pre{margin:0;white-space:pre-wrap}.results .error{color:#fca5a5}.empty{padding:40px;text-align:center;color:#64748b}.tag{display:inline-block;padding:2px 8px;border-radius:4px;font-size:11px;font-weight:600;background:#1e3a8a;color:#bfdbfe}.tag.alt{background:#5b21b6;color:#ddd6fe}.tag.ok{background:#064e3b;color:#a7f3d0}.tag.warn{background:#78350f;color:#fde68a}.error-banner{background:#7f1d1d;border:1px solid #b91c1c;border-radius:6px;padding:10px 12px;margin-bottom:12px;color:#fecaca}.help{font-size:12px;color:#94a3b8;margin-top:4px}.hl-keyword{color:#c084fc;font-weight:600}.hl-string{color:#86efac}.hl-number{color:#fbbf24}.hl-comment{color:#64748b;font-style:italic}.hl-builtin{color:#67e8f9}.hl-function{color:#93c5fd}.hl-op{color:#f87171}.cypher-editor-wrap{margin-top:12px}.api-endpoint-card{padding:0;overflow:hidden}.api-endpoint-header{display:flex;align-items:center;gap:10px;padding:12px 16px;cursor:pointer;transition:background .1s}.api-endpoint-header:hover{background:#111827}.api-method{padding:3px 8px;border-radius:4px;font-size:11px;font-weight:700;text-transform:uppercase;letter-spacing:.05em}.api-method.get{background:#166534;color:#86efac}.api-method.post{background:#1e3a8a;color:#93c5fd}.api-path{font-size:13px;color:#e2e8f0}.api-name{font-size:13px;color:#94a3b8}.api-expand{font-size:12px;color:#64748b}.api-endpoint-detail{padding:0 16px 16px}.api-endpoint-detail h3{font-size:13px;color:#94a3b8;margin:12px 0 6px;text-transform:uppercase;letter-spacing:.05em}.status-dot{width:8px;height:8px;border-radius:50%;display:inline-block;flex-shrink:0}.status-dot.ok{background:#34d399;box-shadow:0 0 6px #34d399}.status-dot.down{background:#ef4444;box-shadow:0 0 6px #ef4444}.metrics-box{font-size:12px}.metrics-grid{display:grid;grid-template-columns:1fr 1fr;gap:8px;margin-top:8px}.metric-item{display:flex;flex-direction:column;gap:2px}.metric-value{font-size:14px;font-weight:600;color:#e2e8f0;font-family:SFMono-Regular,Menlo,Consolas,monospace}.metric-value.error{color:#fca5a5}.metric-label{font-size:10px;color:#64748b;text-transform:uppercase;letter-spacing:.05em}.metrics-footer{display:flex;justify-content:space-between;margin-top:8px;padding-top:8px;border-top:1px solid #1e293b;font-size:11px;color:#64748b}.log-table-wrap{max-height:600px;overflow-y:auto}.log-table{font-size:12px;table-layout:fixed}.log-table th{position:sticky;top:0;background:#0b1220;z-index:1;padding:8px 12px;font-size:11px;text-transform:uppercase;letter-spacing:.05em}.log-table td{padding:6px 12px;border-bottom:1px solid #111827}.log-row{cursor:pointer;transition:background .1s}.log-row:hover{background:#111827}.log-row.selected{background:#1e293b}.log-method{font-weight:600;font-family:SFMono-Regular,Menlo,Consolas,monospace;font-size:11px}.log-status{display:inline-block;padding:1px 6px;border-radius:3px;font-size:11px;font-weight:600;font-family:SFMono-Regular,Menlo,Consolas,monospace}.log-status-ok{background:#064e3b;color:#86efac}.log-status-warn{background:#78350f;color:#fde68a}.log-status-error{background:#7f1d1d;color:#fca5a5}
|
package/package.json
CHANGED
|
@@ -1,6 +1,46 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yuku123/z-graph-component",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"
|
|
5
|
-
"
|
|
6
|
-
|
|
3
|
+
"version": "0.1.0",
|
|
4
|
+
"description": "z-graph 可复用前端组件:图视图/分支/提交/Cypher 查询/Schema/日志(原 console 内化,lead 005 §9)",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"main": "./dist/index.js",
|
|
7
|
+
"module": "./dist/index.js",
|
|
8
|
+
"exports": {
|
|
9
|
+
".": "./dist/index.js",
|
|
10
|
+
"./pages": "./dist/pages.js",
|
|
11
|
+
"./style.css": "./dist/z-graph-component.css"
|
|
12
|
+
},
|
|
13
|
+
"files": [
|
|
14
|
+
"dist"
|
|
15
|
+
],
|
|
16
|
+
"scripts": {
|
|
17
|
+
"build": "vite build"
|
|
18
|
+
},
|
|
19
|
+
"dependencies": {
|
|
20
|
+
"@yuku123/z-frontend-common": "^1.1.1",
|
|
21
|
+
"@ant-design/pro-components": "^3.1.12-0",
|
|
22
|
+
"axios": "^1.16.1"
|
|
23
|
+
},
|
|
24
|
+
"peerDependencies": {
|
|
25
|
+
"@ant-design/icons": "^6.0.0",
|
|
26
|
+
"antd": "^6.0.0",
|
|
27
|
+
"react": "^19.0.0",
|
|
28
|
+
"react-dom": "^19.0.0",
|
|
29
|
+
"react-router-dom": "^7.0.0"
|
|
30
|
+
},
|
|
31
|
+
"devDependencies": {
|
|
32
|
+
"@ant-design/icons": "^6.1.0",
|
|
33
|
+
"@types/react": "^19.2.0",
|
|
34
|
+
"@types/react-dom": "^19.2.0",
|
|
35
|
+
"@vitejs/plugin-react": "^4.2.1",
|
|
36
|
+
"antd": "^6.3.3",
|
|
37
|
+
"react": "^19.2.0",
|
|
38
|
+
"react-dom": "^19.2.0",
|
|
39
|
+
"react-router-dom": "^7.13.1",
|
|
40
|
+
"vite": "^6.2.6"
|
|
41
|
+
},
|
|
42
|
+
"publishConfig": {
|
|
43
|
+
"registry": "https://registry.npmjs.org/",
|
|
44
|
+
"access": "public"
|
|
45
|
+
}
|
|
46
|
+
}
|
package/README.md
DELETED