feat(design): migrate the Incidents list to TableCard with server-side views, sort, filters and paging

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-01 09:33:44 +08:00
co-authored by Claude Haiku 4.5
parent 9ba708ecb7
commit a64b951922
15 changed files with 576 additions and 547 deletions
+7 -1
View File
@@ -1,6 +1,6 @@
import { describe, it, expect, vi } from 'vitest'
import { render, screen, fireEvent } from '@testing-library/react'
import { Button } from '@/components/ui/button'
import { Button, buttonClass } from '@/components/ui/button'
import { StatusTag, PriorityTag, statusHue } from '@/components/ui/status-tag'
import { Checkbox } from '@/components/ui/checkbox'
import { FilterChip } from '@/components/ui/filter-chip'
@@ -35,6 +35,12 @@ describe('Button', () => {
expect(b.className).toContain('h-7')
})
it('buttonClass gives links the same look as buttons', () => {
expect(buttonClass()).toContain('bg-ink-2')
expect(buttonClass('secondary')).toContain('shadow-secondary')
expect(buttonClass('primary', { block: true })).toContain('w-full')
})
it('mobile and block make a full-width 48px button', () => {
render(<Button block mobile>Submit</Button>)
const b = screen.getByRole('button', { name: 'Submit' })