Give the balance input and Recheck button equal explicit heights
Matching just the top edge (via the label-height spacer) wasn't enough - the button's own padding made it naturally shorter than a balance input, so the two boxes still looked slightly off-center against each other. Both now get the same explicit height with the button's text flex-centered inside it.
This commit is contained in:
parent
12e18ae235
commit
534907626c
16
CLAUDE.md
16
CLAUDE.md
|
|
@ -618,10 +618,18 @@ restructure; the behavior itself predates it and is unchanged:
|
||||||
no explanation; "not_available"'s case was only noticed and fixed 2026-10-12, after "fail"
|
no explanation; "not_available"'s case was only noticed and fixed 2026-10-12, after "fail"
|
||||||
already had it. On wide viewports the button is wrapped in `.recheck-wrap` with an
|
already had it. On wide viewports the button is wrapped in `.recheck-wrap` with an
|
||||||
invisible `.recheck-spacer` label above it mirroring `.fields label`'s own box (same
|
invisible `.recheck-spacer` label above it mirroring `.fields label`'s own box (same
|
||||||
font-size/margin-bottom) — this is what lines the button's top edge up with the balance
|
font-size/margin-bottom) — this lines the button's top edge up with the balance inputs'
|
||||||
inputs' own top edge rather than the row's labels, without a hardcoded pixel offset that
|
own top edge rather than the row's labels. Matching the top edge alone turned out not
|
||||||
would drift if the label style ever changes. The spacer is hidden at the 640px mobile
|
to be enough (confirmed by the user after the first pass): `.btn-toggle`'s own padding
|
||||||
breakpoint, where the button drops below the fields instead (see above).
|
makes a button naturally shorter than a balance input (which has more vertical padding
|
||||||
|
plus a 1px border), so top-aligning two boxes of different heights still reads as
|
||||||
|
slightly off-center. Fixed by giving both an explicit, equal `height:36px` (flex-
|
||||||
|
centering the button's own text inside it) instead of leaving either height to the
|
||||||
|
browser's own font-metric-driven "auto" — a hardcoded pixel offset would have been
|
||||||
|
fragile to any future font-size/padding change, but equal explicit heights on both
|
||||||
|
elements can't drift apart from each other even if those values are ever touched. The
|
||||||
|
spacer is hidden at the 640px mobile breakpoint, where the button drops below the
|
||||||
|
fields instead (see above).
|
||||||
- Sort + filter/search on the transactions table (`TransactionsTable.vue` +
|
- Sort + filter/search on the transactions table (`TransactionsTable.vue` +
|
||||||
`useTransactionFilters.js`, added 2026-10-12) — purely client-side display state, no
|
`useTransactionFilters.js`, added 2026-10-12) — purely client-side display state, no
|
||||||
backend involvement, same scope as `useImageZoom.js`. Each sortable header (Date,
|
backend involvement, same scope as `useImageZoom.js`. Each sortable header (Date,
|
||||||
|
|
|
||||||
|
|
@ -78,15 +78,23 @@ h1{ font-family:var(--fd); font-weight:800; font-size:30px; letter-spacing:-.01e
|
||||||
/* .recheck-spacer mirrors .fields label's own box (same font-size/
|
/* .recheck-spacer mirrors .fields label's own box (same font-size/
|
||||||
margin-bottom) invisibly, so the button below it starts at exactly the
|
margin-bottom) invisibly, so the button below it starts at exactly the
|
||||||
same y as the balance inputs - aligned with the closing-balance field,
|
same y as the balance inputs - aligned with the closing-balance field,
|
||||||
not the row's top edge (where the labels sit). */
|
not the row's top edge (where the labels sit). Matching the TOP edge
|
||||||
|
alone isn't enough though - .btn-toggle's own padding makes it
|
||||||
|
naturally shorter than a balance input (which has more vertical
|
||||||
|
padding plus a border), so both get the same explicit height below,
|
||||||
|
with the button's text centered in it via flex, instead of leaving
|
||||||
|
either height to the browser's own font-metric-driven "auto". */
|
||||||
.recheck-wrap{ display:flex; flex-direction:column; flex-shrink:0; }
|
.recheck-wrap{ display:flex; flex-direction:column; flex-shrink:0; }
|
||||||
.recheck-spacer{ font-size:11.5px; line-height:1; margin-bottom:6px; visibility:hidden; }
|
.recheck-spacer{ font-size:11.5px; line-height:1; margin-bottom:6px; visibility:hidden; }
|
||||||
.btn-recheck{ flex-shrink:0; white-space:nowrap; }
|
.btn-recheck{
|
||||||
|
flex-shrink:0; white-space:nowrap; height:36px; padding-top:0; padding-bottom:0;
|
||||||
|
display:inline-flex; align-items:center; justify-content:center;
|
||||||
|
}
|
||||||
.fields{ display:flex; flex-wrap:wrap; gap:16px; }
|
.fields{ display:flex; flex-wrap:wrap; gap:16px; }
|
||||||
.fields > div{ flex:1 1 180px; min-width:160px; }
|
.fields > div{ flex:1 1 180px; min-width:160px; }
|
||||||
.fields label{ font-size:11.5px; color:var(--t3); display:block; margin-bottom:6px; white-space:normal; }
|
.fields label{ font-size:11.5px; color:var(--t3); display:block; margin-bottom:6px; white-space:normal; }
|
||||||
.fields input{
|
.fields input{
|
||||||
width:100%; padding:9px 11px; background:var(--navy); border:1px solid var(--border-2);
|
width:100%; height:36px; padding:0 11px; background:var(--navy); border:1px solid var(--border-2);
|
||||||
border-radius:8px; font-size:13px; color:var(--t1); font-family:var(--fb); outline:none; transition:border-color .2s;
|
border-radius:8px; font-size:13px; color:var(--t1); font-family:var(--fb); outline:none; transition:border-color .2s;
|
||||||
}
|
}
|
||||||
.fields input:focus{ border-color:var(--blue); }
|
.fields input:focus{ border-color:var(--blue); }
|
||||||
|
|
|
||||||
|
|
@ -124,7 +124,7 @@ async function handleRecheck() {
|
||||||
</div>
|
</div>
|
||||||
<div v-if="balanceMismatchText" class="error-note visible">{{ balanceMismatchPrefix }}{{ balanceMismatchText }}</div>
|
<div v-if="balanceMismatchText" class="error-note visible">{{ balanceMismatchPrefix }}{{ balanceMismatchText }}</div>
|
||||||
<div class="note">This statement format may not print a clean opening/closing balance — enter them here to run the full statement balance check; otherwise it's marked "not available" rather than guessed.</div>
|
<div class="note">This statement format may not print a clean opening/closing balance — enter them here to run the full statement balance check; otherwise it's marked "not available" rather than guessed.</div>
|
||||||
<div v-if="result" class="note">Click the pencil on a row to edit it, then Save to commit - edits are saved to this browser as you confirm them, row by row.</div>
|
<div v-if="result" class="note"></div>
|
||||||
|
|
||||||
<div v-if="!result" class="empty-panel empty-panel-table">
|
<div v-if="!result" class="empty-panel empty-panel-table">
|
||||||
<p>No Transactions to Display.<br>Upload a source document to get started.</p>
|
<p>No Transactions to Display.<br>Upload a source document to get started.</p>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue