@elementor/editor-app-bar 0.13.0 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/dist/index.js +219 -16
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +219 -16
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
- package/src/extensions/documents-indicator/components/settings-button.tsx +19 -1
- package/src/extensions/documents-preview/hooks/use-action-props.ts +24 -4
- package/src/extensions/documents-save/components/primary-action.tsx +21 -1
- package/src/extensions/elements/hooks/use-action-props.ts +19 -1
- package/src/extensions/finder/hooks/use-action-props.ts +19 -1
- package/src/extensions/help/index.ts +17 -0
- package/src/extensions/history/hooks/use-action-props.ts +19 -1
- package/src/extensions/keyboard-shortcuts/hooks/use-action-props.ts +19 -1
- package/src/extensions/site-settings/hooks/use-action-props.ts +23 -5
- package/src/extensions/structure/hooks/use-action-props.ts +19 -1
- package/src/extensions/theme-builder/hooks/use-action-props.ts +19 -1
- package/src/extensions/user-preferences/hooks/use-action-props.ts +19 -1
- package/src/extensions/wordpress/index.ts +17 -0
- package/src/types.ts +16 -0
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [0.14.0](https://github.com/elementor/elementor-packages/compare/@elementor/editor-app-bar@0.13.0...@elementor/editor-app-bar@0.14.0) (2024-06-04)
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Features
|
|
10
|
+
|
|
11
|
+
* internal create a top bar data events collection working with mixpanel [ED-14684] ([#184](https://github.com/elementor/elementor-packages/issues/184)) ([9d25189](https://github.com/elementor/elementor-packages/commit/9d25189173a65d535347f9b2f32d377bcffb6c52))
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
|
|
6
17
|
# [0.13.0](https://github.com/elementor/elementor-packages/compare/@elementor/editor-app-bar@0.12.0...@elementor/editor-app-bar@0.13.0) (2024-06-02)
|
|
7
18
|
|
|
8
19
|
|
package/dist/index.js
CHANGED
|
@@ -83,7 +83,22 @@ function SettingsButton() {
|
|
|
83
83
|
value: "document-settings",
|
|
84
84
|
selected: isActive,
|
|
85
85
|
disabled: isBlocked,
|
|
86
|
-
onChange: () =>
|
|
86
|
+
onChange: () => {
|
|
87
|
+
const extendedWindow = window;
|
|
88
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
89
|
+
if (config) {
|
|
90
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
91
|
+
config.names.topBar.documentSettings,
|
|
92
|
+
{
|
|
93
|
+
location: config.locations.topBar,
|
|
94
|
+
secondaryLocation: config.secondaryLocations["document-settings"],
|
|
95
|
+
trigger: config.triggers.click,
|
|
96
|
+
element: config.elements.buttonIcon
|
|
97
|
+
}
|
|
98
|
+
);
|
|
99
|
+
}
|
|
100
|
+
(0, import_editor_v1_adapters2.__privateOpenRoute)("panel/page-settings/settings");
|
|
101
|
+
},
|
|
87
102
|
"aria-label": title,
|
|
88
103
|
size: "small",
|
|
89
104
|
sx: {
|
|
@@ -139,10 +154,27 @@ function useActionProps() {
|
|
|
139
154
|
return {
|
|
140
155
|
icon: import_icons2.EyeIcon,
|
|
141
156
|
title: (0, import_i18n2.__)("Preview Changes", "elementor"),
|
|
142
|
-
onClick: () =>
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
157
|
+
onClick: () => {
|
|
158
|
+
const extendedWindow = window;
|
|
159
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
160
|
+
if (config) {
|
|
161
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
162
|
+
config.names.topBar.previewPage,
|
|
163
|
+
{
|
|
164
|
+
location: config.locations.topBar,
|
|
165
|
+
secondaryLocation: config.secondaryLocations["preview-page"],
|
|
166
|
+
trigger: config.triggers.click,
|
|
167
|
+
element: config.elements.buttonIcon
|
|
168
|
+
}
|
|
169
|
+
);
|
|
170
|
+
}
|
|
171
|
+
if (document2) {
|
|
172
|
+
(0, import_editor_v1_adapters3.__privateRunCommand)("editor/documents/preview", {
|
|
173
|
+
id: document2.id,
|
|
174
|
+
force: true
|
|
175
|
+
});
|
|
176
|
+
}
|
|
177
|
+
}
|
|
146
178
|
};
|
|
147
179
|
}
|
|
148
180
|
|
|
@@ -276,7 +308,24 @@ function PrimaryAction() {
|
|
|
276
308
|
return /* @__PURE__ */ React3.createElement(React3.Fragment, null, /* @__PURE__ */ React3.createElement(import_ui3.ButtonGroup, { size: "large", variant: "contained" }, /* @__PURE__ */ React3.createElement(
|
|
277
309
|
import_ui3.Button,
|
|
278
310
|
{
|
|
279
|
-
onClick: () =>
|
|
311
|
+
onClick: () => {
|
|
312
|
+
const extendedWindow = window;
|
|
313
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
314
|
+
if (config) {
|
|
315
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
316
|
+
config.names.topBar.publishButton,
|
|
317
|
+
{
|
|
318
|
+
location: config.locations.topBar,
|
|
319
|
+
secondaryLocation: config.secondaryLocations["publish-button"],
|
|
320
|
+
trigger: config.triggers.click,
|
|
321
|
+
element: config.elements.mainCta
|
|
322
|
+
}
|
|
323
|
+
);
|
|
324
|
+
}
|
|
325
|
+
if (!document2.isSaving) {
|
|
326
|
+
save();
|
|
327
|
+
}
|
|
328
|
+
},
|
|
280
329
|
sx: {
|
|
281
330
|
height: "100%",
|
|
282
331
|
borderRadius: 0,
|
|
@@ -415,7 +464,22 @@ function useActionProps2() {
|
|
|
415
464
|
return {
|
|
416
465
|
title: (0, import_i18n9.__)("Add Element", "elementor"),
|
|
417
466
|
icon: import_icons8.PlusIcon,
|
|
418
|
-
onClick: () =>
|
|
467
|
+
onClick: () => {
|
|
468
|
+
const extendedWindow = window;
|
|
469
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
470
|
+
if (config) {
|
|
471
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
472
|
+
config.names.topBar.widgetPanel,
|
|
473
|
+
{
|
|
474
|
+
location: config.locations.topBar,
|
|
475
|
+
secondaryLocation: config.secondaryLocations["widget-panel"],
|
|
476
|
+
trigger: config.triggers.toggleClick,
|
|
477
|
+
element: config.elements.buttonIcon
|
|
478
|
+
}
|
|
479
|
+
);
|
|
480
|
+
}
|
|
481
|
+
(0, import_editor_v1_adapters7.__privateOpenRoute)("panel/elements/categories");
|
|
482
|
+
},
|
|
419
483
|
selected: isActive,
|
|
420
484
|
disabled: isBlocked
|
|
421
485
|
};
|
|
@@ -446,7 +510,22 @@ function useActionProps3() {
|
|
|
446
510
|
return {
|
|
447
511
|
title: (0, import_i18n10.__)("Finder", "elementor"),
|
|
448
512
|
icon: import_icons9.SearchIcon,
|
|
449
|
-
onClick: () =>
|
|
513
|
+
onClick: () => {
|
|
514
|
+
const extendedWindow = window;
|
|
515
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
516
|
+
if (config) {
|
|
517
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
518
|
+
config.names.topBar.finder,
|
|
519
|
+
{
|
|
520
|
+
location: config.locations.topBar,
|
|
521
|
+
secondaryLocation: config.secondaryLocations.finder,
|
|
522
|
+
trigger: config.triggers.toggleClick,
|
|
523
|
+
element: config.elements.buttonIcon
|
|
524
|
+
}
|
|
525
|
+
);
|
|
526
|
+
}
|
|
527
|
+
(0, import_editor_v1_adapters8.__privateRunCommand)("finder/toggle");
|
|
528
|
+
},
|
|
450
529
|
disabled: isBlocked
|
|
451
530
|
};
|
|
452
531
|
}
|
|
@@ -475,7 +554,22 @@ function init6() {
|
|
|
475
554
|
title: (0, import_i18n11.__)("Help", "elementor"),
|
|
476
555
|
href: "https://go.elementor.com/editor-top-bar-learn/",
|
|
477
556
|
icon: import_icons10.HelpIcon,
|
|
478
|
-
target: "_blank"
|
|
557
|
+
target: "_blank",
|
|
558
|
+
onClick: () => {
|
|
559
|
+
const extendedWindow = window;
|
|
560
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
561
|
+
if (config) {
|
|
562
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
563
|
+
config.names.topBar.help,
|
|
564
|
+
{
|
|
565
|
+
location: config.locations.topBar,
|
|
566
|
+
secondaryLocation: config.secondaryLocations.help,
|
|
567
|
+
trigger: config.triggers.click,
|
|
568
|
+
element: config.elements.buttonIcon
|
|
569
|
+
}
|
|
570
|
+
);
|
|
571
|
+
}
|
|
572
|
+
}
|
|
479
573
|
};
|
|
480
574
|
}
|
|
481
575
|
});
|
|
@@ -493,7 +587,22 @@ function useActionProps4() {
|
|
|
493
587
|
return {
|
|
494
588
|
title: (0, import_i18n12.__)("History", "elementor"),
|
|
495
589
|
icon: import_icons11.HistoryIcon,
|
|
496
|
-
onClick: () =>
|
|
590
|
+
onClick: () => {
|
|
591
|
+
const extendedWindow = window;
|
|
592
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
593
|
+
if (config) {
|
|
594
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
595
|
+
config.names.topBar.history,
|
|
596
|
+
{
|
|
597
|
+
location: config.locations.topBar,
|
|
598
|
+
secondaryLocation: config.secondaryLocations.elementorLogo,
|
|
599
|
+
trigger: config.triggers.click,
|
|
600
|
+
element: config.elements.link
|
|
601
|
+
}
|
|
602
|
+
);
|
|
603
|
+
}
|
|
604
|
+
(0, import_editor_v1_adapters9.__privateOpenRoute)("panel/history/actions");
|
|
605
|
+
},
|
|
497
606
|
selected: isActive,
|
|
498
607
|
disabled: isBlocked
|
|
499
608
|
};
|
|
@@ -519,7 +628,22 @@ function useActionProps5() {
|
|
|
519
628
|
return {
|
|
520
629
|
icon: import_icons12.KeyboardIcon,
|
|
521
630
|
title: (0, import_i18n13.__)("Keyboard Shortcuts", "elementor"),
|
|
522
|
-
onClick: () =>
|
|
631
|
+
onClick: () => {
|
|
632
|
+
const extendedWindow = window;
|
|
633
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
634
|
+
if (config) {
|
|
635
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
636
|
+
config.names.topBar.keyboardShortcuts,
|
|
637
|
+
{
|
|
638
|
+
location: config.locations.topBar,
|
|
639
|
+
secondaryLocation: config.secondaryLocations.elementorLogo,
|
|
640
|
+
trigger: config.triggers.click,
|
|
641
|
+
element: config.elements.link
|
|
642
|
+
}
|
|
643
|
+
);
|
|
644
|
+
}
|
|
645
|
+
(0, import_editor_v1_adapters10.__privateRunCommand)("shortcuts/open");
|
|
646
|
+
}
|
|
523
647
|
};
|
|
524
648
|
}
|
|
525
649
|
|
|
@@ -606,7 +730,26 @@ function useActionProps6() {
|
|
|
606
730
|
return {
|
|
607
731
|
title: (0, import_i18n15.__)("Site Settings", "elementor"),
|
|
608
732
|
icon: import_icons13.AdjustmentsHorizontalIcon,
|
|
609
|
-
onClick: () =>
|
|
733
|
+
onClick: () => {
|
|
734
|
+
const extendedWindow = window;
|
|
735
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
736
|
+
if (config) {
|
|
737
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
738
|
+
config.names.topBar.siteSettings,
|
|
739
|
+
{
|
|
740
|
+
location: config.locations.topBar,
|
|
741
|
+
secondaryLocation: config.secondaryLocations.siteSettings,
|
|
742
|
+
trigger: config.triggers.toggleClick,
|
|
743
|
+
element: config.elements.buttonIcon
|
|
744
|
+
}
|
|
745
|
+
);
|
|
746
|
+
}
|
|
747
|
+
if (isActive) {
|
|
748
|
+
(0, import_editor_v1_adapters12.__privateRunCommand)("panel/global/close");
|
|
749
|
+
} else {
|
|
750
|
+
(0, import_editor_v1_adapters12.__privateRunCommand)("panel/global/open");
|
|
751
|
+
}
|
|
752
|
+
},
|
|
610
753
|
selected: isActive,
|
|
611
754
|
disabled: isBlocked
|
|
612
755
|
};
|
|
@@ -637,7 +780,22 @@ function useActionProps7() {
|
|
|
637
780
|
return {
|
|
638
781
|
title: (0, import_i18n16.__)("Structure", "elementor"),
|
|
639
782
|
icon: import_icons14.StructureIcon,
|
|
640
|
-
onClick: () =>
|
|
783
|
+
onClick: () => {
|
|
784
|
+
const extendedWindow = window;
|
|
785
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
786
|
+
if (config) {
|
|
787
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
788
|
+
config.names.topBar.structure,
|
|
789
|
+
{
|
|
790
|
+
location: config.locations.topBar,
|
|
791
|
+
secondaryLocation: config.secondaryLocations.structure,
|
|
792
|
+
trigger: config.triggers.toggleClick,
|
|
793
|
+
element: config.elements.buttonIcon
|
|
794
|
+
}
|
|
795
|
+
);
|
|
796
|
+
}
|
|
797
|
+
(0, import_editor_v1_adapters13.__privateRunCommand)("navigator/toggle");
|
|
798
|
+
},
|
|
641
799
|
selected: isActive,
|
|
642
800
|
disabled: isBlocked
|
|
643
801
|
};
|
|
@@ -663,7 +821,22 @@ function useActionProps8() {
|
|
|
663
821
|
return {
|
|
664
822
|
icon: import_icons15.ThemeBuilderIcon,
|
|
665
823
|
title: (0, import_i18n17.__)("Theme Builder", "elementor"),
|
|
666
|
-
onClick: () =>
|
|
824
|
+
onClick: () => {
|
|
825
|
+
const extendedWindow = window;
|
|
826
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
827
|
+
if (config) {
|
|
828
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
829
|
+
config.names.topBar.themeBuilder,
|
|
830
|
+
{
|
|
831
|
+
location: config.locations.topBar,
|
|
832
|
+
secondaryLocation: config.secondaryLocations.elementorLogo,
|
|
833
|
+
trigger: config.triggers.click,
|
|
834
|
+
element: config.elements.link
|
|
835
|
+
}
|
|
836
|
+
);
|
|
837
|
+
}
|
|
838
|
+
(0, import_editor_v1_adapters14.__privateRunCommand)("app/open");
|
|
839
|
+
}
|
|
667
840
|
};
|
|
668
841
|
}
|
|
669
842
|
|
|
@@ -687,7 +860,22 @@ function useActionProps9() {
|
|
|
687
860
|
return {
|
|
688
861
|
icon: import_icons16.ToggleRightIcon,
|
|
689
862
|
title: (0, import_i18n18.__)("User Preferences", "elementor"),
|
|
690
|
-
onClick: () =>
|
|
863
|
+
onClick: () => {
|
|
864
|
+
const extendedWindow = window;
|
|
865
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
866
|
+
if (config) {
|
|
867
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
868
|
+
config.names.topBar.userPreferences,
|
|
869
|
+
{
|
|
870
|
+
location: config.locations.topBar,
|
|
871
|
+
secondaryLocation: config.secondaryLocations.elementorLogo,
|
|
872
|
+
trigger: config.triggers.click,
|
|
873
|
+
element: config.elements.link
|
|
874
|
+
}
|
|
875
|
+
);
|
|
876
|
+
}
|
|
877
|
+
(0, import_editor_v1_adapters15.__privateOpenRoute)("panel/editor-preferences");
|
|
878
|
+
},
|
|
691
879
|
selected: isActive,
|
|
692
880
|
disabled: isBlocked
|
|
693
881
|
};
|
|
@@ -717,7 +905,22 @@ function init13() {
|
|
|
717
905
|
return {
|
|
718
906
|
title: (0, import_i18n19.__)("Exit to WordPress", "elementor"),
|
|
719
907
|
href: document2?.links?.platformEdit,
|
|
720
|
-
icon: import_icons17.WordpressIcon
|
|
908
|
+
icon: import_icons17.WordpressIcon,
|
|
909
|
+
onClick: () => {
|
|
910
|
+
const extendedWindow = window;
|
|
911
|
+
const config = extendedWindow?.elementor?.editorEvents?.config;
|
|
912
|
+
if (config) {
|
|
913
|
+
extendedWindow.elementor.editorEvents.dispatchEvent(
|
|
914
|
+
config.names.topBar.exitToWordpress,
|
|
915
|
+
{
|
|
916
|
+
location: config.locations.topBar,
|
|
917
|
+
secondaryLocation: config.secondaryLocations.elementorLogo,
|
|
918
|
+
trigger: config.triggers.click,
|
|
919
|
+
element: config.elements.link
|
|
920
|
+
}
|
|
921
|
+
);
|
|
922
|
+
}
|
|
923
|
+
}
|
|
721
924
|
};
|
|
722
925
|
}
|
|
723
926
|
});
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../src/index.ts","../src/extensions/documents-save/locations.ts","../src/init.ts","../src/sync/redirect-old-menus.ts","../src/extensions/documents-indicator/index.ts","../src/extensions/documents-indicator/components/settings-button.tsx","../src/extensions/documents-preview/index.ts","../src/extensions/documents-preview/hooks/use-action-props.ts","../src/extensions/documents-save/index.ts","../src/extensions/documents-save/hooks/use-document-save-draft-props.ts","../src/extensions/documents-save/hooks/use-document-save-template-props.ts","../src/extensions/documents-save/hooks/use-document-view-page-props.ts","../src/extensions/documents-save/components/primary-action.tsx","../src/extensions/documents-save/components/primary-action-menu.tsx","../src/extensions/documents-save/hooks/use-document-copy-and-share-props.ts","../src/extensions/elements/sync/sync-panel-title.ts","../src/extensions/elements/index.ts","../src/extensions/elements/hooks/use-action-props.ts","../src/extensions/finder/index.ts","../src/extensions/finder/hooks/use-action-props.ts","../src/extensions/help/index.ts","../src/extensions/history/index.ts","../src/extensions/history/hooks/use-action-props.ts","../src/extensions/keyboard-shortcuts/index.ts","../src/extensions/keyboard-shortcuts/hooks/use-action-props.ts","../src/extensions/site-settings/index.ts","../src/extensions/site-settings/components/portalled-primary-action.tsx","../src/extensions/site-settings/components/portal.tsx","../src/extensions/site-settings/components/primary-action.tsx","../src/extensions/site-settings/hooks/use-action-props.ts","../src/extensions/structure/index.ts","../src/extensions/structure/hooks/use-action-props.ts","../src/extensions/theme-builder/index.ts","../src/extensions/theme-builder/hooks/use-action-props.ts","../src/extensions/user-preferences/index.ts","../src/extensions/user-preferences/hooks/use-action-props.ts","../src/extensions/wordpress/index.ts","../src/extensions/index.ts"],"sourcesContent":["// Re-exporting the menus & locations from `@elementor/editor-app-bar-ui`\n// to expose the API for other packages to use.\nexport {\n\t__privateMainMenu as mainMenu,\n\t__privateToolsMenu as toolsMenu,\n\t__privateUtilitiesMenu as utilitiesMenu,\n\t__privateIntegrationsMenu as integrationsMenu,\n\t__privateInjectIntoPageIndication as injectIntoPageIndication,\n\t__privateInjectIntoResponsive as injectIntoResponsive,\n\t__privateInjectIntoPrimaryAction as injectIntoPrimaryAction,\n} from '@elementor/editor-app-bar-ui';\n\nexport { documentOptionsMenu } from './extensions/documents-save/locations';\n\nimport init from './init';\n\ninit();\n","import { __privateCreateMenu as createMenu } from '@elementor/editor-app-bar-ui';\n\nexport const documentOptionsMenu = createMenu( [ 'save' ] );\n","import { __privateAppBar as AppBar } from '@elementor/editor-app-bar-ui';\nimport { injectIntoTop } from '@elementor/editor';\nimport redirectOldMenus from './sync/redirect-old-menus';\nimport { init as initExtensions } from './extensions';\n\nexport default function init() {\n\tredirectOldMenus();\n\n\tinitExtensions();\n\n\tinjectIntoTop( {\n\t\tid: 'app-bar',\n\t\tcomponent: AppBar,\n\t} );\n}\n","import { __privateListenTo as listenTo, __privateOpenRoute as openRoute, routeOpenEvent } from '@elementor/editor-v1-adapters';\n\nexport default function redirectOldMenus() {\n\t// Currently, in V1, when you click `esc` it opens the hamburger menu in the panel.\n\t// In V2, we don't have this panel, so we redirect the user to the elements panel instead.\n\tlistenTo( routeOpenEvent( 'panel/menu' ), () => {\n\t\topenRoute( 'panel/elements/categories' );\n\t} );\n}\n","import { __privateInjectIntoPageIndication as injectIntoPageIndication } from '@elementor/editor-app-bar-ui';\nimport SettingsButton from './components/settings-button';\n\nexport function init() {\n\tinjectIntoPageIndication( {\n\t\tid: 'document-settings-button',\n\t\tcomponent: SettingsButton,\n\t\toptions: {\n\t\t\tpriority: 20, // After document indicator.\n\t\t},\n\t} );\n}\n","import * as React from 'react';\nimport { Box, ToggleButton, Tooltip as BaseTooltip, TooltipProps } from '@elementor/ui';\nimport { __ } from '@wordpress/i18n';\nimport { __privateOpenRoute as openRoute, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { SettingsIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument, __useHostDocument as useHostDocument } from '@elementor/editor-documents';\n\nexport default function SettingsButton() {\n\tconst activeDocument = useActiveDocument();\n\tconst hostDocument = useHostDocument();\n\n\tconst document = activeDocument && activeDocument.type.value !== 'kit'\n\t\t? activeDocument\n\t\t: hostDocument;\n\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/page-settings' );\n\n\tif ( ! document ) {\n\t\treturn null;\n\t}\n\n\t/* translators: %s: Post type label. */\n\tconst title = __( '%s Settings', 'elementor' )\n\t\t.replace( '%s', document.type.label );\n\n\treturn (\n\t\t<Tooltip title={ title }>\n\t\t\t{ /* @see https://mui.com/material-ui/react-tooltip/#disabled-elements */ }\n\t\t\t<Box component=\"span\" aria-label={ undefined }>\n\t\t\t\t<ToggleButton\n\t\t\t\t\tvalue=\"document-settings\"\n\t\t\t\t\tselected={ isActive }\n\t\t\t\t\tdisabled={ isBlocked }\n\t\t\t\t\tonChange={ () => openRoute( 'panel/page-settings/settings' ) }\n\t\t\t\t\taria-label={ title }\n\t\t\t\t\tsize=\"small\"\n\t\t\t\t\tsx={ {\n\t\t\t\t\t\tborder: 0, // Temp fix until the style of the ToggleButton component will be decided.\n\t\t\t\t\t\t'&.Mui-disabled': {\n\t\t\t\t\t\t\tborder: 0, // Temp fix until the style of the ToggleButton component will be decided.\n\t\t\t\t\t\t},\n\t\t\t\t\t} }\n\t\t\t\t>\n\t\t\t\t\t<SettingsIcon fontSize=\"small\" />\n\t\t\t\t</ToggleButton>\n\t\t\t</Box>\n\t\t</Tooltip>\n\t);\n}\n\nfunction Tooltip( props: TooltipProps ) {\n\treturn <BaseTooltip\n\t\tPopperProps={ {\n\t\t\tsx: {\n\t\t\t\t'&.MuiTooltip-popper .MuiTooltip-tooltip.MuiTooltip-tooltipPlacementBottom': {\n\t\t\t\t\tmt: 1.7,\n\t\t\t\t},\n\t\t\t},\n\t\t} }\n\t\t{ ...props }\n\t/>;\n}\n","import { __privateUtilitiesMenu as utilitiesMenu } from '@elementor/editor-app-bar-ui';\nimport useDocumentPreviewProps from './hooks/use-action-props';\n\nexport function init() {\n\tutilitiesMenu.registerAction( {\n\t\tid: 'document-preview-button',\n\t\tpriority: 30, // After help.\n\t\tuseProps: useDocumentPreviewProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { EyeIcon } from '@elementor/icons';\nimport { __privateRunCommand as runCommand } from '@elementor/editor-v1-adapters';\nimport { __useActiveDocument as useActiveDocument } from '@elementor/editor-documents';\n\nexport default function useActionProps() {\n\tconst document = useActiveDocument();\n\n\treturn {\n\t\ticon: EyeIcon,\n\t\ttitle: __( 'Preview Changes', 'elementor' ),\n\t\tonClick: () => document && runCommand( 'editor/documents/preview', {\n\t\t\tid: document.id,\n\t\t\tforce: true,\n\t\t} ),\n\t};\n}\n","import { __privateInjectIntoPrimaryAction as injectIntoPrimaryAction } from '@elementor/editor-app-bar-ui';\nimport useDocumentSaveDraftProps from './hooks/use-document-save-draft-props';\nimport useDocumentSaveTemplateProps from './hooks/use-document-save-template-props';\nimport useDocumentViewPageProps from './hooks/use-document-view-page-props';\nimport PrimaryAction from './components/primary-action';\nimport { documentOptionsMenu } from './locations';\nimport useDocumentCopyAndShareProps from './hooks/use-document-copy-and-share-props';\n\nexport function init() {\n\tinjectIntoPrimaryAction( {\n\t\tid: 'document-primary-action',\n\t\tcomponent: PrimaryAction,\n\t} );\n\n\tdocumentOptionsMenu.registerAction( {\n\t\tgroup: 'save',\n\t\tid: 'document-save-draft',\n\t\tpriority: 10,\n\t\tuseProps: useDocumentSaveDraftProps,\n\t} );\n\n\tdocumentOptionsMenu.registerAction( {\n\t\tgroup: 'save',\n\t\tid: 'document-save-as-template',\n\t\tpriority: 20,\n\t\tuseProps: useDocumentSaveTemplateProps,\n\t} );\n\n\tdocumentOptionsMenu.registerAction( {\n\t\tid: 'document-copy-and-share',\n\t\tpriority: 10,\n\t\tuseProps: useDocumentCopyAndShareProps,\n\t} );\n\n\tdocumentOptionsMenu.registerAction( {\n\t\tid: 'document-view-page',\n\t\tpriority: 50,\n\t\tuseProps: useDocumentViewPageProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\nimport { FileReportIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument, __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\n\nexport default function useDocumentSaveDraftProps(): ActionProps {\n\tconst document = useActiveDocument();\n\tconst { saveDraft } = useActiveDocumentActions();\n\n\treturn {\n\t\ticon: FileReportIcon,\n\t\ttitle: __( 'Save Draft', 'elementor' ),\n\t\tonClick: saveDraft,\n\t\tdisabled: ! document || document.isSaving || document.isSavingDraft || ! document.isDirty,\n\t};\n}\n","import { __ } from '@wordpress/i18n';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\nimport { FolderIcon } from '@elementor/icons';\nimport { __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\n\nexport default function useDocumentSaveTemplateProps(): ActionProps {\n\tconst { saveTemplate } = useActiveDocumentActions();\n\n\treturn {\n\t\ticon: FolderIcon,\n\t\ttitle: __( 'Save as Template', 'elementor' ),\n\t\tonClick: saveTemplate,\n\t};\n}\n","import { __ } from '@wordpress/i18n';\nimport { EyeIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument } from '@elementor/editor-documents';\nimport { __privateRunCommand as runCommand } from '@elementor/editor-v1-adapters';\n\nexport default function useDocumentViewPageProps() {\n\tconst document = useActiveDocument();\n\n\treturn {\n\t\ticon: EyeIcon,\n\t\ttitle: __( 'View Page', 'elementor' ),\n\t\tonClick: () => document?.id && runCommand( 'editor/documents/view', {\n\t\t\tid: document.id,\n\t\t} ),\n\t};\n}\n","import * as React from 'react';\nimport { __ } from '@wordpress/i18n';\nimport PrimaryActionMenu from './primary-action-menu';\nimport {\n\tbindMenu,\n\tbindTrigger,\n\tBox,\n\tButton,\n\tButtonGroup,\n\tCircularProgress,\n\tTooltip,\n\tusePopupState,\n} from '@elementor/ui';\nimport { Document, __useActiveDocument as useActiveDocument, __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\nimport { ChevronDownIcon } from '@elementor/icons';\nimport { __privateUseIsPreviewMode as useIsPreviewMode } from '@elementor/editor-v1-adapters';\n\nexport default function PrimaryAction() {\n\tconst document = useActiveDocument();\n\tconst { save } = useActiveDocumentActions();\n\tconst isPreviewMode = useIsPreviewMode();\n\n\tconst popupState = usePopupState( {\n\t\tvariant: 'popover',\n\t\tpopupId: 'document-save-options',\n\t} );\n\n\tif ( ! document ) {\n\t\treturn null;\n\t}\n\n\tconst isPublishDisabled = isPreviewMode || ! isPublishEnabled( document );\n\tconst isSaveOptionsDisabled = isPreviewMode || document.type.value === 'kit';\n\n\t// When the document is being saved, the spinner should not appear.\n\t// Usually happens when the Kit is being saved.\n\tconst shouldShowSpinner = document.isSaving && ! isPublishDisabled;\n\n\treturn (\n\t\t<>\n\t\t\t<ButtonGroup size=\"large\" variant=\"contained\">\n\t\t\t\t<Button\n\t\t\t\t\tonClick={ () => ! document.isSaving && save() }\n\t\t\t\t\tsx={ {\n\t\t\t\t\t\theight: '100%',\n\t\t\t\t\t\tborderRadius: 0,\n\t\t\t\t\t\tmaxWidth: '158px',\n\t\t\t\t\t\t'&.MuiButtonBase-root.MuiButtonGroup-grouped': {\n\t\t\t\t\t\t\tminWidth: '110px',\n\t\t\t\t\t\t},\n\t\t\t\t\t} }\n\t\t\t\t\tdisabled={ isPublishDisabled }\n\t\t\t\t>\n\t\t\t\t\t{ shouldShowSpinner ? <CircularProgress color=\"inherit\" size=\"1.5em\" /> : getLabel( document ) }\n\t\t\t\t</Button>\n\n\t\t\t\t<Tooltip\n\t\t\t\t\ttitle={ __( 'Save Options', 'elementor' ) }\n\t\t\t\t\tPopperProps={ {\n\t\t\t\t\t\tsx: {\n\t\t\t\t\t\t\t'&.MuiTooltip-popper .MuiTooltip-tooltip.MuiTooltip-tooltipPlacementBottom': {\n\t\t\t\t\t\t\t\tmt: 1,\n\t\t\t\t\t\t\t\tmr: 0.25,\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t} }\n\t\t\t\t>\n\t\t\t\t\t<Box component=\"span\" aria-label={ undefined }>\n\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\tsize=\"small\"\n\t\t\t\t\t\t\t{ ...bindTrigger( popupState ) }\n\t\t\t\t\t\t\tsx={ { px: 0, height: '100%', borderRadius: 0 } }\n\t\t\t\t\t\t\tdisabled={ isSaveOptionsDisabled }\n\t\t\t\t\t\t\taria-label={ __( 'Save Options', 'elementor' ) }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<ChevronDownIcon />\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t</Box>\n\t\t\t\t</Tooltip>\n\t\t\t</ButtonGroup>\n\t\t\t<PrimaryActionMenu { ...bindMenu( popupState ) } onClick={ popupState.close } />\n\t\t</>\n\t);\n}\n\nfunction getLabel( document: Document ) {\n\treturn document.userCan.publish\n\t\t? __( 'Publish', 'elementor' )\n\t\t: __( 'Submit', 'elementor' );\n}\n\nfunction isPublishEnabled( document: Document ) {\n\tif ( document.type.value === 'kit' ) {\n\t\treturn false;\n\t}\n\n\treturn document.isDirty || document.status.value === 'draft';\n}\n","import * as React from 'react';\nimport { Divider, styled } from '@elementor/ui';\nimport { __privatePopoverMenu as PopoverMenu, PopoverMenuProps } from '@elementor/editor-app-bar-ui';\nimport { documentOptionsMenu } from '../locations';\n\nconst { useMenuItems } = documentOptionsMenu;\n\n// CSS hack to hide dividers for empty menu items, due to a limitation in the locations' mechanism.\nconst StyledPopoverMenu = styled( PopoverMenu )`\n\t& > .MuiPopover-paper > .MuiList-root {\n\t\t& > .MuiDivider-root {\n\t\t\tdisplay: none;\n\t\t}\n\n\t\t& > *:not(.MuiDivider-root):not(:last-of-type) + .MuiDivider-root {\n\t\t\tdisplay: block;\n\t\t}\n\t}\n`;\n\nexport default function PrimaryActionMenu( props: PopoverMenuProps ) {\n\tconst { save: saveActions, default: defaultActions } = useMenuItems();\n\n\treturn (\n\t\t<StyledPopoverMenu\n\t\t\t{ ...props }\n\t\t\tanchorOrigin={ {\n\t\t\t\tvertical: 'bottom',\n\t\t\t\thorizontal: 'right',\n\t\t\t} }\n\t\t\ttransformOrigin={ {\n\t\t\t\tvertical: 'top',\n\t\t\t\thorizontal: 'right',\n\t\t\t} }\n\t\t\tmarginThreshold={ 4 }\n\t\t\tPaperProps={ {\n\t\t\t\tsx: { mt: 0.5 },\n\t\t\t} }\n\t\t>\n\t\t\t{ saveActions.map( ( { MenuItem, id }, index ) => ( [\n\t\t\t\t( index > 0 ) && <Divider key={ `${ id }-divider` } />,\n\t\t\t\t<MenuItem key={ id } />,\n\t\t\t] ) ) }\n\n\t\t\t{ saveActions.length > 0 && defaultActions.length > 0 && <Divider /> }\n\n\t\t\t{ defaultActions.map( ( { MenuItem, id }, index ) => ( [\n\t\t\t\t( index > 0 ) && <Divider key={ `${ id }-divider` } />,\n\t\t\t\t<MenuItem key={ id } />,\n\t\t\t] ) ) }\n\t\t</StyledPopoverMenu>\n\t);\n}\n","import { __ } from '@wordpress/i18n';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\nimport { LinkIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument, __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\n\nexport default function useDocumentCopyAndShareProps(): ActionProps {\n\tconst document = useActiveDocument();\n\tconst { copyAndShare } = useActiveDocumentActions();\n\n\treturn {\n\t\ticon: LinkIcon,\n\t\ttitle: __( 'Copy and Share', 'elementor' ),\n\t\tonClick: copyAndShare,\n\t\tdisabled: ! document ||\n\t\t\tdocument.isSaving ||\n\t\t\tdocument.isSavingDraft ||\n\t\t\t! ( 'publish' === document.status.value ),\n\t\tvisible: document?.permissions?.showCopyAndShare,\n\t};\n}\n","import { __ } from '@wordpress/i18n';\nimport { __privateIsRouteActive as isRouteActive, __privateListenTo as listenTo, routeOpenEvent, v1ReadyEvent } from '@elementor/editor-v1-adapters';\n\ntype ExtendedWindow = Window & {\n\telementor: {\n\t\tgetPanelView: () => {\n\t\t\tgetHeaderView: () => {\n\t\t\t\tsetTitle: ( title: string ) => void;\n\t\t\t}\n\t\t}\n\t}\n}\n\nexport default function syncPanelTitle() {\n\tconst panelTitle = __( 'Elements', 'elementor' );\n\tconst tabTitle = __( 'Widgets', 'elementor' );\n\n\tlistenTo(\n\t\trouteOpenEvent( 'panel/elements' ),\n\t\t() => {\n\t\t\tsetPanelTitle( panelTitle );\n\t\t\tsetTabTitle( tabTitle );\n\t\t}\n\t);\n\n\tlistenTo(\n\t\tv1ReadyEvent(),\n\t\t() => {\n\t\t\tif ( isRouteActive( 'panel/elements' ) ) {\n\t\t\t\tsetPanelTitle( panelTitle );\n\t\t\t\tsetTabTitle( tabTitle );\n\t\t\t}\n\t\t}\n\t);\n}\n\nfunction setPanelTitle( title: string ) {\n\t( window as unknown as ExtendedWindow ).elementor?.getPanelView?.()?.getHeaderView?.()?.setTitle?.( title );\n}\n\nfunction setTabTitle( title: string ) {\n\tconst tab = document.querySelector( '.elementor-component-tab[data-tab=\"categories\"]' );\n\n\tif ( tab ) {\n\t\ttab.textContent = title;\n\t}\n}\n","import syncPanelTitle from './sync/sync-panel-title';\nimport { __privateToolsMenu as toolsMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tsyncPanelTitle();\n\n\ttoolsMenu.registerToggleAction( {\n\t\tid: 'open-elements-panel',\n\t\tpriority: 1,\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { PlusIcon } from '@elementor/icons';\nimport { __ } from '@wordpress/i18n';\nimport { __privateOpenRoute as openRoute, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\n\nexport default function useActionProps() {\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/elements' );\n\n\treturn {\n\t\ttitle: __( 'Add Element', 'elementor' ),\n\t\ticon: PlusIcon,\n\t\tonClick: () => openRoute( 'panel/elements/categories' ),\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateUtilitiesMenu as utilitiesMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tutilitiesMenu.registerAction( {\n\t\tid: 'toggle-finder',\n\t\tpriority: 10, // Before help.\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { SearchIcon } from '@elementor/icons';\nimport { __privateRunCommand as runCommand, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\n\nexport default function useActionProps() {\n\tconst { isBlocked } = useRouteStatus( 'finder', {\n\t\tblockOnKitRoutes: false,\n\t\tblockOnPreviewMode: false,\n\t} );\n\n\treturn {\n\t\ttitle: __( 'Finder', 'elementor' ),\n\t\ticon: SearchIcon,\n\t\tonClick: () => runCommand( 'finder/toggle' ),\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateUtilitiesMenu as utilitiesMenu } from '@elementor/editor-app-bar-ui';\nimport { __ } from '@wordpress/i18n';\nimport { HelpIcon } from '@elementor/icons';\n\nexport function init() {\n\tutilitiesMenu.registerLink( {\n\t\tid: 'open-help-center',\n\t\tpriority: 20, // After Finder.\n\t\tuseProps: () => {\n\t\t\treturn {\n\t\t\t\ttitle: __( 'Help', 'elementor' ),\n\t\t\t\thref: 'https://go.elementor.com/editor-top-bar-learn/',\n\t\t\t\ticon: HelpIcon,\n\t\t\t\ttarget: '_blank',\n\t\t\t};\n\t\t},\n\t} );\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tmainMenu.registerToggleAction( {\n\t\tid: 'open-history',\n\t\tpriority: 20,\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { HistoryIcon } from '@elementor/icons';\nimport { __ } from '@wordpress/i18n';\nimport { __privateOpenRoute as openRoute, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\n\nexport default function useActionProps() {\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/history' );\n\n\treturn {\n\t\ttitle: __( 'History', 'elementor' ),\n\t\ticon: HistoryIcon,\n\t\tonClick: () => openRoute( 'panel/history/actions' ),\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tmainMenu.registerAction( {\n\t\tid: 'open-keyboard-shortcuts',\n\t\tgroup: 'default',\n\t\tpriority: 40, // After user preferences.\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\nimport { KeyboardIcon } from '@elementor/icons';\nimport { __privateRunCommand as runCommand } from '@elementor/editor-v1-adapters';\n\nexport default function useActionProps(): ActionProps {\n\treturn {\n\t\ticon: KeyboardIcon,\n\t\ttitle: __( 'Keyboard Shortcuts', 'elementor' ),\n\t\tonClick: () => runCommand( 'shortcuts/open' ),\n\t};\n}\n","import { injectIntoTop } from '@elementor/editor';\nimport PortalledPrimaryAction from './components/portalled-primary-action';\nimport { __privateToolsMenu as toolsMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\t// This is portal, so it injected into the top of the editor, but renders inside the site-settings panel.\n\tinjectIntoTop( {\n\t\tid: 'site-settings-primary-action-portal',\n\t\tcomponent: PortalledPrimaryAction,\n\t} );\n\n\ttoolsMenu.registerToggleAction( {\n\t\tid: 'toggle-site-settings',\n\t\tpriority: 2,\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import * as React from 'react';\nimport Portal from './portal';\nimport PrimaryAction from './primary-action';\n\nexport default function PortalledPrimaryAction() {\n\treturn (\n\t\t<Portal>\n\t\t\t<PrimaryAction />\n\t\t</Portal>\n\t);\n}\n","import * as React from 'react';\nimport { Portal as BasePortal, PortalProps } from '@elementor/ui';\nimport { __privateIsRouteActive as isRouteActive, routeCloseEvent, routeOpenEvent, __privateUseListenTo as useListenTo } from '@elementor/editor-v1-adapters';\n\nexport default function Portal( props: Omit<PortalProps, 'container'> ) {\n\tconst containerRef = useListenTo(\n\t\t[\n\t\t\trouteOpenEvent( 'panel/global' ),\n\t\t\trouteCloseEvent( 'panel/global' ),\n\t\t],\n\t\tgetContainerRef\n\t);\n\n\tif ( ! containerRef.current ) {\n\t\treturn null;\n\t}\n\n\treturn (\n\t\t<BasePortal container={ containerRef.current } { ...props } />\n\t);\n}\n\nfunction getContainerRef() {\n\treturn isRouteActive( 'panel/global' )\n\t\t? { current: document.querySelector( '#elementor-panel-inner' ) }\n\t\t: { current: null };\n}\n","import * as React from 'react';\nimport { __useActiveDocument as useActiveDocument, __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\nimport { Button, CircularProgress, Paper } from '@elementor/ui';\nimport { __ } from '@wordpress/i18n';\n\nexport default function PrimaryAction() {\n\tconst document = useActiveDocument();\n\tconst { save } = useActiveDocumentActions();\n\n\treturn (\n\t\t<Paper sx={ {\n\t\t\tpx: 5,\n\t\t\tpy: 4,\n\t\t\tborderTop: 1,\n\t\t\tborderColor: 'divider',\n\t\t} }>\n\t\t\t<Button\n\t\t\t\tvariant=\"contained\"\n\t\t\t\tdisabled={ ! document || ! document.isDirty }\n\t\t\t\tsize=\"medium\"\n\t\t\t\tsx={ { width: '100%' } }\n\t\t\t\tonClick={ () => document && ! document.isSaving ? save() : null }\n\t\t\t>\n\t\t\t\t{\n\t\t\t\t\tdocument?.isSaving\n\t\t\t\t\t\t? <CircularProgress />\n\t\t\t\t\t\t: __( 'Save Changes', 'elementor' )\n\t\t\t\t}\n\t\t\t</Button>\n\t\t</Paper>\n\t);\n}\n","import { __ } from '@wordpress/i18n';\nimport { __privateRunCommand as runCommand, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { ToggleActionProps } from '@elementor/editor-app-bar-ui';\nimport { AdjustmentsHorizontalIcon } from '@elementor/icons';\n\nexport default function useActionProps(): ToggleActionProps {\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/global', {\n\t\tblockOnKitRoutes: false,\n\t} );\n\n\treturn {\n\t\ttitle: __( 'Site Settings', 'elementor' ),\n\t\ticon: AdjustmentsHorizontalIcon,\n\t\tonClick: () => (\n\t\t\tisActive\n\t\t\t\t? runCommand( 'panel/global/close' )\n\t\t\t\t: runCommand( 'panel/global/open' )\n\t\t),\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateToolsMenu as toolsMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\ttoolsMenu.registerToggleAction( {\n\t\tid: 'toggle-structure-view',\n\t\tpriority: 3,\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { __privateRunCommand as runCommand, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { StructureIcon } from '@elementor/icons';\nimport { ToggleActionProps } from '@elementor/editor-app-bar-ui';\n\nexport default function useActionProps(): ToggleActionProps {\n\tconst { isActive, isBlocked } = useRouteStatus( 'navigator' );\n\n\treturn {\n\t\ttitle: __( 'Structure', 'elementor' ),\n\t\ticon: StructureIcon,\n\t\tonClick: () => runCommand( 'navigator/toggle' ),\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport useThemeBuilderActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tmainMenu.registerAction( {\n\t\tid: 'open-theme-builder',\n\t\tuseProps: useThemeBuilderActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { ThemeBuilderIcon } from '@elementor/icons';\nimport { __privateRunCommand as runCommand } from '@elementor/editor-v1-adapters';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\n\nexport default function useActionProps(): ActionProps {\n\treturn {\n\t\ticon: ThemeBuilderIcon,\n\t\ttitle: __( 'Theme Builder', 'elementor' ),\n\t\tonClick: () => runCommand( 'app/open' ),\n\t};\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tmainMenu.registerToggleAction( {\n\t\tid: 'open-user-preferences',\n\t\tpriority: 30, // After history.\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { ToggleActionProps } from '@elementor/editor-app-bar-ui';\nimport { ToggleRightIcon } from '@elementor/icons';\nimport { __privateOpenRoute as openRoute, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\n\nexport default function useActionProps(): ToggleActionProps {\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/editor-preferences' );\n\n\treturn {\n\t\ticon: ToggleRightIcon,\n\t\ttitle: __( 'User Preferences', 'elementor' ),\n\t\tonClick: () => openRoute( 'panel/editor-preferences' ),\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport { __ } from '@wordpress/i18n';\nimport { WordpressIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument } from '@elementor/editor-documents';\n\nexport function init() {\n\tmainMenu.registerLink( {\n\t\tid: 'exit-to-wordpress',\n\t\tgroup: 'exits',\n\t\tuseProps: () => {\n\t\t\tconst document = useActiveDocument();\n\t\t\treturn {\n\t\t\t\ttitle: __( 'Exit to WordPress', 'elementor' ),\n\t\t\t\thref: document?.links?.platformEdit,\n\t\t\t\ticon: WordpressIcon,\n\t\t\t};\n\t\t},\n\t} );\n}\n","/**\n * All the code in this directory is a temporary solution.\n * The code should be moved to the appropriate packages.\n */\n\nimport { init as initDocumentsIndicator } from './documents-indicator';\nimport { init as initDocumentsPreview } from './documents-preview';\nimport { init as initDocumentsSave } from './documents-save';\nimport { init as initElements } from './elements';\nimport { init as initFinder } from './finder';\nimport { init as initHelp } from './help';\nimport { init as initHistory } from './history';\nimport { init as initKeyboardShortcuts } from './keyboard-shortcuts';\nimport { init as initSiteSettings } from './site-settings';\nimport { init as initStructure } from './structure';\nimport { init as initThemeBuilder } from './theme-builder';\nimport { init as initUserPreferences } from './user-preferences';\nimport { init as initWordpress } from './wordpress';\n\nexport function init() {\n\tinitDocumentsIndicator();\n\tinitDocumentsPreview();\n\tinitDocumentsSave();\n\tinitElements();\n\tinitFinder();\n\tinitHelp();\n\tinitHistory();\n\tinitKeyboardShortcuts();\n\tinitSiteSettings();\n\tinitStructure();\n\tinitThemeBuilder();\n\tinitUserPreferences();\n\tinitWordpress();\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAEA,IAAAA,6BAQO;;;ACVP,+BAAkD;AAE3C,IAAM,0BAAsB,yBAAAC,qBAAY,CAAE,MAAO,CAAE;;;ACF1D,IAAAC,6BAA0C;AAC1C,IAAAC,iBAA8B;;;ACD9B,gCAA+F;AAEhF,SAAR,mBAAoC;AAG1C,gCAAAC,uBAAU,0CAAgB,YAAa,GAAG,MAAM;AAC/C,kCAAAC,oBAAW,2BAA4B;AAAA,EACxC,CAAE;AACH;;;ACRA,IAAAC,4BAA8E;;;ACA9E,YAAuB;AACvB,gBAAwE;AACxE,kBAAmB;AACnB,IAAAC,6BAA2F;AAC3F,mBAA6B;AAC7B,8BAA+F;AAEhF,SAAR,iBAAkC;AACxC,QAAM,qBAAiB,wBAAAC,qBAAkB;AACzC,QAAM,mBAAe,wBAAAC,mBAAgB;AAErC,QAAMC,YAAW,kBAAkB,eAAe,KAAK,UAAU,QAC9D,iBACA;AAEH,QAAM,EAAE,UAAU,UAAU,QA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O,SAASE,SAAO;AACtB,OAAuB;AACvB,EAAAA,MAAqB;AACrB,EAAAA,MAAkB;AAClB,EAAAA,MAAa;AACb,EAAAA,MAAW;AACX,EAAAA,MAAS;AACT,EAAAA,MAAY;AACZ,EAAAA,MAAsB;AACtB,EAAAA,MAAiB;AACjB,EAAAA,OAAc;AACd,EAAAA,OAAiB;AACjB,EAAAA,OAAoB;AACpB,EAAAA,OAAc;AACf;;;AnC5Be,SAARC,SAAwB;AAC9B,mBAAiB;AAEjB,EAAAA,OAAe;AAEf,oCAAe;AAAA,IACd,IAAI;AAAA,IACJ,WAAW,2BAAAC;AAAA,EACZ,CAAE;AACH;;;AFEAC,OAAK;","names":["import_editor_app_bar_ui","createMenu","import_editor_app_bar_ui","import_editor","listenTo","openRoute","import_editor_app_bar_ui","import_editor_v1_adapters","useActiveDocument","useHostDocument","document","useRouteStatus","openRoute","BaseTooltip","injectIntoPageIndication","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","import_editor_documents","document","useActiveDocument","runCommand","init","utilitiesMenu","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_documents","document","useActiveDocument","useActiveDocumentActions","import_i18n","import_icons","import_editor_documents","useActiveDocumentActions","import_i18n","import_icons","import_editor_documents","import_editor_v1_adapters","document","useActiveDocument","runCommand","React","import_i18n","React","import_ui","import_editor_app_bar_ui","PopoverMenu","import_ui","import_editor_documents","import_icons","import_editor_v1_adapters","document","useActiveDocument","useActiveDocumentActions","useIsPreviewMode","import_i18n","import_icons","import_editor_documents","document","useActiveDocument","useActiveDocumentActions","init","injectIntoPrimaryAction","import_i18n","import_editor_v1_adapters","listenTo","isRouteActive","import_editor_app_bar_ui","import_icons","import_i18n","import_editor_v1_adapters","useActionProps","useRouteStatus","openRoute","init","toolsMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","useActionProps","useRouteStatus","runCommand","init","utilitiesMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","init","utilitiesMenu","import_editor_app_bar_ui","import_icons","import_i18n","import_editor_v1_adapters","useActionProps","useRouteStatus","openRoute","init","mainMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","useActionProps","runCommand","init","mainMenu","useActionProps","React","React","import_ui","import_editor_v1_adapters","useListenTo","BasePortal","isRouteActive","React","import_editor_documents","import_ui","import_i18n","PrimaryAction","document","useActiveDocument","useActiveDocumentActions","PrimaryAction","import_editor_app_bar_ui","import_i18n","import_editor_v1_adapters","import_icons","useActionProps","useRouteStatus","runCommand","init","toolsMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_editor_v1_adapters","import_icons","useActionProps","useRouteStatus","runCommand","init","toolsMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","useActionProps","runCommand","init","mainMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","useActionProps","useRouteStatus","openRoute","init","mainMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_documents","init","mainMenu","document","useActiveDocument","init","init","AppBar","init"]}
|
|
1
|
+
{"version":3,"sources":["../src/index.ts","../src/extensions/documents-save/locations.ts","../src/init.ts","../src/sync/redirect-old-menus.ts","../src/extensions/documents-indicator/index.ts","../src/extensions/documents-indicator/components/settings-button.tsx","../src/extensions/documents-preview/index.ts","../src/extensions/documents-preview/hooks/use-action-props.ts","../src/extensions/documents-save/index.ts","../src/extensions/documents-save/hooks/use-document-save-draft-props.ts","../src/extensions/documents-save/hooks/use-document-save-template-props.ts","../src/extensions/documents-save/hooks/use-document-view-page-props.ts","../src/extensions/documents-save/components/primary-action.tsx","../src/extensions/documents-save/components/primary-action-menu.tsx","../src/extensions/documents-save/hooks/use-document-copy-and-share-props.ts","../src/extensions/elements/sync/sync-panel-title.ts","../src/extensions/elements/index.ts","../src/extensions/elements/hooks/use-action-props.ts","../src/extensions/finder/index.ts","../src/extensions/finder/hooks/use-action-props.ts","../src/extensions/help/index.ts","../src/extensions/history/index.ts","../src/extensions/history/hooks/use-action-props.ts","../src/extensions/keyboard-shortcuts/index.ts","../src/extensions/keyboard-shortcuts/hooks/use-action-props.ts","../src/extensions/site-settings/index.ts","../src/extensions/site-settings/components/portalled-primary-action.tsx","../src/extensions/site-settings/components/portal.tsx","../src/extensions/site-settings/components/primary-action.tsx","../src/extensions/site-settings/hooks/use-action-props.ts","../src/extensions/structure/index.ts","../src/extensions/structure/hooks/use-action-props.ts","../src/extensions/theme-builder/index.ts","../src/extensions/theme-builder/hooks/use-action-props.ts","../src/extensions/user-preferences/index.ts","../src/extensions/user-preferences/hooks/use-action-props.ts","../src/extensions/wordpress/index.ts","../src/extensions/index.ts"],"sourcesContent":["// Re-exporting the menus & locations from `@elementor/editor-app-bar-ui`\n// to expose the API for other packages to use.\nexport {\n\t__privateMainMenu as mainMenu,\n\t__privateToolsMenu as toolsMenu,\n\t__privateUtilitiesMenu as utilitiesMenu,\n\t__privateIntegrationsMenu as integrationsMenu,\n\t__privateInjectIntoPageIndication as injectIntoPageIndication,\n\t__privateInjectIntoResponsive as injectIntoResponsive,\n\t__privateInjectIntoPrimaryAction as injectIntoPrimaryAction,\n} from '@elementor/editor-app-bar-ui';\n\nexport { documentOptionsMenu } from './extensions/documents-save/locations';\n\nimport init from './init';\n\ninit();\n","import { __privateCreateMenu as createMenu } from '@elementor/editor-app-bar-ui';\n\nexport const documentOptionsMenu = createMenu( [ 'save' ] );\n","import { __privateAppBar as AppBar } from '@elementor/editor-app-bar-ui';\nimport { injectIntoTop } from '@elementor/editor';\nimport redirectOldMenus from './sync/redirect-old-menus';\nimport { init as initExtensions } from './extensions';\n\nexport default function init() {\n\tredirectOldMenus();\n\n\tinitExtensions();\n\n\tinjectIntoTop( {\n\t\tid: 'app-bar',\n\t\tcomponent: AppBar,\n\t} );\n}\n","import { __privateListenTo as listenTo, __privateOpenRoute as openRoute, routeOpenEvent } from '@elementor/editor-v1-adapters';\n\nexport default function redirectOldMenus() {\n\t// Currently, in V1, when you click `esc` it opens the hamburger menu in the panel.\n\t// In V2, we don't have this panel, so we redirect the user to the elements panel instead.\n\tlistenTo( routeOpenEvent( 'panel/menu' ), () => {\n\t\topenRoute( 'panel/elements/categories' );\n\t} );\n}\n","import { __privateInjectIntoPageIndication as injectIntoPageIndication } from '@elementor/editor-app-bar-ui';\nimport SettingsButton from './components/settings-button';\n\nexport function init() {\n\tinjectIntoPageIndication( {\n\t\tid: 'document-settings-button',\n\t\tcomponent: SettingsButton,\n\t\toptions: {\n\t\t\tpriority: 20, // After document indicator.\n\t\t},\n\t} );\n}\n","import * as React from 'react';\nimport { Box, ToggleButton, Tooltip as BaseTooltip, TooltipProps } from '@elementor/ui';\nimport { __ } from '@wordpress/i18n';\nimport { __privateOpenRoute as openRoute, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { SettingsIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument, __useHostDocument as useHostDocument } from '@elementor/editor-documents';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function SettingsButton() {\n\tconst activeDocument = useActiveDocument();\n\tconst hostDocument = useHostDocument();\n\n\tconst document = activeDocument && activeDocument.type.value !== 'kit'\n\t\t? activeDocument\n\t\t: hostDocument;\n\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/page-settings' );\n\n\tif ( ! document ) {\n\t\treturn null;\n\t}\n\n\t/* translators: %s: Post type label. */\n\tconst title = __( '%s Settings', 'elementor' )\n\t\t.replace( '%s', document.type.label );\n\n\treturn (\n\t\t<Tooltip title={ title }>\n\t\t\t{ /* @see https://mui.com/material-ui/react-tooltip/#disabled-elements */ }\n\t\t\t<Box component=\"span\" aria-label={ undefined }>\n\t\t\t\t<ToggleButton\n\t\t\t\t\tvalue=\"document-settings\"\n\t\t\t\t\tselected={ isActive }\n\t\t\t\t\tdisabled={ isBlocked }\n\t\t\t\t\tonChange={ () => {\n\t\t\t\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\t\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\t\t\t\tif ( config ) {\n\t\t\t\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\t\t\t\tconfig.names.topBar.documentSettings,\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations[ 'document-settings' ],\n\t\t\t\t\t\t\t\t\ttrigger: config.triggers.click,\n\t\t\t\t\t\t\t\t\telement: config.elements.buttonIcon,\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\topenRoute( 'panel/page-settings/settings' );\n\t\t\t\t\t} }\n\t\t\t\t\taria-label={ title }\n\t\t\t\t\tsize=\"small\"\n\t\t\t\t\tsx={ {\n\t\t\t\t\t\tborder: 0, // Temp fix until the style of the ToggleButton component will be decided.\n\t\t\t\t\t\t'&.Mui-disabled': {\n\t\t\t\t\t\t\tborder: 0, // Temp fix until the style of the ToggleButton component will be decided.\n\t\t\t\t\t\t},\n\t\t\t\t\t} }\n\t\t\t\t>\n\t\t\t\t\t<SettingsIcon fontSize=\"small\" />\n\t\t\t\t</ToggleButton>\n\t\t\t</Box>\n\t\t</Tooltip>\n\t);\n}\n\nfunction Tooltip( props: TooltipProps ) {\n\treturn <BaseTooltip\n\t\tPopperProps={ {\n\t\t\tsx: {\n\t\t\t\t'&.MuiTooltip-popper .MuiTooltip-tooltip.MuiTooltip-tooltipPlacementBottom': {\n\t\t\t\t\tmt: 1.7,\n\t\t\t\t},\n\t\t\t},\n\t\t} }\n\t\t{ ...props }\n\t/>;\n}\n","import { __privateUtilitiesMenu as utilitiesMenu } from '@elementor/editor-app-bar-ui';\nimport useDocumentPreviewProps from './hooks/use-action-props';\n\nexport function init() {\n\tutilitiesMenu.registerAction( {\n\t\tid: 'document-preview-button',\n\t\tpriority: 30, // After help.\n\t\tuseProps: useDocumentPreviewProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { EyeIcon } from '@elementor/icons';\nimport { __privateRunCommand as runCommand } from '@elementor/editor-v1-adapters';\nimport { __useActiveDocument as useActiveDocument } from '@elementor/editor-documents';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function useActionProps() {\n\tconst document = useActiveDocument();\n\n\treturn {\n\t\ticon: EyeIcon,\n\t\ttitle: __( 'Preview Changes', 'elementor' ),\n\t\tonClick: () => {\n\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\tif ( config ) {\n\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\tconfig.names.topBar.previewPage,\n\t\t\t\t\t{\n\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations[ 'preview-page' ],\n\t\t\t\t\t\ttrigger: config.triggers.click,\n\t\t\t\t\t\telement: config.elements.buttonIcon,\n\t\t\t\t\t},\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tif ( document ) {\n\t\t\t\trunCommand( 'editor/documents/preview', {\n\t\t\t\t\tid: document.id,\n\t\t\t\t\tforce: true,\n\t\t\t\t} );\n\t\t\t}\n\t\t},\n\t};\n}\n","import { __privateInjectIntoPrimaryAction as injectIntoPrimaryAction } from '@elementor/editor-app-bar-ui';\nimport useDocumentSaveDraftProps from './hooks/use-document-save-draft-props';\nimport useDocumentSaveTemplateProps from './hooks/use-document-save-template-props';\nimport useDocumentViewPageProps from './hooks/use-document-view-page-props';\nimport PrimaryAction from './components/primary-action';\nimport { documentOptionsMenu } from './locations';\nimport useDocumentCopyAndShareProps from './hooks/use-document-copy-and-share-props';\n\nexport function init() {\n\tinjectIntoPrimaryAction( {\n\t\tid: 'document-primary-action',\n\t\tcomponent: PrimaryAction,\n\t} );\n\n\tdocumentOptionsMenu.registerAction( {\n\t\tgroup: 'save',\n\t\tid: 'document-save-draft',\n\t\tpriority: 10,\n\t\tuseProps: useDocumentSaveDraftProps,\n\t} );\n\n\tdocumentOptionsMenu.registerAction( {\n\t\tgroup: 'save',\n\t\tid: 'document-save-as-template',\n\t\tpriority: 20,\n\t\tuseProps: useDocumentSaveTemplateProps,\n\t} );\n\n\tdocumentOptionsMenu.registerAction( {\n\t\tid: 'document-copy-and-share',\n\t\tpriority: 10,\n\t\tuseProps: useDocumentCopyAndShareProps,\n\t} );\n\n\tdocumentOptionsMenu.registerAction( {\n\t\tid: 'document-view-page',\n\t\tpriority: 50,\n\t\tuseProps: useDocumentViewPageProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\nimport { FileReportIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument, __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\n\nexport default function useDocumentSaveDraftProps(): ActionProps {\n\tconst document = useActiveDocument();\n\tconst { saveDraft } = useActiveDocumentActions();\n\n\treturn {\n\t\ticon: FileReportIcon,\n\t\ttitle: __( 'Save Draft', 'elementor' ),\n\t\tonClick: saveDraft,\n\t\tdisabled: ! document || document.isSaving || document.isSavingDraft || ! document.isDirty,\n\t};\n}\n","import { __ } from '@wordpress/i18n';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\nimport { FolderIcon } from '@elementor/icons';\nimport { __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\n\nexport default function useDocumentSaveTemplateProps(): ActionProps {\n\tconst { saveTemplate } = useActiveDocumentActions();\n\n\treturn {\n\t\ticon: FolderIcon,\n\t\ttitle: __( 'Save as Template', 'elementor' ),\n\t\tonClick: saveTemplate,\n\t};\n}\n","import { __ } from '@wordpress/i18n';\nimport { EyeIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument } from '@elementor/editor-documents';\nimport { __privateRunCommand as runCommand } from '@elementor/editor-v1-adapters';\n\nexport default function useDocumentViewPageProps() {\n\tconst document = useActiveDocument();\n\n\treturn {\n\t\ticon: EyeIcon,\n\t\ttitle: __( 'View Page', 'elementor' ),\n\t\tonClick: () => document?.id && runCommand( 'editor/documents/view', {\n\t\t\tid: document.id,\n\t\t} ),\n\t};\n}\n","import * as React from 'react';\nimport { __ } from '@wordpress/i18n';\nimport PrimaryActionMenu from './primary-action-menu';\nimport {\n\tbindMenu,\n\tbindTrigger,\n\tBox,\n\tButton,\n\tButtonGroup,\n\tCircularProgress,\n\tTooltip,\n\tusePopupState,\n} from '@elementor/ui';\nimport { Document, __useActiveDocument as useActiveDocument, __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\nimport { ChevronDownIcon } from '@elementor/icons';\nimport { __privateUseIsPreviewMode as useIsPreviewMode } from '@elementor/editor-v1-adapters';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function PrimaryAction() {\n\tconst document = useActiveDocument();\n\tconst { save } = useActiveDocumentActions();\n\tconst isPreviewMode = useIsPreviewMode();\n\n\tconst popupState = usePopupState( {\n\t\tvariant: 'popover',\n\t\tpopupId: 'document-save-options',\n\t} );\n\n\tif ( ! document ) {\n\t\treturn null;\n\t}\n\n\tconst isPublishDisabled = isPreviewMode || ! isPublishEnabled( document );\n\tconst isSaveOptionsDisabled = isPreviewMode || document.type.value === 'kit';\n\n\t// When the document is being saved, the spinner should not appear.\n\t// Usually happens when the Kit is being saved.\n\tconst shouldShowSpinner = document.isSaving && ! isPublishDisabled;\n\n\treturn (\n\t\t<>\n\t\t\t<ButtonGroup size=\"large\" variant=\"contained\">\n\t\t\t\t<Button\n\t\t\t\t\tonClick={ () => {\n\t\t\t\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\t\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\t\t\t\tif ( config ) {\n\t\t\t\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\t\t\t\tconfig.names.topBar.publishButton,\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations[ 'publish-button' ],\n\t\t\t\t\t\t\t\t\ttrigger: config.triggers.click,\n\t\t\t\t\t\t\t\t\telement: config.elements.mainCta,\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tif ( ! document.isSaving ) {\n\t\t\t\t\t\t\tsave();\n\t\t\t\t\t\t}\n\t\t\t\t\t} }\n\t\t\t\t\tsx={ {\n\t\t\t\t\t\theight: '100%',\n\t\t\t\t\t\tborderRadius: 0,\n\t\t\t\t\t\tmaxWidth: '158px',\n\t\t\t\t\t\t'&.MuiButtonBase-root.MuiButtonGroup-grouped': {\n\t\t\t\t\t\t\tminWidth: '110px',\n\t\t\t\t\t\t},\n\t\t\t\t\t} }\n\t\t\t\t\tdisabled={ isPublishDisabled }\n\t\t\t\t>\n\t\t\t\t\t{ shouldShowSpinner ? <CircularProgress color=\"inherit\" size=\"1.5em\" /> : getLabel( document ) }\n\t\t\t\t</Button>\n\n\t\t\t\t<Tooltip\n\t\t\t\t\ttitle={ __( 'Save Options', 'elementor' ) }\n\t\t\t\t\tPopperProps={ {\n\t\t\t\t\t\tsx: {\n\t\t\t\t\t\t\t'&.MuiTooltip-popper .MuiTooltip-tooltip.MuiTooltip-tooltipPlacementBottom': {\n\t\t\t\t\t\t\t\tmt: 1,\n\t\t\t\t\t\t\t\tmr: 0.25,\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t},\n\t\t\t\t\t} }\n\t\t\t\t>\n\t\t\t\t\t<Box component=\"span\" aria-label={ undefined }>\n\t\t\t\t\t\t<Button\n\t\t\t\t\t\t\tsize=\"small\"\n\t\t\t\t\t\t\t{ ...bindTrigger( popupState ) }\n\t\t\t\t\t\t\tsx={ { px: 0, height: '100%', borderRadius: 0 } }\n\t\t\t\t\t\t\tdisabled={ isSaveOptionsDisabled }\n\t\t\t\t\t\t\taria-label={ __( 'Save Options', 'elementor' ) }\n\t\t\t\t\t\t>\n\t\t\t\t\t\t\t<ChevronDownIcon />\n\t\t\t\t\t\t</Button>\n\t\t\t\t\t</Box>\n\t\t\t\t</Tooltip>\n\t\t\t</ButtonGroup>\n\t\t\t<PrimaryActionMenu { ...bindMenu( popupState ) } onClick={ popupState.close } />\n\t\t</>\n\t);\n}\n\nfunction getLabel( document: Document ) {\n\treturn document.userCan.publish\n\t\t? __( 'Publish', 'elementor' )\n\t\t: __( 'Submit', 'elementor' );\n}\n\nfunction isPublishEnabled( document: Document ) {\n\tif ( document.type.value === 'kit' ) {\n\t\treturn false;\n\t}\n\n\treturn document.isDirty || document.status.value === 'draft';\n}\n","import * as React from 'react';\nimport { Divider, styled } from '@elementor/ui';\nimport { __privatePopoverMenu as PopoverMenu, PopoverMenuProps } from '@elementor/editor-app-bar-ui';\nimport { documentOptionsMenu } from '../locations';\n\nconst { useMenuItems } = documentOptionsMenu;\n\n// CSS hack to hide dividers for empty menu items, due to a limitation in the locations' mechanism.\nconst StyledPopoverMenu = styled( PopoverMenu )`\n\t& > .MuiPopover-paper > .MuiList-root {\n\t\t& > .MuiDivider-root {\n\t\t\tdisplay: none;\n\t\t}\n\n\t\t& > *:not(.MuiDivider-root):not(:last-of-type) + .MuiDivider-root {\n\t\t\tdisplay: block;\n\t\t}\n\t}\n`;\n\nexport default function PrimaryActionMenu( props: PopoverMenuProps ) {\n\tconst { save: saveActions, default: defaultActions } = useMenuItems();\n\n\treturn (\n\t\t<StyledPopoverMenu\n\t\t\t{ ...props }\n\t\t\tanchorOrigin={ {\n\t\t\t\tvertical: 'bottom',\n\t\t\t\thorizontal: 'right',\n\t\t\t} }\n\t\t\ttransformOrigin={ {\n\t\t\t\tvertical: 'top',\n\t\t\t\thorizontal: 'right',\n\t\t\t} }\n\t\t\tmarginThreshold={ 4 }\n\t\t\tPaperProps={ {\n\t\t\t\tsx: { mt: 0.5 },\n\t\t\t} }\n\t\t>\n\t\t\t{ saveActions.map( ( { MenuItem, id }, index ) => ( [\n\t\t\t\t( index > 0 ) && <Divider key={ `${ id }-divider` } />,\n\t\t\t\t<MenuItem key={ id } />,\n\t\t\t] ) ) }\n\n\t\t\t{ saveActions.length > 0 && defaultActions.length > 0 && <Divider /> }\n\n\t\t\t{ defaultActions.map( ( { MenuItem, id }, index ) => ( [\n\t\t\t\t( index > 0 ) && <Divider key={ `${ id }-divider` } />,\n\t\t\t\t<MenuItem key={ id } />,\n\t\t\t] ) ) }\n\t\t</StyledPopoverMenu>\n\t);\n}\n","import { __ } from '@wordpress/i18n';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\nimport { LinkIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument, __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\n\nexport default function useDocumentCopyAndShareProps(): ActionProps {\n\tconst document = useActiveDocument();\n\tconst { copyAndShare } = useActiveDocumentActions();\n\n\treturn {\n\t\ticon: LinkIcon,\n\t\ttitle: __( 'Copy and Share', 'elementor' ),\n\t\tonClick: copyAndShare,\n\t\tdisabled: ! document ||\n\t\t\tdocument.isSaving ||\n\t\t\tdocument.isSavingDraft ||\n\t\t\t! ( 'publish' === document.status.value ),\n\t\tvisible: document?.permissions?.showCopyAndShare,\n\t};\n}\n","import { __ } from '@wordpress/i18n';\nimport { __privateIsRouteActive as isRouteActive, __privateListenTo as listenTo, routeOpenEvent, v1ReadyEvent } from '@elementor/editor-v1-adapters';\n\ntype ExtendedWindow = Window & {\n\telementor: {\n\t\tgetPanelView: () => {\n\t\t\tgetHeaderView: () => {\n\t\t\t\tsetTitle: ( title: string ) => void;\n\t\t\t}\n\t\t}\n\t}\n}\n\nexport default function syncPanelTitle() {\n\tconst panelTitle = __( 'Elements', 'elementor' );\n\tconst tabTitle = __( 'Widgets', 'elementor' );\n\n\tlistenTo(\n\t\trouteOpenEvent( 'panel/elements' ),\n\t\t() => {\n\t\t\tsetPanelTitle( panelTitle );\n\t\t\tsetTabTitle( tabTitle );\n\t\t}\n\t);\n\n\tlistenTo(\n\t\tv1ReadyEvent(),\n\t\t() => {\n\t\t\tif ( isRouteActive( 'panel/elements' ) ) {\n\t\t\t\tsetPanelTitle( panelTitle );\n\t\t\t\tsetTabTitle( tabTitle );\n\t\t\t}\n\t\t}\n\t);\n}\n\nfunction setPanelTitle( title: string ) {\n\t( window as unknown as ExtendedWindow ).elementor?.getPanelView?.()?.getHeaderView?.()?.setTitle?.( title );\n}\n\nfunction setTabTitle( title: string ) {\n\tconst tab = document.querySelector( '.elementor-component-tab[data-tab=\"categories\"]' );\n\n\tif ( tab ) {\n\t\ttab.textContent = title;\n\t}\n}\n","import syncPanelTitle from './sync/sync-panel-title';\nimport { __privateToolsMenu as toolsMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tsyncPanelTitle();\n\n\ttoolsMenu.registerToggleAction( {\n\t\tid: 'open-elements-panel',\n\t\tpriority: 1,\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { PlusIcon } from '@elementor/icons';\nimport { __ } from '@wordpress/i18n';\nimport { __privateOpenRoute as openRoute, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function useActionProps() {\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/elements' );\n\n\treturn {\n\t\ttitle: __( 'Add Element', 'elementor' ),\n\t\ticon: PlusIcon,\n\t\tonClick: () => {\n\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\tif ( config ) {\n\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\tconfig.names.topBar.widgetPanel,\n\t\t\t\t\t{\n\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations[ 'widget-panel' ],\n\t\t\t\t\t\ttrigger: config.triggers.toggleClick,\n\t\t\t\t\t\telement: config.elements.buttonIcon,\n\t\t\t\t\t},\n\t\t\t\t);\n\t\t\t}\n\n\t\t\topenRoute( 'panel/elements/categories' );\n\t\t},\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateUtilitiesMenu as utilitiesMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tutilitiesMenu.registerAction( {\n\t\tid: 'toggle-finder',\n\t\tpriority: 10, // Before help.\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { SearchIcon } from '@elementor/icons';\nimport { __privateRunCommand as runCommand, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function useActionProps() {\n\tconst { isBlocked } = useRouteStatus( 'finder', {\n\t\tblockOnKitRoutes: false,\n\t\tblockOnPreviewMode: false,\n\t} );\n\n\treturn {\n\t\ttitle: __( 'Finder', 'elementor' ),\n\t\ticon: SearchIcon,\n\t\tonClick: () => {\n\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\tif ( config ) {\n\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\tconfig.names.topBar.finder,\n\t\t\t\t\t{\n\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations.finder,\n\t\t\t\t\t\ttrigger: config.triggers.toggleClick,\n\t\t\t\t\t\telement: config.elements.buttonIcon,\n\t\t\t\t\t},\n\t\t\t\t);\n\t\t\t}\n\n\t\t\trunCommand( 'finder/toggle' );\n\t\t},\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateUtilitiesMenu as utilitiesMenu } from '@elementor/editor-app-bar-ui';\nimport { __ } from '@wordpress/i18n';\nimport { HelpIcon } from '@elementor/icons';\nimport { ExtendedWindow } from '../../types';\n\nexport function init() {\n\tutilitiesMenu.registerLink( {\n\t\tid: 'open-help-center',\n\t\tpriority: 20, // After Finder.\n\t\tuseProps: () => {\n\t\t\treturn {\n\t\t\t\ttitle: __( 'Help', 'elementor' ),\n\t\t\t\thref: 'https://go.elementor.com/editor-top-bar-learn/',\n\t\t\t\ticon: HelpIcon,\n\t\t\t\ttarget: '_blank',\n\t\t\t\tonClick: () => {\n\t\t\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\t\t\tif ( config ) {\n\t\t\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\t\t\tconfig.names.topBar.help,\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations.help,\n\t\t\t\t\t\t\t\ttrigger: config.triggers.click,\n\t\t\t\t\t\t\t\telement: config.elements.buttonIcon,\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t} );\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tmainMenu.registerToggleAction( {\n\t\tid: 'open-history',\n\t\tpriority: 20,\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { HistoryIcon } from '@elementor/icons';\nimport { __ } from '@wordpress/i18n';\nimport { __privateOpenRoute as openRoute, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function useActionProps() {\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/history' );\n\n\treturn {\n\t\ttitle: __( 'History', 'elementor' ),\n\t\ticon: HistoryIcon,\n\t\tonClick: () => {\n\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\tif ( config ) {\n\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\tconfig.names.topBar.history,\n\t\t\t\t\t{\n\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations.elementorLogo,\n\t\t\t\t\t\ttrigger: config.triggers.click,\n\t\t\t\t\t\telement: config.elements.link,\n\t\t\t\t\t},\n\t\t\t\t);\n\t\t\t}\n\n\t\t\topenRoute( 'panel/history/actions' );\n\t\t},\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tmainMenu.registerAction( {\n\t\tid: 'open-keyboard-shortcuts',\n\t\tgroup: 'default',\n\t\tpriority: 40, // After user preferences.\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\nimport { KeyboardIcon } from '@elementor/icons';\nimport { __privateRunCommand as runCommand } from '@elementor/editor-v1-adapters';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function useActionProps(): ActionProps {\n\treturn {\n\t\ticon: KeyboardIcon,\n\t\ttitle: __( 'Keyboard Shortcuts', 'elementor' ),\n\t\tonClick: () => {\n\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\tif ( config ) {\n\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\tconfig.names.topBar.keyboardShortcuts,\n\t\t\t\t\t{\n\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations.elementorLogo,\n\t\t\t\t\t\ttrigger: config.triggers.click,\n\t\t\t\t\t\telement: config.elements.link,\n\t\t\t\t\t},\n\t\t\t\t);\n\t\t\t}\n\n\t\t\trunCommand( 'shortcuts/open' );\n\t\t},\n\t};\n}\n","import { injectIntoTop } from '@elementor/editor';\nimport PortalledPrimaryAction from './components/portalled-primary-action';\nimport { __privateToolsMenu as toolsMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\t// This is portal, so it injected into the top of the editor, but renders inside the site-settings panel.\n\tinjectIntoTop( {\n\t\tid: 'site-settings-primary-action-portal',\n\t\tcomponent: PortalledPrimaryAction,\n\t} );\n\n\ttoolsMenu.registerToggleAction( {\n\t\tid: 'toggle-site-settings',\n\t\tpriority: 2,\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import * as React from 'react';\nimport Portal from './portal';\nimport PrimaryAction from './primary-action';\n\nexport default function PortalledPrimaryAction() {\n\treturn (\n\t\t<Portal>\n\t\t\t<PrimaryAction />\n\t\t</Portal>\n\t);\n}\n","import * as React from 'react';\nimport { Portal as BasePortal, PortalProps } from '@elementor/ui';\nimport { __privateIsRouteActive as isRouteActive, routeCloseEvent, routeOpenEvent, __privateUseListenTo as useListenTo } from '@elementor/editor-v1-adapters';\n\nexport default function Portal( props: Omit<PortalProps, 'container'> ) {\n\tconst containerRef = useListenTo(\n\t\t[\n\t\t\trouteOpenEvent( 'panel/global' ),\n\t\t\trouteCloseEvent( 'panel/global' ),\n\t\t],\n\t\tgetContainerRef\n\t);\n\n\tif ( ! containerRef.current ) {\n\t\treturn null;\n\t}\n\n\treturn (\n\t\t<BasePortal container={ containerRef.current } { ...props } />\n\t);\n}\n\nfunction getContainerRef() {\n\treturn isRouteActive( 'panel/global' )\n\t\t? { current: document.querySelector( '#elementor-panel-inner' ) }\n\t\t: { current: null };\n}\n","import * as React from 'react';\nimport { __useActiveDocument as useActiveDocument, __useActiveDocumentActions as useActiveDocumentActions } from '@elementor/editor-documents';\nimport { Button, CircularProgress, Paper } from '@elementor/ui';\nimport { __ } from '@wordpress/i18n';\n\nexport default function PrimaryAction() {\n\tconst document = useActiveDocument();\n\tconst { save } = useActiveDocumentActions();\n\n\treturn (\n\t\t<Paper sx={ {\n\t\t\tpx: 5,\n\t\t\tpy: 4,\n\t\t\tborderTop: 1,\n\t\t\tborderColor: 'divider',\n\t\t} }>\n\t\t\t<Button\n\t\t\t\tvariant=\"contained\"\n\t\t\t\tdisabled={ ! document || ! document.isDirty }\n\t\t\t\tsize=\"medium\"\n\t\t\t\tsx={ { width: '100%' } }\n\t\t\t\tonClick={ () => document && ! document.isSaving ? save() : null }\n\t\t\t>\n\t\t\t\t{\n\t\t\t\t\tdocument?.isSaving\n\t\t\t\t\t\t? <CircularProgress />\n\t\t\t\t\t\t: __( 'Save Changes', 'elementor' )\n\t\t\t\t}\n\t\t\t</Button>\n\t\t</Paper>\n\t);\n}\n","import { __ } from '@wordpress/i18n';\nimport { __privateRunCommand as runCommand, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { ToggleActionProps } from '@elementor/editor-app-bar-ui';\nimport { AdjustmentsHorizontalIcon } from '@elementor/icons';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function useActionProps(): ToggleActionProps {\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/global', {\n\t\tblockOnKitRoutes: false,\n\t} );\n\n\treturn {\n\t\ttitle: __( 'Site Settings', 'elementor' ),\n\t\ticon: AdjustmentsHorizontalIcon,\n\t\tonClick: () => {\n\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\tif ( config ) {\n\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\tconfig.names.topBar.siteSettings,\n\t\t\t\t\t{\n\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations.siteSettings,\n\t\t\t\t\t\ttrigger: config.triggers.toggleClick,\n\t\t\t\t\t\telement: config.elements.buttonIcon,\n\t\t\t\t\t},\n\t\t\t\t);\n\t\t\t}\n\n\t\t\tif ( isActive ) {\n\t\t\t\trunCommand( 'panel/global/close' );\n\t\t\t} else {\n\t\t\t\trunCommand( 'panel/global/open' );\n\t\t\t}\n\t\t},\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateToolsMenu as toolsMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\ttoolsMenu.registerToggleAction( {\n\t\tid: 'toggle-structure-view',\n\t\tpriority: 3,\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { __privateRunCommand as runCommand, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { StructureIcon } from '@elementor/icons';\nimport { ToggleActionProps } from '@elementor/editor-app-bar-ui';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function useActionProps(): ToggleActionProps {\n\tconst { isActive, isBlocked } = useRouteStatus( 'navigator' );\n\n\treturn {\n\t\ttitle: __( 'Structure', 'elementor' ),\n\t\ticon: StructureIcon,\n\t\tonClick: () => {\n\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\tif ( config ) {\n\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\tconfig.names.topBar.structure,\n\t\t\t\t\t{\n\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations.structure,\n\t\t\t\t\t\ttrigger: config.triggers.toggleClick,\n\t\t\t\t\t\telement: config.elements.buttonIcon,\n\t\t\t\t\t},\n\t\t\t\t);\n\t\t\t}\n\n\t\t\trunCommand( 'navigator/toggle' );\n\t\t},\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport useThemeBuilderActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tmainMenu.registerAction( {\n\t\tid: 'open-theme-builder',\n\t\tuseProps: useThemeBuilderActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { ThemeBuilderIcon } from '@elementor/icons';\nimport { __privateRunCommand as runCommand } from '@elementor/editor-v1-adapters';\nimport { ActionProps } from '@elementor/editor-app-bar-ui';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function useActionProps(): ActionProps {\n\treturn {\n\t\ticon: ThemeBuilderIcon,\n\t\ttitle: __( 'Theme Builder', 'elementor' ),\n\t\tonClick: () => {\n\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\tif ( config ) {\n\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\tconfig.names.topBar.themeBuilder,\n\t\t\t\t\t{\n\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations.elementorLogo,\n\t\t\t\t\t\ttrigger: config.triggers.click,\n\t\t\t\t\t\telement: config.elements.link,\n\t\t\t\t\t},\n\t\t\t\t);\n\t\t\t}\n\n\t\t\trunCommand( 'app/open' );\n\t\t},\n\t};\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport useActionProps from './hooks/use-action-props';\n\nexport function init() {\n\tmainMenu.registerToggleAction( {\n\t\tid: 'open-user-preferences',\n\t\tpriority: 30, // After history.\n\t\tuseProps: useActionProps,\n\t} );\n}\n","import { __ } from '@wordpress/i18n';\nimport { ToggleActionProps } from '@elementor/editor-app-bar-ui';\nimport { ToggleRightIcon } from '@elementor/icons';\nimport { __privateOpenRoute as openRoute, __privateUseRouteStatus as useRouteStatus } from '@elementor/editor-v1-adapters';\nimport { ExtendedWindow } from '../../../types';\n\nexport default function useActionProps(): ToggleActionProps {\n\tconst { isActive, isBlocked } = useRouteStatus( 'panel/editor-preferences' );\n\n\treturn {\n\t\ticon: ToggleRightIcon,\n\t\ttitle: __( 'User Preferences', 'elementor' ),\n\t\tonClick: () => {\n\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\tif ( config ) {\n\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\tconfig.names.topBar.userPreferences,\n\t\t\t\t\t{\n\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations.elementorLogo,\n\t\t\t\t\t\ttrigger: config.triggers.click,\n\t\t\t\t\t\telement: config.elements.link,\n\t\t\t\t\t},\n\t\t\t\t);\n\t\t\t}\n\n\t\t\topenRoute( 'panel/editor-preferences' );\n\t\t},\n\t\tselected: isActive,\n\t\tdisabled: isBlocked,\n\t};\n}\n","import { __privateMainMenu as mainMenu } from '@elementor/editor-app-bar-ui';\nimport { __ } from '@wordpress/i18n';\nimport { WordpressIcon } from '@elementor/icons';\nimport { __useActiveDocument as useActiveDocument } from '@elementor/editor-documents';\nimport { ExtendedWindow } from '../../types';\n\nexport function init() {\n\tmainMenu.registerLink( {\n\t\tid: 'exit-to-wordpress',\n\t\tgroup: 'exits',\n\t\tuseProps: () => {\n\t\t\tconst document = useActiveDocument();\n\t\t\treturn {\n\t\t\t\ttitle: __( 'Exit to WordPress', 'elementor' ),\n\t\t\t\thref: document?.links?.platformEdit,\n\t\t\t\ticon: WordpressIcon,\n\t\t\t\tonClick: () => {\n\t\t\t\t\tconst extendedWindow = window as unknown as ExtendedWindow;\n\t\t\t\t\tconst config = extendedWindow?.elementor?.editorEvents?.config;\n\n\t\t\t\t\tif ( config ) {\n\t\t\t\t\t\textendedWindow.elementor.editorEvents.dispatchEvent(\n\t\t\t\t\t\t\tconfig.names.topBar.exitToWordpress,\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tlocation: config.locations.topBar,\n\t\t\t\t\t\t\t\tsecondaryLocation: config.secondaryLocations.elementorLogo,\n\t\t\t\t\t\t\t\ttrigger: config.triggers.click,\n\t\t\t\t\t\t\t\telement: config.elements.link,\n\t\t\t\t\t\t\t},\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t};\n\t\t},\n\t} );\n}\n","/**\n * All the code in this directory is a temporary solution.\n * The code should be moved to the appropriate packages.\n */\n\nimport { init as initDocumentsIndicator } from './documents-indicator';\nimport { init as initDocumentsPreview } from './documents-preview';\nimport { init as initDocumentsSave } from './documents-save';\nimport { init as initElements } from './elements';\nimport { init as initFinder } from './finder';\nimport { init as initHelp } from './help';\nimport { init as initHistory } from './history';\nimport { init as initKeyboardShortcuts } from './keyboard-shortcuts';\nimport { init as initSiteSettings } from './site-settings';\nimport { init as initStructure } from './structure';\nimport { init as initThemeBuilder } from './theme-builder';\nimport { init as initUserPreferences } from './user-preferences';\nimport { init as initWordpress } from './wordpress';\n\nexport function init() {\n\tinitDocumentsIndicator();\n\tinitDocumentsPreview();\n\tinitDocumentsSave();\n\tinitElements();\n\tinitFinder();\n\tinitHelp();\n\tinitHistory();\n\tinitKeyboardShortcuts();\n\tinitSiteSettings();\n\tinitStructure();\n\tinitThemeBuilder();\n\tinitUserPreferences();\n\tinitWordpress();\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAEA,IAAAA,6BAQO;;;ACVP,+BAAkD;AAE3C,IAAM,0BAAsB,yBAAAC,qBAAY,CAAE,MAAO,CAAE;;;ACF1D,IAAAC,6BAA0C;AAC1C,IAAAC,iBAA8B;;;ACD9B,gCAA+F;AAEhF,SAAR,mBAAoC;AAG1C,gCAAAC,uBAAU,0CAAgB,YAAa,GAAG,MAAM;AAC/C,kCAAAC,oBAAW,2BAA4B;AAAA,EACxC,CAAE;AAC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AAC9B,mBAAiB;AAEjB,EAAAA,OAAe;AAEf,oCAAe;AAAA,IACd,IAAI;AAAA,IACJ,WAAW,2BAAAC;AAAA,EACZ,CAAE;AACH;;;AFEAC,OAAK;","names":["import_editor_app_bar_ui","createMenu","import_editor_app_bar_ui","import_editor","listenTo","openRoute","import_editor_app_bar_ui","import_editor_v1_adapters","useActiveDocument","useHostDocument","document","useRouteStatus","openRoute","BaseTooltip","injectIntoPageIndication","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","import_editor_documents","document","useActiveDocument","runCommand","init","utilitiesMenu","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_documents","document","useActiveDocument","useActiveDocumentActions","import_i18n","import_icons","import_editor_documents","useActiveDocumentActions","import_i18n","import_icons","import_editor_documents","import_editor_v1_adapters","document","useActiveDocument","runCommand","React","import_i18n","React","import_ui","import_editor_app_bar_ui","PopoverMenu","import_ui","import_editor_documents","import_icons","import_editor_v1_adapters","document","useActiveDocument","useActiveDocumentActions","useIsPreviewMode","import_i18n","import_icons","import_editor_documents","document","useActiveDocument","useActiveDocumentActions","init","injectIntoPrimaryAction","import_i18n","import_editor_v1_adapters","listenTo","isRouteActive","import_editor_app_bar_ui","import_icons","import_i18n","import_editor_v1_adapters","useActionProps","useRouteStatus","openRoute","init","toolsMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","useActionProps","useRouteStatus","runCommand","init","utilitiesMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","init","utilitiesMenu","import_editor_app_bar_ui","import_icons","import_i18n","import_editor_v1_adapters","useActionProps","useRouteStatus","openRoute","init","mainMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","useActionProps","runCommand","init","mainMenu","useActionProps","React","React","import_ui","import_editor_v1_adapters","useListenTo","BasePortal","isRouteActive","React","import_editor_documents","import_ui","import_i18n","PrimaryAction","document","useActiveDocument","useActiveDocumentActions","PrimaryAction","import_editor_app_bar_ui","import_i18n","import_editor_v1_adapters","import_icons","useActionProps","useRouteStatus","runCommand","init","toolsMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_editor_v1_adapters","import_icons","useActionProps","useRouteStatus","runCommand","init","toolsMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","useActionProps","runCommand","init","mainMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_v1_adapters","useActionProps","useRouteStatus","openRoute","init","mainMenu","useActionProps","import_editor_app_bar_ui","import_i18n","import_icons","import_editor_documents","init","mainMenu","document","useActiveDocument","init","init","AppBar","init"]}
|