@wordpress/components 25.12.0 → 25.13.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.
Files changed (155) hide show
  1. package/CHANGELOG.md +28 -0
  2. package/build/angle-picker-control/index.js +0 -1
  3. package/build/angle-picker-control/index.js.map +1 -1
  4. package/build/custom-select-control-v2/index.js +87 -0
  5. package/build/custom-select-control-v2/index.js.map +1 -0
  6. package/build/custom-select-control-v2/styles.js +85 -0
  7. package/build/custom-select-control-v2/styles.js.map +1 -0
  8. package/build/custom-select-control-v2/types.js +6 -0
  9. package/build/custom-select-control-v2/types.js.map +1 -0
  10. package/build/dropdown-menu-v2-ariakit/index.js +49 -20
  11. package/build/dropdown-menu-v2-ariakit/index.js.map +1 -1
  12. package/build/dropdown-menu-v2-ariakit/styles.js +82 -59
  13. package/build/dropdown-menu-v2-ariakit/styles.js.map +1 -1
  14. package/build/dropdown-menu-v2-ariakit/types.js.map +1 -1
  15. package/build/form-token-field/index.js +6 -2
  16. package/build/form-token-field/index.js.map +1 -1
  17. package/build/form-token-field/token-input.js.map +1 -1
  18. package/build/form-token-field/types.js.map +1 -1
  19. package/build/heading/hook.js +6 -3
  20. package/build/heading/hook.js.map +1 -1
  21. package/build/heading/types.js.map +1 -1
  22. package/build/mobile/utils/alignments.native.js +1 -1
  23. package/build/mobile/utils/alignments.native.js.map +1 -1
  24. package/build/private-apis.js +3 -2
  25. package/build/private-apis.js.map +1 -1
  26. package/build/slot-fill/types.js.map +1 -1
  27. package/build/tabs/index.js +6 -4
  28. package/build/tabs/index.js.map +1 -1
  29. package/build/tabs/tab.js +2 -2
  30. package/build/tabs/tab.js.map +1 -1
  31. package/build/tabs/tabpanel.js +1 -1
  32. package/build/tabs/tabpanel.js.map +1 -1
  33. package/build/text/types.js.map +1 -1
  34. package/build/tools-panel/tools-panel-item/hook.js +5 -1
  35. package/build/tools-panel/tools-panel-item/hook.js.map +1 -1
  36. package/build-module/angle-picker-control/index.js +0 -1
  37. package/build-module/angle-picker-control/index.js.map +1 -1
  38. package/build-module/custom-select-control-v2/index.js +74 -0
  39. package/build-module/custom-select-control-v2/index.js.map +1 -0
  40. package/build-module/custom-select-control-v2/styles.js +71 -0
  41. package/build-module/custom-select-control-v2/styles.js.map +1 -0
  42. package/build-module/custom-select-control-v2/types.js +2 -0
  43. package/build-module/custom-select-control-v2/types.js.map +1 -0
  44. package/build-module/dropdown-menu-v2-ariakit/index.js +46 -18
  45. package/build-module/dropdown-menu-v2-ariakit/index.js.map +1 -1
  46. package/build-module/dropdown-menu-v2-ariakit/styles.js +69 -40
  47. package/build-module/dropdown-menu-v2-ariakit/styles.js.map +1 -1
  48. package/build-module/dropdown-menu-v2-ariakit/types.js.map +1 -1
  49. package/build-module/form-token-field/index.js +6 -2
  50. package/build-module/form-token-field/index.js.map +1 -1
  51. package/build-module/form-token-field/token-input.js.map +1 -1
  52. package/build-module/form-token-field/types.js.map +1 -1
  53. package/build-module/heading/hook.js +6 -3
  54. package/build-module/heading/hook.js.map +1 -1
  55. package/build-module/heading/types.js.map +1 -1
  56. package/build-module/mobile/utils/alignments.native.js +1 -1
  57. package/build-module/mobile/utils/alignments.native.js.map +1 -1
  58. package/build-module/private-apis.js +4 -3
  59. package/build-module/private-apis.js.map +1 -1
  60. package/build-module/slot-fill/types.js.map +1 -1
  61. package/build-module/tabs/index.js +7 -5
  62. package/build-module/tabs/index.js.map +1 -1
  63. package/build-module/tabs/tab.js +4 -4
  64. package/build-module/tabs/tab.js.map +1 -1
  65. package/build-module/tabs/tabpanel.js +3 -3
  66. package/build-module/tabs/tabpanel.js.map +1 -1
  67. package/build-module/text/types.js.map +1 -1
  68. package/build-module/tools-panel/tools-panel-item/hook.js +6 -2
  69. package/build-module/tools-panel/tools-panel-item/hook.js.map +1 -1
  70. package/build-style/style-rtl.css +31 -5
  71. package/build-style/style.css +31 -5
  72. package/build-types/angle-picker-control/index.d.ts.map +1 -1
  73. package/build-types/box-control/stories/index.story.d.ts +1944 -0
  74. package/build-types/box-control/stories/index.story.d.ts.map +1 -0
  75. package/build-types/color-palette/styles.d.ts +4 -1
  76. package/build-types/color-palette/styles.d.ts.map +1 -1
  77. package/build-types/custom-select-control-v2/index.d.ts +6 -0
  78. package/build-types/custom-select-control-v2/index.d.ts.map +1 -0
  79. package/build-types/custom-select-control-v2/stories/index.story.d.ts +19 -0
  80. package/build-types/custom-select-control-v2/stories/index.story.d.ts.map +1 -0
  81. package/build-types/custom-select-control-v2/styles.d.ts +47 -0
  82. package/build-types/custom-select-control-v2/styles.d.ts.map +1 -0
  83. package/build-types/custom-select-control-v2/types.d.ts +57 -0
  84. package/build-types/custom-select-control-v2/types.d.ts.map +1 -0
  85. package/build-types/date-time/date/styles.d.ts +4 -1
  86. package/build-types/date-time/date/styles.d.ts.map +1 -1
  87. package/build-types/dropdown-menu-v2-ariakit/index.d.ts +11 -2
  88. package/build-types/dropdown-menu-v2-ariakit/index.d.ts.map +1 -1
  89. package/build-types/dropdown-menu-v2-ariakit/stories/index.story.d.ts.map +1 -1
  90. package/build-types/dropdown-menu-v2-ariakit/styles.d.ts +26 -18
  91. package/build-types/dropdown-menu-v2-ariakit/styles.d.ts.map +1 -1
  92. package/build-types/dropdown-menu-v2-ariakit/types.d.ts +0 -6
  93. package/build-types/dropdown-menu-v2-ariakit/types.d.ts.map +1 -1
  94. package/build-types/form-token-field/index.d.ts.map +1 -1
  95. package/build-types/form-token-field/token-input.d.ts.map +1 -1
  96. package/build-types/form-token-field/types.d.ts +1 -1
  97. package/build-types/form-token-field/types.d.ts.map +1 -1
  98. package/build-types/heading/component.d.ts +4 -1
  99. package/build-types/heading/component.d.ts.map +1 -1
  100. package/build-types/heading/hook.d.ts.map +1 -1
  101. package/build-types/heading/types.d.ts +20 -1
  102. package/build-types/heading/types.d.ts.map +1 -1
  103. package/build-types/navigation/styles/navigation-styles.d.ts +4 -1
  104. package/build-types/navigation/styles/navigation-styles.d.ts.map +1 -1
  105. package/build-types/palette-edit/styles.d.ts +4 -1
  106. package/build-types/palette-edit/styles.d.ts.map +1 -1
  107. package/build-types/private-apis.d.ts.map +1 -1
  108. package/build-types/slot-fill/bubbles-virtually/slot.d.ts +1 -1
  109. package/build-types/slot-fill/types.d.ts +16 -6
  110. package/build-types/slot-fill/types.d.ts.map +1 -1
  111. package/build-types/tabs/index.d.ts +1 -0
  112. package/build-types/tabs/index.d.ts.map +1 -1
  113. package/build-types/tabs/stories/index.story.d.ts.map +1 -1
  114. package/build-types/text/types.d.ts +15 -2
  115. package/build-types/text/types.d.ts.map +1 -1
  116. package/build-types/tools-panel/tools-panel-item/hook.d.ts.map +1 -1
  117. package/package.json +19 -19
  118. package/src/angle-picker-control/index.tsx +0 -1
  119. package/src/box-control/stories/index.story.tsx +82 -0
  120. package/src/button/style.scss +10 -2
  121. package/src/combobox-control/README.md +1 -3
  122. package/src/custom-select-control-v2/README.md +73 -0
  123. package/src/custom-select-control-v2/index.tsx +99 -0
  124. package/src/custom-select-control-v2/stories/index.story.tsx +149 -0
  125. package/src/custom-select-control-v2/styles.ts +76 -0
  126. package/src/custom-select-control-v2/types.ts +63 -0
  127. package/src/dropdown-menu-v2-ariakit/README.md +19 -5
  128. package/src/dropdown-menu-v2-ariakit/index.tsx +85 -36
  129. package/src/dropdown-menu-v2-ariakit/stories/index.story.tsx +204 -90
  130. package/src/dropdown-menu-v2-ariakit/styles.ts +153 -117
  131. package/src/dropdown-menu-v2-ariakit/test/index.tsx +5 -10
  132. package/src/dropdown-menu-v2-ariakit/types.ts +0 -7
  133. package/src/form-toggle/style.scss +37 -7
  134. package/src/form-token-field/index.tsx +11 -3
  135. package/src/form-token-field/token-input.tsx +1 -3
  136. package/src/form-token-field/types.ts +1 -0
  137. package/src/heading/README.md +6 -1
  138. package/src/heading/hook.ts +6 -3
  139. package/src/heading/types.ts +23 -1
  140. package/src/mobile/utils/alignments.native.js +1 -0
  141. package/src/navigable-container/README.md +1 -1
  142. package/src/private-apis.ts +4 -2
  143. package/src/slot-fill/README.md +1 -1
  144. package/src/slot-fill/types.ts +18 -6
  145. package/src/tabs/index.tsx +12 -2
  146. package/src/tabs/stories/index.story.tsx +8 -0
  147. package/src/tabs/tab.tsx +4 -4
  148. package/src/tabs/tabpanel.tsx +3 -3
  149. package/src/tabs/test/index.tsx +19 -0
  150. package/src/text/README.md +5 -1
  151. package/src/text/types.ts +15 -2
  152. package/src/toggle-control/README.md +2 -2
  153. package/src/tools-panel/tools-panel-item/hook.ts +11 -2
  154. package/tsconfig.tsbuildinfo +1 -1
  155. package/src/box-control/stories/index.story.js +0 -75
