Add field help dialog with cultivar/process reference notes
Test and deploy / test-and-deploy (push) Successful in 1m32s
Test and deploy / test-and-deploy (push) Successful in 1m32s
Adds a help-dialog UI (field-help.js/field-help-content.js) surfacing per-field guidance, expands cultivar and process reference data with cup notes, sweet-spot width, and watch-fors, and adds a Makefile for common npm tasks. Co-Authored-By: Claude Sonnet 5 <[email protected]>
This commit is contained in:
+200
@@ -430,6 +430,176 @@ label.filebtn input[type="file"] {
|
||||
background: var(--surface-sunken);
|
||||
}
|
||||
|
||||
/* ─── Field-help dialog ───────────────────────────────────────────────── */
|
||||
.help-dialog {
|
||||
padding: 0;
|
||||
border: none;
|
||||
border-radius: var(--radius-lg);
|
||||
background: var(--surface-raised);
|
||||
box-shadow: var(--shadow-pop);
|
||||
width: min(680px, 94vw);
|
||||
max-height: min(82vh, 780px);
|
||||
}
|
||||
.help-dialog::backdrop {
|
||||
background: rgba(27, 22, 20, 0.32);
|
||||
}
|
||||
.help-card {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
max-height: inherit;
|
||||
}
|
||||
.help-head {
|
||||
display: flex;
|
||||
align-items: flex-start;
|
||||
justify-content: space-between;
|
||||
gap: 12px;
|
||||
padding: 16px 20px 12px;
|
||||
border-bottom: 1px solid var(--line);
|
||||
}
|
||||
.help-kicker {
|
||||
display: block;
|
||||
font-size: 10.5px;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.08em;
|
||||
text-transform: uppercase;
|
||||
color: var(--ember);
|
||||
}
|
||||
.help-head h3 {
|
||||
font-size: 15px;
|
||||
font-weight: 700;
|
||||
margin-top: 2px;
|
||||
}
|
||||
.help-body {
|
||||
padding: 14px 20px;
|
||||
overflow-y: auto;
|
||||
font-size: 12.5px;
|
||||
line-height: 1.55;
|
||||
color: var(--ink-2);
|
||||
}
|
||||
.help-body h4 {
|
||||
margin: 14px 0 6px;
|
||||
font-size: 11px;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.05em;
|
||||
text-transform: uppercase;
|
||||
color: var(--ink-2);
|
||||
}
|
||||
.help-body h4:first-child {
|
||||
margin-top: 0;
|
||||
}
|
||||
.help-body p {
|
||||
margin: 0 0 8px;
|
||||
}
|
||||
.help-body dl {
|
||||
margin: 0;
|
||||
}
|
||||
.help-table-wrap {
|
||||
overflow-x: auto;
|
||||
margin: 6px 0 10px;
|
||||
border: 1px solid var(--line);
|
||||
border-radius: var(--radius-sm);
|
||||
}
|
||||
.help-table {
|
||||
width: 100%;
|
||||
border-collapse: collapse;
|
||||
font-size: 12px;
|
||||
}
|
||||
.help-table th {
|
||||
text-align: left;
|
||||
font-size: 10px;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.05em;
|
||||
text-transform: uppercase;
|
||||
color: var(--ink-3);
|
||||
padding: 7px 10px 5px;
|
||||
border-bottom: 1px solid var(--line-strong);
|
||||
background: var(--surface);
|
||||
white-space: nowrap;
|
||||
}
|
||||
.help-table td {
|
||||
padding: 6px 10px;
|
||||
border-bottom: 1px solid var(--line);
|
||||
vertical-align: top;
|
||||
}
|
||||
.help-table tbody tr:last-child td {
|
||||
border-bottom: none;
|
||||
}
|
||||
.help-table td.num {
|
||||
font-family: var(--font-mono);
|
||||
font-variant-numeric: tabular-nums;
|
||||
white-space: nowrap;
|
||||
font-size: 11.5px;
|
||||
}
|
||||
.help-table tr.grp td {
|
||||
background: var(--ember-soft);
|
||||
color: var(--ember-strong);
|
||||
font-weight: 700;
|
||||
font-size: 11px;
|
||||
}
|
||||
.help-table tr.current td {
|
||||
background: var(--ember-soft);
|
||||
box-shadow: inset 3px 0 0 var(--ember);
|
||||
}
|
||||
.help-aside {
|
||||
border-left: 3px solid var(--ember);
|
||||
border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
|
||||
background: var(--ember-soft);
|
||||
padding: 10px 12px;
|
||||
margin: 10px 0;
|
||||
}
|
||||
.help-aside .tag {
|
||||
display: block;
|
||||
font-size: 10px;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.06em;
|
||||
text-transform: uppercase;
|
||||
color: var(--ember-strong);
|
||||
margin-bottom: 4px;
|
||||
}
|
||||
.help-aside p:last-child {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
.help-aside.warn {
|
||||
border-left-color: var(--warn);
|
||||
background: var(--warn-bg);
|
||||
}
|
||||
.help-aside.warn .tag {
|
||||
color: var(--warn);
|
||||
}
|
||||
.help-formula {
|
||||
font-family: var(--font-mono);
|
||||
font-size: 12px;
|
||||
text-align: center;
|
||||
background: var(--surface-sunken);
|
||||
border-radius: var(--radius-sm);
|
||||
padding: 8px 10px;
|
||||
margin: 8px 0;
|
||||
overflow-x: auto;
|
||||
white-space: nowrap;
|
||||
}
|
||||
.help-attrib {
|
||||
margin: 0;
|
||||
padding: 10px 20px 14px;
|
||||
border-top: 1px solid var(--line);
|
||||
font-size: 11px;
|
||||
color: var(--ink-3);
|
||||
}
|
||||
@media (max-width: 720px) {
|
||||
.help-dialog {
|
||||
width: 100vw;
|
||||
max-width: none;
|
||||
margin: auto 0 0;
|
||||
border-radius: var(--radius-lg) var(--radius-lg) 0 0;
|
||||
max-height: 88vh;
|
||||
}
|
||||
}
|
||||
@media print {
|
||||
.help-btn,
|
||||
.help-dialog {
|
||||
display: none !important;
|
||||
}
|
||||
}
|
||||
|
||||
/* ─── Workspace layout ────────────────────────────────────────────────── */
|
||||
.workspace-grid {
|
||||
display: grid;
|
||||
@@ -592,6 +762,36 @@ label.filebtn input[type="file"] {
|
||||
align-items: center;
|
||||
gap: 4px;
|
||||
}
|
||||
.help-btn {
|
||||
flex: 0 0 auto;
|
||||
width: 15px;
|
||||
height: 15px;
|
||||
padding: 0;
|
||||
border: 1px solid var(--line-strong);
|
||||
border-radius: 50%;
|
||||
background: none;
|
||||
color: var(--ink-3);
|
||||
font: 600 9.5px/1 var(--font-ui);
|
||||
cursor: pointer;
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
.help-btn:hover,
|
||||
.help-btn:focus-visible {
|
||||
border-color: var(--ember);
|
||||
color: var(--ember);
|
||||
background: var(--ember-soft);
|
||||
}
|
||||
.help-btn:focus-visible {
|
||||
outline: 2px solid var(--ember);
|
||||
outline-offset: 1px;
|
||||
}
|
||||
.subhead .help-btn,
|
||||
.dock-card-head .help-btn {
|
||||
margin-left: 6px;
|
||||
vertical-align: 1px;
|
||||
}
|
||||
/* ─── Teaching layer ─────────────────────────────────────────────────────
|
||||
Replaces the old per-field "?" tooltip system: a collapsible "why" panel
|
||||
per section, a permanent one-line note under only the causally-loaded
|
||||
|
||||
Reference in New Issue
Block a user