Files
writing-agent/web/modules.css
moran 6392af54b4 完善配方驱动的创作编排
为可重复技能补充参数校验与展示,统一配方、编排器和执行单元术语。

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-07-30 17:59:20 +08:00

319 lines
5.1 KiB
CSS

/* 技能池浏览页 — 叠在 settings.css 壳上 */
.mod-shell {
max-width: 1280px;
--st-rail-w: 260px;
}
.mod-pack {
margin: 0 8px 10px;
font-size: 12px;
color: var(--st-muted);
word-break: break-all;
}
.mod-filter {
padding: 0 8px 8px;
}
.mod-filter input {
width: 100%;
padding: 7px 10px;
border: 1px solid var(--st-border);
border-radius: 6px;
background: var(--st-bg);
}
.mod-status-filters {
display: flex;
flex-wrap: wrap;
gap: 4px;
padding: 0 8px 12px;
}
.mod-chip {
border: 1px solid var(--st-border);
background: var(--st-surface);
color: var(--st-muted);
border-radius: 999px;
padding: 3px 9px;
font-size: 12px;
cursor: pointer;
}
.mod-chip:hover {
color: var(--st-text);
border-color: var(--st-border-strong);
}
.mod-chip.active {
color: var(--st-accent);
background: var(--st-accent-soft);
border-color: transparent;
}
.mod-list {
display: flex;
flex-direction: column;
gap: 2px;
flex: 1;
overflow: auto;
padding-bottom: 12px;
}
.mod-item {
display: block;
width: 100%;
text-align: left;
border: none;
background: transparent;
padding: 8px 10px;
border-radius: 6px;
cursor: pointer;
color: inherit;
}
.mod-item:hover {
background: #f4f4f5;
}
.mod-item.active {
background: var(--st-accent-soft);
}
.mod-item-name {
display: flex;
align-items: center;
justify-content: space-between;
gap: 6px;
font-weight: 600;
font-size: 13px;
}
.mod-item-decl {
margin: 4px 0 0;
font-size: 11px;
color: var(--st-muted);
line-height: 1.35;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;
}
.mod-dot {
width: 8px;
height: 8px;
border-radius: 50%;
flex-shrink: 0;
}
.mod-dot.ready {
background: var(--st-ok);
}
.mod-dot.partial {
background: #ca8a04;
}
.mod-dot.skeleton,
.mod-dot.missing {
background: var(--st-faint);
}
.mod-badge {
font-size: 12px;
font-weight: 600;
padding: 4px 10px;
border-radius: 999px;
background: #f4f4f5;
color: var(--st-muted);
}
.mod-badge.ready {
background: #dcfce7;
color: var(--st-ok);
}
.mod-badge.partial {
background: #fef9c3;
color: #a16207;
}
.mod-badge.skeleton,
.mod-badge.missing {
background: #f4f4f5;
color: var(--st-muted);
}
.mod-error {
margin: 0 0 12px;
color: var(--st-danger);
font-size: 13px;
}
.mod-empty {
color: var(--st-muted);
margin: 2rem 0;
}
.mod-body {
display: flex;
flex-direction: column;
gap: 14px;
}
.mod-summary {
display: grid;
gap: 10px;
padding: 14px 16px;
background: var(--st-surface);
border: 1px solid var(--st-border);
border-radius: var(--st-radius);
}
.mod-summary dl {
display: grid;
grid-template-columns: 6.5rem minmax(0, 1fr);
gap: 6px 12px;
margin: 0;
font-size: 13px;
}
.mod-summary dt {
color: var(--st-muted);
font-weight: 500;
}
.mod-summary dd {
margin: 0;
white-space: pre-wrap;
word-break: break-word;
}
.mod-decl {
margin: 0;
font-size: 14px;
line-height: 1.5;
}
.mod-section-nav {
display: flex;
flex-wrap: wrap;
gap: 6px;
position: sticky;
top: calc(var(--st-top-h) + 8px);
z-index: 5;
background: var(--st-bg);
padding: 6px 0;
}
.mod-section-nav a {
font-size: 12px;
text-decoration: none;
color: var(--st-muted);
padding: 4px 8px;
border-radius: 6px;
border: 1px solid var(--st-border);
background: var(--st-surface);
}
.mod-section-nav a:hover {
color: var(--st-accent);
border-color: var(--st-accent);
}
.mod-section {
background: var(--st-surface);
border: 1px solid var(--st-border);
border-radius: var(--st-radius);
overflow: hidden;
}
.mod-section > summary {
list-style: none;
cursor: pointer;
padding: 12px 16px;
font-weight: 650;
font-size: 14px;
display: flex;
align-items: center;
justify-content: space-between;
gap: 8px;
user-select: none;
}
.mod-section > summary::-webkit-details-marker {
display: none;
}
.mod-section > summary::after {
content: "▸";
color: var(--st-faint);
font-size: 12px;
}
.mod-section[open] > summary::after {
content: "▾";
}
.mod-section > summary:hover {
background: #fafafa;
}
.mod-section-body {
border-top: 1px solid var(--st-border);
padding: 12px 16px 16px;
}
.mod-section pre {
margin: 0;
white-space: pre-wrap;
word-break: break-word;
font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
font-size: 12.5px;
line-height: 1.55;
color: #27272a;
}
.mod-raw-toggle {
align-self: flex-start;
border: 1px solid var(--st-border);
background: var(--st-surface);
border-radius: 6px;
padding: 6px 12px;
font-size: 12px;
cursor: pointer;
color: var(--st-muted);
}
.mod-raw-toggle:hover {
color: var(--st-text);
}
.mod-raw {
background: #18181b;
color: #e4e4e7;
border-radius: var(--st-radius);
padding: 14px 16px;
max-height: 60vh;
overflow: auto;
font-size: 12px;
line-height: 1.5;
white-space: pre-wrap;
word-break: break-word;
}
@media (max-width: 820px) {
.mod-shell {
grid-template-columns: 1fr;
}
.mod-rail {
min-height: auto;
border-right: none;
border-bottom: 1px solid var(--st-border);
max-height: 42vh;
}
}