@pexip/components 20.0.0 → 20.2.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/CHANGELOG.md +204 -0
- package/api-docs/README.mdx +11 -2
- package/api-docs/enumerations/TestId.mdx +1 -0
- package/api-docs/functions/announce.mdx +1 -1
- package/api-docs/functions/onEnter.mdx +3 -3
- package/api-docs/functions/sizeToPadding.mdx +16 -6
- package/api-docs/functions/useBoundingRect.mdx +42 -0
- package/api-docs/functions/useBreakpointChange.mdx +1 -1
- package/api-docs/functions/useFocusFrom.mdx +2 -2
- package/api-docs/functions/useFocusFromOpened.mdx +1 -1
- package/api-docs/functions/useGroupedPagesNav.mdx +2 -2
- package/api-docs/functions/useInput.mdx +4 -2
- package/api-docs/functions/useModal.mdx +2 -2
- package/api-docs/functions/useModalHandle.mdx +1 -1
- package/api-docs/functions/useModalWithoutPreventScroll.mdx +2 -2
- package/api-docs/functions/useMultistepIndicator.mdx +24 -8
- package/api-docs/functions/useOutOfViewNavigation.mdx +4 -4
- package/api-docs/functions/useScrollIntoView.mdx +3 -3
- package/api-docs/functions/useTabs.mdx +1 -1
- package/api-docs/functions/withColorScheme.mdx +3 -3
- package/api-docs/functions/withTabName.mdx +2 -2
- package/api-docs/functions/withTransition.mdx +6 -4
- package/api-docs/interfaces/FullSizeWindowCommonProps.mdx +4 -4
- package/api-docs/interfaces/IconCollection.mdx +7 -0
- package/api-docs/interfaces/IconSource.mdx +3 -3
- package/api-docs/interfaces/LoadingBoxProps.mdx +5 -3
- package/api-docs/interfaces/ModalHandle.mdx +1 -1
- package/api-docs/interfaces/MultistepItem.mdx +1 -1
- package/api-docs/interfaces/StatCardRowData.mdx +5 -5
- package/api-docs/interfaces/ToastProps.mdx +3 -3
- package/api-docs/interfaces/VideoHandle.mdx +2 -2
- package/api-docs/interfaces/WithTransitionProps.mdx +1 -0
- package/api-docs/type-aliases/ActivityCardAction.mdx +1 -1
- package/api-docs/type-aliases/AriaMenuItem.mdx +9 -1
- package/api-docs/type-aliases/AriaMenuProps.mdx +5 -1
- package/api-docs/type-aliases/AriaSubMenu.mdx +27 -0
- package/api-docs/type-aliases/AriaSubMenuContentHelpers.mdx +13 -0
- package/api-docs/type-aliases/BreadcrumbItem.mdx +1 -1
- package/api-docs/type-aliases/ClickEventHandler.mdx +1 -1
- package/api-docs/type-aliases/MenuAction.mdx +1 -1
- package/api-docs/type-aliases/MenuItem.mdx +5 -4
- package/api-docs/type-aliases/MultiselectCoreProps.mdx +3 -0
- package/api-docs/type-aliases/MultiselectOption.mdx +1 -1
- package/api-docs/type-aliases/NotificationToastMessage.mdx +1 -1
- package/api-docs/type-aliases/NotificationTooltipPosition.mdx +3 -1
- package/api-docs/type-aliases/NotificationTooltipProps.mdx +3 -0
- package/api-docs/type-aliases/Option.mdx +1 -1
- package/api-docs/type-aliases/SelectProps.mdx +3 -3
- package/api-docs/type-aliases/TagItem.mdx +2 -2
- package/api-docs/variables/AriaMenu.mdx +3 -1
- package/api-docs/variables/Draggable.mdx +51 -0
- package/api-docs/variables/KEYBOARD_EVENT_KEY.mdx +16 -0
- package/api-docs/variables/MultiselectCore.mdx +27 -0
- package/api-docs/variables/MultistepIndicator.mdx +1 -0
- package/api-docs/variables/PreferenceInput.mdx +1 -0
- package/api-docs/variables/Select.mdx +2 -2
- package/api-docs/variables/Sheet.mdx +9 -1
- package/api-docs/variables/Toast.mdx +3 -1
- package/api-docs/variables/ToggleSwitchDisplay.mdx +16 -0
- package/api-docs/variables/buttonVariantsValues.mdx +3 -0
- package/design-tokens/mixins/_focus.scss +54 -10
- package/design-tokens/mixins/media-queries.scss +12 -0
- package/design-tokens/variables.legacy.scss +8 -0
- package/dist/components-no-global-styles.css +1 -1
- package/dist/components.cjs +2 -2
- package/dist/components.css +1 -1
- package/dist/components.js +6253 -8056
- package/dist/types/design-tokens/generated/Icons.d.ts +7 -0
- package/dist/types/design-tokens/generated/Icons.d.ts.map +1 -1
- package/dist/types/src/components/elements/ActionsRow/ActionsRow.d.ts +1 -0
- package/dist/types/src/components/elements/ActionsRow/ActionsRow.d.ts.map +1 -1
- package/dist/types/src/components/elements/Checkbox/Checkbox.d.ts.map +1 -1
- package/dist/types/src/components/elements/Draggable/Draggable.view.d.ts +43 -0
- package/dist/types/src/components/elements/Draggable/Draggable.view.d.ts.map +1 -1
- package/dist/types/src/components/elements/Input/Input.d.ts +1 -0
- package/dist/types/src/components/elements/Input/Input.d.ts.map +1 -1
- package/dist/types/src/components/elements/ListBoxLink/ListBoxLink.d.ts +2 -2
- package/dist/types/src/components/elements/ListBoxLink/ListBoxLink.d.ts.map +1 -1
- package/dist/types/src/components/elements/ListLink/ListLink.d.ts +8 -5
- package/dist/types/src/components/elements/ListLink/ListLink.d.ts.map +1 -1
- package/dist/types/src/components/elements/Panel/Panel.d.ts +1 -0
- package/dist/types/src/components/elements/Panel/Panel.d.ts.map +1 -1
- package/dist/types/src/components/elements/Scrollbars/Scrollbars.d.ts +0 -1
- package/dist/types/src/components/elements/Scrollbars/Scrollbars.d.ts.map +1 -1
- package/dist/types/src/components/elements/ToggleSwitch/ToggleSwitch.d.ts.map +1 -1
- package/dist/types/src/components/elements/ToggleSwitch/ToggleSwitchDisplay.d.ts +28 -0
- package/dist/types/src/components/elements/ToggleSwitch/ToggleSwitchDisplay.d.ts.map +1 -0
- package/dist/types/src/components/elements/Tooltip/NotificationTooltip.d.ts +1 -2
- package/dist/types/src/components/elements/Tooltip/NotificationTooltip.d.ts.map +1 -1
- package/dist/types/src/components/elements/Tooltip/Tooltip.d.ts.map +1 -1
- package/dist/types/src/components/modules/AriaMenu/AriaMenu.d.ts +3 -1
- package/dist/types/src/components/modules/AriaMenu/AriaMenu.d.ts.map +1 -1
- package/dist/types/src/components/modules/AriaMenu/AriaMenu.types.d.ts +121 -1
- package/dist/types/src/components/modules/AriaMenu/AriaMenu.types.d.ts.map +1 -1
- package/dist/types/src/components/modules/AriaMenu/InnerAriaMenu.d.ts +32 -4
- package/dist/types/src/components/modules/AriaMenu/InnerAriaMenu.d.ts.map +1 -1
- package/dist/types/src/components/modules/AriaMenu/InnerAriaMenuButton.d.ts +3 -6
- package/dist/types/src/components/modules/AriaMenu/InnerAriaMenuButton.d.ts.map +1 -1
- package/dist/types/src/components/modules/AriaMenu/InnerAriaMenuItem.d.ts +3 -0
- package/dist/types/src/components/modules/AriaMenu/InnerAriaMenuItem.d.ts.map +1 -1
- package/dist/types/src/components/modules/AriaMenu/InnerAriaMenuNavigator.d.ts +22 -0
- package/dist/types/src/components/modules/AriaMenu/InnerAriaMenuNavigator.d.ts.map +1 -0
- package/dist/types/src/components/modules/AriaMenu/InnerAriaMenuPopover.d.ts.map +1 -1
- package/dist/types/src/components/modules/Avatar/Avatar.utils.d.ts +2 -2
- package/dist/types/src/components/modules/Avatar/Avatar.utils.d.ts.map +1 -1
- package/dist/types/src/components/modules/Captions/Captions.view.d.ts +1 -0
- package/dist/types/src/components/modules/Captions/Captions.view.d.ts.map +1 -1
- package/dist/types/src/components/modules/CondensedTabs/CondensedTabs.view.d.ts +1 -0
- package/dist/types/src/components/modules/CondensedTabs/CondensedTabs.view.d.ts.map +1 -1
- package/dist/types/src/components/modules/ConfirmationModal/ConfirmationModal.d.ts +2 -0
- package/dist/types/src/components/modules/ConfirmationModal/ConfirmationModal.d.ts.map +1 -1
- package/dist/types/src/components/modules/DropContent/DropContent.d.ts.map +1 -1
- package/dist/types/src/components/modules/Menu/Menu.d.ts +3 -1
- package/dist/types/src/components/modules/Menu/Menu.d.ts.map +1 -1
- package/dist/types/src/components/modules/Menu/types.d.ts +4 -2
- package/dist/types/src/components/modules/Menu/types.d.ts.map +1 -1
- package/dist/types/src/components/modules/Modal/Modal.d.ts +2 -0
- package/dist/types/src/components/modules/Modal/Modal.d.ts.map +1 -1
- package/dist/types/src/components/modules/Multiselect/ConfirmableMultiselect.d.ts.map +1 -1
- package/dist/types/src/components/modules/Multiselect/Multiselect.d.ts +8 -0
- package/dist/types/src/components/modules/Multiselect/Multiselect.d.ts.map +1 -1
- package/dist/types/src/components/modules/Multiselect/MultiselectCore.d.ts.map +1 -1
- package/dist/types/src/components/modules/MultistepIndicator/MultistepIndicator.d.ts +1 -0
- package/dist/types/src/components/modules/MultistepIndicator/MultistepIndicator.d.ts.map +1 -1
- package/dist/types/src/components/modules/MultistepIndicator/MultistepIndicator.utils.d.ts +1 -2
- package/dist/types/src/components/modules/MultistepIndicator/MultistepIndicator.utils.d.ts.map +1 -1
- package/dist/types/src/components/modules/MultistepIndicator/OrdinalText.view.d.ts.map +1 -1
- package/dist/types/src/components/modules/PopOutWindow/PopOutWindow.d.ts.map +1 -1
- package/dist/types/src/components/modules/PopOutWindow/copyStyles.d.ts +23 -0
- package/dist/types/src/components/modules/PopOutWindow/copyStyles.d.ts.map +1 -0
- package/dist/types/src/components/modules/PreferenceInput/PreferenceInput.d.ts +2 -0
- package/dist/types/src/components/modules/PreferenceInput/PreferenceInput.d.ts.map +1 -1
- package/dist/types/src/components/modules/Sheet/Sheet.d.ts +12 -1
- package/dist/types/src/components/modules/Sheet/Sheet.d.ts.map +1 -1
- package/dist/types/src/components/modules/TransitionContainer/withTransition.d.ts +1 -0
- package/dist/types/src/components/modules/TransitionContainer/withTransition.d.ts.map +1 -1
- package/dist/types/src/constants/keyboard.d.ts +2 -0
- package/dist/types/src/constants/keyboard.d.ts.map +1 -1
- package/dist/types/src/exports.d.ts +8 -1
- package/dist/types/src/exports.d.ts.map +1 -1
- package/dist/types/src/hooks/useAriaTooltip.d.ts +9 -3
- package/dist/types/src/hooks/useAriaTooltip.d.ts.map +1 -1
- package/dist/types/src/hooks/useBoundingRect.d.ts +27 -0
- package/dist/types/src/hooks/useBoundingRect.d.ts.map +1 -0
- package/dist/types/src/types/sizes.d.ts +1 -1
- package/dist/types/src/types/sizes.d.ts.map +1 -1
- package/dist/types/src/utils/imageSrc.d.ts +1 -1
- package/dist/types/src/utils/testIds.d.ts +1 -0
- package/dist/types/src/utils/testIds.d.ts.map +1 -1
- package/package.json +15 -26
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,209 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 20.2.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- bb40023: Add optional `hasDivider` prop to `ActionsRow` component. Defaults to
|
|
8
|
+
`true` to preserve existing behavior. Set to `false` to hide the divider.
|
|
9
|
+
- 54883ee: Add `IconSupportAgent` and `IconTranslation`.
|
|
10
|
+
- ca742b0: Fix shrinking icon in `ListLink`. Support `fontVariant` in
|
|
11
|
+
`PlainMenuEntry` in `Menu`.
|
|
12
|
+
- 35a460a: Add `descriptionUrlLinks` prop to `ConfirmationModal` to control
|
|
13
|
+
whether URLs in the description are rendered as clickable links
|
|
14
|
+
- db2c663: Add `presentationElementClassName` prop to `Modal`.
|
|
15
|
+
- cbe8f20: Export `MultiselectCore` so apps can reuse the shared select trigger
|
|
16
|
+
with a custom menu.
|
|
17
|
+
- 593d327: Add nested submenu support to `AriaMenu`, including:
|
|
18
|
+
|
|
19
|
+
- Item and custom-content submenus
|
|
20
|
+
- Configurable back navigation
|
|
21
|
+
- Accessible labelling and keyboard navigation
|
|
22
|
+
- Focus restoration and scrollable overflow
|
|
23
|
+
- Optional submenu indicators and trailing icons
|
|
24
|
+
|
|
25
|
+
Also expose scrollbar styling on `Panel` and keep portalled tooltips
|
|
26
|
+
interactive inside React Aria overlays.
|
|
27
|
+
|
|
28
|
+
- 031693b: Export `buttonVariantsValues`.
|
|
29
|
+
- 81f985c: Add `titleWordBreak` prop to `ConfirmationModal`
|
|
30
|
+
- 27917fb: Add `ToggleSwitchDisplay` presentational component for rendering
|
|
31
|
+
toggle state without interactive elements. Refactor `ToggleSwitch` to compose
|
|
32
|
+
`ToggleSwitchDisplay` internally.
|
|
33
|
+
- ee5a093: Hand tooltip positioning over to react-aria's `useOverlayPosition`.
|
|
34
|
+
|
|
35
|
+
- `Tooltip`, `CustomTooltip` and `NotificationTooltip` are now positioned,
|
|
36
|
+
flipped and kept inside the viewport by react-aria instead of hard-coded CSS
|
|
37
|
+
offsets. This fixes tooltips escaping the viewport, e.g. at 400% browser
|
|
38
|
+
zoom.
|
|
39
|
+
- The arrow is placed with react-aria's `arrowProps` and oriented with the
|
|
40
|
+
resolved `data-placement`, so it stays attached to and pointing at the
|
|
41
|
+
trigger.
|
|
42
|
+
- The CSS placement classes on the tooltip content were removed in favour of
|
|
43
|
+
`data-placement`.
|
|
44
|
+
- The in-meeting control tooltips now hide with the rest of the UI when it
|
|
45
|
+
auto-hides, which they no longer inherited once portalled.
|
|
46
|
+
- **Breaking:** the `usePortal` prop was removed from `NotificationTooltip`;
|
|
47
|
+
the tooltip is always rendered in a portal.
|
|
48
|
+
|
|
49
|
+
- e4a320d: Add renderText prop to PreferenceInput to allow replacing the value's
|
|
50
|
+
Text element
|
|
51
|
+
|
|
52
|
+
### Patch Changes
|
|
53
|
+
|
|
54
|
+
- 8ef9f04: `AriaMenu` items accept an `isChecked` prop, which renders the item
|
|
55
|
+
as a `menuitemcheckbox` and reports its state. Use it for items that toggle
|
|
56
|
+
something, so the state is announced on the focusable item rather than on a
|
|
57
|
+
presentational control inside it.
|
|
58
|
+
- b1f3f9e: Improve accessible danger styling for shared menu and select
|
|
59
|
+
components. AriaMenu now supports a danger state for menu items, and Select
|
|
60
|
+
updates its danger tokens to use higher-contrast colors.
|
|
61
|
+
- 3e652a1: Update Captions header layout to show speakers on the left with
|
|
62
|
+
ellipsis truncation and timestamp on the right. Add `timestamp` prop for
|
|
63
|
+
`Captions` component.
|
|
64
|
+
- 8ef9f04: `CondensedTabs` now exposes its selected state to assistive
|
|
65
|
+
technology. Tabs carry `aria-selected`, the tablist is a single tab stop with
|
|
66
|
+
a roving `tabindex`, and arrow/Home/End keys move between tabs.
|
|
67
|
+
- 380b19c: Draggable: added support for [data-drag-handle] and [data-no-drag]
|
|
68
|
+
regions — pointer-down inside a no-drag region is ignored unless it originates
|
|
69
|
+
from a drag handle, with matching grab/grabbing cursor styling.
|
|
70
|
+
|
|
71
|
+
AriaMenu: menu items now support an optional description rendered below the
|
|
72
|
+
label; preventFocusOnPress is stripped from the DOM button props.
|
|
73
|
+
|
|
74
|
+
Modal: added withAlternativeMaskColor prop and a new
|
|
75
|
+
alternative-modal-mask-color token.
|
|
76
|
+
|
|
77
|
+
Sheet: added withMask, withShadow, innerFullHeight, and custom
|
|
78
|
+
heightPortrait/heightLandscape (dvh) props with orientation-based media
|
|
79
|
+
queries.
|
|
80
|
+
|
|
81
|
+
Added a new md (36px) avatar/circle size (Avatar, RoundIndicator, sizes,
|
|
82
|
+
design tokens) and an $alpha-70 token.
|
|
83
|
+
|
|
84
|
+
Added and exported a new useBoundingRect hook (observes an element's bounding
|
|
85
|
+
rect via ResizeObserver, polls ref.current, with optional
|
|
86
|
+
window-resize/orientation updates); also exported the KEYBOARD_EVENT_KEY
|
|
87
|
+
constant.
|
|
88
|
+
|
|
89
|
+
Scrollbars: removed the redundant children prop from its type.
|
|
90
|
+
|
|
91
|
+
- 1c01e62: Add `language` icon
|
|
92
|
+
- 8f2380a: Default button type "button" for `ListBoxLink` to prevent it being a
|
|
93
|
+
submit type.
|
|
94
|
+
- 3dba14c: Fix horizontal scroll on multiselect dropdown
|
|
95
|
+
- 542adab: Fix crash in `AriaMenu` when items are hidden via branding
|
|
96
|
+
`hiddenFunctionality`. Items whose `data-testid` is overridden to a Fragment
|
|
97
|
+
are now filtered out before entering the react-aria collection, preventing a
|
|
98
|
+
null ref focus crash on keyboard navigation.
|
|
99
|
+
- 33cba9e: Fix copyStyles test to use a lightweight DOM mock that avoids
|
|
100
|
+
triggering happy-dom resource loading.
|
|
101
|
+
- f378928: Stop `aria-label` from overriding visible text in
|
|
102
|
+
`MultistepIndicator`:
|
|
103
|
+
|
|
104
|
+
- Steps no longer carry a 0-based `step N` label that hides the visible step
|
|
105
|
+
name. A label is only set when the step name is not rendered, and it uses
|
|
106
|
+
the same 1-based number as the visible step.
|
|
107
|
+
- The wrapping list is no longer named after the current step; an `aria-label`
|
|
108
|
+
can be supplied by the consumer instead.
|
|
109
|
+
|
|
110
|
+
- 571f17c: Fix CSP style-src-elem violation in PopOutWindow when rendering into
|
|
111
|
+
an about:blank window by inlining stylesheet rules instead of using link
|
|
112
|
+
elements.
|
|
113
|
+
- d066ed1: Restore borders and selection states in forced colors (high contrast)
|
|
114
|
+
mode for `Box` (and so `Panel`/`Modal`), `Button`, `Tabs`, `CondensedTabs`,
|
|
115
|
+
`ToggleSwitch`, `Pill` (and so `Toast`/`NotificationToast`) and `InfoCard`
|
|
116
|
+
- a84b03f: Adds top and bottom margin to `Divider` inside `InnerAriaMenuItem`.
|
|
117
|
+
- 265c898: Migrate test runner from Jest to Vitest.
|
|
118
|
+
- 55018dc: Fix `Modal` becoming non-interactive when opened over a react-aria
|
|
119
|
+
modal overlay (e.g. the mobile participants panel). The modal portal is now
|
|
120
|
+
flagged as a react-aria top layer so it is no longer marked `inert`, which
|
|
121
|
+
previously made its buttons unresponsive and, on touch, caused taps to fall
|
|
122
|
+
through and close the modal without running the action.
|
|
123
|
+
- 3dba14c: Fix clicking an option label in `Multiselect` and
|
|
124
|
+
`ConfirmableMultiselect` not toggling the checkbox. The label was passed to
|
|
125
|
+
`Checkbox` as an inline component, which made React remount it on every render
|
|
126
|
+
and prevented the browser from firing a `click` event on it.
|
|
127
|
+
|
|
128
|
+
`DropContent` now keeps `onContentVisibilityChange` in a ref, so passing an
|
|
129
|
+
inline callback no longer re-runs the effect on every render.
|
|
130
|
+
|
|
131
|
+
- 8b420de: allow for containerRef on Input, setting a ref on the container for
|
|
132
|
+
the input element
|
|
133
|
+
- 5650609: Remove the unused `@types/prettier` dev dependency. It shadowed the
|
|
134
|
+
optional `@types/prettier` peer of `storybook`, which made Yarn resolve a
|
|
135
|
+
second virtual instance of `storybook` for this package and duplicated
|
|
136
|
+
`storybook/theming` in Storybook production builds.
|
|
137
|
+
- e0979b2: Fixed `Draggable` cancelling the first drag. The drag effect tracked
|
|
138
|
+
the element through `ref.current`, which is `null` on the initial render and
|
|
139
|
+
only populated on the next render, causing the effect to tear down and re-arm
|
|
140
|
+
mid-drag. The element is now held in state via a merged callback ref, so the
|
|
141
|
+
first drag completes reliably.
|
|
142
|
+
- 1d41a9d: - CondensedTabs: updated active tab contrast to meet WCAG non-text
|
|
143
|
+
contrast requirements
|
|
144
|
+
- AriaMenu: active/highlighted item now uses accent background with white text
|
|
145
|
+
for contrast; disabled items are excluded from keyboard focus navigation;
|
|
146
|
+
focus indicator uses configurable box-shadow mixin with suppress-on-hover to
|
|
147
|
+
avoid conflicts with hover state
|
|
148
|
+
- Button: translucent button active state uses accent surface background and
|
|
149
|
+
white text
|
|
150
|
+
- Input: focus outline added via the configurable focus mixin; light and dark
|
|
151
|
+
focused stories added
|
|
152
|
+
- ToggleSwitch: focus styling migrated to the configurable box-shadow mixin
|
|
153
|
+
with reduced shadow widths; light/dark checked/unchecked focus stories added
|
|
154
|
+
- Select: focus styling consolidated into the configurable box-shadow mixin,
|
|
155
|
+
removing hardcoded box-shadow overrides
|
|
156
|
+
- Focus mixin (\_focus.scss): refactored to accept `$border-width`,
|
|
157
|
+
`$shadow-width-inset`, `$shadow-width`, `suppress-on-hover`, and
|
|
158
|
+
`color-scheme` parameters for per-component customization
|
|
159
|
+
- b3eedbb: Migrate stories to Storybook 10: import `action` from
|
|
160
|
+
`storybook/actions`, testing helpers from `storybook/test` and doc blocks from
|
|
161
|
+
`@storybook/addon-docs/blocks`, replace the per-story `backgrounds` parameter
|
|
162
|
+
with the `backgrounds` global, and drop the removed
|
|
163
|
+
`@storybook/addon-actions`, `@storybook/blocks` and `@storybook/test` dev
|
|
164
|
+
dependencies.
|
|
165
|
+
- 8f82582: Change colors of the `MultiStepIndicator` steps to be white
|
|
166
|
+
- 62e149e: Checkbox now correctly applies visible focus styling by importing
|
|
167
|
+
Checkbox token definitions into the module stylesheet.
|
|
168
|
+
|
|
169
|
+
Added a dedicated test id on the Checkbox checkmark container span to make
|
|
170
|
+
focus-state assertions more stable in end-to-end tests.
|
|
171
|
+
|
|
172
|
+
New Checkbox Storybook stories for focus verification in both light and dark
|
|
173
|
+
|
|
174
|
+
- Updated dependencies [5a17991]
|
|
175
|
+
- Updated dependencies [380b19c]
|
|
176
|
+
- Updated dependencies [265c898]
|
|
177
|
+
- @pexip/utils@17.4.1
|
|
178
|
+
- @pexip/hooks@21.0.9
|
|
179
|
+
- @pexip/signal@16.9.6
|
|
180
|
+
|
|
181
|
+
## 20.1.0
|
|
182
|
+
|
|
183
|
+
### Minor Changes
|
|
184
|
+
|
|
185
|
+
- d7432f8: Add `variant` prop to `CondensedTabs` with `underline` style support.
|
|
186
|
+
Add `isFullWidth` and `noMargin` props to `Sheet`.
|
|
187
|
+
- 300946c: Adds `className` optional prop to `withTransition`
|
|
188
|
+
- c064e2d: - Add `withTopDivider` / `withBottomDivider` props to `AriaMenuItem`
|
|
189
|
+
for rendering dividers around menu items
|
|
190
|
+
- Move Menu section divider inside `<List>` for consistent padding with menu
|
|
191
|
+
items
|
|
192
|
+
- Add `role="separator"` to dividers for accessibility
|
|
193
|
+
- Update divider color tokens (`neutral-30` / `neutral-80`), preserve old
|
|
194
|
+
values in `variables.legacy.scss`
|
|
195
|
+
- Add `WithDividers` story for AriaMenu
|
|
196
|
+
- fe02b23: Adds 'right' and 'left' position to `NotificationTooltip`
|
|
197
|
+
|
|
198
|
+
### Patch Changes
|
|
199
|
+
|
|
200
|
+
- 15954c9: Lint
|
|
201
|
+
- 6732861: Fix issue with the css overrides.
|
|
202
|
+
- Updated dependencies [44ad859]
|
|
203
|
+
- Updated dependencies [514c523]
|
|
204
|
+
- @pexip/utils@17.4.0
|
|
205
|
+
- @pexip/hooks@21.0.8
|
|
206
|
+
|
|
3
207
|
## 20.0.0
|
|
4
208
|
|
|
5
209
|
### Major Changes
|
package/api-docs/README.mdx
CHANGED
|
@@ -73,12 +73,15 @@ import '@pexip/components/dist/index.css';
|
|
|
73
73
|
| [TextProps](type-aliases/TextProps.mdx) | - |
|
|
74
74
|
| [TextLinkProps](type-aliases/TextLinkProps.mdx) | - |
|
|
75
75
|
| [NotificationTooltipPosition](type-aliases/NotificationTooltipPosition.mdx) | - |
|
|
76
|
+
| [NotificationTooltipProps](type-aliases/NotificationTooltipProps.mdx) | - |
|
|
76
77
|
| [OverlayOpacity](type-aliases/OverlayOpacity.mdx) | - |
|
|
77
78
|
| [FullSizeWindowColorBackgroundProps](type-aliases/FullSizeWindowColorBackgroundProps.mdx) | - |
|
|
78
79
|
| [FullSizeWindowImageBackgroundProps](type-aliases/FullSizeWindowImageBackgroundProps.mdx) | - |
|
|
79
80
|
| [StatusItem](type-aliases/StatusItem.mdx) | - |
|
|
80
81
|
| [ActivityCardAction](type-aliases/ActivityCardAction.mdx) | - |
|
|
81
82
|
| [AriaMenuProps](type-aliases/AriaMenuProps.mdx) | - |
|
|
83
|
+
| [AriaSubMenuContentHelpers](type-aliases/AriaSubMenuContentHelpers.mdx) | Helpers passed to a submenu's `content` render function, allowing the content to close the whole menu or navigate back to the previous level. |
|
|
84
|
+
| [AriaSubMenu](type-aliases/AriaSubMenu.mdx) | A submenu that opens in place inside an [AriaMenu](variables/AriaMenu.mdx) when its parent item is clicked. A submenu can either render a nested list of [AriaMenuItem](type-aliases/AriaMenuItem.mdx) (which can themselves open further submenus) or arbitrary React content. When a submenu is open, a back button is rendered at the top of the menu to return to the previous level. |
|
|
82
85
|
| [AriaMenuItem](type-aliases/AriaMenuItem.mdx) | The structure of a menu item that can be used to create a dropdown menu. |
|
|
83
86
|
| [BreadcrumbItem](type-aliases/BreadcrumbItem.mdx) | - |
|
|
84
87
|
| [DropContentPosition](type-aliases/DropContentPosition.mdx) | - |
|
|
@@ -88,6 +91,7 @@ import '@pexip/components/dist/index.css';
|
|
|
88
91
|
| [MenuAction](type-aliases/MenuAction.mdx) | - |
|
|
89
92
|
| [MenuContent](type-aliases/MenuContent.mdx) | - |
|
|
90
93
|
| [ModalProps](type-aliases/ModalProps.mdx) | - |
|
|
94
|
+
| [MultiselectCoreProps](type-aliases/MultiselectCoreProps.mdx) | - |
|
|
91
95
|
| [MultistepIndicatorProps](type-aliases/MultistepIndicatorProps.mdx) | - |
|
|
92
96
|
| [NotificationToastMessage](type-aliases/NotificationToastMessage.mdx) | - |
|
|
93
97
|
| [NotificationToastSignal](type-aliases/NotificationToastSignal.mdx) | - |
|
|
@@ -151,7 +155,7 @@ import '@pexip/components/dist/index.css';
|
|
|
151
155
|
| [CoreHeader](variables/CoreHeader.mdx) | - |
|
|
152
156
|
| [Divider](variables/Divider.mdx) | - |
|
|
153
157
|
| [DragAndDrop](variables/DragAndDrop.mdx) | - |
|
|
154
|
-
| [Draggable](variables/Draggable.mdx) |
|
|
158
|
+
| [Draggable](variables/Draggable.mdx) | A wrapper that makes its children draggable via pointer (and, when `isMoveableWithArrowKeys` is set, the keyboard). |
|
|
155
159
|
| [FileUpload](variables/FileUpload.mdx) | - |
|
|
156
160
|
| [Heading](variables/Heading.mdx) | - |
|
|
157
161
|
| [Icon](variables/Icon.mdx) | - |
|
|
@@ -181,6 +185,7 @@ import '@pexip/components/dist/index.css';
|
|
|
181
185
|
| [TextHeading](variables/TextHeading.mdx) | - |
|
|
182
186
|
| [TextLink](variables/TextLink.mdx) | - |
|
|
183
187
|
| [ToggleSwitch](variables/ToggleSwitch.mdx) | - |
|
|
188
|
+
| [ToggleSwitchDisplay](variables/ToggleSwitchDisplay.mdx) | Presentational version of ToggleSwitch that renders only the visual toggle indicator and label text — it does not render an `<input>` or manage any interaction/state itself. |
|
|
184
189
|
| [CustomTooltip](variables/CustomTooltip.mdx) | - |
|
|
185
190
|
| [NotificationTooltip](variables/NotificationTooltip.mdx) | - |
|
|
186
191
|
| [Tooltip](variables/Tooltip.mdx) | Tooltips need to be accessible to keyboard and screen reader users, so we ensure that they are only placed on focusable and hoverable elements. For example, plain text and disabled buttons aren't focusable, meaning keyboard and screen reader users would be unable to access the information in that tooltip. |
|
|
@@ -201,7 +206,7 @@ import '@pexip/components/dist/index.css';
|
|
|
201
206
|
| [Accordion](variables/Accordion.mdx) | - |
|
|
202
207
|
| [ActivityCard](variables/ActivityCard.mdx) | - |
|
|
203
208
|
| [ariaMenuOpenStateSignal](variables/ariaMenuOpenStateSignal.mdx) | - |
|
|
204
|
-
| [AriaMenu](variables/AriaMenu.mdx) | AriaMenu component represents a dropdown menu. |
|
|
209
|
+
| [AriaMenu](variables/AriaMenu.mdx) | AriaMenu component represents a dropdown menu. Menu items can open submenus in place, rendering either a nested list of items or arbitrary React content, with a back button to return to the previous level. |
|
|
205
210
|
| [AspectRatio](variables/AspectRatio.mdx) | A wrapper that makes its children element bound to an aspect ratio. Default ration is 16:9, `{width: 16, height: 9}` |
|
|
206
211
|
| [ColorPickerPreviewButton](variables/ColorPickerPreviewButton.mdx) | - |
|
|
207
212
|
| [ImagePreviewButton](variables/ImagePreviewButton.mdx) | - |
|
|
@@ -235,6 +240,7 @@ import '@pexip/components/dist/index.css';
|
|
|
235
240
|
| [HotKey](variables/HotKey.mdx) | - |
|
|
236
241
|
| [ConfirmableMultiselect](variables/ConfirmableMultiselect.mdx) | - |
|
|
237
242
|
| [Multiselect](variables/Multiselect.mdx) | - |
|
|
243
|
+
| [MultiselectCore](variables/MultiselectCore.mdx) | - |
|
|
238
244
|
| [MultistepIndicator](variables/MultistepIndicator.mdx) | - |
|
|
239
245
|
| [NotificationToast](variables/NotificationToast.mdx) | The NotificationToast component works like a normal toast, except it displays data received via a signal, and it stores the messages as an array, displaying one at a time. |
|
|
240
246
|
| [notificationToastSignal](variables/notificationToastSignal.mdx) | - |
|
|
@@ -276,11 +282,13 @@ import '@pexip/components/dist/index.css';
|
|
|
276
282
|
| [UserMenuButton](variables/UserMenuButton.mdx) | - |
|
|
277
283
|
| [UserMenuDropContent](variables/UserMenuDropContent.mdx) | - |
|
|
278
284
|
| [VideoWrapper](variables/VideoWrapper.mdx) | - |
|
|
285
|
+
| [KEYBOARD\_EVENT\_KEY](variables/KEYBOARD_EVENT_KEY.mdx) | - |
|
|
279
286
|
| [themeValues](variables/themeValues.mdx) | - |
|
|
280
287
|
| [ThemeContext](variables/ThemeContext.mdx) | - |
|
|
281
288
|
| [ThemeConsumer](variables/ThemeConsumer.mdx) | - |
|
|
282
289
|
| [ThemeProvider](variables/ThemeProvider.mdx) | - |
|
|
283
290
|
| [TooltipPositionValue](variables/TooltipPositionValue.mdx) | - |
|
|
291
|
+
| [buttonVariantsValues](variables/buttonVariantsValues.mdx) | - |
|
|
284
292
|
|
|
285
293
|
## Functions
|
|
286
294
|
|
|
@@ -317,6 +325,7 @@ import '@pexip/components/dist/index.css';
|
|
|
317
325
|
| [useXlDown](functions/useXlDown.mdx) | - |
|
|
318
326
|
| [useXlUp](functions/useXlUp.mdx) | - |
|
|
319
327
|
| [useXs](functions/useXs.mdx) | - |
|
|
328
|
+
| [useBoundingRect](functions/useBoundingRect.mdx) | Observes a HTMLElement and returns its bounding rect. Updates when the element's size changes. |
|
|
320
329
|
| [useBreakpointChange](functions/useBreakpointChange.mdx) | - |
|
|
321
330
|
| [useFocusFrom](functions/useFocusFrom.mdx) | This hook gives the ability to set the focus on an element which is then blurred right away, thereby effectively resetting the focus order. The next focusable element that comes after this element will be focused on the next tab. |
|
|
322
331
|
| [useFocusFromOpened](functions/useFocusFromOpened.mdx) | Use this hook to set the focus point on an element when something becomes opened, e.g. set focus on a panel container or menu container when it becomes visible so that the next time the user hits on the tab key the element that becomes focused on is potentially a tabbable element inside the container element. |
|
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
| <a id="buttonthreecolumnselector"></a> `ButtonThreeColumnSelector` | `"button-three-column-selector"` |
|
|
8
8
|
| <a id="buttoncollapsablecontainertoggle"></a> `ButtonCollapsableContainerToggle` | `"button-collapsable-container-toggle"` |
|
|
9
9
|
| <a id="checkboxcheck"></a> `CheckboxCheck` | `"checkbox-check"` |
|
|
10
|
+
| <a id="checkboxcheckcontainer"></a> `CheckboxCheckContainer` | `"checkbox-check-container"` |
|
|
10
11
|
| <a id="confirmablemultiselectconfirm"></a> `ConfirmableMultiselectConfirm` | `"confirmable-multiselect-confirm"` |
|
|
11
12
|
| <a id="headercore"></a> `HeaderCore` | `"header-core"` |
|
|
12
13
|
| <a id="headercoreenhancers"></a> `HeaderCoreEnhancers` | `"header-core-enhancers"` |
|
|
@@ -13,7 +13,7 @@ Announcer needs to be mounted in the application for this to work.
|
|
|
13
13
|
| Parameter | Type | Default value | Description |
|
|
14
14
|
| ------ | ------ | ------ | ------ |
|
|
15
15
|
| `message` | `ReactNode` | `undefined` | The message to announce. |
|
|
16
|
-
| `politeness` | `"assertive"
|
|
16
|
+
| `politeness` | `"assertive" \| "polite"` | `'polite'` | The politeness level of the announcement. |
|
|
17
17
|
| `timeout` | `number` | `5000` | The time in milliseconds util the message is removed from area-live region. |
|
|
18
18
|
|
|
19
19
|
## Returns
|
|
@@ -6,8 +6,8 @@ function onEnter<E, T>(callback): (e) => void;
|
|
|
6
6
|
|
|
7
7
|
| Type Parameter |
|
|
8
8
|
| ------ |
|
|
9
|
-
| `E
|
|
10
|
-
| `T
|
|
9
|
+
| `E extends HTMLElement` |
|
|
10
|
+
| `T extends (e) => void` |
|
|
11
11
|
|
|
12
12
|
## Parameters
|
|
13
13
|
|
|
@@ -25,7 +25,7 @@ function onEnter<E, T>(callback): (e) => void;
|
|
|
25
25
|
|
|
26
26
|
| Parameter | Type |
|
|
27
27
|
| ------ | ------ |
|
|
28
|
-
| `e` | `KeyboardEvent
|
|
28
|
+
| `e` | `KeyboardEvent<E>` |
|
|
29
29
|
|
|
30
30
|
### Returns
|
|
31
31
|
|
|
@@ -11,12 +11,22 @@ function sizeToPadding(t):
|
|
|
11
11
|
|
|
12
12
|
| Parameter | Type |
|
|
13
13
|
| ------ | ------ |
|
|
14
|
-
| `t` | `"small"
|
|
14
|
+
| `t` | `"small" \| "medium" \| "compact" \| "large" \| "none"` |
|
|
15
15
|
|
|
16
16
|
## Returns
|
|
17
17
|
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
18
|
+
```ts
|
|
19
|
+
| "compactPadding"
|
|
20
|
+
```
|
|
21
|
+
```ts
|
|
22
|
+
| "largePadding"
|
|
23
|
+
```
|
|
24
|
+
```ts
|
|
25
|
+
| "mediumPadding"
|
|
26
|
+
```
|
|
27
|
+
```ts
|
|
28
|
+
| "nonePadding"
|
|
29
|
+
```
|
|
30
|
+
```ts
|
|
31
|
+
| "smallPadding"
|
|
32
|
+
```
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
```ts
|
|
2
|
+
function useBoundingRect(
|
|
3
|
+
element,
|
|
4
|
+
updateOnWindowResize,
|
|
5
|
+
windowResizeThrottle): DOMRect | undefined;
|
|
6
|
+
```
|
|
7
|
+
|
|
8
|
+
Observes a HTMLElement and returns its bounding rect.
|
|
9
|
+
Updates when the element's size changes.
|
|
10
|
+
|
|
11
|
+
If a ref to a HTMLElement is passed and ref.current is null it polls the ref to detect when
|
|
12
|
+
the HTMLElement value gets assigned to ref.current, this is useful in case the Component
|
|
13
|
+
using this hook does not rerender when ref.current changes.
|
|
14
|
+
|
|
15
|
+
## Parameters
|
|
16
|
+
|
|
17
|
+
| Parameter | Type | Default value | Description |
|
|
18
|
+
| ------ | ------ | ------ | ------ |
|
|
19
|
+
| `element` | `HTMLElement \| RefObject<HTMLElement` | null\>` \\| `null` \| `undefined` | The HTMLElement, null, or a ref to an HTMLElement to observe |
|
|
20
|
+
| `updateOnWindowResize` | `boolean` | `false` | Whether to update the rect on window resize (default: false) |
|
|
21
|
+
| `windowResizeThrottle` | `number` | `0` | Throttle interval in ms for window resize updates (default: 0) |
|
|
22
|
+
|
|
23
|
+
## Returns
|
|
24
|
+
|
|
25
|
+
```ts
|
|
26
|
+
DOMRect | undefined
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
The DOMRect of the element, or undefined if element is not available
|
|
30
|
+
|
|
31
|
+
## Example
|
|
32
|
+
|
|
33
|
+
```ts
|
|
34
|
+
const ref = useRef<HTMLDivElement>(null);
|
|
35
|
+
const rect = useBoundingRect(ref);
|
|
36
|
+
|
|
37
|
+
const [element, setElement] = useState<HTMLDivElement | null>(null);
|
|
38
|
+
const rect2 = useBoundingRect(element);
|
|
39
|
+
|
|
40
|
+
// Update on window resize with 150ms throttle
|
|
41
|
+
const rect3 = useBoundingRect(ref, true, 150);
|
|
42
|
+
```
|
|
@@ -11,7 +11,7 @@ will be focused on the next tab.
|
|
|
11
11
|
|
|
12
12
|
| Parameter | Type | Description |
|
|
13
13
|
| ------ | ------ | ------ |
|
|
14
|
-
| `element` | `HTMLElement
|
|
14
|
+
| `element` | `HTMLElement \| null` | element which focus point should start from |
|
|
15
15
|
|
|
16
16
|
## Returns
|
|
17
17
|
|
|
@@ -21,4 +21,4 @@ focusFrom function, when called sets the focus point to the given element
|
|
|
21
21
|
|
|
22
22
|
| Name | Type |
|
|
23
23
|
| ------ | ------ |
|
|
24
|
-
| `focusFrom()` | () =>
|
|
24
|
+
| `focusFrom()` | `() => void` |
|
|
@@ -12,7 +12,7 @@ element inside the container element.
|
|
|
12
12
|
|
|
13
13
|
| Parameter | Type | Description |
|
|
14
14
|
| ------ | ------ | ------ |
|
|
15
|
-
| `element` | `HTMLElement
|
|
15
|
+
| `element` | `HTMLElement \| null` | element which focus point should start from |
|
|
16
16
|
| `isOpen` | `boolean` | when isOpen is true the element will get the focus point |
|
|
17
17
|
|
|
18
18
|
## Returns
|
|
@@ -6,11 +6,11 @@ function useGroupedPagesNav(__namedParameters): GroupedPageNav[];
|
|
|
6
6
|
|
|
7
7
|
| Parameter | Type |
|
|
8
8
|
| ------ | ------ |
|
|
9
|
-
| `__namedParameters` |
|
|
9
|
+
| `__namedParameters` | `{ groupChunkSize?: number; pageIndex: number; totalPagesCount: number; }` |
|
|
10
10
|
| `__namedParameters.groupChunkSize?` | `number` |
|
|
11
11
|
| `__namedParameters.pageIndex` | `number` |
|
|
12
12
|
| `__namedParameters.totalPagesCount` | `number` |
|
|
13
13
|
|
|
14
14
|
## Returns
|
|
15
15
|
|
|
16
|
-
`GroupedPageNav
|
|
16
|
+
`GroupedPageNav[]`
|
|
@@ -6,8 +6,10 @@ function useInput(props): [string, Omit<Omit<DetailedHTMLProps<InputHTMLAttribut
|
|
|
6
6
|
|
|
7
7
|
| Parameter | Type |
|
|
8
8
|
| ------ | ------ |
|
|
9
|
-
| `props` | `Omit
|
|
9
|
+
| `props` | `Omit<Omit<DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "disabled"> & object, "ref"> & RefAttributes<Pick<HTMLInputElement, "focus">>` |
|
|
10
10
|
|
|
11
11
|
## Returns
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
```ts
|
|
14
|
+
[string, Omit<Omit<DetailedHTMLProps<InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "disabled"> & object, "ref"> & RefAttributes<Pick<HTMLInputElement, "focus">>]
|
|
15
|
+
```
|
|
@@ -14,5 +14,5 @@ function useModal(isOpen): object;
|
|
|
14
14
|
|
|
15
15
|
| Name | Type |
|
|
16
16
|
| ------ | ------ |
|
|
17
|
-
| `ref` | `RefObject
|
|
18
|
-
| `modalProps` | `DOMAttributes
|
|
17
|
+
| `ref` | `RefObject<HTMLDivElement \| null>` |
|
|
18
|
+
| `modalProps` | `DOMAttributes<FocusableElement>` |
|
|
@@ -20,5 +20,5 @@ causes the virtual keyboard to cover focused inputs.
|
|
|
20
20
|
|
|
21
21
|
| Name | Type | Default value |
|
|
22
22
|
| ------ | ------ | ------ |
|
|
23
|
-
| `ref` | `RefObject
|
|
24
|
-
| `modalProps` | `DOMAttributes
|
|
23
|
+
| `ref` | `RefObject<HTMLDivElement \| null>` | - |
|
|
24
|
+
| `modalProps` | `DOMAttributes<FocusableElement>` | `overlayProps` |
|
|
@@ -34,12 +34,28 @@ readonly \[\{
|
|
|
34
34
|
`prevStepsCompleted`: `boolean`;
|
|
35
35
|
`steps`: [`MultistepItem`](../interfaces/MultistepItem.mdx)[];
|
|
36
36
|
\}, \{
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
37
|
+
```ts
|
|
38
|
+
moveToStep: (stepIndex, __namedParameters) => void;
|
|
39
|
+
```
|
|
40
|
+
```ts
|
|
41
|
+
resetAllSteps: () => void;
|
|
42
|
+
```
|
|
43
|
+
```ts
|
|
44
|
+
resetStep: (stepIndex) => void;
|
|
45
|
+
```
|
|
46
|
+
```ts
|
|
47
|
+
updateStepActive: (stepIndex, isActive) => void;
|
|
48
|
+
```
|
|
49
|
+
```ts
|
|
50
|
+
updateStepCompleted: (stepIndex, __namedParameters) => void;
|
|
51
|
+
```
|
|
52
|
+
```ts
|
|
53
|
+
updateStepFailed: (stepIndex, __namedParameters) => void;
|
|
54
|
+
```
|
|
55
|
+
```ts
|
|
56
|
+
updateStepDisabled: (stepIndex, isDisabled) => void;
|
|
57
|
+
```
|
|
58
|
+
```ts
|
|
59
|
+
updateStepLeave: (stepIndex, __namedParameters) => void;
|
|
60
|
+
```
|
|
45
61
|
\}\]
|
|
@@ -6,10 +6,10 @@ function useOutOfViewNavigation(__namedParameters): object;
|
|
|
6
6
|
|
|
7
7
|
| Parameter | Type |
|
|
8
8
|
| ------ | ------ |
|
|
9
|
-
| `__namedParameters` |
|
|
9
|
+
| `__namedParameters` | `{ isDisabled?: boolean; content: ReactElement; root: HTMLElement \| null; moveBy?: number; containerClassName?: string; }` |
|
|
10
10
|
| `__namedParameters.isDisabled?` | `boolean` |
|
|
11
11
|
| `__namedParameters.content` | `ReactElement` |
|
|
12
|
-
| `__namedParameters.root` | `HTMLElement
|
|
12
|
+
| `__namedParameters.root` | `HTMLElement \| null` |
|
|
13
13
|
| `__namedParameters.moveBy?` | `number` |
|
|
14
14
|
| `__namedParameters.containerClassName?` | `string` |
|
|
15
15
|
|
|
@@ -20,6 +20,6 @@ function useOutOfViewNavigation(__namedParameters): object;
|
|
|
20
20
|
| Name | Type |
|
|
21
21
|
| ------ | ------ |
|
|
22
22
|
| `navigationView` | `Element` |
|
|
23
|
-
| `moveLeft` | () =>
|
|
24
|
-
| `moveRight` | () =>
|
|
23
|
+
| `moveLeft` | `() => void \| undefined` |
|
|
24
|
+
| `moveRight` | `() => void \| undefined` |
|
|
25
25
|
| `hasOverflowingContent` | `boolean` |
|
|
@@ -6,10 +6,10 @@ function useScrollIntoView(element, options): () => void;
|
|
|
6
6
|
|
|
7
7
|
| Parameter | Type |
|
|
8
8
|
| ------ | ------ |
|
|
9
|
-
| `element` | `RefObject
|
|
10
|
-
| `options` |
|
|
9
|
+
| `element` | `RefObject<HTMLElement \| null>` |
|
|
10
|
+
| `options` | `{ delay?: number; scrollIntoViewOptions?: Partial<ScrollIntoViewOptions>; }` |
|
|
11
11
|
| `options.delay?` | `number` |
|
|
12
|
-
| `options.scrollIntoViewOptions?` | `Partial
|
|
12
|
+
| `options.scrollIntoViewOptions?` | `Partial<ScrollIntoViewOptions>` |
|
|
13
13
|
|
|
14
14
|
## Returns
|
|
15
15
|
|
|
@@ -6,14 +6,14 @@ function withColorScheme<P>(Component, colorScheme): (props) => Element;
|
|
|
6
6
|
|
|
7
7
|
| Type Parameter |
|
|
8
8
|
| ------ |
|
|
9
|
-
| `P
|
|
9
|
+
| `P extends object` |
|
|
10
10
|
|
|
11
11
|
## Parameters
|
|
12
12
|
|
|
13
13
|
| Parameter | Type |
|
|
14
14
|
| ------ | ------ |
|
|
15
|
-
| `Component` | `ComponentType
|
|
16
|
-
| `colorScheme` | `"dark"
|
|
15
|
+
| `Component` | `ComponentType<P>` |
|
|
16
|
+
| `colorScheme` | `"dark" \| "light"` |
|
|
17
17
|
|
|
18
18
|
## Returns
|
|
19
19
|
|
|
@@ -12,7 +12,7 @@ function withTabName<P>(Component, componentProps?): (props) => Element;
|
|
|
12
12
|
|
|
13
13
|
| Parameter | Type |
|
|
14
14
|
| ------ | ------ |
|
|
15
|
-
| `Component` | `ComponentType
|
|
15
|
+
| `Component` | `ComponentType<P>` |
|
|
16
16
|
| `componentProps?` | `P` |
|
|
17
17
|
|
|
18
18
|
## Returns
|
|
@@ -25,7 +25,7 @@ function withTabName<P>(Component, componentProps?): (props) => Element;
|
|
|
25
25
|
|
|
26
26
|
| Parameter | Type |
|
|
27
27
|
| ------ | ------ |
|
|
28
|
-
| `props` | `P` & `ClassAttributes
|
|
28
|
+
| `props` | `P` & `ClassAttributes<HTMLButtonElement>` & `ButtonHTMLAttributes<HTMLButtonElement>` |
|
|
29
29
|
|
|
30
30
|
### Returns
|
|
31
31
|
|
|
@@ -9,15 +9,15 @@ function withTransition<P>(
|
|
|
9
9
|
|
|
10
10
|
| Type Parameter |
|
|
11
11
|
| ------ |
|
|
12
|
-
| `P
|
|
12
|
+
| `P extends object` |
|
|
13
13
|
|
|
14
14
|
## Parameters
|
|
15
15
|
|
|
16
16
|
| Parameter | Type | Default value |
|
|
17
17
|
| ------ | ------ | ------ |
|
|
18
|
-
| `Component` | `ComponentType
|
|
18
|
+
| `Component` | `ComponentType<P>` | `undefined` |
|
|
19
19
|
| `timeout` | `number` | `undefined` |
|
|
20
|
-
| `stateAfterTransition` | `"hide"
|
|
20
|
+
| `stateAfterTransition` | `"hide" \| "unmount"` | `'unmount'` |
|
|
21
21
|
|
|
22
22
|
## Returns
|
|
23
23
|
|
|
@@ -33,4 +33,6 @@ function withTransition<P>(
|
|
|
33
33
|
|
|
34
34
|
### Returns
|
|
35
35
|
|
|
36
|
-
|
|
36
|
+
```ts
|
|
37
|
+
Element | null
|
|
38
|
+
```
|