fix(panel): memory list layout and formatted metrics

Made-with: Cursor
This commit is contained in:
Youzini-afk
2026-04-06 16:10:03 +08:00
parent cacbc12e2c
commit 76b5116798
2 changed files with 124 additions and 34 deletions

View File

@@ -710,6 +710,7 @@
/* --- Memory Browser Tab --- */
.bme-search-bar {
display: flex;
flex-wrap: wrap;
gap: 6px;
margin-bottom: 10px;
}
@@ -743,6 +744,8 @@
font-size: 11px;
color: var(--bme-on-surface);
outline: none;
min-width: 7rem;
flex: 1 1 8rem;
}
.bme-memory-list {
@@ -751,13 +754,40 @@
margin: 0;
}
.bme-memory-badges {
display: flex;
flex-direction: column;
align-items: flex-start;
gap: 4px;
flex-shrink: 0;
max-width: min(11rem, 42%);
}
.bme-memory-badges .bme-type-badge {
margin-top: 0;
max-width: 100%;
white-space: normal;
word-break: break-word;
line-height: 1.25;
text-align: left;
}
.bme-memory-body {
flex: 1;
min-width: 0;
display: flex;
flex-direction: column;
align-items: stretch;
gap: 4px;
}
.bme-memory-item {
display: flex;
align-items: flex-start;
gap: 8px;
padding: 8px;
border-radius: 4px;
margin-bottom: 3px;
gap: 10px;
padding: 10px 8px;
border-radius: 6px;
margin-bottom: 4px;
cursor: pointer;
transition: background 0.1s;
border: 1px solid transparent;
@@ -777,28 +807,50 @@
font-size: 12px;
font-weight: 600;
color: var(--bme-on-surface);
line-height: 1.35;
word-break: break-word;
overflow-wrap: anywhere;
}
.bme-memory-content {
font-size: 11px;
color: var(--bme-on-surface-dim);
margin-top: 2px;
line-height: 1.3;
line-height: 1.45;
display: -webkit-box;
-webkit-line-clamp: 2;
line-clamp: 2;
-webkit-line-clamp: 3;
line-clamp: 3;
-webkit-box-orient: vertical;
overflow: hidden;
word-break: break-word;
overflow-wrap: anywhere;
}
.bme-memory-meta {
display: flex;
gap: 8px;
margin-top: 4px;
flex-wrap: wrap;
align-items: baseline;
gap: 6px 10px;
margin-top: 2px;
font-size: 10px;
color: var(--bme-on-surface-dim);
}
.bme-memory-metric {
flex: 0 0 auto;
white-space: nowrap;
font-variant-numeric: tabular-nums;
}
.bme-memory-regionline {
flex: 1 1 100%;
min-width: 0;
white-space: normal;
line-height: 1.35;
opacity: 0.92;
word-break: break-word;
overflow-wrap: anywhere;
}
/* --- Injection Preview Tab --- */
.bme-injection-preview {
font-family: "Cascadia Code", "Fira Code", monospace;