@@ -31,9 +31,10 @@ export const DropdownMenuItem = forwardRef(function DropdownMenuItem({
31
31
  return createElement(Styled.DropdownMenuItem, {
32
32
  ref: ref,
33
33
  ...props,
34
+ accessibleWhenDisabled: true,
34
35
  hideOnClick: hideOnClick,
35
36
  store: dropdownMenuContext?.store
36
- }, prefix && createElement(Styled.ItemPrefixWrapper, null, prefix), children, suffix && createElement(Styled.ItemSuffixWrapper, null, suffix));
37
+ }, createElement(Styled.ItemPrefixWrapper, null, prefix), createElement(Styled.DropdownMenuItemContentWrapper, null, createElement(Styled.DropdownMenuItemChildrenWrapper, null, children), suffix && createElement(Styled.ItemSuffixWrapper, null, suffix)));
37
38
  });
38
39
  export const DropdownMenuCheckboxItem = forwardRef(function DropdownMenuCheckboxItem({
39
40
  suffix,
@@ -45,15 +46,22 @@ export const DropdownMenuCheckboxItem = forwardRef(function DropdownMenuCheckbox
45
46
  return createElement(Styled.DropdownMenuCheckboxItem, {
46
47
  ref: ref,
47
48
  ...props,
49
+ accessibleWhenDisabled: true,
48
50
  hideOnClick: hideOnClick,
49
51
  store: dropdownMenuContext?.store
50
52
  }, createElement(Ariakit.MenuItemCheck, {
51
53
  store: dropdownMenuContext?.store,
52
54
  render: createElement(Styled.ItemPrefixWrapper, null)
55
+ // Override some ariakit inline styles
56
+ ,
57
+ style: {
58
+ width: 'auto',
59
+ height: 'auto'
60
+ }
53
61
  }, createElement(Icon, {
54
62
  icon: check,
55
63
  size: 24
56
- })), children, suffix && createElement(Styled.ItemSuffixWrapper, null, suffix));
64
+ })), createElement(Styled.DropdownMenuItemContentWrapper, null, createElement(Styled.DropdownMenuItemChildrenWrapper, null, children), suffix && createElement(Styled.ItemSuffixWrapper, null, suffix)));
57
65
  });
