Spike, not the final UI: it answers whether flare-ui can drive Alkane OS's on-box pages, and what it costs. What works: - schema/alkane-bb.json authors the sidebar as data (3 sections, 14 tabs); - src/bin/ui-spike.rs renders it through flare_ui::nav + flare_ui::shell, so the unified sidebar, ordering and surface filtering come from the schema rather than from hand-written HTML; - the render uses the shared bf- design tokens, the same ones the rest of the suite uses. Size, measured rather than assumed (armv7, release, stripped): ui-baseline 323 KiB (maud + serde_json, no flare-ui) ui-spike 771 KiB (flare-ui + wschema + sha2) marginal 448 KiB Vendoring: third-party/flare-ui is the full v0.2.9 tree pinned in flare-ui/flare-ui.lock (a partial archive does not compile, since the crate include_str!s assets from dash-editor/). vendor/ is re-generated as a cargo directory source with the new registry dependencies (maud, sha2, typenum, digest, generic-array, block-buffer, crypto-common, cfg-if, etc.) so the build still works offline. third-party/README.md records how to re-pin.
156 lines
3.8 KiB
CSS
156 lines
3.8 KiB
CSS
/* The automation flowchart (flow-view.js). The chain runs down the first
|
|
column; the Stopped node, when a procedure has one, sits in the second.
|
|
Edges are an SVG layer under the nodes, drawn from their measured boxes. */
|
|
|
|
.bf-flowchart {
|
|
position: relative;
|
|
display: grid;
|
|
grid-template-columns: minmax(0, 1fr) minmax(7rem, 10rem);
|
|
gap: var(--bf-space-4, 16px);
|
|
padding: var(--bf-space-3, 12px) var(--bf-space-3, 12px) var(--bf-space-3, 12px) 28px;
|
|
}
|
|
|
|
.bf-flowchart__edges {
|
|
position: absolute;
|
|
inset: 0;
|
|
overflow: visible;
|
|
pointer-events: none;
|
|
}
|
|
|
|
.bf-flowchart__edge {
|
|
fill: none;
|
|
stroke: var(--app-text-muted, #6b7280);
|
|
stroke-width: 1.5;
|
|
}
|
|
|
|
.bf-flowchart__edge--false,
|
|
.bf-flowchart__edge--timeout { stroke-dasharray: 5 3; }
|
|
.bf-flowchart__edge--repeat { stroke-dasharray: 2 3; }
|
|
.bf-flowchart__edge--pending { stroke: var(--app-link, #2563eb); stroke-width: 2; }
|
|
.bf-flowchart__arrow { fill: var(--app-text-muted, #6b7280); }
|
|
.bf-flowchart__label { fill: var(--app-text-muted, #6b7280); font-size: 11px; }
|
|
|
|
.bf-flowchart__chain {
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
gap: 32px;
|
|
margin: 0;
|
|
padding: 0;
|
|
list-style: none;
|
|
}
|
|
|
|
.bf-flowchart__item {
|
|
position: relative;
|
|
display: flex;
|
|
justify-content: center;
|
|
width: min(100%, 26rem);
|
|
}
|
|
|
|
.bf-flowchart__node {
|
|
position: relative;
|
|
z-index: 1;
|
|
display: grid;
|
|
grid-template-columns: auto minmax(0, 1fr);
|
|
gap: var(--bf-space-3, 12px);
|
|
align-items: center;
|
|
width: 100%;
|
|
min-height: 56px;
|
|
padding: var(--bf-space-3, 12px);
|
|
border: 1px solid var(--app-border, #d1d5db);
|
|
border-radius: 6px;
|
|
background: var(--app-surface, #fff);
|
|
color: var(--app-text, #111827);
|
|
font: inherit;
|
|
text-align: start;
|
|
cursor: pointer;
|
|
}
|
|
|
|
.bf-flowchart__node > * { min-width: 0; }
|
|
.bf-flowchart__node strong,
|
|
.bf-flowchart__node small { display: block; overflow-wrap: anywhere; }
|
|
.bf-flowchart__node small { color: var(--app-text-muted, #6b7280); }
|
|
|
|
.bf-flowchart__node--start,
|
|
.bf-flowchart__node--end,
|
|
.bf-flowchart__node--stop {
|
|
grid-template-columns: minmax(0, 1fr);
|
|
border-radius: 28px;
|
|
text-align: center;
|
|
}
|
|
|
|
.bf-flowchart__node--stop {
|
|
align-self: end;
|
|
cursor: default;
|
|
border-style: dashed;
|
|
}
|
|
|
|
.bf-flowchart__side {
|
|
display: flex;
|
|
flex-direction: column;
|
|
justify-content: flex-end;
|
|
}
|
|
|
|
.bf-flowchart__node[aria-pressed="true"] {
|
|
border-color: var(--app-link, #2563eb);
|
|
box-shadow: inset 3px 0 0 var(--app-link, #2563eb);
|
|
}
|
|
|
|
.bf-flowchart__node:focus-visible {
|
|
outline: 2px solid var(--app-link, #2563eb);
|
|
outline-offset: 2px;
|
|
}
|
|
|
|
.bf-flowchart__node--invalid {
|
|
border-color: var(--app-danger, #b91c1c);
|
|
box-shadow: inset 3px 0 0 var(--app-danger, #b91c1c);
|
|
}
|
|
|
|
.bf-flowchart__error {
|
|
grid-column: 1 / -1;
|
|
color: var(--app-danger, #b91c1c);
|
|
font-size: 0.875em;
|
|
}
|
|
|
|
.bf-flowchart__number {
|
|
display: grid;
|
|
place-items: center;
|
|
width: 28px;
|
|
height: 28px;
|
|
border-radius: 50%;
|
|
background: var(--app-link, #2563eb);
|
|
color: var(--bf-action-primary-text, #fff);
|
|
font-weight: 600;
|
|
}
|
|
|
|
/* The output port: a press here starts a connection. */
|
|
.bf-flowchart__port {
|
|
position: absolute;
|
|
bottom: -7px;
|
|
left: 50%;
|
|
z-index: 2;
|
|
width: 14px;
|
|
height: 14px;
|
|
margin-left: -7px;
|
|
border: 2px solid var(--app-link, #2563eb);
|
|
border-radius: 50%;
|
|
background: var(--app-surface, #fff);
|
|
cursor: crosshair;
|
|
touch-action: none;
|
|
}
|
|
|
|
.bf-flowchart--connecting .bf-flowchart__node:not(.bf-flowchart__node--stop) {
|
|
border-style: dashed;
|
|
border-color: var(--app-link, #2563eb);
|
|
}
|
|
|
|
.bf-flowchart__item--dragging .bf-flowchart__node {
|
|
border: 2px dashed var(--app-link, #2563eb);
|
|
background: var(--app-row-hover, #f3f4f6);
|
|
}
|
|
|
|
@media (max-width: 640px) {
|
|
.bf-flowchart { grid-template-columns: minmax(0, 1fr); }
|
|
.bf-flowchart__side { justify-content: flex-start; }
|
|
}
|