z-index ran through eleven values (1 to 1100), border-radius through about twenty and floating boxes had six different shadows, with no names, so each new box picked its own. theme.css now defines --z-bar, --z-popover, --z-skip, --z-modal, --z-toast, --radius-sm, --radius-md, --radius-pill and --shadow-pop, and every stylesheet and the toast host use them. Corners and shadows move by a pixel or two at most; the stacking order is unchanged. css-vars.md lists them.
65 lines
1.5 KiB
CSS
65 lines
1.5 KiB
CSS
/* <AgentPicker>: each agent a labelled checkbox card, icon over name; the grid
|
|
wraps to however many cards fit. */
|
|
.ui-agent-picker {
|
|
display: grid;
|
|
grid-template-columns: repeat(auto-fill, minmax(8em, 1fr));
|
|
gap: 0.6em;
|
|
list-style: none;
|
|
margin: 0;
|
|
padding: 0;
|
|
}
|
|
.ui-agent-picker-card {
|
|
position: relative;
|
|
display: flex;
|
|
flex-direction: column;
|
|
align-items: center;
|
|
gap: 0.35em;
|
|
padding: 0.7em 0.5em 0.6em;
|
|
border: 1px solid var(--border);
|
|
border-radius: var(--radius-md);
|
|
background: var(--bg);
|
|
cursor: pointer;
|
|
}
|
|
.ui-agent-picker-card:hover {
|
|
border-color: var(--muted);
|
|
}
|
|
.ui-agent-picker-card-on {
|
|
border-color: var(--purple);
|
|
background: var(--bg-elev);
|
|
}
|
|
.ui-agent-picker-card:focus-within {
|
|
outline: 2px solid var(--purple);
|
|
outline-offset: 2px;
|
|
}
|
|
.ui-agent-picker-check {
|
|
position: absolute;
|
|
top: 0.5em;
|
|
left: 0.5em;
|
|
margin: 0;
|
|
}
|
|
.ui-agent-picker-name {
|
|
max-width: 100%;
|
|
overflow-wrap: anywhere;
|
|
text-align: center;
|
|
}
|
|
.ui-agent-picker-state {
|
|
color: var(--muted);
|
|
font-size: 0.8em;
|
|
}
|
|
.ui-agent-picker-state-up {
|
|
color: var(--green);
|
|
}
|
|
/* The loading twin's card (a skeleton the caller renders in the same grid):
|
|
not a control, so no pointer. */
|
|
.ui-agent-picker-card-loading {
|
|
cursor: default;
|
|
}
|
|
/* Its name and state lines take the height of a line of text, so the card is
|
|
the height of a real one. */
|
|
.ui-agent-picker-card-loading .ui-agent-picker-name,
|
|
.ui-agent-picker-card-loading .ui-agent-picker-state {
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
min-height: 1.6em;
|
|
}
|