Batch bestiary add produces a single undo entry
Extract addOneFromBestiary (no undo) and build addMultipleFromBestiary on top so confirming N creatures from the bestiary panel creates one undo entry that restores the entire batch, not N individual entries. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -52,6 +52,7 @@ function mockContext(overrides: Partial<Encounter> = {}) {
|
||||
toggleCondition: vi.fn(),
|
||||
toggleConcentration: vi.fn(),
|
||||
addFromBestiary: vi.fn(),
|
||||
addMultipleFromBestiary: vi.fn(),
|
||||
addFromPlayerCharacter: vi.fn(),
|
||||
makeStore: vi.fn(),
|
||||
withUndo: vi.fn((action: () => unknown) => action()),
|
||||
|
||||
Reference in New Issue
Block a user