feat: migrate workbench to React

This commit is contained in:
que01 committed 2026-08-26 15:01:07 +08:00
1 parent f15e69c868
commit 3ddb33e321
48 files changed
+16748 -1509

No files matched your search

+223
View File
@@ -0,0 +1,223 @@
:root {
font-family: system-ui, sans-serif;
color: #202523;
background: #eef1ef;
}
* {
box-sizing: border-box;
}
body {
margin: 0;
}
header {
height: 50px;
display: flex;
gap: 12px;
align-items: center;
padding: 0 16px;
background: #183a32;
color: white;
}
header span {
color: #c9d8d2;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.dirty {
color: #ffe08a;
font-weight: 700;
}
.scene {
margin-left: auto;
white-space: nowrap;
}
main {
display: grid;
grid-template-columns: 260px minmax(0, 1fr) 320px;
height: calc(100vh - 50px);
}
aside {
overflow: auto;
background: white;
padding: 16px;
}
.issues {
border-right: 1px solid #d5dfda;
}
.inspector {
border-left: 1px solid #d5dfda;
}
.map {
min-height: 400px;
background: #d7e2de;
}
.button {
display: inline-flex;
align-items: center;
gap: 5px;
border: 1px solid #82988f;
background: white;
color: #1d392f;
padding: 7px 10px;
border-radius: 3px;
cursor: pointer;
text-decoration: none;
font: inherit;
}
.button:disabled {
opacity: 0.55;
cursor: default;
}
header .button {
white-space: nowrap;
}
h1 {
font-size: 16px;
margin: 0 0 8px;
}
h2 {
font-size: 14px;
margin: 12px 0 8px;
}
label,
output {
display: block;
margin: 10px 0;
}
input[type='number'] {
display: block;
width: 100%;
padding: 7px;
border: 1px solid #aab8b2;
}
dl {
display: grid;
grid-template-columns: 1fr auto;
gap: 5px 10px;
margin: 0;
}
dt {
color: #52615b;
}
dd {
margin: 0;
}
hr {
border: 0;
border-top: 1px solid #dde4e1;
margin: 16px 0;
}
ul {
list-style: none;
padding: 0;
margin: 0;
}
.issues li .button {
width: 100%;
text-align: left;
margin: 4px 0;
background: #fff7e5;
border-color: #e7c67b;
}
.segmented {
display: flex;
}
.segmented .button {
flex: 1;
border-radius: 0;
padding: 6px 4px;
}
.segmented .active {
background: #286956;
border-color: #286956;
color: white;
}
pre {
white-space: pre-wrap;
overflow-wrap: anywhere;
color: #52615b;
}
.import-screen {
min-height: 100vh;
display: grid;
place-items: center;
padding: 24px;
}
.import-screen form {
width: min(460px, 100%);
background: white;
padding: 28px;
box-shadow: 0 8px 30px #0003;
}
.import-screen input {
margin: 18px 0;
}
@media (max-width: 900px) {
header {
height: auto;
min-height: 50px;
flex-wrap: wrap;
padding-block: 8px;
}
main {
grid-template-columns: minmax(0, 1fr);
height: calc(100vh - 66px);
}
.issues {
display: none;
}
.inspector {
position: absolute;
right: 0;
bottom: 0;
width: min(360px, 100%);
max-height: 55vh;
border-top: 1px solid #d5dfda;
}
}
.overview-grid {
display: grid;
grid-template-columns: repeat(2, minmax(0, 1fr));
gap: 8px;
}
.overview-grid div,
.overview-status,
.overview-diagnostics {
border: 1px solid #dce5e1;
padding: 7px;
background: #f8fbfa;
}
.overview-grid span,
.overview-status span,
.overview-diagnostics > span {
display: block;
color: #52615b;
font-size: 12px;
}
.overview-grid strong {
display: block;
margin-top: 2px;
font-size: 16px;
font-variant-numeric: tabular-nums;
}
.overview-status {
display: flex;
justify-content: space-between;
margin-top: 8px;
}
.overview-diagnostics {
display: flex;
flex-wrap: wrap;
gap: 6px;
margin-top: 8px;
}
.overview-diagnostics > span {
width: 100%;
}
.overview-diagnostics strong {
background: #fff4dc;
color: #7c5200;
padding: 2px 5px;
font-size: 12px;
}