@elementor/editor-app-bar 3.32.0-33 → 3.32.0-35
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/dist/index.d.mts +3 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.js +168 -109
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +126 -67
- package/dist/index.mjs.map +1 -1
- package/package.json +7 -7
- package/src/components/actions/link.tsx +4 -2
- package/src/components/ui/popover-menu-item.tsx +3 -1
- package/src/extensions/connect/hooks/use-connect-link-config.tsx +60 -0
- package/src/extensions/connect/index.ts +11 -0
- package/src/extensions/help/index.ts +1 -0
- package/src/extensions/index.ts +2 -0
- package/src/extensions/wordpress/index.ts +1 -0
- package/src/types.ts +28 -0
package/dist/index.js
CHANGED
|
@@ -31,7 +31,7 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
|
|
|
31
31
|
var index_exports = {};
|
|
32
32
|
__export(index_exports, {
|
|
33
33
|
documentOptionsMenu: () => documentOptionsMenu,
|
|
34
|
-
init: () =>
|
|
34
|
+
init: () => init17,
|
|
35
35
|
injectIntoPageIndication: () => injectIntoPageIndication,
|
|
36
36
|
injectIntoPrimaryAction: () => injectIntoPrimaryAction,
|
|
37
37
|
injectIntoResponsive: () => injectIntoResponsive,
|
|
@@ -76,9 +76,10 @@ function PopoverMenuItem({
|
|
|
76
76
|
target,
|
|
77
77
|
disabled,
|
|
78
78
|
isGroupParent,
|
|
79
|
+
showExternalLinkIcon,
|
|
79
80
|
...props
|
|
80
81
|
}) {
|
|
81
|
-
const isExternalLink = href && target === "_blank";
|
|
82
|
+
const isExternalLink = href && target === "_blank" && showExternalLinkIcon;
|
|
82
83
|
return /* @__PURE__ */ React2.createElement(
|
|
83
84
|
import_ui.MenuItem,
|
|
84
85
|
{
|
|
@@ -152,12 +153,12 @@ function Action({ icon: Icon, title, visible = true, ...props }) {
|
|
|
152
153
|
|
|
153
154
|
// src/components/actions/link.tsx
|
|
154
155
|
var React5 = __toESM(require("react"));
|
|
155
|
-
function Link({ icon: Icon, title, visible = true, ...props }) {
|
|
156
|
+
function Link({ icon: Icon, title, visible = true, showExternalLinkIcon = false, ...props }) {
|
|
156
157
|
const { type } = useMenuContext();
|
|
157
158
|
if (!visible) {
|
|
158
159
|
return null;
|
|
159
160
|
}
|
|
160
|
-
return type === "toolbar" ? /* @__PURE__ */ React5.createElement(ToolbarMenuItem, { title, ...props }, /* @__PURE__ */ React5.createElement(Icon, null)) : /* @__PURE__ */ React5.createElement(PopoverMenuItem, { ...props, text: title, icon: /* @__PURE__ */ React5.createElement(Icon, null) });
|
|
161
|
+
return type === "toolbar" ? /* @__PURE__ */ React5.createElement(ToolbarMenuItem, { title, ...props }, /* @__PURE__ */ React5.createElement(Icon, null)) : /* @__PURE__ */ React5.createElement(PopoverMenuItem, { ...props, text: title, icon: /* @__PURE__ */ React5.createElement(Icon, null), showExternalLinkIcon });
|
|
161
162
|
}
|
|
162
163
|
|
|
163
164
|
// src/components/actions/toggle-action.tsx
|
|
@@ -451,13 +452,68 @@ function AppBar() {
|
|
|
451
452
|
return /* @__PURE__ */ React19.createElement(import_ui11.ThemeProvider, { colorScheme: "dark" }, /* @__PURE__ */ React19.createElement(import_ui11.AppBar, { position: "sticky" }, /* @__PURE__ */ React19.createElement(import_ui11.Toolbar, { disableGutters: true, variant: "dense" }, /* @__PURE__ */ React19.createElement(import_ui11.Box, { display: "grid", gridTemplateColumns: "repeat(3, 1fr)", flexGrow: 1 }, /* @__PURE__ */ React19.createElement(import_ui11.Grid, { container: true, flexWrap: "nowrap" }, /* @__PURE__ */ React19.createElement(MainMenuLocation, null), document2?.permissions?.allowAddingWidgets && /* @__PURE__ */ React19.createElement(ToolsMenuLocation, null)), /* @__PURE__ */ React19.createElement(import_ui11.Grid, { container: true, justifyContent: "center" }, /* @__PURE__ */ React19.createElement(ToolbarMenu, { spacing: 1.5 }, /* @__PURE__ */ React19.createElement(import_ui11.Divider, { orientation: "vertical" }), /* @__PURE__ */ React19.createElement(PageIndicationLocation, null), /* @__PURE__ */ React19.createElement(import_ui11.Divider, { orientation: "vertical" }), /* @__PURE__ */ React19.createElement(ResponsiveLocation, null), /* @__PURE__ */ React19.createElement(import_ui11.Divider, { orientation: "vertical" }))), /* @__PURE__ */ React19.createElement(import_ui11.Grid, { container: true, justifyContent: "flex-end", flexWrap: "nowrap" }, /* @__PURE__ */ React19.createElement(UtilitiesMenuLocation, null), /* @__PURE__ */ React19.createElement(PrimaryActionLocation, null))))));
|
|
452
453
|
}
|
|
453
454
|
|
|
455
|
+
// src/extensions/connect/hooks/use-connect-link-config.tsx
|
|
456
|
+
var import_react4 = require("react");
|
|
457
|
+
var import_icons4 = require("@elementor/icons");
|
|
458
|
+
var import_i18n4 = require("@wordpress/i18n");
|
|
459
|
+
function useConnectLinkConfig() {
|
|
460
|
+
const extendedWindow = window;
|
|
461
|
+
let isUserConnected = false;
|
|
462
|
+
const isPro = extendedWindow?.elementor?.helpers.hasPro();
|
|
463
|
+
let target = "_blank";
|
|
464
|
+
if (isPro) {
|
|
465
|
+
isUserConnected = extendedWindow?.elementorPro?.config.isActive ?? false;
|
|
466
|
+
} else {
|
|
467
|
+
isUserConnected = extendedWindow?.elementorCommon?.config.library_connect.is_connected ?? false;
|
|
468
|
+
target = "_self";
|
|
469
|
+
}
|
|
470
|
+
const handleConnectClick = (0, import_react4.useCallback)(
|
|
471
|
+
(event) => {
|
|
472
|
+
event.preventDefault();
|
|
473
|
+
if (extendedWindow.jQuery && extendedWindow.jQuery.fn?.elementorConnect) {
|
|
474
|
+
const connectUrl = extendedWindow?.elementor?.config.user.top_bar.connect_url;
|
|
475
|
+
const $tempButton = extendedWindow.jQuery("<a>");
|
|
476
|
+
$tempButton?.attr("href", connectUrl)?.attr("target", "_blank")?.attr("rel", "opener")?.css("display", "none")?.appendTo("body");
|
|
477
|
+
$tempButton.elementorConnect();
|
|
478
|
+
$tempButton[0].click();
|
|
479
|
+
setTimeout(() => {
|
|
480
|
+
$tempButton.remove();
|
|
481
|
+
}, 1e3);
|
|
482
|
+
}
|
|
483
|
+
},
|
|
484
|
+
[extendedWindow]
|
|
485
|
+
);
|
|
486
|
+
return isUserConnected ? {
|
|
487
|
+
title: (0, import_i18n4.__)("My Elementor", "elementor"),
|
|
488
|
+
href: extendedWindow?.elementor?.config.user.top_bar.my_elementor_url,
|
|
489
|
+
icon: import_icons4.UserIcon,
|
|
490
|
+
target: "_blank"
|
|
491
|
+
} : {
|
|
492
|
+
title: (0, import_i18n4.__)("Connect my account", "elementor"),
|
|
493
|
+
href: extendedWindow?.elementor?.config.user.top_bar.connect_url,
|
|
494
|
+
icon: import_icons4.UserIcon,
|
|
495
|
+
target,
|
|
496
|
+
onClick: handleConnectClick
|
|
497
|
+
};
|
|
498
|
+
}
|
|
499
|
+
|
|
500
|
+
// src/extensions/connect/index.ts
|
|
501
|
+
function init() {
|
|
502
|
+
mainMenu.registerLink({
|
|
503
|
+
id: "app-bar-connect",
|
|
504
|
+
group: "exits",
|
|
505
|
+
priority: 10,
|
|
506
|
+
useProps: useConnectLinkConfig
|
|
507
|
+
});
|
|
508
|
+
}
|
|
509
|
+
|
|
454
510
|
// src/extensions/documents-indicator/components/settings-button.tsx
|
|
455
511
|
var React20 = __toESM(require("react"));
|
|
456
512
|
var import_editor_documents2 = require("@elementor/editor-documents");
|
|
457
513
|
var import_editor_v1_adapters = require("@elementor/editor-v1-adapters");
|
|
458
|
-
var
|
|
514
|
+
var import_icons5 = require("@elementor/icons");
|
|
459
515
|
var import_ui12 = require("@elementor/ui");
|
|
460
|
-
var
|
|
516
|
+
var import_i18n5 = require("@wordpress/i18n");
|
|
461
517
|
function SettingsButton() {
|
|
462
518
|
const activeDocument = (0, import_editor_documents2.__useActiveDocument)();
|
|
463
519
|
const hostDocument = (0, import_editor_documents2.__useHostDocument)();
|
|
@@ -466,7 +522,7 @@ function SettingsButton() {
|
|
|
466
522
|
if (!document2) {
|
|
467
523
|
return null;
|
|
468
524
|
}
|
|
469
|
-
const title = (0,
|
|
525
|
+
const title = (0, import_i18n5.__)("%s Settings", "elementor").replace("%s", document2.type.label);
|
|
470
526
|
return /* @__PURE__ */ React20.createElement(Tooltip3, { title }, /* @__PURE__ */ React20.createElement(import_ui12.Box, { component: "span", "aria-label": void 0 }, /* @__PURE__ */ React20.createElement(
|
|
471
527
|
import_ui12.ToggleButton,
|
|
472
528
|
{
|
|
@@ -500,7 +556,7 @@ function SettingsButton() {
|
|
|
500
556
|
}
|
|
501
557
|
}
|
|
502
558
|
},
|
|
503
|
-
/* @__PURE__ */ React20.createElement(
|
|
559
|
+
/* @__PURE__ */ React20.createElement(import_icons5.SettingsIcon, { fontSize: "small" })
|
|
504
560
|
)));
|
|
505
561
|
}
|
|
506
562
|
function Tooltip3(props) {
|
|
@@ -520,7 +576,7 @@ function Tooltip3(props) {
|
|
|
520
576
|
}
|
|
521
577
|
|
|
522
578
|
// src/extensions/documents-indicator/index.ts
|
|
523
|
-
function
|
|
579
|
+
function init2() {
|
|
524
580
|
injectIntoPageIndication({
|
|
525
581
|
id: "document-settings-button",
|
|
526
582
|
component: SettingsButton,
|
|
@@ -534,13 +590,13 @@ function init() {
|
|
|
534
590
|
// src/extensions/documents-preview/hooks/use-action-props.ts
|
|
535
591
|
var import_editor_documents3 = require("@elementor/editor-documents");
|
|
536
592
|
var import_editor_v1_adapters2 = require("@elementor/editor-v1-adapters");
|
|
537
|
-
var
|
|
538
|
-
var
|
|
593
|
+
var import_icons6 = require("@elementor/icons");
|
|
594
|
+
var import_i18n6 = require("@wordpress/i18n");
|
|
539
595
|
function useActionProps() {
|
|
540
596
|
const document2 = (0, import_editor_documents3.__useActiveDocument)();
|
|
541
597
|
return {
|
|
542
|
-
icon:
|
|
543
|
-
title: (0,
|
|
598
|
+
icon: import_icons6.EyeIcon,
|
|
599
|
+
title: (0, import_i18n6.__)("Preview Changes", "elementor"),
|
|
544
600
|
onClick: () => {
|
|
545
601
|
const extendedWindow = window;
|
|
546
602
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -563,7 +619,7 @@ function useActionProps() {
|
|
|
563
619
|
}
|
|
564
620
|
|
|
565
621
|
// src/extensions/documents-preview/index.ts
|
|
566
|
-
function
|
|
622
|
+
function init3() {
|
|
567
623
|
utilitiesMenu.registerAction({
|
|
568
624
|
id: "document-preview-button",
|
|
569
625
|
priority: 30,
|
|
@@ -576,9 +632,9 @@ function init2() {
|
|
|
576
632
|
var React22 = __toESM(require("react"));
|
|
577
633
|
var import_editor_documents4 = require("@elementor/editor-documents");
|
|
578
634
|
var import_editor_v1_adapters3 = require("@elementor/editor-v1-adapters");
|
|
579
|
-
var
|
|
635
|
+
var import_icons7 = require("@elementor/icons");
|
|
580
636
|
var import_ui14 = require("@elementor/ui");
|
|
581
|
-
var
|
|
637
|
+
var import_i18n7 = require("@wordpress/i18n");
|
|
582
638
|
|
|
583
639
|
// src/extensions/documents-save/components/primary-action-menu.tsx
|
|
584
640
|
var React21 = __toESM(require("react"));
|
|
@@ -677,7 +733,7 @@ function PrimaryAction() {
|
|
|
677
733
|
), /* @__PURE__ */ React22.createElement(
|
|
678
734
|
import_ui14.Tooltip,
|
|
679
735
|
{
|
|
680
|
-
title: (0,
|
|
736
|
+
title: (0, import_i18n7.__)("Save Options", "elementor"),
|
|
681
737
|
PopperProps: {
|
|
682
738
|
sx: {
|
|
683
739
|
"&.MuiTooltip-popper .MuiTooltip-tooltip.MuiTooltip-tooltipPlacementBottom": {
|
|
@@ -694,14 +750,14 @@ function PrimaryAction() {
|
|
|
694
750
|
...(0, import_ui14.bindTrigger)(popupState),
|
|
695
751
|
sx: { px: 0, height: "100%", borderRadius: 0 },
|
|
696
752
|
disabled: isSaveOptionsDisabled,
|
|
697
|
-
"aria-label": (0,
|
|
753
|
+
"aria-label": (0, import_i18n7.__)("Save Options", "elementor")
|
|
698
754
|
},
|
|
699
|
-
/* @__PURE__ */ React22.createElement(
|
|
755
|
+
/* @__PURE__ */ React22.createElement(import_icons7.ChevronDownIcon, null)
|
|
700
756
|
))
|
|
701
757
|
)), /* @__PURE__ */ React22.createElement(PrimaryActionMenu, { ...(0, import_ui14.bindMenu)(popupState), onClick: popupState.close }));
|
|
702
758
|
}
|
|
703
759
|
function getLabel(document2) {
|
|
704
|
-
return document2.userCan.publish ? (0,
|
|
760
|
+
return document2.userCan.publish ? (0, import_i18n7.__)("Publish", "elementor") : (0, import_i18n7.__)("Submit", "elementor");
|
|
705
761
|
}
|
|
706
762
|
function isPublishEnabled(document2) {
|
|
707
763
|
if (document2.type.value === "kit") {
|
|
@@ -712,14 +768,14 @@ function isPublishEnabled(document2) {
|
|
|
712
768
|
|
|
713
769
|
// src/extensions/documents-save/hooks/use-document-copy-and-share-props.ts
|
|
714
770
|
var import_editor_documents5 = require("@elementor/editor-documents");
|
|
715
|
-
var
|
|
716
|
-
var
|
|
771
|
+
var import_icons8 = require("@elementor/icons");
|
|
772
|
+
var import_i18n8 = require("@wordpress/i18n");
|
|
717
773
|
function useDocumentCopyAndShareProps() {
|
|
718
774
|
const document2 = (0, import_editor_documents5.__useActiveDocument)();
|
|
719
775
|
const { copyAndShare } = (0, import_editor_documents5.__useActiveDocumentActions)();
|
|
720
776
|
return {
|
|
721
|
-
icon:
|
|
722
|
-
title: (0,
|
|
777
|
+
icon: import_icons8.LinkIcon,
|
|
778
|
+
title: (0, import_i18n8.__)("Copy and Share", "elementor"),
|
|
723
779
|
onClick: copyAndShare,
|
|
724
780
|
disabled: !document2 || document2.isSaving || document2.isSavingDraft || !("publish" === document2.status.value),
|
|
725
781
|
visible: document2?.permissions?.showCopyAndShare
|
|
@@ -728,14 +784,14 @@ function useDocumentCopyAndShareProps() {
|
|
|
728
784
|
|
|
729
785
|
// src/extensions/documents-save/hooks/use-document-save-draft-props.ts
|
|
730
786
|
var import_editor_documents6 = require("@elementor/editor-documents");
|
|
731
|
-
var
|
|
732
|
-
var
|
|
787
|
+
var import_icons9 = require("@elementor/icons");
|
|
788
|
+
var import_i18n9 = require("@wordpress/i18n");
|
|
733
789
|
function useDocumentSaveDraftProps() {
|
|
734
790
|
const document2 = (0, import_editor_documents6.__useActiveDocument)();
|
|
735
791
|
const { saveDraft } = (0, import_editor_documents6.__useActiveDocumentActions)();
|
|
736
792
|
return {
|
|
737
|
-
icon:
|
|
738
|
-
title: (0,
|
|
793
|
+
icon: import_icons9.FileReportIcon,
|
|
794
|
+
title: (0, import_i18n9.__)("Save Draft", "elementor"),
|
|
739
795
|
onClick: saveDraft,
|
|
740
796
|
disabled: !document2 || document2.isSaving || document2.isSavingDraft || !document2.isDirty
|
|
741
797
|
};
|
|
@@ -743,13 +799,13 @@ function useDocumentSaveDraftProps() {
|
|
|
743
799
|
|
|
744
800
|
// src/extensions/documents-save/hooks/use-document-save-template-props.ts
|
|
745
801
|
var import_editor_documents7 = require("@elementor/editor-documents");
|
|
746
|
-
var
|
|
747
|
-
var
|
|
802
|
+
var import_icons10 = require("@elementor/icons");
|
|
803
|
+
var import_i18n10 = require("@wordpress/i18n");
|
|
748
804
|
function useDocumentSaveTemplateProps() {
|
|
749
805
|
const { saveTemplate } = (0, import_editor_documents7.__useActiveDocumentActions)();
|
|
750
806
|
return {
|
|
751
|
-
icon:
|
|
752
|
-
title: (0,
|
|
807
|
+
icon: import_icons10.FolderIcon,
|
|
808
|
+
title: (0, import_i18n10.__)("Save as Template", "elementor"),
|
|
753
809
|
onClick: saveTemplate
|
|
754
810
|
};
|
|
755
811
|
}
|
|
@@ -757,13 +813,13 @@ function useDocumentSaveTemplateProps() {
|
|
|
757
813
|
// src/extensions/documents-save/hooks/use-document-view-page-props.ts
|
|
758
814
|
var import_editor_documents8 = require("@elementor/editor-documents");
|
|
759
815
|
var import_editor_v1_adapters4 = require("@elementor/editor-v1-adapters");
|
|
760
|
-
var
|
|
761
|
-
var
|
|
816
|
+
var import_icons11 = require("@elementor/icons");
|
|
817
|
+
var import_i18n11 = require("@wordpress/i18n");
|
|
762
818
|
function useDocumentViewPageProps() {
|
|
763
819
|
const document2 = (0, import_editor_documents8.__useActiveDocument)();
|
|
764
820
|
return {
|
|
765
|
-
icon:
|
|
766
|
-
title: (0,
|
|
821
|
+
icon: import_icons11.EyeIcon,
|
|
822
|
+
title: (0, import_i18n11.__)("View Page", "elementor"),
|
|
767
823
|
onClick: () => document2?.id && (0, import_editor_v1_adapters4.__privateRunCommand)("editor/documents/view", {
|
|
768
824
|
id: document2.id
|
|
769
825
|
})
|
|
@@ -771,7 +827,7 @@ function useDocumentViewPageProps() {
|
|
|
771
827
|
}
|
|
772
828
|
|
|
773
829
|
// src/extensions/documents-save/index.ts
|
|
774
|
-
function
|
|
830
|
+
function init4() {
|
|
775
831
|
injectIntoPrimaryAction({
|
|
776
832
|
id: "document-primary-action",
|
|
777
833
|
component: PrimaryAction
|
|
@@ -802,13 +858,13 @@ function init3() {
|
|
|
802
858
|
|
|
803
859
|
// src/extensions/elements/hooks/use-action-props.ts
|
|
804
860
|
var import_editor_v1_adapters5 = require("@elementor/editor-v1-adapters");
|
|
805
|
-
var
|
|
806
|
-
var
|
|
861
|
+
var import_icons12 = require("@elementor/icons");
|
|
862
|
+
var import_i18n12 = require("@wordpress/i18n");
|
|
807
863
|
function useActionProps2() {
|
|
808
864
|
const { isActive, isBlocked } = (0, import_editor_v1_adapters5.__privateUseRouteStatus)("panel/elements");
|
|
809
865
|
return {
|
|
810
|
-
title: (0,
|
|
811
|
-
icon:
|
|
866
|
+
title: (0, import_i18n12.__)("Add Element", "elementor"),
|
|
867
|
+
icon: import_icons12.PlusIcon,
|
|
812
868
|
onClick: () => {
|
|
813
869
|
const extendedWindow = window;
|
|
814
870
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -829,10 +885,10 @@ function useActionProps2() {
|
|
|
829
885
|
|
|
830
886
|
// src/extensions/elements/sync/sync-panel-title.ts
|
|
831
887
|
var import_editor_v1_adapters6 = require("@elementor/editor-v1-adapters");
|
|
832
|
-
var
|
|
888
|
+
var import_i18n13 = require("@wordpress/i18n");
|
|
833
889
|
function syncPanelTitle() {
|
|
834
|
-
const panelTitle = (0,
|
|
835
|
-
const tabTitle = (0,
|
|
890
|
+
const panelTitle = (0, import_i18n13.__)("Elements", "elementor");
|
|
891
|
+
const tabTitle = (0, import_i18n13.__)("Widgets", "elementor");
|
|
836
892
|
(0, import_editor_v1_adapters6.__privateListenTo)((0, import_editor_v1_adapters6.routeOpenEvent)("panel/elements"), () => {
|
|
837
893
|
setPanelTitle(panelTitle);
|
|
838
894
|
setTabTitle(tabTitle);
|
|
@@ -855,7 +911,7 @@ function setTabTitle(title) {
|
|
|
855
911
|
}
|
|
856
912
|
|
|
857
913
|
// src/extensions/elements/index.ts
|
|
858
|
-
function
|
|
914
|
+
function init5() {
|
|
859
915
|
syncPanelTitle();
|
|
860
916
|
toolsMenu.registerToggleAction({
|
|
861
917
|
id: "open-elements-panel",
|
|
@@ -866,12 +922,12 @@ function init4() {
|
|
|
866
922
|
|
|
867
923
|
// src/extensions/finder/hooks/use-action-props.ts
|
|
868
924
|
var import_editor_v1_adapters7 = require("@elementor/editor-v1-adapters");
|
|
869
|
-
var
|
|
870
|
-
var
|
|
925
|
+
var import_icons13 = require("@elementor/icons");
|
|
926
|
+
var import_i18n14 = require("@wordpress/i18n");
|
|
871
927
|
function useActionProps3() {
|
|
872
928
|
return {
|
|
873
|
-
title: (0,
|
|
874
|
-
icon:
|
|
929
|
+
title: (0, import_i18n14.__)("Finder", "elementor"),
|
|
930
|
+
icon: import_icons13.SearchIcon,
|
|
875
931
|
onClick: () => {
|
|
876
932
|
const extendedWindow = window;
|
|
877
933
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -889,7 +945,7 @@ function useActionProps3() {
|
|
|
889
945
|
}
|
|
890
946
|
|
|
891
947
|
// src/extensions/finder/index.ts
|
|
892
|
-
function
|
|
948
|
+
function init6() {
|
|
893
949
|
utilitiesMenu.registerAction({
|
|
894
950
|
id: "toggle-finder",
|
|
895
951
|
priority: 15,
|
|
@@ -899,19 +955,20 @@ function init5() {
|
|
|
899
955
|
}
|
|
900
956
|
|
|
901
957
|
// src/extensions/help/index.ts
|
|
902
|
-
var
|
|
903
|
-
var
|
|
904
|
-
function
|
|
958
|
+
var import_icons14 = require("@elementor/icons");
|
|
959
|
+
var import_i18n15 = require("@wordpress/i18n");
|
|
960
|
+
function init7() {
|
|
905
961
|
utilitiesMenu.registerLink({
|
|
906
962
|
id: "open-help-center",
|
|
907
963
|
priority: 25,
|
|
908
964
|
// After Finder.
|
|
909
965
|
useProps: () => {
|
|
910
966
|
return {
|
|
911
|
-
title: (0,
|
|
967
|
+
title: (0, import_i18n15.__)("Help", "elementor"),
|
|
912
968
|
href: "https://go.elementor.com/editor-top-bar-learn/",
|
|
913
|
-
icon:
|
|
969
|
+
icon: import_icons14.HelpIcon,
|
|
914
970
|
target: "_blank",
|
|
971
|
+
showExternalLinkIcon: true,
|
|
915
972
|
onClick: () => {
|
|
916
973
|
const extendedWindow = window;
|
|
917
974
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -931,13 +988,13 @@ function init6() {
|
|
|
931
988
|
|
|
932
989
|
// src/extensions/history/hooks/use-action-props.ts
|
|
933
990
|
var import_editor_v1_adapters8 = require("@elementor/editor-v1-adapters");
|
|
934
|
-
var
|
|
935
|
-
var
|
|
991
|
+
var import_icons15 = require("@elementor/icons");
|
|
992
|
+
var import_i18n16 = require("@wordpress/i18n");
|
|
936
993
|
function useActionProps4() {
|
|
937
994
|
const { isActive, isBlocked } = (0, import_editor_v1_adapters8.__privateUseRouteStatus)("panel/history");
|
|
938
995
|
return {
|
|
939
|
-
title: (0,
|
|
940
|
-
icon:
|
|
996
|
+
title: (0, import_i18n16.__)("History", "elementor"),
|
|
997
|
+
icon: import_icons15.HistoryIcon,
|
|
941
998
|
onClick: () => {
|
|
942
999
|
const extendedWindow = window;
|
|
943
1000
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -957,7 +1014,7 @@ function useActionProps4() {
|
|
|
957
1014
|
}
|
|
958
1015
|
|
|
959
1016
|
// src/extensions/history/index.ts
|
|
960
|
-
function
|
|
1017
|
+
function init8() {
|
|
961
1018
|
mainMenu.registerToggleAction({
|
|
962
1019
|
id: "open-history",
|
|
963
1020
|
priority: 20,
|
|
@@ -967,12 +1024,12 @@ function init7() {
|
|
|
967
1024
|
|
|
968
1025
|
// src/extensions/keyboard-shortcuts/hooks/use-action-props.ts
|
|
969
1026
|
var import_editor_v1_adapters9 = require("@elementor/editor-v1-adapters");
|
|
970
|
-
var
|
|
971
|
-
var
|
|
1027
|
+
var import_icons16 = require("@elementor/icons");
|
|
1028
|
+
var import_i18n17 = require("@wordpress/i18n");
|
|
972
1029
|
function useActionProps5() {
|
|
973
1030
|
return {
|
|
974
|
-
icon:
|
|
975
|
-
title: (0,
|
|
1031
|
+
icon: import_icons16.KeyboardIcon,
|
|
1032
|
+
title: (0, import_i18n17.__)("Keyboard Shortcuts", "elementor"),
|
|
976
1033
|
onClick: () => {
|
|
977
1034
|
const extendedWindow = window;
|
|
978
1035
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -990,7 +1047,7 @@ function useActionProps5() {
|
|
|
990
1047
|
}
|
|
991
1048
|
|
|
992
1049
|
// src/extensions/keyboard-shortcuts/index.ts
|
|
993
|
-
function
|
|
1050
|
+
function init9() {
|
|
994
1051
|
mainMenu.registerAction({
|
|
995
1052
|
id: "open-keyboard-shortcuts",
|
|
996
1053
|
group: "default",
|
|
@@ -1003,9 +1060,9 @@ function init8() {
|
|
|
1003
1060
|
// src/extensions/responsive/components/breakpoints-switcher.tsx
|
|
1004
1061
|
var React23 = __toESM(require("react"));
|
|
1005
1062
|
var import_editor_responsive = require("@elementor/editor-responsive");
|
|
1006
|
-
var
|
|
1063
|
+
var import_icons17 = require("@elementor/icons");
|
|
1007
1064
|
var import_ui15 = require("@elementor/ui");
|
|
1008
|
-
var
|
|
1065
|
+
var import_i18n18 = require("@wordpress/i18n");
|
|
1009
1066
|
function BreakpointsSwitcher() {
|
|
1010
1067
|
const breakpoints = (0, import_editor_responsive.useBreakpoints)();
|
|
1011
1068
|
const activeBreakpoint = (0, import_editor_responsive.useActiveBreakpoint)();
|
|
@@ -1034,7 +1091,7 @@ function BreakpointsSwitcher() {
|
|
|
1034
1091
|
indicatorColor: "secondary",
|
|
1035
1092
|
value: activeBreakpoint,
|
|
1036
1093
|
onChange,
|
|
1037
|
-
"aria-label": (0,
|
|
1094
|
+
"aria-label": (0, import_i18n18.__)("Switch Device", "elementor"),
|
|
1038
1095
|
sx: {
|
|
1039
1096
|
"& .MuiTabs-indicator": {
|
|
1040
1097
|
backgroundColor: "text.primary"
|
|
@@ -1074,24 +1131,24 @@ function Tooltip5(props) {
|
|
|
1074
1131
|
);
|
|
1075
1132
|
}
|
|
1076
1133
|
var iconsMap = {
|
|
1077
|
-
widescreen:
|
|
1078
|
-
desktop:
|
|
1079
|
-
laptop:
|
|
1080
|
-
tablet_extra:
|
|
1081
|
-
tablet:
|
|
1082
|
-
mobile_extra:
|
|
1083
|
-
mobile:
|
|
1134
|
+
widescreen: import_icons17.WidescreenIcon,
|
|
1135
|
+
desktop: import_icons17.DesktopIcon,
|
|
1136
|
+
laptop: import_icons17.LaptopIcon,
|
|
1137
|
+
tablet_extra: import_icons17.TabletLandscapeIcon,
|
|
1138
|
+
tablet: import_icons17.TabletPortraitIcon,
|
|
1139
|
+
mobile_extra: import_icons17.MobileLandscapeIcon,
|
|
1140
|
+
mobile: import_icons17.MobilePortraitIcon
|
|
1084
1141
|
};
|
|
1085
1142
|
var labelsMap = {
|
|
1086
1143
|
default: "%s",
|
|
1087
1144
|
// translators: %s: Breakpoint label, %d: Breakpoint size.
|
|
1088
|
-
"min-width": (0,
|
|
1145
|
+
"min-width": (0, import_i18n18.__)("%s (%dpx and up)", "elementor"),
|
|
1089
1146
|
// translators: %s: Breakpoint label, %d: Breakpoint size.
|
|
1090
|
-
"max-width": (0,
|
|
1147
|
+
"max-width": (0, import_i18n18.__)("%s (up to %dpx)", "elementor")
|
|
1091
1148
|
};
|
|
1092
1149
|
|
|
1093
1150
|
// src/extensions/responsive/index.ts
|
|
1094
|
-
function
|
|
1151
|
+
function init10() {
|
|
1095
1152
|
injectIntoResponsive({
|
|
1096
1153
|
id: "responsive-breakpoints-switcher",
|
|
1097
1154
|
component: BreakpointsSwitcher,
|
|
@@ -1130,7 +1187,7 @@ function getContainerRef() {
|
|
|
1130
1187
|
var React25 = __toESM(require("react"));
|
|
1131
1188
|
var import_editor_documents9 = require("@elementor/editor-documents");
|
|
1132
1189
|
var import_ui17 = require("@elementor/ui");
|
|
1133
|
-
var
|
|
1190
|
+
var import_i18n19 = require("@wordpress/i18n");
|
|
1134
1191
|
function PrimaryAction2() {
|
|
1135
1192
|
const document2 = (0, import_editor_documents9.__useActiveDocument)();
|
|
1136
1193
|
const { save } = (0, import_editor_documents9.__useActiveDocumentActions)();
|
|
@@ -1153,7 +1210,7 @@ function PrimaryAction2() {
|
|
|
1153
1210
|
sx: { width: "100%" },
|
|
1154
1211
|
onClick: () => document2 && !document2.isSaving ? save() : null
|
|
1155
1212
|
},
|
|
1156
|
-
document2?.isSaving ? /* @__PURE__ */ React25.createElement(import_ui17.CircularProgress, null) : (0,
|
|
1213
|
+
document2?.isSaving ? /* @__PURE__ */ React25.createElement(import_ui17.CircularProgress, null) : (0, import_i18n19.__)("Save Changes", "elementor")
|
|
1157
1214
|
)
|
|
1158
1215
|
);
|
|
1159
1216
|
}
|
|
@@ -1165,15 +1222,15 @@ function PortalledPrimaryAction() {
|
|
|
1165
1222
|
|
|
1166
1223
|
// src/extensions/site-settings/hooks/use-action-props.ts
|
|
1167
1224
|
var import_editor_v1_adapters11 = require("@elementor/editor-v1-adapters");
|
|
1168
|
-
var
|
|
1169
|
-
var
|
|
1225
|
+
var import_icons18 = require("@elementor/icons");
|
|
1226
|
+
var import_i18n20 = require("@wordpress/i18n");
|
|
1170
1227
|
function useActionProps6() {
|
|
1171
1228
|
const { isActive, isBlocked } = (0, import_editor_v1_adapters11.__privateUseRouteStatus)("panel/global", {
|
|
1172
1229
|
blockOnKitRoutes: false
|
|
1173
1230
|
});
|
|
1174
1231
|
return {
|
|
1175
|
-
title: (0,
|
|
1176
|
-
icon:
|
|
1232
|
+
title: (0, import_i18n20.__)("Site Settings", "elementor"),
|
|
1233
|
+
icon: import_icons18.AdjustmentsHorizontalIcon,
|
|
1177
1234
|
onClick: () => {
|
|
1178
1235
|
const extendedWindow = window;
|
|
1179
1236
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -1197,7 +1254,7 @@ function useActionProps6() {
|
|
|
1197
1254
|
}
|
|
1198
1255
|
|
|
1199
1256
|
// src/extensions/site-settings/index.ts
|
|
1200
|
-
function
|
|
1257
|
+
function init11() {
|
|
1201
1258
|
(0, import_editor.injectIntoTop)({
|
|
1202
1259
|
id: "site-settings-primary-action-portal",
|
|
1203
1260
|
component: PortalledPrimaryAction
|
|
@@ -1211,13 +1268,13 @@ function init10() {
|
|
|
1211
1268
|
|
|
1212
1269
|
// src/extensions/structure/hooks/use-action-props.ts
|
|
1213
1270
|
var import_editor_v1_adapters12 = require("@elementor/editor-v1-adapters");
|
|
1214
|
-
var
|
|
1215
|
-
var
|
|
1271
|
+
var import_icons19 = require("@elementor/icons");
|
|
1272
|
+
var import_i18n21 = require("@wordpress/i18n");
|
|
1216
1273
|
function useActionProps7() {
|
|
1217
1274
|
const { isActive, isBlocked } = (0, import_editor_v1_adapters12.__privateUseRouteStatus)("navigator");
|
|
1218
1275
|
return {
|
|
1219
|
-
title: (0,
|
|
1220
|
-
icon:
|
|
1276
|
+
title: (0, import_i18n21.__)("Structure", "elementor"),
|
|
1277
|
+
icon: import_icons19.StructureIcon,
|
|
1221
1278
|
onClick: () => {
|
|
1222
1279
|
const extendedWindow = window;
|
|
1223
1280
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -1237,7 +1294,7 @@ function useActionProps7() {
|
|
|
1237
1294
|
}
|
|
1238
1295
|
|
|
1239
1296
|
// src/extensions/structure/index.ts
|
|
1240
|
-
function
|
|
1297
|
+
function init12() {
|
|
1241
1298
|
toolsMenu.registerToggleAction({
|
|
1242
1299
|
id: "toggle-structure-view",
|
|
1243
1300
|
priority: 3,
|
|
@@ -1247,12 +1304,12 @@ function init11() {
|
|
|
1247
1304
|
|
|
1248
1305
|
// src/extensions/theme-builder/hooks/use-action-props.ts
|
|
1249
1306
|
var import_editor_v1_adapters13 = require("@elementor/editor-v1-adapters");
|
|
1250
|
-
var
|
|
1251
|
-
var
|
|
1307
|
+
var import_icons20 = require("@elementor/icons");
|
|
1308
|
+
var import_i18n22 = require("@wordpress/i18n");
|
|
1252
1309
|
function useActionProps8() {
|
|
1253
1310
|
return {
|
|
1254
|
-
icon:
|
|
1255
|
-
title: (0,
|
|
1311
|
+
icon: import_icons20.ThemeBuilderIcon,
|
|
1312
|
+
title: (0, import_i18n22.__)("Theme Builder", "elementor"),
|
|
1256
1313
|
onClick: () => {
|
|
1257
1314
|
const extendedWindow = window;
|
|
1258
1315
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -1270,7 +1327,7 @@ function useActionProps8() {
|
|
|
1270
1327
|
}
|
|
1271
1328
|
|
|
1272
1329
|
// src/extensions/theme-builder/index.ts
|
|
1273
|
-
function
|
|
1330
|
+
function init13() {
|
|
1274
1331
|
mainMenu.registerAction({
|
|
1275
1332
|
id: "open-theme-builder",
|
|
1276
1333
|
useProps: useActionProps8
|
|
@@ -1279,13 +1336,13 @@ function init12() {
|
|
|
1279
1336
|
|
|
1280
1337
|
// src/extensions/user-preferences/hooks/use-action-props.ts
|
|
1281
1338
|
var import_editor_v1_adapters14 = require("@elementor/editor-v1-adapters");
|
|
1282
|
-
var
|
|
1283
|
-
var
|
|
1339
|
+
var import_icons21 = require("@elementor/icons");
|
|
1340
|
+
var import_i18n23 = require("@wordpress/i18n");
|
|
1284
1341
|
function useActionProps9() {
|
|
1285
1342
|
const { isActive, isBlocked } = (0, import_editor_v1_adapters14.__privateUseRouteStatus)("panel/editor-preferences");
|
|
1286
1343
|
return {
|
|
1287
|
-
icon:
|
|
1288
|
-
title: (0,
|
|
1344
|
+
icon: import_icons21.ToggleRightIcon,
|
|
1345
|
+
title: (0, import_i18n23.__)("User Preferences", "elementor"),
|
|
1289
1346
|
onClick: () => {
|
|
1290
1347
|
const extendedWindow = window;
|
|
1291
1348
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -1305,7 +1362,7 @@ function useActionProps9() {
|
|
|
1305
1362
|
}
|
|
1306
1363
|
|
|
1307
1364
|
// src/extensions/user-preferences/index.ts
|
|
1308
|
-
function
|
|
1365
|
+
function init14() {
|
|
1309
1366
|
mainMenu.registerToggleAction({
|
|
1310
1367
|
id: "open-user-preferences",
|
|
1311
1368
|
priority: 30,
|
|
@@ -1316,18 +1373,19 @@ function init13() {
|
|
|
1316
1373
|
|
|
1317
1374
|
// src/extensions/wordpress/index.ts
|
|
1318
1375
|
var import_editor_documents10 = require("@elementor/editor-documents");
|
|
1319
|
-
var
|
|
1320
|
-
var
|
|
1321
|
-
function
|
|
1376
|
+
var import_icons22 = require("@elementor/icons");
|
|
1377
|
+
var import_i18n24 = require("@wordpress/i18n");
|
|
1378
|
+
function init15() {
|
|
1322
1379
|
mainMenu.registerLink({
|
|
1323
1380
|
id: "exit-to-wordpress",
|
|
1324
1381
|
group: "exits",
|
|
1382
|
+
priority: 20,
|
|
1325
1383
|
useProps: () => {
|
|
1326
1384
|
const document2 = (0, import_editor_documents10.__useActiveDocument)();
|
|
1327
1385
|
return {
|
|
1328
|
-
title: (0,
|
|
1386
|
+
title: (0, import_i18n24.__)("Exit to WordPress", "elementor"),
|
|
1329
1387
|
href: document2?.links?.platformEdit,
|
|
1330
|
-
icon:
|
|
1388
|
+
icon: import_icons22.WordpressIcon,
|
|
1331
1389
|
onClick: () => {
|
|
1332
1390
|
const extendedWindow = window;
|
|
1333
1391
|
const config = extendedWindow?.elementorCommon?.eventsManager?.config;
|
|
@@ -1349,8 +1407,7 @@ function init14() {
|
|
|
1349
1407
|
}
|
|
1350
1408
|
|
|
1351
1409
|
// src/extensions/index.ts
|
|
1352
|
-
function
|
|
1353
|
-
init();
|
|
1410
|
+
function init16() {
|
|
1354
1411
|
init2();
|
|
1355
1412
|
init3();
|
|
1356
1413
|
init4();
|
|
@@ -1364,6 +1421,8 @@ function init15() {
|
|
|
1364
1421
|
init12();
|
|
1365
1422
|
init13();
|
|
1366
1423
|
init14();
|
|
1424
|
+
init15();
|
|
1425
|
+
init();
|
|
1367
1426
|
}
|
|
1368
1427
|
|
|
1369
1428
|
// src/sync/redirect-old-menus.ts
|
|
@@ -1375,9 +1434,9 @@ function redirectOldMenus() {
|
|
|
1375
1434
|
}
|
|
1376
1435
|
|
|
1377
1436
|
// src/init.ts
|
|
1378
|
-
function
|
|
1437
|
+
function init17() {
|
|
1379
1438
|
redirectOldMenus();
|
|
1380
|
-
|
|
1439
|
+
init16();
|
|
1381
1440
|
(0, import_editor2.injectIntoTop)({
|
|
1382
1441
|
id: "app-bar",
|
|
1383
1442
|
component: AppBar
|