Files

127 lines
13 KiB
CSS

:root { font: 13px/1.5 Inter, "Segoe UI", "Microsoft YaHei", sans-serif; color: #263442; background: #eef2f6; --blue: #1d6fb8; --border: #cfd8e3; --muted: #64748b; --gas: #8b134f; }
* { box-sizing: border-box; }
html, body { margin: 0; width: 100%; height: 100%; }
button, input { font: inherit; }
button { cursor: pointer; border: 1px solid #c2ccda; background: #fff; color: #263442; padding: 5px 10px; border-radius: 4px; }
button:hover { background: #eff5fa; }
button:disabled { cursor: default; opacity: .48; }
button:focus-visible, input:focus-visible, a:focus-visible, summary:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
a { color: #155a94; text-decoration: none; }
input[type=checkbox] { accent-color: var(--blue); }
.app-shell { height: 100dvh; display: grid; grid-template-rows: 62px 42px minmax(0,1fr) 28px; }
.topbar { display: grid; grid-template-columns: minmax(220px,1fr) auto minmax(240px,1fr); align-items: center; gap: 16px; padding: 8px 14px; border-bottom: 1px solid var(--border); background: #fff; }
.product strong { display: block; font-size: 15px; }
.product span { display: block; margin-top: 2px; font-size: 12px; color: var(--muted); }
.view-tabs { display: flex; height: 34px; border-bottom: 1px solid #bfcbd8; }
.view-tabs button { min-width: 68px; padding: 0 13px; border: 0; border-radius: 0; border-bottom: 2px solid transparent; color: #526172; background: transparent; }
.view-tabs button[aria-pressed=true] { border-bottom-color: var(--blue); color: #155a94; background: #eaf3fa; font-weight: 600; }
.topbar-actions { display: flex; justify-content: flex-end; align-items: center; gap: 13px; font-size: 12px; }
.editor-toolbar { display: flex; gap: 9px; align-items: center; padding: 5px 12px; border-bottom: 1px solid var(--border); background: #f5f7f9; }
.editor-toolbar button { font-size: 12px; background: transparent; border-color: transparent; }
.editor-toolbar button:hover { border-color: #c2ccda; background: #fff; }
.mode-marker { color: #155a94; font-size: 12px; font-weight: 600; }
.toolbar-separator { height: 22px; width: 1px; background: #d0d9e2; margin: 0 3px; }
.toolbar-check { display: flex; align-items: center; gap: 5px; font-size: 12px; cursor: pointer; }
.toolbar-end { margin-left: auto; display: flex; gap: 6px; align-items: center; font-size: 12px; color: var(--muted); }
.toolbar-end svg { stroke: currentColor; stroke-width: 1.2; fill: none; }
.workbench { display: grid; grid-template-columns: 230px 7px minmax(0,1fr) 7px 330px; min-height: 0; }
.palette { display: flex; flex-direction: column; min-height: 0; overflow: auto; background: #fff; }
.panel-title { display: flex; justify-content: space-between; align-items: center; gap: 8px; padding: 0 10px; min-height: 33px; background: #f2f4f6; border-bottom: 1px solid #c7cdd4; font-size: 12px; }
.panel-title span { font-size: 11px; color: var(--muted); }
.panel-title button { font-size: 11px; border: 0; background: transparent; padding: 3px; color: #155a94; }
.palette > .panel-title { background: #fff; padding: 12px 14px; min-height: 49px; border-bottom: 1px solid #e3e8ef; font-size: 13px; }
.palette-content { padding: 12px; }
.compat-filter { display: flex; align-items: center; gap: 4px; font-size: 11px; color: #526172; cursor: pointer; margin-bottom: 15px; }
.library-heading { color: #526172; font-size: 12px; margin-bottom: 10px; font-weight: 600; }
.palette-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 8px; }
.model-tile { display: grid; grid-template-rows: 39px 18px 15px; gap: 2px; padding: 7px 5px; place-items: center; min-width: 0; border: 1px solid #d6dee9; background: #fff; border-radius: 5px; }
.model-tile svg { width: 70px; height: 37px; color: var(--gas); }
.model-tile strong { font-size: 11px; line-height: 18px; }
.model-tile small { color: #66788c; font-size: 10px; line-height: 15px; }
.model-tile[aria-pressed=true] { border-color: #4f92c7; background: #eaf4fc; box-shadow: inset 0 0 0 1px #4f92c7; }
.model-tile:disabled { opacity: .4; background: #f5f6f7; }
.library-hint { font-size: 11px; color: var(--muted); margin-top: 12px; min-height: 33px; }
.section-heading { padding: 9px 13px; border-top: 1px solid #e3e8ef; border-bottom: 1px solid #e3e8ef; font-size: 12px; color: #475a6e; background: #f8fafc; }
.pipe-list { padding: 7px 0; }
.pipe-list button { display: grid; grid-template-columns: 8px 27px minmax(0,1fr); align-items: center; gap: 7px; width: 100%; border: 0; border-radius: 0; text-align: left; padding: 9px 14px; font-size: 12px; }
.pipe-list button[aria-pressed=true] { color: #155a94; background: #eaf3fa; }
.pipe-list .model-id { justify-self: end; font-size: 11px; color: #63788b; }
.state-dot { width: 6px; height: 6px; border-radius: 50%; background: #c3904f; }
.state-dot.assigned { background: #628594; }
.state-dot.ready { background: #398267; }
.palette-footer { margin-top: auto; padding: 15px 13px; color: #738295; font-size: 11px; border-top: 1px solid #e5ebf0; }
.pane-divider { background: linear-gradient(90deg,#eef2f6 3px,#c7d1dc 3px,#c7d1dc 4px,#eef2f6 4px); }
.horizontal-divider { height: 7px; background: linear-gradient(#eef2f6 3px,#c7d1dc 3px,#c7d1dc 4px,#eef2f6 4px); }
.center-pane { min-width: 0; min-height: 0; display: grid; grid-template-rows: 32px minmax(0,1fr) auto; }
.document-tab { display: flex; justify-content: space-between; align-items: center; background: #f2f5f8; border-bottom: 1px solid #cbd5df; font-size: 12px; }
.document-tab > span:first-child { background: #fff; height: 100%; padding: 7px 16px; border-right: 1px solid #cbd5df; }
.document-note { padding-right: 11px; color: #8290a0; font-size: 11px; }
.canvas { min-width: 0; min-height: 0; position: relative; overflow: hidden; background: #fff; }
#diagram { display: block; width: 100%; height: 100%; user-select: none; touch-action: none; }
#diagram [data-background] { cursor: grab; }
#diagram.panning [data-background] { cursor: grabbing; }
.fixed-component { cursor: default; }
.fixed-component path, .fixed-component rect, .fixed-component circle { vector-effect: non-scaling-stroke; }
.component-label { font: 15px "Segoe UI", "Microsoft YaHei", sans-serif; fill: #344759; }
.component-code { font: 11px "Segoe UI", sans-serif; fill: #8a97a4; }
.port-label { font: 11px "Segoe UI", sans-serif; fill: #8b134f; }
.wire { fill: none; stroke: #b66b92; stroke-width: 1.6; stroke-dasharray: 5 4; vector-effect: non-scaling-stroke; pointer-events: none; }
.wire.assigned { stroke: #8b134f; stroke-dasharray: none; }
.wire.selected { stroke: #176eb0; stroke-width: 2.6; }
.wire-hit { fill: none; stroke: transparent; stroke-width: 20; vector-effect: non-scaling-stroke; cursor: pointer; }
.pipe-name { font: 13px "Segoe UI", "Microsoft YaHei", sans-serif; fill: #8b134f; paint-order: stroke; stroke: white; stroke-width: 5px; stroke-linejoin: round; pointer-events: none; }
.pipe-name.selected { fill: #155a94; }
.canvas-lock { position: absolute; top: 10px; right: 12px; font-size: 10px; color: #8a97a5; pointer-events: none; }
.viewport-controls { display: flex; align-items: center; position: absolute; left: 12px; bottom: 12px; border: 1px solid #cbd5e1; background: white; border-radius: 4px; box-shadow: 0 2px 5px #40526910; }
.viewport-controls button { padding: 2px 9px; border: 0; font-size: 18px; }
.viewport-controls span { font-size: 11px; color: #536b7f; min-width: 44px; text-align: center; }
.console { background: #fff; border-top: 1px solid #c7d1dc; min-height: 31px; }
.console-header { display: flex; gap: 10px; align-items: center; min-height: 31px; background: #f3f5f8; border-bottom: 1px solid #dfe5ec; padding-right: 11px; }
.console-header button { font-size: 12px; background: transparent; border: 0; text-align: left; border-radius: 0; }
.console-header span { margin-left: auto; color: #7f8d9b; font-size: 10px; }
.console-content { height: 120px; padding: 9px 12px; overflow: auto; font-size: 11px; color: #5e7286; }
.console.collapsed .console-content { display: none; }
.log-row { display: flex; align-items: baseline; gap: 10px; padding: 4px 0; }
.log-kind { font-size: 10px; color: #6a8090; flex: 0 0 30px; }
.log-kind.warn { color: #956b28; }
.log-kind.ok { color: #388166; }
.log-row button { font-size: 11px; padding: 0; border: 0; color: #1764a0; background: transparent; text-align: left; }
.properties { display: grid; grid-template-rows: minmax(290px, 46%) 7px minmax(0,1fr); min-width: 0; min-height: 0; }
.properties-subpane { display: grid; grid-template-rows: 33px minmax(0,1fr); min-width: 0; min-height: 0; background: #fff; }
.properties-content { min-height: 0; overflow: auto; }
.property-table, .parameter-table { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 12px; }
.property-table th, .property-table td, .parameter-table td, .parameter-table th { text-align: left; vertical-align: middle; padding: 7px 9px; border-bottom: 1px solid #e3e8ee; overflow-wrap: anywhere; }
.property-table th { width: 76px; font-weight: 400; color: #687c8e; background: #f8fafc; }
.preview { padding: 13px 11px 10px; }
.preview-title { display: flex; align-items: center; gap: 10px; }
.preview-title svg { width: 72px; height: 38px; color: var(--gas); }
.preview-title strong { font-size: 13px; }
.preview-title small { display: block; color: #7f8e9d; font-size: 11px; }
.preview-description { font-size: 11px; color: #62768a; margin: 7px 0 9px; }
.apply-buttons { display: flex; gap: 7px; flex-wrap: wrap; }
.apply-buttons button { font-size: 12px; }
.primary { background: var(--blue); border-color: var(--blue); color: white; }
.primary:hover { background: #155a94; }
.property-details { font-size: 11px; color: #6a7d8f; margin: 11px 0 0; }
summary { cursor: pointer; }
.property-details p { margin: 7px 0; }
.empty-hint { padding: 15px 12px; color: #7d8b99; font-size: 12px; }
.parameter-table th { background: #f2f4f6; color: #536576; font-size: 11px; font-weight: 400; }
.parameter-table th:nth-child(1) { width: 46%; }
.parameter-table th:nth-child(2) { width: 34%; }
.parameter-table th:nth-child(3) { width: 20%; }
.parameter-table td { padding: 3px 7px; height: 34px; }
.parameter-table td:first-child { color: #435b70; font-size: 11px; }
.parameter-table td:last-child { color: #7c8d9e; font-size: 10px; }
.parameter-table input { width: 100%; min-width: 0; height: 26px; color: #293f52; padding: 3px 5px; border: 1px solid #c9d4df; border-radius: 2px; font-size: 12px; background: white; }
.parameter-table input:read-only { background: #f7f9fb; color: #7b8a98; border-color: transparent; }
.parameter-table input[aria-invalid=true] { border-color: #c39450; }
.parameter-note { font-size: 11px; color: #7d8d9b; padding: 10px; }
.parameter-note.ready { color: #398267; }
.statusbar { display: flex; align-items: center; gap: 16px; padding: 0 12px; font-size: 11px; background: #f5f7f9; border-top: 1px solid #cbd5df; color: #647b8f; }
#notice { margin-right: auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#progress, #save-state { flex-shrink: 0; }
@media(max-width:1150px) { .workbench { grid-template-columns: 195px 7px minmax(0,1fr) 7px 280px; } .topbar { grid-template-columns: minmax(185px,1fr) auto minmax(180px,1fr); gap: 8px; } .view-tabs button { min-width: 56px; padding: 0 10px; } .topbar-actions { gap: 9px; } .palette-content { padding: 10px; } .model-tile svg { width: 60px; } }
@media(max-width:850px) { .app-shell { height: auto; min-height: 100dvh; grid-template-rows: auto auto 1fr auto; } .topbar { grid-template-columns: 1fr auto; padding: 10px; } .view-tabs { grid-row: 2; grid-column: 1 / -1; justify-content: center; margin-top: 6px; } .view-tabs button { flex: 1; } .editor-toolbar { flex-wrap: wrap; min-height: 42px; } .toolbar-end { margin-left: auto; } .workbench { grid-template-columns: 175px 5px minmax(0,1fr); grid-template-rows: 530px auto; } .workbench > .pane-divider:nth-of-type(2) { display: none; } .properties { grid-column: 1 / -1; grid-template-columns: 1fr 7px 1fr; grid-template-rows: 350px; border-top: 1px solid #cbd5df; } .horizontal-divider { height: 100%; background: #eef2f6; } .properties-subpane { height: 100%; } .palette { min-height: 0; } .document-note { display: none; } .console-header span { display: none; } .console-content { height: 95px; } .palette-content { padding: 8px; } .palette-footer { font-size: 10px; } .statusbar { min-height: 28px; flex-wrap: wrap; gap: 5px 10px; padding: 5px 10px; } #notice { flex: 1 1 100%; } }
@media(max-width:520px) { .topbar-actions { gap: 8px; font-size: 11px; } .topbar-actions button { padding: 4px 6px; } .product strong { font-size: 13px; } .product span { font-size: 10px; } .toolbar-check { margin-right: auto; } .toolbar-end { font-size: 10px; } .workbench { display: flex; flex-direction: column; } .workbench > .pane-divider { display: none; } .palette { display: grid; grid-template-columns: 1fr; overflow: visible; } .palette-content { padding: 10px; } .palette-grid { grid-template-columns: repeat(4,minmax(0,1fr)); gap: 5px; } .model-tile svg { width: 54px; } .model-tile small { font-size: 9px; } .palette-footer, .library-heading, .palette .section-heading { display: none; } .compat-filter { margin-bottom: 8px; } .library-hint { margin-top: 7px; min-height: 0; } .pipe-list { display: flex; padding: 0; } .pipe-list button { display: flex; gap: 5px; padding: 8px; } .pipe-list .model-id { display: none; } .center-pane { height: 450px; } .properties { display: flex; flex-direction: column; } .properties-subpane { min-height: 310px; max-height: none; overflow: visible; } .properties-content { overflow: visible; } .horizontal-divider { height: 7px; } }