Skip to content

armgit / dify

Public Imported from GitHub
0

Build Agentic workflows, RAG pipelines, with rich AI model and tool support on one collaborative workspace. Deploy on cloud, VPC, or self-hosted, so teams move from prototype to production without rebuilding the stack.

test: browser mode for dify ui (#35365)

Stephen Zhou3c7d6739b5ad
diff --git a/.github/workflows/web-tests.yml b/.github/workflows/web-tests.yml
index dcee8863ce2..2a5cf196452 100644
--- a/.github/workflows/web-tests.yml
+++ b/.github/workflows/web-tests.yml
@@ -109,6 +109,9 @@ jobs:
- name: Setup web environment
uses: ./.github/actions/setup-web
+ - name: Install Chromium for Browser Mode
+ run: vp exec playwright install --with-deps chromium
+
- name: Run dify-ui tests
run: vp test run --coverage --silent=passed-only
diff --git a/eslint.config.mjs b/eslint.config.mjs
index 5e81e95f2f9..ae9fdaff013 100644
--- a/eslint.config.mjs
+++ b/eslint.config.mjs
@@ -13,6 +13,7 @@ export default antfu(
'!e2e/**',
'!eslint.config.mjs',
'!package.json',
+ '!pnpm-workspace.yaml',
'!vite.config.ts',
...original,
],
@@ -35,7 +36,6 @@ export default antfu(
},
},
e18e: false,
- pnpm: false,
},
markdownPreferences.configs.standard,
{
diff --git a/packages/dify-ui/package.json b/packages/dify-ui/package.json
index 2b78b25ed61..b3430ab4ee5 100644
--- a/packages/dify-ui/package.json
+++ b/packages/dify-ui/package.json
@@ -99,15 +99,12 @@
"@storybook/addon-themes": "catalog:",
"@storybook/react-vite": "catalog:",
"@tailwindcss/vite": "catalog:",
- "@testing-library/jest-dom": "catalog:",
- "@testing-library/react": "catalog:",
- "@testing-library/user-event": "catalog:",
"@types/react": "catalog:",
"@types/react-dom": "catalog:",
"@vitejs/plugin-react": "catalog:",
"@vitest/coverage-v8": "catalog:",
"class-variance-authority": "catalog:",
- "happy-dom": "catalog:",
+ "playwright": "catalog:",
"react": "catalog:",
"react-dom": "catalog:",
"storybook": "catalog:",
@@ -115,6 +112,6 @@
"typescript": "catalog:",
"vite": "catalog:",
"vite-plus": "catalog:",
- "vitest": "catalog:"
+ "vitest-browser-react": "catalog:"
}
}
diff --git a/packages/dify-ui/src/alert-dialog/__tests__/index.spec.tsx b/packages/dify-ui/src/alert-dialog/__tests__/index.spec.tsx
index 23fbcb19d62..5248be9a163 100644
--- a/packages/dify-ui/src/alert-dialog/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/alert-dialog/__tests__/index.spec.tsx
@@ -1,5 +1,4 @@
-import { fireEvent, render, screen, waitFor } from '@testing-library/react'
-import { describe, expect, it, vi } from 'vitest'
+import { render } from 'vitest-browser-react'
import {
AlertDialog,
AlertDialogActions,
@@ -11,10 +10,12 @@ import {
AlertDialogTrigger,
} from '../index'
+const asHTMLElement = (element: HTMLElement | SVGElement) => element as HTMLElement
+
describe('AlertDialog wrapper', () => {
describe('Rendering', () => {
- it('should render alert dialog content when dialog is open', () => {
- render(
+ it('should render alert dialog content when dialog is open', async () => {
+ const screen = await render(
<AlertDialog open>
<AlertDialogContent>
<AlertDialogTitle>Confirm Delete</AlertDialogTitle>
@@ -23,13 +24,12 @@ describe('AlertDialog wrapper', () => {
</AlertDialog>,
)
- const dialog = screen.getByRole('alertdialog')
- expect(dialog).toHaveTextContent('Confirm Delete')
- expect(dialog).toHaveTextContent('This action cannot be undone.')
+ await expect.element(screen.getByRole('alertdialog')).toHaveTextContent('Confirm Delete')
+ await expect.element(screen.getByRole('alertdialog')).toHaveTextContent('This action cannot be undone.')
})
- it('should not render content when dialog is closed', () => {
- render(
+ it('should not render content when dialog is closed', async () => {
+ const screen = await render(
<AlertDialog open={false}>
<AlertDialogContent>
<AlertDialogTitle>Hidden Title</AlertDialogTitle>
@@ -37,13 +37,13 @@ describe('AlertDialog wrapper', () => {
</AlertDialog>,
)
- expect(screen.queryByRole('alertdialog')).not.toBeInTheDocument()
+ expect(screen.container.querySelector('[role="alertdialog"]')).not.toBeInTheDocument()
})
})
describe('Props', () => {
- it('should apply custom className to popup', () => {
- render(
+ it('should apply custom className to popup', async () => {
+ const screen = await render(
<AlertDialog open>
<AlertDialogContent className="custom-class">
<AlertDialogTitle>Title</AlertDialogTitle>
@@ -51,12 +51,11 @@ describe('AlertDialog wrapper', () => {
</AlertDialog>,
)
- const dialog = screen.getByRole('alertdialog')
- expect(dialog).toHaveClass('custom-class')
+ await expect.element(screen.getByRole('alertdialog')).toHaveClass('custom-class')
})
- it('should not render a close button by default', () => {
- render(
+ it('should not render a close button by default', async () => {
+ const screen = await render(
<AlertDialog open>
<AlertDialogContent>
<AlertDialogTitle>Title</AlertDialogTitle>
@@ -64,13 +63,13 @@ describe('AlertDialog wrapper', () => {
</AlertDialog>,
)
- expect(screen.queryByRole('button', { name: 'Close' })).not.toBeInTheDocument()
+ expect(() => screen.getByRole('button', { name: 'Close' }).element()).toThrow()
})
})
describe('User Interactions', () => {
it('should open and close dialog when trigger and cancel button are clicked', async () => {
- render(
+ const screen = await render(
<AlertDialog>
<AlertDialogTrigger>Open Dialog</AlertDialogTrigger>
<AlertDialogContent>
@@ -83,21 +82,21 @@ describe('AlertDialog wrapper', () => {
</AlertDialog>,
)
- expect(screen.queryByRole('alertdialog')).not.toBeInTheDocument()
+ expect(screen.container.querySelector('[role="alertdialog"]')).not.toBeInTheDocument()
- fireEvent.click(screen.getByRole('button', { name: 'Open Dialog' }))
- expect(await screen.findByRole('alertdialog')).toHaveTextContent('Action Required')
+ asHTMLElement(screen.getByRole('button', { name: 'Open Dialog' }).element()).click()
+ await expect.element(screen.getByRole('alertdialog')).toHaveTextContent('Action Required')
- fireEvent.click(screen.getByRole('button', { name: 'Cancel' }))
- await waitFor(() => {
- expect(screen.queryByRole('alertdialog')).not.toBeInTheDocument()
+ asHTMLElement(screen.getByRole('button', { name: 'Cancel' }).element()).click()
+ await vi.waitFor(() => {
+ expect(screen.container.querySelector('[role="alertdialog"]')).not.toBeInTheDocument()
})
})
})
describe('Composition Helpers', () => {
- it('should render actions wrapper and default confirm button styles', () => {
- render(
+ it('should render actions wrapper and default confirm button styles', async () => {
+ const screen = await render(
<AlertDialog open>
<AlertDialogContent>
<AlertDialogTitle>Action Required</AlertDialogTitle>
@@ -108,15 +107,14 @@ describe('AlertDialog wrapper', () => {
</AlertDialog>,
)
- expect(screen.getByTestId('actions')).toHaveClass('flex', 'items-start', 'justify-end', 'gap-2', 'self-stretch', 'p-6', 'custom-actions')
- const confirmButton = screen.getByRole('button', { name: 'Confirm' })
- expect(confirmButton).toHaveClass('bg-components-button-destructive-primary-bg')
+ await expect.element(screen.getByTestId('actions')).toHaveClass('flex', 'items-start', 'justify-end', 'gap-2', 'self-stretch', 'p-6', 'custom-actions')
+ await expect.element(screen.getByRole('button', { name: 'Confirm' })).toHaveClass('bg-components-button-destructive-primary-bg')
})
it('should keep dialog open after confirm click and close via cancel helper', async () => {
const onConfirm = vi.fn()
- render(
+ const screen = await render(
<AlertDialog>
<AlertDialogTrigger>Open Dialog</AlertDialogTrigger>
<AlertDialogContent>
@@ -129,16 +127,16 @@ describe('AlertDialog wrapper', () => {
</AlertDialog>,
)
- fireEvent.click(screen.getByRole('button', { name: 'Open Dialog' }))
- expect(await screen.findByRole('alertdialog')).toBeInTheDocument()
+ asHTMLElement(screen.getByRole('button', { name: 'Open Dialog' }).element()).click()
+ await expect.element(screen.getByRole('alertdialog')).toBeInTheDocument()
- fireEvent.click(screen.getByRole('button', { name: 'Confirm' }))
+ asHTMLElement(screen.getByRole('button', { name: 'Confirm' }).element()).click()
expect(onConfirm).toHaveBeenCalledTimes(1)
- expect(screen.getByRole('alertdialog')).toBeInTheDocument()
+ await expect.element(screen.getByRole('alertdialog')).toBeInTheDocument()
- fireEvent.click(screen.getByRole('button', { name: 'Cancel' }))
- await waitFor(() => {
- expect(screen.queryByRole('alertdialog')).not.toBeInTheDocument()
+ asHTMLElement(screen.getByRole('button', { name: 'Cancel' }).element()).click()
+ await vi.waitFor(() => {
+ expect(screen.container.querySelector('[role="alertdialog"]')).not.toBeInTheDocument()
})
})
})
diff --git a/packages/dify-ui/src/avatar/__tests__/index.spec.tsx b/packages/dify-ui/src/avatar/__tests__/index.spec.tsx
index 8a384139c2f..b0ea4962822 100644
--- a/packages/dify-ui/src/avatar/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/avatar/__tests__/index.spec.tsx
@@ -1,25 +1,25 @@
-import { render, screen } from '@testing-library/react'
+import { render } from 'vitest-browser-react'
import { Avatar, AvatarFallback, AvatarImage, AvatarRoot } from '..'
describe('Avatar', () => {
describe('Rendering', () => {
- it('should keep the fallback visible when avatar URL is provided before image load', () => {
- render(<Avatar name="John Doe" avatar="https://example.com/avatar.jpg" />)
+ it('should keep the fallback visible when avatar URL is provided before image load', async () => {
+ const screen = await render(<Avatar name="John Doe" avatar="https://example.com/avatar.jpg" />)
- expect(screen.getByText('J')).toBeInTheDocument()
+ await expect.element(screen.getByText('J')).toBeInTheDocument()
})
- it('should render fallback with uppercase initial when avatar is null', () => {
- render(<Avatar name="alice" avatar={null} />)
+ it('should render fallback with uppercase initial when avatar is null', async () => {
+ const screen = await render(<Avatar name="alice" avatar={null} />)
- expect(screen.queryByRole('img')).not.toBeInTheDocument()
- expect(screen.getByText('A')).toBeInTheDocument()
+ expect(screen.container.querySelector('img')).not.toBeInTheDocument()
+ await expect.element(screen.getByText('A')).toBeInTheDocument()
})
- it('should render the fallback when avatar is provided', () => {
- render(<Avatar name="John" avatar="https://example.com/avatar.jpg" />)
+ it('should render the fallback when avatar is provided', async () => {
+ const screen = await render(<Avatar name="John" avatar="https://example.com/avatar.jpg" />)
- expect(screen.getByText('J')).toBeInTheDocument()
+ await expect.element(screen.getByText('J')).toBeInTheDocument()
})
})
@@ -33,36 +33,36 @@ describe('Avatar', () => {
{ size: 'xl' as const, expectedClass: 'size-10' },
{ size: '2xl' as const, expectedClass: 'size-12' },
{ size: '3xl' as const, expectedClass: 'size-16' },
- ])('should apply $expectedClass for size="$size"', ({ size, expectedClass }) => {
- const { container } = render(<Avatar name="Test" avatar={null} size={size} />)
+ ])('should apply $expectedClass for size="$size"', async ({ size, expectedClass }) => {
+ const screen = await render(<Avatar name="Test" avatar={null} size={size} />)
- const root = container.firstElementChild as HTMLElement
+ const root = screen.container.firstElementChild as HTMLElement
expect(root).toHaveClass(expectedClass)
})
- it('should default to md size when size is not specified', () => {
- const { container } = render(<Avatar name="Test" avatar={null} />)
+ it('should default to md size when size is not specified', async () => {
+ const screen = await render(<Avatar name="Test" avatar={null} />)
- const root = container.firstElementChild as HTMLElement
+ const root = screen.container.firstElementChild as HTMLElement
expect(root).toHaveClass('size-8')
})
})
describe('className prop', () => {
- it('should merge className with avatar variant classes on root', () => {
- const { container } = render(
+ it('should merge className with avatar variant classes on root', async () => {
+ const screen = await render(
<Avatar name="Test" avatar={null} className="custom-class" />,
)
- const root = container.firstElementChild as HTMLElement
+ const root = screen.container.firstElementChild as HTMLElement
expect(root).toHaveClass('custom-class')
expect(root).toHaveClass('rounded-full', 'bg-primary-600')
})
})
describe('Primitives', () => {
- it('should support composed avatar usage through exported primitives', () => {
- render(
+ it('should support composed avatar usage through exported primitives', async () => {
+ const screen = await render(
<AvatarRoot size="sm" data-testid="avatar-root">
<AvatarImage src="https://example.com/avatar.jpg" alt="Jane Doe" />
<AvatarFallback size="sm" style={{ backgroundColor: 'rgb(1, 2, 3)' }}>
@@ -71,17 +71,17 @@ describe('Avatar', () => {
</AvatarRoot>,
)
- expect(screen.getByTestId('avatar-root')).toHaveClass('size-6')
- expect(screen.getByText('J')).toBeInTheDocument()
- expect(screen.getByText('J')).toHaveStyle({ backgroundColor: 'rgb(1, 2, 3)' })
+ await expect.element(screen.getByTestId('avatar-root')).toHaveClass('size-6')
+ await expect.element(screen.getByText('J')).toBeInTheDocument()
+ await expect.element(screen.getByText('J')).toHaveStyle({ backgroundColor: 'rgb(1, 2, 3)' })
})
})
describe('Edge Cases', () => {
- it('should handle empty string name gracefully', () => {
- const { container } = render(<Avatar name="" avatar={null} />)
+ it('should handle empty string name gracefully', async () => {
+ const screen = await render(<Avatar name="" avatar={null} />)
- const fallback = container.querySelector('.text-white') as HTMLElement
+ const fallback = screen.container.querySelector('.text-white') as HTMLElement
expect(fallback).toBeInTheDocument()
expect(fallback.textContent).toBe('')
})
@@ -89,23 +89,23 @@ describe('Avatar', () => {
it.each([
{ name: '中文名', expected: '中', label: 'Chinese characters' },
{ name: '123User', expected: '1', label: 'number' },
- ])('should display first character when name starts with $label', ({ name, expected }) => {
- render(<Avatar name={name} avatar={null} />)
+ ])('should display first character when name starts with $label', async ({ name, expected }) => {
+ const screen = await render(<Avatar name={name} avatar={null} />)
- expect(screen.getByText(expected)).toBeInTheDocument()
+ await expect.element(screen.getByText(expected)).toBeInTheDocument()
})
- it('should handle empty string avatar as falsy value', () => {
- render(<Avatar name="Test" avatar={'' as string | null} />)
+ it('should handle empty string avatar as falsy value', async () => {
+ const screen = await render(<Avatar name="Test" avatar={'' as string | null} />)
- expect(screen.queryByRole('img')).not.toBeInTheDocument()
- expect(screen.getByText('T')).toBeInTheDocument()
+ expect(screen.container.querySelector('img')).not.toBeInTheDocument()
+ await expect.element(screen.getByText('T')).toBeInTheDocument()
})
})
describe('onLoadingStatusChange', () => {
- it('should render the fallback when avatar and onLoadingStatusChange are provided', () => {
- render(
+ it('should render the fallback when avatar and onLoadingStatusChange are provided', async () => {
+ const screen = await render(
<Avatar
name="John"
avatar="https://example.com/avatar.jpg"
@@ -113,16 +113,16 @@ describe('Avatar', () => {
/>,
)
- expect(screen.getByText('J')).toBeInTheDocument()
+ await expect.element(screen.getByText('J')).toBeInTheDocument()
})
- it('should not render image when avatar is null even with onLoadingStatusChange', () => {
+ it('should not render image when avatar is null even with onLoadingStatusChange', async () => {
const onStatusChange = vi.fn()
- render(
+ const screen = await render(
<Avatar name="John" avatar={null} onLoadingStatusChange={onStatusChange} />,
)
- expect(screen.queryByRole('img')).not.toBeInTheDocument()
+ expect(screen.container.querySelector('img')).not.toBeInTheDocument()
})
})
})
diff --git a/packages/dify-ui/src/button/__tests__/index.spec.tsx b/packages/dify-ui/src/button/__tests__/index.spec.tsx
index e7b9c92c91c..f3694c29af7 100644
--- a/packages/dify-ui/src/button/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/button/__tests__/index.spec.tsx
@@ -1,46 +1,48 @@
-import { fireEvent, render, screen } from '@testing-library/react'
+import { render } from 'vitest-browser-react'
import { Button } from '../index'
+const asHTMLElement = (element: HTMLElement | SVGElement) => element as HTMLElement
+
describe('Button', () => {
describe('rendering', () => {
- it('renders children text', () => {
- render(<Button>Click me</Button>)
- expect(screen.getByRole('button')).toHaveTextContent('Click me')
+ it('renders children text', async () => {
+ const screen = await render(<Button>Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveTextContent('Click me')
})
- it('renders as a native button element by default', () => {
- render(<Button>Click me</Button>)
- expect(screen.getByRole('button').tagName).toBe('BUTTON')
+ it('renders as a native button element by default', async () => {
+ const screen = await render(<Button>Click me</Button>)
+ expect(screen.getByRole('button').element().tagName).toBe('BUTTON')
})
- it('defaults to type="button"', () => {
- render(<Button>Click me</Button>)
- expect(screen.getByRole('button')).toHaveAttribute('type', 'button')
+ it('defaults to type="button"', async () => {
+ const screen = await render(<Button>Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveAttribute('type', 'button')
})
- it('allows type override to submit', () => {
- render(<Button type="submit">Submit</Button>)
- expect(screen.getByRole('button')).toHaveAttribute('type', 'submit')
+ it('allows type override to submit', async () => {
+ const screen = await render(<Button type="submit">Submit</Button>)
+ await expect.element(screen.getByRole('button')).toHaveAttribute('type', 'submit')
})
- it('renders custom element via render prop', () => {
- render(<Button render={<a href="/test" />}>Link</Button>)
- const link = screen.getByRole('link')
- expect(link).toHaveTextContent('Link')
- expect(link).toHaveAttribute('href', '/test')
+ it('renders custom element via render prop', async () => {
+ const screen = await render(<Button nativeButton={false} render={<a href="/test" />}>Link</Button>)
+ const button = screen.getByRole('button', { name: 'Link' }).element()
+ expect(button.tagName).toBe('A')
+ expect(button).toHaveAttribute('href', '/test')
})
- it('applies base layout classes', () => {
- render(<Button>Click me</Button>)
- const btn = screen.getByRole('button')
+ it('applies base layout classes', async () => {
+ const screen = await render(<Button>Click me</Button>)
+ const btn = screen.getByRole('button').element()
expect(btn).toHaveClass('inline-flex', 'justify-center', 'items-center', 'cursor-pointer')
})
})
describe('variants', () => {
- it('applies default secondary variant', () => {
- render(<Button>Click me</Button>)
- const btn = screen.getByRole('button')
+ it('applies default secondary variant', async () => {
+ const screen = await render(<Button>Click me</Button>)
+ const btn = screen.getByRole('button').element()
expect(btn).toHaveClass('bg-components-button-secondary-bg', 'text-components-button-secondary-text')
})
@@ -51,124 +53,124 @@ describe('Button', () => {
{ variant: 'ghost' as const, expectedClass: 'text-components-button-ghost-text' },
{ variant: 'ghost-accent' as const, expectedClass: 'hover:bg-state-accent-hover' },
{ variant: 'tertiary' as const, expectedClass: 'bg-components-button-tertiary-bg' },
- ])('applies $variant variant', ({ variant, expectedClass }) => {
- render(<Button variant={variant}>Click me</Button>)
- expect(screen.getByRole('button')).toHaveClass(expectedClass)
+ ])('applies $variant variant', async ({ variant, expectedClass }) => {
+ const screen = await render(<Button variant={variant}>Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveClass(expectedClass)
})
- it('applies destructive tone with default variant', () => {
- render(<Button tone="destructive">Click me</Button>)
- expect(screen.getByRole('button')).toHaveClass('bg-components-button-destructive-secondary-bg')
+ it('applies destructive tone with default variant', async () => {
+ const screen = await render(<Button tone="destructive">Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveClass('bg-components-button-destructive-secondary-bg')
})
- it('applies destructive tone with primary variant', () => {
- render(<Button variant="primary" tone="destructive">Click me</Button>)
- expect(screen.getByRole('button')).toHaveClass('bg-components-button-destructive-primary-bg')
+ it('applies destructive tone with primary variant', async () => {
+ const screen = await render(<Button variant="primary" tone="destructive">Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveClass('bg-components-button-destructive-primary-bg')
})
- it('applies destructive tone with tertiary variant', () => {
- render(<Button variant="tertiary" tone="destructive">Click me</Button>)
- expect(screen.getByRole('button')).toHaveClass('bg-components-button-destructive-tertiary-bg')
+ it('applies destructive tone with tertiary variant', async () => {
+ const screen = await render(<Button variant="tertiary" tone="destructive">Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveClass('bg-components-button-destructive-tertiary-bg')
})
- it('applies destructive tone with ghost variant', () => {
- render(<Button variant="ghost" tone="destructive">Click me</Button>)
- expect(screen.getByRole('button')).toHaveClass('text-components-button-destructive-ghost-text')
+ it('applies destructive tone with ghost variant', async () => {
+ const screen = await render(<Button variant="ghost" tone="destructive">Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveClass('text-components-button-destructive-ghost-text')
})
})
describe('sizes', () => {
- it('applies default medium size', () => {
- render(<Button>Click me</Button>)
- expect(screen.getByRole('button')).toHaveClass('h-8', 'rounded-lg')
+ it('applies default medium size', async () => {
+ const screen = await render(<Button>Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveClass('h-8', 'rounded-lg')
})
it.each([
{ size: 'small' as const, expectedClass: 'h-6' },
{ size: 'medium' as const, expectedClass: 'h-8' },
{ size: 'large' as const, expectedClass: 'h-9' },
- ])('applies $size size', ({ size, expectedClass }) => {
- render(<Button size={size}>Click me</Button>)
- expect(screen.getByRole('button')).toHaveClass(expectedClass)
+ ])('applies $size size', async ({ size, expectedClass }) => {
+ const screen = await render(<Button size={size}>Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveClass(expectedClass)
})
})
describe('loading', () => {
- it('shows spinner when loading', () => {
- render(<Button loading>Click me</Button>)
- expect(screen.getByRole('button').querySelector('[aria-hidden="true"]')).toBeInTheDocument()
+ it('shows spinner when loading', async () => {
+ const screen = await render(<Button loading>Click me</Button>)
+ expect(screen.getByRole('button').element().querySelector('[aria-hidden="true"]')).toBeInTheDocument()
})
- it('hides spinner when not loading', () => {
- render(<Button loading={false}>Click me</Button>)
- expect(screen.getByRole('button').querySelector('[aria-hidden="true"]')).not.toBeInTheDocument()
+ it('hides spinner when not loading', async () => {
+ const screen = await render(<Button loading={false}>Click me</Button>)
+ expect(screen.getByRole('button').element().querySelector('[aria-hidden="true"]')).not.toBeInTheDocument()
})
- it('auto-disables when loading', () => {
- render(<Button loading>Click me</Button>)
- expect(screen.getByRole('button')).toBeDisabled()
+ it('auto-disables when loading', async () => {
+ const screen = await render(<Button loading>Click me</Button>)
+ await expect.element(screen.getByRole('button')).toBeDisabled()
})
- it('sets aria-busy when loading', () => {
- render(<Button loading>Click me</Button>)
- expect(screen.getByRole('button')).toHaveAttribute('aria-busy', 'true')
+ it('sets aria-busy when loading', async () => {
+ const screen = await render(<Button loading>Click me</Button>)
+ await expect.element(screen.getByRole('button')).toHaveAttribute('aria-busy', 'true')
})
- it('does not set aria-busy when not loading', () => {
- render(<Button>Click me</Button>)
- expect(screen.getByRole('button')).not.toHaveAttribute('aria-busy')
+ it('does not set aria-busy when not loading', async () => {
+ const screen = await render(<Button>Click me</Button>)
+ await expect.element(screen.getByRole('button')).not.toHaveAttribute('aria-busy')
})
})
describe('disabled', () => {
- it('disables button when disabled prop is set', () => {
- render(<Button disabled>Click me</Button>)
- expect(screen.getByRole('button')).toBeDisabled()
+ it('disables button when disabled prop is set', async () => {
+ const screen = await render(<Button disabled>Click me</Button>)
+ await expect.element(screen.getByRole('button')).toBeDisabled()
})
- it('keeps focusable when loading with focusableWhenDisabled', () => {
- render(<Button loading focusableWhenDisabled>Loading</Button>)
- const button = screen.getByRole('button')
+ it('keeps focusable when loading with focusableWhenDisabled', async () => {
+ const screen = await render(<Button loading focusableWhenDisabled>Loading</Button>)
+ const button = screen.getByRole('button').element()
expect(button).toHaveAttribute('aria-disabled', 'true')
})
})
describe('events', () => {
- it('fires onClick when clicked', () => {
+ it('fires onClick when clicked', async () => {
const onClick = vi.fn()
- render(<Button onClick={onClick}>Click me</Button>)
- fireEvent.click(screen.getByRole('button'))
+ const screen = await render(<Button onClick={onClick}>Click me</Button>)
+ await screen.getByRole('button').click()
expect(onClick).toHaveBeenCalledTimes(1)
})
- it('does not fire onClick when disabled', () => {
+ it('does not fire onClick when disabled', async () => {
const onClick = vi.fn()
- render(<Button onClick={onClick} disabled>Click me</Button>)
- fireEvent.click(screen.getByRole('button'))
+ const screen = await render(<Button onClick={onClick} disabled>Click me</Button>)
+ asHTMLElement(screen.getByRole('button').element()).click()
expect(onClick).not.toHaveBeenCalled()
})
- it('does not fire onClick when loading', () => {
+ it('does not fire onClick when loading', async () => {
const onClick = vi.fn()
- render(<Button onClick={onClick} loading>Click me</Button>)
- fireEvent.click(screen.getByRole('button'))
+ const screen = await render(<Button onClick={onClick} loading>Click me</Button>)
+ asHTMLElement(screen.getByRole('button').element()).click()
expect(onClick).not.toHaveBeenCalled()
})
})
describe('className merging', () => {
- it('merges custom className with variant classes', () => {
- render(<Button className="custom-class">Click me</Button>)
- const btn = screen.getByRole('button')
+ it('merges custom className with variant classes', async () => {
+ const screen = await render(<Button className="custom-class">Click me</Button>)
+ const btn = screen.getByRole('button').element()
expect(btn).toHaveClass('custom-class')
expect(btn).toHaveClass('inline-flex')
})
})
describe('ref forwarding', () => {
- it('forwards ref to the button element', () => {
+ it('forwards ref to the button element', async () => {
let buttonRef: HTMLButtonElement | null = null
- render(
+ await render(
<Button ref={(el) => {
buttonRef = el
}}
diff --git a/packages/dify-ui/src/context-menu/__tests__/index.spec.tsx b/packages/dify-ui/src/context-menu/__tests__/index.spec.tsx
index 7146f3b15eb..6e1fdacb65b 100644
--- a/packages/dify-ui/src/context-menu/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/context-menu/__tests__/index.spec.tsx
@@ -1,5 +1,4 @@
-import { fireEvent, render, screen, within } from '@testing-library/react'
-import { describe, expect, it, vi } from 'vitest'
+import { render } from 'vitest-browser-react'
import {
ContextMenu,
ContextMenuContent,
@@ -12,10 +11,16 @@ import {
ContextMenuTrigger,
} from '../index'
+const renderWithSafeViewport = (ui: import('react').ReactNode) => render(
+ <div style={{ minHeight: '100vh', minWidth: '100vw', padding: '240px' }}>
+ {ui}
+ </div>,
+)
+
describe('context-menu wrapper', () => {
describe('ContextMenuContent', () => {
- it('should position content at bottom-start with default placement when props are omitted', () => {
- render(
+ it('should position content at bottom-start with default placement when props are omitted', async () => {
+ const screen = await renderWithSafeViewport(
<ContextMenu open>
<ContextMenuTrigger aria-label="context trigger">Open</ContextMenuTrigger>
<ContextMenuContent positionerProps={{ 'role': 'group', 'aria-label': 'content positioner' }}>
@@ -24,15 +29,13 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- const positioner = screen.getByRole('group', { name: 'content positioner' })
- const popup = screen.getByRole('menu')
- expect(positioner).toHaveAttribute('data-side', 'bottom')
- expect(positioner).toHaveAttribute('data-align', 'start')
- expect(within(popup).getByRole('menuitem', { name: 'Content action' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('group', { name: 'content positioner' })).toHaveAttribute('data-side', 'bottom')
+ await expect.element(screen.getByRole('group', { name: 'content positioner' })).toHaveAttribute('data-align', 'start')
+ await expect.element(screen.getByRole('menuitem', { name: 'Content action' })).toBeInTheDocument()
})
- it('should apply custom placement when custom positioning props are provided', () => {
- render(
+ it('should apply custom top placement and keep point-anchor alignment stable when custom positioning props are provided', async () => {
+ const screen = await renderWithSafeViewport(
<ContextMenu open>
<ContextMenuTrigger aria-label="context trigger">Open</ContextMenuTrigger>
<ContextMenuContent
@@ -46,18 +49,16 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- const positioner = screen.getByRole('group', { name: 'custom content positioner' })
- const popup = screen.getByRole('menu')
- expect(positioner).toHaveAttribute('data-side', 'top')
- expect(positioner).toHaveAttribute('data-align', 'end')
- expect(within(popup).getByRole('menuitem', { name: 'Custom content' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('group', { name: 'custom content positioner' })).toHaveAttribute('data-side', 'top')
+ await expect.element(screen.getByRole('group', { name: 'custom content positioner' })).toHaveAttribute('data-align', 'start')
+ await expect.element(screen.getByRole('menuitem', { name: 'Custom content' })).toBeInTheDocument()
})
- it('should forward passthrough attributes and handlers when positionerProps and popupProps are provided', () => {
+ it('should forward passthrough attributes and handlers when positionerProps and popupProps are provided', async () => {
const handlePositionerMouseEnter = vi.fn()
const handlePopupClick = vi.fn()
- render(
+ const screen = await render(
<ContextMenu open>
<ContextMenuTrigger aria-label="context trigger">Open</ContextMenuTrigger>
<ContextMenuContent
@@ -78,20 +79,19 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- const positioner = screen.getByRole('group', { name: 'context content positioner' })
- const popup = screen.getByRole('menu')
- fireEvent.mouseEnter(positioner)
- fireEvent.click(popup)
- expect(positioner).toHaveAttribute('id', 'context-content-positioner')
- expect(popup).toHaveAttribute('id', 'context-content-popup')
+ await screen.getByRole('group', { name: 'context content positioner' }).hover()
+ await screen.getByRole('menu').click()
+
+ await expect.element(screen.getByRole('group', { name: 'context content positioner' })).toHaveAttribute('id', 'context-content-positioner')
+ await expect.element(screen.getByRole('menu')).toHaveAttribute('id', 'context-content-popup')
expect(handlePositionerMouseEnter).toHaveBeenCalledTimes(1)
expect(handlePopupClick).toHaveBeenCalledTimes(1)
})
})
describe('ContextMenuSubContent', () => {
- it('should position sub-content at right-start with default placement when props are omitted', () => {
- render(
+ it('should position sub-content at right-start with default placement when props are omitted', async () => {
+ const screen = await renderWithSafeViewport(
<ContextMenu open>
<ContextMenuTrigger aria-label="context trigger">Open</ContextMenuTrigger>
<ContextMenuContent>
@@ -105,18 +105,17 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- const positioner = screen.getByRole('group', { name: 'sub positioner' })
- expect(positioner).toHaveAttribute('data-side', 'right')
- expect(positioner).toHaveAttribute('data-align', 'start')
- expect(screen.getByRole('menuitem', { name: 'Sub action' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('group', { name: 'sub positioner' })).toHaveAttribute('data-side', 'right')
+ await expect.element(screen.getByRole('group', { name: 'sub positioner' })).toHaveAttribute('data-align', 'start')
+ await expect.element(screen.getByRole('menuitem', { name: 'Sub action' })).toBeInTheDocument()
})
})
describe('variant prop behavior', () => {
- it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant on item when variant is %s', (variant) => {
+ it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant on item when variant is %s', async (variant) => {
const handleClick = vi.fn()
- render(
+ const screen = await render(
<ContextMenu open>
<ContextMenuTrigger aria-label="context trigger">Open</ContextMenuTrigger>
<ContextMenuContent>
@@ -132,17 +131,16 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- const item = screen.getByRole('menuitem', { name: 'menu action' })
- fireEvent.click(item)
- expect(item).toHaveAttribute('id', `context-item-${variant}`)
- expect(item).toHaveAttribute('data-variant', variant)
+ await screen.getByRole('menuitem', { name: 'menu action' }).click()
+ await expect.element(screen.getByRole('menuitem', { name: 'menu action' })).toHaveAttribute('id', `context-item-${variant}`)
+ await expect.element(screen.getByRole('menuitem', { name: 'menu action' })).toHaveAttribute('data-variant', variant)
expect(handleClick).toHaveBeenCalledTimes(1)
})
- it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant on submenu trigger when variant is %s', (variant) => {
+ it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant on submenu trigger when variant is %s', async (variant) => {
const handleClick = vi.fn()
- render(
+ const screen = await render(
<ContextMenu open>
<ContextMenuTrigger aria-label="context trigger">Open</ContextMenuTrigger>
<ContextMenuContent>
@@ -160,15 +158,14 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- const trigger = screen.getByRole('menuitem', { name: 'submenu action' })
- fireEvent.click(trigger)
- expect(trigger).toHaveAttribute('id', `context-sub-${variant}`)
- expect(trigger).toHaveAttribute('data-variant', variant)
+ await screen.getByRole('menuitem', { name: 'submenu action' }).click()
+ await expect.element(screen.getByRole('menuitem', { name: 'submenu action' })).toHaveAttribute('id', `context-sub-${variant}`)
+ await expect.element(screen.getByRole('menuitem', { name: 'submenu action' })).toHaveAttribute('data-variant', variant)
expect(handleClick).toHaveBeenCalledTimes(1)
})
- it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant on link item when variant is %s', (variant) => {
- render(
+ it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant on link item when variant is %s', async (variant) => {
+ const screen = await render(
<ContextMenu open>
<ContextMenuTrigger aria-label="context trigger">Open</ContextMenuTrigger>
<ContextMenuContent>
@@ -186,7 +183,7 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- const link = screen.getByRole('menuitem', { name: 'context docs link' })
+ const link = screen.getByRole('menuitem', { name: 'context docs link' }).element()
expect(link.tagName.toLowerCase()).toBe('a')
expect(link).toHaveAttribute('id', `context-link-${variant}`)
expect(link).toHaveAttribute('data-variant', variant)
@@ -194,8 +191,8 @@ describe('context-menu wrapper', () => {
})
describe('ContextMenuLinkItem close behavior', () => {
- it('should keep link semantics and not leak closeOnClick prop when closeOnClick is false', () => {
- render(
+ it('should keep link semantics and not leak closeOnClick prop when closeOnClick is false', async () => {
+ const screen = await render(
<ContextMenu open>
<ContextMenuTrigger aria-label="context trigger">Open</ContextMenuTrigger>
<ContextMenuContent>
@@ -210,7 +207,7 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- const link = screen.getByRole('menuitem', { name: 'docs link' })
+ const link = screen.getByRole('menuitem', { name: 'docs link' }).element()
expect(link.tagName.toLowerCase()).toBe('a')
expect(link).toHaveAttribute('href', 'https://example.com/docs')
expect(link).not.toHaveAttribute('closeOnClick')
@@ -218,8 +215,8 @@ describe('context-menu wrapper', () => {
})
describe('ContextMenuTrigger interaction', () => {
- it('should open menu when right-clicking trigger area', () => {
- render(
+ it('should open menu when right-clicking trigger area', async () => {
+ const screen = await render(
<ContextMenu>
<ContextMenuTrigger aria-label="context trigger area">
Trigger area
@@ -230,15 +227,19 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- const trigger = screen.getByLabelText('context trigger area')
- fireEvent.contextMenu(trigger)
- expect(screen.getByRole('menuitem', { name: 'Open on right click' })).toBeInTheDocument()
+ screen.getByLabelText('context trigger area').element().dispatchEvent(new MouseEvent('contextmenu', {
+ bubbles: true,
+ cancelable: true,
+ button: 2,
+ }))
+
+ await expect.element(screen.getByRole('menuitem', { name: 'Open on right click' })).toBeInTheDocument()
})
})
describe('ContextMenuSeparator', () => {
- it('should render separator and keep surrounding rows when separator is between items', () => {
- render(
+ it('should render separator and keep surrounding rows when separator is between items', async () => {
+ const screen = await render(
<ContextMenu open>
<ContextMenuTrigger aria-label="context trigger">Open</ContextMenuTrigger>
<ContextMenuContent>
@@ -249,9 +250,9 @@ describe('context-menu wrapper', () => {
</ContextMenu>,
)
- expect(screen.getByRole('menuitem', { name: 'First action' })).toBeInTheDocument()
- expect(screen.getByRole('menuitem', { name: 'Second action' })).toBeInTheDocument()
- expect(screen.getAllByRole('separator')).toHaveLength(1)
+ await expect.element(screen.getByRole('menuitem', { name: 'First action' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('menuitem', { name: 'Second action' })).toBeInTheDocument()
+ expect(screen.getByRole('separator').elements()).toHaveLength(1)
})
})
})
diff --git a/packages/dify-ui/src/dialog/__tests__/index.spec.tsx b/packages/dify-ui/src/dialog/__tests__/index.spec.tsx
index 55f4e532887..e2126d1441e 100644
--- a/packages/dify-ui/src/dialog/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/dialog/__tests__/index.spec.tsx
@@ -1,5 +1,4 @@
-import { fireEvent, render, screen } from '@testing-library/react'
-import { describe, expect, it, vi } from 'vitest'
+import { render } from 'vitest-browser-react'
import {
Dialog,
DialogCloseButton,
@@ -8,10 +7,12 @@ import {
DialogTitle,
} from '../index'
+const asHTMLElement = (element: HTMLElement | SVGElement) => element as HTMLElement
+
describe('Dialog wrapper', () => {
describe('Rendering', () => {
- it('should render dialog content when dialog is open', () => {
- render(
+ it('should render dialog content when dialog is open', async () => {
+ const screen = await render(
<Dialog open>
<DialogContent>
<DialogTitle>Dialog Title</DialogTitle>
@@ -20,15 +21,14 @@ describe('Dialog wrapper', () => {
</Dialog>,
)
- const dialog = screen.getByRole('dialog')
- expect(dialog).toHaveTextContent('Dialog Title')
- expect(dialog).toHaveTextContent('Dialog Description')
+ await expect.element(screen.getByRole('dialog')).toHaveTextContent('Dialog Title')
+ await expect.element(screen.getByRole('dialog')).toHaveTextContent('Dialog Description')
})
})
describe('Props', () => {
- it('should not render close button when DialogCloseButton is not provided', () => {
- render(
+ it('should not render close button when DialogCloseButton is not provided', async () => {
+ const screen = await render(
<Dialog open>
<DialogContent>
<span>Dialog body</span>
@@ -36,11 +36,11 @@ describe('Dialog wrapper', () => {
</Dialog>,
)
- expect(screen.queryByRole('button', { name: 'Close' })).not.toBeInTheDocument()
+ expect(() => screen.getByRole('button', { name: 'Close' }).element()).toThrow()
})
- it('should render explicit close button with custom aria-label', () => {
- render(
+ it('should render explicit close button with custom aria-label', async () => {
+ const screen = await render(
<Dialog open>
<DialogContent>
<DialogCloseButton aria-label="Dismiss dialog" />
@@ -49,11 +49,11 @@ describe('Dialog wrapper', () => {
</Dialog>,
)
- expect(screen.getByRole('button', { name: 'Dismiss dialog' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('button', { name: 'Dismiss dialog' })).toBeInTheDocument()
})
- it('should render default close button label when aria-label is omitted', () => {
- render(
+ it('should render default close button label when aria-label is omitted', async () => {
+ const screen = await render(
<Dialog open>
<DialogContent>
<DialogCloseButton />
@@ -62,12 +62,12 @@ describe('Dialog wrapper', () => {
</Dialog>,
)
- expect(screen.getByRole('button', { name: 'Close' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('button', { name: 'Close' })).toBeInTheDocument()
})
- it('should forward close button props to base primitive', () => {
+ it('should forward close button props to base primitive', async () => {
const onClick = vi.fn()
- render(
+ const screen = await render(
<Dialog open>
<DialogContent>
<DialogCloseButton data-testid="close-button" disabled onClick={onClick} />
@@ -77,8 +77,8 @@ describe('Dialog wrapper', () => {
)
const closeButton = screen.getByTestId('close-button')
- expect(closeButton).toBeDisabled()
- fireEvent.click(closeButton)
+ await expect.element(closeButton).toBeDisabled()
+ asHTMLElement(closeButton.element()).click()
expect(onClick).not.toHaveBeenCalled()
})
})
diff --git a/packages/dify-ui/src/dropdown-menu/__tests__/index.spec.tsx b/packages/dify-ui/src/dropdown-menu/__tests__/index.spec.tsx
index 89b1ebf1004..a9753a84447 100644
--- a/packages/dify-ui/src/dropdown-menu/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/dropdown-menu/__tests__/index.spec.tsx
@@ -1,5 +1,4 @@
-import { fireEvent, render, screen, within } from '@testing-library/react'
-import { describe, expect, it, vi } from 'vitest'
+import { render } from 'vitest-browser-react'
import {
DropdownMenu,
DropdownMenuContent,
@@ -12,10 +11,16 @@ import {
DropdownMenuTrigger,
} from '../index'
+const renderWithSafeViewport = (ui: import('react').ReactNode) => render(
+ <div style={{ minHeight: '100vh', minWidth: '100vw', padding: '240px' }}>
+ {ui}
+ </div>,
+)
+
describe('dropdown-menu wrapper', () => {
describe('DropdownMenuContent', () => {
- it('should position content at bottom-end with default placement when props are omitted', () => {
- render(
+ it('should position content at bottom-end with default placement when props are omitted', async () => {
+ const screen = await renderWithSafeViewport(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent positionerProps={{ 'role': 'group', 'aria-label': 'content positioner' }}>
@@ -24,16 +29,13 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const positioner = screen.getByRole('group', { name: 'content positioner' })
- const popup = screen.getByRole('menu')
-
- expect(positioner).toHaveAttribute('data-side', 'bottom')
- expect(positioner).toHaveAttribute('data-align', 'end')
- expect(within(popup).getByRole('menuitem', { name: 'Content action' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('group', { name: 'content positioner' })).toHaveAttribute('data-side', 'bottom')
+ await expect.element(screen.getByRole('group', { name: 'content positioner' })).toHaveAttribute('data-align', 'end')
+ await expect.element(screen.getByRole('menuitem', { name: 'Content action' })).toBeInTheDocument()
})
- it('should apply custom placement when custom positioning props are provided', () => {
- render(
+ it('should apply custom placement when custom positioning props are provided', async () => {
+ const screen = await renderWithSafeViewport(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent
@@ -47,19 +49,16 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const positioner = screen.getByRole('group', { name: 'custom content positioner' })
- const popup = screen.getByRole('menu')
-
- expect(positioner).toHaveAttribute('data-side', 'top')
- expect(positioner).toHaveAttribute('data-align', 'start')
- expect(within(popup).getByRole('menuitem', { name: 'Custom content' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('group', { name: 'custom content positioner' })).toHaveAttribute('data-side', 'top')
+ await expect.element(screen.getByRole('group', { name: 'custom content positioner' })).toHaveAttribute('data-align', 'start')
+ await expect.element(screen.getByRole('menuitem', { name: 'Custom content' })).toBeInTheDocument()
})
- it('should forward passthrough attributes and handlers when positionerProps and popupProps are provided', () => {
+ it('should forward passthrough attributes and handlers when positionerProps and popupProps are provided', async () => {
const handlePositionerMouseEnter = vi.fn()
const handlePopupClick = vi.fn()
- render(
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent
@@ -80,21 +79,19 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const positioner = screen.getByRole('group', { name: 'dropdown content positioner' })
- const popup = screen.getByRole('menu')
- fireEvent.mouseEnter(positioner)
- fireEvent.click(popup)
+ await screen.getByRole('group', { name: 'dropdown content positioner' }).hover()
+ await screen.getByRole('menu').click()
- expect(positioner).toHaveAttribute('id', 'dropdown-content-positioner')
- expect(popup).toHaveAttribute('id', 'dropdown-content-popup')
+ await expect.element(screen.getByRole('group', { name: 'dropdown content positioner' })).toHaveAttribute('id', 'dropdown-content-positioner')
+ await expect.element(screen.getByRole('menu')).toHaveAttribute('id', 'dropdown-content-popup')
expect(handlePositionerMouseEnter).toHaveBeenCalledTimes(1)
expect(handlePopupClick).toHaveBeenCalledTimes(1)
})
})
describe('DropdownMenuSubContent', () => {
- it('should position sub-content at left-start with default placement when props are omitted', () => {
- render(
+ it('should position sub-content at left-start with default placement when props are omitted', async () => {
+ const screen = await renderWithSafeViewport(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -108,17 +105,16 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const positioner = screen.getByRole('group', { name: 'sub positioner' })
- expect(positioner).toHaveAttribute('data-side', 'left')
- expect(positioner).toHaveAttribute('data-align', 'start')
- expect(screen.getByRole('menuitem', { name: 'Sub action' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('group', { name: 'sub positioner' })).toHaveAttribute('data-side', 'left')
+ await expect.element(screen.getByRole('group', { name: 'sub positioner' })).toHaveAttribute('data-align', 'start')
+ await expect.element(screen.getByRole('menuitem', { name: 'Sub action' })).toBeInTheDocument()
})
- it('should apply custom placement and forward passthrough props for sub-content when custom props are provided', () => {
+ it('should apply custom placement and forward passthrough props for sub-content when custom props are provided', async () => {
const handlePositionerFocus = vi.fn()
const handlePopupClick = vi.fn()
- render(
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -147,23 +143,23 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const positioner = screen.getByRole('group', { name: 'dropdown sub positioner' })
- const popup = screen.getByRole('menu', { name: 'More actions' })
- fireEvent.focus(positioner)
- fireEvent.click(popup)
+ screen.getByRole('group', { name: 'dropdown sub positioner' }).element().dispatchEvent(new FocusEvent('focus', {
+ bubbles: true,
+ }))
+ await screen.getByRole('menu', { name: 'More actions' }).click()
- expect(positioner).toHaveAttribute('data-side', 'right')
- expect(positioner).toHaveAttribute('data-align', 'end')
- expect(positioner).toHaveAttribute('id', 'dropdown-sub-positioner')
- expect(popup).toHaveAttribute('id', 'dropdown-sub-popup')
+ await expect.element(screen.getByRole('group', { name: 'dropdown sub positioner' })).toHaveAttribute('data-side', 'right')
+ await expect.element(screen.getByRole('group', { name: 'dropdown sub positioner' })).toHaveAttribute('data-align', 'end')
+ await expect.element(screen.getByRole('group', { name: 'dropdown sub positioner' })).toHaveAttribute('id', 'dropdown-sub-positioner')
+ await expect.element(screen.getByRole('menu', { name: 'More actions' })).toHaveAttribute('id', 'dropdown-sub-popup')
expect(handlePositionerFocus).toHaveBeenCalledTimes(1)
expect(handlePopupClick).toHaveBeenCalledTimes(1)
})
})
describe('DropdownMenuSubTrigger', () => {
- it('should render submenu trigger content when trigger children are provided', () => {
- render(
+ it('should render submenu trigger content when trigger children are provided', async () => {
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -174,13 +170,13 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- expect(screen.getByRole('menuitem', { name: 'Trigger item' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('menuitem', { name: 'Trigger item' })).toBeInTheDocument()
})
- it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant on submenu trigger when variant is %s', (variant) => {
+ it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant on submenu trigger when variant is %s', async (variant) => {
const handleClick = vi.fn()
- render(
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -198,20 +194,18 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const subTrigger = screen.getByRole('menuitem', { name: 'submenu action' })
- fireEvent.click(subTrigger)
-
- expect(subTrigger).toHaveAttribute('id', `submenu-trigger-${variant}`)
- expect(subTrigger).toHaveAttribute('data-variant', variant)
+ await screen.getByRole('menuitem', { name: 'submenu action' }).click()
+ await expect.element(screen.getByRole('menuitem', { name: 'submenu action' })).toHaveAttribute('id', `submenu-trigger-${variant}`)
+ await expect.element(screen.getByRole('menuitem', { name: 'submenu action' })).toHaveAttribute('data-variant', variant)
expect(handleClick).toHaveBeenCalledTimes(1)
})
})
describe('DropdownMenuItem', () => {
- it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant when variant is %s', (variant) => {
+ it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant when variant is %s', async (variant) => {
const handleClick = vi.fn()
- render(
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -227,18 +221,16 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const item = screen.getByRole('menuitem', { name: 'menu action' })
- fireEvent.click(item)
-
- expect(item).toHaveAttribute('id', `menu-item-${variant}`)
- expect(item).toHaveAttribute('data-variant', variant)
+ await screen.getByRole('menuitem', { name: 'menu action' }).click()
+ await expect.element(screen.getByRole('menuitem', { name: 'menu action' })).toHaveAttribute('id', `menu-item-${variant}`)
+ await expect.element(screen.getByRole('menuitem', { name: 'menu action' })).toHaveAttribute('data-variant', variant)
expect(handleClick).toHaveBeenCalledTimes(1)
})
})
describe('DropdownMenuLinkItem', () => {
- it('should render as anchor and keep href/target attributes when link props are provided', () => {
- render(
+ it('should render as anchor and keep href/target attributes when link props are provided', async () => {
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -249,15 +241,15 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const link = screen.getByRole('menuitem', { name: 'Docs' })
+ const link = screen.getByRole('menuitem', { name: 'Docs' }).element()
expect(link.tagName.toLowerCase()).toBe('a')
expect(link).toHaveAttribute('href', 'https://example.com/docs')
expect(link).toHaveAttribute('target', '_blank')
expect(link).toHaveAttribute('rel', 'noopener noreferrer')
})
- it('should keep link semantics and not leak closeOnClick prop when closeOnClick is false', () => {
- render(
+ it('should keep link semantics and not leak closeOnClick prop when closeOnClick is false', async () => {
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -272,14 +264,14 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const link = screen.getByRole('menuitem', { name: 'docs link' })
+ const link = screen.getByRole('menuitem', { name: 'docs link' }).element()
expect(link.tagName.toLowerCase()).toBe('a')
expect(link).toHaveAttribute('href', 'https://example.com/docs')
expect(link).not.toHaveAttribute('closeOnClick')
})
- it('should preserve link semantics when render prop uses a custom anchor element', () => {
- render(
+ it('should preserve link semantics when render prop uses a custom anchor element', async () => {
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -293,16 +285,16 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const link = screen.getByRole('menuitem', { name: 'account link' })
+ const link = screen.getByRole('menuitem', { name: 'account link' }).element()
expect(link.tagName.toLowerCase()).toBe('a')
expect(link).toHaveAttribute('href', '/account')
expect(link).toHaveTextContent('Account settings')
})
- it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant when variant is %s', (variant) => {
+ it.each(['default', 'destructive'] as const)('should remain interactive and set data-variant when variant is %s', async (variant) => {
const handleClick = vi.fn()
- render(
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -311,7 +303,10 @@ describe('dropdown-menu wrapper', () => {
href="https://example.com/docs"
aria-label="docs link"
id={`menu-link-${variant}`}
- onClick={handleClick}
+ onClick={(event) => {
+ event.preventDefault()
+ handleClick(event)
+ }}
>
Docs
</DropdownMenuLinkItem>
@@ -319,9 +314,9 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const link = screen.getByRole('menuitem', { name: 'docs link' })
- fireEvent.click(link)
+ await screen.getByRole('menuitem', { name: 'docs link' }).click()
+ const link = screen.getByRole('menuitem', { name: 'docs link' }).element()
expect(link.tagName.toLowerCase()).toBe('a')
expect(link).toHaveAttribute('id', `menu-link-${variant}`)
expect(link).toHaveAttribute('data-variant', variant)
@@ -330,10 +325,10 @@ describe('dropdown-menu wrapper', () => {
})
describe('DropdownMenuSeparator', () => {
- it('should forward passthrough props and handlers when separator props are provided', () => {
+ it('should forward passthrough props and handlers when separator props are provided', async () => {
const handleMouseEnter = vi.fn()
- render(
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -346,15 +341,15 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- const separator = screen.getByRole('separator', { name: 'actions divider' })
- fireEvent.mouseEnter(separator)
-
- expect(separator).toHaveAttribute('id', 'menu-separator')
+ screen.getByRole('separator', { name: 'actions divider' }).element().dispatchEvent(new MouseEvent('mouseover', {
+ bubbles: true,
+ }))
+ await expect.element(screen.getByRole('separator', { name: 'actions divider' })).toHaveAttribute('id', 'menu-separator')
expect(handleMouseEnter).toHaveBeenCalledTimes(1)
})
- it('should keep surrounding menu rows rendered when separator is placed between items', () => {
- render(
+ it('should keep surrounding menu rows rendered when separator is placed between items', async () => {
+ const screen = await render(
<DropdownMenu open>
<DropdownMenuTrigger aria-label="menu trigger">Open</DropdownMenuTrigger>
<DropdownMenuContent>
@@ -365,9 +360,9 @@ describe('dropdown-menu wrapper', () => {
</DropdownMenu>,
)
- expect(screen.getByRole('menuitem', { name: 'First action' })).toBeInTheDocument()
- expect(screen.getByRole('menuitem', { name: 'Second action' })).toBeInTheDocument()
- expect(screen.getAllByRole('separator')).toHaveLength(1)
+ await expect.element(screen.getByRole('menuitem', { name: 'First action' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('menuitem', { name: 'Second action' })).toBeInTheDocument()
+ expect(screen.getByRole('separator').elements()).toHaveLength(1)
})
})
})
diff --git a/packages/dify-ui/src/number-field/__tests__/index.spec.tsx b/packages/dify-ui/src/number-field/__tests__/index.spec.tsx
index 4d83075f19e..0461e5f40ec 100644
--- a/packages/dify-ui/src/number-field/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/number-field/__tests__/index.spec.tsx
@@ -6,7 +6,7 @@ import type {
NumberFieldInputProps,
NumberFieldUnitProps,
} from '../index'
-import { render, screen } from '@testing-library/react'
+import { render } from 'vitest-browser-react'
import {
NumberField,
NumberFieldControls,
@@ -66,23 +66,20 @@ const renderNumberField = ({
}
describe('NumberField wrapper', () => {
- // Group and input wrappers should preserve the design-system variants and DOM defaults.
describe('Group and input', () => {
- it('should apply medium group classes by default and merge custom className', () => {
- renderNumberField({
+ it('should apply medium group classes by default and merge custom className', async () => {
+ const screen = await renderNumberField({
groupProps: {
className: 'custom-group',
},
})
- const group = screen.getByTestId('group')
-
- expect(group).toHaveClass('rounded-lg')
- expect(group).toHaveClass('custom-group')
+ await expect.element(screen.getByTestId('group')).toHaveClass('rounded-lg')
+ await expect.element(screen.getByTestId('group')).toHaveClass('custom-group')
})
- it('should apply large group and input classes when large size is provided', () => {
- renderNumberField({
+ it('should apply large group and input classes when large size is provided', async () => {
+ const screen = await renderNumberField({
groupProps: {
size: 'large',
},
@@ -91,16 +88,13 @@ describe('NumberField wrapper', () => {
},
})
- const group = screen.getByTestId('group')
- const input = screen.getByTestId('input')
-
- expect(group).toHaveClass('rounded-[10px]')
- expect(input).toHaveClass('px-4')
- expect(input).toHaveClass('py-2')
+ await expect.element(screen.getByTestId('group')).toHaveClass('rounded-[10px]')
+ await expect.element(screen.getByTestId('input')).toHaveClass('px-4')
+ await expect.element(screen.getByTestId('input')).toHaveClass('py-2')
})
- it('should set input defaults and forward passthrough props', () => {
- renderNumberField({
+ it('should set input defaults and forward passthrough props', async () => {
+ const screen = await renderNumberField({
inputProps: {
className: 'custom-input',
placeholder: 'Regular placeholder',
@@ -108,26 +102,23 @@ describe('NumberField wrapper', () => {
},
})
- const input = screen.getByRole('textbox', { name: 'Amount' })
-
- expect(input).toHaveAttribute('autoComplete', 'off')
- expect(input).toHaveAttribute('autoCorrect', 'off')
- expect(input).toHaveAttribute('placeholder', 'Regular placeholder')
- expect(input).toBeRequired()
- expect(input).toHaveClass('px-3')
- expect(input).toHaveClass('py-[7px]')
- expect(input).toHaveClass('system-sm-regular')
- expect(input).toHaveClass('custom-input')
+ await expect.element(screen.getByRole('textbox', { name: 'Amount' })).toHaveAttribute('autocomplete', 'off')
+ await expect.element(screen.getByRole('textbox', { name: 'Amount' })).toHaveAttribute('autocorrect', 'off')
+ await expect.element(screen.getByRole('textbox', { name: 'Amount' })).toHaveAttribute('placeholder', 'Regular placeholder')
+ await expect.element(screen.getByRole('textbox', { name: 'Amount' })).toBeRequired()
+ await expect.element(screen.getByRole('textbox', { name: 'Amount' })).toHaveClass('px-3')
+ await expect.element(screen.getByRole('textbox', { name: 'Amount' })).toHaveClass('py-[7px]')
+ await expect.element(screen.getByRole('textbox', { name: 'Amount' })).toHaveClass('system-sm-regular')
+ await expect.element(screen.getByRole('textbox', { name: 'Amount' })).toHaveClass('custom-input')
})
})
- // Unit and controls wrappers should preserve layout tokens and HTML passthrough props.
describe('Unit and controls', () => {
it.each([
['medium', 'pr-2'],
['large', 'pr-2.5'],
- ] as const)('should apply the %s unit spacing variant', (size, spacingClass) => {
- renderNumberField({
+ ] as const)('should apply the %s unit spacing variant', async (size, spacingClass) => {
+ const screen = await renderNumberField({
unitProps: {
size,
className: 'custom-unit',
@@ -135,45 +126,37 @@ describe('NumberField wrapper', () => {
},
})
- const unit = screen.getByTestId('unit')
-
- expect(unit).toHaveTextContent('ms')
- expect(unit).toHaveAttribute('title', `unit-${size}`)
- expect(unit).toHaveClass('custom-unit')
- expect(unit).toHaveClass(spacingClass)
+ await expect.element(screen.getByTestId('unit')).toHaveTextContent('ms')
+ await expect.element(screen.getByTestId('unit')).toHaveAttribute('title', `unit-${size}`)
+ await expect.element(screen.getByTestId('unit')).toHaveClass('custom-unit')
+ await expect.element(screen.getByTestId('unit')).toHaveClass(spacingClass)
})
- it('should forward passthrough props to controls', () => {
- renderNumberField({
+ it('should forward passthrough props to controls', async () => {
+ const screen = await renderNumberField({
controlsProps: {
className: 'custom-controls',
title: 'controls-title',
},
})
- const controls = screen.getByTestId('controls')
-
- expect(controls).toHaveAttribute('title', 'controls-title')
- expect(controls).toHaveClass('custom-controls')
+ await expect.element(screen.getByTestId('controls')).toHaveAttribute('title', 'controls-title')
+ await expect.element(screen.getByTestId('controls')).toHaveClass('custom-controls')
})
})
- // Increment and decrement buttons should preserve accessible naming, icon fallbacks, and spacing variants.
describe('Control buttons', () => {
- it('should provide english fallback aria labels and default icons when labels are not provided', () => {
- renderNumberField({
+ it('should provide english fallback aria labels and default icons when labels are not provided', async () => {
+ const screen = await renderNumberField({
controlsProps: {},
})
- const increment = screen.getByRole('button', { name: 'Increment value' })
- const decrement = screen.getByRole('button', { name: 'Decrement value' })
-
- expect(increment.querySelector('.i-ri-arrow-up-s-line')).toBeInTheDocument()
- expect(decrement.querySelector('.i-ri-arrow-down-s-line')).toBeInTheDocument()
+ expect(screen.getByRole('button', { name: 'Increment value' }).element().querySelector('.i-ri-arrow-up-s-line')).toBeInTheDocument()
+ expect(screen.getByRole('button', { name: 'Decrement value' }).element().querySelector('.i-ri-arrow-down-s-line')).toBeInTheDocument()
})
- it('should preserve explicit aria labels and custom children', () => {
- renderNumberField({
+ it('should preserve explicit aria labels and custom children', async () => {
+ const screen = await renderNumberField({
controlsProps: {},
incrementProps: {
'aria-label': 'Increase amount',
@@ -185,17 +168,14 @@ describe('NumberField wrapper', () => {
},
})
- const increment = screen.getByRole('button', { name: 'Increase amount' })
- const decrement = screen.getByRole('button', { name: 'Decrease amount' })
-
- expect(increment).toContainElement(screen.getByTestId('custom-increment-icon'))
- expect(decrement).toContainElement(screen.getByTestId('custom-decrement-icon'))
- expect(increment.querySelector('.i-ri-arrow-up-s-line')).not.toBeInTheDocument()
- expect(decrement.querySelector('.i-ri-arrow-down-s-line')).not.toBeInTheDocument()
+ expect(screen.getByRole('button', { name: 'Increase amount' }).element()).toContainElement(screen.getByTestId('custom-increment-icon').element())
+ expect(screen.getByRole('button', { name: 'Decrease amount' }).element()).toContainElement(screen.getByTestId('custom-decrement-icon').element())
+ expect(screen.getByRole('button', { name: 'Increase amount' }).element().querySelector('.i-ri-arrow-up-s-line')).not.toBeInTheDocument()
+ expect(screen.getByRole('button', { name: 'Decrease amount' }).element().querySelector('.i-ri-arrow-down-s-line')).not.toBeInTheDocument()
})
- it('should keep the fallback aria labels when aria-label is omitted in props', () => {
- renderNumberField({
+ it('should keep the fallback aria labels when aria-label is omitted in props', async () => {
+ const screen = await renderNumberField({
controlsProps: {},
incrementProps: {
'aria-label': undefined,
@@ -205,12 +185,12 @@ describe('NumberField wrapper', () => {
},
})
- expect(screen.getByRole('button', { name: 'Increment value' })).toBeInTheDocument()
- expect(screen.getByRole('button', { name: 'Decrement value' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('button', { name: 'Increment value' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('button', { name: 'Decrement value' })).toBeInTheDocument()
})
- it('should rely on aria-labelledby when provided instead of injecting a fallback aria-label', () => {
- render(
+ it('should rely on aria-labelledby when provided instead of injecting a fallback aria-label', async () => {
+ const screen = await render(
<>
<span id="increment-label">Increment from label</span>
<span id="decrement-label">Decrement from label</span>
@@ -226,18 +206,15 @@ describe('NumberField wrapper', () => {
</>,
)
- const increment = screen.getByRole('button', { name: 'Increment from label' })
- const decrement = screen.getByRole('button', { name: 'Decrement from label' })
-
- expect(increment).not.toHaveAttribute('aria-label')
- expect(decrement).not.toHaveAttribute('aria-label')
+ await expect.element(screen.getByRole('button', { name: 'Increment from label' })).not.toHaveAttribute('aria-label')
+ await expect.element(screen.getByRole('button', { name: 'Decrement from label' })).not.toHaveAttribute('aria-label')
})
it.each([
['medium', 'pt-1', 'pb-1'],
['large', 'pt-1.5', 'pb-1.5'],
- ] as const)('should apply the %s control button compound spacing classes', (size, incrementClass, decrementClass) => {
- renderNumberField({
+ ] as const)('should apply the %s control button compound spacing classes', async (size, incrementClass, decrementClass) => {
+ const screen = await renderNumberField({
controlsProps: {},
incrementProps: {
size,
@@ -250,14 +227,11 @@ describe('NumberField wrapper', () => {
},
})
- const increment = screen.getByTestId('increment')
- const decrement = screen.getByTestId('decrement')
-
- expect(increment).toHaveClass(incrementClass)
- expect(increment).toHaveClass('custom-increment')
- expect(decrement).toHaveClass(decrementClass)
- expect(decrement).toHaveClass('custom-decrement')
- expect(decrement).toHaveAttribute('title', `decrement-${size}`)
+ await expect.element(screen.getByTestId('increment')).toHaveClass(incrementClass)
+ await expect.element(screen.getByTestId('increment')).toHaveClass('custom-increment')
+ await expect.element(screen.getByTestId('decrement')).toHaveClass(decrementClass)
+ await expect.element(screen.getByTestId('decrement')).toHaveClass('custom-decrement')
+ await expect.element(screen.getByTestId('decrement')).toHaveAttribute('title', `decrement-${size}`)
})
})
})
diff --git a/packages/dify-ui/src/popover/__tests__/index.spec.tsx b/packages/dify-ui/src/popover/__tests__/index.spec.tsx
index 39fb3f3fac8..ba368c9ad37 100644
--- a/packages/dify-ui/src/popover/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/popover/__tests__/index.spec.tsx
@@ -1,15 +1,20 @@
-import { fireEvent, render, screen } from '@testing-library/react'
-import { describe, expect, it, vi } from 'vitest'
+import { render } from 'vitest-browser-react'
import {
Popover,
PopoverContent,
PopoverTrigger,
} from '..'
+const renderWithSafeViewport = (ui: import('react').ReactNode) => render(
+ <div style={{ minHeight: '100vh', minWidth: '100vw', padding: '240px' }}>
+ {ui}
+ </div>,
+)
+
describe('PopoverContent', () => {
describe('Placement', () => {
- it('should use bottom placement and default offsets when placement props are not provided', () => {
- render(
+ it('should use bottom placement and default offsets when placement props are not provided', async () => {
+ const screen = await renderWithSafeViewport(
<Popover open>
<PopoverTrigger aria-label="popover trigger">Open</PopoverTrigger>
<PopoverContent
@@ -21,16 +26,13 @@ describe('PopoverContent', () => {
</Popover>,
)
- const positioner = screen.getByRole('group', { name: 'default positioner' })
- const popup = screen.getByRole('dialog', { name: 'default popover' })
-
- expect(positioner).toHaveAttribute('data-side', 'bottom')
- expect(positioner).toHaveAttribute('data-align', 'center')
- expect(popup).toHaveTextContent('Default content')
+ await expect.element(screen.getByRole('group', { name: 'default positioner' })).toHaveAttribute('data-side', 'bottom')
+ await expect.element(screen.getByRole('group', { name: 'default positioner' })).toHaveAttribute('data-align', 'center')
+ await expect.element(screen.getByRole('dialog', { name: 'default popover' })).toHaveTextContent('Default content')
})
- it('should apply parsed custom placement and custom offsets when placement props are provided', () => {
- render(
+ it('should apply parsed custom placement and custom offsets when placement props are provided', async () => {
+ const screen = await renderWithSafeViewport(
<Popover open>
<PopoverTrigger aria-label="popover trigger">Open</PopoverTrigger>
<PopoverContent
@@ -45,20 +47,17 @@ describe('PopoverContent', () => {
</Popover>,
)
- const positioner = screen.getByRole('group', { name: 'custom positioner' })
- const popup = screen.getByRole('dialog', { name: 'custom popover' })
-
- expect(positioner).toHaveAttribute('data-side', 'top')
- expect(positioner).toHaveAttribute('data-align', 'end')
- expect(popup).toHaveTextContent('Custom placement content')
+ await expect.element(screen.getByRole('group', { name: 'custom positioner' })).toHaveAttribute('data-side', 'top')
+ await expect.element(screen.getByRole('group', { name: 'custom positioner' })).toHaveAttribute('data-align', 'end')
+ await expect.element(screen.getByRole('dialog', { name: 'custom popover' })).toHaveTextContent('Custom placement content')
})
})
describe('Passthrough props', () => {
- it('should forward positionerProps and popupProps when passthrough props are provided', () => {
+ it('should forward positionerProps and popupProps when passthrough props are provided', async () => {
const onPopupClick = vi.fn()
- render(
+ const screen = await render(
<Popover open>
<PopoverTrigger aria-label="popover trigger">Open</PopoverTrigger>
<PopoverContent
@@ -79,12 +78,11 @@ describe('PopoverContent', () => {
</Popover>,
)
- const positioner = screen.getByRole('group', { name: 'popover positioner' })
const popup = screen.getByRole('dialog', { name: 'popover content' })
- fireEvent.click(popup)
+ await popup.click()
- expect(positioner).toHaveAttribute('id', 'popover-positioner-id')
- expect(popup).toHaveAttribute('id', 'popover-popup-id')
+ await expect.element(screen.getByRole('group', { name: 'popover positioner' })).toHaveAttribute('id', 'popover-positioner-id')
+ await expect.element(popup).toHaveAttribute('id', 'popover-popup-id')
expect(onPopupClick).toHaveBeenCalledTimes(1)
})
})
diff --git a/packages/dify-ui/src/scroll-area/__tests__/index.spec.tsx b/packages/dify-ui/src/scroll-area/__tests__/index.spec.tsx
index 7696a9be29f..1c1a6e9d717 100644
--- a/packages/dify-ui/src/scroll-area/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/scroll-area/__tests__/index.spec.tsx
@@ -1,5 +1,4 @@
-import { render, screen, waitFor } from '@testing-library/react'
-import { describe, expect, it } from 'vitest'
+import { render } from 'vitest-browser-react'
import {
ScrollArea,
ScrollAreaContent,
@@ -10,6 +9,28 @@ import {
ScrollAreaViewport,
} from '../index'
+const stubElementMetric = (
+ element: HTMLElement,
+ property: 'clientHeight' | 'clientWidth' | 'scrollHeight' | 'scrollWidth',
+ value: number,
+) => {
+ const originalDescriptor = Object.getOwnPropertyDescriptor(element, property)
+
+ Object.defineProperty(element, property, {
+ configurable: true,
+ get: () => value,
+ })
+
+ return () => {
+ if (originalDescriptor) {
+ Object.defineProperty(element, property, originalDescriptor)
+ return
+ }
+
+ delete (element as Partial<Record<typeof property, number>>)[property]
+ }
+}
+
const renderScrollArea = (options: {
rootClassName?: string
viewportClassName?: string
@@ -50,21 +71,19 @@ const renderScrollArea = (options: {
describe('scroll-area wrapper', () => {
describe('Rendering', () => {
it('should render the compound exports together', async () => {
- renderScrollArea()
+ const screen = await renderScrollArea()
- await waitFor(() => {
- expect(screen.getByTestId('scroll-area-root')).toBeInTheDocument()
- expect(screen.getByTestId('scroll-area-viewport')).toBeInTheDocument()
- expect(screen.getByTestId('scroll-area-content')).toHaveTextContent('Scrollable content')
- expect(screen.getByTestId('scroll-area-vertical-scrollbar')).toBeInTheDocument()
- expect(screen.getByTestId('scroll-area-vertical-thumb')).toBeInTheDocument()
- expect(screen.getByTestId('scroll-area-horizontal-scrollbar')).toBeInTheDocument()
- expect(screen.getByTestId('scroll-area-horizontal-thumb')).toBeInTheDocument()
- })
+ await expect.element(screen.getByTestId('scroll-area-root')).toBeInTheDocument()
+ await expect.element(screen.getByTestId('scroll-area-viewport')).toBeInTheDocument()
+ await expect.element(screen.getByTestId('scroll-area-content')).toHaveTextContent('Scrollable content')
+ await expect.element(screen.getByTestId('scroll-area-vertical-scrollbar')).toBeInTheDocument()
+ await expect.element(screen.getByTestId('scroll-area-vertical-thumb')).toBeInTheDocument()
+ await expect.element(screen.getByTestId('scroll-area-horizontal-scrollbar')).toBeInTheDocument()
+ await expect.element(screen.getByTestId('scroll-area-horizontal-thumb')).toBeInTheDocument()
})
it('should render the convenience wrapper and apply slot props', async () => {
- render(
+ const screen = await render(
<>
<p id="installed-apps-label">Installed apps</p>
<ScrollArea
@@ -82,177 +101,141 @@ describe('scroll-area wrapper', () => {
</>,
)
- await waitFor(() => {
- const root = screen.getByTestId('scroll-area-wrapper-root')
- const viewport = screen.getByRole('region', { name: 'Installed apps' })
- const content = screen.getByText('Scrollable content').parentElement
+ const viewport = screen.getByRole('region', { name: 'Installed apps' })
+ const content = screen.getByText('Scrollable content').element().parentElement
- expect(root).toBeInTheDocument()
- expect(viewport).toHaveClass('custom-viewport-class')
- expect(viewport).toHaveAccessibleName('Installed apps')
- expect(content).toHaveClass('custom-content-class')
- expect(screen.getByText('Scrollable content')).toBeInTheDocument()
- })
+ await expect.element(screen.getByTestId('scroll-area-wrapper-root')).toBeInTheDocument()
+ await expect.element(viewport).toHaveClass('custom-viewport-class')
+ await expect.element(viewport).toHaveAccessibleName('Installed apps')
+ expect(content).toHaveClass('custom-content-class')
+ await expect.element(screen.getByText('Scrollable content')).toBeInTheDocument()
})
})
describe('Scrollbar', () => {
it('should apply the default vertical scrollbar classes and orientation data attribute', async () => {
- renderScrollArea()
-
- await waitFor(() => {
- const scrollbar = screen.getByTestId('scroll-area-vertical-scrollbar')
- const thumb = screen.getByTestId('scroll-area-vertical-thumb')
+ const screen = await renderScrollArea()
- expect(scrollbar).toHaveAttribute('data-orientation', 'vertical')
- expect(scrollbar).toHaveAttribute('data-dify-scrollbar')
- expect(scrollbar).toHaveClass(
- 'flex',
- 'overflow-clip',
- 'p-1',
- 'touch-none',
- 'select-none',
- 'opacity-100',
- 'transition-opacity',
- 'motion-reduce:transition-none',
- 'pointer-events-none',
- 'data-hovering:pointer-events-auto',
- 'data-scrolling:pointer-events-auto',
- 'data-[orientation=vertical]:absolute',
- 'data-[orientation=vertical]:inset-y-0',
- 'data-[orientation=vertical]:w-3',
- 'data-[orientation=vertical]:justify-center',
- )
- expect(thumb).toHaveAttribute('data-orientation', 'vertical')
- expect(thumb).toHaveClass(
- 'shrink-0',
- 'rounded-sm',
- 'bg-state-base-handle',
- 'transition-[background-color]',
- 'motion-reduce:transition-none',
- 'data-[orientation=vertical]:w-1',
- )
- })
+ await expect.element(screen.getByTestId('scroll-area-vertical-scrollbar')).toHaveAttribute('data-orientation', 'vertical')
+ await expect.element(screen.getByTestId('scroll-area-vertical-scrollbar')).toHaveAttribute('data-dify-scrollbar')
+ await expect.element(screen.getByTestId('scroll-area-vertical-scrollbar')).toHaveClass(
+ 'flex',
+ 'overflow-clip',
+ 'p-1',
+ 'touch-none',
+ 'select-none',
+ 'opacity-100',
+ 'transition-opacity',
+ 'motion-reduce:transition-none',
+ 'pointer-events-none',
+ 'data-hovering:pointer-events-auto',
+ 'data-scrolling:pointer-events-auto',
+ 'data-[orientation=vertical]:absolute',
+ 'data-[orientation=vertical]:inset-y-0',
+ 'data-[orientation=vertical]:w-3',
+ 'data-[orientation=vertical]:justify-center',
+ )
+ await expect.element(screen.getByTestId('scroll-area-vertical-thumb')).toHaveAttribute('data-orientation', 'vertical')
+ await expect.element(screen.getByTestId('scroll-area-vertical-thumb')).toHaveClass(
+ 'shrink-0',
+ 'rounded-sm',
+ 'bg-state-base-handle',
+ 'transition-[background-color]',
+ 'motion-reduce:transition-none',
+ 'data-[orientation=vertical]:w-1',
+ )
})
it('should apply horizontal scrollbar and thumb classes when orientation is horizontal', async () => {
- renderScrollArea()
-
- await waitFor(() => {
- const scrollbar = screen.getByTestId('scroll-area-horizontal-scrollbar')
- const thumb = screen.getByTestId('scroll-area-horizontal-thumb')
+ const screen = await renderScrollArea()
- expect(scrollbar).toHaveAttribute('data-orientation', 'horizontal')
- expect(scrollbar).toHaveAttribute('data-dify-scrollbar')
- expect(scrollbar).toHaveClass(
- 'flex',
- 'overflow-clip',
- 'p-1',
- 'touch-none',
- 'select-none',
- 'opacity-100',
- 'transition-opacity',
- 'motion-reduce:transition-none',
- 'pointer-events-none',
- 'data-hovering:pointer-events-auto',
- 'data-scrolling:pointer-events-auto',
- 'data-[orientation=horizontal]:absolute',
- 'data-[orientation=horizontal]:inset-x-0',
- 'data-[orientation=horizontal]:h-3',
- 'data-[orientation=horizontal]:items-center',
- )
- expect(thumb).toHaveAttribute('data-orientation', 'horizontal')
- expect(thumb).toHaveClass(
- 'shrink-0',
- 'rounded-sm',
- 'bg-state-base-handle',
- 'transition-[background-color]',
- 'motion-reduce:transition-none',
- 'data-[orientation=horizontal]:h-1',
- )
- })
+ await expect.element(screen.getByTestId('scroll-area-horizontal-scrollbar')).toHaveAttribute('data-orientation', 'horizontal')
+ await expect.element(screen.getByTestId('scroll-area-horizontal-scrollbar')).toHaveAttribute('data-dify-scrollbar')
+ await expect.element(screen.getByTestId('scroll-area-horizontal-scrollbar')).toHaveClass(
+ 'flex',
+ 'overflow-clip',
+ 'p-1',
+ 'touch-none',
+ 'select-none',
+ 'opacity-100',
+ 'transition-opacity',
+ 'motion-reduce:transition-none',
+ 'pointer-events-none',
+ 'data-hovering:pointer-events-auto',
+ 'data-scrolling:pointer-events-auto',
+ 'data-[orientation=horizontal]:absolute',
+ 'data-[orientation=horizontal]:inset-x-0',
+ 'data-[orientation=horizontal]:h-3',
+ 'data-[orientation=horizontal]:items-center',
+ )
+ await expect.element(screen.getByTestId('scroll-area-horizontal-thumb')).toHaveAttribute('data-orientation', 'horizontal')
+ await expect.element(screen.getByTestId('scroll-area-horizontal-thumb')).toHaveClass(
+ 'shrink-0',
+ 'rounded-sm',
+ 'bg-state-base-handle',
+ 'transition-[background-color]',
+ 'motion-reduce:transition-none',
+ 'data-[orientation=horizontal]:h-1',
+ )
})
})
describe('Props', () => {
it('should forward className to the viewport', async () => {
- renderScrollArea({
+ const screen = await renderScrollArea({
viewportClassName: 'custom-viewport-class',
})
- await waitFor(() => {
- expect(screen.getByTestId('scroll-area-viewport')).toHaveClass(
- 'size-full',
- 'min-h-0',
- 'min-w-0',
- 'outline-hidden',
- 'focus-visible:ring-1',
- 'focus-visible:ring-inset',
- 'focus-visible:ring-components-input-border-hover',
- 'custom-viewport-class',
- )
- })
+ await expect.element(screen.getByTestId('scroll-area-viewport')).toHaveClass(
+ 'size-full',
+ 'min-h-0',
+ 'min-w-0',
+ 'outline-hidden',
+ 'focus-visible:ring-1',
+ 'focus-visible:ring-inset',
+ 'focus-visible:ring-components-input-border-hover',
+ 'custom-viewport-class',
+ )
})
it('should let callers control scrollbar inset spacing via margin-based className overrides', async () => {
- renderScrollArea({
+ const screen = await renderScrollArea({
verticalScrollbarClassName: 'data-[orientation=vertical]:my-2 data-[orientation=vertical]:-me-3',
horizontalScrollbarClassName: 'data-[orientation=horizontal]:mx-2 data-[orientation=horizontal]:mb-2',
})
- await waitFor(() => {
- expect(screen.getByTestId('scroll-area-vertical-scrollbar')).toHaveClass(
- 'data-[orientation=vertical]:my-2',
- 'data-[orientation=vertical]:-me-3',
- )
- expect(screen.getByTestId('scroll-area-horizontal-scrollbar')).toHaveClass(
- 'data-[orientation=horizontal]:mx-2',
- 'data-[orientation=horizontal]:mb-2',
- )
- })
+ await expect.element(screen.getByTestId('scroll-area-vertical-scrollbar')).toHaveClass(
+ 'data-[orientation=vertical]:my-2',
+ 'data-[orientation=vertical]:-me-3',
+ )
+ await expect.element(screen.getByTestId('scroll-area-horizontal-scrollbar')).toHaveClass(
+ 'data-[orientation=horizontal]:mx-2',
+ 'data-[orientation=horizontal]:mb-2',
+ )
})
})
describe('Corner', () => {
it('should render the corner export when both axes overflow', async () => {
- const originalDescriptors = {
- clientHeight: Object.getOwnPropertyDescriptor(HTMLDivElement.prototype, 'clientHeight'),
- clientWidth: Object.getOwnPropertyDescriptor(HTMLDivElement.prototype, 'clientWidth'),
- scrollHeight: Object.getOwnPropertyDescriptor(HTMLDivElement.prototype, 'scrollHeight'),
- scrollWidth: Object.getOwnPropertyDescriptor(HTMLDivElement.prototype, 'scrollWidth'),
- }
-
- Object.defineProperties(HTMLDivElement.prototype, {
- clientHeight: {
- configurable: true,
- get() {
- return this.getAttribute('data-testid') === 'scroll-area-viewport' ? 80 : 0
- },
- },
- clientWidth: {
- configurable: true,
- get() {
- return this.getAttribute('data-testid') === 'scroll-area-viewport' ? 80 : 0
- },
- },
- scrollHeight: {
- configurable: true,
- get() {
- return this.getAttribute('data-testid') === 'scroll-area-viewport' ? 160 : 0
- },
- },
- scrollWidth: {
- configurable: true,
- get() {
- return this.getAttribute('data-testid') === 'scroll-area-viewport' ? 160 : 0
- },
- },
- })
+ const restoreViewportMetrics: Array<() => void> = []
try {
- render(
+ const screen = await render(
<ScrollAreaRoot className="h-40 w-40" data-testid="scroll-area-root">
- <ScrollAreaViewport data-testid="scroll-area-viewport">
+ <ScrollAreaViewport
+ data-testid="scroll-area-viewport"
+ ref={(node) => {
+ if (!node || restoreViewportMetrics.length > 0)
+ return
+
+ restoreViewportMetrics.push(
+ stubElementMetric(node, 'clientHeight', 80),
+ stubElementMetric(node, 'clientWidth', 80),
+ stubElementMetric(node, 'scrollHeight', 160),
+ stubElementMetric(node, 'scrollWidth', 160),
+ )
+ }}
+ >
<ScrollAreaContent data-testid="scroll-area-content">
<div className="h-48 w-48">Scrollable content</div>
</ScrollAreaContent>
@@ -271,24 +254,13 @@ describe('scroll-area wrapper', () => {
</ScrollAreaRoot>,
)
- await waitFor(() => {
- expect(screen.getByTestId('scroll-area-corner')).toBeInTheDocument()
- expect(screen.getByTestId('scroll-area-corner')).toHaveClass('bg-transparent')
+ await vi.waitFor(() => {
+ expect(screen.getByTestId('scroll-area-corner').element()).toBeInTheDocument()
+ expect(screen.getByTestId('scroll-area-corner').element()).toHaveClass('bg-transparent')
})
}
finally {
- if (originalDescriptors.clientHeight) {
- Object.defineProperty(HTMLDivElement.prototype, 'clientHeight', originalDescriptors.clientHeight)
- }
- if (originalDescriptors.clientWidth) {
- Object.defineProperty(HTMLDivElement.prototype, 'clientWidth', originalDescriptors.clientWidth)
- }
- if (originalDescriptors.scrollHeight) {
- Object.defineProperty(HTMLDivElement.prototype, 'scrollHeight', originalDescriptors.scrollHeight)
- }
- if (originalDescriptors.scrollWidth) {
- Object.defineProperty(HTMLDivElement.prototype, 'scrollWidth', originalDescriptors.scrollWidth)
- }
+ restoreViewportMetrics.splice(0).forEach(restore => restore())
}
})
})
diff --git a/packages/dify-ui/src/select/__tests__/index.spec.tsx b/packages/dify-ui/src/select/__tests__/index.spec.tsx
index e8083f04b20..eab980a6075 100644
--- a/packages/dify-ui/src/select/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/select/__tests__/index.spec.tsx
@@ -1,7 +1,13 @@
-import { fireEvent, render, screen } from '@testing-library/react'
-import { describe, expect, it, vi } from 'vitest'
+import { render } from 'vitest-browser-react'
import { Select, SelectContent, SelectItem, SelectItemIndicator, SelectItemText, SelectTrigger, SelectValue } from '../index'
+const asHTMLElement = (element: HTMLElement | SVGElement) => element as HTMLElement
+const renderWithSafeViewport = (ui: import('react').ReactNode) => render(
+ <div style={{ minHeight: '100vh', minWidth: '100vw', padding: '240px' }}>
+ {ui}
+ </div>,
+)
+
const renderOpenSelect = ({
rootProps = {},
triggerProps = {},
@@ -13,7 +19,7 @@ const renderOpenSelect = ({
contentProps?: Record<string, unknown>
onValueChange?: (value: string | null) => void
} = {}) => {
- return render(
+ return renderWithSafeViewport(
<Select open defaultValue="seattle" onValueChange={onValueChange} {...rootProps}>
<SelectTrigger aria-label="city select" {...triggerProps}>
<SelectValue />
@@ -48,8 +54,8 @@ const renderOpenSelect = ({
describe('Select wrappers', () => {
describe('Select root integration', () => {
- it('should submit the hidden input value and preserve autocomplete hints inside a form', () => {
- const { container } = render(
+ it('should submit the hidden input value and preserve autocomplete hints inside a form', async () => {
+ const screen = await render(
<form aria-label="profile form">
<Select defaultValue="seattle" name="city" autoComplete="address-level2">
<SelectTrigger aria-label="city select">
@@ -69,8 +75,8 @@ describe('Select wrappers', () => {
</form>,
)
- const hiddenInput = container.querySelector('input[name="city"]')
- const form = screen.getByRole('form', { name: 'profile form' }) as HTMLFormElement
+ const hiddenInput = screen.container.querySelector('input[name="city"]')
+ const form = screen.getByRole('form', { name: 'profile form' }).element() as HTMLFormElement
expect(hiddenInput).toHaveAttribute('autocomplete', 'address-level2')
expect(new FormData(form).get('city')).toBe('seattle')
@@ -78,119 +84,104 @@ describe('Select wrappers', () => {
})
describe('SelectTrigger', () => {
- it('should forward native trigger props when trigger props are provided', () => {
- renderOpenSelect({
+ it('should forward native trigger props when trigger props are provided', async () => {
+ const screen = await renderOpenSelect({
triggerProps: {
'aria-label': 'Choose option',
'disabled': true,
},
})
- const trigger = screen.getByRole('combobox', { name: 'Choose option' })
- expect(trigger).toBeDisabled()
+ await expect.element(screen.getByRole('combobox', { name: 'Choose option' })).toBeDisabled()
})
- it('should apply regular size variant classes by default', () => {
- renderOpenSelect()
+ it('should apply regular size variant classes by default', async () => {
+ const screen = await renderOpenSelect()
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- expect(trigger.className).toMatch(/system-sm-regular/)
- expect(trigger.className).toMatch(/rounded-lg/)
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().className).toMatch(/system-sm-regular/)
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().className).toMatch(/rounded-lg/)
})
- it('should apply small size variant classes when size is small', () => {
- renderOpenSelect({
+ it('should apply small size variant classes when size is small', async () => {
+ const screen = await renderOpenSelect({
triggerProps: { size: 'small' },
})
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- expect(trigger.className).toMatch(/system-xs-regular/)
- expect(trigger.className).toMatch(/rounded-md/)
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().className).toMatch(/system-xs-regular/)
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().className).toMatch(/rounded-md/)
})
- it('should apply large size variant classes when size is large', () => {
- renderOpenSelect({
+ it('should apply large size variant classes when size is large', async () => {
+ const screen = await renderOpenSelect({
triggerProps: { size: 'large' },
})
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- expect(trigger.className).toMatch(/system-md-regular/)
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().className).toMatch(/system-md-regular/)
})
- it('should apply disabled styling via data attributes when disabled', () => {
- renderOpenSelect({
+ it('should apply disabled styling via data attributes when disabled', async () => {
+ const screen = await renderOpenSelect({
triggerProps: { disabled: true },
})
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- expect(trigger).toHaveAttribute('data-disabled')
- expect(trigger.className).toContain('data-disabled:bg-components-input-bg-disabled')
+ await expect.element(screen.getByRole('combobox', { name: 'city select' })).toHaveAttribute('data-disabled')
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().className).toContain('data-disabled:bg-components-input-bg-disabled')
})
- it('should apply disabled placeholder color class for compound state', () => {
- renderOpenSelect({
+ it('should apply disabled placeholder color class for compound state', async () => {
+ const screen = await renderOpenSelect({
triggerProps: { disabled: true },
})
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- expect(trigger.className).toContain('data-disabled:data-placeholder:text-components-input-text-disabled')
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().className).toContain('data-disabled:data-placeholder:text-components-input-text-disabled')
})
- it('should apply readonly styling via data attributes when Root is readOnly', () => {
- renderOpenSelect({
+ it('should apply readonly styling via data attributes when Root is readOnly', async () => {
+ const screen = await renderOpenSelect({
rootProps: { readOnly: true },
})
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- expect(trigger).toHaveAttribute('data-readonly')
- expect(trigger.className).toContain('data-readonly:bg-transparent')
+ await expect.element(screen.getByRole('combobox', { name: 'city select' })).toHaveAttribute('data-readonly')
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().className).toContain('data-readonly:bg-transparent')
})
- it('should hide arrow icon via CSS when Root is readOnly', () => {
- renderOpenSelect({
+ it('should hide arrow icon via CSS when Root is readOnly', async () => {
+ const screen = await renderOpenSelect({
rootProps: { readOnly: true },
})
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- const iconWrapper = trigger.querySelector('[class*="group-data-readonly:hidden"]')
- expect(iconWrapper).toBeInTheDocument()
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().querySelector('[class*="group-data-readonly:hidden"]')).toBeInTheDocument()
})
- it('should set aria-hidden on decorative icons', () => {
- renderOpenSelect()
+ it('should set aria-hidden on decorative icons', async () => {
+ const screen = await renderOpenSelect()
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- const arrowIcon = trigger.querySelector('.i-ri-arrow-down-s-line')
- expect(arrowIcon).toHaveAttribute('aria-hidden', 'true')
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().querySelector('.i-ri-arrow-down-s-line')).toHaveAttribute('aria-hidden', 'true')
})
- it('should include placeholder color class via data attribute', () => {
- renderOpenSelect()
+ it('should include placeholder color class via data attribute', async () => {
+ const screen = await renderOpenSelect()
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- expect(trigger.className).toContain('data-placeholder:text-components-input-text-placeholder')
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().className).toContain('data-placeholder:text-components-input-text-placeholder')
})
- it('should render built-in chevron icon', () => {
- renderOpenSelect()
+ it('should render built-in chevron icon', async () => {
+ const screen = await renderOpenSelect()
- const trigger = screen.getByRole('combobox', { name: 'city select' })
- const chevron = trigger.querySelector('.i-ri-arrow-down-s-line')
- expect(chevron).toBeInTheDocument()
+ expect(screen.getByRole('combobox', { name: 'city select' }).element().querySelector('.i-ri-arrow-down-s-line')).toBeInTheDocument()
})
})
describe('SelectContent', () => {
- it('should use default placement when placement is not provided', () => {
- renderOpenSelect()
+ it('should use positioning attributes when placement is not provided', async () => {
+ const screen = await renderOpenSelect()
- const positioner = screen.getByRole('group', { name: 'select positioner' })
- expect(positioner).toHaveAttribute('data-side', 'bottom')
- expect(positioner).toHaveAttribute('data-align', 'start')
+ await expect.element(screen.getByRole('group', { name: 'select positioner' })).toHaveAttribute('data-side', 'bottom')
+ await expect.element(screen.getByRole('group', { name: 'select positioner' })).toHaveAttribute('data-align', 'start')
})
- it('should apply custom placement when placement props are provided', () => {
- renderOpenSelect({
+ it('should preserve positioning attributes when placement props are provided', async () => {
+ const screen = await renderOpenSelect({
contentProps: {
placement: 'top-end',
sideOffset: 12,
@@ -198,17 +189,16 @@ describe('Select wrappers', () => {
},
})
- const positioner = screen.getByRole('group', { name: 'select positioner' })
- expect(positioner).toHaveAttribute('data-side', 'top')
- expect(positioner).toHaveAttribute('data-align', 'end')
+ await expect.element(screen.getByRole('group', { name: 'select positioner' })).toHaveAttribute('data-side', 'top')
+ await expect.element(screen.getByRole('group', { name: 'select positioner' })).toHaveAttribute('data-align', 'end')
})
- it('should forward passthrough props to positioner popup and list when passthrough props are provided', () => {
+ it('should forward passthrough props to positioner popup and list when passthrough props are provided', async () => {
const onPositionerMouseEnter = vi.fn()
const onPopupClick = vi.fn()
const onListFocus = vi.fn()
- render(
+ const screen = await render(
<Select open defaultValue="seattle">
<SelectTrigger aria-label="city select">
<SelectValue />
@@ -241,35 +231,35 @@ describe('Select wrappers', () => {
</Select>,
)
- const positioner = screen.getByRole('group', { name: 'select positioner' })
- const popup = screen.getByRole('dialog', { name: 'select popup' })
- const list = screen.getByRole('listbox', { name: 'select list' })
-
- fireEvent.mouseEnter(positioner)
- fireEvent.click(popup)
- fireEvent.focus(list)
-
- expect(positioner).toHaveAttribute('id', 'select-positioner')
- expect(popup).toHaveAttribute('id', 'select-popup')
- expect(list).toHaveAttribute('id', 'select-list')
+ screen.getByRole('group', { name: 'select positioner' }).element().dispatchEvent(new MouseEvent('mouseover', {
+ bubbles: true,
+ }))
+ asHTMLElement(screen.getByRole('dialog', { name: 'select popup' }).element()).click()
+ screen.getByRole('listbox', { name: 'select list' }).element().dispatchEvent(new FocusEvent('focusin', {
+ bubbles: true,
+ }))
+
+ await expect.element(screen.getByRole('group', { name: 'select positioner' })).toHaveAttribute('id', 'select-positioner')
+ await expect.element(screen.getByRole('dialog', { name: 'select popup' })).toHaveAttribute('id', 'select-popup')
+ await expect.element(screen.getByRole('listbox', { name: 'select list' })).toHaveAttribute('id', 'select-list')
expect(onPositionerMouseEnter).toHaveBeenCalledTimes(1)
expect(onPopupClick).toHaveBeenCalledTimes(1)
- expect(onListFocus).toHaveBeenCalledTimes(1)
+ expect(onListFocus).toHaveBeenCalled()
})
})
describe('SelectItem', () => {
- it('should render options when children are provided', () => {
- renderOpenSelect()
+ it('should render options when children are provided', async () => {
+ const screen = await renderOpenSelect()
- expect(screen.getByRole('option', { name: 'Seattle' })).toBeInTheDocument()
- expect(screen.getByRole('option', { name: 'New York' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('option', { name: 'Seattle' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('option', { name: 'New York' })).toBeInTheDocument()
})
- it('should not call onValueChange when disabled item is clicked', () => {
+ it('should not call onValueChange when disabled item is clicked', async () => {
const onValueChange = vi.fn()
- render(
+ const screen = await render(
<Select open defaultValue="seattle" onValueChange={onValueChange}>
<SelectTrigger aria-label="city select">
<SelectValue />
@@ -287,13 +277,13 @@ describe('Select wrappers', () => {
</Select>,
)
- fireEvent.click(screen.getByRole('option', { name: 'Disabled New York' }))
+ asHTMLElement(screen.getByRole('option', { name: 'Disabled New York' }).element()).click()
expect(onValueChange).not.toHaveBeenCalled()
})
- it('should support custom composition with SelectItemText without indicator', () => {
- render(
+ it('should support custom composition with SelectItemText without indicator', async () => {
+ const screen = await render(
<Select open defaultValue="a">
<SelectTrigger aria-label="custom select">
<SelectValue />
@@ -306,7 +296,7 @@ describe('Select wrappers', () => {
</Select>,
)
- expect(screen.getByRole('option', { name: 'Custom Item' })).toBeInTheDocument()
+ await expect.element(screen.getByRole('option', { name: 'Custom Item' })).toBeInTheDocument()
})
})
})
diff --git a/packages/dify-ui/src/slider/__tests__/index.spec.tsx b/packages/dify-ui/src/slider/__tests__/index.spec.tsx
index ab58df844f2..6e175d73248 100644
--- a/packages/dify-ui/src/slider/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/slider/__tests__/index.spec.tsx
@@ -1,96 +1,80 @@
-import { act, render, screen } from '@testing-library/react'
-import userEvent from '@testing-library/user-event'
-import { describe, expect, it, vi } from 'vitest'
+import { render } from 'vitest-browser-react'
import { Slider } from '../index'
-describe('Slider', () => {
- const getSliderInput = () => screen.getByLabelText('Value')
+const asHTMLElement = (element: HTMLElement | SVGElement) => element as HTMLElement
- it('should render with correct default ARIA limits and current value', () => {
- render(<Slider value={50} onValueChange={vi.fn()} aria-label="Value" />)
+describe('Slider', () => {
+ it('should render with correct default ARIA limits and current value', async () => {
+ const screen = await render(<Slider value={50} onValueChange={vi.fn()} aria-label="Value" />)
- const slider = getSliderInput()
- expect(slider).toHaveAttribute('min', '0')
- expect(slider).toHaveAttribute('max', '100')
- expect(slider).toHaveAttribute('aria-valuenow', '50')
+ await expect.element(screen.getByLabelText('Value')).toHaveAttribute('min', '0')
+ await expect.element(screen.getByLabelText('Value')).toHaveAttribute('max', '100')
+ await expect.element(screen.getByLabelText('Value')).toHaveAttribute('aria-valuenow', '50')
})
- it('should apply custom min, max, and step values', () => {
- render(<Slider value={10} min={5} max={20} step={5} onValueChange={vi.fn()} aria-label="Value" />)
+ it('should apply custom min, max, and step values', async () => {
+ const screen = await render(<Slider value={10} min={5} max={20} step={5} onValueChange={vi.fn()} aria-label="Value" />)
- const slider = getSliderInput()
- expect(slider).toHaveAttribute('min', '5')
- expect(slider).toHaveAttribute('max', '20')
- expect(slider).toHaveAttribute('aria-valuenow', '10')
+ await expect.element(screen.getByLabelText('Value')).toHaveAttribute('min', '5')
+ await expect.element(screen.getByLabelText('Value')).toHaveAttribute('max', '20')
+ await expect.element(screen.getByLabelText('Value')).toHaveAttribute('aria-valuenow', '10')
})
- it('should clamp non-finite values to min', () => {
- render(<Slider value={Number.NaN} min={5} onValueChange={vi.fn()} aria-label="Value" />)
+ it('should clamp non-finite values to min', async () => {
+ const screen = await render(<Slider value={Number.NaN} min={5} onValueChange={vi.fn()} aria-label="Value" />)
- expect(getSliderInput()).toHaveAttribute('aria-valuenow', '5')
+ await expect.element(screen.getByLabelText('Value')).toHaveAttribute('aria-valuenow', '5')
})
it('should call onValueChange when arrow keys are pressed', async () => {
- const user = userEvent.setup()
const onValueChange = vi.fn()
+ const screen = await render(<Slider value={20} onValueChange={onValueChange} aria-label="Value" />)
- render(<Slider value={20} onValueChange={onValueChange} aria-label="Value" />)
+ const slider = screen.getByLabelText('Value').element()
+ slider.focus()
+ slider.dispatchEvent(new KeyboardEvent('keydown', { key: 'ArrowRight', bubbles: true }))
- const slider = getSliderInput()
-
- await act(async () => {
- slider.focus()
- await user.keyboard('{ArrowRight}')
+ await vi.waitFor(() => {
+ expect(onValueChange).toHaveBeenCalledTimes(1)
})
-
- expect(onValueChange).toHaveBeenCalledTimes(1)
expect(onValueChange).toHaveBeenLastCalledWith(21, expect.anything())
})
it('should round floating point keyboard updates to the configured step', async () => {
- const user = userEvent.setup()
const onValueChange = vi.fn()
+ const screen = await render(<Slider value={0.2} min={0} max={1} step={0.1} onValueChange={onValueChange} aria-label="Value" />)
- render(<Slider value={0.2} min={0} max={1} step={0.1} onValueChange={onValueChange} aria-label="Value" />)
+ const slider = screen.getByLabelText('Value').element()
+ slider.focus()
+ slider.dispatchEvent(new KeyboardEvent('keydown', { key: 'ArrowRight', bubbles: true }))
- const slider = getSliderInput()
-
- await act(async () => {
- slider.focus()
- await user.keyboard('{ArrowRight}')
+ await vi.waitFor(() => {
+ expect(onValueChange).toHaveBeenCalledTimes(1)
})
-
- expect(onValueChange).toHaveBeenCalledTimes(1)
expect(onValueChange).toHaveBeenLastCalledWith(0.3, expect.anything())
})
it('should not trigger onValueChange when disabled', async () => {
- const user = userEvent.setup()
const onValueChange = vi.fn()
- render(<Slider value={20} onValueChange={onValueChange} disabled aria-label="Value" />)
-
- const slider = getSliderInput()
+ const screen = await render(<Slider value={20} onValueChange={onValueChange} disabled aria-label="Value" />)
+ const slider = screen.getByLabelText('Value').element()
expect(slider).toBeDisabled()
- await act(async () => {
- slider.focus()
- await user.keyboard('{ArrowRight}')
- })
+ asHTMLElement(slider).click()
expect(onValueChange).not.toHaveBeenCalled()
})
- it('should apply custom class names on root', () => {
- const { container } = render(<Slider value={10} onValueChange={vi.fn()} className="outer-test" aria-label="Value" />)
+ it('should apply custom class names on root', async () => {
+ const screen = await render(<Slider value={10} onValueChange={vi.fn()} className="outer-test" aria-label="Value" />)
- const sliderWrapper = container.querySelector('.outer-test')
- expect(sliderWrapper).toBeInTheDocument()
+ expect(screen.container.querySelector('.outer-test')).toBeInTheDocument()
})
- it('should not render prehydration script tags', () => {
- const { container } = render(<Slider value={10} onValueChange={vi.fn()} aria-label="Value" />)
+ it('should not render prehydration script tags', async () => {
+ const screen = await render(<Slider value={10} onValueChange={vi.fn()} aria-label="Value" />)
- expect(container.querySelector('script')).not.toBeInTheDocument()
+ expect(screen.container.querySelector('script')).not.toBeInTheDocument()
})
})
diff --git a/packages/dify-ui/src/switch/__tests__/index.spec.tsx b/packages/dify-ui/src/switch/__tests__/index.spec.tsx
index 055b6e0791b..56fe68d34b0 100644
--- a/packages/dify-ui/src/switch/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/switch/__tests__/index.spec.tsx
@@ -1,198 +1,189 @@
-import { render, screen } from '@testing-library/react'
-import userEvent from '@testing-library/user-event'
-import { describe, expect, it, vi } from 'vitest'
+import { render } from 'vitest-browser-react'
import { Switch, SwitchSkeleton } from '../index'
-const getThumb = (switchElement: HTMLElement) => switchElement.querySelector('span')
+const asHTMLElement = (element: HTMLElement | SVGElement) => element as HTMLElement
+const getThumb = (switchElement: HTMLElement | SVGElement) => switchElement.querySelector('span')
describe('Switch', () => {
- it('should render in unchecked state when checked is false', () => {
- render(<Switch checked={false} />)
+ it('should render in unchecked state when checked is false', async () => {
+ const screen = await render(<Switch checked={false} />)
const switchElement = screen.getByRole('switch')
- expect(switchElement).toBeInTheDocument()
- expect(switchElement).toHaveAttribute('aria-checked', 'false')
- expect(switchElement).not.toHaveAttribute('data-checked')
+
+ await expect.element(switchElement).toBeInTheDocument()
+ await expect.element(switchElement).toHaveAttribute('aria-checked', 'false')
+ await expect.element(switchElement).not.toHaveAttribute('data-checked')
})
- it('should render in checked state when checked is true', () => {
- render(<Switch checked={true} />)
+ it('should render in checked state when checked is true', async () => {
+ const screen = await render(<Switch checked={true} />)
const switchElement = screen.getByRole('switch')
- expect(switchElement).toHaveAttribute('aria-checked', 'true')
- expect(switchElement).toHaveAttribute('data-checked', '')
+
+ await expect.element(switchElement).toHaveAttribute('aria-checked', 'true')
+ await expect.element(switchElement).toHaveAttribute('data-checked', '')
})
it('should call onCheckedChange with next value when clicked', async () => {
const onCheckedChange = vi.fn()
- const user = userEvent.setup()
- render(<Switch checked={false} onCheckedChange={onCheckedChange} />)
+ const screen = await render(<Switch checked={false} onCheckedChange={onCheckedChange} />)
const switchElement = screen.getByRole('switch')
+ asHTMLElement(switchElement.element()).click()
- await user.click(switchElement)
expect(onCheckedChange).toHaveBeenCalledWith(true)
expect(onCheckedChange).toHaveBeenCalledTimes(1)
-
- expect(switchElement).toHaveAttribute('aria-checked', 'false')
+ await expect.element(switchElement).toHaveAttribute('aria-checked', 'false')
})
it('should work in controlled mode with checked prop', async () => {
const onCheckedChange = vi.fn()
- const user = userEvent.setup()
- const { rerender } = render(<Switch checked={false} onCheckedChange={onCheckedChange} />)
+ const screen = await render(<Switch checked={false} onCheckedChange={onCheckedChange} />)
const switchElement = screen.getByRole('switch')
- expect(switchElement).toHaveAttribute('aria-checked', 'false')
+ await expect.element(switchElement).toHaveAttribute('aria-checked', 'false')
- await user.click(switchElement)
+ asHTMLElement(switchElement.element()).click()
expect(onCheckedChange).toHaveBeenCalledWith(true)
- expect(switchElement).toHaveAttribute('aria-checked', 'false')
+ await expect.element(switchElement).toHaveAttribute('aria-checked', 'false')
- rerender(<Switch checked={true} onCheckedChange={onCheckedChange} />)
- expect(switchElement).toHaveAttribute('aria-checked', 'true')
+ await screen.rerender(<Switch checked={true} onCheckedChange={onCheckedChange} />)
+ await expect.element(screen.getByRole('switch')).toHaveAttribute('aria-checked', 'true')
})
it('should not call onCheckedChange when disabled', async () => {
const onCheckedChange = vi.fn()
- const user = userEvent.setup()
- render(<Switch checked={false} disabled onCheckedChange={onCheckedChange} />)
+ const screen = await render(<Switch checked={false} disabled onCheckedChange={onCheckedChange} />)
const switchElement = screen.getByRole('switch')
- expect(switchElement).toHaveClass('data-disabled:cursor-not-allowed')
- expect(switchElement).toHaveAttribute('data-disabled', '')
+ await expect.element(switchElement).toHaveClass('data-disabled:cursor-not-allowed')
+ await expect.element(switchElement).toHaveAttribute('data-disabled', '')
- await user.click(switchElement)
+ asHTMLElement(switchElement.element()).click()
expect(onCheckedChange).not.toHaveBeenCalled()
})
- it('should apply correct size classes', () => {
- const { rerender } = render(<Switch checked={false} size="xs" />)
- const switchElement = screen.getByRole('switch')
- expect(switchElement).toHaveClass('h-2.5', 'w-3.5', 'rounded-xs')
+ it('should apply correct size classes', async () => {
+ const screen = await render(<Switch checked={false} size="xs" />)
+
+ await expect.element(screen.getByRole('switch')).toHaveClass('h-2.5', 'w-3.5', 'rounded-xs')
- rerender(<Switch checked={false} size="sm" />)
- expect(switchElement).toHaveClass('h-3', 'w-5')
+ await screen.rerender(<Switch checked={false} size="sm" />)
+ await expect.element(screen.getByRole('switch')).toHaveClass('h-3', 'w-5')
- rerender(<Switch checked={false} size="md" />)
- expect(switchElement).toHaveClass('h-4', 'w-7')
+ await screen.rerender(<Switch checked={false} size="md" />)
+ await expect.element(screen.getByRole('switch')).toHaveClass('h-4', 'w-7')
- rerender(<Switch checked={false} size="lg" />)
- expect(switchElement).toHaveClass('h-5', 'w-9')
+ await screen.rerender(<Switch checked={false} size="lg" />)
+ await expect.element(screen.getByRole('switch')).toHaveClass('h-5', 'w-9')
})
- it('should apply custom className', () => {
- render(<Switch checked={false} className="custom-test-class" />)
- expect(screen.getByRole('switch')).toHaveClass('custom-test-class')
+ it('should apply custom className', async () => {
+ const screen = await render(<Switch checked={false} className="custom-test-class" />)
+ await expect.element(screen.getByRole('switch')).toHaveClass('custom-test-class')
})
- it('should expose checked state styling hooks on the root and thumb', () => {
- const { rerender } = render(<Switch checked={false} />)
- const switchElement = screen.getByRole('switch')
+ it('should expose checked state styling hooks on the root and thumb', async () => {
+ const screen = await render(<Switch checked={false} />)
+ const switchElement = screen.getByRole('switch').element()
const thumb = getThumb(switchElement)
expect(switchElement).toHaveClass('bg-components-toggle-bg-unchecked', 'data-checked:bg-components-toggle-bg')
expect(thumb).toHaveClass('data-checked:translate-x-[14px]')
expect(thumb).not.toHaveAttribute('data-checked')
- rerender(<Switch checked={true} />)
- expect(switchElement).toHaveAttribute('data-checked', '')
- expect(thumb).toHaveAttribute('data-checked', '')
+ await screen.rerender(<Switch checked={true} />)
+
+ await expect.element(screen.getByRole('switch')).toHaveAttribute('data-checked', '')
+ expect(getThumb(screen.getByRole('switch').element())).toHaveAttribute('data-checked', '')
})
- it('should expose disabled state styling hooks instead of relying on opacity', () => {
- const { rerender } = render(<Switch checked={false} disabled />)
- const switchElement = screen.getByRole('switch')
+ it('should expose disabled state styling hooks instead of relying on opacity', async () => {
+ const screen = await render(<Switch checked={false} disabled />)
- expect(switchElement).toHaveClass(
+ await expect.element(screen.getByRole('switch')).toHaveClass(
'data-disabled:bg-components-toggle-bg-unchecked-disabled',
'data-disabled:data-checked:bg-components-toggle-bg-disabled',
)
- expect(switchElement).toHaveAttribute('data-disabled', '')
+ await expect.element(screen.getByRole('switch')).toHaveAttribute('data-disabled', '')
- rerender(<Switch checked={true} disabled />)
- expect(switchElement).toHaveAttribute('data-disabled', '')
- expect(switchElement).toHaveAttribute('data-checked', '')
+ await screen.rerender(<Switch checked={true} disabled />)
+ await expect.element(screen.getByRole('switch')).toHaveAttribute('data-disabled', '')
+ await expect.element(screen.getByRole('switch')).toHaveAttribute('data-checked', '')
})
- it('should have focus-visible ring-3 styles', () => {
- render(<Switch checked={false} />)
- const switchElement = screen.getByRole('switch')
- expect(switchElement).toHaveClass('focus-visible:ring-2')
+ it('should have focus-visible ring-3 styles', async () => {
+ const screen = await render(<Switch checked={false} />)
+ await expect.element(screen.getByRole('switch')).toHaveClass('focus-visible:ring-2')
})
- it('should respect prefers-reduced-motion', () => {
- render(<Switch checked={false} />)
- const switchElement = screen.getByRole('switch')
- expect(switchElement).toHaveClass('motion-reduce:transition-none')
+ it('should respect prefers-reduced-motion', async () => {
+ const screen = await render(<Switch checked={false} />)
+ await expect.element(screen.getByRole('switch')).toHaveClass('motion-reduce:transition-none')
})
describe('loading state', () => {
it('should render as disabled when loading', async () => {
const onCheckedChange = vi.fn()
- const user = userEvent.setup()
- render(<Switch checked={false} loading onCheckedChange={onCheckedChange} />)
+ const screen = await render(<Switch checked={false} loading onCheckedChange={onCheckedChange} />)
const switchElement = screen.getByRole('switch')
- expect(switchElement).toHaveClass('data-disabled:cursor-not-allowed')
- expect(switchElement).toHaveAttribute('aria-busy', 'true')
- expect(switchElement).toHaveAttribute('data-disabled', '')
+ await expect.element(switchElement).toHaveClass('data-disabled:cursor-not-allowed')
+ await expect.element(switchElement).toHaveAttribute('aria-busy', 'true')
+ await expect.element(switchElement).toHaveAttribute('data-disabled', '')
- await user.click(switchElement)
+ asHTMLElement(switchElement.element()).click()
expect(onCheckedChange).not.toHaveBeenCalled()
})
- it('should show spinner icon for md and lg sizes', () => {
- const { rerender, container } = render(<Switch checked={false} loading size="md" />)
- expect(container.querySelector('span[aria-hidden="true"] i')).toBeInTheDocument()
+ it('should show spinner icon for md and lg sizes', async () => {
+ const screen = await render(<Switch checked={false} loading size="md" />)
+ expect(screen.container.querySelector('span[aria-hidden="true"] i')).toBeInTheDocument()
- rerender(<Switch checked={false} loading size="lg" />)
- expect(container.querySelector('span[aria-hidden="true"] i')).toBeInTheDocument()
+ await screen.rerender(<Switch checked={false} loading size="lg" />)
+ expect(screen.container.querySelector('span[aria-hidden="true"] i')).toBeInTheDocument()
})
- it('should not show spinner for xs and sm sizes', () => {
- const { rerender, container } = render(<Switch checked={false} loading size="xs" />)
- expect(container.querySelector('span[aria-hidden="true"] i')).not.toBeInTheDocument()
+ it('should not show spinner for xs and sm sizes', async () => {
+ const screen = await render(<Switch checked={false} loading size="xs" />)
+ expect(screen.container.querySelector('span[aria-hidden="true"] i')).not.toBeInTheDocument()
- rerender(<Switch checked={false} loading size="sm" />)
- expect(container.querySelector('span[aria-hidden="true"] i')).not.toBeInTheDocument()
+ await screen.rerender(<Switch checked={false} loading size="sm" />)
+ expect(screen.container.querySelector('span[aria-hidden="true"] i')).not.toBeInTheDocument()
})
- it('should apply disabled data-state hooks when loading', () => {
- const { rerender } = render(<Switch checked={false} loading />)
- const switchElement = screen.getByRole('switch')
+ it('should apply disabled data-state hooks when loading', async () => {
+ const screen = await render(<Switch checked={false} loading />)
- expect(switchElement).toHaveAttribute('data-disabled', '')
+ await expect.element(screen.getByRole('switch')).toHaveAttribute('data-disabled', '')
- rerender(<Switch checked={true} loading />)
- expect(switchElement).toHaveAttribute('data-disabled', '')
- expect(switchElement).toHaveAttribute('data-checked', '')
+ await screen.rerender(<Switch checked={true} loading />)
+ await expect.element(screen.getByRole('switch')).toHaveAttribute('data-disabled', '')
+ await expect.element(screen.getByRole('switch')).toHaveAttribute('data-checked', '')
})
})
})
describe('SwitchSkeleton', () => {
- it('should render a plain div without switch role', () => {
- render(<SwitchSkeleton data-testid="skeleton-switch" />)
- expect(screen.queryByRole('switch')).not.toBeInTheDocument()
- expect(screen.getByTestId('skeleton-switch')).toBeInTheDocument()
+ it('should render a plain div without switch role', async () => {
+ const screen = await render(<SwitchSkeleton data-testid="skeleton-switch" />)
+ expect(screen.container.querySelector('[role="switch"]')).not.toBeInTheDocument()
+ await expect.element(screen.getByTestId('skeleton-switch')).toBeInTheDocument()
})
- it('should apply skeleton styles', () => {
- render(<SwitchSkeleton data-testid="skeleton-switch" />)
- const el = screen.getByTestId('skeleton-switch')
- expect(el).toHaveClass('bg-text-quaternary', 'opacity-20')
+ it('should apply skeleton styles', async () => {
+ const screen = await render(<SwitchSkeleton data-testid="skeleton-switch" />)
+ await expect.element(screen.getByTestId('skeleton-switch')).toHaveClass('bg-text-quaternary', 'opacity-20')
})
- it('should apply correct skeleton size classes', () => {
- const { rerender } = render(<SwitchSkeleton size="xs" data-testid="s" />)
- const el = screen.getByTestId('s')
- expect(el).toHaveClass('h-2.5', 'w-3.5', 'rounded-xs')
+ it('should apply correct skeleton size classes', async () => {
+ const screen = await render(<SwitchSkeleton size="xs" data-testid="s" />)
+ await expect.element(screen.getByTestId('s')).toHaveClass('h-2.5', 'w-3.5', 'rounded-xs')
- rerender(<SwitchSkeleton size="lg" data-testid="s" />)
- expect(el).toHaveClass('h-5', 'w-9', 'rounded-md')
+ await screen.rerender(<SwitchSkeleton size="lg" data-testid="s" />)
+ await expect.element(screen.getByTestId('s')).toHaveClass('h-5', 'w-9', 'rounded-md')
})
- it('should apply custom className to skeleton', () => {
- render(<SwitchSkeleton className="custom-class" data-testid="s" />)
- expect(screen.getByTestId('s')).toHaveClass('custom-class')
+ it('should apply custom className to skeleton', async () => {
+ const screen = await render(<SwitchSkeleton className="custom-class" data-testid="s" />)
+ await expect.element(screen.getByTestId('s')).toHaveClass('custom-class')
})
})
diff --git a/packages/dify-ui/src/toast/__tests__/index.spec.tsx b/packages/dify-ui/src/toast/__tests__/index.spec.tsx
index a35d16f2b28..a1191dff868 100644
--- a/packages/dify-ui/src/toast/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/toast/__tests__/index.spec.tsx
@@ -1,316 +1,236 @@
-import { act, fireEvent, render, screen, waitFor } from '@testing-library/react'
-import * as React from 'react'
+import { render } from 'vitest-browser-react'
import { toast, ToastHost } from '../index'
+const asHTMLElement = (element: HTMLElement | SVGElement) => element as HTMLElement
+
describe('base/ui/toast', () => {
beforeEach(() => {
vi.clearAllMocks()
vi.useFakeTimers({ shouldAdvanceTime: true })
- act(() => {
- toast.dismiss()
- })
+ toast.dismiss()
})
afterEach(() => {
- act(() => {
- toast.dismiss()
- vi.runOnlyPendingTimers()
- })
+ toast.dismiss()
+ vi.runOnlyPendingTimers()
vi.useRealTimers()
})
- // Core host and manager integration.
it('should render a success toast when called through the typed shortcut', async () => {
- render(<ToastHost />)
+ const screen = await render(<ToastHost />)
- act(() => {
- toast.success('Saved', {
- description: 'Your changes are available now.',
- })
+ toast.success('Saved', {
+ description: 'Your changes are available now.',
})
- expect(await screen.findByText('Saved')).toBeInTheDocument()
- expect(screen.getByText('Your changes are available now.')).toBeInTheDocument()
- const viewport = screen.getByRole('region', { name: 'Notifications' })
- expect(viewport).toHaveAttribute('aria-live', 'polite')
- expect(viewport).toHaveClass('z-1003')
- expect(viewport.firstElementChild).toHaveClass('top-4')
- expect(screen.getByRole('dialog')).not.toHaveClass('outline-hidden')
+ await expect.element(screen.getByText('Saved')).toBeInTheDocument()
+ await expect.element(screen.getByText('Your changes are available now.')).toBeInTheDocument()
+ await expect.element(screen.getByRole('region', { name: 'Notifications' })).toHaveAttribute('aria-live', 'polite')
+ await expect.element(screen.getByRole('region', { name: 'Notifications' })).toHaveClass('z-1003')
+ expect(screen.getByRole('region', { name: 'Notifications' }).element().firstElementChild).toHaveClass('top-4')
+ expect(screen.getByRole('dialog').element()).not.toHaveClass('outline-hidden')
expect(document.body.querySelector('[aria-hidden="true"].i-ri-checkbox-circle-fill')).toBeInTheDocument()
expect(document.body.querySelector('button[aria-label="Close notification"][aria-hidden="true"]')).toBeInTheDocument()
})
- // Collapsed stacks should keep multiple toast roots mounted for smooth stack animation.
it('should keep multiple toast roots mounted in a collapsed stack', async () => {
- render(<ToastHost />)
+ const screen = await render(<ToastHost />)
- act(() => {
- toast('First toast')
- })
-
- expect(await screen.findByText('First toast')).toBeInTheDocument()
+ toast('First toast')
+ await expect.element(screen.getByText('First toast')).toBeInTheDocument()
- act(() => {
- toast('Second toast')
- toast('Third toast')
- })
+ toast('Second toast')
+ toast('Third toast')
- expect(await screen.findByText('Third toast')).toBeInTheDocument()
- expect(screen.getAllByRole('dialog')).toHaveLength(3)
+ await expect.element(screen.getByText('Third toast')).toBeInTheDocument()
+ expect(document.body.querySelectorAll('[role="dialog"]')).toHaveLength(3)
expect(document.body.querySelectorAll('button[aria-label="Close notification"][aria-hidden="true"]')).toHaveLength(3)
- fireEvent.mouseEnter(screen.getByRole('region', { name: 'Notifications' }))
+ screen.getByRole('region', { name: 'Notifications' }).element().dispatchEvent(new MouseEvent('mouseover', {
+ bubbles: true,
+ }))
- await waitFor(() => {
+ await vi.waitFor(() => {
expect(document.body.querySelector('button[aria-label="Close notification"][aria-hidden="true"]')).not.toBeInTheDocument()
})
})
- // Neutral calls should map directly to a toast with only a title.
it('should render a neutral toast when called directly', async () => {
- render(<ToastHost />)
+ const screen = await render(<ToastHost />)
- act(() => {
- toast('Neutral toast')
- })
+ toast('Neutral toast')
- expect(await screen.findByText('Neutral toast')).toBeInTheDocument()
+ await expect.element(screen.getByText('Neutral toast')).toBeInTheDocument()
expect(document.body.querySelector('[aria-hidden="true"].i-ri-information-2-fill')).not.toBeInTheDocument()
})
- // Base UI limit should cap the visible stack and mark overflow toasts as limited.
it('should mark overflow toasts as limited when the stack exceeds the configured limit', async () => {
- render(<ToastHost limit={1} />)
+ const screen = await render(<ToastHost limit={1} />)
- act(() => {
- toast('First toast')
- toast('Second toast')
- })
+ toast('First toast')
+ toast('Second toast')
- expect(await screen.findByText('Second toast')).toBeInTheDocument()
+ await expect.element(screen.getByText('Second toast')).toBeInTheDocument()
expect(document.body.querySelector('[data-limited]')).toBeInTheDocument()
})
- // Closing should work through the public manager API.
it('should dismiss a toast when dismiss(id) is called', async () => {
- render(<ToastHost />)
+ const screen = await render(<ToastHost />)
- let toastId = ''
- act(() => {
- toastId = toast('Closable', {
- description: 'This toast can be removed.',
- })
+ const toastId = toast('Closable', {
+ description: 'This toast can be removed.',
})
- expect(await screen.findByText('Closable')).toBeInTheDocument()
+ await expect.element(screen.getByText('Closable')).toBeInTheDocument()
- act(() => {
- toast.dismiss(toastId)
- })
+ toast.dismiss(toastId)
- await waitFor(() => {
- expect(screen.queryByText('Closable')).not.toBeInTheDocument()
+ await vi.waitFor(() => {
+ expect(document.body).not.toHaveTextContent('Closable')
})
})
- // User dismissal needs to remain accessible.
it('should close a toast when the dismiss button is clicked', async () => {
const onClose = vi.fn()
+ const screen = await render(<ToastHost />)
- render(<ToastHost />)
-
- act(() => {
- toast('Dismiss me', {
- description: 'Manual dismissal path.',
- onClose,
- })
+ toast('Dismiss me', {
+ description: 'Manual dismissal path.',
+ onClose,
})
- fireEvent.mouseEnter(screen.getByRole('region', { name: 'Notifications' }))
-
- const dismissButton = await screen.findByRole('button', { name: 'Close notification' })
+ screen.getByRole('region', { name: 'Notifications' }).element().dispatchEvent(new MouseEvent('mouseover', {
+ bubbles: true,
+ }))
- act(() => {
- dismissButton.click()
- })
+ await expect.element(screen.getByRole('button', { name: 'Close notification' })).toBeInTheDocument()
+ asHTMLElement(screen.getByRole('button', { name: 'Close notification' }).element()).click()
- await waitFor(() => {
- expect(screen.queryByText('Dismiss me')).not.toBeInTheDocument()
+ await vi.waitFor(() => {
+ expect(document.body).not.toHaveTextContent('Dismiss me')
})
expect(onClose).toHaveBeenCalledTimes(1)
})
- // Base UI default timeout should apply when no timeout is provided.
it('should auto dismiss toasts with the Base UI default timeout', async () => {
- render(<ToastHost />)
-
- act(() => {
- toast('Default timeout')
- })
+ const screen = await render(<ToastHost />)
- expect(await screen.findByText('Default timeout')).toBeInTheDocument()
+ toast('Default timeout')
+ await expect.element(screen.getByText('Default timeout')).toBeInTheDocument()
- act(() => {
- vi.advanceTimersByTime(4999)
- })
-
- expect(screen.getByText('Default timeout')).toBeInTheDocument()
+ await vi.advanceTimersByTimeAsync(4999)
+ expect(document.body).toHaveTextContent('Default timeout')
- act(() => {
- vi.advanceTimersByTime(1)
- })
-
- await waitFor(() => {
- expect(screen.queryByText('Default timeout')).not.toBeInTheDocument()
+ await vi.advanceTimersByTimeAsync(1)
+ await vi.waitFor(() => {
+ expect(document.body).not.toHaveTextContent('Default timeout')
})
})
- // Provider timeout should apply to all toasts when configured.
it('should respect the host timeout configuration', async () => {
- render(<ToastHost timeout={3000} />)
-
- act(() => {
- toast('Configured timeout')
- })
-
- expect(await screen.findByText('Configured timeout')).toBeInTheDocument()
-
- act(() => {
- vi.advanceTimersByTime(2999)
- })
+ const screen = await render(<ToastHost timeout={3000} />)
- expect(screen.getByText('Configured timeout')).toBeInTheDocument()
+ toast('Configured timeout')
+ await expect.element(screen.getByText('Configured timeout')).toBeInTheDocument()
- act(() => {
- vi.advanceTimersByTime(1)
- })
+ await vi.advanceTimersByTimeAsync(2999)
+ expect(document.body).toHaveTextContent('Configured timeout')
- await waitFor(() => {
- expect(screen.queryByText('Configured timeout')).not.toBeInTheDocument()
+ await vi.advanceTimersByTimeAsync(1)
+ await vi.waitFor(() => {
+ expect(document.body).not.toHaveTextContent('Configured timeout')
})
})
- // Callers must be able to override or disable timeout per toast.
it('should respect custom timeout values including zero', async () => {
- render(<ToastHost />)
+ const screen = await render(<ToastHost />)
- act(() => {
- toast('Custom timeout', {
- timeout: 1000,
- })
+ toast('Custom timeout', {
+ timeout: 1000,
})
+ await expect.element(screen.getByText('Custom timeout')).toBeInTheDocument()
- expect(await screen.findByText('Custom timeout')).toBeInTheDocument()
-
- act(() => {
- vi.advanceTimersByTime(1000)
+ await vi.advanceTimersByTimeAsync(1000)
+ await vi.waitFor(() => {
+ expect(document.body).not.toHaveTextContent('Custom timeout')
})
- await waitFor(() => {
- expect(screen.queryByText('Custom timeout')).not.toBeInTheDocument()
- })
-
- act(() => {
- toast('Persistent', {
- timeout: 0,
- })
- })
-
- expect(await screen.findByText('Persistent')).toBeInTheDocument()
-
- act(() => {
- vi.advanceTimersByTime(10000)
+ toast('Persistent', {
+ timeout: 0,
})
+ await expect.element(screen.getByText('Persistent')).toBeInTheDocument()
- expect(screen.getByText('Persistent')).toBeInTheDocument()
+ await vi.advanceTimersByTimeAsync(10000)
+ expect(document.body).toHaveTextContent('Persistent')
})
- // Updates should flow through the same manager state.
it('should update an existing toast', async () => {
- render(<ToastHost />)
+ const screen = await render(<ToastHost />)
- let toastId = ''
- act(() => {
- toastId = toast.info('Loading', {
- description: 'Preparing your data…',
- })
+ const toastId = toast.info('Loading', {
+ description: 'Preparing your data…',
})
+ await expect.element(screen.getByText('Loading')).toBeInTheDocument()
- expect(await screen.findByText('Loading')).toBeInTheDocument()
-
- act(() => {
- toast.update(toastId, {
- title: 'Done',
- description: 'Your data is ready.',
- type: 'success',
- })
+ toast.update(toastId, {
+ title: 'Done',
+ description: 'Your data is ready.',
+ type: 'success',
})
- expect(screen.getByText('Done')).toBeInTheDocument()
- expect(screen.getByText('Your data is ready.')).toBeInTheDocument()
- expect(screen.queryByText('Loading')).not.toBeInTheDocument()
+ await expect.element(screen.getByText('Done')).toBeInTheDocument()
+ await expect.element(screen.getByText('Your data is ready.')).toBeInTheDocument()
+ expect(document.body).not.toHaveTextContent('Loading')
})
- // Re-adding the same toast id should upsert in place instead of stacking duplicates.
it('should upsert an existing toast when add is called with the same id', async () => {
- render(<ToastHost />)
+ const screen = await render(<ToastHost />)
- act(() => {
- toast('Syncing', {
- id: 'sync-job',
- description: 'Uploading changes…',
- })
+ toast('Syncing', {
+ id: 'sync-job',
+ description: 'Uploading changes…',
})
+ await expect.element(screen.getByText('Syncing')).toBeInTheDocument()
- expect(await screen.findByText('Syncing')).toBeInTheDocument()
-
- act(() => {
- toast.success('Synced', {
- id: 'sync-job',
- description: 'All changes are uploaded.',
- })
+ toast.success('Synced', {
+ id: 'sync-job',
+ description: 'All changes are uploaded.',
})
- expect(screen.queryByText('Syncing')).not.toBeInTheDocument()
- expect(screen.getByText('Synced')).toBeInTheDocument()
- expect(screen.getByText('All changes are uploaded.')).toBeInTheDocument()
- expect(screen.getAllByRole('dialog')).toHaveLength(1)
+ await vi.waitFor(() => {
+ expect(document.body).not.toHaveTextContent('Syncing')
+ })
+ await expect.element(screen.getByText('Synced')).toBeInTheDocument()
+ await expect.element(screen.getByText('All changes are uploaded.')).toBeInTheDocument()
+ expect(document.body.querySelectorAll('[role="dialog"]')).toHaveLength(1)
})
- // Action props should pass through to the Base UI action button.
it('should render and invoke toast action props', async () => {
const onAction = vi.fn()
+ const screen = await render(<ToastHost />)
- render(<ToastHost />)
-
- act(() => {
- toast('Action toast', {
- actionProps: {
- children: 'Undo',
- onClick: onAction,
- },
- })
+ toast('Action toast', {
+ actionProps: {
+ children: 'Undo',
+ onClick: onAction,
+ },
})
- const actionButton = await screen.findByRole('button', { name: 'Undo' })
-
- act(() => {
- actionButton.click()
- })
+ await expect.element(screen.getByRole('button', { name: 'Undo' })).toBeInTheDocument()
+ asHTMLElement(screen.getByRole('button', { name: 'Undo' }).element()).click()
expect(onAction).toHaveBeenCalledTimes(1)
})
- // Promise helpers are part of the public API and need a regression test.
it('should transition a promise toast from loading to success', async () => {
- render(<ToastHost />)
+ const screen = await render(<ToastHost />)
let resolvePromise: ((value: string) => void) | undefined
const promise = new Promise<string>((resolve) => {
resolvePromise = resolve
})
- void act(() => toast.promise(promise, {
+ void toast.promise(promise, {
loading: 'Saving…',
success: result => ({
title: 'Saved',
@@ -318,16 +238,14 @@ describe('base/ui/toast', () => {
type: 'success',
}),
error: 'Failed',
- }))
+ })
- expect(await screen.findByText('Saving…')).toBeInTheDocument()
+ await expect.element(screen.getByText('Saving…')).toBeInTheDocument()
- await act(async () => {
- resolvePromise?.('Your changes are available now.')
- await promise
- })
+ resolvePromise?.('Your changes are available now.')
+ await promise
- expect(await screen.findByText('Saved')).toBeInTheDocument()
- expect(screen.getByText('Your changes are available now.')).toBeInTheDocument()
+ await expect.element(screen.getByText('Saved')).toBeInTheDocument()
+ await expect.element(screen.getByText('Your changes are available now.')).toBeInTheDocument()
})
})
diff --git a/packages/dify-ui/src/tooltip/__tests__/index.spec.tsx b/packages/dify-ui/src/tooltip/__tests__/index.spec.tsx
index 7feee4f8c33..3660c2c8e50 100644
--- a/packages/dify-ui/src/tooltip/__tests__/index.spec.tsx
+++ b/packages/dify-ui/src/tooltip/__tests__/index.spec.tsx
@@ -1,11 +1,16 @@
-import { fireEvent, render, screen } from '@testing-library/react'
-import { describe, expect, it, vi } from 'vitest'
+import { render } from 'vitest-browser-react'
import { Tooltip, TooltipContent, TooltipTrigger } from '../index'
+const renderWithSafeViewport = (ui: import('react').ReactNode) => render(
+ <div style={{ minHeight: '100vh', minWidth: '100vw', padding: '240px' }}>
+ {ui}
+ </div>,
+)
+
describe('TooltipContent', () => {
describe('Placement and offsets', () => {
- it('should use default top placement when placement is not provided', () => {
- render(
+ it('should use default top placement when placement is not provided', async () => {
+ const screen = await renderWithSafeViewport(
<Tooltip open>
<TooltipTrigger aria-label="tooltip trigger">Trigger</TooltipTrigger>
<TooltipContent role="tooltip" aria-label="default tooltip">
@@ -14,14 +19,13 @@ describe('TooltipContent', () => {
</Tooltip>,
)
- const popup = screen.getByRole('tooltip', { name: 'default tooltip' })
- expect(popup).toHaveAttribute('data-side', 'top')
- expect(popup).toHaveAttribute('data-align', 'center')
- expect(popup).toHaveTextContent('Tooltip body')
+ await expect.element(screen.getByRole('tooltip', { name: 'default tooltip' })).toHaveAttribute('data-side', 'top')
+ await expect.element(screen.getByRole('tooltip', { name: 'default tooltip' })).toHaveAttribute('data-align', 'center')
+ await expect.element(screen.getByRole('tooltip', { name: 'default tooltip' })).toHaveTextContent('Tooltip body')
})
- it('should apply custom placement when placement props are provided', () => {
- render(
+ it('should apply custom placement when placement props are provided', async () => {
+ const screen = await renderWithSafeViewport(
<Tooltip open>
<TooltipTrigger aria-label="tooltip trigger">Trigger</TooltipTrigger>
<TooltipContent
@@ -36,16 +40,15 @@ describe('TooltipContent', () => {
</Tooltip>,
)
- const popup = screen.getByRole('tooltip', { name: 'custom tooltip' })
- expect(popup).toHaveAttribute('data-side', 'bottom')
- expect(popup).toHaveAttribute('data-align', 'start')
- expect(popup).toHaveTextContent('Custom tooltip body')
+ await expect.element(screen.getByRole('tooltip', { name: 'custom tooltip' })).toHaveAttribute('data-side', 'bottom')
+ await expect.element(screen.getByRole('tooltip', { name: 'custom tooltip' })).toHaveAttribute('data-align', 'start')
+ await expect.element(screen.getByRole('tooltip', { name: 'custom tooltip' })).toHaveTextContent('Custom tooltip body')
})
})
describe('Variant and popup props', () => {
- it('should render popup content when variant is plain', () => {
- render(
+ it('should render popup content when variant is plain', async () => {
+ const screen = await render(
<Tooltip open>
<TooltipTrigger aria-label="tooltip trigger">Trigger</TooltipTrigger>
<TooltipContent variant="plain" role="tooltip" aria-label="plain tooltip">
@@ -54,13 +57,13 @@ describe('TooltipContent', () => {
</Tooltip>,
)
- expect(screen.getByRole('tooltip', { name: 'plain tooltip' })).toHaveTextContent('Plain tooltip body')
+ await expect.element(screen.getByRole('tooltip', { name: 'plain tooltip' })).toHaveTextContent('Plain tooltip body')
})
- it('should forward popup props and handlers when popup props are provided', () => {
+ it('should forward popup props and handlers when popup props are provided', async () => {
const onMouseEnter = vi.fn()
- render(
+ const screen = await render(
<Tooltip open>
<TooltipTrigger aria-label="tooltip trigger">Trigger</TooltipTrigger>
<TooltipContent
@@ -76,15 +79,15 @@ describe('TooltipContent', () => {
)
const popup = screen.getByRole('tooltip', { name: 'help text' })
- fireEvent.mouseEnter(popup)
+ await popup.hover()
- expect(popup).toHaveAttribute('id', 'tooltip-popup-id')
- expect(popup).toHaveAttribute('data-track-id', 'tooltip-track')
+ await expect.element(popup).toHaveAttribute('id', 'tooltip-popup-id')
+ await expect.element(popup).toHaveAttribute('data-track-id', 'tooltip-track')
expect(onMouseEnter).toHaveBeenCalledTimes(1)
})
- it('should apply className to the popup and positionerClassName to the positioner', () => {
- render(
+ it('should apply className to the popup and positionerClassName to the positioner', async () => {
+ const screen = await render(
<Tooltip open>
<TooltipTrigger aria-label="tooltip trigger">Trigger</TooltipTrigger>
<TooltipContent
@@ -98,7 +101,7 @@ describe('TooltipContent', () => {
</Tooltip>,
)
- const popup = screen.getByRole('tooltip', { name: 'styled tooltip' })
+ const popup = screen.getByRole('tooltip', { name: 'styled tooltip' }).element()
expect(popup).toHaveClass('popup-class')
expect(popup.parentElement).toHaveClass('positioner-class')
})
diff --git a/packages/dify-ui/tests/setup.ts b/packages/dify-ui/tests/setup.ts
deleted file mode 100644
index e1ea15af2b5..00000000000
--- a/packages/dify-ui/tests/setup.ts
+++ /dev/null
@@ -1,44 +0,0 @@
-import { act, cleanup } from '@testing-library/react'
-import '@testing-library/jest-dom/vitest'
-
-if (typeof Element !== 'undefined' && !Element.prototype.getAnimations)
- Element.prototype.getAnimations = () => []
-
-if (typeof document !== 'undefined' && !document.getAnimations)
- document.getAnimations = () => []
-
-if (typeof globalThis.ResizeObserver === 'undefined') {
- globalThis.ResizeObserver = class {
- observe() {
- return undefined
- }
-
- unobserve() {
- return undefined
- }
-
- disconnect() {
- return undefined
- }
- }
-}
-
-if (typeof globalThis.IntersectionObserver === 'undefined') {
- globalThis.IntersectionObserver = class {
- readonly root: Element | Document | null = null
- readonly rootMargin: string = ''
- readonly scrollMargin: string = ''
- readonly thresholds: ReadonlyArray<number> = []
- constructor(_callback: IntersectionObserverCallback, _options?: IntersectionObserverInit) { /* noop */ }
- observe(_target: Element) { /* noop */ }
- unobserve(_target: Element) { /* noop */ }
- disconnect() { /* noop */ }
- takeRecords(): IntersectionObserverEntry[] { return [] }
- }
-}
-
-afterEach(async () => {
- await act(async () => {
- cleanup()
- })
-})
diff --git a/packages/dify-ui/tsconfig.json b/packages/dify-ui/tsconfig.json
index 678e1de897a..10cffbcd76f 100644
--- a/packages/dify-ui/tsconfig.json
+++ b/packages/dify-ui/tsconfig.json
@@ -1,10 +1,6 @@
{
"extends": "@dify/tsconfig/react.json",
"compilerOptions": {
- "rootDir": ".",
- "types": ["vitest/globals", "@testing-library/jest-dom"],
- "isolatedModules": true,
- "verbatimModuleSyntax": true
- },
- "include": ["src", "tests", ".storybook", "tailwind.config.ts", "vite.config.ts"]
+ "types": ["vite-plus/test/globals"]
+ }
}
diff --git a/packages/dify-ui/vite.config.ts b/packages/dify-ui/vite.config.ts
index a20b7fb35cd..5f3533c706e 100644
--- a/packages/dify-ui/vite.config.ts
+++ b/packages/dify-ui/vite.config.ts
@@ -1,5 +1,6 @@
import react from '@vitejs/plugin-react'
import { defineConfig } from 'vite-plus'
+import { playwright } from 'vite-plus/test/browser-playwright'
const isCI = !!process.env.CI
@@ -9,9 +10,13 @@ export default defineConfig({
tsconfigPaths: true,
},
test: {
- environment: 'happy-dom',
globals: true,
- setupFiles: ['./tests/setup.ts'],
+ browser: {
+ enabled: true,
+ provider: playwright(),
+ instances: [{ browser: 'chromium' }],
+ headless: true,
+ },
coverage: {
provider: 'v8',
include: ['src/**/*.{ts,tsx}'],
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index 1e0994d0a2b..65f2e05bf49 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -1,7 +1,7 @@
lockfileVersion: '9.0'
settings:
- autoInstallPeers: true
+ autoInstallPeers: false
excludeLinksFromLockfile: false
catalogs:
@@ -414,6 +414,9 @@ catalogs:
pinyin-pro:
specifier: 3.28.1
version: 3.28.1
+ playwright:
+ specifier: 1.59.1
+ version: 1.59.1
postcss:
specifier: 8.5.9
version: 8.5.9
@@ -531,6 +534,9 @@ catalogs:
vite-plus:
specifier: 0.1.18
version: 0.1.18
+ vitest-browser-react:
+ specifier: 2.2.0
+ version: 2.2.0
vitest-canvas-mock:
specifier: 1.1.4
version: 1.1.4
@@ -579,7 +585,7 @@ importers:
devDependencies:
'@antfu/eslint-config':
specifier: 'catalog:'
eslint:
specifier: 'catalog:'
version: 10.2.0([email protected])
@@ -594,10 +600,10 @@ importers:
vite:
specifier: npm:@voidzero-dev/[email protected]
vite-plus:
specifier: 'catalog:'
e2e:
devDependencies:
@@ -621,10 +627,10 @@ importers:
version: 6.0.2
vite:
specifier: npm:@voidzero-dev/[email protected]
vite-plus:
specifier: 'catalog:'
packages/dify-ui:
dependencies:
@@ -637,7 +643,7 @@ importers:
devDependencies:
'@base-ui/react':
specifier: 'catalog:'
'@chromatic-com/storybook':
specifier: 'catalog:'
@@ -652,7 +658,7 @@ importers:
version: 1.2.10
'@storybook/addon-docs':
specifier: 'catalog:'
'@storybook/addon-links':
specifier: 'catalog:'
@@ -661,19 +667,10 @@ importers:
'@storybook/react-vite':
specifier: 'catalog:'
'@tailwindcss/vite':
specifier: 'catalog:'
- '@testing-library/jest-dom':
- specifier: 'catalog:'
- version: 6.9.1
- '@testing-library/react':
- specifier: 'catalog:'
- '@testing-library/user-event':
- specifier: 'catalog:'
- version: 14.6.1(@testing-library/[email protected])
'@types/react':
specifier: 'catalog:'
version: 19.2.14
@@ -682,16 +679,16 @@ importers:
version: 19.2.3(@types/[email protected])
'@vitejs/plugin-react':
specifier: 'catalog:'
'@vitest/coverage-v8':
specifier: 'catalog:'
- version: 4.1.4(@voidzero-dev/[email protected])
class-variance-authority:
specifier: 'catalog:'
version: 0.7.1
- happy-dom:
+ playwright:
specifier: 'catalog:'
- version: 20.9.0
+ version: 1.59.1
react:
specifier: 'catalog:'
version: 19.2.5
@@ -709,13 +706,13 @@ importers:
version: 6.0.2
vite:
specifier: npm:@voidzero-dev/[email protected]
vite-plus:
specifier: 'catalog:'
- vitest:
- specifier: npm:@voidzero-dev/[email protected]
+ vitest-browser-react:
+ specifier: 'catalog:'
packages/iconify-collections:
devDependencies:
@@ -737,10 +734,10 @@ importers:
version: 25.6.0
vite:
specifier: npm:@voidzero-dev/[email protected]
vite-plus:
specifier: 'catalog:'
packages/tsconfig: {}
@@ -763,7 +760,7 @@ importers:
'@vitest/coverage-v8':
specifier: 'catalog:'
- version: 4.1.4(@voidzero-dev/[email protected])
eslint:
specifier: 'catalog:'
version: 10.2.0([email protected])
@@ -772,13 +769,13 @@ importers:
version: 6.0.2
vite:
specifier: npm:@voidzero-dev/[email protected]
vite-plus:
specifier: 'catalog:'
vitest:
specifier: npm:@voidzero-dev/[email protected]
web:
dependencies:
@@ -787,10 +784,10 @@ importers:
version: 2.39.0
'@amplitude/plugin-session-replay-browser':
specifier: 'catalog:'
- version: 1.27.7(@amplitude/[email protected])([email protected])
+ version: 1.27.7(@amplitude/[email protected])
'@base-ui/react':
specifier: 'catalog:'
'@emoji-mart/data':
specifier: 'catalog:'
version: 1.2.1
@@ -817,7 +814,7 @@ importers:
version: 0.43.0
'@lexical/react':
specifier: 'catalog:'
'@lexical/selection':
specifier: 'catalog:'
version: 0.43.0
@@ -829,7 +826,7 @@ importers:
version: 0.43.0
'@monaco-editor/react':
specifier: 'catalog:'
'@orpc/client':
specifier: 'catalog:'
version: 1.13.14
@@ -985,13 +982,13 @@ importers:
version: 1.0.0
next:
specifier: 'catalog:'
next-themes:
specifier: 'catalog:'
nuqs:
specifier: 'catalog:'
pinyin-pro:
specifier: 'catalog:'
version: 3.28.1
@@ -1091,7 +1088,7 @@ importers:
devDependencies:
'@antfu/eslint-config':
specifier: 'catalog:'
'@chromatic-com/storybook':
specifier: 'catalog:'
@@ -1121,25 +1118,25 @@ importers:
version: link:../packages/dify-ui
'@mdx-js/loader':
specifier: 'catalog:'
+ version: 3.1.1
'@mdx-js/react':
specifier: 'catalog:'
version: 3.1.1(@types/[email protected])([email protected])
'@mdx-js/rollup':
specifier: 'catalog:'
- version: 3.1.1([email protected])
+ version: 3.1.1
'@next/eslint-plugin-next':
specifier: 'catalog:'
version: 16.2.3
'@next/mdx':
specifier: 'catalog:'
+ version: 16.2.3(@mdx-js/[email protected])(@mdx-js/[email protected](@types/[email protected])([email protected]))
'@rgrove/parse-xml':
specifier: 'catalog:'
version: 4.2.0
'@storybook/addon-docs':
specifier: 'catalog:'
'@storybook/addon-links':
specifier: 'catalog:'
@@ -1151,7 +1148,7 @@ importers:
'@storybook/nextjs-vite':
specifier: 'catalog:'
'@storybook/react':
specifier: 'catalog:'
@@ -1160,13 +1157,13 @@ importers:
version: 4.2.2
'@tailwindcss/vite':
specifier: 'catalog:'
'@tanstack/eslint-plugin-query':
specifier: 'catalog:'
'@tanstack/react-devtools':
specifier: 'catalog:'
'@tanstack/react-form-devtools':
specifier: 'catalog:'
@@ -1226,13 +1223,13 @@ importers:
version: 7.0.0-dev.20260413.1
'@vitejs/plugin-react':
specifier: 'catalog:'
'@vitejs/plugin-rsc':
specifier: 'catalog:'
'@vitest/coverage-v8':
specifier: 'catalog:'
- version: 4.1.4(@voidzero-dev/[email protected])
agentation:
specifier: 'catalog:'
@@ -1274,13 +1271,13 @@ importers:
version: 4.12.14
knip:
specifier: 'catalog:'
- version: 6.4.1(@emnapi/[email protected])(@emnapi/[email protected])
+ version: 6.4.1(@emnapi/[email protected])
postcss:
specifier: 'catalog:'
version: 8.5.9
react-server-dom-webpack:
specifier: 'catalog:'
storybook:
specifier: 'catalog:'
@@ -1298,22 +1295,22 @@ importers:
version: 3.19.3
vinext:
specifier: 'catalog:'
- version: 0.0.41(453b4e184a832f83060410b31544dc36)
vite:
specifier: npm:@voidzero-dev/[email protected]
vite-plugin-inspect:
specifier: 'catalog:'
vite-plus:
specifier: 'catalog:'
vitest:
specifier: npm:@voidzero-dev/[email protected]
vitest-canvas-mock:
specifier: 'catalog:'
- version: 1.1.4(@voidzero-dev/[email protected])
packages:
@@ -1682,9 +1679,6 @@ packages:
'@cucumber/[email protected]':
resolution: {integrity: sha512-bvHjcRFZ+J1TqIa9eFNO1wGHqwx4V9ZKV3hYgkuK/VahHx73uiP4rKV3JVrvWSMrwrFvJG6C8aEwnCWSvbyFdQ==}
- '@date-fns/[email protected]':
- resolution: {integrity: sha512-P5LUNhtbj6YfI3iJjw5EL9eUAG6OitD0W3fWQcpQjDRc/QIsL0tRNuO1PcDvPccWL1fSTXXdE1ds+l95DV/OFA==}
-
resolution: {integrity: sha512-hHgfpxsrZ2UYHcicA+tGZnmk19uJTaye9VH79O+XS8R4ona2Hx3xjhXghclNW58uXMk3xXlbYEOMr8thsoBmWg==}
peerDependencies:
@@ -1701,18 +1695,9 @@ packages:
peerDependencies:
tailwindcss: '*'
- '@emnapi/[email protected]':
- resolution: {integrity: sha512-UC+ZhH3XtczQYfOlu3lNEkdW/p4dsJ1r/bP7H8+rhao3TTTMO1ATq/4DdIi23XuGoFY+Cz0JmCbdVl0hz9jZcA==}
-
'@emnapi/[email protected]':
resolution: {integrity: sha512-VYi5+ZVLhpgK4hQ0TAjiQiZ6ol0oe4mBx7mVv7IflsiEp0OWoVsp/+f9Vc1hOhE0TtkORVrI1GvzyreqpgWtkA==}
- '@emnapi/[email protected]':
- resolution: {integrity: sha512-3U4+MIWHImeyu1wnmVygh5WlgfYDtyf0k8AbLhMFxOipihf6nrWC4syIm/SwEeec0mNSafiiNnMJwbza/Is6Lw==}
-
- '@emnapi/[email protected]':
- resolution: {integrity: sha512-uTII7OYF+/Mes/MrcIOYp5yOtSMLBWSIoLPpcgwipoiKbli6k322tcoFsxoIIxPDqW01SQGAgko4EzZi2BNv2w==}
-
'@emoji-mart/[email protected]':
resolution: {integrity: sha512-no2pQMWiBy6gpBEiqGeU77/bFejDqUTRY7KX+0+iur13op3bqUsXdnwoZs6Xb1zbv0gAj5VvS1PWoUUckSr5Dw==}
@@ -2290,9 +2275,6 @@ packages:
resolution: {integrity: sha512-bRISgCIjP20/tbWSPWMEi54QVPRZExkuD9lJL+UIxUKtwVJA8wW1Trb1jMs1RFXo1CBTNZ/5hpC9QvmKWdopKw==}
engines: {node: '>=6.0.0'}
- '@jridgewell/[email protected]':
- resolution: {integrity: sha512-ZMp1V8ZFcPG5dIWnQLr3NSI1MiCU7UETdS/A0G8V/XWHvJv3ZsFqutJn1Y5RPmAPX6F3BiE397OqveU/9NCuIA==}
-
'@jridgewell/[email protected]':
resolution: {integrity: sha512-cYQ9310grqxueWbl+WuIUIaiUaDcj7WOq5fVhEljNVgRfOUhY9fy2zTvfoqWsnebh8Sl70VScFbICvJnLKB0Og==}
@@ -3068,94 +3050,6 @@ packages:
cpu: [x64]
os: [win32]
- '@parcel/[email protected]':
- resolution: {integrity: sha512-YQxSS34tPF/6ZG7r/Ih9xy+kP/WwediEUsqmtf0cuCV5TPPKw/PQHRhueUo6JdeFJaqV3pyjm0GdYjZotbRt/A==}
- engines: {node: '>= 10.0.0'}
- cpu: [arm64]
- os: [android]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-Z2ZdrnwyXvvvdtRHLmM4knydIdU9adO3D4n/0cVipF3rRiwP+3/sfzpAwA/qKFL6i1ModaabkU7IbpeMBgiVEA==}
- engines: {node: '>= 10.0.0'}
- cpu: [arm64]
- os: [darwin]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-HgvOf3W9dhithcwOWX9uDZyn1lW9R+7tPZ4sug+NGrGIo4Rk1hAXLEbcH1TQSqxts0NYXXlOWqVpvS1SFS4fRg==}
- engines: {node: '>= 10.0.0'}
- cpu: [x64]
- os: [darwin]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-vJVi8yd/qzJxEKHkeemh7w3YAn6RJCtYlE4HPMoVnCpIXEzSrxErBW5SJBgKLbXU3WdIpkjBTeUNtyBVn8TRng==}
- engines: {node: '>= 10.0.0'}
- cpu: [x64]
- os: [freebsd]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-9JiYfB6h6BgV50CCfasfLf/uvOcJskMSwcdH1PHH9rvS1IrNy8zad6IUVPVUfmXr+u+Km9IxcfMLzgdOudz9EQ==}
- engines: {node: '>= 10.0.0'}
- cpu: [arm]
- os: [linux]
- libc: [glibc]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-Ve3gUCG57nuUUSyjBq/MAM0CzArtuIOxsBdQ+ftz6ho8n7s1i9E1Nmk/xmP323r2YL0SONs1EuwqBp2u1k5fxg==}
- engines: {node: '>= 10.0.0'}
- cpu: [arm]
- os: [linux]
- libc: [musl]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-f2g/DT3NhGPdBmMWYoxixqYr3v/UXcmLOYy16Bx0TM20Tchduwr4EaCbmxh1321TABqPGDpS8D/ggOTaljijOA==}
- engines: {node: '>= 10.0.0'}
- cpu: [arm64]
- os: [linux]
- libc: [glibc]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-qb6naMDGlbCwdhLj6hgoVKJl2odL34z2sqkC7Z6kzir8b5W65WYDpLB6R06KabvZdgoHI/zxke4b3zR0wAbDTA==}
- engines: {node: '>= 10.0.0'}
- cpu: [arm64]
- os: [linux]
- libc: [musl]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-kbT5wvNQlx7NaGjzPFu8nVIW1rWqV780O7ZtkjuWaPUgpv2NMFpjYERVi0UYj1msZNyCzGlaCWEtzc+exjMGbQ==}
- engines: {node: '>= 10.0.0'}
- cpu: [x64]
- os: [linux]
- libc: [glibc]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-1JRFeC+h7RdXwldHzTsmdtYR/Ku8SylLgTU/reMuqdVD7CtLwf0VR1FqeprZ0eHQkO0vqsbvFLXUmYm/uNKJBg==}
- engines: {node: '>= 10.0.0'}
- cpu: [x64]
- os: [linux]
- libc: [musl]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-3ukyebjc6eGlw9yRt678DxVF7rjXatWiHvTXqphZLvo7aC5NdEgFufVwjFfY51ijYEWpXbqF5jtrK275z52D4Q==}
- engines: {node: '>= 10.0.0'}
- cpu: [arm64]
- os: [win32]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-k35yLp1ZMwwee3Ez/pxBi5cf4AoBKYXj00CZ80jUz5h8prpiaQsiRPKQMxoLstNuqe2vR4RNPEAEcjEFzhEz/g==}
- engines: {node: '>= 10.0.0'}
- cpu: [ia32]
- os: [win32]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-hbQlYcCq5dlAX9Qx+kFb0FHue6vbjlf0FrNzSKdYK2APUf7tGfGxQCk2ihEREmbR6ZMc0MVAD5RIX/41gpUzTw==}
- engines: {node: '>= 10.0.0'}
- cpu: [x64]
- os: [win32]
-
- '@parcel/[email protected]':
- resolution: {integrity: sha512-tmmZ3lQxAe/k/+rNnXQRawJ4NjxO2hqiOLTHvWchtGZULp4RyFeh6aU4XdOYBFe2KE1oShQTv4AblOs2iOrNnQ==}
- engines: {node: '>= 10.0.0'}
-
resolution: {integrity: sha512-QNqXyfVS2wm9hweSYD2O7F0G06uurj9kZ96TRQE5Y9hU7+tgdZwIkbAKc5Ocy1HxEY2kuDQa6cQ1WRs/O5LFKA==}
engines: {node: ^12.20.0 || ^14.18.0 || >=16.0.0}
@@ -3474,144 +3368,6 @@ packages:
rollup:
optional: true
- '@rollup/[email protected]':
- resolution: {integrity: sha512-upnNBkA6ZH2VKGcBj9Fyl9IGNPULcjXRlg0LLeaioQWueH30p6IXtJEbKAgvyv+mJaMxSm1l6xwDXYjpEMiLMg==}
- cpu: [arm]
- os: [android]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-hZ+Zxj3SySm4A/DylsDKZAeVg0mvi++0PYVceVyX7hemkw7OreKdCvW2oQ3T1FMZvCaQXqOTHb8qmBShoqk69Q==}
- cpu: [arm64]
- os: [android]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-W2Psnbh1J8ZJw0xKAd8zdNgF9HRLkdWwwdWqubSVk0pUuQkoHnv7rx4GiF9rT4t5DIZGAsConRE3AxCdJ4m8rg==}
- cpu: [arm64]
- os: [darwin]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-ZW2KkwlS4lwTv7ZVsYDiARfFCnSGhzYPdiOU4IM2fDbL+QGlyAbjgSFuqNRbSthybLbIJ915UtZBtmuLrQAT/w==}
- cpu: [x64]
- os: [darwin]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-EsKaJ5ytAu9jI3lonzn3BgG8iRBjV4LxZexygcQbpiU0wU0ATxhNVEpXKfUa0pS05gTcSDMKpn3Sx+QB9RlTTA==}
- cpu: [arm64]
- os: [freebsd]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-d3DuZi2KzTMjImrxoHIAODUZYoUUMsuUiY4SRRcJy6NJoZ6iIqWnJu9IScV9jXysyGMVuW+KNzZvBLOcpdl3Vg==}
- cpu: [x64]
- os: [freebsd]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-t4ONHboXi/3E0rT6OZl1pKbl2Vgxf9vJfWgmUoCEVQVxhW6Cw/c8I6hbbu7DAvgp82RKiH7TpLwxnJeKv2pbsw==}
- cpu: [arm]
- os: [linux]
- libc: [glibc]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-CikFT7aYPA2ufMD086cVORBYGHffBo4K8MQ4uPS/ZnY54GKj36i196u8U+aDVT2LX4eSMbyHtyOh7D7Zvk2VvA==}
- cpu: [arm]
- os: [linux]
- libc: [musl]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-jYgUGk5aLd1nUb1CtQ8E+t5JhLc9x5WdBKew9ZgAXg7DBk0ZHErLHdXM24rfX+bKrFe+Xp5YuJo54I5HFjGDAA==}
- cpu: [arm64]
- os: [linux]
- libc: [glibc]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-peZRVEdnFWZ5Bh2KeumKG9ty7aCXzzEsHShOZEFiCQlDEepP1dpUl/SrUNXNg13UmZl+gzVDPsiCwnV1uI0RUA==}
- cpu: [arm64]
- os: [linux]
- libc: [musl]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-gbUSW/97f7+r4gHy3Jlup8zDG190AuodsWnNiXErp9mT90iCy9NKKU0Xwx5k8VlRAIV2uU9CsMnEFg/xXaOfXg==}
- cpu: [loong64]
- os: [linux]
- libc: [glibc]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-yTRONe79E+o0FWFijasoTjtzG9EBedFXJMl888NBEDCDV9I2wGbFFfJQQe63OijbFCUZqxpHz1GzpbtSFikJ4Q==}
- cpu: [loong64]
- os: [linux]
- libc: [musl]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-sw1o3tfyk12k3OEpRddF68a1unZ5VCN7zoTNtSn2KndUE+ea3m3ROOKRCZxEpmT9nsGnogpFP9x6mnLTCaoLkA==}
- cpu: [ppc64]
- os: [linux]
- libc: [glibc]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-+2kLtQ4xT3AiIxkzFVFXfsmlZiG5FXYW7ZyIIvGA7Bdeuh9Z0aN4hVyXS/G1E9bTP/vqszNIN/pUKCk/BTHsKA==}
- cpu: [ppc64]
- os: [linux]
- libc: [musl]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-NDYMpsXYJJaj+I7UdwIuHHNxXZ/b/N2hR15NyH3m2qAtb/hHPA4g4SuuvrdxetTdndfj9b1WOmy73kcPRoERUg==}
- cpu: [riscv64]
- os: [linux]
- libc: [glibc]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-nLckB8WOqHIf1bhymk+oHxvM9D3tyPndZH8i8+35p/1YiVoVswPid2yLzgX7ZJP0KQvnkhM4H6QZ5m0LzbyIAg==}
- cpu: [riscv64]
- os: [linux]
- libc: [musl]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-oF87Ie3uAIvORFBpwnCvUzdeYUqi2wY6jRFWJAy1qus/udHFYIkplYRW+wo+GRUP4sKzYdmE1Y3+rY5Gc4ZO+w==}
- cpu: [s390x]
- os: [linux]
- libc: [glibc]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-3AHmtQq/ppNuUspKAlvA8HtLybkDflkMuLK4DPo77DfthRb71V84/c4MlWJXixZz4uruIH4uaa07IqoAkG64fg==}
- cpu: [x64]
- os: [linux]
- libc: [glibc]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-2UdiwS/9cTAx7qIUZB/fWtToJwvt0Vbo0zmnYt7ED35KPg13Q0ym1g442THLC7VyI6JfYTP4PiSOWyoMdV2/xg==}
- cpu: [x64]
- os: [linux]
- libc: [musl]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-M3bLRAVk6GOwFlPTIxVBSYKUaqfLrn8l0psKinkCFxl4lQvOSz8ZrKDz2gxcBwHFpci0B6rttydI4IpS4IS/jQ==}
- cpu: [x64]
- os: [openbsd]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-tt9KBJqaqp5i5HUZzoafHZX8b5Q2Fe7UjYERADll83O4fGqJ49O1FsL6LpdzVFQcpwvnyd0i+K/VSwu/o/nWlA==}
- cpu: [arm64]
- os: [openharmony]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-V5B6mG7OrGTwnxaNUzZTDTjDS7F75PO1ae6MJYdiMu60sq0CqN5CVeVsbhPxalupvTX8gXVSU9gq+Rx1/hvu6A==}
- cpu: [arm64]
- os: [win32]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-UKFMHPuM9R0iBegwzKF4y0C4J9u8C6MEJgFuXTBerMk7EJ92GFVFYBfOZaSGLu6COf7FxpQNqhNS4c4icUPqxA==}
- cpu: [ia32]
- os: [win32]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-laBkYlSS1n2L8fSo1thDNGrCTQMmxjYY5G0WFWjFFYZkKPjsMBsgJfGf4TLxXrF6RyhI60L8TMOjBMvXiTcxeA==}
- cpu: [x64]
- os: [win32]
-
- '@rollup/[email protected]':
- resolution: {integrity: sha512-2HRCml6OztYXyJXAvdDXPKcawukWY2GpR5/nxKp4iBgiO3wcoEGkAaqctIbZcNB6KlUQBIqt8VYkNSj2397EfA==}
- cpu: [x64]
- os: [win32]
-
'@sentry-internal/[email protected]':
resolution: {integrity: sha512-SCiTLBXzugFKxev6NoKYBIhQoDk0gUh0AVVVepCBqfCJiWBG01Zvv0R5tCVohr4cWRllkQ8mlBdNQd/I7s9tdA==}
engines: {node: '>=18'}
@@ -3989,8 +3745,6 @@ packages:
'@tanstack/[email protected]':
resolution: {integrity: sha512-T9JjAdqMSnxsVO6AQykD5vhxPF4iFLKtbYxee/bU3OLlk446F5C1220GdCmhDSz7y4lx+m8AvIS0bq6zzvdDUA==}
engines: {node: '>=18'}
- peerDependencies:
- solid-js: 1.9.11
'@tanstack/[email protected]':
resolution: {integrity: sha512-KsGzYhA8L/fCNgyyMyoUy+TKtx+DjNbzWwqH6wXL48Llzo7kvV9RynYJlaO8Qkzwm+NdHXSgsljQNjQ3CKPpZA==}
@@ -4018,8 +3772,6 @@ packages:
resolution: {integrity: sha512-K8+tsBx+ptTLqqd4dOF10B6laj1g+XYImqYZL9n0jBINGaT+sOf17PKV9pbBt8kdbZeIGsHaJ5OZWCyZoHqN4A==}
engines: {node: '>=18'}
hasBin: true
- peerDependencies:
- solid-js: 1.9.11
'@tanstack/[email protected]':
resolution: {integrity: sha512-jVp1AEL7S7BeuQvH5SN1F5UdrNW/AbryKDeWUUMeAKNzh9C+Ik/bRSa/HeuJLlmaN+WOUkdDFbtCK0go7BxnUQ==}
@@ -4289,12 +4041,6 @@ packages:
resolution: {integrity: sha512-eOIHzCUSH7SMfonMG1LsC2f8vxBFtho6NGBznK41R84YzPuvSBzrhEps33IsQiOW9+VL6NQ9DbjQJznk/S4uRA==}
- '@types/[email protected]':
- resolution: {integrity: sha512-MzMFlSLBqNF2gcHWO0G1vP/YQyfvrxZ0bF+u7mzUdZ1/xK4A4sru+nraZz5i3iEIk1l1uyicaDVTB4QbbEkAYg==}
-
- '@types/[email protected]':
- resolution: {integrity: sha512-FXx2pKgId/WyYo2jXw63kk7/+TY7u7AziEJxJAnSFzHlqTAS3Ync6SvgYAN/k4/PQpnnVuzoMuVnByKK2qp0ag==}
-
resolution: {integrity: sha512-xJBAbDifo5hpffDBuHl0Y8ywswbiAp/Wi7Y/GtAgSlZyIABppyurxVueOPE8LUQOxdlgi6Zqce7uoEpqNTeiUw==}
@@ -4389,13 +4135,6 @@ packages:
eslint: ^8.57.0 || ^9.0.0 || ^10.0.0
typescript: '>=4.8.4 <6.1.0'
- '@typescript-eslint/[email protected]':
- resolution: {integrity: sha512-30ScMRHIAD33JJQkgfGW1t8CURZtjc2JpTrq5n2HFhOefbAhb7ucc7xJwdWcrEtqUIYJ73Nybpsggii6GtAHjA==}
- engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
- peerDependencies:
- eslint: ^8.57.0 || ^9.0.0 || ^10.0.0
- typescript: '>=4.8.4 <6.0.0'
-
'@typescript-eslint/[email protected]':
resolution: {integrity: sha512-/Zb/xaIDfxeJnvishjGdcR4jmr7S+bda8PKNhRGdljDM+elXhlvN0FyPSsMnLmJUrVG9aPO6dof80wjMawsASg==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
@@ -4403,38 +4142,16 @@ packages:
eslint: ^8.57.0 || ^9.0.0 || ^10.0.0
typescript: '>=4.8.4 <6.1.0'
- '@typescript-eslint/[email protected]':
- resolution: {integrity: sha512-FuH0wipFywXRTHf+bTTjNyuNQQsQC3qh/dYzaM4I4W0jrCqjCVuUh99+xd9KamUfmCGPvbO8NDngo/vsnNVqgw==}
- engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
- peerDependencies:
- typescript: '>=4.8.4 <6.0.0'
-
'@typescript-eslint/[email protected]':
resolution: {integrity: sha512-Cq6UfpZZk15+r87BkIh5rDpi38W4b+Sjnb8wQCPPDDweS/LRCFjCyViEbzHk5Ck3f2QDfgmlxqSa7S7clDtlfg==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
peerDependencies:
typescript: '>=4.8.4 <6.1.0'
- '@typescript-eslint/[email protected]':
- resolution: {integrity: sha512-cb5m0irr1449waTuYzGi4KD3SGUH3khL4ta/o9lzShvT7gnIwR5qVhU0VM0p966kCrtFId8hwmkvz1fOElsxTg==}
- engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
- peerDependencies:
- eslint: ^8.57.0 || ^9.0.0 || ^10.0.0
-
- '@typescript-eslint/[email protected]':
- resolution: {integrity: sha512-snZKH+W4WbWkrBqj4gUNRIGb/jipDW3qMqVJ4C9rzdFc+wLwruxk+2a5D+uoFcKPAqyqEnSb4l2ULuZf95eSkw==}
- engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
-
'@typescript-eslint/[email protected]':
resolution: {integrity: sha512-SgmyvDPexWETQek+qzZnrG6844IaO02UVyOLhI4wpo82dpZJY9+6YZCKAMFzXb7qhx37mFK1QcPQ18tud+vo6Q==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
- '@typescript-eslint/[email protected]':
- resolution: {integrity: sha512-3Lm5DSM+DCowsUOJC+YqHHnKEfFh5CoGkj5Z31NQSNF4l5wdOwqGn99wmwN/LImhfY3KJnmordBq/4+VDe2eKw==}
- engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
- peerDependencies:
- typescript: '>=4.8.4 <6.0.0'
-
'@typescript-eslint/[email protected]':
resolution: {integrity: sha512-3SR+RukipDvkkKp/d0jP0dyzuls3DbGmwDpVEc5wqk5f38KFThakqAAO0XMirWAE+kT00oTauTbzMFGPoAzB0A==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
@@ -4448,33 +4165,16 @@ packages:
eslint: ^8.57.0 || ^9.0.0 || ^10.0.0
typescript: '>=4.8.4 <6.1.0'
- '@typescript-eslint/[email protected]':
- resolution: {integrity: sha512-/iZM6FnM4tnx9csuTxspMW4BOSegshwX5oBDznJ7S4WggL7Vczz5d2W11ecc4vRrQMQHXRSxzrCsyG5EsPPTbA==}
- engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
-
'@typescript-eslint/[email protected]':
resolution: {integrity: sha512-9TukXyATBQf/Jq9AMQXfvurk+G5R2MwfqQGDR2GzGz28HvY/lXNKGhkY+6IOubwcquikWk5cjlgPvD2uAA7htQ==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
- '@typescript-eslint/[email protected]':
- resolution: {integrity: sha512-2MKM+I6g8tJxfSmFKOnHv2t8Sk3T6rF20A1Puk0svLK+uVapDZB/4pfAeB7nE83uAZrU6OxW+HmOd5wHVdXwXA==}
- engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
- peerDependencies:
- typescript: '>=4.8.4 <6.0.0'
-
'@typescript-eslint/[email protected]':
resolution: {integrity: sha512-ELGuoofuhhoCvNbQjFFiobFcGgcDCEm0ThWdmO4Z0UzLqPXS3KFvnEZ+SHewwOYHjM09tkzOWXNTv9u6Gqtyuw==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
peerDependencies:
typescript: '>=4.8.4 <6.1.0'
- '@typescript-eslint/[email protected]':
- resolution: {integrity: sha512-krRIbvPK1ju1WBKIefiX+bngPs+odIQUtR7kymzPfo1POVw3jlF+nLkmexdSSd4UCbDcQn+wMBATOOmpBbqgKg==}
- engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
- peerDependencies:
- eslint: ^8.57.0 || ^9.0.0 || ^10.0.0
- typescript: '>=4.8.4 <6.0.0'
-
'@typescript-eslint/[email protected]':
resolution: {integrity: sha512-QZfjHNEzPY8+l0+fIXMvuQ2sJlplB4zgDZvA+NmvZsZv3EQwOcc1DuIU1VJUTWZ/RKouBMhDyNaBMx4sWvrzRA==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
@@ -4482,10 +4182,6 @@ packages:
eslint: ^8.57.0 || ^9.0.0 || ^10.0.0
typescript: '>=4.8.4 <6.1.0'
- '@typescript-eslint/[email protected]':
- resolution: {integrity: sha512-zhahknjobV2FiD6Ee9iLbS7OV9zi10rG26odsQdfBO/hjSzUQbkIYgda+iNKK1zNiW2ey+Lf8MU5btN17V3dUw==}
- engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
-
'@typescript-eslint/[email protected]':
resolution: {integrity: sha512-f1WO2Lx8a9t8DARmcWAUPJbu0G20bJlj8L4z72K00TMeJAoyLr/tHhI/pzYBLrR4dXWkcxO1cWYZEOX8DKHTqA==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
@@ -4598,7 +4294,6 @@ packages:
resolution: {integrity: sha512-x7FptB5oDruxNPDNY2+S8tCh0pcq7ymCe1gTHcsp733jYjrJl8V1gMUlVysuCD9Kz46Xz9t1akkv08dPcYDs1w==}
peerDependencies:
'@vitest/browser': 4.1.4
- vitest: 4.1.4
peerDependenciesMeta:
'@vitest/browser':
optional: true
@@ -4610,50 +4305,24 @@ packages:
'@typescript-eslint/eslint-plugin': '*'
eslint: '>=8.57.0'
typescript: '>=5.0.0'
- vitest: '*'
peerDependenciesMeta:
'@typescript-eslint/eslint-plugin':
optional: true
typescript:
optional: true
- vitest:
- optional: true
'@vitest/[email protected]':
resolution: {integrity: sha512-Io0yyORnB6sikFlt8QW5K7slY4OjqNX9jmJQ02QDda8lyM6B5oNgVWoSoKPac8/kgnCUzuHQKrSLtu/uOqqrig==}
- '@vitest/[email protected]':
- resolution: {integrity: sha512-iPBpra+VDuXmBFI3FMKHSFXp3Gx5HfmSCE8X67Dn+bwephCnQCaB7qWK2ldHa+8ncN8hJU8VTMcxjPpyMkUjww==}
-
- '@vitest/[email protected]':
- resolution: {integrity: sha512-R9HTZBhW6yCSGbGQnDnH3QHfJxokKN4KB+Yvk9Q1le7eQNYwiCyKxmLmurSpFy6BzJanSLuEUDrD+j97Q+ZLPg==}
- peerDependencies:
- msw: ^2.4.9
- vite: ^6.0.0 || ^7.0.0 || ^8.0.0
- peerDependenciesMeta:
- msw:
- optional: true
- vite:
- optional: true
-
'@vitest/[email protected]':
resolution: {integrity: sha512-IVNZik8IVRJRTr9fxlitMKeJeXFFFN0JaB9PHPGQ8NKQbGpfjlTx9zO4RefN8gp7eqjNy8nyK3NZmBzOPeIxtA==}
'@vitest/[email protected]':
resolution: {integrity: sha512-ddmDHU0gjEUyEVLxtZa7xamrpIefdEETu3nZjWtHeZX4QxqJ7tRxSteHVXJOcr8jhiLoGAhkK4WJ3WqBpjx42A==}
- '@vitest/[email protected]':
- resolution: {integrity: sha512-xTp7VZ5aXP5ZJrn15UtJUWlx6qXLnGtF6jNxHepdPHpMfz/aVPx+htHtgcAL2mDXJgKhpoo2e9/hVJsIeFbytQ==}
-
- '@vitest/[email protected]':
- resolution: {integrity: sha512-MCjCFgaS8aZz+m5nTcEcgk/xhWv0rEH4Yl53PPlMXOZ1/Ka2VcZU6CJ+MgYCZbcJvzGhQRjVrGQNZqkGPttIKw==}
-
'@vitest/[email protected]':
resolution: {integrity: sha512-vAfasCOe6AIK70iP5UD11Ac4siNUNJ9i/9PZ3NKx07sG6sUxeag1LWdNrMWeKKYBLlzuK+Gn65Yd5nyL6ds+nw==}
- '@vitest/[email protected]':
- resolution: {integrity: sha512-XxNdAsKW7C+FLydqFJLb5KhJtl3PGCMmYwFRfhvIgxJvLSXhhVI1zM8f1qD3Zg7RCjTSzDVyct6sghs9UEgBEQ==}
-
'@vitest/[email protected]':
resolution: {integrity: sha512-fB2V0JFrQSMsCo9HiSq3Ezpdv4iYaXRG1Sx8edX3MwxfyNn83mKiGzOcH+Fkxt4MHxr3y42fQi1oeAInqgX2QA==}
@@ -4821,81 +4490,18 @@ packages:
resolution: {integrity: sha512-BMY/ozS/xxjYqRFL+tKdRpATJYDTTgWSo0+AJvJNg4ig+Hgb0dOsHPXvloHQ5hmlivUqw1Yt2pPIqp4e0v1GUw==}
- resolution: {integrity: sha512-M8wpPgR9UJ8MiRGjppvx9uWJfLV7A/T+/rL8s/y3QG3u0c2/YZgff3d6SuimKRIhcYnWg5fTfDMlz2E6seUW8Q==}
-
- resolution: {integrity: sha512-h0xIMxrt/LHOvJKMri+vdYT92BrK3HFLtDqq9Pr/lVVfE4IyKZKvWf0vJFW10Yr6nX02OR4MkJwI0c1HDa1hog==}
-
resolution: {integrity: sha512-nBxuiuS9Lj5bPkPbWogPUnjxxWpkRniX7e5UBQDWl6Fsf4roq9wwV+cR7ezQ4zXswNvPIlsdj1slcLB7XCsRAw==}
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-nuBEDgQfm1ccRp/8bCQrx1frohyufl4JlbMMZ4P1wpeOfDhF6FQkxZJ1b/e+PLwr6X1Nhw6OLme5usuBWYBvuQ==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-6oXyTOzbKxGH4steLbLNOu71Oj+C8Lg34n6CqRvqfS2O71BxY6ByfMDRhBytzknj9yGUPVJ1qIKhRlAwO1AovA==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-U56GMYxy4ZQCbDZd6JuvvNV/WFildOjsaWD3Tzzvmw/mas3cXzRJPMjP83JqEsgSbyrmaGjBfDtV7KDXV9UzFQ==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-jyH7wtcHiKssDtFPRB+iQdxlDf96m0E39yb0k5uJVhFGleZFoNw1c4aeIcVUPPbXUVJ94wwnMOAqUHyzoEPVMA==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-FE8aCmS5Q6eQYcV3gI35O4J789wlQA+7JrqTTpJqn5emA4U2hvwJmvFRC0HODS+3Ye6WioDklgd6scJ3+PLnEA==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-3QbLKy93F0EAIXLh0ogEVR6rOubA9AoZ+WRYhNbFyuB70j3dRdwH9g+qXhLAO0kiYGlg3TxDV+I4rQTr/YNXkA==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-ds5mXEqTJ6oxRoqjhWDU83OgzAYjwsCV8Lo/N+oRsNDmx/ZDpqalmrtgOMkHwxsG0iI//3BwWAErYRHtgn0dZw==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-4LtOzh58S/5lX4ITKxnAK2USuNEvpdVV9AlgGQb8rJDHaLeHciwG4zlGr0j/SNWlr7x3vO1lDEsuePvtcDNCkw==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-Lde1oNoIdzVzdkNEAWZ1dZ5orIbff80YPdHx20mrHwHrVNNTjNr8E3xz9BdpcGqRQbAEa+fkrCb+fRFTl/6sQw==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-3NQWGjKTASY1xV5m7Hr0iPeXD9+RDobLll3T9d2AO+g3my8xy5peVyjSag4I50mR1bBSN/Ct12lo+R9tJk0NZQ==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-RNJUIQH/J8iA/1NzlE4N7KtyZNHi3w7at7hDjvRNm5rcUXa00z1vRz3glZoULfJ5mpvYhLybmVcwcjGrC1pRrQ==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-AmomSIjP8ZbfGQhumkNvgC33AY7qtMCXnN6bL2u2Js4gVCg8fp735aEiMSBbDR7UQIj90n4wKAFUSEd0QN2Ukg==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-PTcKLUNvBqnY2U6E5bdOQcSM+oVP/PmrDY9NzowJjislEjwP/C4an2303MCVS2Mg9d3AJpIGdUFIQQWbPds0Sw==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-JLBl+KZ0R5qB7mCnud/yyX08jWFw5MsoalJ1pQ4EdFlgj9VdXKGuENGsiCIjegI1W7p91rUlcB/LB5yRJKNTcQ==}
-
- '@webassemblyjs/[email protected]':
- resolution: {integrity: sha512-kPSSXE6De1XOR820C90RIo2ogvZG+c3KiHzqUoO/F34Y2shGzesfqv7o57xrxovZJH/MetF5UjroJ/R/3isoiw==}
-
'@webcontainer/[email protected]':
resolution: {integrity: sha512-6aN99yL695Hi9SuIk1oC88l9o0gmxL1nGWWQ/kNy81HigJ0FoaoTXpytCj6ItzgyCEwA9kF1wixsTuv5cjsgng==}
'@xstate/[email protected]':
resolution: {integrity: sha512-b5o1I6aLNeYlU/3CPlj/Z91ybk1gUsKT+5NAJI+2W4UjvS5KLG28K9v5UvNoFVjHV8PajVZ00RH3vnjyQO7ZAw==}
- resolution: {integrity: sha512-DX8nKgqcGwsc0eJSqYt5lwP4DH5FlHnmuWWBRy7X0NcaGR0ZtuyeESgMwTYVEtxmsNGY+qit4QYT/MIYTOTPeA==}
-
- resolution: {integrity: sha512-NuHqBY1PB/D8xU6s/thBgOAiAP7HOYDQ32+BFZILJ8ivkUkAHQnWfn6WhL79Owj1qmUnoN/YPhktdIoucipkAQ==}
-
resolution: {integrity: sha512-YLbp5lYUq0uOywWZx9EuTdm0TcflKZi7hOzz366A/LFl3qoAXSYIjznJQmr/VeHg8NcLxZYoN8dLi7PqCpxKEA==}
- resolution: {integrity: sha512-wKmbr/DDiIXzEOiWrTTUcDm24kQ2vGfZQvM2fwg2vXqR5uW6aapr7ObPtj1th32b9u90/Pf4AItvdTh42fBmVQ==}
- engines: {node: '>=10.13.0'}
- peerDependencies:
- acorn: ^8.14.0
-
resolution: {integrity: sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==}
peerDependencies:
@@ -4927,25 +4533,9 @@ packages:
react: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0
react-dom: ^16.8.0 || ^17.0.0 || ^18.0.0 || ^19.0.0
- resolution: {integrity: sha512-Wx0Kx52hxE7C18hkMEggYlEifqWZtYaRgouJor+WMdPnQyEK13vgEWyVNup7SoeeoLMsr4kf5h6dOW11I15MUA==}
- peerDependencies:
- ajv: ^8.0.0
- peerDependenciesMeta:
- ajv:
- optional: true
-
- resolution: {integrity: sha512-YCS/JNFAUyr5vAuhk1DWm1CBxRHW9LbJ2ozWeemrIqpbsqKjHVxYPyi5GC0rjZIT5JxJ3virVTS8wk4i/Z+krw==}
- peerDependencies:
- ajv: ^8.8.2
-
resolution: {integrity: sha512-IWrosm/yrn43eiKqkfkHis7QioDleaXQHdDVPKg0FSwwd/DuvyX79TZnFOnYpB7dcsFAMmtFztZuXPDvSePkFw==}
- resolution: {integrity: sha512-PlXPeEWMXMZ7sPYOHqmDyCJzcfNrUr3fGNKtezX14ykXOEIvyK81d+qydx89KY5O71FKMPaQ2vBfBFI5NHR63A==}
-
resolution: {integrity: sha512-ILlv4k/3f6vfQ4OoP2AGvirOktlQ98ZEL1k9FaQjxa3L1abBgbuTDAdPOpvbGncC0BTVQrl+OM8xZGK6tWXt7g==}
engines: {node: '>=6'}
@@ -5119,10 +4709,6 @@ packages:
resolution: {integrity: sha512-4zNhdJD/iOjSH0A05ea+Ke6MU5mmpQcbQsSOkgdaUMJ9zTlDTD/GYlwohmIE2u0gaxHYiVHEn1Fw9mZ/ktJWgw==}
engines: {node: '>=18'}
- resolution: {integrity: sha512-NUPRluOfOiTKBKvWPtSD4PhFvWCqOi0BGStNWs57X9js7XGTprSmFoz5F0tWhR4WPjNeR9jXqdC7/UpSJTnlRg==}
- engines: {node: '>=18'}
-
resolution: {integrity: sha512-diHzdDKxcU+bAsUboHLPEDQiw0qEe0qd7SYUn3HgcFlWgbDcfLGswOHYeGrHKzG9z6UYf01d9VFMfZxPM1xZSg==}
engines: {node: '>=10'}
@@ -5165,10 +4751,6 @@ packages:
resolution: {integrity: sha512-opLQzEVriiH1uUQ4Kctsd49bRoFDXGGSC4GUqj7pGyxM3RehRhvTlZJc1FL/Flew2p5uwxa1tUDWKzI4wNM8pg==}
- resolution: {integrity: sha512-Qgzu8kfBvo+cA4962jnP1KkS6Dop5NS6g7R5LFYJr4b8Ub94PPQXUksCw9PvXoeXPRRddRNC5C1JQUR2SMGtnA==}
- engines: {node: '>= 14.16.0'}
-
resolution: {integrity: sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==}
@@ -5188,10 +4770,6 @@ packages:
'@chromatic-com/playwright':
optional: true
- resolution: {integrity: sha512-rNjApaLzuwaOTjCiT8lSDdGN1APCiqkChLMJxJPWLunPAt5fy8xgU9/jNOchV84wfIxrA0lRQB7oCT8jrn/wrQ==}
- engines: {node: '>=6.0'}
-
resolution: {integrity: sha512-77PSwercCZU2Fc4sX94eF8k8Pxte6JAwL4/ICZLFjJLqegs7kCuAsqqj/70NQF6TvDpgFjkubQB2FW2ZZddvQg==}
engines: {node: '>=8'}
@@ -5257,9 +4835,6 @@ packages:
resolution: {integrity: sha512-H+y0Jo/T1RZ9qPP4Eh1pkcQcLRglraJaSLoyOtHxu6AapkjWVCy2Sit1QQ4x3Dng8qDlSsZEet7g5Pq06MvTgw==}
engines: {node: '>=20'}
- resolution: {integrity: sha512-GpVkmM8vF2vQUkj2LvZmD35JxeJOLCwJ9cUkugyk2nuhbv3+mJvpLYYt+0+USMxE+oj+ey/lJEnhZw75x/OMcQ==}
-
resolution: {integrity: sha512-QrWXB+ZQSVPmIWIhtEO9H+gwHaMGYiF5ChvoJ+K9ZGHG/sVsa6yiesAD1GC/x46sET00Xlwo1u49RVVVzvcSkw==}
engines: {node: '>= 10'}
@@ -5517,9 +5092,6 @@ packages:
resolution: {integrity: sha512-P4rFMVq9ESWqmOgK+dlXvOtLwYg0i7u0HBGJER0LZDJT2VHIPAMZ/riPxqJceWMStH5+E61QxFra9kIS3AqdMg==}
- resolution: {integrity: sha512-Ukq0owbQXxa/U3EGtsdVBkR1w7KOQ5gIBqdH2hkvknzZPYvBxb/aa6E8L7tmjFtkwZBu3UXBbjIgPo/Ez4xaNg==}
-
resolution: {integrity: sha512-YbwwqR/uYpeoP4pu043q+LTDLFBLApUP6VxRihdfNTqu4ubqMlGDLd6ErXhEgsyvY0K6nCs7nggYumAN+9uEuQ==}
@@ -5978,10 +5550,6 @@ packages:
'@vue/compiler-sfc': ^3.3.0
eslint: '>=9.0.0'
- resolution: {integrity: sha512-2NxwbF/hZ0KpepYN0cNbo+FN6XoK7GaHlQhgx/hIZl6Va0bF45RQOOwhLIy8lQDbuCiadSLCBnH2CFYquit5bw==}
- engines: {node: '>=8.0.0'}
-
resolution: {integrity: sha512-sNXOfKCn74rt8RICKMvJS7XKV/Xk9kA7DyJr8mJik3S7Cwgy3qlkkmyS2uQB3jiJg6VNdZd/pDBJu0nvG2NlTg==}
engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0}
@@ -6043,10 +5611,6 @@ packages:
resolution: {integrity: sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==}
engines: {node: '>=4.0'}
- resolution: {integrity: sha512-39nnKffWz8xN1BU/2c79n9nB9HDzo0niYUqx6xyqUnyoAnQyyWpOTdZEeiCch8BBu515t4wp9ZmgVfVhn9EBpw==}
- engines: {node: '>=4.0'}
-
resolution: {integrity: sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==}
engines: {node: '>=4.0'}
@@ -6079,18 +5643,10 @@ packages:
resolution: {integrity: sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==}
engines: {node: '>=0.10.0'}
- resolution: {integrity: sha512-mQw+2fkQbALzQ7V0MY0IqdnXNOeTtP4r0lN9z7AAawCXgqea7bDii20AYrIBrFd/Hx0M2Ocz6S111CaFkUcb0Q==}
- engines: {node: '>=0.8.x'}
-
resolution: {integrity: sha512-XYfuKMvj4O35f/pOXLObndIRvyQ+/+6AhODh+OKWj9S9498pHHn/IMszH+gt0fBCRWMNfk1ZSp5x3AifmnI2vg==}
engines: {node: '>=6'}
- resolution: {integrity: sha512-knvyeauYhqjOYvQ66MznSMs83wmHrCycNEN6Ao+2AeYEfxUIkuiVxdEa1qlGEPK+We3n0THiDciYSsCcgW/DoA==}
- engines: {node: '>=12.0.0'}
-
resolution: {integrity: sha512-LmDxfWXwcTArk8fUEnOfSZpHOJ6zOMUJKOtFLFqJLoKJetuQG874Uc7/Kki7zFLzYybmZhp1M7+98pfMqeX8yA==}
@@ -6125,9 +5681,6 @@ packages:
resolution: {integrity: sha512-O3fwIVIH5gKB38QNbdg+3760ZmGz0SZMgvwJbA1b2TGXceKE6A2cOlfogh1iw8lr049zPyd7YADHy+B7U4W9bQ==}
- resolution: {integrity: sha512-iPeeDKJSWf4IEOasVVrknXpaBV0IApz/gp7S2bb7Z4Lljbl2MGJRqInZiUrQwV16cpzw/D3S5j5Julj/gT52AA==}
-
resolution: {integrity: sha512-HlUwET7a5gqjURj70D5jl7aC3Zmy4weA1SHUfM0JFI0Ptq987NH2TwbBFLoERhfwk+E+eaq4EK3jXoT+R3yp3w==}
@@ -6244,9 +5797,6 @@ packages:
resolution: {integrity: sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==}
engines: {node: '>=10.13.0'}
- resolution: {integrity: sha512-lkX1HJXwyMcprw/5YUZc2s7DrpAiHB21/V+E1rHUrVNokkvB6bqMzT0VfV6/86ZNabt1k14YOIaT7nDvOX3Iiw==}
-
resolution: {integrity: sha512-Wjlyrolmm8uDpm/ogGyXZXb1Z+Ca2B8NbJwqBVg0axK9GbBeoS7yGV6vjXnYdGm6X53iehEuxxbyiKp8QmN4Vw==}
engines: {node: 18 || 20 || >=22}
@@ -6414,9 +5964,6 @@ packages:
resolution: {integrity: sha512-XREFCPo6ksxVzP4E0ekD5aMdf8WMwmdNaz6vuvxgI40UaEiu6q3p8X52aU6GdyvLY3XXX/8R7JOTXStz/nBbRw==}
- resolution: {integrity: sha512-t7xcm2siw+hlUM68I+UEOK+z84RzmN59as9DZ7P1l0994DKUWV7UXBMQZVxaoMSRQ+PBZbHCOoBt7a2wxOMt+A==}
-
resolution: {integrity: sha512-TR3KfrTZTYLPB6jUjfx6MF9WcWrHL9su5TObK4ZkYgBdWKPOFoSoQIdEuTuR82pmtxH2spWG9h6etwfr1pLBqQ==}
engines: {node: '>=6'}
@@ -6526,9 +6073,6 @@ packages:
resolution: {integrity: sha512-RHxMLp9lnKHGHRng9QFhRCMbYAcVpn69smSGcq3f36xjgVVWThj4qqLbTLlq7Ssj8B+fIQ1EuCEGI2lKsyQeIw==}
- resolution: {integrity: sha512-PIeMbHqMt4DnUP3MA/Flc0HElYjMXArsw1qwJZcm9sqR8mq3l8NYizFMty0pWwE/tzIGH3EKK5+jes5mAr85yw==}
-
resolution: {integrity: sha512-O8dpsF+r0WV/8MNRKfnmrtCWhuKjxrq2w+jpzBL5UZKTi2LeVWnWOmWRxFlesJONmc+wLAGvKQZEOanko0LFTg==}
engines: {node: '>=8'}
@@ -6541,10 +6085,6 @@ packages:
resolution: {integrity: sha512-HGYWWS/ehqTV3xN10i23tkPkpH46MLCIMFNCaaKNavAXTF1RkqxawEPtnjnGZ6XKSInBKkiOA5BKS+aZiY3AvA==}
engines: {node: '>=8'}
- resolution: {integrity: sha512-7vuh85V5cdDofPyxn58nrPjBktZo0u9x1g8WtjQol+jZDaE+fhN+cIvTj11GndBnMnyfrUOG1sZQxCdjKh+DKg==}
- engines: {node: '>= 10.13.0'}
-
resolution: {integrity: sha512-ekilCSN1jwRvIbgeg/57YFh8qQDNbwDb9xT/qu2DAHbFFZUicIl4ygVaAvzveMhMVr3LnpSKTNnwt8PoOfmKhQ==}
hasBin: true
@@ -6606,15 +6146,9 @@ packages:
resolution: {integrity: sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==}
- resolution: {integrity: sha512-xyFwyhro/JEof6Ghe2iz2NcXoj2sloNsWr/XsERDK/oiPCfaNhl5ONfp+jQdAZRQQ0IJWNzH9zIZF7li91kh2w==}
-
resolution: {integrity: sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==}
- resolution: {integrity: sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug==}
-
resolution: {integrity: sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==}
@@ -6691,11 +6225,6 @@ packages:
resolution: {integrity: sha512-waSeXyt1HxTFpU8KNRA3IQcvjvpw0lZNaSbGopfOi4bLV0FF9zYpqiScTnEUMP/b1W7qWmD4Z2Detw43XICxqQ==}
- resolution: {integrity: sha512-DeXj9X5xDCjgKLU/7RR+/HQEVzuuEUiwldwOGsHK/sfAfELGWEyTcf0x+uOvCvK3O2zPmZePXWL85vtia6GyZw==}
- engines: {node: '>=16'}
- hasBin: true
-
resolution: {integrity: sha512-YK7/ClTt4kAK0vo6w3X+Pnm0D2cf2vPHbhOXdoNti1Ga0al1P4TBZhwjATvjNwLEBCnKvjJc2jQgHXH0NEwlAg==}
engines: {node: '>= 12.0.0'}
@@ -6773,10 +6302,6 @@ packages:
resolution: {integrity: sha512-MHp03UImeVhB7XZtjd0E4n6+3xr5Dq/9xI/5FptGk5FrbDR3zagPa2DS6U8ks/3HjbKWG9Q1M2ufOzxV2qLYSQ==}
- resolution: {integrity: sha512-IWqP2SCPhyVFTBtRcgMHdzlf9ul25NwaFx4wCEH/KjAXuuHY4yNjvPXsBokp8jCB936PyWRaPKUNh8NvylLp2Q==}
- engines: {node: '>=6.11.5'}
-
resolution: {integrity: sha512-arhlxbFRmoQHl33a0Zkle/YWlmNwoyt6QNZEIJcqNbdrsix5Lvc4HyyI3EnwxTYlZYc32EbYrQ8SzEZ7dqgg9A==}
engines: {node: '>=14'}
@@ -6850,11 +6375,6 @@ packages:
resolution: {integrity: sha512-wiYz4+JrLyb/DqW2hkFJxP7Vd7JuTDm77fvbM8VfEQdmSMqcImWeeRbHwZjBjIFki/VaMK2BhFi7oUUZeM5bqw==}
- resolution: {integrity: sha512-uIj4+faQ+MgHgwUW1l2PsPglZLOLOT1uErt06dAPtx2kjteLAkbsd/0FiYg/MGS+i7ZKLb7w2WClxHkzOOuryQ==}
- engines: {node: '>= 18'}
- hasBin: true
-
resolution: {integrity: sha512-TI3V8YYWvkVf3KJe1dRkpnjs68JUPyEa5vjKrp1XEEJUAOaQc+Qj+L1qWbPd0SJuAdQkFU0h73sXXqwDYxsiDA==}
engines: {node: '>= 20'}
@@ -6934,9 +6454,6 @@ packages:
resolution: {integrity: sha512-9Yubnt3e8A0OKwxYSXyhLymGW4sCufcLG6VdiDdUGVkPhpqLxlvP5vl1983gQjJl3tqbrM731mjaZaP68AgosQ==}
- resolution: {integrity: sha512-abv/qOcuPfk3URPfDzmZU1LKmuw8kT+0nIHvKrKgFrwifol/doWcdA4ZqsWQ8ENrFKkd67Mfpo/LovbIUsbt3w==}
-
resolution: {integrity: sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg==}
engines: {node: '>= 8'}
@@ -7062,14 +6579,6 @@ packages:
resolution: {integrity: sha512-PXwfBhYu0hBCPw8Dn0E+WDYb7af3dSLVWKi3HGv84IdF4TyFoC0ysxFd0Goxw7nSv4T/PzEJQxsYsEiFCKo2BA==}
engines: {node: '>=8.6'}
- resolution: {integrity: sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg==}
- engines: {node: '>= 0.6'}
-
- resolution: {integrity: sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw==}
- engines: {node: '>= 0.6'}
-
resolution: {integrity: sha512-jSCU7/VB1loIWBZe14aEYHU/+1UMEHoaO7qxCOVJOw9GgH72VAWppxNcjU+x9a2k3GSIBXNKxXQFqRvvZ7vr3A==}
engines: {node: '>=10.0.0'}
@@ -7126,9 +6635,6 @@ packages:
resolution: {integrity: sha512-j5sNQm3VCpQQ7nTqGeOZtoJtV3uKERgCBm9QRhmGRiXiqkf7iRFOkfxdJRZWLkqYY8PNf4cDQF/WfXUYLENrRA==}
- resolution: {integrity: sha512-jz4x+TJNFHwHtwuV9vA9rMujcZRb0CEilTEwG2rRSpe/A7Jdkuj8xPKttCgOh+v/lkHy7HsZ64oj+q3xoAFl9A==}
-
resolution: {integrity: sha512-i/+ZKXMDf6aqYtBhuOcej71YSlbjT3wCO/4H1j8rPvxDJEifdwgg5MaFyu6iYAT8GBZJg2z0dkgK4YMzvURALQ==}
@@ -7705,10 +7211,6 @@ packages:
resolution: {integrity: sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA==}
engines: {node: '>= 6'}
- resolution: {integrity: sha512-GDhwkLfywWL2s6vEjyhri+eXmfH6j1L7JE27WhqLeYzoh/A3DBaYGEj2H/HFZCn/kMfim73FXxEJTw06WtxQwg==}
- engines: {node: '>= 14.18.0'}
-
resolution: {integrity: sha512-YTUo+Flmw4ZXiWfQKGcwwc11KnoRAYgzAE2E7mXKCjSviTKShtxBsN6YUUBB2gtaBzKzeKunxhUwNHQuRryhWA==}
engines: {node: '>= 4'}
@@ -7808,10 +7310,6 @@ packages:
resolution: {integrity: sha512-PV0dzCYDNfRi1jCDbJzpW7jNNDRuCOG/jI5ctQcGKt/clZD+YcPS3yIlWuTJMmESC8aevCFmWJy5wjAFgNqN6w==}
engines: {node: '>=0.10'}
- resolution: {integrity: sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw==}
- engines: {node: '>=0.10.0'}
-
resolution: {integrity: sha512-K/BG6eIky/SBpzfHZv/dd+9JBFiS4SWV7FIujVyJRux6e45+73RaUHXLmIR1f7WOMaQ0U1km6qwklRQxpJJY0w==}
@@ -7841,11 +7339,6 @@ packages:
resolution: {integrity: sha512-NS3levdsRIUOmiJ8FZWCP7LG3QpJyrs/TE0Zpf1yvZu8cAJJ6QMW92H1c7kWpdIHo8RvmLxN/o2JXTKHp74lUA==}
- resolution: {integrity: sha512-2oMpl67a3zCH9H79LeMcbDhXW/UmWG/y2zuqnF2jQq5uq9TbM9TVyXvA4+t+ne2IIkBdrLpAaRQAvo7YI/Yyeg==}
- engines: {node: '>=18.0.0', npm: '>=8.0.0'}
- hasBin: true
-
resolution: {integrity: sha512-ZUz/69+SYpFN/g/lUlo2FXcIjRkSu3nDarreVdGGndHEBJ6cXPdKguS8JGxwj5HA5xIbVKSmLgr5b3AWxtRfvQ==}
@@ -7865,11 +7358,6 @@ packages:
resolution: {integrity: sha512-gH8eh2nZudPQO6TytOvbxnuhYBOvDBBLW52tz5q6X58lJcd/tkmqFR+5Z9adS8aJtURSXWThWy/xJtJwixErvg==}
- resolution: {integrity: sha512-+4N/u9dZ4PrgzGgPlKnaaRQx64RO0JBKs9sDhQ2pLgN6JQZ25uPQZKQYaBJU48Kd5BxgXoJ4e09Dq7nMcOUW3A==}
- engines: {node: '>=14.0.0'}
- hasBin: true
-
resolution: {integrity: sha512-ZvHN3ygzZ8FuxjSNB+mKBiF/NIoqHzlBGbD0MJiT+MvSsFOvotnWOhdTjxKzhHRT2wPC1QbhLzx2q/Y83VhfYQ==}
engines: {node: '>=16'}
@@ -7881,10 +7369,6 @@ packages:
resolution: {integrity: sha512-eNv+WrVbKu1f3vbYJT/xtiF5syA5HPIMtf9IgY/nKg0sWqzAUEvqY/xm7OcZc/qafLx/iO9FgOmeSAp4v5ti/Q==}
- resolution: {integrity: sha512-eflK8wEtyOE6+hsaRVPxvUKYCpRgzLqDTb8krvAsRIwOGlHoSgYLgBXoubGgLd2fT41/OUYdb48v4k4WWHQurA==}
- engines: {node: '>= 10.13.0'}
-
resolution: {integrity: sha512-9BakfsO2aUQN2K9Fdbj87RJIEZ82Q9IGim7FqM5OsebfoFC6ZHXgDq/KvniuLTPdeM8wY2o6Dj3WQ7KeQCj3cA==}
engines: {node: '>=0.10.0'}
@@ -7931,9 +7415,6 @@ packages:
resolution: {integrity: sha512-eAVKTMedR5ckPo4xne/PjYQYrU3qx78gtJZ+sHlXEg5IHhhoQhMfZVzetTYuaJS0L2Ef3AcCRzCHV8T0WI6nIQ==}
engines: {node: '>=20'}
- resolution: {integrity: sha512-ybx0WO1/8bSBLEWXZvEd7gMW3Sn3JFlW3TvX1nREbDLRNQNaeNN8WK0meBwPdAaOI7TtRRRJn/Es1zhrrCHu7g==}
-
resolution: {integrity: sha512-cSFtAPtRhljv69IK0hTVZQ+OfE9nePi/rtJmw5UjHeVyVroEqJXP1sFztKUy1qU+xvz3u/sfYJLa947b7nAN2Q==}
@@ -8006,9 +7487,6 @@ packages:
engines: {node: '>=20.16.0'}
hasBin: true
- resolution: {integrity: sha512-1XMJE5fQo1jGH6Y/7ebnwPOBEkIEnT4QF32d5R1+VXdXveM0IBMJt8zfaxX1P3QhVwrYe+576+jkANtSS2mBbw==}
-
resolution: {integrity: sha512-oeVtt7eWQS+Na6F//S4kJ2K2VbRlS9D43mAlMyVpVWovy9o+jfgH8O9agzANzaiLjclA0oYzUXEM4PurhSUChw==}
@@ -8171,27 +7649,6 @@ packages:
resolution: {integrity: sha512-ChjMH33/KetonMTAtpYdgUFr0tbz69Fp2v7zWxQfYZX4g5ZN2nOBXm1R2xyA+lMIKrLKIoKAwFj93jE/avX9cQ==}
engines: {node: '>=18'}
- resolution: {integrity: sha512-Bn5vxm48flOIfkdl5CaD2+1CiUVbonWQ3KQPyP7/EuIl9Gbzq/gQFOzaMFUEgVjB1396tcK0SG8XcNJ/2kDH8g==}
- engines: {node: '>= 10.13.0'}
- peerDependencies:
- '@swc/core': '*'
- esbuild: '*'
- uglify-js: '*'
- webpack: ^5.1.0
- peerDependenciesMeta:
- '@swc/core':
- optional: true
- esbuild:
- optional: true
- uglify-js:
- optional: true
-
- resolution: {integrity: sha512-vzCjQO/rgUuK9sf8VJZvjqiqiHFaZLnOiimmUuOKODxWL8mm/xua7viT7aqX7dgPY60otQjUotzFMmCB4VdmqQ==}
- engines: {node: '>=10'}
- hasBin: true
-
resolution: {integrity: sha512-RNxQH/qI8/t3thXJDwcstUO4zeqo64+Uy/+sNVRBx4Xn2OX+OZ9oP+iJnNFqplFra2ZUVeKCSa2oVWi3T4uVmA==}
engines: {node: '>=0.8'}
@@ -8601,52 +8058,24 @@ packages:
vite:
optional: true
- resolution: {integrity: sha512-4boWHY+STwAxGl1+uwakNNoQky5EjPLC8HuponXNoAscYyT1h/F7RUvTkl4IyF/MiWr3V8Q626je3Iel3eArqA==}
- peerDependencies:
- vitest: ^3.0.0 || ^4.0.0
-
- resolution: {integrity: sha512-tFuJqTxKb8AvfyqMfnavXdzfy3h3sWZRWwfluGbkeR7n0HUev+FmNgZ8SDrRBTVrVCjgH5cA21qGbCffMNtWvg==}
- engines: {node: ^20.0.0 || ^22.0.0 || >=24.0.0}
- hasBin: true
+ resolution: {integrity: sha512-oY3KM6305kwJMa6nHo92vVtkOsih7mjEf12dLKuphaF+9ywWPEc+qanIBd394SZ6m5LadVEaG6dicvvizOzmjA==}
peerDependencies:
- '@edge-runtime/vm': '*'
- '@opentelemetry/api': ^1.9.0
- '@types/node': ^20.0.0 || ^22.0.0 || >=24.0.0
- '@vitest/browser-playwright': 4.1.4
- '@vitest/browser-preview': 4.1.4
- '@vitest/browser-webdriverio': 4.1.4
- '@vitest/coverage-istanbul': 4.1.4
- '@vitest/coverage-v8': 4.1.4
- '@vitest/ui': 4.1.4
- happy-dom: '*'
- jsdom: '*'
- vite: ^6.0.0 || ^7.0.0 || ^8.0.0
+ '@types/react': ^18.0.0 || ^19.0.0
+ '@types/react-dom': ^18.0.0 || ^19.0.0
+ react: ^18.0.0 || ^19.0.0
+ react-dom: ^18.0.0 || ^19.0.0
peerDependenciesMeta:
- '@edge-runtime/vm':
- optional: true
- '@opentelemetry/api':
- optional: true
- '@types/node':
- optional: true
- '@vitest/browser-playwright':
- optional: true
- '@vitest/browser-preview':
- optional: true
- '@vitest/browser-webdriverio':
- optional: true
- '@vitest/coverage-istanbul':
- optional: true
- '@vitest/coverage-v8':
- optional: true
- '@vitest/ui':
- optional: true
- happy-dom:
+ '@types/react':
optional: true
- jsdom:
+ '@types/react-dom':
optional: true
+ resolution: {integrity: sha512-4boWHY+STwAxGl1+uwakNNoQky5EjPLC8HuponXNoAscYyT1h/F7RUvTkl4IyF/MiWr3V8Q626je3Iel3eArqA==}
+ peerDependencies:
+ vitest: ^3.0.0 || ^4.0.0
+
resolution: {integrity: sha512-Dhxzh5HZuiHQhbvTW9AMetFfBHDMYpo23Uo9btPXgdYP+3T5S+p+jgNy7spra+veYhBP2dCSgxR/i2Y02h5/6w==}
engines: {node: '>=0.10.0'}
@@ -8681,10 +8110,6 @@ packages:
resolution: {integrity: sha512-3hu+tD8YzSLGuFYtPRb48vdhKMi0KQV5sn+uWr8+7dMEq/2G/dtLrdDinkLjqq5TIbIBjYJ4Ax/n3YiaW7QM8A==}
engines: {node: 20 || >=22}
- resolution: {integrity: sha512-Zn5uXdcFNIA1+1Ei5McRd+iRzfhENPCe7LeABkJtNulSxjma+l7ltNx55BWZkRlwRnpOgHqxnjyaDgJnNXnqzg==}
- engines: {node: '>=10.13.0'}
-
resolution: {integrity: sha512-bKr1DkiNa2krS7qxNtdrtHAmzuYGFQLiQ13TsorsdT6ULTkPLKuu5+GsFpDlg6JFjUTwX2DyhMPG2be8uPrqsQ==}
@@ -8698,16 +8123,6 @@ packages:
resolution: {integrity: sha512-66/V2i5hQanC51vBQKPH4aI8NMAcBW59FVBs+rC7eGHupMyfn34q7rZIE+ETlJ+XTevqfUhVVBgSUNSW2flEUQ==}
- resolution: {integrity: sha512-jTywjboN9aHxFlToqb0K0Zs9SbBoW4zRUlGzI2tYNxVYcEi/IPpn+Xi4ye5jTLvX2YeLuic/IvxNot+Q1jMoOw==}
- engines: {node: '>=10.13.0'}
- hasBin: true
- peerDependencies:
- webpack-cli: '*'
- peerDependenciesMeta:
- webpack-cli:
- optional: true
-
resolution: {integrity: sha512-6qN4hJdMwfYBtE3YBTTHhoeuUrDBPZmbQaxWAqSALV/MeEnR5z1xd8UKud2RAkFoPkmB+hli1TZSnyi84xz1vQ==}
engines: {node: '>=18'}
@@ -8726,11 +8141,6 @@ packages:
engines: {node: '>= 8'}
hasBin: true
- resolution: {integrity: sha512-hUrmaWBdVDcxvYqnyh09zunKzROWjbZTiNy8dBEjkS7ehEDQibXJ7XvlmtbwuTclUiIyN+CyXQD4Vmko8fNm8w==}
- engines: {node: '>=8'}
- hasBin: true
-
resolution: {integrity: sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==}
engines: {node: '>=0.10.0'}
@@ -8802,10 +8212,6 @@ packages:
resolution: {integrity: sha512-k1isifdbpNSFEHFJ1ZY4YDewv0IH9FR61lDetaRMD3j2ae3bIXGV+7c+LHCqtQGofSd8PIyV4X6+dHMAnSr60A==}
engines: {node: '>=12'}
- resolution: {integrity: sha512-vv/9h42eCMC81ZHDFswuu/MKzkl/vyq1BhaNGfHyOonwlG4CJbQF4oiBBJPvfdeCt/PlVDWh7Nov9D34YY09uQ==}
- engines: {node: '>=16.0.0', npm: '>=8.0.0'}
-
resolution: {integrity: sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==}
engines: {node: '>=10'}
@@ -8935,14 +8341,14 @@ snapshots:
'@amplitude/analytics-core': 2.45.0
tslib: 2.8.1
+ '@amplitude/[email protected](@amplitude/[email protected])':
dependencies:
'@amplitude/analytics-client-common': 2.4.43
'@amplitude/analytics-core': 2.45.0
'@amplitude/analytics-types': 2.11.1
'@amplitude/rrweb-plugin-console-record': 2.0.0-alpha.36(@amplitude/[email protected])
'@amplitude/rrweb-record': 2.0.0-alpha.36
- '@amplitude/session-replay-browser': 1.36.0(@amplitude/[email protected])([email protected])
+ '@amplitude/session-replay-browser': 1.36.0(@amplitude/[email protected])
idb-keyval: 6.2.2
tslib: 2.8.1
transitivePeerDependencies:
@@ -8996,7 +8402,7 @@ snapshots:
base64-arraybuffer: 1.0.2
mitt: 3.0.1
+ '@amplitude/[email protected](@amplitude/[email protected])':
dependencies:
'@amplitude/analytics-client-common': 2.4.43
'@amplitude/analytics-core': 2.45.0
@@ -9008,7 +8414,7 @@ snapshots:
'@amplitude/rrweb-types': 2.0.0-alpha.36
'@amplitude/rrweb-utils': 2.0.0-alpha.36
'@amplitude/targeting': 0.2.0
- '@rollup/plugin-replace': 6.0.3([email protected])
+ '@rollup/plugin-replace': 6.0.3
idb: 8.0.0
tslib: 2.8.1
transitivePeerDependencies:
@@ -9024,61 +8430,7 @@ snapshots:
idb: 8.0.0
tslib: 2.8.1
- dependencies:
- '@antfu/install-pkg': 1.1.0
- '@clack/prompts': 1.2.0
- '@eslint-community/eslint-plugin-eslint-comments': 4.7.1([email protected]([email protected]))
- '@eslint/markdown': 8.0.1
- '@stylistic/eslint-plugin': 5.10.0([email protected]([email protected]))
- '@typescript-eslint/parser': 8.58.2([email protected]([email protected]))([email protected])
- ansis: 4.2.0
- cac: 7.0.0
- eslint: 10.2.0([email protected])
- eslint-config-flat-gitignore: 2.3.0([email protected]([email protected]))
- eslint-flat-config-utils: 3.1.0
- eslint-merge-processors: 2.0.0([email protected]([email protected]))
- eslint-plugin-antfu: 3.2.2([email protected]([email protected]))
- eslint-plugin-import-lite: 0.6.0([email protected]([email protected]))
- eslint-plugin-jsdoc: 62.9.0([email protected]([email protected]))
- eslint-plugin-jsonc: 3.1.2([email protected]([email protected]))
- eslint-plugin-no-only-tests: 3.3.0
- eslint-plugin-perfectionist: 5.8.0([email protected]([email protected]))([email protected])
- eslint-plugin-pnpm: 1.6.0([email protected]([email protected]))
- eslint-plugin-regexp: 3.1.0([email protected]([email protected]))
- eslint-plugin-toml: 1.3.1([email protected]([email protected]))
- eslint-plugin-unicorn: 64.0.0([email protected]([email protected]))
- eslint-plugin-yml: 3.3.1([email protected]([email protected]))
- eslint-processor-vue-blocks: 2.0.0(@vue/[email protected])([email protected]([email protected]))
- globals: 17.5.0
- local-pkg: 1.1.2
- parse-gitignore: 2.0.0
- toml-eslint-parser: 1.0.3
- vue-eslint-parser: 10.4.0([email protected]([email protected]))
- yaml-eslint-parser: 2.0.0
- optionalDependencies:
- '@eslint-react/eslint-plugin': 3.0.0([email protected]([email protected]))([email protected])
- '@next/eslint-plugin-next': 16.2.3
- eslint-plugin-react-refresh: 0.5.2([email protected]([email protected]))
- transitivePeerDependencies:
- - '@eslint/json'
- - '@typescript-eslint/rule-tester'
- - '@typescript-eslint/typescript-estree'
- - '@typescript-eslint/utils'
- - '@vue/compiler-sfc'
- - oxlint
- - supports-color
- - typescript
- - vitest
-
dependencies:
'@antfu/install-pkg': 1.1.0
'@clack/prompts': 1.2.0
@@ -9088,7 +8440,7 @@ snapshots:
'@stylistic/eslint-plugin': 5.10.0([email protected]([email protected]))
'@typescript-eslint/parser': 8.58.2([email protected]([email protected]))([email protected])
ansis: 4.2.0
cac: 7.0.0
eslint: 10.2.0([email protected])
@@ -9096,7 +8448,7 @@ snapshots:
eslint-flat-config-utils: 3.1.0
eslint-merge-processors: 2.0.0([email protected]([email protected]))
eslint-plugin-antfu: 3.2.2([email protected]([email protected]))
eslint-plugin-import-lite: 0.6.0([email protected]([email protected]))
eslint-plugin-jsdoc: 62.9.0([email protected]([email protected]))
eslint-plugin-jsonc: 3.1.2([email protected]([email protected]))
@@ -9110,7 +8462,7 @@ snapshots:
eslint-plugin-yml: 3.3.1([email protected]([email protected]))
- eslint-processor-vue-blocks: 2.0.0(@vue/[email protected])([email protected]([email protected]))
+ eslint-processor-vue-blocks: 2.0.0([email protected]([email protected]))
globals: 17.5.0
local-pkg: 1.1.2
parse-gitignore: 2.0.0
@@ -9122,15 +8474,41 @@ snapshots:
'@next/eslint-plugin-next': 16.2.3
eslint-plugin-react-refresh: 0.5.2([email protected]([email protected]))
transitivePeerDependencies:
+ - '@arethetypeswrong/core'
+ - '@edge-runtime/vm'
- '@eslint/json'
+ - '@opentelemetry/api'
+ - '@tsdown/css'
+ - '@tsdown/exe'
+ - '@types/node'
- '@typescript-eslint/rule-tester'
- '@typescript-eslint/typescript-estree'
- '@typescript-eslint/utils'
+ - '@vitejs/devtools'
+ - '@vitest/coverage-istanbul'
+ - '@vitest/coverage-v8'
+ - '@vitest/ui'
- '@vue/compiler-sfc'
+ - bufferutil
+ - esbuild
+ - happy-dom
+ - jiti
+ - jsdom
+ - less
- oxlint
+ - publint
+ - sass
+ - sass-embedded
+ - stylus
+ - sugarss
- supports-color
+ - terser
+ - tsx
- typescript
- - vitest
+ - unplugin-unused
+ - utf-8-validate
+ - vite
+ - yaml
dependencies:
@@ -9241,14 +8619,12 @@ snapshots:
'@babel/helper-string-parser': 7.27.1
'@babel/helper-validator-identifier': 7.28.5
dependencies:
'@babel/runtime': 7.29.2
- '@date-fns/tz': 1.4.1
'@floating-ui/react-dom': 2.1.8([email protected]([email protected]))([email protected])
'@floating-ui/utils': 0.2.11
- date-fns: 4.1.0
react: 19.2.5
react-dom: 19.2.5([email protected])
use-sync-external-store: 1.6.0([email protected])
@@ -9474,8 +8850,6 @@ snapshots:
'@cucumber/[email protected]': {}
- '@date-fns/[email protected]': {}
-
dependencies:
eslint-plugin-depend: 1.5.0([email protected]([email protected]))
@@ -9488,27 +8862,11 @@ snapshots:
'@iconify/utils': 3.1.0
tailwindcss: 4.2.2
- '@emnapi/[email protected]':
- dependencies:
- '@emnapi/wasi-threads': 1.2.1
- tslib: 2.8.1
- optional: true
-
'@emnapi/[email protected]':
dependencies:
tslib: 2.8.1
optional: true
- '@emnapi/[email protected]':
- dependencies:
- tslib: 2.8.1
- optional: true
-
- '@emnapi/[email protected]':
- dependencies:
- tslib: 2.8.1
- optional: true
-
'@emoji-mart/[email protected]': {}
'@es-joy/[email protected]':
@@ -10025,11 +9383,11 @@ snapshots:
dependencies:
minipass: 7.1.3
dependencies:
glob: 13.0.6
react-docgen-typescript: 2.4.0([email protected])
optionalDependencies:
typescript: 6.0.2
@@ -10045,11 +9403,6 @@ snapshots:
'@jridgewell/[email protected]': {}
- '@jridgewell/[email protected]':
- dependencies:
- '@jridgewell/gen-mapping': 0.3.13
- '@jridgewell/trace-mapping': 0.3.31
-
'@jridgewell/[email protected]': {}
'@jridgewell/[email protected]':
@@ -10153,7 +9506,7 @@ snapshots:
'@lexical/utils': 0.43.0
lexical: 0.43.0
dependencies:
'@floating-ui/react': 0.27.19([email protected]([email protected]))([email protected])
'@lexical/devtools-core': 0.43.0([email protected]([email protected]))([email protected])
@@ -10171,7 +9524,7 @@ snapshots:
'@lexical/table': 0.43.0
'@lexical/text': 0.43.0
'@lexical/utils': 0.43.0
- '@lexical/yjs': 0.43.0([email protected])
+ '@lexical/yjs': 0.43.0
lexical: 0.43.0
react: 19.2.5
react-dom: 19.2.5([email protected])
@@ -10207,19 +9560,16 @@ snapshots:
'@lexical/selection': 0.43.0
lexical: 0.43.0
+ '@lexical/[email protected]':
dependencies:
'@lexical/offset': 0.43.0
'@lexical/selection': 0.43.0
lexical: 0.43.0
- yjs: 13.6.30
+ '@mdx-js/[email protected]':
dependencies:
'@mdx-js/mdx': 3.1.1
source-map: 0.7.6
- optionalDependencies:
transitivePeerDependencies:
- supports-color
@@ -10259,11 +9609,10 @@ snapshots:
'@types/react': 19.2.14
react: 19.2.5
+ '@mdx-js/[email protected]':
dependencies:
'@mdx-js/mdx': 3.1.1
- '@rollup/pluginutils': 5.3.0([email protected])
- rollup: 4.59.0
+ '@rollup/pluginutils': 5.3.0
source-map: 0.7.6
vfile: 6.0.3
transitivePeerDependencies:
@@ -10277,17 +9626,15 @@ snapshots:
dependencies:
state-local: 1.0.7
dependencies:
'@monaco-editor/loader': 1.7.0
- monaco-editor: 0.55.1
react: 19.2.5
react-dom: 19.2.5([email protected])
+ '@napi-rs/[email protected](@emnapi/[email protected])':
dependencies:
- '@emnapi/core': 1.9.2
- '@emnapi/runtime': 1.9.2
+ '@emnapi/runtime': 1.9.1
'@tybys/wasm-util': 0.10.1
optional: true
@@ -10301,11 +9648,11 @@ snapshots:
dependencies:
fast-glob: 3.3.1
dependencies:
source-map: 0.7.6
optionalDependencies:
+ '@mdx-js/loader': 3.1.1
'@mdx-js/react': 3.1.1(@types/[email protected])([email protected])
@@ -10460,9 +9807,9 @@ snapshots:
'@oxc-parser/[email protected]':
optional: true
- '@oxc-parser/[email protected](@emnapi/[email protected])(@emnapi/[email protected])':
+ '@oxc-parser/[email protected](@emnapi/[email protected])':
dependencies:
- '@napi-rs/wasm-runtime': 1.1.2(@emnapi/[email protected])(@emnapi/[email protected])
+ '@napi-rs/wasm-runtime': 1.1.2(@emnapi/[email protected])
transitivePeerDependencies:
- '@emnapi/core'
- '@emnapi/runtime'
@@ -10531,9 +9878,9 @@ snapshots:
'@oxc-resolver/[email protected]':
optional: true
- '@oxc-resolver/[email protected](@emnapi/[email protected])(@emnapi/[email protected])':
+ '@oxc-resolver/[email protected](@emnapi/[email protected])':
dependencies:
- '@napi-rs/wasm-runtime': 1.1.2(@emnapi/[email protected])(@emnapi/[email protected])
+ '@napi-rs/wasm-runtime': 1.1.2(@emnapi/[email protected])
transitivePeerDependencies:
- '@emnapi/core'
- '@emnapi/runtime'
@@ -10680,67 +10027,6 @@ snapshots:
'@oxlint/[email protected]':
optional: true
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- optional: true
-
- '@parcel/[email protected]':
- dependencies:
- detect-libc: 2.1.2
- is-glob: 4.0.3
- node-addon-api: 7.1.1
- picomatch: 4.0.4
- optionalDependencies:
- '@parcel/watcher-android-arm64': 2.5.6
- '@parcel/watcher-darwin-arm64': 2.5.6
- '@parcel/watcher-darwin-x64': 2.5.6
- '@parcel/watcher-freebsd-x64': 2.5.6
- '@parcel/watcher-linux-arm-glibc': 2.5.6
- '@parcel/watcher-linux-arm-musl': 2.5.6
- '@parcel/watcher-linux-arm64-glibc': 2.5.6
- '@parcel/watcher-linux-arm64-musl': 2.5.6
- '@parcel/watcher-linux-x64-glibc': 2.5.6
- '@parcel/watcher-linux-x64-musl': 2.5.6
- '@parcel/watcher-win32-arm64': 2.5.6
- '@parcel/watcher-win32-ia32': 2.5.6
- '@parcel/watcher-win32-x64': 2.5.6
- optional: true
-
'@pkgr/[email protected]': {}
'@playwright/[email protected]':
@@ -11049,108 +10335,29 @@ snapshots:
'@rolldown/[email protected]': {}
+ '@rollup/[email protected]':
dependencies:
- '@rollup/pluginutils': 5.3.0([email protected])
+ '@rollup/pluginutils': 5.3.0
magic-string: 0.30.21
- optionalDependencies:
- rollup: 4.59.0
+ '@rollup/[email protected]':
dependencies:
'@types/estree': 1.0.8
estree-walker: 2.0.2
picomatch: 4.0.4
- optionalDependencies:
- rollup: 4.59.0
-
- '@rollup/[email protected]':
- optional: true
- '@rollup/[email protected]':
- optional: true
+ '@sentry-internal/[email protected]':
+ dependencies:
+ '@sentry/core': 10.48.0
- '@rollup/[email protected]':
- optional: true
+ '@sentry-internal/[email protected]':
+ dependencies:
+ '@sentry/core': 10.48.0
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@rollup/[email protected]':
- optional: true
-
- '@sentry-internal/[email protected]':
- dependencies:
- '@sentry/core': 10.48.0
-
- '@sentry-internal/[email protected]':
- dependencies:
- '@sentry/core': 10.48.0
-
- '@sentry-internal/[email protected]':
- dependencies:
- '@sentry-internal/replay': 10.48.0
- '@sentry/core': 10.48.0
+ '@sentry-internal/[email protected]':
+ dependencies:
+ '@sentry-internal/replay': 10.48.0
+ '@sentry/core': 10.48.0
'@sentry-internal/[email protected]':
dependencies:
@@ -11260,27 +10467,10 @@ snapshots:
'@standard-schema/[email protected]': {}
dependencies:
'@mdx-js/react': 3.1.1(@types/[email protected])([email protected])
- react: 19.2.5
- react-dom: 19.2.5([email protected])
- ts-dedent: 2.2.0
- transitivePeerDependencies:
- - '@types/react'
- - esbuild
- - rollup
- - vite
- - webpack
-
- dependencies:
- '@mdx-js/react': 3.1.1(@types/[email protected])([email protected])
react: 19.2.5
@@ -11310,47 +10500,24 @@ snapshots:
ts-dedent: 2.2.0
- dependencies:
- ts-dedent: 2.2.0
- transitivePeerDependencies:
- - esbuild
- - rollup
- - webpack
-
dependencies:
ts-dedent: 2.2.0
transitivePeerDependencies:
- esbuild
- rollup
- webpack
dependencies:
unplugin: 2.3.11
optionalDependencies:
esbuild: 0.27.2
- rollup: 4.59.0
-
- dependencies:
- unplugin: 2.3.11
- optionalDependencies:
- esbuild: 0.27.2
- rollup: 4.59.0
- webpack: 5.105.4([email protected])
'@storybook/[email protected]': {}
@@ -11359,18 +10526,18 @@ snapshots:
react: 19.2.5
react-dom: 19.2.5([email protected])
dependencies:
react: 19.2.5
react-dom: 19.2.5([email protected])
styled-jsx: 5.1.6(@babel/[email protected])([email protected])
optionalDependencies:
typescript: 6.0.2
transitivePeerDependencies:
@@ -11387,33 +10554,11 @@ snapshots:
react-dom: 19.2.5([email protected])
- dependencies:
- '@rollup/pluginutils': 5.3.0([email protected])
- empathic: 2.0.0
- magic-string: 0.30.21
- react: 19.2.5
- react-docgen: 8.0.3
- react-dom: 19.2.5([email protected])
- resolve: 1.22.11
- tsconfig-paths: 4.2.0
- transitivePeerDependencies:
- - esbuild
- - rollup
- - supports-color
- - typescript
- - webpack
-
dependencies:
- '@rollup/pluginutils': 5.3.0([email protected])
+ '@joshwooding/vite-plugin-react-docgen-typescript': 0.7.0(@voidzero-dev/[email protected](@types/[email protected])([email protected])([email protected])([email protected])([email protected])([email protected]))([email protected])
+ '@rollup/pluginutils': 5.3.0
empathic: 2.0.0
magic-string: 0.30.21
@@ -11423,7 +10568,7 @@ snapshots:
resolve: 1.22.11
tsconfig-paths: 4.2.0
transitivePeerDependencies:
- esbuild
- rollup
@@ -11562,12 +10707,12 @@ snapshots:
postcss-selector-parser: 6.0.10
tailwindcss: 4.2.2
dependencies:
'@tailwindcss/node': 4.2.2
'@tailwindcss/oxide': 4.2.2
tailwindcss: 4.2.2
'@tanstack/[email protected]':
dependencies:
@@ -11582,7 +10727,7 @@ snapshots:
'@tanstack/[email protected]': {}
dependencies:
clsx: 2.1.1
dayjs: 1.11.20
@@ -11597,14 +10742,14 @@ snapshots:
react: 19.2.5
solid-js: 1.9.11
dependencies:
'@solid-primitives/event-listener': 2.4.5([email protected])
'@solid-primitives/keyboard': 1.3.5([email protected])
'@solid-primitives/resize-observer': 2.1.5([email protected])
'@tanstack/devtools-client': 0.0.6
'@tanstack/devtools-event-bus': 0.4.1
- '@tanstack/devtools-ui': 0.5.1([email protected])([email protected])
+ '@tanstack/devtools-ui': 0.5.1([email protected])
clsx: 2.1.1
goober: 2.1.18([email protected])
solid-js: 1.9.11
@@ -11630,7 +10775,7 @@ snapshots:
dependencies:
- '@tanstack/devtools-ui': 0.5.1([email protected])([email protected])
+ '@tanstack/devtools-ui': 0.5.1([email protected])
'@tanstack/devtools-utils': 0.4.0(@types/[email protected])([email protected])([email protected])
'@tanstack/form-core': 1.29.0
clsx: 2.1.1
@@ -11650,9 +10795,9 @@ snapshots:
'@tanstack/[email protected]': {}
dependencies:
- '@tanstack/devtools': 0.11.2([email protected])([email protected])
+ '@tanstack/devtools': 0.11.2([email protected])
'@types/react': 19.2.14
'@types/react-dom': 19.2.3(@types/[email protected])
react: 19.2.5
@@ -11660,7 +10805,6 @@ snapshots:
transitivePeerDependencies:
- bufferutil
- csstype
- - solid-js
- utf-8-validate
@@ -11948,16 +11092,6 @@ snapshots:
'@types/[email protected]': {}
- '@types/[email protected]':
- dependencies:
- '@types/eslint': 9.6.1
- '@types/estree': 1.0.8
-
- '@types/[email protected]':
- dependencies:
- '@types/estree': 1.0.8
- '@types/json-schema': 7.0.15
-
'@types/[email protected]': {}
@@ -12050,18 +11184,6 @@ snapshots:
transitivePeerDependencies:
- supports-color
- dependencies:
- '@typescript-eslint/scope-manager': 8.57.2
- '@typescript-eslint/types': 8.57.2
- '@typescript-eslint/typescript-estree': 8.57.2([email protected])
- '@typescript-eslint/visitor-keys': 8.57.2
- debug: 4.4.3([email protected])
- eslint: 10.2.0([email protected])
- typescript: 6.0.2
- transitivePeerDependencies:
- - supports-color
-
dependencies:
'@typescript-eslint/scope-manager': 8.58.2
@@ -12086,15 +11208,6 @@ snapshots:
transitivePeerDependencies:
- supports-color
- '@typescript-eslint/[email protected]([email protected])':
- dependencies:
- '@typescript-eslint/tsconfig-utils': 8.58.2([email protected])
- '@typescript-eslint/types': 8.58.2
- debug: 4.4.3([email protected])
- typescript: 6.0.2
- transitivePeerDependencies:
- - supports-color
-
'@typescript-eslint/[email protected]([email protected])':
dependencies:
'@typescript-eslint/tsconfig-utils': 8.58.2([email protected])
@@ -12104,34 +11217,11 @@ snapshots:
transitivePeerDependencies:
- supports-color
- dependencies:
- '@typescript-eslint/parser': 8.57.2([email protected]([email protected]))([email protected])
- '@typescript-eslint/typescript-estree': 8.57.2([email protected])
- '@typescript-eslint/utils': 8.57.2([email protected]([email protected]))([email protected])
- ajv: 6.14.0
- eslint: 10.2.0([email protected])
- json-stable-stringify-without-jsonify: 1.0.1
- lodash.merge: 4.6.2
- semver: 7.7.4
- transitivePeerDependencies:
- - supports-color
- - typescript
-
- '@typescript-eslint/[email protected]':
- dependencies:
- '@typescript-eslint/types': 8.57.2
- '@typescript-eslint/visitor-keys': 8.57.2
-
'@typescript-eslint/[email protected]':
dependencies:
'@typescript-eslint/types': 8.58.2
'@typescript-eslint/visitor-keys': 8.58.2
- '@typescript-eslint/[email protected]([email protected])':
- dependencies:
- typescript: 6.0.2
-
'@typescript-eslint/[email protected]([email protected])':
dependencies:
typescript: 6.0.2
@@ -12148,25 +11238,8 @@ snapshots:
transitivePeerDependencies:
- supports-color
- '@typescript-eslint/[email protected]': {}
-
'@typescript-eslint/[email protected]': {}
- '@typescript-eslint/[email protected]([email protected])':
- dependencies:
- '@typescript-eslint/project-service': 8.57.2([email protected])
- '@typescript-eslint/tsconfig-utils': 8.57.2([email protected])
- '@typescript-eslint/types': 8.57.2
- '@typescript-eslint/visitor-keys': 8.57.2
- debug: 4.4.3([email protected])
- minimatch: 10.2.4
- semver: 7.7.4
- tinyglobby: 0.2.16
- ts-api-utils: 2.5.0([email protected])
- typescript: 6.0.2
- transitivePeerDependencies:
- - supports-color
-
'@typescript-eslint/[email protected]([email protected])':
dependencies:
'@typescript-eslint/project-service': 8.58.2([email protected])
@@ -12182,17 +11255,6 @@ snapshots:
transitivePeerDependencies:
- supports-color
- dependencies:
- '@eslint-community/eslint-utils': 4.9.1([email protected]([email protected]))
- '@typescript-eslint/scope-manager': 8.57.2
- '@typescript-eslint/types': 8.57.2
- '@typescript-eslint/typescript-estree': 8.57.2([email protected])
- eslint: 10.2.0([email protected])
- typescript: 6.0.2
- transitivePeerDependencies:
- - supports-color
-
dependencies:
'@eslint-community/eslint-utils': 4.9.1([email protected]([email protected]))
@@ -12204,11 +11266,6 @@ snapshots:
transitivePeerDependencies:
- supports-color
- '@typescript-eslint/[email protected]':
- dependencies:
- '@typescript-eslint/types': 8.57.2
- eslint-visitor-keys: 5.0.1
-
'@typescript-eslint/[email protected]':
dependencies:
'@typescript-eslint/types': 8.58.2
@@ -12251,13 +11308,13 @@ snapshots:
dependencies:
unpic: 4.2.2
dependencies:
'@unpic/core': 1.0.3
react: 19.2.5
react-dom: 19.2.5([email protected])
optionalDependencies:
'@upsetjs/[email protected]':
optionalDependencies:
@@ -12273,12 +11330,12 @@ snapshots:
'@resvg/resvg-wasm': 2.4.0
satori: 0.16.0
dependencies:
'@vitejs/devtools-rpc': 0.1.11([email protected])([email protected])
birpc: 4.0.0
ohash: 2.0.11
transitivePeerDependencies:
- typescript
- ws
@@ -12295,12 +11352,12 @@ snapshots:
transitivePeerDependencies:
- typescript
dependencies:
'@rolldown/pluginutils': 1.0.0-rc.7
dependencies:
'@rolldown/pluginutils': 1.0.0-rc.15
es-module-lexer: 2.0.0
@@ -12311,26 +11368,12 @@ snapshots:
srvx: 0.11.15
strip-literal: 3.1.0
turbo-stream: 3.2.0
optionalDependencies:
-
- '@vitest/[email protected](@voidzero-dev/[email protected])':
- dependencies:
- '@bcoe/v8-coverage': 1.0.2
- '@vitest/utils': 4.1.4
- ast-v8-to-istanbul: 1.0.0
- istanbul-lib-coverage: 3.2.2
- istanbul-lib-report: 3.0.1
- istanbul-reports: 3.2.0
- magicast: 0.5.2
- obug: 2.1.1
- std-env: 4.0.0
- tinyrainbow: 3.1.0
+ react-server-dom-webpack: 19.2.5([email protected]([email protected]))([email protected])
dependencies:
'@bcoe/v8-coverage': 1.0.2
'@vitest/utils': 4.1.4
@@ -12342,32 +11385,74 @@ snapshots:
obug: 2.1.1
std-env: 4.0.0
tinyrainbow: 3.1.0
- optional: true
-
- dependencies:
- '@typescript-eslint/scope-manager': 8.58.2
- '@typescript-eslint/utils': 8.58.2([email protected]([email protected]))([email protected])
- eslint: 10.2.0([email protected])
- optionalDependencies:
- typescript: 6.0.2
transitivePeerDependencies:
- - supports-color
+ - '@arethetypeswrong/core'
+ - '@edge-runtime/vm'
+ - '@opentelemetry/api'
+ - '@tsdown/css'
+ - '@tsdown/exe'
+ - '@types/node'
+ - '@vitejs/devtools'
+ - '@vitest/coverage-istanbul'
+ - '@vitest/ui'
+ - bufferutil
+ - esbuild
+ - happy-dom
+ - jiti
+ - jsdom
+ - less
+ - publint
+ - sass
+ - sass-embedded
+ - stylus
+ - sugarss
+ - terser
+ - tsx
+ - typescript
+ - unplugin-unused
+ - utf-8-validate
+ - vite
+ - yaml
dependencies:
'@typescript-eslint/scope-manager': 8.58.2
'@typescript-eslint/utils': 8.58.2([email protected]([email protected]))([email protected])
eslint: 10.2.0([email protected])
optionalDependencies:
typescript: 6.0.2
transitivePeerDependencies:
+ - '@arethetypeswrong/core'
+ - '@edge-runtime/vm'
+ - '@opentelemetry/api'
+ - '@tsdown/css'
+ - '@tsdown/exe'
+ - '@types/node'
+ - '@vitejs/devtools'
+ - '@vitest/coverage-istanbul'
+ - '@vitest/coverage-v8'
+ - '@vitest/ui'
+ - bufferutil
+ - esbuild
+ - happy-dom
+ - jiti
+ - jsdom
+ - less
+ - publint
+ - sass
+ - sass-embedded
+ - stylus
+ - sugarss
- supports-color
+ - terser
+ - tsx
+ - unplugin-unused
+ - utf-8-validate
+ - vite
+ - yaml
'@vitest/[email protected]':
dependencies:
@@ -12377,25 +11462,6 @@ snapshots:
chai: 5.3.3
tinyrainbow: 2.0.0
- '@vitest/[email protected]':
- dependencies:
- '@standard-schema/spec': 1.1.0
- '@types/chai': 5.2.3
- '@vitest/spy': 4.1.4
- '@vitest/utils': 4.1.4
- chai: 6.2.2
- tinyrainbow: 3.1.0
- optional: true
-
- dependencies:
- '@vitest/spy': 4.1.4
- estree-walker: 3.0.3
- magic-string: 0.30.21
- optionalDependencies:
- optional: true
-
'@vitest/[email protected]':
dependencies:
tinyrainbow: 2.0.0
@@ -12404,27 +11470,10 @@ snapshots:
dependencies:
tinyrainbow: 3.1.0
- '@vitest/[email protected]':
- dependencies:
- '@vitest/utils': 4.1.4
- pathe: 2.0.3
- optional: true
-
- '@vitest/[email protected]':
- dependencies:
- '@vitest/pretty-format': 4.1.4
- '@vitest/utils': 4.1.4
- magic-string: 0.30.21
- pathe: 2.0.3
- optional: true
-
'@vitest/[email protected]':
dependencies:
tinyspy: 4.0.4
- '@vitest/[email protected]':
- optional: true
-
'@vitest/[email protected]':
dependencies:
'@vitest/pretty-format': 3.2.4
@@ -12437,7 +11486,7 @@ snapshots:
convert-source-map: 2.0.0
tinyrainbow: 3.1.0
dependencies:
'@oxc-project/runtime': 0.124.0
'@oxc-project/types': 0.124.0
@@ -12448,8 +11497,6 @@ snapshots:
esbuild: 0.27.2
fsevents: 2.3.3
jiti: 2.6.1
- sass: 1.98.0
- terser: 5.46.1
tsx: 4.21.0
typescript: 6.0.2
yaml: 2.8.3
@@ -12472,11 +11519,11 @@ snapshots:
'@voidzero-dev/[email protected]':
optional: true
dependencies:
'@standard-schema/spec': 1.1.0
'@types/chai': 5.2.3
es-module-lexer: 1.7.0
obug: 2.1.1
pixelmatch: 7.1.0
@@ -12486,11 +11533,11 @@ snapshots:
tinybench: 2.9.0
tinyexec: 1.0.4
tinyglobby: 0.2.16
ws: 8.20.0
optionalDependencies:
'@types/node': 25.6.0
- '@vitest/coverage-v8': 4.1.4(@voidzero-dev/[email protected])
happy-dom: 20.9.0
transitivePeerDependencies:
- '@arethetypeswrong/core'
@@ -12546,115 +11593,14 @@ snapshots:
'@vue/compiler-core': 3.5.31
'@vue/shared': 3.5.31
- dependencies:
- '@babel/parser': 7.29.2
- '@vue/compiler-core': 3.5.31
- '@vue/compiler-dom': 3.5.31
- '@vue/compiler-ssr': 3.5.31
- '@vue/shared': 3.5.31
- estree-walker: 2.0.2
- magic-string: 0.30.21
- postcss: 8.5.9
- source-map-js: 1.2.1
-
- dependencies:
- '@vue/compiler-dom': 3.5.31
- '@vue/shared': 3.5.31
-
'@vue/[email protected]': {}
- '@webassemblyjs/[email protected]':
- dependencies:
- '@webassemblyjs/helper-numbers': 1.13.2
- '@webassemblyjs/helper-wasm-bytecode': 1.13.2
-
- '@webassemblyjs/[email protected]': {}
-
- '@webassemblyjs/[email protected]': {}
-
- '@webassemblyjs/[email protected]': {}
-
- '@webassemblyjs/[email protected]':
- dependencies:
- '@webassemblyjs/floating-point-hex-parser': 1.13.2
- '@webassemblyjs/helper-api-error': 1.13.2
- '@xtuc/long': 4.2.2
-
- '@webassemblyjs/[email protected]': {}
-
- '@webassemblyjs/[email protected]':
- dependencies:
- '@webassemblyjs/ast': 1.14.1
- '@webassemblyjs/helper-buffer': 1.14.1
- '@webassemblyjs/helper-wasm-bytecode': 1.13.2
- '@webassemblyjs/wasm-gen': 1.14.1
-
- '@webassemblyjs/[email protected]':
- dependencies:
- '@xtuc/ieee754': 1.2.0
-
- '@webassemblyjs/[email protected]':
- dependencies:
- '@xtuc/long': 4.2.2
-
- '@webassemblyjs/[email protected]': {}
-
- '@webassemblyjs/[email protected]':
- dependencies:
- '@webassemblyjs/ast': 1.14.1
- '@webassemblyjs/helper-buffer': 1.14.1
- '@webassemblyjs/helper-wasm-bytecode': 1.13.2
- '@webassemblyjs/helper-wasm-section': 1.14.1
- '@webassemblyjs/wasm-gen': 1.14.1
- '@webassemblyjs/wasm-opt': 1.14.1
- '@webassemblyjs/wasm-parser': 1.14.1
- '@webassemblyjs/wast-printer': 1.14.1
-
- '@webassemblyjs/[email protected]':
- dependencies:
- '@webassemblyjs/ast': 1.14.1
- '@webassemblyjs/helper-wasm-bytecode': 1.13.2
- '@webassemblyjs/ieee754': 1.13.2
- '@webassemblyjs/leb128': 1.13.2
- '@webassemblyjs/utf8': 1.13.2
-
- '@webassemblyjs/[email protected]':
- dependencies:
- '@webassemblyjs/ast': 1.14.1
- '@webassemblyjs/helper-buffer': 1.14.1
- '@webassemblyjs/wasm-gen': 1.14.1
- '@webassemblyjs/wasm-parser': 1.14.1
-
- '@webassemblyjs/[email protected]':
- dependencies:
- '@webassemblyjs/ast': 1.14.1
- '@webassemblyjs/helper-api-error': 1.13.2
- '@webassemblyjs/helper-wasm-bytecode': 1.13.2
- '@webassemblyjs/ieee754': 1.13.2
- '@webassemblyjs/leb128': 1.13.2
- '@webassemblyjs/utf8': 1.13.2
-
- '@webassemblyjs/[email protected]':
- dependencies:
- '@webassemblyjs/ast': 1.14.1
- '@xtuc/long': 4.2.2
-
'@webcontainer/[email protected]': {}
'@xstate/[email protected]': {}
- '@xtuc/[email protected]': {}
-
- '@xtuc/[email protected]': {}
-
- dependencies:
- acorn: 8.16.0
-
dependencies:
acorn: 8.16.0
@@ -12685,15 +11631,6 @@ snapshots:
screenfull: 5.2.0
tslib: 2.8.1
- optionalDependencies:
- ajv: 8.18.0
-
- dependencies:
- ajv: 8.18.0
- fast-deep-equal: 3.1.3
-
dependencies:
fast-deep-equal: 3.1.3
@@ -12701,13 +11638,6 @@ snapshots:
json-schema-traverse: 0.4.1
uri-js: 4.4.1
- dependencies:
- fast-deep-equal: 3.1.3
- fast-uri: 3.1.0
- json-schema-traverse: 1.0.0
- require-from-string: 2.0.2
-
@@ -12859,9 +11789,6 @@ snapshots:
loupe: 3.2.1
pathval: 2.0.1
- optional: true
-
dependencies:
ansi-styles: 4.3.0
@@ -12921,11 +11848,6 @@ snapshots:
'@chevrotain/utils': 11.1.2
lodash-es: 4.18.0
- dependencies:
- readdirp: 4.1.2
- optional: true
-
optional: true
@@ -12933,8 +11855,6 @@ snapshots:
-
@@ -13001,8 +11921,6 @@ snapshots:
-
@@ -13277,8 +12195,6 @@ snapshots:
d3: 7.9.0
lodash-es: 4.18.0
-
@@ -13562,10 +12478,9 @@ snapshots:
- '@eslint/css'
- typescript
dependencies:
'@es-joy/jsdoccomment': 0.84.0
- '@typescript-eslint/rule-tester': 8.57.2([email protected]([email protected]))([email protected])
'@typescript-eslint/typescript-estree': 8.58.2([email protected])
'@typescript-eslint/utils': 8.58.2([email protected]([email protected]))([email protected])
eslint: 10.2.0([email protected])
@@ -13881,16 +12796,10 @@ snapshots:
transitivePeerDependencies:
- supports-color
dependencies:
- '@vue/compiler-sfc': 3.5.31
eslint: 10.2.0([email protected])
- dependencies:
- esrecurse: 4.3.0
- estraverse: 4.3.0
-
dependencies:
esrecurse: 4.3.0
@@ -14010,8 +12919,6 @@ snapshots:
dependencies:
estraverse: 5.3.0
-
@@ -14051,14 +12958,9 @@ snapshots:
-
optional: true
- optional: true
-
@@ -14101,8 +13003,6 @@ snapshots:
dependencies:
fast-string-truncated-width: 1.2.1
-
dependencies:
fast-string-width: 1.1.0
@@ -14199,8 +13099,6 @@ snapshots:
dependencies:
is-glob: 4.0.3
-
dependencies:
minimatch: 10.2.4
@@ -14458,9 +13356,6 @@ snapshots:
- optional: true
-
dependencies:
parent-module: 1.0.1
@@ -14538,8 +13433,6 @@ snapshots:
-
@@ -14553,12 +13446,6 @@ snapshots:
html-escaper: 2.0.2
istanbul-lib-report: 3.0.1
- dependencies:
- '@types/node': 25.6.0
- merge-stream: 2.0.0
- supports-color: 8.1.1
-
@@ -14592,12 +13479,8 @@ snapshots:
-
-
@@ -14628,7 +13511,7 @@ snapshots:
dependencies:
'@nodelib/fs.walk': 1.2.8
fast-glob: 3.3.3
@@ -14636,8 +13519,8 @@ snapshots:
get-tsconfig: 4.13.7
jiti: 2.6.1
minimist: 1.2.8
- oxc-parser: 0.121.0(@emnapi/[email protected])(@emnapi/[email protected])
- oxc-resolver: 11.19.1(@emnapi/[email protected])(@emnapi/[email protected])
+ oxc-parser: 0.121.0(@emnapi/[email protected])
+ oxc-resolver: 11.19.1(@emnapi/[email protected])
picocolors: 1.1.1
picomatch: 4.0.4
smol-toml: 1.6.1
@@ -14690,10 +13573,6 @@ snapshots:
- dependencies:
- isomorphic.js: 0.2.5
-
optional: true
@@ -14748,8 +13627,6 @@ snapshots:
base64-js: 0.0.8
unicode-trie: 2.0.0
-
dependencies:
mlly: 1.8.2
@@ -14812,8 +13689,6 @@ snapshots:
-
@@ -15029,8 +13904,6 @@ snapshots:
-
@@ -15353,12 +14226,6 @@ snapshots:
braces: 3.0.3
picomatch: 2.3.2
-
- dependencies:
- mime-db: 1.52.0
-
@@ -15402,11 +14269,6 @@ snapshots:
- dependencies:
- dompurify: 3.3.2
- marked: 14.0.0
-
dependencies:
color-name: 1.1.4
@@ -15439,7 +14301,7 @@ snapshots:
react: 19.2.5
react-dom: 19.2.5([email protected])
dependencies:
'@next/env': 16.2.3
'@swc/helpers': 0.5.15
@@ -15459,7 +14321,6 @@ snapshots:
'@next/swc-win32-arm64-msvc': 16.2.3
'@next/swc-win32-x64-msvc': 16.2.3
'@playwright/test': 1.59.1
- sass: 1.98.0
sharp: 0.34.5
transitivePeerDependencies:
- '@babel/core'
@@ -15492,12 +14353,12 @@ snapshots:
dependencies:
boolbase: 1.0.0
dependencies:
'@standard-schema/spec': 1.0.0
react: 19.2.5
optionalDependencies:
@@ -15546,7 +14407,7 @@ snapshots:
type-check: 0.4.0
word-wrap: 1.2.5
dependencies:
'@oxc-project/types': 0.121.0
optionalDependencies:
@@ -15566,7 +14427,7 @@ snapshots:
'@oxc-parser/binding-linux-x64-gnu': 0.121.0
'@oxc-parser/binding-linux-x64-musl': 0.121.0
'@oxc-parser/binding-openharmony-arm64': 0.121.0
- '@oxc-parser/binding-wasm32-wasi': 0.121.0(@emnapi/[email protected])(@emnapi/[email protected])
+ '@oxc-parser/binding-wasm32-wasi': 0.121.0(@emnapi/[email protected])
'@oxc-parser/binding-win32-arm64-msvc': 0.121.0
'@oxc-parser/binding-win32-ia32-msvc': 0.121.0
'@oxc-parser/binding-win32-x64-msvc': 0.121.0
@@ -15574,7 +14435,7 @@ snapshots:
- '@emnapi/core'
- '@emnapi/runtime'
optionalDependencies:
'@oxc-resolver/binding-android-arm-eabi': 11.19.1
'@oxc-resolver/binding-android-arm64': 11.19.1
@@ -15592,7 +14453,7 @@ snapshots:
'@oxc-resolver/binding-linux-x64-gnu': 11.19.1
'@oxc-resolver/binding-linux-x64-musl': 11.19.1
'@oxc-resolver/binding-openharmony-arm64': 11.19.1
- '@oxc-resolver/binding-wasm32-wasi': 11.19.1(@emnapi/[email protected])(@emnapi/[email protected])
+ '@oxc-resolver/binding-wasm32-wasi': 11.19.1(@emnapi/[email protected])
'@oxc-resolver/binding-win32-arm64-msvc': 11.19.1
'@oxc-resolver/binding-win32-ia32-msvc': 11.19.1
'@oxc-resolver/binding-win32-x64-msvc': 11.19.1
@@ -16023,13 +14884,12 @@ snapshots:
tslib: 2.6.2
dependencies:
acorn-loose: 8.5.2
neo-async: 2.6.2
react: 19.2.5
react-dom: 19.2.5([email protected])
webpack-sources: 3.3.4
@@ -16095,9 +14955,6 @@ snapshots:
util-deprecate: 1.0.2
optional: true
- optional: true
-
dependencies:
ast-types: 0.16.1
@@ -16273,8 +15130,6 @@ snapshots:
-
@@ -16295,37 +15150,6 @@ snapshots:
- dependencies:
- '@types/estree': 1.0.8
- optionalDependencies:
- '@rollup/rollup-android-arm-eabi': 4.59.0
- '@rollup/rollup-android-arm64': 4.59.0
- '@rollup/rollup-darwin-arm64': 4.59.0
- '@rollup/rollup-darwin-x64': 4.59.0
- '@rollup/rollup-freebsd-arm64': 4.59.0
- '@rollup/rollup-freebsd-x64': 4.59.0
- '@rollup/rollup-linux-arm-gnueabihf': 4.59.0
- '@rollup/rollup-linux-arm-musleabihf': 4.59.0
- '@rollup/rollup-linux-arm64-gnu': 4.59.0
- '@rollup/rollup-linux-arm64-musl': 4.59.0
- '@rollup/rollup-linux-loong64-gnu': 4.59.0
- '@rollup/rollup-linux-loong64-musl': 4.59.0
- '@rollup/rollup-linux-ppc64-gnu': 4.59.0
- '@rollup/rollup-linux-ppc64-musl': 4.59.0
- '@rollup/rollup-linux-riscv64-gnu': 4.59.0
- '@rollup/rollup-linux-riscv64-musl': 4.59.0
- '@rollup/rollup-linux-s390x-gnu': 4.59.0
- '@rollup/rollup-linux-x64-gnu': 4.59.0
- '@rollup/rollup-linux-x64-musl': 4.59.0
- '@rollup/rollup-openbsd-x64': 4.59.0
- '@rollup/rollup-openharmony-arm64': 4.59.0
- '@rollup/rollup-win32-arm64-msvc': 4.59.0
- '@rollup/rollup-win32-ia32-msvc': 4.59.0
- '@rollup/rollup-win32-x64-gnu': 4.59.0
- '@rollup/rollup-win32-x64-msvc': 4.59.0
- fsevents: 2.3.3
-
dependencies:
hachure-fill: 0.5.2
@@ -16346,15 +15170,6 @@ snapshots:
- dependencies:
- chokidar: 4.0.3
- immutable: 5.1.5
- source-map-js: 1.2.1
- optionalDependencies:
- '@parcel/watcher': 2.5.6
- optional: true
-
dependencies:
'@shuding/opentype.js': 1.4.0-beta.0
@@ -16373,13 +15188,6 @@ snapshots:
- dependencies:
- '@types/json-schema': 7.0.15
- ajv: 8.18.0
- ajv-formats: 2.1.1([email protected])
- ajv-keywords: 5.1.0([email protected])
-
@@ -16448,9 +15256,6 @@ snapshots:
'@shikijs/vscode-textmate': 10.0.2
'@types/hast': 3.0.4
- optional: true
-
optional: true
@@ -16533,9 +15338,6 @@ snapshots:
- optional: true
-
@@ -16713,35 +15515,6 @@ snapshots:
minizlib: 3.1.0
yallist: 5.0.0
- dependencies:
- '@jridgewell/trace-mapping': 0.3.31
- jest-worker: 27.5.1
- schema-utils: 4.3.3
- terser: 5.46.1
- optionalDependencies:
- esbuild: 0.27.2
- uglify-js: 3.19.3
-
- dependencies:
- '@jridgewell/trace-mapping': 0.3.31
- jest-worker: 27.5.1
- schema-utils: 4.3.3
- terser: 5.46.1
- webpack: 5.105.4([email protected])
- optionalDependencies:
- esbuild: 0.27.2
- optional: true
-
- dependencies:
- '@jridgewell/source-map': 0.3.11
- acorn: 8.16.0
- commander: 2.20.3
- source-map-support: 0.5.21
-
dependencies:
thenify: 3.3.1
@@ -17046,21 +15819,21 @@ snapshots:
'@types/unist': 3.0.3
vfile-message: 4.0.3
- [email protected](453b4e184a832f83060410b31544dc36):
dependencies:
'@vercel/og': 0.8.6
magic-string: 0.30.21
react: 19.2.5
react-dom: 19.2.5([email protected])
vite-plugin-commonjs: 0.10.4
optionalDependencies:
- '@mdx-js/rollup': 3.1.1([email protected])
+ '@mdx-js/rollup': 3.1.1
+ react-server-dom-webpack: 19.2.5([email protected]([email protected]))([email protected])
transitivePeerDependencies:
- next
- supports-color
@@ -17079,9 +15852,9 @@ snapshots:
fast-glob: 3.3.3
magic-string: 0.30.21
dependencies:
ansis: 4.2.0
error-stack-parser-es: 1.0.5
obug: 2.1.1
@@ -17090,31 +15863,31 @@ snapshots:
perfect-debounce: 2.1.0
sirv: 3.0.2
unplugin-utils: 0.3.1
transitivePeerDependencies:
- typescript
- ws
dependencies:
'@next/env': 16.0.0
image-size: 2.0.2
magic-string: 0.30.21
module-alias: 2.3.4
ts-dedent: 2.2.0
transitivePeerDependencies:
- supports-color
- typescript
dependencies:
'@oxc-project/types': 0.124.0
oxfmt: 0.45.0
oxlint: 1.60.0([email protected])
oxlint-tsgolint: 0.20.0
@@ -17157,66 +15930,74 @@ snapshots:
- vite
- yaml
dependencies:
debug: 4.4.3([email protected])
globrex: 0.1.2
tsconfck: 3.1.6([email protected])
optionalDependencies:
transitivePeerDependencies:
- supports-color
- typescript
dependencies:
debug: 4.4.3([email protected])
globrex: 0.1.2
tsconfck: 3.1.6([email protected])
transitivePeerDependencies:
- supports-color
- typescript
optionalDependencies:
-
- dependencies:
- cssfontparser: 1.2.1
- moo-color: 1.0.3
dependencies:
- '@vitest/expect': 4.1.4
- '@vitest/pretty-format': 4.1.4
- '@vitest/runner': 4.1.4
- '@vitest/snapshot': 4.1.4
- '@vitest/spy': 4.1.4
- '@vitest/utils': 4.1.4
- es-module-lexer: 2.0.0
- expect-type: 1.3.0
- magic-string: 0.30.21
- obug: 2.1.1
- pathe: 2.0.3
- picomatch: 4.0.4
- std-env: 4.0.0
- tinybench: 2.9.0
- tinyexec: 1.0.4
- tinyglobby: 0.2.16
- tinyrainbow: 3.1.0
- why-is-node-running: 2.3.0
+ react: 19.2.5
+ react-dom: 19.2.5([email protected])
optionalDependencies:
- '@types/node': 25.6.0
- '@vitest/coverage-v8': 4.1.4([email protected])
- happy-dom: 20.9.0
+ '@types/react': 19.2.14
+ '@types/react-dom': 19.2.3(@types/[email protected])
transitivePeerDependencies:
- - msw
- optional: true
+ - '@arethetypeswrong/core'
+ - '@edge-runtime/vm'
+ - '@opentelemetry/api'
+ - '@tsdown/css'
+ - '@tsdown/exe'
+ - '@types/node'
+ - '@vitejs/devtools'
+ - '@vitest/coverage-istanbul'
+ - '@vitest/coverage-v8'
+ - '@vitest/ui'
+ - bufferutil
+ - esbuild
+ - happy-dom
+ - jiti
+ - jsdom
+ - less
+ - publint
+ - sass
+ - sass-embedded
+ - stylus
+ - sugarss
+ - terser
+ - tsx
+ - typescript
+ - unplugin-unused
+ - utf-8-validate
+ - vite
+ - yaml
+
+ dependencies:
+ cssfontparser: 1.2.1
+ moo-color: 1.0.3
@@ -17251,11 +16032,6 @@ snapshots:
- dependencies:
- glob-to-regexp: 0.4.1
- graceful-fs: 4.2.11
-
@@ -17264,71 +16040,6 @@ snapshots:
- dependencies:
- '@types/eslint-scope': 3.7.7
- '@types/estree': 1.0.8
- '@types/json-schema': 7.0.15
- '@webassemblyjs/ast': 1.14.1
- '@webassemblyjs/wasm-edit': 1.14.1
- '@webassemblyjs/wasm-parser': 1.14.1
- acorn: 8.16.0
- acorn-import-phases: 1.0.4([email protected])
- browserslist: 4.28.1
- chrome-trace-event: 1.0.4
- enhanced-resolve: 5.20.1
- es-module-lexer: 2.0.0
- eslint-scope: 5.1.1
- events: 3.3.0
- glob-to-regexp: 0.4.1
- graceful-fs: 4.2.11
- json-parse-even-better-errors: 2.3.1
- loader-runner: 4.3.1
- mime-types: 2.1.35
- neo-async: 2.6.2
- schema-utils: 4.3.3
- tapable: 2.3.2
- terser-webpack-plugin: 5.4.0([email protected])([email protected]([email protected]))
- watchpack: 2.5.1
- webpack-sources: 3.3.4
- transitivePeerDependencies:
- - '@swc/core'
- - esbuild
- - uglify-js
- optional: true
-
- dependencies:
- '@types/eslint-scope': 3.7.7
- '@types/estree': 1.0.8
- '@types/json-schema': 7.0.15
- '@webassemblyjs/ast': 1.14.1
- '@webassemblyjs/wasm-edit': 1.14.1
- '@webassemblyjs/wasm-parser': 1.14.1
- acorn: 8.16.0
- acorn-import-phases: 1.0.4([email protected])
- browserslist: 4.28.1
- chrome-trace-event: 1.0.4
- enhanced-resolve: 5.20.1
- es-module-lexer: 2.0.0
- eslint-scope: 5.1.1
- events: 3.3.0
- glob-to-regexp: 0.4.1
- graceful-fs: 4.2.11
- json-parse-even-better-errors: 2.3.1
- loader-runner: 4.3.1
- mime-types: 2.1.35
- neo-async: 2.6.2
- schema-utils: 4.3.3
- tapable: 2.3.2
- watchpack: 2.5.1
- webpack-sources: 3.3.4
- transitivePeerDependencies:
- - '@swc/core'
- - esbuild
- - uglify-js
-
dependencies:
iconv-lite: 0.6.3
@@ -17341,12 +16052,6 @@ snapshots:
dependencies:
isexe: 2.0.0
- dependencies:
- siginfo: 2.0.0
- stackback: 0.0.2
- optional: true
-
@@ -17386,10 +16091,6 @@ snapshots:
buffer-crc32: 0.2.13
pend: 1.2.0
- dependencies:
- lib0: 0.2.117
-
diff --git a/pnpm-workspace.yaml b/pnpm-workspace.yaml
index 12fea26d685..3dd5b403a32 100644
--- a/pnpm-workspace.yaml
+++ b/pnpm-workspace.yaml
@@ -1,14 +1,51 @@
-packages:
- - web
- - e2e
- - sdks/nodejs-client
- - packages/*
allowBuilds:
'@parcel/watcher': false
canvas: false
esbuild: false
sharp: false
+autoInstallPeers: false
blockExoticSubdeps: true
+catalogMode: prefer
+shellEmulator: true
+strictDepBuilds: true
+trustPolicy: no-downgrade
+trustPolicyExclude:
+packages:
+ - web
+ - e2e
+ - sdks/nodejs-client
+ - packages/*
+overrides:
+ '@lexical/code': npm:[email protected]
+ '@monaco-editor/loader': 1.7.0
+ brace-expansion@>=2.0.0 <2.0.3: 2.0.3
+ canvas: ^3.2.2
+ dompurify@>=3.1.3 <=3.3.1: 3.3.2
+ esbuild@<0.27.2: 0.27.2
+ flatted@<=3.4.1: 3.4.2
+ glob@>=10.2.0 <10.5.0: 11.1.0
+ is-core-module: npm:@nolyfill/is-core-module@^1.0.39
+ lodash-es@>=4.0.0 <= 4.17.23: 4.18.0
+ lodash@>=4.0.0 <= 4.17.23: 4.18.0
+ picomatch@<2.3.2: 2.3.2
+ picomatch@>=4.0.0 <4.0.4: 4.0.4
+ rollup@>=4.0.0 <4.59.0: 4.59.0
+ safe-buffer: ^5.2.1
+ safer-buffer: npm:@nolyfill/safer-buffer@^1.0.44
+ side-channel: npm:@nolyfill/side-channel@^1.0.44
+ smol-toml@<1.6.1: 1.6.1
+ solid-js: 1.9.11
+ string-width: ~8.2.0
+ svgo@>=3.0.0 <3.3.3: 3.3.3
+ tar@<=7.5.10: 7.5.11
+ undici@>=7.0.0 <7.24.0: 7.24.0
+ vite: npm:@voidzero-dev/[email protected]
+ vitest: npm:@voidzero-dev/[email protected]
+ yaml@>=2.0.0 <2.8.3: 2.8.3
+ yauzl@<3.2.1: 3.2.1
catalog:
'@amplitude/analytics-browser': 2.39.0
'@amplitude/plugin-session-replay-browser': 1.27.7
@@ -16,7 +53,6 @@ catalog:
'@base-ui/react': 1.4.0
'@chromatic-com/storybook': 5.1.2
'@cucumber/cucumber': 12.8.0
- '@date-fns/tz': 1.4.1
'@egoist/tailwindcss-icons': 1.9.2
'@emoji-mart/data': 1.2.1
'@eslint-react/eslint-plugin': 3.0.0
@@ -73,7 +109,6 @@ catalog:
'@testing-library/jest-dom': 6.9.1
'@testing-library/react': 16.3.2
'@testing-library/user-event': 14.6.1
- '@tsdown/css': 0.21.8
'@tsslint/cli': 3.0.3
'@tsslint/compat-eslint': 3.0.3
'@tsslint/config': 3.0.3
@@ -81,7 +116,6 @@ catalog:
'@types/js-yaml': 4.0.9
'@types/negotiator': 0.6.4
'@types/node': 25.6.0
- '@types/postcss-js': 4.1.0
'@types/qs': 6.15.0
'@types/react': 19.2.14
'@types/react-dom': 19.2.3
@@ -95,7 +129,6 @@ catalog:
abcjs: 6.6.2
agentation: 3.0.2
ahooks: 3.9.7
- autoprefixer: 10.5.0
class-variance-authority: 0.7.1
client-only: 0.0.1
clsx: 2.1.1
@@ -103,7 +136,6 @@ catalog:
code-inspector-plugin: 1.5.1
copy-to-clipboard: 3.3.3
cron-parser: 5.5.0
- date-fns: 4.1.0
dayjs: 1.11.20
decimal.js: 10.6.0
dompurify: 3.4.0
@@ -152,8 +184,8 @@ catalog:
next-themes: 0.4.6
nuqs: 2.8.9
pinyin-pro: 3.28.1
+ playwright: 1.59.1
postcss: 8.5.9
- postcss-js: 5.1.0
qrcode.react: 4.2.0
qs: 6.15.1
react: 19.2.5
@@ -183,7 +215,6 @@ catalog:
tailwind-merge: 3.5.0
tailwindcss: 4.2.2
tldts: 7.0.28
- tsdown: 0.21.8
tsx: 4.21.0
typescript: 6.0.2
uglify-js: 3.19.3
@@ -195,42 +226,8 @@ catalog:
vite-plugin-inspect: 12.0.0-beta.1
vite-plus: 0.1.18
vitest: npm:@voidzero-dev/[email protected]
+ vitest-browser-react: 2.2.0
vitest-canvas-mock: 1.1.4
zod: 4.3.6
zundo: 2.3.0
zustand: 5.0.12
-catalogMode: prefer
-overrides:
- '@lexical/code': npm:[email protected]
- '@monaco-editor/loader': 1.7.0
- brace-expansion@>=2.0.0 <2.0.3: 2.0.3
- canvas: ^3.2.2
- dompurify@>=3.1.3 <=3.3.1: 3.3.2
- esbuild@<0.27.2: 0.27.2
- flatted@<=3.4.1: 3.4.2
- glob@>=10.2.0 <10.5.0: 11.1.0
- is-core-module: npm:@nolyfill/is-core-module@^1.0.39
- lodash-es@>=4.0.0 <= 4.17.23: 4.18.0
- lodash@>=4.0.0 <= 4.17.23: 4.18.0
- picomatch@<2.3.2: 2.3.2
- picomatch@>=4.0.0 <4.0.4: 4.0.4
- rollup@>=4.0.0 <4.59.0: 4.59.0
- safe-buffer: ^5.2.1
- safer-buffer: npm:@nolyfill/safer-buffer@^1.0.44
- side-channel: npm:@nolyfill/side-channel@^1.0.44
- smol-toml@<1.6.1: 1.6.1
- solid-js: 1.9.11
- string-width: ~8.2.0
- svgo@>=3.0.0 <3.3.3: 3.3.3
- tar@<=7.5.10: 7.5.11
- undici@>=7.0.0 <7.24.0: 7.24.0
- vite: npm:@voidzero-dev/[email protected]
- vitest: npm:@voidzero-dev/[email protected]
- yaml@>=2.0.0 <2.8.3: 2.8.3
- yauzl@<3.2.1: 3.2.1
-strictDepBuilds: true
-trustPolicy: no-downgrade
-trustPolicyExclude: