Align Transactions heading with Source Document; move "Move to project" into the title row
The Transactions heading sat below two other rows while Source Document was the first thing in its own column, so the two never lined up. Reordered TransactionsTable.vue's template: the title row (now also hosting "Move to project", moved off its own standalone row) is first, and the former top bar (Results/DocumentNavBar/Accept/Download) drops into the vertical slot that row vacated. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
This commit is contained in:
parent
a898488bcd
commit
4f474fa3ea
42
CLAUDE.md
42
CLAUDE.md
|
|
@ -2643,6 +2643,36 @@ files touched are `TransactionRow.vue` and `main.css`. **Not machine-verified:**
|
|||
the actual click-through in a real browser - same standing limitation as every
|
||||
other UI-only change this project.
|
||||
|
||||
**Transactions column reordered to align with Source Document, and "Move to project"
|
||||
relocated into the title row's own actions, 2026-10-30.** Explicit layout request:
|
||||
the "Transactions" heading sat BELOW two other rows (the Results/DocumentNavBar/
|
||||
Accept/Download top bar, then "Move to project" on its own standalone row), while
|
||||
the sibling panel's "Source Document" heading was the very first thing in ITS column
|
||||
- the two headings never lined up horizontally. Fixed by reordering
|
||||
`TransactionsTable.vue`'s template, not by adding new CSS: `.txn-col-head` is now the
|
||||
first element (matching `SourceDocumentPanel.vue`'s own `.pdf-col-head`, already the
|
||||
first child of its column), `.txn-top-bar` moved down to occupy the vertical slot
|
||||
"Move to project" used to have, and "Move to project" itself moved off its own row
|
||||
and into `.txn-col-head-actions`, alongside Flagged only/Next flagged/Hide Source
|
||||
Doc - one horizontal line instead of three stacked rows above the fields.
|
||||
|
||||
No new CSS was needed for the alignment itself - `.review-grid`'s existing
|
||||
`align-items:start` already lines up both columns' first child at the same top edge,
|
||||
so moving `.txn-col-head` to literally be first was sufficient. `.move-to-project`'s
|
||||
own `margin-bottom:14px` (needed when it was a standalone block row) was dropped
|
||||
since it's now a flex child within `.txn-col-head-actions`'s own row, and the stale
|
||||
code comments on `.txn-top-bar`/`.doc-nav`/`.move-to-project` (each referencing the
|
||||
old order) were updated to match.
|
||||
|
||||
Verified: `npm run build` passes; the `app` container rebuilt, and the served bundle
|
||||
(hash-matched against the local build output) confirmed to contain both
|
||||
`txn-col-head-actions` and `move-to-project`. No backend touched - pure template
|
||||
reordering + a CSS trim, so `backend/measure.py` doesn't apply. **Not machine-
|
||||
verified:** the actual rendered alignment in a real browser - Claude-in-Chrome still
|
||||
did not connect this session (tried again) - same standing limitation as every
|
||||
other UI-only change in this project; this one in particular is worth the user's
|
||||
own look since it's a pure visual-alignment request.
|
||||
|
||||
**Governing rule: never silently correct or exclude data.** This shows up in several
|
||||
concrete places, not just as an abstract principle:
|
||||
- A row with an unusual status (e.g. HSBC's "Cancelled" wires) stays in the output and is
|
||||
|
|
@ -2910,6 +2940,18 @@ restructure; the behavior itself predates it and is unchanged:
|
|||
- A Hide/Show toggle in the Transactions header (`TransactionsTable.vue`, driven by
|
||||
`uiStore.pdfColHidden`, labeled "Hide Source Doc"/"Show Source Doc") collapses the
|
||||
source-doc column so Transactions fills the row.
|
||||
- **The Transactions column's own vertical order, as of 2026-10-30:** `.txn-col-head`
|
||||
(the "Transactions" h2 + its actions row - Flagged only/Next flagged, "Move to
|
||||
project," Hide/Show Source Doc) is the FIRST thing in the column, so it aligns
|
||||
horizontally with `SourceDocumentPanel.vue`'s own "Source Document" heading on the
|
||||
sibling panel - both are simply the first child of a sibling flex column under
|
||||
`.review-grid`'s `align-items:start`, so no extra CSS was needed once each was
|
||||
literally first. The former top bar (Results dropdown/`DocumentNavBar`/Accept/
|
||||
Download, `.txn-top-bar`) moved down to sit second, in the vertical slot "Move to
|
||||
project" used to occupy on its own standalone row - see the next bullet for what it
|
||||
contains. "Move to project" itself moved FROM that standalone row INTO
|
||||
`.txn-col-head-actions`, same horizontal line as Flagged only/Next flagged/Hide
|
||||
Source Doc, rather than its own row.
|
||||
- `TransactionsTable.vue`'s own top bar (replacing the old standalone `ResultCard.vue`,
|
||||
deleted 2026-10-13) is a 3-part row: a "Results" toggle on the left opens a
|
||||
hover-sticky dropdown (click to open; closes automatically once the mouse leaves the
|
||||
|
|
|
|||
|
|
@ -344,9 +344,11 @@ tr.editing td{ background:rgba(37,99,235,.03); }
|
|||
/* ── Top bar: Results (left) / DocumentNavBar (center, TRUE center via
|
||||
grid - not flex space-between, which would only center it when the
|
||||
left/right content happens to be equal width) / Download (right).
|
||||
Sits across the top of the transactions card - no border/background
|
||||
box of its own since it's already inside the card's; a bottom border
|
||||
is enough to separate it from the move-to-project/title rows beneath. */
|
||||
Sits BELOW the Transactions title row now (2026-10-30 - that row
|
||||
moved up to align with "Source Document" on the sibling panel, and
|
||||
this one dropped into the vertical slot it vacated) - no border/
|
||||
background box of its own since it's already inside the card's; a
|
||||
bottom border is enough to separate it from the fields row beneath. */
|
||||
.txn-top-bar{
|
||||
display:grid; grid-template-columns:1fr auto 1fr; align-items:center; gap:12px;
|
||||
padding-bottom:12px; margin-bottom:14px; border-bottom:1px solid var(--border-2);
|
||||
|
|
@ -402,10 +404,10 @@ tr.editing td{ background:rgba(37,99,235,.03); }
|
|||
}
|
||||
.results-dropdown-inner{ margin-bottom:0; }
|
||||
|
||||
/* Sits across the top of the transactions card, above the Hide Source
|
||||
Doc row (TransactionsTable.vue renders it first) - no border/
|
||||
background box of its own since it's already inside the card's; a
|
||||
bottom border is enough to separate it from the title row beneath. */
|
||||
/* Sits below the Transactions title row (TransactionsTable.vue), inside
|
||||
its own .txn-top-bar - no border/background box of its own since it's
|
||||
already inside the card's; a bottom border is enough to separate it
|
||||
from the fields row beneath. */
|
||||
.doc-nav{ display:flex; align-items:center; gap:14px; min-width:0; justify-self:center; }
|
||||
.doc-nav-arrow{
|
||||
background:transparent; border:1px solid var(--border-2); color:var(--t2); width:28px; height:28px;
|
||||
|
|
@ -851,9 +853,12 @@ tr.editing td{ background:rgba(37,99,235,.03); }
|
|||
|
||||
/* Lets the active document be reassigned to a different project even
|
||||
with just one document loaded (independent of DocumentNavBar's own
|
||||
>1-document visibility gate) - sits right below it, above the
|
||||
Transactions/Hide Source Doc row. */
|
||||
.move-to-project{ display:flex; align-items:center; gap:8px; margin-bottom:14px; }
|
||||
>1-document visibility gate). Lives inside .txn-col-head-actions
|
||||
(2026-10-30, moved there from its own standalone row) - same
|
||||
horizontal line as Flagged only/Next flagged/Hide Source Doc, so no
|
||||
margin-bottom of its own anymore (that row's parent already handles
|
||||
spacing via .txn-col-head's own margin-bottom). */
|
||||
.move-to-project{ display:flex; align-items:center; gap:8px; }
|
||||
.move-to-project label{ display:inline-flex; align-items:center; gap:6px; font-size:11.5px; color:var(--t3); flex-shrink:0; }
|
||||
.move-to-project select{
|
||||
height:32px; padding:0 8px; background:var(--navy); border:1px solid var(--border-2);
|
||||
|
|
|
|||
|
|
@ -376,6 +376,61 @@ async function handleAccept() {
|
|||
</script>
|
||||
|
||||
<template>
|
||||
<!--
|
||||
"Transactions" is the first thing in this column (2026-10-30, moved
|
||||
up from beneath the Results/move-to-project rows) so it aligns
|
||||
horizontally with SourceDocumentPanel.vue's own "Source Document"
|
||||
heading - both are the first child of a sibling column under
|
||||
.review-grid's align-items:start, so they land on the same line for
|
||||
free once each is literally first, no extra CSS needed. "Move to
|
||||
project" moved INTO this row's own actions (same horizontal line as
|
||||
Flagged only/Next flagged/Hide Source Doc), vacating the row below
|
||||
the heading - which is exactly where the former top bar (Results/
|
||||
DocumentNavBar/Accept/Download) now sits instead, see below.
|
||||
-->
|
||||
<div class="txn-col-head">
|
||||
<h2>Transactions</h2>
|
||||
<div class="txn-col-head-actions">
|
||||
<template v-if="extractionStore.flaggedIndexes.size > 0">
|
||||
<button
|
||||
type="button"
|
||||
class="btn-toggle"
|
||||
:class="{ 'btn-toggle-active': flaggedOnly }"
|
||||
title="Show only flagged rows"
|
||||
@click="toggleFlaggedOnly"
|
||||
>
|
||||
<i class="fa-solid fa-triangle-exclamation"></i>
|
||||
Flagged only
|
||||
</button>
|
||||
<button type="button" class="btn-toggle" title="Jump to the next flagged row" @click="jumpToNextFlagged">
|
||||
<i class="fa-solid fa-forward-step"></i>
|
||||
Next flagged
|
||||
</button>
|
||||
</template>
|
||||
<div v-if="result" class="move-to-project">
|
||||
<label><i class="fa-solid fa-folder-open"></i>Move to project</label>
|
||||
<select v-model="selectedProjectId" :disabled="movingProject" @change="handleSelectChange">
|
||||
<option v-for="p in projectsStore.projects" :key="p.id" :value="p.id">{{ p.name }}</option>
|
||||
</select>
|
||||
<span v-if="moveConfirmNote" class="move-confirm-note"><i class="fa-solid fa-circle-check"></i>{{ moveConfirmNote }}</span>
|
||||
</div>
|
||||
<button class="btn-toggle" type="button" @click="uiStore.togglePdfCol">
|
||||
<i class="fa-solid" :class="uiStore.pdfColHidden ? 'fa-eye' : 'fa-eye-slash'"></i>
|
||||
{{ toggleLabel }}
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<ConfirmModal
|
||||
:visible="showMoveConfirm"
|
||||
title="Move document?"
|
||||
title-icon="fa-folder-open"
|
||||
:message="`Move “${extractionStore.activeDocument?.fileName}” to “${pendingProjectName}”?`"
|
||||
confirm-label="Move"
|
||||
confirm-icon="fa-folder-open"
|
||||
@confirm="confirmMove"
|
||||
@cancel="cancelMove"
|
||||
/>
|
||||
|
||||
<!--
|
||||
The former ResultCard.vue, merged into this top bar: a Results
|
||||
toggle (left) opens a hover-sticky dropdown with the status/checks
|
||||
|
|
@ -383,7 +438,9 @@ async function handleAccept() {
|
|||
regardless of how wide the left/right content is) carries the active
|
||||
document's filename - click it to rename or delete; Download (right)
|
||||
exports the current document, or opens DownloadChoiceModal to ask
|
||||
"current vs. all" once more than one document is loaded.
|
||||
"current vs. all" once more than one document is loaded. Sits second
|
||||
(2026-10-30, moved down from being this column's first element) -
|
||||
the Transactions heading above it now takes that position instead.
|
||||
-->
|
||||
<div v-if="extractionStore.documents.length > 0" class="txn-top-bar">
|
||||
<div class="results-trigger-wrap" @mouseleave="uiStore.closeResultsOpen">
|
||||
|
|
@ -433,49 +490,6 @@ async function handleAccept() {
|
|||
@all="handleDownloadChoiceAll"
|
||||
@cancel="showDownloadChoice = false"
|
||||
/>
|
||||
|
||||
<div v-if="result" class="move-to-project">
|
||||
<label><i class="fa-solid fa-folder-open"></i>Move to project</label>
|
||||
<select v-model="selectedProjectId" :disabled="movingProject" @change="handleSelectChange">
|
||||
<option v-for="p in projectsStore.projects" :key="p.id" :value="p.id">{{ p.name }}</option>
|
||||
</select>
|
||||
<span v-if="moveConfirmNote" class="move-confirm-note"><i class="fa-solid fa-circle-check"></i>{{ moveConfirmNote }}</span>
|
||||
</div>
|
||||
<ConfirmModal
|
||||
:visible="showMoveConfirm"
|
||||
title="Move document?"
|
||||
title-icon="fa-folder-open"
|
||||
:message="`Move “${extractionStore.activeDocument?.fileName}” to “${pendingProjectName}”?`"
|
||||
confirm-label="Move"
|
||||
confirm-icon="fa-folder-open"
|
||||
@confirm="confirmMove"
|
||||
@cancel="cancelMove"
|
||||
/>
|
||||
<div class="txn-col-head">
|
||||
<h2>Transactions</h2>
|
||||
<div class="txn-col-head-actions">
|
||||
<template v-if="extractionStore.flaggedIndexes.size > 0">
|
||||
<button
|
||||
type="button"
|
||||
class="btn-toggle"
|
||||
:class="{ 'btn-toggle-active': flaggedOnly }"
|
||||
title="Show only flagged rows"
|
||||
@click="toggleFlaggedOnly"
|
||||
>
|
||||
<i class="fa-solid fa-triangle-exclamation"></i>
|
||||
Flagged only
|
||||
</button>
|
||||
<button type="button" class="btn-toggle" title="Jump to the next flagged row" @click="jumpToNextFlagged">
|
||||
<i class="fa-solid fa-forward-step"></i>
|
||||
Next flagged
|
||||
</button>
|
||||
</template>
|
||||
<button class="btn-toggle" type="button" @click="uiStore.togglePdfCol">
|
||||
<i class="fa-solid" :class="uiStore.pdfColHidden ? 'fa-eye' : 'fa-eye-slash'"></i>
|
||||
{{ toggleLabel }}
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
<div class="fields-row">
|
||||
<div class="fields">
|
||||
<div>
|
||||
|
|
|
|||
Loading…
Reference in New Issue