diff --git a/src/App.css b/src/App.css
index d836f30..37bf8a2 100644
--- a/src/App.css
+++ b/src/App.css
@@ -2454,13 +2454,18 @@
}
.record-settings-close {
+ display: inline-flex;
+ align-items: center;
+ justify-content: center;
+ width: 28px;
+ height: 28px;
+ padding: 0;
border: 1px solid var(--border);
border-radius: 4px;
background: none;
color: var(--text-muted);
font-size: 16px;
line-height: 1;
- padding: 2px 8px;
cursor: pointer;
}
@@ -2469,6 +2474,11 @@
border-color: var(--error);
}
+.record-settings-close:focus-visible {
+ outline: 2px solid var(--accent);
+ outline-offset: 2px;
+}
+
.record-settings-group-title {
font-size: 12px;
text-transform: uppercase;
@@ -2477,21 +2487,47 @@
margin: 12px 0 6px;
}
+/* One field shape for every panel: a label column and a control column, so a
+ checkbox, a select and a text input all start at the same x. The checkbox is
+ an 18px box in the control column — the old `min-width: 220px` applied to
+ every input, which made the featured checkbox 220px wide. */
.record-settings-field {
- display: flex;
+ display: grid;
+ grid-template-columns: 150px minmax(0, 1fr);
align-items: center;
- gap: 8px;
+ gap: 10px;
margin: 8px 0;
}
-.record-settings-field input,
+.record-settings-field > span {
+ font-size: var(--text-meta);
+ color: var(--text-muted);
+}
+
+.record-settings-field input[type='text'],
.record-settings-field select {
+ width: 100%;
+ min-width: 0;
background: var(--bg-surface);
color: inherit;
border: 1px solid var(--border);
border-radius: 4px;
padding: 4px 8px;
- min-width: 220px;
+}
+
+.record-settings-field input[type='checkbox'] {
+ width: 18px;
+ height: 18px;
+ margin: 0;
+ accent-color: var(--accent);
+ cursor: pointer;
+}
+
+.record-settings-field input:focus-visible,
+.record-settings-field select:focus-visible,
+.record-settings-row select:focus-visible {
+ outline: 2px solid var(--accent);
+ outline-offset: 2px;
}
.record-settings-list {
@@ -2502,8 +2538,19 @@
padding: 0;
}
+/* The add control sits under the list it extends, not beside its last row. */
+.record-settings .edit-add-inline {
+ margin-top: 8px;
+}
+
+/* A section row is a five-column grid — id | type | up | down | delete. The
+ control columns are fixed, so every id ellipsizes at the same x and every
+ select opens at the same x. Below the dialog's own width the type select
+ takes a row of its own and the controls stay on the id's row. */
.record-settings-row {
- display: flex;
+ display: grid;
+ grid-template-columns: minmax(0, 1fr) minmax(120px, 170px) repeat(3, 22px);
+ grid-template-areas: "id type up down remove";
align-items: center;
gap: 8px;
border: 1px solid var(--border);
@@ -2512,6 +2559,9 @@
}
.record-settings-row select {
+ grid-area: type;
+ width: 100%;
+ min-width: 0;
background: var(--bg-surface);
color: inherit;
border: 1px solid var(--border);
@@ -2519,13 +2569,40 @@
padding: 3px 6px;
}
+.record-settings-move-up {
+ grid-area: up;
+}
+
+.record-settings-move-down {
+ grid-area: down;
+}
+
+.record-settings-row .edit-record-remove {
+ grid-area: remove;
+}
+
.record-settings-id {
+ grid-area: id;
font-size: 12px;
color: var(--text-muted);
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
- max-width: 220px;
+ min-width: 0;
+}
+
+@media (max-width: 520px) {
+ .record-settings-field {
+ grid-template-columns: 1fr;
+ gap: 4px;
+ }
+
+ .record-settings-row {
+ grid-template-columns: minmax(0, 1fr) repeat(3, 22px);
+ grid-template-areas:
+ "id up down remove"
+ "type type type type";
+ }
}
/* Field-by-field conflict view (E8). */
diff --git a/src/components/ui/RecordSettings.tsx b/src/components/ui/RecordSettings.tsx
index 03bc06c..d19bceb 100644
--- a/src/components/ui/RecordSettings.tsx
+++ b/src/components/ui/RecordSettings.tsx
@@ -66,12 +66,12 @@ export function ProjectSettingsPanel({ project }: { project: ProjectStructure })
return (
<>