Skip to content
Open
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
4 changes: 2 additions & 2 deletions mods/diff/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,8 +37,8 @@ where the focus ring starts; the plugin follows the ring's walk through
`ui.focus` and re-centres the rows as the built-in does), the key hints;
Enter shows that file's hunks alone,
Escape backs out to the list and then closes, leaving `Diff dialog
dismissed`; toasts are held while it is up. A file's ask button arms that
file: its hunks ride the next prompt as context, once.
dismissed`; toasts show while it is up, as beside the docked pane. A file's
ask button arms that file: its hunks ride the next prompt as context, once.

The pane compares the working tree against HEAD, split at the session's
start (the default; the start the engine gives in `$.session.usage()`, so a
Expand Down
3 changes: 1 addition & 2 deletions mods/diff/hooks/register.ts
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,6 @@ export function register(on: On) {
return {
id: Names.PANE_ID,
title: Names.PANE_TITLE,
holdToasts: true,
closeOnEscape: true,
rows: Views.dialogRowsOf(model),
}
Expand Down Expand Up @@ -439,7 +438,7 @@ export function register(on: On) {
const opened = await engine.openPane(
isDialog
? { ...dialogPane(), focus: true }
: { id: Names.PANE_ID, title: Names.PANE_TITLE, holdToasts: true },
: { id: Names.PANE_ID, title: Names.PANE_TITLE },
)

const isWaiting = isRecord(opened) && opened.isPlaced === false
Expand Down
5 changes: 1 addition & 4 deletions mods/diff/tests/register.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -358,9 +358,7 @@ describe('register', () => {
'--show-toplevel',
)

expect(world.opened).toEqual([
{ id: 'diff', title: 'Diff', holdToasts: true },
])
expect(world.opened).toEqual([{ id: 'diff', title: 'Diff' }])

await world.clock.advance(Fixtures.SETTLE_MS)

Expand All @@ -380,7 +378,6 @@ describe('register', () => {
expect(world.opened[0]).toEqual({
id: 'diff',
title: 'Diff',
holdToasts: true,
closeOnEscape: true,
rows: expect.any(Number),
focus: true,
Expand Down
1 change: 0 additions & 1 deletion mods/diff/tests/views.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -290,7 +290,6 @@ describe('views', () => {
expect(world.opened.at(-1), 'sized to its rows once listed').toEqual({
id: 'diff',
title: 'Diff',
holdToasts: true,
closeOnEscape: true,
rows: 8,
})
Expand Down
Loading