@elementor/editor-app-bar 0.9.7 → 0.10.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 (60) hide show
  1. package/CHANGELOG.md +19 -0
  2. package/dist/index.d.mts +9 -218
  3. package/dist/index.d.ts +9 -218
  4. package/dist/index.js +169 -641
  5. package/dist/index.js.map +1 -1
  6. package/dist/index.mjs +142 -619
  7. package/dist/index.mjs.map +1 -1
  8. package/package.json +4 -7
  9. package/src/extensions/documents-indicator/index.ts +1 -1
  10. package/src/extensions/documents-preview/index.ts +1 -1
  11. package/src/extensions/documents-save/components/__tests__/primary-action-menu.test.tsx +1 -1
  12. package/src/extensions/documents-save/components/primary-action-menu.tsx +2 -2
  13. package/src/extensions/documents-save/hooks/use-document-save-draft-props.ts +1 -1
  14. package/src/extensions/documents-save/hooks/use-document-save-template-props.ts +1 -1
  15. package/src/extensions/documents-save/index.ts +2 -1
  16. package/src/extensions/documents-save/locations.ts +3 -0
  17. package/src/extensions/elements/index.ts +1 -1
  18. package/src/extensions/finder/index.ts +1 -1
  19. package/src/extensions/help/index.ts +1 -1
  20. package/src/extensions/history/index.ts +1 -1
  21. package/src/extensions/keyboard-shortcuts/hooks/use-action-props.ts +1 -1
  22. package/src/extensions/keyboard-shortcuts/index.ts +1 -1
  23. package/src/extensions/site-settings/hooks/use-action-props.ts +1 -1
  24. package/src/extensions/site-settings/index.ts +1 -1
  25. package/src/extensions/structure/hooks/use-action-props.ts +1 -1
  26. package/src/extensions/structure/index.ts +1 -1
  27. package/src/extensions/theme-builder/hooks/use-action-props.ts +1 -1
  28. package/src/extensions/theme-builder/index.ts +1 -1
  29. package/src/extensions/user-preferences/hooks/use-action-props.ts +1 -1
  30. package/src/extensions/user-preferences/index.ts +1 -1
  31. package/src/extensions/wordpress/index.ts +1 -1
  32. package/src/index.ts +12 -9
  33. package/src/init.ts +1 -1
  34. package/src/components/__tests__/top-bar.test.tsx +0 -15
  35. package/src/components/actions/action.tsx +0 -33
  36. package/src/components/actions/link.tsx +0 -33
  37. package/src/components/actions/toggle-action.tsx +0 -35
  38. package/src/components/app-bar.tsx +0 -37
  39. package/src/components/locations/__tests__/locations-components.test.tsx +0 -37
  40. package/src/components/locations/__tests__/menus.test.tsx +0 -120
  41. package/src/components/locations/integrations-menu-location.tsx +0 -59
  42. package/src/components/locations/main-menu-location.tsx +0 -38
  43. package/src/components/locations/page-indication-location.tsx +0 -8
  44. package/src/components/locations/primary-action-location.tsx +0 -8
  45. package/src/components/locations/responsive-location.tsx +0 -8
  46. package/src/components/locations/tools-menu-location.tsx +0 -26
  47. package/src/components/locations/utilities-menu-location.tsx +0 -35
  48. package/src/components/ui/popover-menu-item.tsx +0 -44
  49. package/src/components/ui/popover-menu.tsx +0 -24
  50. package/src/components/ui/popover-sub-menu.tsx +0 -29
  51. package/src/components/ui/toolbar-logo.tsx +0 -84
  52. package/src/components/ui/toolbar-menu-item.tsx +0 -45
  53. package/src/components/ui/toolbar-menu-more.tsx +0 -29
  54. package/src/components/ui/toolbar-menu-toggle-item.tsx +0 -34
  55. package/src/components/ui/toolbar-menu.tsx +0 -15
  56. package/src/contexts/menu-context.tsx +0 -20
  57. package/src/locations/__tests__/menus.test.tsx +0 -212
  58. package/src/locations/index.ts +0 -29
  59. package/src/locations/menus.tsx +0 -129
  60. package/src/types.ts +0 -3
