feat(planning): explain and trace planning decisions
This commit is contained in:
1 parent
609b3dece9
commit
d7a13b0b1e
24 files changed
+6073
-342
No files matched your search
@@ -3,6 +3,18 @@
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.sr-only {
|
||||
position: absolute;
|
||||
width: 1px;
|
||||
height: 1px;
|
||||
padding: 0;
|
||||
margin: -1px;
|
||||
overflow: hidden;
|
||||
clip: rect(0, 0, 0, 0);
|
||||
white-space: nowrap;
|
||||
border: 0;
|
||||
}
|
||||
|
||||
.calendar-year {
|
||||
display: grid;
|
||||
container: calendar-year / inline-size;
|
||||
@@ -146,6 +158,261 @@
|
||||
}
|
||||
}
|
||||
|
||||
.reason-list,
|
||||
.outcome-explanation,
|
||||
.placement-explanation,
|
||||
.trace-explorer {
|
||||
margin: 0;
|
||||
padding: 1rem;
|
||||
border: 1px solid var(--ui-border, #c7c7d0);
|
||||
border-radius: var(--ui-radius-md, 0.75rem);
|
||||
background: var(--ui-card-bg, #fff);
|
||||
}
|
||||
|
||||
.outcome-explanation,
|
||||
.placement-explanation {
|
||||
display: grid;
|
||||
gap: 1rem;
|
||||
|
||||
h3,
|
||||
h4,
|
||||
h5,
|
||||
p,
|
||||
ul,
|
||||
ol {
|
||||
margin-block: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.conflict-explanation {
|
||||
border-inline-start: 0.35rem solid var(--ui-error-text, #751b1b);
|
||||
}
|
||||
|
||||
.incomplete-explanation {
|
||||
border-inline-start: 0.35rem solid var(--ui-warning-text, #4f3800);
|
||||
}
|
||||
|
||||
.incomplete-incumbent {
|
||||
display: grid;
|
||||
gap: 0.35rem;
|
||||
padding: 0.75rem 1rem;
|
||||
border-inline-start: 0.35rem solid var(--ui-warning-text, #4f3800);
|
||||
background: var(--ui-warning-bg, #fff4d6);
|
||||
|
||||
p {
|
||||
margin: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.explanation-heading {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
justify-content: space-between;
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
.eyebrow {
|
||||
color: var(--ui-text-secondary, #45464f);
|
||||
font-size: 0.75rem;
|
||||
font-weight: 700;
|
||||
letter-spacing: 0.08em;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
.placement-stepper,
|
||||
.trace-toolbar,
|
||||
.trace-decisions nav {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
align-items: center;
|
||||
gap: 0.35rem;
|
||||
|
||||
button,
|
||||
output {
|
||||
min-height: 2.5rem;
|
||||
padding: 0.45rem 0.7rem;
|
||||
border: 1px solid var(--ui-border, #777984);
|
||||
border-radius: var(--ui-radius-sm, 0.5rem);
|
||||
background: var(--ui-card-bg, #fff);
|
||||
color: inherit;
|
||||
font: inherit;
|
||||
}
|
||||
|
||||
button {
|
||||
cursor: pointer;
|
||||
|
||||
&:hover:not(:disabled),
|
||||
&[aria-pressed='true'] {
|
||||
background: var(--ui-panel-bg, #ececf2);
|
||||
}
|
||||
|
||||
&:focus-visible {
|
||||
outline: 3px solid var(--today-border-color, #1976d2);
|
||||
outline-offset: 2px;
|
||||
}
|
||||
|
||||
&:disabled {
|
||||
opacity: 0.45;
|
||||
cursor: not-allowed;
|
||||
}
|
||||
}
|
||||
|
||||
output {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
}
|
||||
|
||||
.compact-facts {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(min(100%, 13rem), 1fr));
|
||||
gap: 0.75rem;
|
||||
margin: 0;
|
||||
|
||||
div {
|
||||
min-width: 0;
|
||||
padding: 0.75rem;
|
||||
border-radius: var(--ui-radius-sm, 0.5rem);
|
||||
background: var(--ui-panel-bg, #f7f7fa);
|
||||
}
|
||||
|
||||
dt {
|
||||
margin-block-end: 0.25rem;
|
||||
color: var(--ui-text-secondary, #45464f);
|
||||
font-size: 0.8rem;
|
||||
font-weight: 700;
|
||||
}
|
||||
|
||||
dd {
|
||||
margin: 0;
|
||||
line-height: 1.5;
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
}
|
||||
|
||||
code {
|
||||
font-size: 0.8em;
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
|
||||
.explanation-columns {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr));
|
||||
gap: 1rem;
|
||||
|
||||
section {
|
||||
display: grid;
|
||||
align-content: start;
|
||||
gap: 0.75rem;
|
||||
padding: 1rem;
|
||||
border-radius: var(--ui-radius-sm, 0.5rem);
|
||||
background: var(--ui-panel-bg, #f7f7fa);
|
||||
}
|
||||
}
|
||||
|
||||
.objective-vector {
|
||||
display: grid;
|
||||
gap: 0.4rem;
|
||||
padding-inline-start: 1.5rem;
|
||||
|
||||
li {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(0, 1fr) auto;
|
||||
gap: 0 0.75rem;
|
||||
}
|
||||
|
||||
small {
|
||||
grid-column: 1 / -1;
|
||||
color: var(--ui-text-secondary, #45464f);
|
||||
}
|
||||
}
|
||||
|
||||
.metric-list {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(2, minmax(0, 1fr));
|
||||
gap: 0.4rem 1rem;
|
||||
margin: 0;
|
||||
|
||||
div {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
gap: 0.5rem;
|
||||
}
|
||||
|
||||
dt {
|
||||
color: var(--ui-text-secondary, #45464f);
|
||||
}
|
||||
|
||||
dd {
|
||||
margin: 0;
|
||||
font-weight: 700;
|
||||
font-variant-numeric: tabular-nums;
|
||||
}
|
||||
}
|
||||
|
||||
.comparison-details,
|
||||
.counterfactual-panel {
|
||||
padding: 0.75rem 1rem;
|
||||
border-radius: var(--ui-radius-sm, 0.5rem);
|
||||
background: var(--ui-panel-bg, #f7f7fa);
|
||||
}
|
||||
|
||||
.comparison-details summary,
|
||||
.trace-explorer > summary,
|
||||
.candidate-list summary {
|
||||
cursor: pointer;
|
||||
font-weight: 700;
|
||||
}
|
||||
|
||||
.counterfactual-result {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
align-items: baseline;
|
||||
gap: 0.5rem 1rem;
|
||||
}
|
||||
|
||||
.comparison-vectors {
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr));
|
||||
gap: 0.75rem;
|
||||
margin-block-start: 0.5rem;
|
||||
|
||||
div {
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
ol {
|
||||
margin-block: 0.35rem 0;
|
||||
padding-inline-start: 1.25rem;
|
||||
}
|
||||
|
||||
li {
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
}
|
||||
|
||||
.status-badge {
|
||||
padding: 0.2rem 0.5rem;
|
||||
border: 2px solid var(--ui-success-text, #174d26);
|
||||
border-radius: 999px;
|
||||
font-weight: 700;
|
||||
|
||||
&.ineligible {
|
||||
border-color: var(--ui-error-text, #751b1b);
|
||||
text-decoration: line-through;
|
||||
}
|
||||
}
|
||||
|
||||
.inline-error {
|
||||
margin: 0;
|
||||
padding: 0.75rem;
|
||||
border-inline-start: 0.35rem solid var(--ui-error-text, #751b1b);
|
||||
background: var(--ui-error-bg, #ffe0e0);
|
||||
color: var(--ui-error-text, #751b1b);
|
||||
}
|
||||
|
||||
.calendar-legend {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
@@ -212,15 +479,124 @@
|
||||
}
|
||||
}
|
||||
|
||||
.legend-symbol {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
width: 1rem;
|
||||
height: 1rem;
|
||||
font-weight: 800;
|
||||
}
|
||||
|
||||
.month-grid {
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
flex-wrap: wrap;
|
||||
justify-content: space-evenly;
|
||||
display: grid;
|
||||
grid-template-columns: repeat(auto-fit, minmax(min(100%, 21rem), 1fr));
|
||||
gap: 1rem;
|
||||
width: 100%;
|
||||
max-width: 100%;
|
||||
}
|
||||
|
||||
.month-card {
|
||||
margin: 16px;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.trace-explorer {
|
||||
summary {
|
||||
font-size: 1.05rem;
|
||||
}
|
||||
}
|
||||
|
||||
.trace-layout {
|
||||
display: grid;
|
||||
grid-template-columns: minmax(12rem, 0.35fr) minmax(0, 1fr);
|
||||
gap: 1rem;
|
||||
margin-block-start: 1rem;
|
||||
}
|
||||
|
||||
.trace-phases {
|
||||
display: grid;
|
||||
align-content: start;
|
||||
gap: 0.35rem;
|
||||
|
||||
button {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
gap: 0.75rem;
|
||||
padding: 0.6rem 0.75rem;
|
||||
border: 1px solid var(--ui-border, #c7c7d0);
|
||||
border-radius: var(--ui-radius-sm, 0.5rem);
|
||||
background: transparent;
|
||||
color: inherit;
|
||||
font: inherit;
|
||||
text-align: start;
|
||||
cursor: pointer;
|
||||
|
||||
&.active {
|
||||
border-inline-start: 0.35rem solid var(--today-border-color, #1976d2);
|
||||
background: var(--ui-panel-bg, #f7f7fa);
|
||||
}
|
||||
|
||||
small {
|
||||
color: var(--ui-text-secondary, #45464f);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
.trace-phase-stepper {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
gap: 0.35rem;
|
||||
|
||||
output {
|
||||
min-width: 4rem;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
|
||||
.trace-decisions {
|
||||
display: grid;
|
||||
align-content: start;
|
||||
gap: 0.85rem;
|
||||
min-width: 0;
|
||||
|
||||
h3,
|
||||
h4,
|
||||
p,
|
||||
ul {
|
||||
margin-block: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.candidate-list {
|
||||
display: grid;
|
||||
gap: 0.4rem;
|
||||
|
||||
details {
|
||||
padding: 0.55rem 0.75rem;
|
||||
border: 1px solid var(--ui-border, #c7c7d0);
|
||||
border-radius: var(--ui-radius-sm, 0.5rem);
|
||||
}
|
||||
}
|
||||
|
||||
.status-symbol {
|
||||
display: inline-block;
|
||||
min-width: 1rem;
|
||||
font-weight: 800;
|
||||
}
|
||||
|
||||
.trace-state-summary {
|
||||
padding: 0.75rem;
|
||||
border: 2px solid var(--today-border-color, #1976d2);
|
||||
border-radius: var(--ui-radius-sm, 0.5rem);
|
||||
}
|
||||
|
||||
@media (max-width: 52rem) {
|
||||
.trace-layout {
|
||||
grid-template-columns: 1fr;
|
||||
}
|
||||
|
||||
.trace-phases {
|
||||
grid-template-columns: repeat(auto-fit, minmax(10rem, 1fr));
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user