@wordpress/components 23.9.0 → 24.0.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 +36 -0
- package/CONTRIBUTING.md +65 -1
- package/README.md +1 -3
- package/build/autocomplete/autocompleter-ui.js +0 -2
- package/build/autocomplete/autocompleter-ui.js.map +1 -1
- package/build/autocomplete/index.js +2 -0
- package/build/autocomplete/index.js.map +1 -1
- package/build/button/index.js +2 -0
- package/build/button/index.js.map +1 -1
- package/build/card/card-media/component.js +2 -1
- package/build/card/card-media/component.js.map +1 -1
- package/build/combobox-control/index.js +7 -5
- package/build/combobox-control/index.js.map +1 -1
- package/build/combobox-control/styles.js +3 -3
- package/build/combobox-control/styles.js.map +1 -1
- package/build/dimension-control/index.js +1 -1
- package/build/dimension-control/index.js.map +1 -1
- package/build/draggable/index.js +2 -7
- package/build/draggable/index.js.map +1 -1
- package/build/form-token-field/index.js +5 -3
- package/build/form-token-field/index.js.map +1 -1
- package/build/form-token-field/styles.js +3 -3
- package/build/form-token-field/styles.js.map +1 -1
- package/build/mobile/global-styles-context/index.native.js +13 -1
- package/build/mobile/global-styles-context/index.native.js.map +1 -1
- package/build/mobile/link-picker/link-picker-results.native.js +3 -1
- package/build/mobile/link-picker/link-picker-results.native.js.map +1 -1
- package/build/modal/index.js +2 -1
- package/build/modal/index.js.map +1 -1
- package/build/navigable-container/container.js +39 -19
- package/build/navigable-container/container.js.map +1 -1
- package/build/navigable-container/index.js.map +1 -1
- package/build/navigable-container/menu.js +37 -5
- package/build/navigable-container/menu.js.map +1 -1
- package/build/navigable-container/tabbable.js +45 -4
- package/build/navigable-container/tabbable.js.map +1 -1
- package/build/navigable-container/types.js +6 -0
- package/build/navigable-container/types.js.map +1 -0
- package/build/palette-edit/index.js +34 -12
- package/build/palette-edit/index.js.map +1 -1
- package/build/sandbox/index.native.js +6 -2
- package/build/sandbox/index.native.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/fill.js +2 -1
- package/build/slot-fill/bubbles-virtually/fill.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/slot-fill-provider.js +45 -35
- package/build/slot-fill/bubbles-virtually/slot-fill-provider.js.map +1 -1
- package/build/slot-fill/bubbles-virtually/use-slot.js +11 -26
- package/build/slot-fill/bubbles-virtually/use-slot.js.map +1 -1
- package/build/slot-fill/fill.js +7 -31
- package/build/slot-fill/fill.js.map +1 -1
- package/build/slot-fill/index.js.map +1 -1
- package/build/slot-fill/provider.js +0 -6
- package/build/slot-fill/provider.js.map +1 -1
- package/build/slot-fill/slot.js +0 -5
- package/build/slot-fill/slot.js.map +1 -1
- package/build/tab-panel/index.js.map +1 -1
- package/build/theme/color-algorithms.js +1 -1
- package/build/theme/color-algorithms.js.map +1 -1
- package/build/toolbar/toolbar-button/index.js +1 -2
- package/build/toolbar/toolbar-button/index.js.map +1 -1
- package/build/toolbar/toolbar-item/index.js +4 -2
- package/build/toolbar/toolbar-item/index.js.map +1 -1
- package/build/utils/colors-values.js +3 -3
- package/build/utils/colors-values.js.map +1 -1
- package/build/utils/use-deprecated-props.js +35 -0
- package/build/utils/use-deprecated-props.js.map +1 -0
- package/build-module/autocomplete/autocompleter-ui.js +1 -3
- package/build-module/autocomplete/autocompleter-ui.js.map +1 -1
- package/build-module/autocomplete/index.js +3 -3
- package/build-module/autocomplete/index.js.map +1 -1
- package/build-module/button/index.js +2 -0
- package/build-module/button/index.js.map +1 -1
- package/build-module/card/card-media/component.js +2 -1
- package/build-module/card/card-media/component.js.map +1 -1
- package/build-module/combobox-control/index.js +6 -5
- package/build-module/combobox-control/index.js.map +1 -1
- package/build-module/combobox-control/styles.js +3 -3
- package/build-module/combobox-control/styles.js.map +1 -1
- package/build-module/dimension-control/index.js +1 -1
- package/build-module/dimension-control/index.js.map +1 -1
- package/build-module/draggable/index.js +2 -7
- package/build-module/draggable/index.js.map +1 -1
- package/build-module/form-token-field/index.js +4 -3
- package/build-module/form-token-field/index.js.map +1 -1
- package/build-module/form-token-field/styles.js +3 -3
- package/build-module/form-token-field/styles.js.map +1 -1
- package/build-module/mobile/global-styles-context/index.native.js +13 -1
- package/build-module/mobile/global-styles-context/index.native.js.map +1 -1
- package/build-module/mobile/link-picker/link-picker-results.native.js +3 -1
- package/build-module/mobile/link-picker/link-picker-results.native.js.map +1 -1
- package/build-module/modal/index.js +2 -1
- package/build-module/modal/index.js.map +1 -1
- package/build-module/navigable-container/container.js +43 -19
- package/build-module/navigable-container/container.js.map +1 -1
- package/build-module/navigable-container/index.js +0 -2
- package/build-module/navigable-container/index.js.map +1 -1
- package/build-module/navigable-container/menu.js +36 -4
- package/build-module/navigable-container/menu.js.map +1 -1
- package/build-module/navigable-container/tabbable.js +44 -3
- package/build-module/navigable-container/tabbable.js.map +1 -1
- package/build-module/navigable-container/types.js +2 -0
- package/build-module/navigable-container/types.js.map +1 -0
- package/build-module/palette-edit/index.js +34 -13
- package/build-module/palette-edit/index.js.map +1 -1
- package/build-module/sandbox/index.native.js +6 -2
- package/build-module/sandbox/index.native.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/fill.js +2 -1
- package/build-module/slot-fill/bubbles-virtually/fill.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/slot-fill-provider.js +46 -36
- package/build-module/slot-fill/bubbles-virtually/slot-fill-provider.js.map +1 -1
- package/build-module/slot-fill/bubbles-virtually/use-slot.js +12 -27
- package/build-module/slot-fill/bubbles-virtually/use-slot.js.map +1 -1
- package/build-module/slot-fill/fill.js +7 -31
- package/build-module/slot-fill/fill.js.map +1 -1
- package/build-module/slot-fill/index.js +1 -2
- package/build-module/slot-fill/index.js.map +1 -1
- package/build-module/slot-fill/provider.js +0 -6
- package/build-module/slot-fill/provider.js.map +1 -1
- package/build-module/slot-fill/slot.js +0 -5
- package/build-module/slot-fill/slot.js.map +1 -1
- package/build-module/tab-panel/index.js.map +1 -1
- package/build-module/theme/color-algorithms.js +1 -1
- package/build-module/theme/color-algorithms.js.map +1 -1
- package/build-module/toolbar/toolbar-button/index.js +1 -2
- package/build-module/toolbar/toolbar-button/index.js.map +1 -1
- package/build-module/toolbar/toolbar-item/index.js +5 -2
- package/build-module/toolbar/toolbar-item/index.js.map +1 -1
- package/build-module/utils/colors-values.js +3 -3
- package/build-module/utils/colors-values.js.map +1 -1
- package/build-module/utils/use-deprecated-props.js +25 -0
- package/build-module/utils/use-deprecated-props.js.map +1 -0
- package/build-style/style-rtl.css +58 -55
- package/build-style/style.css +58 -55
- package/build-types/autocomplete/autocompleter-ui.d.ts.map +1 -1
- package/build-types/autocomplete/index.d.ts.map +1 -1
- package/build-types/autocomplete/types.d.ts +2 -18
- package/build-types/autocomplete/types.d.ts.map +1 -1
- package/build-types/button/deprecated.d.ts +6 -0
- package/build-types/button/deprecated.d.ts.map +1 -1
- package/build-types/button/index.d.ts.map +1 -1
- package/build-types/button/types.d.ts +7 -0
- package/build-types/button/types.d.ts.map +1 -1
- package/build-types/card/card-media/component.d.ts +2 -1
- package/build-types/card/card-media/component.d.ts.map +1 -1
- package/build-types/card/stories/index.d.ts +21 -1
- package/build-types/card/stories/index.d.ts.map +1 -1
- package/build-types/combobox-control/index.d.ts +1 -1
- package/build-types/combobox-control/index.d.ts.map +1 -1
- package/build-types/combobox-control/stories/index.d.ts.map +1 -1
- package/build-types/combobox-control/styles.d.ts +1 -1
- package/build-types/combobox-control/types.d.ts +8 -1
- package/build-types/combobox-control/types.d.ts.map +1 -1
- package/build-types/dimension-control/index.d.ts +1 -1
- package/build-types/draggable/index.d.ts.map +1 -1
- package/build-types/form-token-field/index.d.ts.map +1 -1
- package/build-types/form-token-field/styles.d.ts +1 -1
- package/build-types/form-token-field/types.d.ts +8 -1
- package/build-types/form-token-field/types.d.ts.map +1 -1
- package/build-types/modal/index.d.ts.map +1 -1
- package/build-types/navigable-container/container.d.ts +20 -1
- package/build-types/navigable-container/container.d.ts.map +1 -1
- package/build-types/navigable-container/index.d.ts +5 -2
- package/build-types/navigable-container/index.d.ts.map +1 -1
- package/build-types/navigable-container/menu.d.ts +45 -11
- package/build-types/navigable-container/menu.d.ts.map +1 -1
- package/build-types/navigable-container/stories/navigable-menu.d.ts +12 -0
- package/build-types/navigable-container/stories/navigable-menu.d.ts.map +1 -0
- package/build-types/navigable-container/stories/tabbable-container.d.ts +12 -0
- package/build-types/navigable-container/stories/tabbable-container.d.ts.map +1 -0
- package/build-types/navigable-container/tabbable.d.ts +52 -9
- package/build-types/navigable-container/tabbable.d.ts.map +1 -1
- package/build-types/navigable-container/test/navigable-menu.d.ts +2 -0
- package/build-types/navigable-container/test/navigable-menu.d.ts.map +1 -0
- package/build-types/navigable-container/test/tababble-container.d.ts +2 -0
- package/build-types/navigable-container/test/tababble-container.d.ts.map +1 -0
- package/build-types/navigable-container/types.d.ts +61 -0
- package/build-types/navigable-container/types.d.ts.map +1 -0
- package/build-types/navigator/navigator-back-button/component.d.ts +1 -0
- package/build-types/navigator/navigator-back-button/component.d.ts.map +1 -1
- package/build-types/navigator/navigator-back-button/hook.d.ts +1 -0
- package/build-types/navigator/navigator-back-button/hook.d.ts.map +1 -1
- package/build-types/navigator/navigator-button/component.d.ts +1 -0
- package/build-types/navigator/navigator-button/component.d.ts.map +1 -1
- package/build-types/navigator/navigator-button/hook.d.ts +1 -0
- package/build-types/navigator/navigator-button/hook.d.ts.map +1 -1
- package/build-types/navigator/navigator-to-parent-button/component.d.ts +1 -0
- package/build-types/navigator/navigator-to-parent-button/component.d.ts.map +1 -1
- package/build-types/palette-edit/index.d.ts +1 -1
- package/build-types/palette-edit/index.d.ts.map +1 -1
- package/build-types/palette-edit/stories/index.d.ts.map +1 -1
- package/build-types/palette-edit/types.d.ts +8 -0
- package/build-types/palette-edit/types.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/fill.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/slot-fill-provider.d.ts.map +1 -1
- package/build-types/slot-fill/bubbles-virtually/use-slot.d.ts.map +1 -1
- package/build-types/slot-fill/fill.d.ts +4 -2
- package/build-types/slot-fill/fill.d.ts.map +1 -1
- package/build-types/slot-fill/index.d.ts +1 -2
- package/build-types/slot-fill/index.d.ts.map +1 -1
- package/build-types/slot-fill/provider.d.ts +0 -2
- package/build-types/slot-fill/provider.d.ts.map +1 -1
- package/build-types/slot-fill/slot.d.ts.map +1 -1
- package/build-types/toolbar/stories/index.d.ts.map +1 -1
- package/build-types/toolbar/toolbar-button/index.d.ts +6 -0
- package/build-types/toolbar/toolbar-button/index.d.ts.map +1 -1
- package/build-types/toolbar/toolbar-item/index.d.ts +6 -4
- package/build-types/toolbar/toolbar-item/index.d.ts.map +1 -1
- package/build-types/tree-grid/types.d.ts +7 -0
- package/build-types/tree-grid/types.d.ts.map +1 -1
- package/build-types/utils/use-deprecated-props.d.ts +9 -0
- package/build-types/utils/use-deprecated-props.d.ts.map +1 -0
- package/package.json +19 -19
- package/src/autocomplete/README.md +78 -52
- package/src/autocomplete/autocompleter-ui.tsx +0 -2
- package/src/autocomplete/index.tsx +1 -2
- package/src/autocomplete/types.ts +3 -19
- package/src/button/index.tsx +2 -0
- package/src/button/style.scss +13 -6
- package/src/button/types.ts +7 -0
- package/src/card/card-media/README.md +1 -1
- package/src/card/card-media/component.tsx +2 -1
- package/src/card/stories/index.tsx +47 -26
- package/src/checkbox-control/style.scss +1 -4
- package/src/combobox-control/index.tsx +24 -18
- package/src/combobox-control/stories/index.tsx +0 -1
- package/src/combobox-control/styles.ts +4 -4
- package/src/combobox-control/types.ts +8 -1
- package/src/custom-gradient-picker/style.scss +2 -2
- package/src/dimension-control/index.tsx +1 -1
- package/src/draggable/index.tsx +1 -9
- package/src/form-toggle/style.scss +1 -5
- package/src/form-token-field/index.tsx +7 -3
- package/src/form-token-field/styles.ts +4 -4
- package/src/form-token-field/types.ts +8 -1
- package/src/mobile/global-styles-context/index.native.js +12 -1
- package/src/mobile/link-picker/link-picker-results.native.js +3 -0
- package/src/modal/index.tsx +6 -1
- package/src/modal/style.scss +1 -1
- package/src/navigable-container/README.md +24 -13
- package/src/navigable-container/{container.js → container.tsx} +57 -27
- package/src/navigable-container/{index.js → index.tsx} +0 -1
- package/src/navigable-container/menu.tsx +100 -0
- package/src/navigable-container/stories/{navigable-menu.js → navigable-menu.tsx} +15 -10
- package/src/navigable-container/stories/{tabbable-container.js → tabbable-container.tsx} +15 -6
- package/src/navigable-container/tabbable.tsx +92 -0
- package/src/navigable-container/test/{navigable-menu.js → navigable-menu.tsx} +3 -1
- package/src/navigable-container/test/{tababble-container.js → tababble-container.tsx} +53 -24
- package/src/navigable-container/types.ts +76 -0
- package/src/palette-edit/index.tsx +45 -7
- package/src/palette-edit/stories/index.tsx +4 -0
- package/src/palette-edit/types.ts +11 -0
- package/src/sandbox/index.native.js +4 -0
- package/src/slot-fill/bubbles-virtually/fill.js +2 -1
- package/src/slot-fill/bubbles-virtually/slot-fill-provider.js +46 -60
- package/src/slot-fill/bubbles-virtually/use-slot.js +14 -41
- package/src/slot-fill/fill.js +4 -26
- package/src/slot-fill/index.js +1 -3
- package/src/slot-fill/provider.js +0 -6
- package/src/slot-fill/slot.js +0 -5
- package/src/style.scss +6 -0
- package/src/tab-panel/index.tsx +1 -1
- package/src/theme/color-algorithms.ts +1 -1
- package/src/theme/stories/index.tsx +1 -1
- package/src/theme/test/color-algorithms.ts +2 -2
- package/src/toggle-group-control/test/__snapshots__/index.tsx.snap +4 -4
- package/src/toolbar/stories/index.tsx +26 -24
- package/src/toolbar/toolbar-button/index.tsx +10 -13
- package/src/toolbar/toolbar-item/{index.js → index.tsx} +12 -3
- package/src/tree-grid/README.md +18 -0
- package/src/tree-grid/types.ts +7 -0
- package/src/utils/colors-values.js +3 -3
- package/src/utils/theme-variables.scss +4 -4
- package/src/utils/use-deprecated-props.ts +29 -0
- package/tsconfig.json +1 -0
- package/tsconfig.tsbuildinfo +1 -1
- package/src/CONTRIBUTING.md +0 -78
- package/src/README.md +0 -20
- package/src/navigable-container/menu.js +0 -62
- package/src/navigable-container/tabbable.js +0 -46
|
@@ -41,31 +41,52 @@ const meta: ComponentMeta< typeof Card > = {
|
|
|
41
41
|
export default meta;
|
|
42
42
|
|
|
43
43
|
const Template: ComponentStory< typeof Card > = ( args ) => (
|
|
44
|
-
<Card { ...args }
|
|
45
|
-
<CardHeader>
|
|
46
|
-
<Heading>CardHeader</Heading>
|
|
47
|
-
</CardHeader>
|
|
48
|
-
<CardBody>
|
|
49
|
-
<Text>CardBody</Text>
|
|
50
|
-
</CardBody>
|
|
51
|
-
<CardBody>
|
|
52
|
-
<Text>CardBody (before CardDivider)</Text>
|
|
53
|
-
</CardBody>
|
|
54
|
-
<CardDivider />
|
|
55
|
-
<CardBody>
|
|
56
|
-
<Text>CardBody (after CardDivider)</Text>
|
|
57
|
-
</CardBody>
|
|
58
|
-
<CardMedia>
|
|
59
|
-
<img
|
|
60
|
-
alt="Card Media"
|
|
61
|
-
src="https://images.unsplash.com/photo-1566125882500-87e10f726cdc?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=crop&w=1867&q=80"
|
|
62
|
-
/>
|
|
63
|
-
</CardMedia>
|
|
64
|
-
<CardFooter>
|
|
65
|
-
<Text>CardFooter</Text>
|
|
66
|
-
<Button variant="secondary">Action Button</Button>
|
|
67
|
-
</CardFooter>
|
|
68
|
-
</Card>
|
|
44
|
+
<Card { ...args } />
|
|
69
45
|
);
|
|
70
46
|
|
|
71
|
-
export const Default
|
|
47
|
+
export const Default = Template.bind( {} );
|
|
48
|
+
Default.args = {
|
|
49
|
+
children: (
|
|
50
|
+
<>
|
|
51
|
+
<CardHeader>
|
|
52
|
+
<Heading>CardHeader</Heading>
|
|
53
|
+
</CardHeader>
|
|
54
|
+
<CardBody>
|
|
55
|
+
<Text>CardBody</Text>
|
|
56
|
+
</CardBody>
|
|
57
|
+
<CardBody>
|
|
58
|
+
<Text>CardBody (before CardDivider)</Text>
|
|
59
|
+
</CardBody>
|
|
60
|
+
<CardDivider />
|
|
61
|
+
<CardBody>
|
|
62
|
+
<Text>CardBody (after CardDivider)</Text>
|
|
63
|
+
</CardBody>
|
|
64
|
+
<CardMedia>
|
|
65
|
+
<img
|
|
66
|
+
alt="Card Media"
|
|
67
|
+
src="https://images.unsplash.com/photo-1566125882500-87e10f726cdc?ixlib=rb-1.2.1&ixid=MnwxMjA3fDB8MHxwaG90by1wYWdlfHx8fGVufDB8fHx8&auto=format&fit=crop&w=1867&q=80"
|
|
68
|
+
/>
|
|
69
|
+
</CardMedia>
|
|
70
|
+
<CardFooter>
|
|
71
|
+
<Text>CardFooter</Text>
|
|
72
|
+
<Button variant="secondary">Action Button</Button>
|
|
73
|
+
</CardFooter>
|
|
74
|
+
</>
|
|
75
|
+
),
|
|
76
|
+
};
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* `CardMedia` provides a container for full-bleed content within a `Card`,
|
|
80
|
+
* such as images, video, or even just a background color. The corners will be rounded if necessary.
|
|
81
|
+
*/
|
|
82
|
+
export const FullBleedContent = Template.bind( {} );
|
|
83
|
+
FullBleedContent.args = {
|
|
84
|
+
...Default.args,
|
|
85
|
+
children: (
|
|
86
|
+
<CardMedia>
|
|
87
|
+
<div style={ { padding: 16, background: 'beige' } }>
|
|
88
|
+
Some full bleed content
|
|
89
|
+
</div>
|
|
90
|
+
</CardMedia>
|
|
91
|
+
),
|
|
92
|
+
};
|
|
@@ -27,10 +27,7 @@ $checkbox-input-size-sm: 24px; // Width & height for small viewports.
|
|
|
27
27
|
@include reduce-motion("transition");
|
|
28
28
|
|
|
29
29
|
&:focus {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
// Only visible in Windows High Contrast mode.
|
|
33
|
-
outline: 2px solid transparent;
|
|
30
|
+
@include button-style-outset__focus(var(--wp-admin-theme-color));
|
|
34
31
|
}
|
|
35
32
|
|
|
36
33
|
&:checked,
|
|
@@ -32,6 +32,7 @@ import { useControlledValue } from '../utils/hooks';
|
|
|
32
32
|
import { normalizeTextString } from '../utils/strings';
|
|
33
33
|
import type { ComboboxControlOption, ComboboxControlProps } from './types';
|
|
34
34
|
import type { TokenInputProps } from '../form-token-field/types';
|
|
35
|
+
import { useDeprecated36pxDefaultSizeProp } from '../utils/use-deprecated-props';
|
|
35
36
|
|
|
36
37
|
const noop = () => {};
|
|
37
38
|
|
|
@@ -104,23 +105,28 @@ const getIndexOfMatchingSuggestion = (
|
|
|
104
105
|
* }
|
|
105
106
|
* ```
|
|
106
107
|
*/
|
|
107
|
-
function ComboboxControl( {
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
108
|
+
function ComboboxControl( props: ComboboxControlProps ) {
|
|
109
|
+
const {
|
|
110
|
+
__nextHasNoMarginBottom = false,
|
|
111
|
+
__next40pxDefaultSize = false,
|
|
112
|
+
value: valueProp,
|
|
113
|
+
label,
|
|
114
|
+
options,
|
|
115
|
+
onChange: onChangeProp,
|
|
116
|
+
onFilterValueChange = noop,
|
|
117
|
+
hideLabelFromVision,
|
|
118
|
+
help,
|
|
119
|
+
allowReset = true,
|
|
120
|
+
className,
|
|
121
|
+
messages = {
|
|
122
|
+
selected: __( 'Item selected.' ),
|
|
123
|
+
},
|
|
124
|
+
__experimentalRenderItem,
|
|
125
|
+
} = useDeprecated36pxDefaultSizeProp< ComboboxControlProps >(
|
|
126
|
+
props,
|
|
127
|
+
'wp.components.ComboboxControl'
|
|
128
|
+
);
|
|
129
|
+
|
|
124
130
|
const [ value, setValue ] = useControlledValue( {
|
|
125
131
|
value: valueProp,
|
|
126
132
|
onChange: onChangeProp,
|
|
@@ -314,7 +320,7 @@ function ComboboxControl( {
|
|
|
314
320
|
onKeyDown={ onKeyDown }
|
|
315
321
|
>
|
|
316
322
|
<InputWrapperFlex
|
|
317
|
-
|
|
323
|
+
__next40pxDefaultSize={ __next40pxDefaultSize }
|
|
318
324
|
>
|
|
319
325
|
<FlexBlock>
|
|
320
326
|
<TokenInput
|
|
@@ -12,9 +12,9 @@ import { space } from '../ui/utils/space';
|
|
|
12
12
|
import type { ComboboxControlProps } from './types';
|
|
13
13
|
|
|
14
14
|
const deprecatedDefaultSize = ( {
|
|
15
|
-
|
|
16
|
-
}: Pick< ComboboxControlProps, '
|
|
17
|
-
!
|
|
15
|
+
__next40pxDefaultSize,
|
|
16
|
+
}: Pick< ComboboxControlProps, '__next40pxDefaultSize' > ) =>
|
|
17
|
+
! __next40pxDefaultSize &&
|
|
18
18
|
css`
|
|
19
19
|
height: 28px; // 30px - 2px vertical borders on parent container
|
|
20
20
|
padding-left: ${ space( 1 ) };
|
|
@@ -22,7 +22,7 @@ const deprecatedDefaultSize = ( {
|
|
|
22
22
|
`;
|
|
23
23
|
|
|
24
24
|
export const InputWrapperFlex = styled( Flex )`
|
|
25
|
-
height:
|
|
25
|
+
height: 38px; // 40px - 2px vertical borders on parent container
|
|
26
26
|
padding-left: ${ space( 2 ) };
|
|
27
27
|
padding-right: ${ space( 2 ) };
|
|
28
28
|
|
|
@@ -26,11 +26,18 @@ export type ComboboxControlProps = Pick<
|
|
|
26
26
|
item: ComboboxControlOption;
|
|
27
27
|
} ) => React.ReactNode;
|
|
28
28
|
/**
|
|
29
|
-
*
|
|
29
|
+
* Deprecated. Use `__next40pxDefaultSize` instead.
|
|
30
30
|
*
|
|
31
31
|
* @default false
|
|
32
|
+
* @deprecated
|
|
32
33
|
*/
|
|
33
34
|
__next36pxDefaultSize?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* Start opting into the larger default height that will become the default size in a future version.
|
|
37
|
+
*
|
|
38
|
+
* @default false
|
|
39
|
+
*/
|
|
40
|
+
__next40pxDefaultSize?: boolean;
|
|
34
41
|
/**
|
|
35
42
|
* Show a reset button to clear the input.
|
|
36
43
|
*
|
|
@@ -76,14 +76,14 @@ $components-custom-gradient-picker__padding: $grid-unit-20; // 48px container, 1
|
|
|
76
76
|
padding: 0;
|
|
77
77
|
|
|
78
78
|
// Shadow and stroke.
|
|
79
|
-
box-shadow: inset 0 0 0 var(--wp-admin-border-width-focus) $white, 0 0 $border-width-focus 0 rgba($black, 0.25);
|
|
79
|
+
box-shadow: inset 0 0 0 var(--wp-admin-border-width-focus) $white, 0 0 $border-width-focus-fallback 0 rgba($black, 0.25);
|
|
80
80
|
|
|
81
81
|
// Windows High Contrast mode will show this outline, but not the box-shadow.
|
|
82
82
|
outline: 2px solid transparent;
|
|
83
83
|
|
|
84
84
|
&:focus,
|
|
85
85
|
&.is-active {
|
|
86
|
-
box-shadow: inset 0 0 0 calc(var(--wp-admin-border-width-focus) * 2) $white, 0 0 $border-width-focus 0 rgba($black, 0.25);
|
|
86
|
+
box-shadow: inset 0 0 0 calc(var(--wp-admin-border-width-focus) * 2) $white, 0 0 $border-width-focus-fallback 0 rgba($black, 0.25);
|
|
87
87
|
|
|
88
88
|
// Windows High Contrast mode will show this outline, but not the box-shadow.
|
|
89
89
|
outline: $border-width-tab solid transparent;
|
|
@@ -23,8 +23,8 @@ import type { SelectControlSingleSelectionProps } from '../select-control/types'
|
|
|
23
23
|
* This feature is still experimental. “Experimental” means this is an early implementation subject to drastic and breaking changes.
|
|
24
24
|
*
|
|
25
25
|
* ```jsx
|
|
26
|
-
* import { useState } from 'react';
|
|
27
26
|
* import { __experimentalDimensionControl as DimensionControl } from '@wordpress/components';
|
|
27
|
+
* import { useState } from '@wordpress/element';
|
|
28
28
|
*
|
|
29
29
|
* export default function MyCustomDimensionControl() {
|
|
30
30
|
* const [ paddingSize, setPaddingSize ] = useState( '' );
|
package/src/draggable/index.tsx
CHANGED
|
@@ -212,14 +212,8 @@ export function Draggable( {
|
|
|
212
212
|
// Update cursor to 'grabbing', document wide.
|
|
213
213
|
ownerDocument.body.classList.add( bodyClass );
|
|
214
214
|
|
|
215
|
-
// Allow the Synthetic Event to be accessed from asynchronous code.
|
|
216
|
-
// https://reactjs.org/docs/events.html#event-pooling
|
|
217
|
-
event.persist();
|
|
218
|
-
|
|
219
|
-
let timerId: number | undefined;
|
|
220
|
-
|
|
221
215
|
if ( onDragStart ) {
|
|
222
|
-
|
|
216
|
+
onDragStart( event );
|
|
223
217
|
}
|
|
224
218
|
|
|
225
219
|
cleanup.current = () => {
|
|
@@ -236,8 +230,6 @@ export function Draggable( {
|
|
|
236
230
|
ownerDocument.body.classList.remove( bodyClass );
|
|
237
231
|
|
|
238
232
|
ownerDocument.removeEventListener( 'dragover', throttledDragOver );
|
|
239
|
-
|
|
240
|
-
clearTimeout( timerId );
|
|
241
233
|
};
|
|
242
234
|
}
|
|
243
235
|
|
|
@@ -44,11 +44,7 @@ $toggle-border-width: 1px;
|
|
|
44
44
|
}
|
|
45
45
|
|
|
46
46
|
.components-form-toggle__input:focus + .components-form-toggle__track {
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
// Windows High Contrast mode will show this outline, but not the box-shadow.
|
|
50
|
-
outline: 2px solid transparent;
|
|
51
|
-
outline-offset: 2px;
|
|
47
|
+
@include button-style-outset__focus($components-color-accent);
|
|
52
48
|
}
|
|
53
49
|
|
|
54
50
|
&.is-checked {
|
|
@@ -27,6 +27,7 @@ import {
|
|
|
27
27
|
StyledLabel,
|
|
28
28
|
} from '../base-control/styles/base-control-styles';
|
|
29
29
|
import { Spacer } from '../spacer';
|
|
30
|
+
import { useDeprecated36pxDefaultSizeProp } from '../utils/use-deprecated-props';
|
|
30
31
|
|
|
31
32
|
const identity = ( value: string ) => value;
|
|
32
33
|
|
|
@@ -69,10 +70,13 @@ export function FormTokenField( props: FormTokenFieldProps ) {
|
|
|
69
70
|
__experimentalExpandOnFocus = false,
|
|
70
71
|
__experimentalValidateInput = () => true,
|
|
71
72
|
__experimentalShowHowTo = true,
|
|
72
|
-
|
|
73
|
+
__next40pxDefaultSize = false,
|
|
73
74
|
__experimentalAutoSelectFirstMatch = false,
|
|
74
75
|
__nextHasNoMarginBottom = false,
|
|
75
|
-
} =
|
|
76
|
+
} = useDeprecated36pxDefaultSizeProp< FormTokenFieldProps >(
|
|
77
|
+
props,
|
|
78
|
+
'wp.components.FormTokenField'
|
|
79
|
+
);
|
|
76
80
|
|
|
77
81
|
const instanceId = useInstanceId( FormTokenField );
|
|
78
82
|
|
|
@@ -702,7 +706,7 @@ export function FormTokenField( props: FormTokenFieldProps ) {
|
|
|
702
706
|
align="center"
|
|
703
707
|
gap={ 1 }
|
|
704
708
|
wrap={ true }
|
|
705
|
-
|
|
709
|
+
__next40pxDefaultSize={ __next40pxDefaultSize }
|
|
706
710
|
hasTokens={ !! value.length }
|
|
707
711
|
>
|
|
708
712
|
{ renderTokensAndInput() }
|
|
@@ -11,22 +11,22 @@ import { Flex } from '../flex';
|
|
|
11
11
|
import { space } from '../ui/utils/space';
|
|
12
12
|
|
|
13
13
|
type TokensAndInputWrapperProps = {
|
|
14
|
-
|
|
14
|
+
__next40pxDefaultSize: boolean;
|
|
15
15
|
hasTokens: boolean;
|
|
16
16
|
};
|
|
17
17
|
|
|
18
18
|
const deprecatedPaddings = ( {
|
|
19
|
-
|
|
19
|
+
__next40pxDefaultSize,
|
|
20
20
|
hasTokens,
|
|
21
21
|
}: TokensAndInputWrapperProps ) =>
|
|
22
|
-
!
|
|
22
|
+
! __next40pxDefaultSize &&
|
|
23
23
|
css`
|
|
24
24
|
padding-top: ${ space( hasTokens ? 1 : 0.5 ) };
|
|
25
25
|
padding-bottom: ${ space( hasTokens ? 1 : 0.5 ) };
|
|
26
26
|
`;
|
|
27
27
|
|
|
28
28
|
export const TokensAndInputWrapperFlex = styled( Flex )`
|
|
29
|
-
padding:
|
|
29
|
+
padding: 7px;
|
|
30
30
|
|
|
31
31
|
${ deprecatedPaddings }
|
|
32
32
|
`;
|
|
@@ -151,13 +151,20 @@ export interface FormTokenFieldProps
|
|
|
151
151
|
* @default true
|
|
152
152
|
*/
|
|
153
153
|
__experimentalShowHowTo?: boolean;
|
|
154
|
+
/**
|
|
155
|
+
* Deprecated. Use `__next40pxDefaultSize` instead.
|
|
156
|
+
*
|
|
157
|
+
* @default false
|
|
158
|
+
* @deprecated
|
|
159
|
+
*/
|
|
160
|
+
__next36pxDefaultSize?: boolean;
|
|
154
161
|
/**
|
|
155
162
|
* Start opting into the larger default height that will become the
|
|
156
163
|
* default size in a future version.
|
|
157
164
|
*
|
|
158
165
|
* @default false
|
|
159
166
|
*/
|
|
160
|
-
|
|
167
|
+
__next40pxDefaultSize?: boolean;
|
|
161
168
|
/**
|
|
162
169
|
* If true, the select the first matching suggestion when the user presses
|
|
163
170
|
* the Enter key (or space when tokenizeOnSpace is true).
|
|
@@ -26,9 +26,20 @@ export const getMergedGlobalStyles = (
|
|
|
26
26
|
blockName,
|
|
27
27
|
fontSizes
|
|
28
28
|
) => {
|
|
29
|
+
// Current support for general styles and blocks.
|
|
29
30
|
const baseGlobalColors = {
|
|
30
|
-
baseColors:
|
|
31
|
+
baseColors: {
|
|
32
|
+
color: baseGlobalStyles?.color,
|
|
33
|
+
typography: baseGlobalStyles?.typography,
|
|
34
|
+
elements: {
|
|
35
|
+
link: baseGlobalStyles?.elements?.link,
|
|
36
|
+
},
|
|
37
|
+
blocks: {
|
|
38
|
+
'core/button': baseGlobalStyles?.blocks?.[ 'core/button' ],
|
|
39
|
+
},
|
|
40
|
+
},
|
|
31
41
|
};
|
|
42
|
+
|
|
32
43
|
const blockStyleAttributes = Object.fromEntries(
|
|
33
44
|
Object.entries( blockAttributes ?? {} ).filter( ( [ key ] ) =>
|
|
34
45
|
BLOCK_STYLE_ATTRIBUTES.includes( key )
|
|
@@ -74,6 +74,9 @@ export default function LinkPickerResults( {
|
|
|
74
74
|
return {
|
|
75
75
|
fetchMoreSuggestions: debounce( fetchMore, REQUEST_DEBOUNCE_DELAY ),
|
|
76
76
|
};
|
|
77
|
+
// Disable eslint rule for now, to avoid introducing a regression
|
|
78
|
+
// (see https://github.com/WordPress/gutenberg/pull/23922#discussion_r1170634879).
|
|
79
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
77
80
|
}, [] );
|
|
78
81
|
|
|
79
82
|
// Prevent setting state when unmounted.
|
package/src/modal/index.tsx
CHANGED
|
@@ -252,7 +252,12 @@ function UnforwardedModal(
|
|
|
252
252
|
) }
|
|
253
253
|
</div>
|
|
254
254
|
) }
|
|
255
|
-
<div
|
|
255
|
+
<div
|
|
256
|
+
ref={ childrenContainerRef }
|
|
257
|
+
className="components-modal__children-container"
|
|
258
|
+
>
|
|
259
|
+
{ children }
|
|
260
|
+
</div>
|
|
256
261
|
</div>
|
|
257
262
|
</div>
|
|
258
263
|
</StyleProvider>
|
package/src/modal/style.scss
CHANGED
|
@@ -2,38 +2,49 @@
|
|
|
2
2
|
|
|
3
3
|
`NavigableContainer` is a React component to render a container navigable using the keyboard. Only things that are focusable can be navigated to. It will currently always be a `div`.
|
|
4
4
|
|
|
5
|
-
`NavigableContainer` is exported as two
|
|
5
|
+
`NavigableContainer` is exported as two components: `NavigableMenu` and `TabbableContainer`. `NavigableContainer` itself is **not** exported. `NavigableMenu` and `TabbableContainer` have the props listed below. Any other props will be passed through to the `div`.
|
|
6
6
|
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
## Props
|
|
10
10
|
|
|
11
|
-
These are the props that `NavigableMenu` and `TabbableContainer`. Any props which are specific to one
|
|
11
|
+
These are the props that `NavigableMenu` and `TabbableContainer`. Any props which are specific to one component are labelled appropriately.
|
|
12
12
|
|
|
13
|
-
###
|
|
13
|
+
### `cycle`: `boolean`
|
|
14
14
|
|
|
15
|
-
A
|
|
15
|
+
A boolean which tells the component whether or not to cycle from the end back to the beginning and vice versa.
|
|
16
16
|
|
|
17
|
-
- Type: `Function`
|
|
18
17
|
- Required: No
|
|
18
|
+
- default: `true`
|
|
19
19
|
|
|
20
|
-
###
|
|
20
|
+
### `eventToOffset`: `( event: KeyboardEvent ) => -1 | 0 | 1 | undefined`
|
|
21
21
|
|
|
22
|
-
|
|
22
|
+
(TabbableContainer only)
|
|
23
|
+
Gets an offset, given an event.
|
|
24
|
+
|
|
25
|
+
- Required: No
|
|
26
|
+
|
|
27
|
+
### `onKeydown`: `( event: KeyboardEvent ) => void`
|
|
28
|
+
|
|
29
|
+
A callback invoked on the keydown event.
|
|
30
|
+
|
|
31
|
+
- Required: No
|
|
32
|
+
|
|
33
|
+
### `onNavigate`: `( index: number, focusable: HTMLElement ) => void`
|
|
34
|
+
|
|
35
|
+
A callback invoked when the menu navigates to one of its children passing the index and child as an argument
|
|
23
36
|
|
|
24
|
-
- Type: `Boolean`
|
|
25
37
|
- Required: No
|
|
26
|
-
- default: true
|
|
27
38
|
|
|
28
|
-
### orientation
|
|
39
|
+
### `orientation`: `'vertical' | 'horizontal' | 'both'`
|
|
29
40
|
|
|
30
|
-
|
|
41
|
+
(NavigableMenu only)
|
|
42
|
+
The orientation of the menu. It could be "vertical", "horizontal", or "both".
|
|
31
43
|
|
|
32
|
-
- Type: `String`
|
|
33
44
|
- Required: No
|
|
34
45
|
- Default: `"vertical"`
|
|
35
46
|
|
|
36
|
-
##
|
|
47
|
+
## Components
|
|
37
48
|
|
|
38
49
|
### NavigableMenu
|
|
39
50
|
|
|
@@ -1,14 +1,23 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* External dependencies
|
|
3
|
+
*/
|
|
4
|
+
import type { ForwardedRef } from 'react';
|
|
5
|
+
|
|
2
6
|
/**
|
|
3
7
|
* WordPress dependencies
|
|
4
8
|
*/
|
|
5
9
|
import { Component, forwardRef } from '@wordpress/element';
|
|
6
10
|
import { focus } from '@wordpress/dom';
|
|
7
11
|
|
|
12
|
+
/**
|
|
13
|
+
* Internal dependencies
|
|
14
|
+
*/
|
|
15
|
+
import type { NavigableContainerProps } from './types';
|
|
16
|
+
|
|
8
17
|
const noop = () => {};
|
|
9
18
|
const MENU_ITEM_ROLES = [ 'menuitem', 'menuitemradio', 'menuitemcheckbox' ];
|
|
10
19
|
|
|
11
|
-
function cycleValue( value, total, offset ) {
|
|
20
|
+
function cycleValue( value: number, total: number, offset: number ) {
|
|
12
21
|
const nextValue = value + offset;
|
|
13
22
|
if ( nextValue < 0 ) {
|
|
14
23
|
return total + nextValue;
|
|
@@ -19,9 +28,11 @@ function cycleValue( value, total, offset ) {
|
|
|
19
28
|
return nextValue;
|
|
20
29
|
}
|
|
21
30
|
|
|
22
|
-
class NavigableContainer extends Component {
|
|
23
|
-
|
|
24
|
-
|
|
31
|
+
class NavigableContainer extends Component< NavigableContainerProps > {
|
|
32
|
+
container?: HTMLDivElement;
|
|
33
|
+
|
|
34
|
+
constructor( args: NavigableContainerProps ) {
|
|
35
|
+
super( args );
|
|
25
36
|
this.onKeyDown = this.onKeyDown.bind( this );
|
|
26
37
|
this.bindContainer = this.bindContainer.bind( this );
|
|
27
38
|
|
|
@@ -30,21 +41,27 @@ class NavigableContainer extends Component {
|
|
|
30
41
|
}
|
|
31
42
|
|
|
32
43
|
componentDidMount() {
|
|
44
|
+
if ( ! this.container ) {
|
|
45
|
+
return;
|
|
46
|
+
}
|
|
47
|
+
|
|
33
48
|
// We use DOM event listeners instead of React event listeners
|
|
34
49
|
// because we want to catch events from the underlying DOM tree
|
|
35
50
|
// The React Tree can be different from the DOM tree when using
|
|
36
51
|
// portals. Block Toolbars for instance are rendered in a separate
|
|
37
52
|
// React Trees.
|
|
38
53
|
this.container.addEventListener( 'keydown', this.onKeyDown );
|
|
39
|
-
this.container.addEventListener( 'focus', this.onFocus );
|
|
40
54
|
}
|
|
41
55
|
|
|
42
56
|
componentWillUnmount() {
|
|
57
|
+
if ( ! this.container ) {
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
|
|
43
61
|
this.container.removeEventListener( 'keydown', this.onKeyDown );
|
|
44
|
-
this.container.removeEventListener( 'focus', this.onFocus );
|
|
45
62
|
}
|
|
46
63
|
|
|
47
|
-
bindContainer( ref ) {
|
|
64
|
+
bindContainer( ref: HTMLDivElement ) {
|
|
48
65
|
const { forwardedRef } = this.props;
|
|
49
66
|
this.container = ref;
|
|
50
67
|
|
|
@@ -55,10 +72,14 @@ class NavigableContainer extends Component {
|
|
|
55
72
|
}
|
|
56
73
|
}
|
|
57
74
|
|
|
58
|
-
getFocusableContext( target ) {
|
|
75
|
+
getFocusableContext( target: Element ) {
|
|
76
|
+
if ( ! this.container ) {
|
|
77
|
+
return null;
|
|
78
|
+
}
|
|
79
|
+
|
|
59
80
|
const { onlyBrowserTabstops } = this.props;
|
|
60
81
|
const finder = onlyBrowserTabstops ? focus.tabbable : focus.focusable;
|
|
61
|
-
const focusables = finder.find( this.container );
|
|
82
|
+
const focusables = finder.find( this.container ) as HTMLElement[];
|
|
62
83
|
|
|
63
84
|
const index = this.getFocusableIndex( focusables, target );
|
|
64
85
|
if ( index > -1 && target ) {
|
|
@@ -67,14 +88,11 @@ class NavigableContainer extends Component {
|
|
|
67
88
|
return null;
|
|
68
89
|
}
|
|
69
90
|
|
|
70
|
-
getFocusableIndex( focusables, target ) {
|
|
71
|
-
|
|
72
|
-
if ( directIndex !== -1 ) {
|
|
73
|
-
return directIndex;
|
|
74
|
-
}
|
|
91
|
+
getFocusableIndex( focusables: Element[], target: Element ) {
|
|
92
|
+
return focusables.indexOf( target );
|
|
75
93
|
}
|
|
76
94
|
|
|
77
|
-
onKeyDown( event ) {
|
|
95
|
+
onKeyDown( event: KeyboardEvent ) {
|
|
78
96
|
if ( this.props.onKeyDown ) {
|
|
79
97
|
this.props.onKeyDown( event );
|
|
80
98
|
}
|
|
@@ -98,15 +116,13 @@ class NavigableContainer extends Component {
|
|
|
98
116
|
// from scrolling. The preventDefault also prevents Voiceover from
|
|
99
117
|
// 'handling' the event, as voiceover will try to use arrow keys
|
|
100
118
|
// for highlighting text.
|
|
101
|
-
const targetRole =
|
|
119
|
+
const targetRole = (
|
|
120
|
+
event.target as HTMLDivElement | null
|
|
121
|
+
)?.getAttribute( 'role' );
|
|
102
122
|
const targetHasMenuItemRole =
|
|
103
|
-
MENU_ITEM_ROLES.includes( targetRole );
|
|
104
|
-
|
|
105
|
-
// `preventDefault()` on tab to avoid having the browser move the focus
|
|
106
|
-
// after this component has already moved it.
|
|
107
|
-
const isTab = event.code === 'Tab';
|
|
123
|
+
!! targetRole && MENU_ITEM_ROLES.includes( targetRole );
|
|
108
124
|
|
|
109
|
-
if ( targetHasMenuItemRole
|
|
125
|
+
if ( targetHasMenuItemRole ) {
|
|
110
126
|
event.preventDefault();
|
|
111
127
|
}
|
|
112
128
|
}
|
|
@@ -115,9 +131,13 @@ class NavigableContainer extends Component {
|
|
|
115
131
|
return;
|
|
116
132
|
}
|
|
117
133
|
|
|
118
|
-
const
|
|
119
|
-
|
|
120
|
-
)
|
|
134
|
+
const activeElement = ( event.target as HTMLElement | null )
|
|
135
|
+
?.ownerDocument?.activeElement;
|
|
136
|
+
if ( ! activeElement ) {
|
|
137
|
+
return;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
const context = getFocusableContext( activeElement );
|
|
121
141
|
if ( ! context ) {
|
|
122
142
|
return;
|
|
123
143
|
}
|
|
@@ -126,9 +146,16 @@ class NavigableContainer extends Component {
|
|
|
126
146
|
const nextIndex = cycle
|
|
127
147
|
? cycleValue( index, focusables.length, offset )
|
|
128
148
|
: index + offset;
|
|
149
|
+
|
|
129
150
|
if ( nextIndex >= 0 && nextIndex < focusables.length ) {
|
|
130
151
|
focusables[ nextIndex ].focus();
|
|
131
152
|
onNavigate( nextIndex, focusables[ nextIndex ] );
|
|
153
|
+
|
|
154
|
+
// `preventDefault()` on tab to avoid having the browser move the focus
|
|
155
|
+
// after this component has already moved it.
|
|
156
|
+
if ( event.code === 'Tab' ) {
|
|
157
|
+
event.preventDefault();
|
|
158
|
+
}
|
|
132
159
|
}
|
|
133
160
|
}
|
|
134
161
|
|
|
@@ -152,7 +179,10 @@ class NavigableContainer extends Component {
|
|
|
152
179
|
}
|
|
153
180
|
}
|
|
154
181
|
|
|
155
|
-
const forwardedNavigableContainer = (
|
|
182
|
+
const forwardedNavigableContainer = (
|
|
183
|
+
props: NavigableContainerProps,
|
|
184
|
+
ref: ForwardedRef< HTMLDivElement >
|
|
185
|
+
) => {
|
|
156
186
|
return <NavigableContainer { ...props } forwardedRef={ ref } />;
|
|
157
187
|
};
|
|
158
188
|
forwardedNavigableContainer.displayName = 'NavigableContainer';
|