package/dist/index.mjs CHANGED
@@ -1,533 +1,20 @@
1
- // src/locations/menus.tsx
2
- import * as React8 from "react";
3
- import { useMemo } from "react";
4
- import { createLocation } from "@elementor/locations";
5
-
6
- // src/components/actions/action.tsx
7
- import * as React4 from "react";
8
-
9
- // src/contexts/menu-context.tsx
10
- import * as React from "react";
11
- import { createContext, useContext } from "react";
12
- var MenuContext = createContext({ type: "toolbar" });
13
- function MenuContextProvider({ type, children }) {
14
- return /* @__PURE__ */ React.createElement(MenuContext.Provider, { value: { type } }, children);
15
- }
16
- function useMenuContext() {
17
- return useContext(MenuContext);
18
- }
19
-
20
- // src/components/ui/toolbar-menu-item.tsx
21
- import * as React2 from "react";
22
- import { Box, IconButton, Tooltip as BaseTooltip } from "@elementor/ui";
23
- function ToolbarMenuItem({ title, ...props }) {
24
- return /* @__PURE__ */ React2.createElement(Tooltip, { title }, /* @__PURE__ */ React2.createElement(Box, { component: "span", "aria-label": void 0 }, /* @__PURE__ */ React2.createElement(
25
- IconButton,
26
- {
27
- ...props,
28
- "aria-label": title,
29
- size: "medium",
30
- sx: {
31
- "& svg": {
32
- fontSize: "1.25rem",
33
- height: "1em",
34
- width: "1em"
35
- },
36
- "&:hover": {
37
- color: "text.primary"
38
- }
39
- }
40
- }
41
- )));
42
- }
43
- function Tooltip(props) {
44
- return /* @__PURE__ */ React2.createElement(
45
- BaseTooltip,
46
- {
47
- PopperProps: {
48
- sx: {
49
- "&.MuiTooltip-popper .MuiTooltip-tooltip.MuiTooltip-tooltipPlacementBottom": {
50
- mt: 2
51
- }
52
- }
53
- },
54
- ...props
55
- }
56
- );
57
- }
58
-
59
- // src/components/ui/popover-menu-item.tsx
60
- import * as React3 from "react";
1
+ // src/index.ts
61
2
  import {
62
- MenuItem,
63
- ListItemText,
64
- ListItemIcon,
65
- withDirection
66
- } from "@elementor/ui";
67
- import { ArrowUpRightIcon } from "@elementor/icons";
68
- var DirectionalArrowIcon = withDirection(ArrowUpRightIcon);
69
- function PopoverMenuItem({ text, icon, onClick, href, target, disabled, ...props }) {
70
- const isExternalLink = href && target === "_blank";
71
- return /* @__PURE__ */ React3.createElement(
72
- MenuItem,
73
- {
74
- ...props,
75
- disabled,
76
- onClick,
77
- component: href ? "a" : "div",
78
- href,
79
- target,
80
- sx: {
81
- "&:hover": {
82
- color: "text.primary"
83
- // Overriding global CSS from the editor.
84
- }
85
- }
86
- },
87
- /* @__PURE__ */ React3.createElement(ListItemIcon, null, icon),
88
- /* @__PURE__ */ React3.createElement(ListItemText, { primary: text }),
89
- isExternalLink && /* @__PURE__ */ React3.createElement(DirectionalArrowIcon, null)
90
- );
91
- }
92
-
93
- // src/components/actions/action.tsx
94
- function Action({ icon: Icon, title, visible = true, ...props }) {
95
- const { type } = useMenuContext();
96
- if (!visible) {
97
- return null;
98
- }
99
- return type === "toolbar" ? /* @__PURE__ */ React4.createElement(ToolbarMenuItem, { title, ...props }, /* @__PURE__ */ React4.createElement(Icon, null)) : /* @__PURE__ */ React4.createElement(
100
- PopoverMenuItem,
101
- {
102
- ...props,
103
- text: title,
104
- icon: /* @__PURE__ */ React4.createElement(Icon, null)
105
- }
106
- );
107
- }
108
-
109
- // src/components/actions/toggle-action.tsx
110
- import * as React6 from "react";
111
-
112
- // src/components/ui/toolbar-menu-toggle-item.tsx
113
- import * as React5 from "react";
114
- import { Box as Box2, ToggleButton, Tooltip as Tooltip2 } from "@elementor/ui";
115
- function ToolbarMenuToggleItem({ title, onClick, ...props }) {
116
- return /* @__PURE__ */ React5.createElement(Tooltip2, { title }, /* @__PURE__ */ React5.createElement(Box2, { component: "span", "aria-label": void 0 }, /* @__PURE__ */ React5.createElement(
117
- ToggleButton,
118
- {
119
- ...props,
120
- onChange: onClick,
121
- "aria-label": title,
122
- size: "small",
123
- sx: {
124
- border: 0,
125
- // Temp fix until the style of the ToggleButton component will be decided.
126
- "&.Mui-disabled": {
127
- border: 0
128
- // Temp fix until the style of the ToggleButton component will be decided.
129
- },
130
- "& svg": {
131
- fontSize: "1.25rem",
132
- height: "1em",
133
- width: "1em"
134
- }
135
- }
136
- }
137
- )));
138
- }
139
-
140
- // src/components/actions/toggle-action.tsx
141
- function ToggleAction({ icon: Icon, title, value, visible = true, ...props }) {
142
- const { type } = useMenuContext();
143
- if (!visible) {
144
- return null;
145
- }
146
- return type === "toolbar" ? /* @__PURE__ */ React6.createElement(ToolbarMenuToggleItem, { value: value || title, title, ...props }, /* @__PURE__ */ React6.createElement(Icon, null)) : /* @__PURE__ */ React6.createElement(
147
- PopoverMenuItem,
148
- {
149
- ...props,
150
- text: title,
151
- icon: /* @__PURE__ */ React6.createElement(Icon, null)
152
- }
153
- );
154
- }
155
-
156
- // src/components/actions/link.tsx
157
- import * as React7 from "react";
158
- function Link({ icon: Icon, title, visible = true, ...props }) {
159
- const { type } = useMenuContext();
160
- if (!visible) {
161
- return null;
162
- }
163
- return type === "toolbar" ? /* @__PURE__ */ React7.createElement(ToolbarMenuItem, { title, ...props }, /* @__PURE__ */ React7.createElement(Icon, null)) : /* @__PURE__ */ React7.createElement(
164
- PopoverMenuItem,
165
- {
166
- ...props,
167
- text: title,
168
- icon: /* @__PURE__ */ React7.createElement(Icon, null)
169
- }
170
- );
171
- }
172
-
173
- // src/locations/menus.tsx
174
- function createMenu(groups = []) {
175
- const menuGroups = [
176
- ...groups,
177
- "default"
178
- ];
179
- const locations = menuGroups.reduce(
180
- (carry, group) => ({
181
- ...carry,
182
- [group]: createLocation()
183
- }),
184
- {}
185
- );
186
- const [
187
- registerAction,
188
- registerToggleAction,
189
- registerLink
190
- ] = [Action, ToggleAction, Link].map(
191
- (Component) => createRegisterMenuItem({
192
- locations,
193
- menuGroups,
194
- component: Component
195
- })
196
- );
197
- const useMenuItems6 = createUseMenuItems(locations);
198
- return {
199
- registerAction,
200
- registerToggleAction,
201
- registerLink,
202
- useMenuItems: useMenuItems6
203
- };
204
- }
205
- function createRegisterMenuItem({ locations, menuGroups, component }) {
206
- return ({ group = "default", id, overwrite, priority, ...args }) => {
207
- if (!menuGroups.includes(group)) {
208
- return;
209
- }
210
- const useProps = "props" in args ? () => args.props : args.useProps;
211
- const Component = component;
212
- const InjectedComponent = (props) => {
213
- const componentProps = useProps();
214
- return /* @__PURE__ */ React8.createElement(Component, { ...props, ...componentProps });
215
- };
216
- locations[group].inject({
217
- id,
218
- component: InjectedComponent,
219
- options: {
220
- priority,
221
- overwrite
222
- }
223
- });
224
- };
225
- }
226
- function createUseMenuItems(locations) {
227
- return () => {
228
- return useMemo(() => {
229
- return Object.entries(locations).reduce(
230
- (carry, [groupName, location]) => {
231
- const items = location.getInjections().map((injection) => ({
232
- id: injection.id,
233
- MenuItem: injection.component
234
- }));
235
- return {
236
- ...carry,
237
- [groupName]: items
238
- };
239
- },
240
- {}
241
- );
242
- }, []);
243
- };
244
- }
245
-
246
- // src/locations/index.ts
247
- import { createLocation as createLocation2 } from "@elementor/locations";
248
- var {
249
- inject: injectIntoPageIndication,
250
- Slot: PageIndicationSlot
251
- } = createLocation2();
252
- var {
253
- inject: injectIntoResponsive,
254
- Slot: ResponsiveSlot
255
- } = createLocation2();
256
- var {
257
- inject: injectIntoPrimaryAction,
258
- Slot: PrimaryActionSlot
259
- } = createLocation2();
260
- var mainMenu = createMenu(["exits"]);
261
- var toolsMenu = createMenu();
262
- var utilitiesMenu = createMenu();
263
- var integrationsMenu = createMenu();
3
+ __privateMainMenu,
4
+ __privateToolsMenu,
5
+ __privateUtilitiesMenu,
6
+ __privateIntegrationsMenu,
7
+ __privateInjectIntoPageIndication,
8
+ __privateInjectIntoResponsive,
9
+ __privateInjectIntoPrimaryAction
10
+ } from "@elementor/editor-app-bar-ui";
11
+
12
+ // src/extensions/documents-save/locations.ts
13
+ import { __privateCreateMenu as createMenu } from "@elementor/editor-app-bar-ui";
264
14
  var documentOptionsMenu = createMenu(["save"]);
265
15
 