58
66
  const radioCheck = createElement(SVG, {
59
67
  xmlns: "http://www.w3.org/2000/svg",
@@ -73,15 +81,22 @@ export const DropdownMenuRadioItem = forwardRef(function DropdownMenuRadioItem({
73
81
  return createElement(Styled.DropdownMenuRadioItem, {
74
82
  ref: ref,
75
83
  ...props,
84
+ accessibleWhenDisabled: true,
76
85
  hideOnClick: hideOnClick,
77
86
  store: dropdownMenuContext?.store
78
87
  }, createElement(Ariakit.MenuItemCheck, {
79
88
  store: dropdownMenuContext?.store,
80
89
  render: createElement(Styled.ItemPrefixWrapper, null)
90
+ // Override some ariakit inline styles
91
+ ,
92
+ style: {
93
+ width: 'auto',
94
+ height: 'auto'
95
+ }
81
96
  }, createElement(Icon, {
82
97
  icon: radioCheck,
83
98
  size: 24
84
- })), children, suffix);
99
+ })), createElement(Styled.DropdownMenuItemContentWrapper, null, createElement(Styled.DropdownMenuItemChildrenWrapper, null, children), suffix && createElement(Styled.ItemSuffixWrapper, null, suffix)));
85
100
  });
86
101
  export const DropdownMenuGroup = forwardRef(function DropdownMenuGroup(props, ref) {
87
102
  const dropdownMenuContext = useContext(DropdownMenuContext);
@@ -91,16 +106,8 @@ export const DropdownMenuGroup = forwardRef(function DropdownMenuGroup(props, re
91
106
  store: dropdownMenuContext?.store
92
107
  });
93
108
  });
