Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 24 additions & 0 deletions frontend/e2e/atlas-select-group.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,30 @@ test('atlas shift-click select: toggle membership, group via member right-click,
await expect(selected).toHaveCount(1)
await cardB.click({ modifiers: ['Shift'] })
await expect(selected).toHaveCount(2)

// Regression: a selected STICKY's ring must survive its yellow
// ground -- the border flips to the accent on selection (the 2px
// card ring alone was invisible over the attention tint).
await page.keyboard.press('n')
const noteBB = await board.boundingBox()
if (!noteBB) throw new Error('board box missing for note placement')
await page.mouse.click(noteBB.x + noteBB.width - 60, noteBB.y + noteBB.height - 80)
const noteTA = page.getByTestId('atlas-sticky-textarea')
await noteTA.fill('ZzK2eStickySel')
await noteTA.blur()
const stickyNote = page.locator('[data-testid="atlas-sticky-note"]')
const restingBorder = await stickyNote.evaluate((el) => getComputedStyle(el).borderColor)
await stickyNote.click({ modifiers: ['Shift'] })
await expect(selected).toHaveCount(3)
const selectedBorder = await stickyNote.evaluate((el) => getComputedStyle(el).borderColor)
expect(selectedBorder).not.toBe(restingBorder)
// Deselect + delete the note so the rest of the flow sees its
// original two-card selection world.
await stickyNote.click({ modifiers: ['Shift'] })
await expect(selected).toHaveCount(2)
await stickyNote.click({ button: 'right' })
await menu.getByText('Delete note', { exact: true }).click()
await expect(stickyNote).toHaveCount(0)
await expect(page.locator('[data-testid="atlas-note-card"][data-flipped="true"]')).toHaveCount(0)
await cardB.click({ modifiers: ['Shift'] })
await expect(selected).toHaveCount(1)
Expand Down
20 changes: 15 additions & 5 deletions frontend/src/atlas/AtlasStickyNode.module.css
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,23 @@
cursor: text;
}

/* Multi-selection outline (owner-caught follow-up to goal 0092): same
box-shadow ring AtlasNoteCardNode.module.css uses, keyed off React
Flow's own .selected on the node's outer wrapper. */
/* Multi-selection outline (owner-caught follow-up to goal 0092),
heavier than the card ring on purpose: the sticky's attention-tinted
ground swallows the 2px accent line cards get away with on white --
a wider ring plus the border flipping to the accent keeps a selected
note legible at board zoom. */
:global(.react-flow__node.selected) .sticky {
border-color: var(--borderColor-accent-emphasis);
box-shadow:
0 0 0 2px var(--borderColor-accent-emphasis),
0 0 0 5px var(--bgColor-accent-muted);
0 0 0 3px var(--borderColor-accent-emphasis),
0 0 0 7px var(--bgColor-accent-muted);
}

/* A pointer click must not flash the webview's OS focus halo (the
"blue flash" over the selection ring); keyboard focus keeps its
visible ring via :focus-visible. */
.sticky:focus:not(:focus-visible) {
outline: none;
}

.text {
Expand Down
Loading