266
- // src/components/app-bar.tsx
267
- import * as React21 from "react";
268
- import { AppBar as BaseAppBar, Box as Box3, Divider as Divider4, Grid, ThemeProvider } from "@elementor/ui";
269
-
270
- // src/components/locations/main-menu-location.tsx
271
- import * as React13 from "react";
272
- import { usePopupState as usePopupState2, bindMenu as bindMenu2, bindTrigger, Stack, Divider as Divider2 } from "@elementor/ui";
273
-
274
- // src/components/ui/popover-menu.tsx
275
- import * as React9 from "react";
276
- import { Menu } from "@elementor/ui";
277
- function PopoverMenu({ children, ...props }) {
278
- return /* @__PURE__ */ React9.createElement(MenuContextProvider, { type: "popover" }, /* @__PURE__ */ React9.createElement(
279
- Menu,
280
- {
281
- PaperProps: {
282
- sx: { mt: 1.5 }
283
- },
284
- ...props,
285
- MenuListProps: {
286
- component: "div",
287
- dense: true
288
- }
289
- },
290
- children
291
- ));
292
- }
293
-
294
- // src/components/ui/toolbar-logo.tsx
295
- import * as React10 from "react";
296
- import { useState } from "react";
297
- import { __ } from "@wordpress/i18n";
298
- import { ToggleButton as ToggleButton2, SvgIcon, styled } from "@elementor/ui";
299
- var ElementorLogo = (props) => {
300
- return /* @__PURE__ */ React10.createElement(SvgIcon, { viewBox: "0 0 32 32", ...props }, /* @__PURE__ */ React10.createElement("g", null, /* @__PURE__ */ React10.createElement("circle", { cx: "16", cy: "16", r: "16" }), /* @__PURE__ */ React10.createElement("path", { d: "M11.7 9H9V22.3H11.7V9Z" }), /* @__PURE__ */ React10.createElement("path", { d: "M22.4 9H9V11.7H22.4V9Z" }), /* @__PURE__ */ React10.createElement("path", { d: "M22.4 14.4004H9V17.1004H22.4V14.4004Z" }), /* @__PURE__ */ React10.createElement("path", { d: "M22.4 19.6992H9V22.3992H22.4V19.6992Z" })));
301
- };
302
- var StyledToggleButton = styled(ToggleButton2)(({ theme }) => ({
303
- padding: 0,
304
- border: 0,
305
- color: theme.palette.text.primary,
306
- "&.MuiToggleButton-root:hover": {
307
- backgroundColor: "initial"
308
- },
309
- "&.MuiToggleButton-root.Mui-selected": {
310
- backgroundColor: "initial"
311
- }
312
- }));
313
- var StyledElementorLogo = styled(ElementorLogo, {
314
- shouldForwardProp: (prop) => prop !== "showMenuIcon"
315
- })(({ theme, showMenuIcon }) => ({
316
- "& path": {
317
- fill: theme.palette.background.default,
318
- transition: "all 0.2s linear",
319
- transformOrigin: "bottom left",
320
- "&:first-of-type": {
321
- transitionDelay: !showMenuIcon && "0.2s",
322
- transform: showMenuIcon && "translateY(-9px) scaleY(0)"
323
- },
324
- "&:not(:first-of-type)": {
325
- // Emotion automatically change 4 to -4 in RTL moode.
326
- transform: !showMenuIcon && `translateX(${theme.direction === "rtl" ? "4" : "9"}px) scaleX(0.6)`
327
- },
328
- "&:nth-of-type(2)": {
329
- transitionDelay: showMenuIcon ? "0" : "0.2s"
330
- },
331
- "&:nth-of-type(3)": {
332
- transitionDelay: "0.1s"
333
- },
334
- "&:nth-of-type(4)": {
335
- transitionDelay: showMenuIcon ? "0.2s" : "0"
336
- }
337
- }
338
- }));
339
- function ToolbarLogo(props) {
340
- const [isHoverState, setIsHoverState] = useState(false);
341
- const showMenuIcon = props.selected || isHoverState;
342
- return /* @__PURE__ */ React10.createElement(
343
- StyledToggleButton,
344
- {
345
- ...props,
346
- value: "selected",
347
- size: "large",
348
- onMouseEnter: () => setIsHoverState(true),
349
- onMouseLeave: () => setIsHoverState(false)
350
- },
351
- /* @__PURE__ */ React10.createElement(
352
- StyledElementorLogo,
353
- {
354
- fontSize: "large",
355
- showMenuIcon,
356
- titleAccess: __("Elementor Logo", "elementor")
357
- }
358
- )
359
- );
360
- }
361
-
362
- // src/components/locations/integrations-menu-location.tsx
363
- import * as React12 from "react";
364
- import {
365
- bindMenu,
366
- Divider,
367
- ListItemIcon as ListItemIcon2,
368
- ListItemText as ListItemText2,
369
- MenuItem as MenuItem2,
370
- usePopupState,
371
- bindHover,
372
- bindFocus,
373
- withDirection as withDirection2
374
- } from "@elementor/ui";
375
- import { __ as __2 } from "@wordpress/i18n";
376
- import { ChevronRightIcon, PlugIcon } from "@elementor/icons";
377
-
378
- // src/components/ui/popover-sub-menu.tsx
379
- import * as React11 from "react";
380
- import { useTheme } from "@elementor/ui";
381
- function PopoverSubMenu({ children, ...props }) {
382
- const theme = useTheme();
383
- const isRTL = theme.direction === "rtl";
384
- return /* @__PURE__ */ React11.createElement(
385
- PopoverMenu,
386
- {
387
- sx: { pointerEvents: "none" },
388
- PaperProps: {
389
- sx: {
390
- // This is a workaround to support RTL in PopoverMenu, since it doesn't support it yet.
391
- ...isRTL ? { marginInlineEnd: -1 } : { marginInlineStart: 1 },
392
- pointerEvents: "auto"
393
- }
394
- },
395
- anchorOrigin: { vertical: "center", horizontal: isRTL ? "left" : "right" },
396
- transformOrigin: { vertical: "center", horizontal: isRTL ? "right" : "left" },
397
- ...props
398
- },
399
- children
400
- );
401
- }
402
-
403
- // src/components/locations/integrations-menu-location.tsx
404
- var { useMenuItems } = integrationsMenu;
405
- var DirectionalChevronIcon = withDirection2(ChevronRightIcon);
406
- function IntegrationsMenuLocation({ parentPopupState }) {
407
- const menuItems = useMenuItems();
408
- const popupState = usePopupState({
409
- parentPopupState,
410
- variant: "popover",
411
- popupId: "elementor-v2-app-bar-integrations"
412
- });
413
- if (menuItems.default.length === 0) {
414
- return null;
415
- }
416
- return /* @__PURE__ */ React12.createElement(React12.Fragment, null, /* @__PURE__ */ React12.createElement(Divider, null), /* @__PURE__ */ React12.createElement(
417
- MenuItem2,
418
- {
419
- ...bindHover(popupState),
420
- ...bindFocus(popupState)
421
- },
422
- /* @__PURE__ */ React12.createElement(ListItemIcon2, null, /* @__PURE__ */ React12.createElement(PlugIcon, null)),
423
- /* @__PURE__ */ React12.createElement(ListItemText2, { primary: __2("Integrations", "elementor") }),
424
- /* @__PURE__ */ React12.createElement(DirectionalChevronIcon, null),
425
- /* @__PURE__ */ React12.createElement(PopoverSubMenu, { ...bindMenu(popupState), onClick: popupState.close }, menuItems.default.map(
426
- ({ MenuItem: IntegrationsMenuItem, id }) => /* @__PURE__ */ React12.createElement(IntegrationsMenuItem, { key: id })
427
- ))
428
- ));
429
- }
430
-
431
- // src/components/locations/main-menu-location.tsx
432
- var { useMenuItems: useMenuItems2 } = mainMenu;
433
- function MainMenuLocation() {
434
- const menuItems = useMenuItems2();
435
- const popupState = usePopupState2({
436
- variant: "popover",
437
- popupId: "elementor-v2-app-bar-main-menu"
438
- });
439
- return /* @__PURE__ */ React13.createElement(Stack, { sx: { paddingInlineStart: 3 }, direction: "row", alignItems: "center" }, /* @__PURE__ */ React13.createElement(
440
- ToolbarLogo,
441
- {
442
- ...bindTrigger(popupState),
443
- selected: popupState.isOpen
444
- }
445
- ), /* @__PURE__ */ React13.createElement(
446
- PopoverMenu,
447
- {
448
- onClick: popupState.close,
449
- ...bindMenu2(popupState),
450
- marginThreshold: 8
451
- },
452
- menuItems.default.map(({ MenuItem: MenuItem3, id }) => /* @__PURE__ */ React13.createElement(MenuItem3, { key: id })),
453
- /* @__PURE__ */ React13.createElement(IntegrationsMenuLocation, { key: "integrations-location", parentPopupState: popupState }),
454
- menuItems.exits.length > 0 && /* @__PURE__ */ React13.createElement(Divider2, null),
455
- menuItems.exits.map(({ MenuItem: MenuItem3, id }) => /* @__PURE__ */ React13.createElement(MenuItem3, { key: id }))
456
- ));
457
- }
458
-
459
- // src/components/locations/tools-menu-location.tsx
460
- import * as React16 from "react";
461
-
462
- // src/components/ui/toolbar-menu.tsx
463
- import * as React14 from "react";
464
- import { Stack as Stack2 } from "@elementor/ui";
465
- function ToolbarMenu({ children, ...props }) {
466
- return /* @__PURE__ */ React14.createElement(MenuContextProvider, { type: "toolbar" }, /* @__PURE__ */ React14.createElement(Stack2, { sx: { px: 1.5 }, spacing: 1.5, direction: "row", alignItems: "center", ...props }, children));
467
- }
468
-
469
- // src/components/ui/toolbar-menu-more.tsx
470
- import * as React15 from "react";
471
- import { bindMenu as bindMenu3, bindTrigger as bindTrigger2, usePopupState as usePopupState3 } from "@elementor/ui";
472
- import { __ as __3 } from "@wordpress/i18n";
473
- import { DotsVerticalIcon } from "@elementor/icons";
474
- function ToolbarMenuMore({ children, id }) {
475
- const popupState = usePopupState3({
476
- variant: "popover",
477
- popupId: id
478
- });
479
- return /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(ToolbarMenuItem, { ...bindTrigger2(popupState), title: __3("More", "elementor") }, /* @__PURE__ */ React15.createElement(DotsVerticalIcon, null)), /* @__PURE__ */ React15.createElement(PopoverMenu, { onClick: popupState.close, ...bindMenu3(popupState) }, children));
480
- }
481
-
482
- // src/components/locations/tools-menu-location.tsx
483
- var MAX_TOOLBAR_ACTIONS = 5;
484
- var { useMenuItems: useMenuItems3 } = toolsMenu;
485
- function ToolsMenuLocation() {
486
- const menuItems = useMenuItems3();
487
- const toolbarMenuItems = menuItems.default.slice(0, MAX_TOOLBAR_ACTIONS);
488
- const popoverMenuItems = menuItems.default.slice(MAX_TOOLBAR_ACTIONS);
489
- return /* @__PURE__ */ React16.createElement(ToolbarMenu, null, toolbarMenuItems.map(({ MenuItem: MenuItem3, id }) => /* @__PURE__ */ React16.createElement(MenuItem3, { key: id })), popoverMenuItems.length > 0 && /* @__PURE__ */ React16.createElement(ToolbarMenuMore, { id: "elementor-editor-app-bar-tools-more" }, popoverMenuItems.map(({ MenuItem: MenuItem3, id }) => /* @__PURE__ */ React16.createElement(MenuItem3, { key: id }))));
490
- }
491
-
492
- // src/components/locations/utilities-menu-location.tsx
493
- import * as React17 from "react";
494
- import { Fragment as Fragment3 } from "react";
495
- import { Divider as Divider3 } from "@elementor/ui";
496
- var MAX_TOOLBAR_ACTIONS2 = 3;
497
- var { useMenuItems: useMenuItems4 } = utilitiesMenu;
498
- function UtilitiesMenuLocation() {
499
- const menuItems = useMenuItems4();
500
- const toolbarMenuItems = menuItems.default.slice(0, MAX_TOOLBAR_ACTIONS2);
501
- const popoverMenuItems = menuItems.default.slice(MAX_TOOLBAR_ACTIONS2);
502
- return /* @__PURE__ */ React17.createElement(ToolbarMenu, null, toolbarMenuItems.map(
503
- ({ MenuItem: MenuItem3, id }, index) => /* @__PURE__ */ React17.createElement(Fragment3, { key: id }, index === 0 && /* @__PURE__ */ React17.createElement(Divider3, { orientation: "vertical" }), /* @__PURE__ */ React17.createElement(MenuItem3, null))
504
- ), popoverMenuItems.length > 0 && /* @__PURE__ */ React17.createElement(ToolbarMenuMore, { id: "elementor-editor-app-bar-utilities-more" }, popoverMenuItems.map(({ MenuItem: MenuItem3, id }) => /* @__PURE__ */ React17.createElement(MenuItem3, { key: id }))));
505
- }
506
-
507
- // src/components/locations/primary-action-location.tsx
508
- import * as React18 from "react";
509
- function PrimaryActionLocation() {
510
- return /* @__PURE__ */ React18.createElement(PrimaryActionSlot, null);
511
- }
512
-
513
- // src/components/locations/page-indication-location.tsx
514
- import * as React19 from "react";
515
- function PageIndicationLocation() {
516
- return /* @__PURE__ */ React19.createElement(PageIndicationSlot, null);
517
- }
518
-
519
- // src/components/locations/responsive-location.tsx
520
- import * as React20 from "react";
521
- function ResponsiveLocation() {
522
- return /* @__PURE__ */ React20.createElement(ResponsiveSlot, null);
523
- }
524
-
525
- // src/components/app-bar.tsx
526
- function AppBar() {
527
- return /* @__PURE__ */ React21.createElement(ThemeProvider, { colorScheme: "dark" }, /* @__PURE__ */ React21.createElement(BaseAppBar, { position: "sticky" }, /* @__PURE__ */ React21.createElement(Box3, { display: "grid", gridTemplateColumns: "repeat(3, 1fr)" }, /* @__PURE__ */ React21.createElement(Grid, { container: true }, /* @__PURE__ */ React21.createElement(MainMenuLocation, null), /* @__PURE__ */ React21.createElement(ToolsMenuLocation, null)), /* @__PURE__ */ React21.createElement(Grid, { container: true, justifyContent: "center" }, /* @__PURE__ */ React21.createElement(ToolbarMenu, { spacing: 1.5 }, /* @__PURE__ */ React21.createElement(Divider4, { orientation: "vertical" }), /* @__PURE__ */ React21.createElement(PageIndicationLocation, null), /* @__PURE__ */ React21.createElement(Divider4, { orientation: "vertical" }), /* @__PURE__ */ React21.createElement(ResponsiveLocation, null), /* @__PURE__ */ React21.createElement(Divider4, { orientation: "vertical" }))), /* @__PURE__ */ React21.createElement(Grid, { container: true, justifyContent: "flex-end" }, /* @__PURE__ */ React21.createElement(UtilitiesMenuLocation, null), /* @__PURE__ */ React21.createElement(PrimaryActionLocation, null)))));
528
- }
529
-
530
16
  // src/init.ts
