@loadsmart/loadsmart-ui 5.10.1 → 5.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Calendar/Calendar.stories.d.ts +2 -7
- package/dist/components/Calendar/Date.helper.d.ts +47 -12
- package/dist/components/Dropdown/Dropdown.stories.d.ts +4 -1
- package/dist/components/Loaders/LoadingBar.stories.d.ts +1 -1
- package/dist/index.js +64 -64
- package/dist/index.js.map +1 -1
- package/dist/tests/generator.d.ts +35 -0
- package/dist/tests/renderer.d.ts +10 -0
- package/package.json +1 -1
- package/src/components/Accordion/Accordion.stories.tsx +1 -1
- package/src/components/Accordion/Accordion.test.tsx +2 -2
- package/src/components/Banner/Banner.test.tsx +2 -2
- package/src/components/Breadcrumbs/Breadbrumbs.test.tsx +2 -2
- package/src/components/Button/Button.test.tsx +2 -2
- package/src/components/Calendar/Calendar.stories.tsx +4 -2
- package/src/components/Calendar/Calendar.test.tsx +3 -3
- package/src/components/Calendar/Date.helper.test.ts +463 -15
- package/src/components/Calendar/Date.helper.ts +106 -45
- package/src/components/Calendar/Pickers/DayPicker.test.tsx +2 -2
- package/src/components/Calendar/Pickers/MonthPicker.test.tsx +2 -2
- package/src/components/Calendar/Pickers/YearPicker.test.tsx +9 -7
- package/src/components/Card/Card.stories.tsx +1 -1
- package/src/components/Card/Card.test.tsx +2 -2
- package/src/components/Checkbox/Checkbox.test.tsx +2 -2
- package/src/components/DatePicker/DatePicker.test.tsx +2 -2
- package/src/components/DatePicker/DateRangePicker.stories.tsx +6 -1
- package/src/components/DatePicker/DateRangePicker.test.tsx +2 -2
- package/src/components/Dialog/Dialog.test.tsx +2 -2
- package/src/components/DragDropFile/components/DropZone.test.tsx +1 -1
- package/src/components/Drawer/Drawer.test.tsx +1 -1
- package/src/components/Dropdown/Dropdown.stories.tsx +10 -5
- package/src/components/Dropdown/Dropdown.test.tsx +14 -16
- package/src/components/EmptyState/EmptyState.test.tsx +1 -1
- package/src/components/ErrorMessage/ErrorMessage.test.tsx +1 -1
- package/src/components/HighlightMatch/HighlightMatch.test.tsx +1 -1
- package/src/components/IconFactory/IconFactory.test.tsx +2 -2
- package/src/components/Label/Label.test.tsx +2 -2
- package/src/components/Link/Link.test.tsx +2 -2
- package/src/components/Loaders/LoadingBar.stories.tsx +2 -2
- package/src/components/Loaders/LoadingBar.test.tsx +1 -1
- package/src/components/Loaders/LoadingDots.test.tsx +1 -1
- package/src/components/Loaders/Spinner.test.tsx +2 -2
- package/src/components/Modal/Modal.test.tsx +2 -2
- package/src/components/Pagination/Pagination.test.tsx +1 -1
- package/src/components/Popover/Popover.test.tsx +2 -2
- package/src/components/ProgressBar/ProgressBar.test.tsx +1 -1
- package/src/components/Radio/Radio.test.tsx +2 -2
- package/src/components/Section/Section.test.tsx +2 -2
- package/src/components/Section/Sections.stories.tsx +1 -1
- package/src/components/Select/Select.fixtures.ts +1 -1
- package/src/components/Select/Select.stories.tsx +2 -2
- package/src/components/Select/Select.test.tsx +12 -5
- package/src/components/Select/useSelect.helpers.test.ts +1 -1
- package/src/components/SideNavigation/Logo/Logo.test.tsx +2 -2
- package/src/components/SideNavigation/Menu/Menu.test.tsx +2 -2
- package/src/components/SideNavigation/Separator/Separator.test.tsx +1 -1
- package/src/components/SideNavigation/SideNavigation.test.tsx +2 -2
- package/src/components/Steps/Steps.fixtures.ts +1 -1
- package/src/components/Steps/Steps.test.tsx +2 -2
- package/src/components/Steps/useStep.test.tsx +1 -1
- package/src/components/Switch/Switch.test.tsx +1 -1
- package/src/components/Table/Table.fixtures.ts +1 -1
- package/src/components/Table/Table.test.tsx +1 -1
- package/src/components/TablePagination/TablePagination.test.tsx +1 -1
- package/src/components/Tabs/Tabs.test.tsx +1 -1
- package/src/components/Tag/Tag.stories.tsx +1 -1
- package/src/components/Tag/Tag.test.tsx +2 -2
- package/src/components/Text/Text.test.tsx +2 -2
- package/src/components/TextField/TextField.test.tsx +1 -1
- package/src/components/Textarea/Textarea.test.tsx +1 -1
- package/src/components/Toast/Toast.test.tsx +2 -2
- package/src/components/ToggleGroup/Toggle.test.tsx +2 -2
- package/src/components/ToggleGroup/ToggleGroup.test.tsx +2 -2
- package/src/components/Tooltip/Tooltip.test.tsx +2 -2
- package/src/components/TopNavigation/Logo/Logo.test.tsx +2 -2
- package/src/components/TopNavigation/Menu/Menu.test.tsx +1 -1
- package/src/components/VisuallyHidden/VisuallyHidden.test.tsx +1 -1
- package/src/hooks/useClickOutside/useClickOutside.test.tsx +1 -1
- package/src/hooks/useDidMount/useDidMount.test.tsx +1 -1
- package/src/hooks/useFocusTrap/useFocusTrap.test.tsx +1 -1
- package/src/hooks/useFocusWithin/useFocusWithin.test.tsx +1 -1
- package/src/hooks/useHeightExpansionToggler/useHeightExpansionToggler.test.tsx +1 -1
- package/src/hooks/useSelectable/SelectableStrategy.test.ts +1 -1
- package/src/hooks/useSelectable/useSelectable.test.ts +1 -1
- package/src/testing/SelectEvent/SelectEvent.test.tsx +2 -2
- package/src/tests/generator.ts +127 -0
- package/src/tests/renderer.tsx +39 -0
- package/src/tools/conditional.test.ts +1 -1
- package/src/utils/toolset/interleave.test.ts +1 -1
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
import { screen } from '@testing-library/react'
|
|
3
|
-
import renderer from '
|
|
3
|
+
import renderer from '../../tests/renderer'
|
|
4
4
|
import Link from './Link'
|
|
5
|
-
import generator from '
|
|
5
|
+
import generator from '../../tests/generator'
|
|
6
6
|
|
|
7
7
|
describe('<Link />', () => {
|
|
8
8
|
describe('default', () => {
|
|
@@ -2,7 +2,7 @@ import React from 'react'
|
|
|
2
2
|
import type { Story, Meta } from '@storybook/react/types-6-0'
|
|
3
3
|
import { Text } from 'components/Text'
|
|
4
4
|
|
|
5
|
-
import { LoadingBarProps } from './LoadingBar'
|
|
5
|
+
import type { LoadingBarProps } from './LoadingBar'
|
|
6
6
|
|
|
7
7
|
import LoadingBar from './LoadingBar'
|
|
8
8
|
|
|
@@ -12,7 +12,7 @@ export default {
|
|
|
12
12
|
argTypes: {},
|
|
13
13
|
} as Meta
|
|
14
14
|
|
|
15
|
-
export const Playground: Story<LoadingBarProps> = (args
|
|
15
|
+
export const Playground: Story<LoadingBarProps> = (args) => {
|
|
16
16
|
return (
|
|
17
17
|
<div className="flex flex-col space-y-2">
|
|
18
18
|
<div className="flex items-center">
|
|
@@ -2,7 +2,7 @@ import React from 'react'
|
|
|
2
2
|
import { composeStories } from '@storybook/testing-react'
|
|
3
3
|
|
|
4
4
|
import * as stories from './LoadingBar.stories'
|
|
5
|
-
import renderer, { screen } from '
|
|
5
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
6
6
|
|
|
7
7
|
import type { LoadingBarProps } from './LoadingBar'
|
|
8
8
|
|
|
@@ -2,7 +2,7 @@ import React from 'react'
|
|
|
2
2
|
import { composeStories } from '@storybook/testing-react'
|
|
3
3
|
|
|
4
4
|
import * as stories from './LoadingDots.stories'
|
|
5
|
-
import renderer, { screen } from '
|
|
5
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
6
6
|
|
|
7
7
|
import type { LoadingDotsProps } from './LoadingDots'
|
|
8
8
|
|
|
@@ -2,8 +2,8 @@ import React from 'react'
|
|
|
2
2
|
import { composeStories } from '@storybook/testing-react'
|
|
3
3
|
|
|
4
4
|
import * as stories from './Spinner.stories'
|
|
5
|
-
import generator from '
|
|
6
|
-
import renderer, { screen } from '
|
|
5
|
+
import generator from '../../tests/generator'
|
|
6
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
7
7
|
|
|
8
8
|
import type { SpinnerProps } from './Spinner'
|
|
9
9
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
|
|
3
3
|
import Modal from './Modal'
|
|
4
|
-
import generator from '
|
|
5
|
-
import renderer, { screen, user } from '
|
|
4
|
+
import generator from '../../tests/generator'
|
|
5
|
+
import renderer, { screen, user } from '../../tests/renderer'
|
|
6
6
|
|
|
7
7
|
const setup = ({ open = false, ...overrides }) =>
|
|
8
8
|
renderer(<Modal open={open} {...overrides} />).render()
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import userEvent from '@testing-library/user-event'
|
|
2
2
|
import React from 'react'
|
|
3
3
|
|
|
4
|
-
import renderer, { screen, fire } from '
|
|
4
|
+
import renderer, { screen, fire } from '../../tests/renderer'
|
|
5
5
|
|
|
6
6
|
import Pagination from './Pagination'
|
|
7
7
|
import type { PaginationProps } from './Pagination.types'
|
|
@@ -2,8 +2,8 @@ import React from 'react'
|
|
|
2
2
|
import { composeStories } from '@storybook/testing-react'
|
|
3
3
|
|
|
4
4
|
import * as stories from './Popover.stories'
|
|
5
|
-
import generator from '
|
|
6
|
-
import renderer, { screen } from '
|
|
5
|
+
import generator from '../../tests/generator'
|
|
6
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
7
7
|
|
|
8
8
|
import type { PopoverProps } from './Popover'
|
|
9
9
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
|
|
3
3
|
import Radio from './Radio'
|
|
4
|
-
import generator from '
|
|
5
|
-
import renderer, { fire } from '
|
|
4
|
+
import generator from '../../tests/generator'
|
|
5
|
+
import renderer, { fire } from '../../tests/renderer'
|
|
6
6
|
|
|
7
7
|
const setup = ({ ...overrides }) => renderer(<Radio {...overrides} />).render()
|
|
8
8
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React, { Fragment } from 'react'
|
|
2
2
|
|
|
3
|
-
import generator from '
|
|
4
|
-
import renderer, { screen } from '
|
|
3
|
+
import generator from '../../tests/generator'
|
|
4
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
5
5
|
|
|
6
6
|
import Section from './Section'
|
|
7
7
|
|
|
@@ -3,7 +3,7 @@ import type { Meta } from '@storybook/react/types-6-0'
|
|
|
3
3
|
import Section from './Section'
|
|
4
4
|
import type { SectionProps } from './Section'
|
|
5
5
|
|
|
6
|
-
import generator from '
|
|
6
|
+
import generator from '../../tests/generator'
|
|
7
7
|
|
|
8
8
|
export default {
|
|
9
9
|
title: 'Components/Section',
|
|
@@ -15,7 +15,7 @@ import type {
|
|
|
15
15
|
SelectProps,
|
|
16
16
|
} from './Select.types'
|
|
17
17
|
import { useSelect } from '.'
|
|
18
|
-
import generators from '
|
|
18
|
+
import generators from '../../tests/generator'
|
|
19
19
|
|
|
20
20
|
export default {
|
|
21
21
|
title: 'Components/Select',
|
|
@@ -32,7 +32,7 @@ export const Playground: Story<SelectProps> = (args: SelectProps) => {
|
|
|
32
32
|
<div className="flex-1">
|
|
33
33
|
<Label htmlFor="select-playground">Select your favorite fruit</Label>
|
|
34
34
|
<Select
|
|
35
|
-
options={FRUITS}
|
|
35
|
+
options={[...FRUITS]}
|
|
36
36
|
placeholder="Select sync"
|
|
37
37
|
{...omit(args, OMITTED_PROPS)}
|
|
38
38
|
id="select-playground"
|
|
@@ -5,8 +5,8 @@ import { render } from '@testing-library/react'
|
|
|
5
5
|
|
|
6
6
|
import { SelectableKeyTypeOptions, Fruit, FRUITS, USERS } from './Select.fixtures'
|
|
7
7
|
import * as stories from './Select.stories'
|
|
8
|
-
import generator from '
|
|
9
|
-
import renderer, { screen, fire, waitFor } from '
|
|
8
|
+
import generator from '../../tests/generator'
|
|
9
|
+
import renderer, { screen, fire, waitFor } from '../../tests/renderer'
|
|
10
10
|
import selectEvent from '../../testing/SelectEvent'
|
|
11
11
|
|
|
12
12
|
import type { SelectProps, Option } from './Select.types'
|
|
@@ -322,7 +322,10 @@ describe('Select', () => {
|
|
|
322
322
|
const searchInput = screen.getByLabelText('Select your favorite fruit')
|
|
323
323
|
await selectEvent.select(firstOption.label, searchInput)
|
|
324
324
|
|
|
325
|
-
|
|
325
|
+
await waitFor(() => {
|
|
326
|
+
expect(screen.getByTestId('select-trigger-clear-counter')).toHaveTextContent('1')
|
|
327
|
+
})
|
|
328
|
+
|
|
326
329
|
expect(screen.getByTitle('1 selected option')).toBeInTheDocument()
|
|
327
330
|
|
|
328
331
|
await selectEvent.select(secondOption.label, searchInput)
|
|
@@ -346,7 +349,9 @@ describe('Select', () => {
|
|
|
346
349
|
const searchInput = screen.getByLabelText('Select your favorite fruit')
|
|
347
350
|
expect(await selectEvent.getSelectedOptions(searchInput)).toHaveLength(3)
|
|
348
351
|
|
|
349
|
-
|
|
352
|
+
await waitFor(() => {
|
|
353
|
+
expect(screen.getByTestId('select-trigger-clear-counter')).toHaveTextContent('3')
|
|
354
|
+
})
|
|
350
355
|
|
|
351
356
|
await selectEvent.unselect(secondOption.label, searchInput)
|
|
352
357
|
|
|
@@ -366,7 +371,9 @@ describe('Select', () => {
|
|
|
366
371
|
const searchInput = screen.getByLabelText('Select your favorite fruit')
|
|
367
372
|
expect(await selectEvent.getSelectedOptions(searchInput)).toHaveLength(3)
|
|
368
373
|
|
|
369
|
-
|
|
374
|
+
await waitFor(() => {
|
|
375
|
+
expect(screen.getByTestId('select-trigger-clear-counter')).toHaveTextContent('3')
|
|
376
|
+
})
|
|
370
377
|
|
|
371
378
|
await selectEvent.clear(searchInput)
|
|
372
379
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
|
|
3
3
|
import { Logo } from './'
|
|
4
|
-
import renderer, { screen } from '
|
|
5
|
-
import generator from '
|
|
4
|
+
import renderer, { screen } from '../../../tests/renderer'
|
|
5
|
+
import generator from '../../../tests/generator'
|
|
6
6
|
import type { LogoProps } from './Logo'
|
|
7
7
|
|
|
8
8
|
const setup = ({ ...overrides }: LogoProps) => renderer(<Logo {...overrides} />).render()
|
|
@@ -2,8 +2,8 @@ import React from 'react'
|
|
|
2
2
|
|
|
3
3
|
import { Menu } from './'
|
|
4
4
|
import type { MenuProps } from './Menu'
|
|
5
|
-
import renderer, { screen } from '
|
|
6
|
-
import generator from '
|
|
5
|
+
import renderer, { screen } from '../../../tests/renderer'
|
|
6
|
+
import generator from '../../../tests/generator'
|
|
7
7
|
import userEvent from '@testing-library/user-event'
|
|
8
8
|
|
|
9
9
|
function setup(props: MenuProps) {
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
|
|
3
3
|
import { SideNavigation } from './'
|
|
4
|
-
import renderer from '
|
|
5
|
-
import generator from '
|
|
4
|
+
import renderer from '../../tests/renderer'
|
|
5
|
+
import generator from '../../tests/generator'
|
|
6
6
|
import type { SideNavigationProps } from './SideNavigation'
|
|
7
7
|
|
|
8
8
|
function setup(props: SideNavigationProps) {
|
|
@@ -2,9 +2,9 @@ import React from 'react'
|
|
|
2
2
|
import { composeStory } from '@storybook/testing-react'
|
|
3
3
|
|
|
4
4
|
import { STEPS, CONTENTS } from './Steps.fixtures'
|
|
5
|
-
import generator from '
|
|
5
|
+
import generator from '../../tests/generator'
|
|
6
6
|
import Meta, { Playground as PlaygroundStory } from './Steps.stories'
|
|
7
|
-
import renderer, { screen } from '
|
|
7
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
8
8
|
|
|
9
9
|
import type { StepsProps } from './Steps'
|
|
10
10
|
import type { Step } from './Steps.types'
|
|
@@ -3,7 +3,7 @@ import { composeStories } from '@storybook/testing-react'
|
|
|
3
3
|
import userEvent from '@testing-library/user-event'
|
|
4
4
|
|
|
5
5
|
import * as stories from './Switch.stories'
|
|
6
|
-
import renderer, { screen } from '
|
|
6
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
7
7
|
import type { SwitchProps } from './Switch'
|
|
8
8
|
|
|
9
9
|
const { Playground } = composeStories(stories)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/* eslint-disable @typescript-eslint/no-unsafe-return */
|
|
2
2
|
import React from 'react'
|
|
3
|
-
import renderer, { screen, user } from '
|
|
3
|
+
import renderer, { screen, user } from '../../tests/renderer'
|
|
4
4
|
|
|
5
5
|
import Table from './Table'
|
|
6
6
|
import type { TableProps } from './Table.types'
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import userEvent from '@testing-library/user-event'
|
|
2
2
|
import React from 'react'
|
|
3
3
|
|
|
4
|
-
import renderer, { screen } from '
|
|
4
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
5
5
|
|
|
6
6
|
import TablePagination from './TablePagination'
|
|
7
7
|
import type { TablePaginationProps } from './TablePagination.types'
|
|
@@ -3,7 +3,7 @@ import Tag, { TagProps } from './Tag'
|
|
|
3
3
|
import type { Meta } from '@storybook/react/types-6-0'
|
|
4
4
|
|
|
5
5
|
import { Icon as MirandaIcon } from '../Icon'
|
|
6
|
-
import generator from '
|
|
6
|
+
import generator from '../../tests/generator'
|
|
7
7
|
|
|
8
8
|
export default {
|
|
9
9
|
title: 'Components/Tag',
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
|
|
3
3
|
import Tag from './Tag'
|
|
4
|
-
import generator from '
|
|
5
|
-
import renderer from '
|
|
4
|
+
import generator from '../../tests/generator'
|
|
5
|
+
import renderer from '../../tests/renderer'
|
|
6
6
|
|
|
7
7
|
const setup = ({ ...overrides }) => renderer(<Tag {...overrides} />).render()
|
|
8
8
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
|
|
3
|
-
import renderer, { screen } from '
|
|
4
|
-
import generators from '
|
|
3
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
4
|
+
import generators from '../../tests/generator'
|
|
5
5
|
import typography from '../../styles/typography'
|
|
6
6
|
|
|
7
7
|
import { Text } from '.'
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
import { screen } from '@testing-library/react'
|
|
3
3
|
|
|
4
|
-
import renderer from '
|
|
5
|
-
import generator from '
|
|
4
|
+
import renderer from '../../tests/renderer'
|
|
5
|
+
import generator from '../../tests/generator'
|
|
6
6
|
|
|
7
7
|
import Toast from './Toast'
|
|
8
8
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
|
|
3
|
-
import generator from '
|
|
4
|
-
import renderer, { screen, fire } from '
|
|
3
|
+
import generator from '../../tests/generator'
|
|
4
|
+
import renderer, { screen, fire } from '../../tests/renderer'
|
|
5
5
|
import Toggle from './Toggle'
|
|
6
6
|
import ToggleGroupContext, { SelectableContext } from './ToggleGroupContext'
|
|
7
7
|
|
|
@@ -3,8 +3,8 @@ import { composeStories } from '@storybook/testing-react'
|
|
|
3
3
|
|
|
4
4
|
import { OPTIONS } from './ToggleGroup.constants'
|
|
5
5
|
import * as stories from './ToggleGroup.stories'
|
|
6
|
-
import generator from '
|
|
7
|
-
import renderer, { screen, fire } from '
|
|
6
|
+
import generator from '../../tests/generator'
|
|
7
|
+
import renderer, { screen, fire } from '../../tests/renderer'
|
|
8
8
|
|
|
9
9
|
import type { ToggleGroupProps, ToggleGroupOptionProps } from './ToggleGroup.types'
|
|
10
10
|
|
|
@@ -3,8 +3,8 @@ import { screen } from '@testing-library/react'
|
|
|
3
3
|
import userEvent from '@testing-library/user-event'
|
|
4
4
|
|
|
5
5
|
import Tooltip from './Tooltip'
|
|
6
|
-
import generator from '
|
|
7
|
-
import renderer from '
|
|
6
|
+
import generator from '../../tests/generator'
|
|
7
|
+
import renderer from '../../tests/renderer'
|
|
8
8
|
|
|
9
9
|
const setup = ({ ...overrides }) => renderer(<Tooltip message="" {...overrides} />).render()
|
|
10
10
|
|
|
@@ -2,8 +2,8 @@ import React from 'react'
|
|
|
2
2
|
|
|
3
3
|
import { Logo } from './'
|
|
4
4
|
import type { LogoProps } from './Logo'
|
|
5
|
-
import renderer, { screen } from '
|
|
6
|
-
import generators from '
|
|
5
|
+
import renderer, { screen } from '../../../tests/renderer'
|
|
6
|
+
import generators from '../../../tests/generator'
|
|
7
7
|
|
|
8
8
|
function setup(props: LogoProps) {
|
|
9
9
|
return renderer(<Logo {...props} />).render()
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
import { ThemeProvider } from 'styled-components'
|
|
3
|
-
import renderer, { screen, user } from '
|
|
3
|
+
import renderer, { screen, user } from '../../../tests/renderer'
|
|
4
4
|
import { Menu } from './'
|
|
5
5
|
import type { MenuProps } from './Menu'
|
|
6
6
|
import { Alice } from '../../../theming/themes'
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
2
|
import { screen } from '@testing-library/react'
|
|
3
3
|
|
|
4
|
-
import renderer from '
|
|
4
|
+
import renderer from '../../tests/renderer'
|
|
5
5
|
|
|
6
6
|
import hiddenStyle from 'styles/hidden'
|
|
7
7
|
import { VisuallyHidden } from './VisuallyHidden'
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react'
|
|
2
|
-
import renderer, { screen, fire, user } from '
|
|
2
|
+
import renderer, { screen, fire, user } from '../../tests/renderer'
|
|
3
3
|
import { composeStories } from '@storybook/testing-react'
|
|
4
4
|
|
|
5
5
|
import * as stories from './useFocusTrap.stories'
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { act, waitFor } from '@testing-library/react'
|
|
2
2
|
import React, { useRef, useState } from 'react'
|
|
3
3
|
|
|
4
|
-
import renderer, { screen, fire, user } from '
|
|
4
|
+
import renderer, { screen, fire, user } from '../../tests/renderer'
|
|
5
5
|
|
|
6
6
|
import useHeightExpansionToggler from './useHeightExpansionToggler'
|
|
7
7
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { renderHook, act } from '@testing-library/react-hooks'
|
|
2
2
|
|
|
3
3
|
import { createSelectable } from './useSelectable'
|
|
4
|
-
import generator from '
|
|
4
|
+
import generator from '../../tests/generator'
|
|
5
5
|
|
|
6
6
|
import type { Selectable, SelectableAdapter, SelectableKeyType } from './useSelectable.types'
|
|
7
7
|
|
|
@@ -7,8 +7,8 @@ import {
|
|
|
7
7
|
useSyncFruits,
|
|
8
8
|
useAsyncUsers,
|
|
9
9
|
} from '../../components/Select/Select.fixtures'
|
|
10
|
-
import generator from '
|
|
11
|
-
import renderer, { screen } from '
|
|
10
|
+
import generator from '../../tests/generator'
|
|
11
|
+
import renderer, { screen } from '../../tests/renderer'
|
|
12
12
|
import Select from '../../components/Select/Select'
|
|
13
13
|
|
|
14
14
|
import selectEvent from './SelectEvent'
|