Remember for each user which Kanban cards have their task list open

The open cards are kept in the user's board preferences (expanded_cards,
at most 500), saved without redrawing the board and restored on return.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
2026-11-30 11:25:58 +02:00
co-authored by Claude Opus 5.5
parent e274a8d2b1
commit 9eac4c4d4e
10 changed files with 172 additions and 21 deletions
+19
View File
@@ -193,6 +193,25 @@ it('scrolls only the body of the job editor when a task has many comments', func
->assertNoAccessibilityIssues(level: 2);
});
it('keeps the task list of a card open when the board is opened again', function () {
$this->job->update(['status' => 'in_production']);
TaskModel::factory()->create(['customer_job_id' => $this->job->id, 'title' => 'Leikkaus']);
$toggle = '[aria-controls="tasks-job-'.$this->job->id.'"]';
$panel = 'document.getElementById("tasks-job-'.$this->job->id.'")';
visit(route('jobs.board'))
->on()->desktop()
->click($toggle)
->assertScript($panel.'.offsetParent !== null', true)
->wait(1);
visit(route('jobs.board'))
->on()->desktop()
->assertAttribute($toggle, 'aria-expanded', 'true')
->assertScript($panel.'.offsetParent !== null', true)
->assertNoAccessibilityIssues(level: 2);
});
it('marks a task done from the task panel of a card', function () {
$this->job->update(['status' => 'in_production']);
$task = TaskModel::factory()->create(['customer_job_id' => $this->job->id, 'title' => 'Leikkaus', 'status' => 'in_progress']);