17
+ import { __privateAppBar as AppBar } from "@elementor/editor-app-bar-ui";
531
18
  import { injectIntoTop as injectIntoTop2 } from "@elementor/editor";
532
19
 
533
20
  // src/sync/redirect-old-menus.ts
@@ -538,10 +25,13 @@ function redirectOldMenus() {
538
25
  });
539
26
  }
540
27
 
28
+ // src/extensions/documents-indicator/index.ts
29
+ import { __privateInjectIntoPageIndication as injectIntoPageIndication } from "@elementor/editor-app-bar-ui";
30
+
541
31
  // src/extensions/documents-indicator/components/settings-button.tsx
542
- import * as React22 from "react";
543
- import { Box as Box4, ToggleButton as ToggleButton3, Tooltip as BaseTooltip2 } from "@elementor/ui";
544
- import { __ as __4 } from "@wordpress/i18n";
32
+ import * as React from "react";
33
+ import { Box, ToggleButton, Tooltip as BaseTooltip } from "@elementor/ui";
34
+ import { __ } from "@wordpress/i18n";
545
35
  import { __privateOpenRoute as openRoute2, __privateUseRouteStatus as useRouteStatus } from "@elementor/editor-v1-adapters";
546
36
  import { SettingsIcon } from "@elementor/icons";