94
- export const DropdownMenuGroupLabel = forwardRef(function DropdownMenuGroupLabel(props, ref) {
95
- const dropdownMenuContext = useContext(DropdownMenuContext);
96
- return createElement(Styled.DropdownMenuGroupLabel, {
97
- ref: ref,
98
- ...props,
99
- store: dropdownMenuContext?.store
100
- });
101
- });
102
109
  const UnconnectedDropdownMenu = (props, ref) => {
103
- var _props$placement, _trigger$props$suffix;
110
+ var _props$placement;
104
111
  const {
105
112
  // Store props
106
113
  open,
@@ -174,18 +181,25 @@ const UnconnectedDropdownMenu = (props, ref) => {
174
181
  store: dropdownMenuStore,
175
182
  render: dropdownMenuStore.parent ? cloneElement(trigger, {
176
183
  // Add submenu arrow, unless a `suffix` is explicitly specified
177
- suffix: (_trigger$props$suffix = trigger.props.suffix) !== null && _trigger$props$suffix !== void 0 ? _trigger$props$suffix : createElement(Styled.SubmenuChevronIcon, {
184
+ suffix: createElement(Fragment, null, trigger.props.suffix, createElement(Styled.SubmenuChevronIcon, {
178
185
  "aria-hidden": "true",
179
186
  icon: chevronRightSmall,
180
- size: 24
181
- })
187
+ size: 24,
188
+ preserveAspectRatio: "xMidYMid slice"
189
+ }))
182
190
  }) : trigger
183
191
  }), createElement(Styled.DropdownMenu, {
184
192
  ...otherProps,
185
193
  modal: modal,
186
- store: dropdownMenuStore,
187
- gutter: gutter !== null && gutter !== void 0 ? gutter : dropdownMenuStore.parent ? 16 : 8,
188
- shift: shift !== null && shift !== void 0 ? shift : dropdownMenuStore.parent ? -8 : 0,
194
+ store: dropdownMenuStore
195
+ // Root menu has an 8px distance from its trigger,
196
+ // otherwise 0 (which causes the submenu to slightly overlap)
197
+ ,
198
+ gutter: gutter !== null && gutter !== void 0 ? gutter : dropdownMenuStore.parent ? 0 : 8
199
+ // Align nested menu by the same (but opposite) amount
200
+ // as the menu container's padding.
201
+ ,
202
+ shift: shift !== null && shift !== void 0 ? shift : dropdownMenuStore.parent ? -4 : 0,
189
203
  hideOnHoverOutside: false,
190
204
  "data-side": appliedPlacementSide,
191
205
  variant: variant,
@@ -206,4 +220,18 @@ export const DropdownMenuSeparator = forwardRef(function DropdownMenuSeparator(p
206
220
  variant: dropdownMenuContext?.variant
207
221
  });
208
222
  });
223
+ export const DropdownMenuItemLabel = forwardRef(function DropdownMenuItemLabel(props, ref) {
224
+ return createElement(Styled.DropdownMenuItemLabel, {
225
+ numberOfLines: 1,
226
+ ref: ref,
227
+ ...props
228
+ });
229
+ });
230
+ export const DropdownMenuItemHelpText = forwardRef(function DropdownMenuItemHelpText(props, ref) {
231
+ return createElement(Styled.DropdownMenuItemHelpText, {
232
+ numberOfLines: 2,
233
+ ref: ref,
234
+ ...props
235
+ });
236
+ });
209
237
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"names":["Ariakit","forwardRef","createContext","useContext","useMemo","cloneElement","isValidElement","useCallback","isRTL","check","chevronRightSmall","SVG","Circle","useContextSystem","contextConnect","Icon","Styled","DropdownMenuContext","undefined","DropdownMenuItem","prefix","suffix","children","hideOnClick","props","ref","dropdownMenuContext","createElement","store","ItemPrefixWrapper","ItemSuffixWrapper","DropdownMenuCheckboxItem","MenuItemCheck","render","icon","size","radioCheck","xmlns","viewBox","cx","cy","r","DropdownMenuRadioItem","DropdownMenuGroup","DropdownMenuGroupLabel","UnconnectedDropdownMenu","_props$placement","_trigger$props$suffix","open","defaultOpen","onOpenChange","placement","trigger","gutter","shift","modal","variant","otherProps","parentContext","computedDirection","computedPlacement","test","replace","dropdownMenuStore","useMenuStore","parent","focusLoop","setOpen","willBeOpen","rtl","contextValue","appliedPlacementSide","useState","split","type","console","warn","hideOnEscape","event","preventDefault","wrapperProps","dir","style","direction","Fragment","MenuButton","SubmenuChevronIcon","DropdownMenu","hideOnHoverOutside","unmountOnHide","Provider","value","DropdownMenuSeparator"],"sources":["@wordpress/components/src/dropdown-menu-v2-ariakit/index.tsx"],"sourcesContent":["/**\n * External dependencies\n */\n// eslint-disable-next-line no-restricted-imports\nimport * as Ariakit from '@ariakit/react';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tforwardRef,\n\tcreateContext,\n\tuseContext,\n\tuseMemo,\n\tcloneElement,\n\tisValidElement,\n\tuseCallback,\n} from '@wordpress/element';\nimport { isRTL } from '@wordpress/i18n';\nimport { check, chevronRightSmall } from '@wordpress/icons';\nimport { SVG, Circle } from '@wordpress/primitives';\n\n/**\n * Internal dependencies\n */\nimport { useContextSystem, contextConnect } from '../context';\nimport type { WordPressComponentProps } from '../context';\nimport Icon from '../icon';\nimport type {\n\tDropdownMenuContext as DropdownMenuContextType,\n\tDropdownMenuProps,\n\tDropdownMenuGroupProps,\n\tDropdownMenuGroupLabelProps,\n\tDropdownMenuItemProps,\n\tDropdownMenuCheckboxItemProps,\n\tDropdownMenuRadioItemProps,\n\tDropdownMenuSeparatorProps,\n} from './types';\nimport * as Styled from './styles';\n\nexport const DropdownMenuContext = createContext<\n\tDropdownMenuContextType | undefined\n>( undefined );\n\nexport const DropdownMenuItem = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< DropdownMenuItemProps, 'div', false >\n>( function DropdownMenuItem(\n\t{ prefix, suffix, children, hideOnClick = true, ...props },\n\tref\n) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\n\treturn (\n\t\t<Styled.DropdownMenuItem\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\thideOnClick={ hideOnClick }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t>\n\t\t\t{ prefix && (\n\t\t\t\t<Styled.ItemPrefixWrapper>{ prefix }</Styled.ItemPrefixWrapper>\n\t\t\t) }\n\t\t\t{ children }\n\t\t\t{ suffix && (\n\t\t\t\t<Styled.ItemSuffixWrapper>{ suffix }</Styled.ItemSuffixWrapper>\n\t\t\t) }\n\t\t</Styled.DropdownMenuItem>\n\t);\n} );\n\nexport const DropdownMenuCheckboxItem = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< DropdownMenuCheckboxItemProps, 'div', false >\n>( function DropdownMenuCheckboxItem(\n\t{ suffix, children, hideOnClick = false, ...props },\n\tref\n) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\n\treturn (\n\t\t<Styled.DropdownMenuCheckboxItem\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\thideOnClick={ hideOnClick }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t>\n\t\t\t<Ariakit.MenuItemCheck\n\t\t\t\tstore={ dropdownMenuContext?.store }\n\t\t\t\trender={ <Styled.ItemPrefixWrapper /> }\n\t\t\t>\n\t\t\t\t<Icon icon={ check } size={ 24 } />\n\t\t\t</Ariakit.MenuItemCheck>\n\n\t\t\t{ children }\n\t\t\t{ suffix && (\n\t\t\t\t<Styled.ItemSuffixWrapper>{ suffix }</Styled.ItemSuffixWrapper>\n\t\t\t) }\n\t\t</Styled.DropdownMenuCheckboxItem>\n\t);\n} );\n\nconst radioCheck = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Circle cx={ 12 } cy={ 12 } r={ 3 }></Circle>\n\t</SVG>\n);\n\nexport const DropdownMenuRadioItem = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< DropdownMenuRadioItemProps, 'div', false >\n>( function DropdownMenuRadioItem(\n\t{ suffix, children, hideOnClick = false, ...props },\n\tref\n) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\n\treturn (\n\t\t<Styled.DropdownMenuRadioItem\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\thideOnClick={ hideOnClick }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t>\n\t\t\t<Ariakit.MenuItemCheck\n\t\t\t\tstore={ dropdownMenuContext?.store }\n\t\t\t\trender={ <Styled.ItemPrefixWrapper /> }\n\t\t\t>\n\t\t\t\t<Icon icon={ radioCheck } size={ 24 } />\n\t\t\t</Ariakit.MenuItemCheck>\n\t\t\t{ children }\n\t\t\t{ suffix }\n\t\t</Styled.DropdownMenuRadioItem>\n\t);\n} );\n\nexport const DropdownMenuGroup = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< DropdownMenuGroupProps, 'div', false >\n>( function DropdownMenuGroup( props, ref ) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\treturn (\n\t\t<Styled.DropdownMenuGroup\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t/>\n\t);\n} );\n\nexport const DropdownMenuGroupLabel = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< DropdownMenuGroupLabelProps, 'div', false >\n>( function DropdownMenuGroupLabel( props, ref ) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\treturn (\n\t\t<Styled.DropdownMenuGroupLabel\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t/>\n\t);\n} );\n\nconst UnconnectedDropdownMenu = (\n\tprops: WordPressComponentProps< DropdownMenuProps, 'div', false >,\n\tref: React.ForwardedRef< HTMLDivElement >\n) => {\n\tconst {\n\t\t// Store props\n\t\topen,\n\t\tdefaultOpen = false,\n\t\tonOpenChange,\n\t\tplacement,\n\n\t\t// Menu trigger props\n\t\ttrigger,\n\n\t\t// Menu props\n\t\tgutter,\n\t\tchildren,\n\t\tshift,\n\t\tmodal = true,\n\n\t\t// From internal components context\n\t\tvariant,\n\n\t\t// Rest\n\t\t...otherProps\n\t} = useContextSystem<\n\t\ttypeof props & Pick< DropdownMenuContextType, 'variant' >\n\t>( props, 'DropdownMenu' );\n\n\tconst parentContext = useContext( DropdownMenuContext );\n\n\tconst computedDirection = isRTL() ? 'rtl' : 'ltr';\n\n\t// If an explicit value for the `placement` prop is not passed,\n\t// apply a default placement of `bottom-start` for the root dropdown,\n\t// and of `right-start` for nested dropdowns.\n\tlet computedPlacement =\n\t\tprops.placement ??\n\t\t( parentContext?.store ? 'right-start' : 'bottom-start' );\n\t// Swap left/right in case of RTL direction\n\tif ( computedDirection === 'rtl' ) {\n\t\tif ( /right/.test( computedPlacement ) ) {\n\t\t\tcomputedPlacement = computedPlacement.replace(\n\t\t\t\t'right',\n\t\t\t\t'left'\n\t\t\t) as typeof computedPlacement;\n\t\t} else if ( /left/.test( computedPlacement ) ) {\n\t\t\tcomputedPlacement = computedPlacement.replace(\n\t\t\t\t'left',\n\t\t\t\t'right'\n\t\t\t) as typeof computedPlacement;\n\t\t}\n\t}\n\n\tconst dropdownMenuStore = Ariakit.useMenuStore( {\n\t\tparent: parentContext?.store,\n\t\topen,\n\t\tdefaultOpen,\n\t\tplacement: computedPlacement,\n\t\tfocusLoop: true,\n\t\tsetOpen( willBeOpen ) {\n\t\t\tonOpenChange?.( willBeOpen );\n\t\t},\n\t\trtl: computedDirection === 'rtl',\n\t} );\n\n\tconst contextValue = useMemo(\n\t\t() => ( { store: dropdownMenuStore, variant } ),\n\t\t[ dropdownMenuStore, variant ]\n\t);\n\n\t// Extract the side from the applied placement — useful for animations.\n\tconst appliedPlacementSide = dropdownMenuStore\n\t\t.useState( 'placement' )\n\t\t.split( '-' )[ 0 ];\n\n\tif (\n\t\tdropdownMenuStore.parent &&\n\t\t! ( isValidElement( trigger ) && DropdownMenuItem === trigger.type )\n\t) {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn(\n\t\t\t'For nested DropdownMenus, the `trigger` should always be a `DropdownMenuItem`.'\n\t\t);\n\t}\n\n\tconst hideOnEscape = useCallback(\n\t\t( event: React.KeyboardEvent< Element > ) => {\n\t\t\t// Pressing Escape can cause unexpected consequences (ie. exiting\n\t\t\t// full screen mode on MacOs, close parent modals...).\n\t\t\tevent.preventDefault();\n\t\t\t// Returning `true` causes the menu to hide.\n\t\t\treturn true;\n\t\t},\n\t\t[]\n\t);\n\n\tconst wrapperProps = useMemo(\n\t\t() => ( {\n\t\t\tdir: computedDirection,\n\t\t\tstyle: {\n\t\t\t\tdirection:\n\t\t\t\t\tcomputedDirection as React.CSSProperties[ 'direction' ],\n\t\t\t},\n\t\t} ),\n\t\t[ computedDirection ]\n\t);\n\n\treturn (\n\t\t<>\n\t\t\t{ /* Menu trigger */ }\n\t\t\t<Ariakit.MenuButton\n\t\t\t\tref={ ref }\n\t\t\t\tstore={ dropdownMenuStore }\n\t\t\t\trender={\n\t\t\t\t\tdropdownMenuStore.parent\n\t\t\t\t\t\t? cloneElement( trigger, {\n\t\t\t\t\t\t\t\t// Add submenu arrow, unless a `suffix` is explicitly specified\n\t\t\t\t\t\t\t\tsuffix: trigger.props.suffix ?? (\n\t\t\t\t\t\t\t\t\t<Styled.SubmenuChevronIcon\n\t\t\t\t\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\t\t\t\t\ticon={ chevronRightSmall }\n\t\t\t\t\t\t\t\t\t\tsize={ 24 }\n\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t } )\n\t\t\t\t\t\t: trigger\n\t\t\t\t}\n\t\t\t/>\n\n\t\t\t{ /* Menu popover */ }\n\t\t\t<Styled.DropdownMenu\n\t\t\t\t{ ...otherProps }\n\t\t\t\tmodal={ modal }\n\t\t\t\tstore={ dropdownMenuStore }\n\t\t\t\tgutter={ gutter ?? ( dropdownMenuStore.parent ? 16 : 8 ) }\n\t\t\t\tshift={ shift ?? ( dropdownMenuStore.parent ? -8 : 0 ) }\n\t\t\t\thideOnHoverOutside={ false }\n\t\t\t\tdata-side={ appliedPlacementSide }\n\t\t\t\tvariant={ variant }\n\t\t\t\twrapperProps={ wrapperProps }\n\t\t\t\thideOnEscape={ hideOnEscape }\n\t\t\t\tunmountOnHide\n\t\t\t>\n\t\t\t\t<DropdownMenuContext.Provider value={ contextValue }>\n\t\t\t\t\t{ children }\n\t\t\t\t</DropdownMenuContext.Provider>\n\t\t\t</Styled.DropdownMenu>\n\t\t</>\n\t);\n};\nexport const DropdownMenu = contextConnect(\n\tUnconnectedDropdownMenu,\n\t'DropdownMenu'\n);\n\nexport const DropdownMenuSeparator = forwardRef<\n\tHTMLHRElement,\n\tWordPressComponentProps< DropdownMenuSeparatorProps, 'hr', false >\n>( function DropdownMenuSeparator( props, ref ) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\treturn (\n\t\t<Styled.DropdownMenuSeparator\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t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,MAAM,aAANA,MAAM,cAANA,MAAM,GAAMU,iBAAiB,CAACE,MAAM,GAAG,EAAE,GAAG,CAAK;IAC1DX,KAAK,EAAGA,KAAK,aAALA,KAAK,cAALA,KAAK,GAAMS,iBAAiB,CAACE,MAAM,GAAG,CAAC,CAAC,GAAG,CAAK;IACxDuB,kBAAkB,EAAG,KAAO;IAC5B,aAAYjB,oBAAsB;IAClCf,OAAO,EAAGA,OAAS;IACnBwB,YAAY,EAAGA,YAAc;IAC7BH,YAAY,EAAGA,YAAc;IAC7BY,aAAa;EAAA,GAEb9D,aAAA,CAACV,mBAAmB,CAACyE,QAAQ;IAACC,KAAK,EAAGrB;EAAc,GACjDhD,QAC2B,CACV,CACpB,CAAC;AAEL,CAAC;AACD,OAAO,MAAMiE,YAAY,GAAGzE,cAAc,CACzC+B,uBAAuB,EACvB,cACD,CAAC;AAED,OAAO,MAAM+C,qBAAqB,GAAG3F,UAAU,CAG5C,SAAS2F,qBAAqBA,CAAEpE,KAAK,EAAEC,GAAG,EAAG;EAC/C,MAAMC,mBAAmB,GAAGvB,UAAU,CAAEc,mBAAoB,CAAC;EAC7D,OACCU,aAAA,CAACX,MAAM,CAAC4E,qBAAqB;IAC5BnE,GAAG,EAAGA,GAAK;IAAA,GACND,KAAK;IACVI,KAAK,EAAGF,mBAAmB,EAAEE,KAAO;IACpC4B,OAAO,EAAG9B,mBAAmB,EAAE8B;EAAS,CACxC,CAAC;AAEJ,CAAE,CAAC"}
1
+ {"version":3,"names":["Ariakit","forwardRef","createContext","useContext","useMemo","cloneElement","isValidElement","useCallback","isRTL","check","chevronRightSmall","SVG","Circle","useContextSystem","contextConnect","Icon","Styled","DropdownMenuContext","undefined","DropdownMenuItem","prefix","suffix","children","hideOnClick","props","ref","dropdownMenuContext","createElement","accessibleWhenDisabled","store","ItemPrefixWrapper","DropdownMenuItemContentWrapper","DropdownMenuItemChildrenWrapper","ItemSuffixWrapper","DropdownMenuCheckboxItem","MenuItemCheck","render","style","width","height","icon","size","radioCheck","xmlns","viewBox","cx","cy","r","DropdownMenuRadioItem","DropdownMenuGroup","UnconnectedDropdownMenu","_props$placement","open","defaultOpen","onOpenChange","placement","trigger","gutter","shift","modal","variant","otherProps","parentContext","computedDirection","computedPlacement","test","replace","dropdownMenuStore","useMenuStore","parent","focusLoop","setOpen","willBeOpen","rtl","contextValue","appliedPlacementSide","useState","split","type","console","warn","hideOnEscape","event","preventDefault","wrapperProps","dir","direction","Fragment","MenuButton","SubmenuChevronIcon","preserveAspectRatio","DropdownMenu","hideOnHoverOutside","unmountOnHide","Provider","value","DropdownMenuSeparator","DropdownMenuItemLabel","numberOfLines","DropdownMenuItemHelpText"],"sources":["@wordpress/components/src/dropdown-menu-v2-ariakit/index.tsx"],"sourcesContent":["/**\n * External dependencies\n */\n// eslint-disable-next-line no-restricted-imports\nimport * as Ariakit from '@ariakit/react';\n\n/**\n * WordPress dependencies\n */\nimport {\n\tforwardRef,\n\tcreateContext,\n\tuseContext,\n\tuseMemo,\n\tcloneElement,\n\tisValidElement,\n\tuseCallback,\n} from '@wordpress/element';\nimport { isRTL } from '@wordpress/i18n';\nimport { check, chevronRightSmall } from '@wordpress/icons';\nimport { SVG, Circle } from '@wordpress/primitives';\n\n/**\n * Internal dependencies\n */\nimport { useContextSystem, contextConnect } from '../context';\nimport type { WordPressComponentProps } from '../context';\nimport Icon from '../icon';\nimport type {\n\tDropdownMenuContext as DropdownMenuContextType,\n\tDropdownMenuProps,\n\tDropdownMenuGroupProps,\n\tDropdownMenuItemProps,\n\tDropdownMenuCheckboxItemProps,\n\tDropdownMenuRadioItemProps,\n\tDropdownMenuSeparatorProps,\n} from './types';\nimport * as Styled from './styles';\n\nexport const DropdownMenuContext = createContext<\n\tDropdownMenuContextType | undefined\n>( undefined );\n\nexport const DropdownMenuItem = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< DropdownMenuItemProps, 'div', false >\n>( function DropdownMenuItem(\n\t{ prefix, suffix, children, hideOnClick = true, ...props },\n\tref\n) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\n\treturn (\n\t\t<Styled.DropdownMenuItem\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\taccessibleWhenDisabled\n\t\t\thideOnClick={ hideOnClick }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t>\n\t\t\t<Styled.ItemPrefixWrapper>{ prefix }</Styled.ItemPrefixWrapper>\n\n\t\t\t<Styled.DropdownMenuItemContentWrapper>\n\t\t\t\t<Styled.DropdownMenuItemChildrenWrapper>\n\t\t\t\t\t{ children }\n\t\t\t\t</Styled.DropdownMenuItemChildrenWrapper>\n\n\t\t\t\t{ suffix && (\n\t\t\t\t\t<Styled.ItemSuffixWrapper>\n\t\t\t\t\t\t{ suffix }\n\t\t\t\t\t</Styled.ItemSuffixWrapper>\n\t\t\t\t) }\n\t\t\t</Styled.DropdownMenuItemContentWrapper>\n\t\t</Styled.DropdownMenuItem>\n\t);\n} );\n\nexport const DropdownMenuCheckboxItem = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< DropdownMenuCheckboxItemProps, 'div', false >\n>( function DropdownMenuCheckboxItem(\n\t{ suffix, children, hideOnClick = false, ...props },\n\tref\n) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\n\treturn (\n\t\t<Styled.DropdownMenuCheckboxItem\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\taccessibleWhenDisabled\n\t\t\thideOnClick={ hideOnClick }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t>\n\t\t\t<Ariakit.MenuItemCheck\n\t\t\t\tstore={ dropdownMenuContext?.store }\n\t\t\t\trender={ <Styled.ItemPrefixWrapper /> }\n\t\t\t\t// Override some ariakit inline styles\n\t\t\t\tstyle={ { width: 'auto', height: 'auto' } }\n\t\t\t>\n\t\t\t\t<Icon icon={ check } size={ 24 } />\n\t\t\t</Ariakit.MenuItemCheck>\n\n\t\t\t<Styled.DropdownMenuItemContentWrapper>\n\t\t\t\t<Styled.DropdownMenuItemChildrenWrapper>\n\t\t\t\t\t{ children }\n\t\t\t\t</Styled.DropdownMenuItemChildrenWrapper>\n\n\t\t\t\t{ suffix && (\n\t\t\t\t\t<Styled.ItemSuffixWrapper>\n\t\t\t\t\t\t{ suffix }\n\t\t\t\t\t</Styled.ItemSuffixWrapper>\n\t\t\t\t) }\n\t\t\t</Styled.DropdownMenuItemContentWrapper>\n\t\t</Styled.DropdownMenuCheckboxItem>\n\t);\n} );\n\nconst radioCheck = (\n\t<SVG xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\">\n\t\t<Circle cx={ 12 } cy={ 12 } r={ 3 }></Circle>\n\t</SVG>\n);\n\nexport const DropdownMenuRadioItem = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< DropdownMenuRadioItemProps, 'div', false >\n>( function DropdownMenuRadioItem(\n\t{ suffix, children, hideOnClick = false, ...props },\n\tref\n) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\n\treturn (\n\t\t<Styled.DropdownMenuRadioItem\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\taccessibleWhenDisabled\n\t\t\thideOnClick={ hideOnClick }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t>\n\t\t\t<Ariakit.MenuItemCheck\n\t\t\t\tstore={ dropdownMenuContext?.store }\n\t\t\t\trender={ <Styled.ItemPrefixWrapper /> }\n\t\t\t\t// Override some ariakit inline styles\n\t\t\t\tstyle={ { width: 'auto', height: 'auto' } }\n\t\t\t>\n\t\t\t\t<Icon icon={ radioCheck } size={ 24 } />\n\t\t\t</Ariakit.MenuItemCheck>\n\n\t\t\t<Styled.DropdownMenuItemContentWrapper>\n\t\t\t\t<Styled.DropdownMenuItemChildrenWrapper>\n\t\t\t\t\t{ children }\n\t\t\t\t</Styled.DropdownMenuItemChildrenWrapper>\n\n\t\t\t\t{ suffix && (\n\t\t\t\t\t<Styled.ItemSuffixWrapper>\n\t\t\t\t\t\t{ suffix }\n\t\t\t\t\t</Styled.ItemSuffixWrapper>\n\t\t\t\t) }\n\t\t\t</Styled.DropdownMenuItemContentWrapper>\n\t\t</Styled.DropdownMenuRadioItem>\n\t);\n} );\n\nexport const DropdownMenuGroup = forwardRef<\n\tHTMLDivElement,\n\tWordPressComponentProps< DropdownMenuGroupProps, 'div', false >\n>( function DropdownMenuGroup( props, ref ) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\treturn (\n\t\t<Styled.DropdownMenuGroup\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t/>\n\t);\n} );\n\nconst UnconnectedDropdownMenu = (\n\tprops: WordPressComponentProps< DropdownMenuProps, 'div', false >,\n\tref: React.ForwardedRef< HTMLDivElement >\n) => {\n\tconst {\n\t\t// Store props\n\t\topen,\n\t\tdefaultOpen = false,\n\t\tonOpenChange,\n\t\tplacement,\n\n\t\t// Menu trigger props\n\t\ttrigger,\n\n\t\t// Menu props\n\t\tgutter,\n\t\tchildren,\n\t\tshift,\n\t\tmodal = true,\n\n\t\t// From internal components context\n\t\tvariant,\n\n\t\t// Rest\n\t\t...otherProps\n\t} = useContextSystem<\n\t\ttypeof props & Pick< DropdownMenuContextType, 'variant' >\n\t>( props, 'DropdownMenu' );\n\n\tconst parentContext = useContext( DropdownMenuContext );\n\n\tconst computedDirection = isRTL() ? 'rtl' : 'ltr';\n\n\t// If an explicit value for the `placement` prop is not passed,\n\t// apply a default placement of `bottom-start` for the root dropdown,\n\t// and of `right-start` for nested dropdowns.\n\tlet computedPlacement =\n\t\tprops.placement ??\n\t\t( parentContext?.store ? 'right-start' : 'bottom-start' );\n\t// Swap left/right in case of RTL direction\n\tif ( computedDirection === 'rtl' ) {\n\t\tif ( /right/.test( computedPlacement ) ) {\n\t\t\tcomputedPlacement = computedPlacement.replace(\n\t\t\t\t'right',\n\t\t\t\t'left'\n\t\t\t) as typeof computedPlacement;\n\t\t} else if ( /left/.test( computedPlacement ) ) {\n\t\t\tcomputedPlacement = computedPlacement.replace(\n\t\t\t\t'left',\n\t\t\t\t'right'\n\t\t\t) as typeof computedPlacement;\n\t\t}\n\t}\n\n\tconst dropdownMenuStore = Ariakit.useMenuStore( {\n\t\tparent: parentContext?.store,\n\t\topen,\n\t\tdefaultOpen,\n\t\tplacement: computedPlacement,\n\t\tfocusLoop: true,\n\t\tsetOpen( willBeOpen ) {\n\t\t\tonOpenChange?.( willBeOpen );\n\t\t},\n\t\trtl: computedDirection === 'rtl',\n\t} );\n\n\tconst contextValue = useMemo(\n\t\t() => ( { store: dropdownMenuStore, variant } ),\n\t\t[ dropdownMenuStore, variant ]\n\t);\n\n\t// Extract the side from the applied placement — useful for animations.\n\tconst appliedPlacementSide = dropdownMenuStore\n\t\t.useState( 'placement' )\n\t\t.split( '-' )[ 0 ];\n\n\tif (\n\t\tdropdownMenuStore.parent &&\n\t\t! ( isValidElement( trigger ) && DropdownMenuItem === trigger.type )\n\t) {\n\t\t// eslint-disable-next-line no-console\n\t\tconsole.warn(\n\t\t\t'For nested DropdownMenus, the `trigger` should always be a `DropdownMenuItem`.'\n\t\t);\n\t}\n\n\tconst hideOnEscape = useCallback(\n\t\t( event: React.KeyboardEvent< Element > ) => {\n\t\t\t// Pressing Escape can cause unexpected consequences (ie. exiting\n\t\t\t// full screen mode on MacOs, close parent modals...).\n\t\t\tevent.preventDefault();\n\t\t\t// Returning `true` causes the menu to hide.\n\t\t\treturn true;\n\t\t},\n\t\t[]\n\t);\n\n\tconst wrapperProps = useMemo(\n\t\t() => ( {\n\t\t\tdir: computedDirection,\n\t\t\tstyle: {\n\t\t\t\tdirection:\n\t\t\t\t\tcomputedDirection as React.CSSProperties[ 'direction' ],\n\t\t\t},\n\t\t} ),\n\t\t[ computedDirection ]\n\t);\n\n\treturn (\n\t\t<>\n\t\t\t{ /* Menu trigger */ }\n\t\t\t<Ariakit.MenuButton\n\t\t\t\tref={ ref }\n\t\t\t\tstore={ dropdownMenuStore }\n\t\t\t\trender={\n\t\t\t\t\tdropdownMenuStore.parent\n\t\t\t\t\t\t? cloneElement( trigger, {\n\t\t\t\t\t\t\t\t// Add submenu arrow, unless a `suffix` is explicitly specified\n\t\t\t\t\t\t\t\tsuffix: (\n\t\t\t\t\t\t\t\t\t<>\n\t\t\t\t\t\t\t\t\t\t{ trigger.props.suffix }\n\t\t\t\t\t\t\t\t\t\t<Styled.SubmenuChevronIcon\n\t\t\t\t\t\t\t\t\t\t\taria-hidden=\"true\"\n\t\t\t\t\t\t\t\t\t\t\ticon={ chevronRightSmall }\n\t\t\t\t\t\t\t\t\t\t\tsize={ 24 }\n\t\t\t\t\t\t\t\t\t\t\tpreserveAspectRatio=\"xMidYMid slice\"\n\t\t\t\t\t\t\t\t\t\t/>\n\t\t\t\t\t\t\t\t\t</>\n\t\t\t\t\t\t\t\t),\n\t\t\t\t\t\t } )\n\t\t\t\t\t\t: trigger\n\t\t\t\t}\n\t\t\t/>\n\n\t\t\t{ /* Menu popover */ }\n\t\t\t<Styled.DropdownMenu\n\t\t\t\t{ ...otherProps }\n\t\t\t\tmodal={ modal }\n\t\t\t\tstore={ dropdownMenuStore }\n\t\t\t\t// Root menu has an 8px distance from its trigger,\n\t\t\t\t// otherwise 0 (which causes the submenu to slightly overlap)\n\t\t\t\tgutter={ gutter ?? ( dropdownMenuStore.parent ? 0 : 8 ) }\n\t\t\t\t// Align nested menu by the same (but opposite) amount\n\t\t\t\t// as the menu container's padding.\n\t\t\t\tshift={ shift ?? ( dropdownMenuStore.parent ? -4 : 0 ) }\n\t\t\t\thideOnHoverOutside={ false }\n\t\t\t\tdata-side={ appliedPlacementSide }\n\t\t\t\tvariant={ variant }\n\t\t\t\twrapperProps={ wrapperProps }\n\t\t\t\thideOnEscape={ hideOnEscape }\n\t\t\t\tunmountOnHide\n\t\t\t>\n\t\t\t\t<DropdownMenuContext.Provider value={ contextValue }>\n\t\t\t\t\t{ children }\n\t\t\t\t</DropdownMenuContext.Provider>\n\t\t\t</Styled.DropdownMenu>\n\t\t</>\n\t);\n};\nexport const DropdownMenu = contextConnect(\n\tUnconnectedDropdownMenu,\n\t'DropdownMenu'\n);\n\nexport const DropdownMenuSeparator = forwardRef<\n\tHTMLHRElement,\n\tWordPressComponentProps< DropdownMenuSeparatorProps, 'hr', false >\n>( function DropdownMenuSeparator( props, ref ) {\n\tconst dropdownMenuContext = useContext( DropdownMenuContext );\n\treturn (\n\t\t<Styled.DropdownMenuSeparator\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t\tstore={ dropdownMenuContext?.store }\n\t\t\tvariant={ dropdownMenuContext?.variant }\n\t\t/>\n\t);\n} );\n\nexport const DropdownMenuItemLabel = forwardRef<\n\tHTMLSpanElement,\n\tWordPressComponentProps< { children: React.ReactNode }, 'span', true >\n>( function DropdownMenuItemLabel( props, ref ) {\n\treturn (\n\t\t<Styled.DropdownMenuItemLabel\n\t\t\tnumberOfLines={ 1 }\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t/>\n\t);\n} );\n\nexport const DropdownMenuItemHelpText = forwardRef<\n\tHTMLSpanElement,\n\tWordPressComponentProps< { children: React.ReactNode }, 'span', true >\n>( function DropdownMenuItemHelpText( props, ref ) {\n\treturn (\n\t\t<Styled.DropdownMenuItemHelpText\n\t\t\tnumberOfLines={ 2 }\n\t\t\tref={ ref }\n\t\t\t{ ...props }\n\t\t/>\n\t);\n} );\n"],"mappings":";AAAA;AACA;AACA;AACA;AACA,OAAO,KAAKA,OAAO,MAAM,gBAAgB;;AAEzC;AACA;AACA;AACA,SACCC,UAAU,EACVC,aAAa,EACbC,UAAU,EACVC,OAAO,EACPC,YAAY,EACZC,cAAc,EACdC,WAAW,QACL,oBAAoB;AAC3B,SAASC,KAAK,QAAQ,iBAAiB;AACvC,SAASC,KAAK,EAAEC,iBAAiB,QAAQ,kBAAkB;AAC3D,SAASC,GAAG,EAAEC,MAAM,QAAQ,uBAAuB;;AAEnD;AACA;AACA;AACA,SAASC,gBAAg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