547
37
  import { __useActiveDocument as useActiveDocument, __useHostDocument as useHostDocument } from "@elementor/editor-documents";
@@ -553,9 +43,9 @@ function SettingsButton() {
553
43
  if (!document2) {
554
44
  return null;
555
45
  }
556
- const title = __4("%s Settings", "elementor").replace("%s", document2.type.label);
557
- return /* @__PURE__ */ React22.createElement(Tooltip3, { title }, /* @__PURE__ */ React22.createElement(Box4, { component: "span", "aria-label": void 0 }, /* @__PURE__ */ React22.createElement(
558
- ToggleButton3,
46
+ const title = __("%s Settings", "elementor").replace("%s", document2.type.label);
47
+ return /* @__PURE__ */ React.createElement(Tooltip, { title }, /* @__PURE__ */ React.createElement(Box, { component: "span", "aria-label": void 0 }, /* @__PURE__ */ React.createElement(
48
+ ToggleButton,
559
49
  {
560
50
  value: "document-settings",
561
51
  selected: isActive,
@@ -572,12 +62,12 @@ function SettingsButton() {
572
62
  }
573
63
  }
574
64
  },
575
- /* @__PURE__ */ React22.createElement(SettingsIcon, { fontSize: "small" })
65
+ /* @__PURE__ */ React.createElement(SettingsIcon, { fontSize: "small" })
576
66
  )));
577
67
  }
578
- function Tooltip3(props) {
579
- return /* @__PURE__ */ React22.createElement(
580
- BaseTooltip2,
68
+ function Tooltip(props) {
69
+ return /* @__PURE__ */ React.createElement(
70
+ BaseTooltip,
581
71
  {
582
72
  PopperProps: {
583
73
  sx: {
@@ -603,8 +93,11 @@ function init() {
603
93
  });
604
94
  }
605
95
 
96
+ // src/extensions/documents-preview/index.ts
97
+ import { __privateUtilitiesMenu as utilitiesMenu } from "@elementor/editor-app-bar-ui";
98
+
606
99
  // src/extensions/documents-preview/hooks/use-action-props.ts
607
- import { __ as __5 } from "@wordpress/i18n";
100
+ import { __ as __2 } from "@wordpress/i18n";
608
101
  import { EyeIcon } from "@elementor/icons";
609
102
  import { __privateRunCommand as runCommand } from "@elementor/editor-v1-adapters";
610
103
  import { __useActiveDocument as useActiveDocument2 } from "@elementor/editor-documents";
@@ -612,7 +105,7 @@ function useActionProps() {
612
105
  const document2 = useActiveDocument2();
613
106
  return {
614
107
  icon: EyeIcon,
615
- title: __5("Preview Changes", "elementor"),
108
+ title: __2("Preview Changes", "elementor"),
616
109
  onClick: () => document2 && runCommand("editor/documents/preview", {
617
110
  id: document2.id,
618
111
  force: true
@@ -630,8 +123,11 @@ function init2() {
630
123
  });
631
124
  }
632
125
 
126
+ // src/extensions/documents-save/index.ts
127
+ import { __privateInjectIntoPrimaryAction as injectIntoPrimaryAction } from "@elementor/editor-app-bar-ui";
128
+
633
129
  // src/extensions/documents-save/hooks/use-document-save-draft-props.ts
634
- import { __ as __6 } from "@wordpress/i18n";
130
+ import { __ as __3 } from "@wordpress/i18n";
635
131
  import { FileReportIcon } from "@elementor/icons";
636
132
  import { __useActiveDocument as useActiveDocument3, __useActiveDocumentActions as useActiveDocumentActions } from "@elementor/editor-documents";
637
133
  function useDocumentSaveDraftProps() {
@@ -639,34 +135,35 @@ function useDocumentSaveDraftProps() {
639
135
  const { saveDraft } = useActiveDocumentActions();
640
136
  return {
641
137
  icon: FileReportIcon,
642
- title: __6("Save Draft", "elementor"),
138
+ title: __3("Save Draft", "elementor"),
643
139
  onClick: saveDraft,
644
140
  disabled: !document2 || document2.isSaving || document2.isSavingDraft || !document2.isDirty
645
141
  };
646
142
  }
647
143
 
648
144
  // src/extensions/documents-save/hooks/use-document-save-template-props.ts
649
- import { __ as __7 } from "@wordpress/i18n";
145
+ import { __ as __4 } from "@wordpress/i18n";
650
146
  import { FolderIcon } from "@elementor/icons";
651
147
  import { __useActiveDocumentActions as useActiveDocumentActions2 } from "@elementor/editor-documents";
652
148
  function useDocumentSaveTemplateProps() {
653
149
  const { saveTemplate } = useActiveDocumentActions2();
654
150
  return {
655
151
  icon: FolderIcon,
656
- title: __7("Save as Template", "elementor"),
152
+ title: __4("Save as Template", "elementor"),
657
153
  onClick: saveTemplate
658
154
  };
659
155
  }
660
156
 
661
157
  // src/extensions/documents-save/components/primary-action.tsx
662
- import * as React24 from "react";
663
- import { __ as __8 } from "@wordpress/i18n";
158
+ import * as React3 from "react";
159
+ import { __ as __5 } from "@wordpress/i18n";
664
160
 
665
161
  // src/extensions/documents-save/components/primary-action-menu.tsx
666
- import * as React23 from "react";
667
- import { Divider as Divider5, styled as styled2 } from "@elementor/ui";
668
- var { useMenuItems: useMenuItems5 } = documentOptionsMenu;
669
- var StyledPopoverMenu = styled2(PopoverMenu)`
162
+ import * as React2 from "react";
163
+ import { Divider, styled } from "@elementor/ui";
164
+ import { __privatePopoverMenu as PopoverMenu } from "@elementor/editor-app-bar-ui";
165
+ var { useMenuItems } = documentOptionsMenu;
166
+ var StyledPopoverMenu = styled(PopoverMenu)`
670
167
  & > .MuiPopover-paper > .MuiList-root > .MuiDivider-root {
671
168
  &:only-child, /* A divider is being rendered lonely */
672
169
  &:last-child, /* The last group renders empty but renders a divider */
@@ -676,8 +173,8 @@ var StyledPopoverMenu = styled2(PopoverMenu)`
676
173
  }
677
174
  `;
678
175
  function PrimaryActionMenu(props) {
679
- const { save: saveActions, default: defaultActions } = useMenuItems5();
680
- return /* @__PURE__ */ React23.createElement(
176
+ const { save: saveActions, default: defaultActions } = useMenuItems();
177
+ return /* @__PURE__ */ React2.createElement(
681
178
  StyledPopoverMenu,
682
179
  {
683
180
  ...props,
@@ -694,25 +191,25 @@ function PrimaryActionMenu(props) {
694
191
  sx: { mt: 0.5 }
695
192
  }
696
193
  },
697
- saveActions.map(({ MenuItem: MenuItem3, id }, index) => [
698
- index > 0 && /* @__PURE__ */ React23.createElement(Divider5, { key: `${id}-divider` }),
699
- /* @__PURE__ */ React23.createElement(MenuItem3, { key: id })
194
+ saveActions.map(({ MenuItem, id }, index) => [
195
+ index > 0 && /* @__PURE__ */ React2.createElement(Divider, { key: `${id}-divider` }),
196
+ /* @__PURE__ */ React2.createElement(MenuItem, { key: id })
700
197
  ]),
701
- defaultActions.length > 0 && /* @__PURE__ */ React23.createElement(Divider5, null),
702
- defaultActions.map(({ MenuItem: MenuItem3, id }) => /* @__PURE__ */ React23.createElement(MenuItem3, { key: id }))
198
+ defaultActions.length > 0 && /* @__PURE__ */ React2.createElement(Divider, null),
199
+ defaultActions.map(({ MenuItem, id }) => /* @__PURE__ */ React2.createElement(MenuItem, { key: id }))
703
200
  );
704
201
  }
705
202
 
706
203
  // src/extensions/documents-save/components/primary-action.tsx
707
204
  import {
708
- bindMenu as bindMenu4,
709
- bindTrigger as bindTrigger3,
710
- Box as Box5,
205
+ bindMenu,
206
+ bindTrigger,
207
+ Box as Box2,
711
208
  Button,
712
209
  ButtonGroup,
713
210
  CircularProgress,
714
- Tooltip as Tooltip4,
715
- usePopupState as usePopupState4
211
+ Tooltip as Tooltip2,
212
+ usePopupState
716
213
  } from "@elementor/ui";
717
214
  import { __useActiveDocument as useActiveDocument4, __useActiveDocumentActions as useActiveDocumentActions3 } from "@elementor/editor-documents";
718
215
  import { ChevronDownIcon } from "@elementor/icons";
@@ -721,7 +218,7 @@ function PrimaryAction() {
721
218
  const document2 = useActiveDocument4();
722
219
  const { save } = useActiveDocumentActions3();
723
220
  const isPreviewMode = useIsPreviewMode();
724
- const popupState = usePopupState4({
221
+ const popupState = usePopupState({
725
222
  variant: "popover",
726
223
  popupId: "document-save-options"
727
224
  });
@@ -731,7 +228,7 @@ function PrimaryAction() {
731
228
  const isPublishDisabled = isPreviewMode || !isPublishEnabled(document2);
732
229
  const isSaveOptionsDisabled = isPreviewMode || document2.type.value === "kit";
733
230
  const shouldShowSpinner = document2.isSaving && !isPublishDisabled;
734
- return /* @__PURE__ */ React24.createElement(React24.Fragment, null, /* @__PURE__ */ React24.createElement(ButtonGroup, { size: "large", variant: "contained" }, /* @__PURE__ */ React24.createElement(
231
+ return /* @__PURE__ */ React3.createElement(React3.Fragment, null, /* @__PURE__ */ React3.createElement(ButtonGroup, { size: "large", variant: "contained" }, /* @__PURE__ */ React3.createElement(
735
232
  Button,
736
233
  {
737
234
  onClick: () => !document2.isSaving && save(),
@@ -745,11 +242,11 @@ function PrimaryAction() {
745
242
  },
746
243
  disabled: isPublishDisabled
747
244
  },
748
- shouldShowSpinner ? /* @__PURE__ */ React24.createElement(CircularProgress, { color: "inherit", size: "1.5em" }) : getLabel(document2)
749
- ), /* @__PURE__ */ React24.createElement(
750
- Tooltip4,
245
+ shouldShowSpinner ? /* @__PURE__ */ React3.createElement(CircularProgress, { color: "inherit", size: "1.5em" }) : getLabel(document2)
246
+ ), /* @__PURE__ */ React3.createElement(
247
+ Tooltip2,
751
248
  {
752
- title: __8("Save Options", "elementor"),
249
+ title: __5("Save Options", "elementor"),
753
250
  PopperProps: {
754
251
  sx: {
755
252
  "&.MuiTooltip-popper .MuiTooltip-tooltip.MuiTooltip-tooltipPlacementBottom": {
@@ -759,21 +256,21 @@ function PrimaryAction() {
759
256
  }
760
257
  }
761
258
  },
762
- /* @__PURE__ */ React24.createElement(Box5, { component: "span", "aria-label": void 0 }, /* @__PURE__ */ React24.createElement(
259
+ /* @__PURE__ */ React3.createElement(Box2, { component: "span", "aria-label": void 0 }, /* @__PURE__ */ React3.createElement(
763
260
  Button,
764
261
  {
765
262
  size: "small",
766
- ...bindTrigger3(popupState),
263
+ ...bindTrigger(popupState),
767
264
  sx: { px: 0, height: "100%", borderRadius: 0 },
768
265
  disabled: isSaveOptionsDisabled,
769
- "aria-label": __8("Save Options", "elementor")
266
+ "aria-label": __5("Save Options", "elementor")
770
267
  },
771
- /* @__PURE__ */ React24.createElement(ChevronDownIcon, null)
268
+ /* @__PURE__ */ React3.createElement(ChevronDownIcon, null)
772
269
  ))
773
- )), /* @__PURE__ */ React24.createElement(PrimaryActionMenu, { ...bindMenu4(popupState), onClick: popupState.close }));
270
+ )), /* @__PURE__ */ React3.createElement(PrimaryActionMenu, { ...bindMenu(popupState), onClick: popupState.close }));
774
271
  }
775
272
  function getLabel(document2) {
776
- return document2.userCan.publish ? __8("Publish", "elementor") : __8("Submit", "elementor");
273
+ return document2.userCan.publish ? __5("Publish", "elementor") : __5("Submit", "elementor");
777
274
  }
778
275
  function isPublishEnabled(document2) {
779
276
  if (document2.type.value === "kit") {
@@ -805,11 +302,11 @@ function init3() {
805
302
  }
806
303
 
807
304
  // src/extensions/elements/sync/sync-panel-title.ts
808
- import { __ as __9 } from "@wordpress/i18n";
305
+ import { __ as __6 } from "@wordpress/i18n";
809
306
  import { __privateIsRouteActive as isRouteActive, __privateListenTo as listenTo2, routeOpenEvent as routeOpenEvent2, v1ReadyEvent } from "@elementor/editor-v1-adapters";
810
307
  function syncPanelTitle() {
811
- const panelTitle = __9("Elements", "elementor");
812
- const tabTitle = __9("Widgets", "elementor");
308
+ const panelTitle = __6("Elements", "elementor");
309
+ const tabTitle = __6("Widgets", "elementor");
813
310
  listenTo2(
814
311
  routeOpenEvent2("panel/elements"),
815
312
  () => {
@@ -837,14 +334,17 @@ function setTabTitle(title) {
837
334
  }
838
335
  }
839
336
 
337
+ // src/extensions/elements/index.ts
338
+ import { __privateToolsMenu as toolsMenu } from "@elementor/editor-app-bar-ui";
339
+
840
340
  // src/extensions/elements/hooks/use-action-props.ts
841
341
  import { PlusIcon } from "@elementor/icons";
842
- import { __ as __10 } from "@wordpress/i18n";
342
+ import { __ as __7 } from "@wordpress/i18n";
843
343
  import { __privateOpenRoute as openRoute3, __privateUseRouteStatus as useRouteStatus2 } from "@elementor/editor-v1-adapters";
844
344
  function useActionProps2() {
845
345
  const { isActive, isBlocked } = useRouteStatus2("panel/elements");
846
346
  return {
847
- title: __10("Add Element", "elementor"),
347
+ title: __7("Add Element", "elementor"),
848
348
  icon: PlusIcon,
849
349
  onClick: () => openRoute3("panel/elements/categories"),
850
350
  selected: isActive,
@@ -862,8 +362,11 @@ function init4() {
862
362
  });
863
363
  }
864
364
 
365
+ // src/extensions/finder/index.ts
366
+ import { __privateUtilitiesMenu as utilitiesMenu2 } from "@elementor/editor-app-bar-ui";
367
+
865
368
  // src/extensions/finder/hooks/use-action-props.ts
866
- import { __ as __11 } from "@wordpress/i18n";
369
+ import { __ as __8 } from "@wordpress/i18n";
867
370
  import { SearchIcon } from "@elementor/icons";
868
371
  import { __privateRunCommand as runCommand2, __privateUseRouteStatus as useRouteStatus3 } from "@elementor/editor-v1-adapters";
869
372
  function useActionProps3() {
@@ -872,7 +375,7 @@ function useActionProps3() {
872
375
  blockOnPreviewMode: false
873
376
  });
874
377
  return {
875
- title: __11("Finder", "elementor"),
378
+ title: __8("Finder", "elementor"),
876
379
  icon: SearchIcon,
877
380
  onClick: () => runCommand2("finder/toggle"),
878
381
  disabled: isBlocked
@@ -881,7 +384,7 @@ function useActionProps3() {
881
384
 
882
385
  // src/extensions/finder/index.ts
883
386
  function init5() {
884
- utilitiesMenu.registerAction({
387
+ utilitiesMenu2.registerAction({
885
388
  id: "toggle-finder",
886
389
  priority: 10,
887
390
  // Before help.
@@ -890,16 +393,17 @@ function init5() {
890
393
  }
891
394
 
892
395
  // src/extensions/help/index.ts
893
- import { __ as __12 } from "@wordpress/i18n";
396
+ import { __privateUtilitiesMenu as utilitiesMenu3 } from "@elementor/editor-app-bar-ui";
397
+ import { __ as __9 } from "@wordpress/i18n";
894
398
  import { HelpIcon } from "@elementor/icons";
895
399
  function init6() {
896
- utilitiesMenu.registerLink({
400
+ utilitiesMenu3.registerLink({
897
401
  id: "open-help-center",
898
402
  priority: 20,
899
403
  // After Finder.
900
404
  useProps: () => {
901
405
  return {
902
- title: __12("Help", "elementor"),
406
+ title: __9("Help", "elementor"),
903
407
  href: "https://go.elementor.com/editor-top-bar-learn/",
904
408
  icon: HelpIcon,
905
409
  target: "_blank"
@@ -908,14 +412,17 @@ function init6() {
908
412
  });
909
413
  }
910
414
 
415
+ // src/extensions/history/index.ts
416
+ import { __privateMainMenu as mainMenu } from "@elementor/editor-app-bar-ui";
417
+
911
418
  // src/extensions/history/hooks/use-action-props.ts
912
419
  import { HistoryIcon } from "@elementor/icons";
913
- import { __ as __13 } from "@wordpress/i18n";
420
+ import { __ as __10 } from "@wordpress/i18n";
914
421
  import { __privateOpenRoute as openRoute4, __privateUseRouteStatus as useRouteStatus4 } from "@elementor/editor-v1-adapters";
915
422
  function useActionProps4() {
916
423
  const { isActive, isBlocked } = useRouteStatus4("panel/history");
917
424
  return {
918
- title: __13("History", "elementor"),
425
+ title: __10("History", "elementor"),
919
426
  icon: HistoryIcon,
920
427
  onClick: () => openRoute4("panel/history/actions"),
921
428
  selected: isActive,
@@ -932,21 +439,24 @@ function init7() {
932
439
  });
933
440
  }
934
441
 
442
+ // src/extensions/keyboard-shortcuts/index.ts
443
+ import { __privateMainMenu as mainMenu2 } from "@elementor/editor-app-bar-ui";
444
+
935
445
  // src/extensions/keyboard-shortcuts/hooks/use-action-props.ts
936
- import { __ as __14 } from "@wordpress/i18n";
446
+ import { __ as __11 } from "@wordpress/i18n";
937
447
  import { KeyboardIcon } from "@elementor/icons";
938
448
  import { __privateRunCommand as runCommand3 } from "@elementor/editor-v1-adapters";
939
449
  function useActionProps5() {
940
450
  return {
941
451
  icon: KeyboardIcon,
942
- title: __14("Keyboard Shortcuts", "elementor"),
452
+ title: __11("Keyboard Shortcuts", "elementor"),
943
453
  onClick: () => runCommand3("shortcuts/open")
944
454
  };
945
455
  }
946
456
 
947
457
  // src/extensions/keyboard-shortcuts/index.ts
948
458
  function init8() {
949
- mainMenu.registerAction({
459
+ mainMenu2.registerAction({
950
460
  id: "open-keyboard-shortcuts",
951
461
  group: "default",
952
462
  priority: 40,
@@ -959,10 +469,10 @@ function init8() {
959
469
  import { injectIntoTop } from "@elementor/editor";
960
470
 
961
471
  // src/extensions/site-settings/components/portalled-primary-action.tsx
962
- import * as React27 from "react";
472
+ import * as React6 from "react";
963
473
 
964
474
  // src/extensions/site-settings/components/portal.tsx
965
- import * as React25 from "react";
475
+ import * as React4 from "react";
966
476
  import { Portal as BasePortal } from "@elementor/ui";
967
477
  import { __privateIsRouteActive as isRouteActive2, routeCloseEvent, routeOpenEvent as routeOpenEvent3, __privateUseListenTo as useListenTo } from "@elementor/editor-v1-adapters";
968
478
  function Portal(props) {
@@ -976,26 +486,26 @@ function Portal(props) {
976
486
  if (!containerRef.current) {
977
487
  return null;
978
488
  }
979
- return /* @__PURE__ */ React25.createElement(BasePortal, { container: containerRef.current, ...props });
489
+ return /* @__PURE__ */ React4.createElement(BasePortal, { container: containerRef.current, ...props });
980
490
  }
981
491
  function getContainerRef() {
982
492
  return isRouteActive2("panel/global") ? { current: document.querySelector("#elementor-panel-inner") } : { current: null };
983
493
  }
984
494
 
985
495
  // src/extensions/site-settings/components/primary-action.tsx
986
- import * as React26 from "react";
496
+ import * as React5 from "react";
987
497
  import { __useActiveDocument as useActiveDocument5, __useActiveDocumentActions as useActiveDocumentActions4 } from "@elementor/editor-documents";
988
498
  import { Button as Button2, CircularProgress as CircularProgress2, Paper } from "@elementor/ui";
989
- import { __ as __15 } from "@wordpress/i18n";
499
+ import { __ as __12 } from "@wordpress/i18n";
990
500
  function PrimaryAction2() {
991
501
  const document2 = useActiveDocument5();
992
502
  const { save } = useActiveDocumentActions4();
993
- return /* @__PURE__ */ React26.createElement(Paper, { sx: {
503
+ return /* @__PURE__ */ React5.createElement(Paper, { sx: {
994
504
  px: 5,
995
505
  py: 4,
996
506
  borderTop: 1,
997
507
  borderColor: "divider"
998
- } }, /* @__PURE__ */ React26.createElement(
508
+ } }, /* @__PURE__ */ React5.createElement(
999
509
  Button2,
1000
510
  {
1001
511
  variant: "contained",
@@ -1004,17 +514,20 @@ function PrimaryAction2() {
1004
514
  sx: { width: "100%" },
1005
515
  onClick: () => document2 && !document2.isSaving ? save() : null
1006
516
  },
1007
- document2?.isSaving ? /* @__PURE__ */ React26.createElement(CircularProgress2, null) : __15("Save Changes", "elementor")
517
+ document2?.isSaving ? /* @__PURE__ */ React5.createElement(CircularProgress2, null) : __12("Save Changes", "elementor")
1008
518
  ));
1009
519
  }
1010
520
 
1011
521
  // src/extensions/site-settings/components/portalled-primary-action.tsx
1012
522
  function PortalledPrimaryAction() {
1013
- return /* @__PURE__ */ React27.createElement(Portal, null, /* @__PURE__ */ React27.createElement(PrimaryAction2, null));
523
+ return /* @__PURE__ */ React6.createElement(Portal, null, /* @__PURE__ */ React6.createElement(PrimaryAction2, null));
1014
524
  }
1015
525
 
526
+ // src/extensions/site-settings/index.ts
527
+ import { __privateToolsMenu as toolsMenu2 } from "@elementor/editor-app-bar-ui";
528
+
1016
529
  // src/extensions/site-settings/hooks/use-action-props.ts
1017
- import { __ as __16 } from "@wordpress/i18n";
530
+ import { __ as __13 } from "@wordpress/i18n";
1018
531
  import { __privateRunCommand as runCommand4, __privateUseRouteStatus as useRouteStatus5 } from "@elementor/editor-v1-adapters";
1019
532
  import { AdjustmentsHorizontalIcon } from "@elementor/icons";
1020
533
  function useActionProps6() {
@@ -1022,7 +535,7 @@ function useActionProps6() {
1022
535
  blockOnKitRoutes: false
1023
536
  });
1024
537
  return {
1025
- title: __16("Site Settings", "elementor"),
538
+ title: __13("Site Settings", "elementor"),
1026
539
  icon: AdjustmentsHorizontalIcon,
1027
540
  onClick: () => isActive ? runCommand4("panel/global/close") : runCommand4("panel/global/open"),
1028
541
  selected: isActive,
@@ -1036,21 +549,24 @@ function init9() {
1036
549
  id: "site-settings-primary-action-portal",
1037
550
  component: PortalledPrimaryAction
1038
551
  });
1039
- toolsMenu.registerToggleAction({
552
+ toolsMenu2.registerToggleAction({
1040
553
  id: "toggle-site-settings",
1041
554
  priority: 2,
1042
555
  useProps: useActionProps6
1043
556
  });
1044
557
  }
1045
558
 
559
+ // src/extensions/structure/index.ts
560
+ import { __privateToolsMenu as toolsMenu3 } from "@elementor/editor-app-bar-ui";
561
+
1046
562
  // src/extensions/structure/hooks/use-action-props.ts
1047
- import { __ as __17 } from "@wordpress/i18n";
563
+ import { __ as __14 } from "@wordpress/i18n";
1048
564
  import { __privateRunCommand as runCommand5, __privateUseRouteStatus as useRouteStatus6 } from "@elementor/editor-v1-adapters";
1049
565
  import { StructureIcon } from "@elementor/icons";
1050
566
  function useActionProps7() {
1051
567
  const { isActive, isBlocked } = useRouteStatus6("navigator");
1052
568
  return {
1053
- title: __17("Structure", "elementor"),
569
+ title: __14("Structure", "elementor"),
1054
570
  icon: StructureIcon,
1055
571
  onClick: () => runCommand5("navigator/toggle"),
1056
572
  selected: isActive,
@@ -1060,42 +576,48 @@ function useActionProps7() {
1060
576
 
1061
577
  // src/extensions/structure/index.ts
1062
578
  function init10() {
1063
- toolsMenu.registerToggleAction({
579
+ toolsMenu3.registerToggleAction({
1064
580
  id: "toggle-structure-view",
1065
581
  priority: 3,
1066
582
  useProps: useActionProps7
1067
583
  });
1068
584
  }
1069
585
 
586
+ // src/extensions/theme-builder/index.ts
587
+ import { __privateMainMenu as mainMenu3 } from "@elementor/editor-app-bar-ui";
588
+
1070
589
  // src/extensions/theme-builder/hooks/use-action-props.ts
1071
- import { __ as __18 } from "@wordpress/i18n";
590
+ import { __ as __15 } from "@wordpress/i18n";
1072
591
  import { ThemeBuilderIcon } from "@elementor/icons";
1073
592
  import { __privateRunCommand as runCommand6 } from "@elementor/editor-v1-adapters";
1074
593
  function useActionProps8() {
1075
594
  return {
1076
595
  icon: ThemeBuilderIcon,
1077
- title: __18("Theme Builder", "elementor"),
596
+ title: __15("Theme Builder", "elementor"),
1078
597
  onClick: () => runCommand6("app/open")
1079
598
  };
1080
599
  }
1081
600
 
1082
601
  // src/extensions/theme-builder/index.ts
1083
602
  function init11() {
1084
- mainMenu.registerAction({
603
+ mainMenu3.registerAction({
1085
604
  id: "open-theme-builder",
1086
605
  useProps: useActionProps8
1087
606
  });
1088
607
  }
1089
608
 
609
+ // src/extensions/user-preferences/index.ts
610
+ import { __privateMainMenu as mainMenu4 } from "@elementor/editor-app-bar-ui";
611
+
1090
612
  // src/extensions/user-preferences/hooks/use-action-props.ts
1091
- import { __ as __19 } from "@wordpress/i18n";
613
+ import { __ as __16 } from "@wordpress/i18n";
1092
614
  import { ToggleRightIcon } from "@elementor/icons";
1093
615
  import { __privateOpenRoute as openRoute5, __privateUseRouteStatus as useRouteStatus7 } from "@elementor/editor-v1-adapters";
1094
616
  function useActionProps9() {
1095
617
  const { isActive, isBlocked } = useRouteStatus7("panel/editor-preferences");
1096
618
  return {
1097
619
  icon: ToggleRightIcon,
1098
- title: __19("User Preferences", "elementor"),
620
+ title: __16("User Preferences", "elementor"),
1099
621
  onClick: () => openRoute5("panel/editor-preferences"),
1100
622
  selected: isActive,
1101
623
  disabled: isBlocked
@@ -1104,7 +626,7 @@ function useActionProps9() {
1104
626
 
1105
627
  // src/extensions/user-preferences/index.ts
1106
628
  function init12() {
1107
- mainMenu.registerToggleAction({
629
+ mainMenu4.registerToggleAction({
1108
630
  id: "open-user-preferences",
1109
631
  priority: 30,
1110
632
  // After history.
@@ -1113,17 +635,18 @@ function init12() {
1113
635
  }
1114
636
 
1115
637
  // src/extensions/wordpress/index.ts
1116
- import { __ as __20 } from "@wordpress/i18n";
638
+ import { __privateMainMenu as mainMenu5 } from "@elementor/editor-app-bar-ui";
639
+ import { __ as __17 } from "@wordpress/i18n";
1117
640
  import { WordpressIcon } from "@elementor/icons";
1118
641
  import { __useActiveDocument as useActiveDocument6 } from "@elementor/editor-documents";
1119
642
  function init13() {
1120
- mainMenu.registerLink({
643
+ mainMenu5.registerLink({
1121
644
  id: "exit-to-wordpress",
1122
645
  group: "exits",
1123
646
  useProps: () => {
1124
647
  const document2 = useActiveDocument6();
1125
648
  return {
1126
- title: __20("Exit to WordPress", "elementor"),
649
+ title: __17("Exit to WordPress", "elementor"),
1127
650
  href: document2?.links?.platformEdit,
1128
651
  icon: WordpressIcon
1129
652
  };
@@ -1162,12 +685,12 @@ function init15() {
1162
685
  init15();
1163
686
  export {
1164
687
  documentOptionsMenu,
1165
- injectIntoPageIndication,
1166
- injectIntoPrimaryAction,
1167
- injectIntoResponsive,
1168
- integrationsMenu,
1169
- mainMenu,
1170
- toolsMenu,
1171
- utilitiesMenu
688
+ __privateInjectIntoPageIndication as injectIntoPageIndication,
689
+ __privateInjectIntoPrimaryAction as injectIntoPrimaryAction,
690
+ __privateInjectIntoResponsive as injectIntoResponsive,
691
+ __privateIntegrationsMenu as integrationsMenu,
692
+ __privateMainMenu as mainMenu,
693
+ __privateToolsMenu as toolsMenu,
694
+ __privateUtilitiesMenu as utilitiesMenu
1172
695
  };
1173
696
  //# sourceMappingURL=index.mjs.map