@elementor/editor-site-navigation 4.5.0-1229 → 4.5.0-1230

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.js CHANGED
@@ -30,10 +30,31 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
30
30
  // src/index.ts
31
31
  var index_exports = {};
32
32
  __export(index_exports, {
33
+ ContentPanelAddIconButton: () => ContentPanelAddIconButton,
34
+ ContentPanelCoordinatorProvider: () => ContentPanelCoordinatorProvider,
35
+ POPUPS_SITE_CONTENT_SECTION_ID: () => POPUPS_SITE_CONTENT_SECTION_ID,
36
+ POST_PER_PAGE: () => POST_PER_PAGE,
37
+ PopupSectionAddButton: () => PopupSectionAddButton,
38
+ SiteContentCollapsibleList: () => CollapsibleList,
39
+ SiteContentEditModeTemplate: () => EditModeTemplate,
40
+ SiteContentListErrorState: () => ErrorState,
33
41
  SiteContentListItemActionsSlot: () => SiteContentListItemActionsSlot,
42
+ SiteContentPageTitleAndStatus: () => PageTitleAndStatus,
43
+ SiteContentPaginationActions: () => PostListPaginationActions,
44
+ contentPanelListItemButtonSx: () => contentPanelListItemButtonSx,
45
+ contentPanelListRowPaddingSx: () => contentPanelListRowPaddingSx,
46
+ env: () => env,
34
47
  extendIconsMap: () => extendIconsMap,
48
+ getSiteContentHeaderCreateItems: () => getSiteContentHeaderCreateItems,
49
+ getSiteContentSections: () => getSiteContentSections,
35
50
  init: () => init,
36
- injectIntoSiteContentListItemActions: () => injectIntoSiteContentListItemActions
51
+ injectIntoSiteContentListItemActions: () => injectIntoSiteContentListItemActions,
52
+ registerSiteContentHeaderCreateItem: () => registerSiteContentHeaderCreateItem,
53
+ registerSiteContentSection: () => registerSiteContentSection,
54
+ resetSiteContentHeaderCreateItems: () => resetSiteContentHeaderCreateItems,
55
+ resetSiteContentSections: () => resetSiteContentSections,
56
+ useContentPanelCoordinator: () => useContentPanelCoordinator,
57
+ usePostListPagination: () => usePostListPagination
37
58
  });
38
59
  module.exports = __toCommonJS(index_exports);
39
60
 
@@ -63,12 +84,12 @@ var import_editor_sidebar2 = require("@elementor/editor-sidebar");
63
84
  var import_editor_panels2 = require("@elementor/editor-panels");
64
85
 
65
86
  // src/components/panel/shell.tsx
66
- var React36 = __toESM(require("react"));
67
- var import_react12 = require("react");
87
+ var React38 = __toESM(require("react"));
88
+ var import_react14 = require("react");
68
89
  var import_editor_panels = require("@elementor/editor-panels");
69
90
  var import_editor_sidebar = require("@elementor/editor-sidebar");
70
- var import_ui25 = require("@elementor/ui");
71
- var import_i18n26 = require("@wordpress/i18n");
91
+ var import_ui27 = require("@elementor/ui");
92
+ var import_i18n28 = require("@wordpress/i18n");
72
93
 
73
94
  // src/contexts/content-panel-coordinator.tsx
74
95
  var React = __toESM(require("react"));
@@ -421,7 +442,9 @@ function useAccessiblePanelPostTypes() {
421
442
  var CONTENT_PANEL_INSET_SPACING = 2;
422
443
  var CONTENT_PANEL_LIST_ROW_GAP = 0.5;
423
444
  var CONTENT_PANEL_LIST_ROW_INSET_INLINE = 0.75;
424
- var CONTENT_PANEL_LIST_ROW_ACTIVE_SECONDARY_INSET = 10;
445
+ var CONTENT_PANEL_LIST_ROW_ACTIVE_SECONDARY_ACTIONS_COUNT = 2;
446
+ var CONTENT_PANEL_LIST_ROW_ACTIVE_SECONDARY_ACTION_SLOT_WIDTH = 5.5;
447
+ var CONTENT_PANEL_LIST_ROW_ACTIVE_SECONDARY_INSET = CONTENT_PANEL_LIST_ROW_ACTIVE_SECONDARY_ACTIONS_COUNT * CONTENT_PANEL_LIST_ROW_ACTIVE_SECONDARY_ACTION_SLOT_WIDTH;
425
448
  var CONTENT_PANEL_LIST_ROW_TITLE_FONT_SIZE = "0.75rem";
426
449
  var CONTENT_PANEL_LIST_SECTION_BOTTOM_SPACING = 1;
427
450
  var CONTENT_PANEL_SECTION_HEADER_PADDING_BLOCK = 1.25;
@@ -486,10 +509,10 @@ var contentPanelListItemButtonSx = {
486
509
  };
487
510
 
488
511
  // src/components/panel/content-panel-header-add.tsx
489
- var React3 = __toESM(require("react"));
490
- var import_icons3 = require("@elementor/icons");
491
- var import_ui2 = require("@elementor/ui");
492
- var import_i18n4 = require("@wordpress/i18n");
512
+ var React5 = __toESM(require("react"));
513
+ var import_icons4 = require("@elementor/icons");
514
+ var import_ui4 = require("@elementor/ui");
515
+ var import_i18n6 = require("@wordpress/i18n");
493
516
 
494
517
  // src/hooks/use-can-create.ts
495
518
  function useCanCreate(postTypeSlug) {
@@ -498,6 +521,27 @@ function useCanCreate(postTypeSlug) {
498
521
  return !!user?.capabilities?.[capability];
499
522
  }
500
523
 
524
+ // src/popups/constants.ts
525
+ var POPUPS_SITE_CONTENT_SECTION_ID = "popups";
526
+ var POPUP_SITE_CONTENT_UPGRADE_URL = "https://go.elementor.com/go-pro-site-content-popups/";
527
+
528
+ // src/site-content-header-create-items.ts
529
+ var registeredHeaderCreateItems = /* @__PURE__ */ new Map();
530
+ var DEFAULT_HEADER_CREATE_PRIORITY = 0;
531
+ function registerSiteContentHeaderCreateItem(item) {
532
+ registeredHeaderCreateItems.set(item.id, item);
533
+ }
534
+ function getSiteContentHeaderCreateItems() {
535
+ return Array.from(registeredHeaderCreateItems.values()).sort((first, second) => {
536
+ const firstPriority = first.priority ?? DEFAULT_HEADER_CREATE_PRIORITY;
537
+ const secondPriority = second.priority ?? DEFAULT_HEADER_CREATE_PRIORITY;
538
+ return firstPriority - secondPriority;
539
+ });
540
+ }
541
+ function resetSiteContentHeaderCreateItems() {
542
+ registeredHeaderCreateItems.clear();
543
+ }
544
+
501
545
  // src/components/panel/content-panel-add-icon-button.tsx
502
546
  var React2 = __toESM(require("react"));
503
547
  var import_icons2 = require("@elementor/icons");
@@ -507,58 +551,153 @@ function ContentPanelAddIconButton(props) {
507
551
  return /* @__PURE__ */ React2.createElement(import_ui.IconButton, { size: CONTENT_PANEL_ADD_ICON_SIZE, variant: "outlined", ...props }, /* @__PURE__ */ React2.createElement(import_icons2.PlusIcon, { fontSize: CONTENT_PANEL_ADD_ICON_SIZE }));
508
552
  }
509
553
 
554
+ // src/components/panel/popups/popup-header-create-menu-item.tsx
555
+ var React4 = __toESM(require("react"));
556
+ var import_react4 = require("react");
557
+ var import_icons3 = require("@elementor/icons");
558
+ var import_ui3 = require("@elementor/ui");
559
+ var import_i18n5 = require("@wordpress/i18n");
560
+
561
+ // src/components/panel/popups/site-content-popups-promotion-chip.tsx
562
+ var React3 = __toESM(require("react"));
563
+ var import_react3 = require("react");
564
+ var import_editor_controls = require("@elementor/editor-controls");
565
+ var import_editor_ui = require("@elementor/editor-ui");
566
+ var import_ui2 = require("@elementor/ui");
567
+ var import_i18n4 = require("@wordpress/i18n");
568
+ var TRACKING_DATA = {
569
+ target_name: "popups",
570
+ target_location: "widget_panel"
571
+ };
572
+ var SiteContentPopupsPromotionChip = (0, import_react3.forwardRef)((_, ref) => {
573
+ const [isOpen, setIsOpen] = (0, import_react3.useState)(false);
574
+ const upgradeUrl = env.popups?.upgrade_url ?? POPUP_SITE_CONTENT_UPGRADE_URL;
575
+ (0, import_editor_ui.useCanvasClickHandler)(isOpen, () => setIsOpen(false));
576
+ const toggle = (0, import_react3.useCallback)(() => {
577
+ setIsOpen((previous) => {
578
+ if (!previous) {
579
+ (0, import_editor_controls.trackViewPromotion)(TRACKING_DATA);
580
+ }
581
+ return !previous;
582
+ });
583
+ }, []);
584
+ (0, import_react3.useImperativeHandle)(ref, () => ({ toggle }), [toggle]);
585
+ return /* @__PURE__ */ React3.createElement(
586
+ import_editor_ui.PromotionPopover,
587
+ {
588
+ open: isOpen,
589
+ title: (0, import_i18n4.__)("Popups", "elementor"),
590
+ content: (0, import_i18n4.__)("Upgrade to continue creating and editing popups.", "elementor"),
591
+ ctaText: (0, import_i18n4.__)("Upgrade now", "elementor"),
592
+ ctaUrl: upgradeUrl,
593
+ onClose: (event) => {
594
+ event.stopPropagation();
595
+ setIsOpen(false);
596
+ },
597
+ onCtaClick: () => (0, import_editor_controls.trackUpgradePromotionClick)(TRACKING_DATA)
598
+ },
599
+ /* @__PURE__ */ React3.createElement(
600
+ import_ui2.Box,
601
+ {
602
+ onClick: (event) => {
603
+ event.stopPropagation();
604
+ toggle();
605
+ },
606
+ sx: { cursor: "pointer", display: "inline-flex" }
607
+ },
608
+ /* @__PURE__ */ React3.createElement(import_editor_ui.PromotionChip, null)
609
+ )
610
+ );
611
+ });
612
+
613
+ // src/components/panel/popups/popup-header-create-menu-item.tsx
614
+ function PopupHeaderCreateMenuItem({ onSelect }) {
615
+ const promotionRef = (0, import_react4.useRef)(null);
616
+ const canCreate = env.popups?.can_use ?? false;
617
+ const label = (0, import_i18n5.__)("Popup", "elementor");
618
+ const handleClick = () => {
619
+ if (!canCreate) {
620
+ promotionRef.current?.toggle();
621
+ return;
622
+ }
623
+ onSelect();
624
+ };
625
+ return /* @__PURE__ */ React4.createElement(import_ui3.MenuItem, { onClick: handleClick }, /* @__PURE__ */ React4.createElement(import_ui3.ListItemIcon, null, /* @__PURE__ */ React4.createElement(import_icons3.PopupTemplateIcon, { fontSize: "small", color: canCreate ? "action" : "disabled" })), /* @__PURE__ */ React4.createElement(
626
+ import_ui3.ListItemText,
627
+ {
628
+ primary: label,
629
+ primaryTypographyProps: {
630
+ variant: "body2",
631
+ color: canCreate ? "text.primary" : "text.disabled"
632
+ }
633
+ }
634
+ ), !canCreate && /* @__PURE__ */ React4.createElement(import_ui3.Box, { sx: { flexShrink: 0, ml: "auto", pl: 1 } }, /* @__PURE__ */ React4.createElement(SiteContentPopupsPromotionChip, { ref: promotionRef })));
635
+ }
636
+
510
637
  // src/components/panel/content-panel-header-add.tsx
511
638
  var typeIcons = {
512
- page: import_icons3.PageTypeIcon,
513
- post: import_icons3.PostTypeIcon
639
+ page: import_icons4.PageTypeIcon,
640
+ post: import_icons4.PostTypeIcon
514
641
  };
515
642
  function HeaderAddMenuItem({ slug, onSelect }) {
516
643
  const canCreate = useCanCreate(slug);
517
644
  const Icon = typeIcons[slug];
518
645
  const singularName = postTypesMap[slug].labels.singular_name;
519
- return /* @__PURE__ */ React3.createElement(import_ui2.MenuItem, { disabled: !canCreate, onClick: () => onSelect(slug) }, /* @__PURE__ */ React3.createElement(import_ui2.ListItemIcon, null, /* @__PURE__ */ React3.createElement(Icon, { fontSize: "small" })), /* @__PURE__ */ React3.createElement(import_ui2.ListItemText, { primary: singularName, primaryTypographyProps: { variant: "body2" } }));
646
+ return /* @__PURE__ */ React5.createElement(import_ui4.MenuItem, { disabled: !canCreate, onClick: () => onSelect(slug) }, /* @__PURE__ */ React5.createElement(import_ui4.ListItemIcon, null, /* @__PURE__ */ React5.createElement(Icon, { fontSize: "small" })), /* @__PURE__ */ React5.createElement(import_ui4.ListItemText, { primary: singularName, primaryTypographyProps: { variant: "body2" } }));
520
647
  }
521
648
  function ContentPanelHeaderAdd() {
522
649
  const { requestCreate } = useContentPanelCoordinator();
523
650
  const { accessiblePostTypes: accessibleSlugs } = useAccessiblePanelPostTypes();
524
- const popupState = (0, import_ui2.usePopupState)({
651
+ const popupState = (0, import_ui4.usePopupState)({
525
652
  variant: "popover",
526
653
  popupId: "elementor-content-panel-header-add"
527
654
  });
528
- const canAddAny = accessibleSlugs.length > 0;
529
- const buttonProps = (0, import_ui2.bindTrigger)(popupState);
530
- const menuProps = (0, import_ui2.bindMenu)(popupState);
655
+ const headerCreateItems = getSiteContentHeaderCreateItems();
656
+ const canAddAny = true;
657
+ const buttonProps = (0, import_ui4.bindTrigger)(popupState);
658
+ const menuProps = (0, import_ui4.bindMenu)(popupState);
531
659
  const handleSelectType = (slug) => {
532
660
  popupState.close();
533
661
  requestAnimationFrame(() => {
534
662
  requestCreate(slug);
535
663
  });
536
664
  };
537
- return /* @__PURE__ */ React3.createElement(React3.Fragment, null, /* @__PURE__ */ React3.createElement(
665
+ const handleSelectPopup = () => {
666
+ popupState.close();
667
+ requestAnimationFrame(() => {
668
+ requestCreate(POPUPS_SITE_CONTENT_SECTION_ID);
669
+ });
670
+ };
671
+ return /* @__PURE__ */ React5.createElement(React5.Fragment, null, /* @__PURE__ */ React5.createElement(
538
672
  ContentPanelAddIconButton,
539
673
  {
540
- "aria-label": (0, import_i18n4.__)("Add new", "elementor"),
674
+ "aria-label": (0, import_i18n6.__)("Add new", "elementor"),
541
675
  ...buttonProps,
542
676
  disabled: !canAddAny
543
677
  }
544
- ), /* @__PURE__ */ React3.createElement(import_ui2.Menu, { ...menuProps }, accessibleSlugs.map((slug) => /* @__PURE__ */ React3.createElement(HeaderAddMenuItem, { key: slug, onSelect: handleSelectType, slug }))));
678
+ ), /* @__PURE__ */ React5.createElement(import_ui4.Menu, { ...menuProps }, accessibleSlugs.map((slug) => /* @__PURE__ */ React5.createElement(HeaderAddMenuItem, { key: slug, onSelect: handleSelectType, slug })), /* @__PURE__ */ React5.createElement(PopupHeaderCreateMenuItem, { onSelect: handleSelectPopup }), headerCreateItems.map((item) => /* @__PURE__ */ React5.createElement(React5.Fragment, { key: item.id }, item.renderMenuItem(() => {
679
+ popupState.close();
680
+ requestAnimationFrame(() => {
681
+ requestCreate(item.id);
682
+ });
683
+ })))));
545
684
  }
546
685
 
547
686
  // src/components/panel/content-panel-toolbar.tsx
548
- var React11 = __toESM(require("react"));
549
- var import_ui10 = require("@elementor/ui");
687
+ var React13 = __toESM(require("react"));
688
+ var import_ui12 = require("@elementor/ui");
550
689
 
551
690
  // src/components/panel/content-panel-active-filters.tsx
552
- var React5 = __toESM(require("react"));
553
- var import_ui4 = require("@elementor/ui");
554
- var import_i18n5 = require("@wordpress/i18n");
691
+ var React7 = __toESM(require("react"));
692
+ var import_ui6 = require("@elementor/ui");
693
+ var import_i18n7 = require("@wordpress/i18n");
555
694
 
556
695
  // src/components/panel/content-panel-clear-filters-button.tsx
557
- var React4 = __toESM(require("react"));
558
- var import_icons4 = require("@elementor/icons");
559
- var import_ui3 = require("@elementor/ui");
696
+ var React6 = __toESM(require("react"));
697
+ var import_icons5 = require("@elementor/icons");
698
+ var import_ui5 = require("@elementor/ui");
560
699
  function ContentPanelClearFiltersButton({ ariaLabel, onClear, sx, tooltipText }) {
561
- return /* @__PURE__ */ React4.createElement(import_ui3.Tooltip, { disableInteractive: true, placement: "top", title: tooltipText }, /* @__PURE__ */ React4.createElement(import_ui3.Box, null, /* @__PURE__ */ React4.createElement(import_ui3.IconButton, { "aria-label": ariaLabel, onClick: onClear, size: "tiny", sx }, /* @__PURE__ */ React4.createElement(import_icons4.BrushBigIcon, { fontSize: "tiny" }))));
700
+ return /* @__PURE__ */ React6.createElement(import_ui5.Tooltip, { disableInteractive: true, placement: "top", title: tooltipText }, /* @__PURE__ */ React6.createElement(import_ui5.Box, null, /* @__PURE__ */ React6.createElement(import_ui5.IconButton, { "aria-label": ariaLabel, onClick: onClear, size: "tiny", sx }, /* @__PURE__ */ React6.createElement(import_icons5.BrushBigIcon, { fontSize: "tiny" }))));
562
701
  }
563
702
 
564
703
  // src/components/panel/content-panel-active-filters.tsx
@@ -579,16 +718,16 @@ function ContentPanelActiveFilters() {
579
718
  return null;
580
719
  }
581
720
  const activeKeys = getActiveSiteContentStatusFilterKeys(statusFilters);
582
- return /* @__PURE__ */ React5.createElement(import_ui4.Stack, { alignItems: "center", direction: "row", justifyContent: "space-between" }, /* @__PURE__ */ React5.createElement(import_ui4.Stack, { alignItems: "center", direction: "row", flexWrap: "wrap", gap: 0.5 }, hasSort && /* @__PURE__ */ React5.createElement(
583
- import_ui4.Chip,
721
+ return /* @__PURE__ */ React7.createElement(import_ui6.Stack, { alignItems: "center", direction: "row", justifyContent: "space-between" }, /* @__PURE__ */ React7.createElement(import_ui6.Stack, { alignItems: "center", direction: "row", flexWrap: "wrap", gap: 0.5 }, hasSort && /* @__PURE__ */ React7.createElement(
722
+ import_ui6.Chip,
584
723
  {
585
724
  label: getSiteContentSortLabel(siteContentSort),
586
725
  onDelete: () => setSiteContentSort(DEFAULT_SITE_CONTENT_SORT),
587
726
  size: "tiny",
588
727
  sx: contentPanelFilterChipSx
589
728
  }
590
- ), activeKeys.map((key) => /* @__PURE__ */ React5.createElement(
591
- import_ui4.Chip,
729
+ ), activeKeys.map((key) => /* @__PURE__ */ React7.createElement(
730
+ import_ui6.Chip,
592
731
  {
593
732
  key,
594
733
  label: getSiteContentStatusFilterLabel(key),
@@ -596,60 +735,60 @@ function ContentPanelActiveFilters() {
596
735
  size: "tiny",
597
736
  sx: contentPanelFilterChipSx
598
737
  }
599
- ))), /* @__PURE__ */ React5.createElement(
738
+ ))), /* @__PURE__ */ React7.createElement(
600
739
  ContentPanelClearFiltersButton,
601
740
  {
602
- ariaLabel: (0, import_i18n5.__)("Clear Filters", "elementor"),
741
+ ariaLabel: (0, import_i18n7.__)("Clear Filters", "elementor"),
603
742
  onClear: clearActiveToolbarFilters,
604
743
  sx: { margin: "0 0 auto auto" },
605
- tooltipText: (0, import_i18n5.__)("Clear Filters", "elementor")
744
+ tooltipText: (0, import_i18n7.__)("Clear Filters", "elementor")
606
745
  }
607
746
  ));
608
747
  }
609
748
 
610
749
  // src/components/panel/content-panel-search.tsx
611
- var React6 = __toESM(require("react"));
612
- var import_icons5 = require("@elementor/icons");
613
- var import_ui5 = require("@elementor/ui");
614
- var import_i18n6 = require("@wordpress/i18n");
750
+ var React8 = __toESM(require("react"));
751
+ var import_icons6 = require("@elementor/icons");
752
+ var import_ui7 = require("@elementor/ui");
753
+ var import_i18n8 = require("@wordpress/i18n");
615
754
  function ContentPanelSearch() {
616
755
  const { searchQuery, setSearchQuery } = useContentPanelCoordinator();
617
- return /* @__PURE__ */ React6.createElement(import_ui5.Box, { component: "search", "aria-label": (0, import_i18n6.__)("Search site content", "elementor") }, /* @__PURE__ */ React6.createElement(
618
- import_ui5.TextField,
756
+ return /* @__PURE__ */ React8.createElement(import_ui7.Box, { component: "search", "aria-label": (0, import_i18n8.__)("Search site content", "elementor") }, /* @__PURE__ */ React8.createElement(
757
+ import_ui7.TextField,
619
758
  {
620
759
  fullWidth: true,
621
760
  size: "tiny",
622
761
  value: searchQuery,
623
- placeholder: (0, import_i18n6.__)("Search", "elementor"),
762
+ placeholder: (0, import_i18n8.__)("Search", "elementor"),
624
763
  onChange: (event) => setSearchQuery(event.target.value),
625
764
  inputProps: {
626
- "aria-label": (0, import_i18n6.__)("Search", "elementor")
765
+ "aria-label": (0, import_i18n8.__)("Search", "elementor")
627
766
  },
628
767
  InputProps: {
629
- startAdornment: /* @__PURE__ */ React6.createElement(import_ui5.InputAdornment, { position: "start" }, /* @__PURE__ */ React6.createElement(import_icons5.SearchIcon, { fontSize: "tiny" }))
768
+ startAdornment: /* @__PURE__ */ React8.createElement(import_ui7.InputAdornment, { position: "start" }, /* @__PURE__ */ React8.createElement(import_icons6.SearchIcon, { fontSize: "tiny" }))
630
769
  }
631
770
  }
632
771
  ));
633
772
  }
634
773
 
635
774
  // src/components/panel/content-panel-sort.tsx
636
- var React8 = __toESM(require("react"));
637
- var import_editor_ui = require("@elementor/editor-ui");
638
- var import_icons7 = require("@elementor/icons");
639
- var import_ui7 = require("@elementor/ui");
640
- var import_i18n7 = require("@wordpress/i18n");
775
+ var React10 = __toESM(require("react"));
776
+ var import_editor_ui2 = require("@elementor/editor-ui");
777
+ var import_icons8 = require("@elementor/icons");
778
+ var import_ui9 = require("@elementor/ui");
779
+ var import_i18n9 = require("@wordpress/i18n");
641
780
 
642
781
  // src/components/panel/content-panel-sort-list.tsx
643
- var React7 = __toESM(require("react"));
644
- var import_icons6 = require("@elementor/icons");
645
- var import_ui6 = require("@elementor/ui");
646
- var renderSortMenuItemContent = (label, selected) => /* @__PURE__ */ React7.createElement(import_ui6.Stack, { alignItems: "center", direction: "row", gap: 1, width: "100%" }, /* @__PURE__ */ React7.createElement(import_ui6.Typography, { sx: { color: "text.secondary", flex: 1 }, variant: "caption" }, label), selected ? /* @__PURE__ */ React7.createElement(import_icons6.CheckIcon, { "aria-hidden": true, fontSize: "tiny" }) : null);
782
+ var React9 = __toESM(require("react"));
783
+ var import_icons7 = require("@elementor/icons");
784
+ var import_ui8 = require("@elementor/ui");
785
+ var renderSortMenuItemContent = (label, selected) => /* @__PURE__ */ React9.createElement(import_ui8.Stack, { alignItems: "center", direction: "row", gap: 1, width: "100%" }, /* @__PURE__ */ React9.createElement(import_ui8.Typography, { sx: { color: "text.secondary", flex: 1 }, variant: "caption" }, label), selected ? /* @__PURE__ */ React9.createElement(import_icons7.CheckIcon, { "aria-hidden": true, fontSize: "tiny" }) : null);
647
786
  function ContentPanelSortList() {
648
787
  const { setSiteContentSort, siteContentSort } = useContentPanelCoordinator();
649
- return /* @__PURE__ */ React7.createElement(import_ui6.MenuList, { dense: true }, SITE_CONTENT_SORT_OPTIONS.map((option) => {
788
+ return /* @__PURE__ */ React9.createElement(import_ui8.MenuList, { dense: true }, SITE_CONTENT_SORT_OPTIONS.map((option) => {
650
789
  const isSelected = siteContentSort === option;
651
- return /* @__PURE__ */ React7.createElement(
652
- import_ui6.MenuItem,
790
+ return /* @__PURE__ */ React9.createElement(
791
+ import_ui8.MenuItem,
653
792
  {
654
793
  key: option,
655
794
  "aria-checked": isSelected,
@@ -665,23 +804,23 @@ function ContentPanelSortList() {
665
804
  // src/components/panel/content-panel-sort.tsx
666
805
  function ContentPanelSort() {
667
806
  const { clearSiteContentSort, siteContentSort } = useContentPanelCoordinator();
668
- const popupState = (0, import_ui7.usePopupState)({
807
+ const popupState = (0, import_ui9.usePopupState)({
669
808
  variant: "popover",
670
809
  disableAutoFocus: true
671
810
  });
672
811
  const hasActiveSort = hasActiveSiteContentSort(siteContentSort);
673
- return /* @__PURE__ */ React8.createElement(React8.Fragment, null, /* @__PURE__ */ React8.createElement(import_ui7.Tooltip, { placement: "top", title: (0, import_i18n7.__)("Sort", "elementor") }, /* @__PURE__ */ React8.createElement(
674
- import_ui7.ToggleButton,
812
+ return /* @__PURE__ */ React10.createElement(React10.Fragment, null, /* @__PURE__ */ React10.createElement(import_ui9.Tooltip, { placement: "top", title: (0, import_i18n9.__)("Sort", "elementor") }, /* @__PURE__ */ React10.createElement(
813
+ import_ui9.ToggleButton,
675
814
  {
676
- "aria-label": (0, import_i18n7.__)("Sort", "elementor"),
815
+ "aria-label": (0, import_i18n9.__)("Sort", "elementor"),
677
816
  selected: popupState.isOpen || hasActiveSort,
678
817
  size: "tiny",
679
818
  value: "sort",
680
- ...(0, import_ui7.bindToggle)(popupState)
819
+ ...(0, import_ui9.bindToggle)(popupState)
681
820
  },
682
- /* @__PURE__ */ React8.createElement(import_icons7.ArrowsSortIcon, { fontSize: "tiny" })
683
- )), /* @__PURE__ */ React8.createElement(
684
- import_ui7.Popover,
821
+ /* @__PURE__ */ React10.createElement(import_icons8.ArrowsSortIcon, { fontSize: "tiny" })
822
+ )), /* @__PURE__ */ React10.createElement(
823
+ import_ui9.Popover,
685
824
  {
686
825
  anchorOrigin: {
687
826
  horizontal: "right",
@@ -694,43 +833,43 @@ function ContentPanelSort() {
694
833
  horizontal: -21,
695
834
  vertical: "top"
696
835
  },
697
- ...(0, import_ui7.bindPopover)(popupState)
836
+ ...(0, import_ui9.bindPopover)(popupState)
698
837
  },
699
- /* @__PURE__ */ React8.createElement(
700
- import_editor_ui.PopoverHeader,
838
+ /* @__PURE__ */ React10.createElement(
839
+ import_editor_ui2.PopoverHeader,
701
840
  {
702
841
  actions: hasActiveSort ? [
703
- /* @__PURE__ */ React8.createElement(
842
+ /* @__PURE__ */ React10.createElement(
704
843
  ContentPanelClearFiltersButton,
705
844
  {
706
- ariaLabel: (0, import_i18n7.__)("Clear sort", "elementor"),
845
+ ariaLabel: (0, import_i18n9.__)("Clear sort", "elementor"),
707
846
  key: "clear-sort",
708
847
  onClear: clearSiteContentSort,
709
- tooltipText: (0, import_i18n7.__)("Clear sort", "elementor")
848
+ tooltipText: (0, import_i18n9.__)("Clear sort", "elementor")
710
849
  }
711
850
  )
712
851
  ] : [],
713
- icon: /* @__PURE__ */ React8.createElement(import_icons7.ArrowsSortIcon, { fontSize: "tiny" }),
852
+ icon: /* @__PURE__ */ React10.createElement(import_icons8.ArrowsSortIcon, { fontSize: "tiny" }),
714
853
  onClose: popupState.close,
715
- title: (0, import_i18n7.__)("Sort", "elementor")
854
+ title: (0, import_i18n9.__)("Sort", "elementor")
716
855
  }
717
856
  ),
718
- /* @__PURE__ */ React8.createElement(import_ui7.Divider, { sx: { borderWidth: "1px 0 0 0" } }),
719
- /* @__PURE__ */ React8.createElement(import_editor_ui.PopoverBody, { height: "auto", width: SITE_CONTENT_SORT_POPOVER_WIDTH_PX }, /* @__PURE__ */ React8.createElement(ContentPanelSortList, null))
857
+ /* @__PURE__ */ React10.createElement(import_ui9.Divider, { sx: { borderWidth: "1px 0 0 0" } }),
858
+ /* @__PURE__ */ React10.createElement(import_editor_ui2.PopoverBody, { height: "auto", width: SITE_CONTENT_SORT_POPOVER_WIDTH_PX }, /* @__PURE__ */ React10.createElement(ContentPanelSortList, null))
720
859
  ));
721
860
  }
722
861
 
723
862
  // src/components/panel/content-panel-status-filter.tsx
724
- var React10 = __toESM(require("react"));
725
- var import_editor_ui2 = require("@elementor/editor-ui");
726
- var import_icons9 = require("@elementor/icons");
727
- var import_ui9 = require("@elementor/ui");
728
- var import_i18n8 = require("@wordpress/i18n");
863
+ var React12 = __toESM(require("react"));
864
+ var import_editor_ui3 = require("@elementor/editor-ui");
865
+ var import_icons10 = require("@elementor/icons");
866
+ var import_ui11 = require("@elementor/ui");
867
+ var import_i18n10 = require("@wordpress/i18n");
729
868
 
730
869
  // src/components/panel/content-panel-status-filter-list.tsx
731
- var React9 = __toESM(require("react"));
732
- var import_icons8 = require("@elementor/icons");
733
- var import_ui8 = require("@elementor/ui");
870
+ var React11 = __toESM(require("react"));
871
+ var import_icons9 = require("@elementor/icons");
872
+ var import_ui10 = require("@elementor/ui");
734
873
 
735
874
  // src/hooks/use-site-content-status-filter-counts.ts
736
875
  var import_query2 = require("@elementor/query");
@@ -772,7 +911,7 @@ function useSiteContentStatusFilterCounts(postTypes, enabled) {
772
911
  }
773
912
 
774
913
  // src/components/panel/content-panel-status-filter-list.tsx
775
- var renderFilterMenuItemContent = (label, selected) => /* @__PURE__ */ React9.createElement(import_ui8.Stack, { alignItems: "center", direction: "row", gap: 1, width: "100%" }, /* @__PURE__ */ React9.createElement(import_ui8.Typography, { sx: { color: "text.secondary", flex: 1 }, variant: "caption" }, label), selected ? /* @__PURE__ */ React9.createElement(import_icons8.CheckIcon, { "aria-hidden": true, fontSize: "tiny" }) : null);
914
+ var renderFilterMenuItemContent = (label, selected) => /* @__PURE__ */ React11.createElement(import_ui10.Stack, { alignItems: "center", direction: "row", gap: 1, width: "100%" }, /* @__PURE__ */ React11.createElement(import_ui10.Typography, { sx: { color: "text.secondary", flex: 1 }, variant: "caption" }, label), selected ? /* @__PURE__ */ React11.createElement(import_icons9.CheckIcon, { "aria-hidden": true, fontSize: "tiny" }) : null);
776
915
  function ContentPanelStatusFilterList({ loadCounts }) {
777
916
  const { clearStatusFilters, statusFilters, toggleStatusFilter } = useContentPanelCoordinator();
778
917
  const { accessiblePostTypes } = useAccessiblePanelPostTypes();
@@ -784,8 +923,8 @@ function ContentPanelStatusFilterList({ loadCounts }) {
784
923
  const visibleFilters = SITE_CONTENT_SELECTABLE_STATUS_FILTERS.filter(
785
924
  (filter) => shouldShowSiteContentStatusFilterRow(statusCounts?.[filter], isLoadingCounts, statusFilters[filter])
786
925
  );
787
- return /* @__PURE__ */ React9.createElement(import_ui8.MenuList, { dense: true }, /* @__PURE__ */ React9.createElement(
788
- import_ui8.MenuItem,
926
+ return /* @__PURE__ */ React11.createElement(import_ui10.MenuList, { dense: true }, /* @__PURE__ */ React11.createElement(
927
+ import_ui10.MenuItem,
789
928
  {
790
929
  "aria-checked": isAllSelected,
791
930
  onClick: clearStatusFilters,
@@ -795,8 +934,8 @@ function ContentPanelStatusFilterList({ loadCounts }) {
795
934
  renderFilterMenuItemContent(SITE_CONTENT_ALL_FILTER_LABEL, isAllSelected)
796
935
  ), visibleFilters.map((filter) => {
797
936
  const isSelected = statusFilters[filter];
798
- return /* @__PURE__ */ React9.createElement(
799
- import_ui8.MenuItem,
937
+ return /* @__PURE__ */ React11.createElement(
938
+ import_ui10.MenuItem,
800
939
  {
801
940
  key: filter,
802
941
  "aria-checked": isSelected,
@@ -812,23 +951,23 @@ function ContentPanelStatusFilterList({ loadCounts }) {
812
951
  // src/components/panel/content-panel-status-filter.tsx
813
952
  function ContentPanelStatusFilter() {
814
953
  const { clearStatusFilters, statusFilters } = useContentPanelCoordinator();
815
- const popupState = (0, import_ui9.usePopupState)({
954
+ const popupState = (0, import_ui11.usePopupState)({
816
955
  variant: "popover",
817
956
  disableAutoFocus: true
818
957
  });
819
958
  const hasActiveFilters = hasActiveSiteContentStatusFilters(statusFilters);
820
- return /* @__PURE__ */ React10.createElement(React10.Fragment, null, /* @__PURE__ */ React10.createElement(import_ui9.Tooltip, { placement: "top", title: (0, import_i18n8.__)("Filters", "elementor") }, /* @__PURE__ */ React10.createElement(
821
- import_ui9.ToggleButton,
959
+ return /* @__PURE__ */ React12.createElement(React12.Fragment, null, /* @__PURE__ */ React12.createElement(import_ui11.Tooltip, { placement: "top", title: (0, import_i18n10.__)("Filters", "elementor") }, /* @__PURE__ */ React12.createElement(
960
+ import_ui11.ToggleButton,
822
961
  {
823
- "aria-label": (0, import_i18n8.__)("Filters", "elementor"),
962
+ "aria-label": (0, import_i18n10.__)("Filters", "elementor"),
824
963
  selected: popupState.isOpen || hasActiveFilters,
825
964
  size: "tiny",
826
965
  value: "filter",
827
- ...(0, import_ui9.bindToggle)(popupState)
966
+ ...(0, import_ui11.bindToggle)(popupState)
828
967
  },
829
- /* @__PURE__ */ React10.createElement(import_icons9.FilterIcon, { fontSize: "tiny" })
830
- )), /* @__PURE__ */ React10.createElement(
831
- import_ui9.Popover,
968
+ /* @__PURE__ */ React12.createElement(import_icons10.FilterIcon, { fontSize: "tiny" })
969
+ )), /* @__PURE__ */ React12.createElement(
970
+ import_ui11.Popover,
832
971
  {
833
972
  anchorOrigin: {
834
973
  horizontal: "right",
@@ -841,43 +980,43 @@ function ContentPanelStatusFilter() {
841
980
  horizontal: -21,
842
981
  vertical: "top"
843
982
  },
844
- ...(0, import_ui9.bindPopover)(popupState)
983
+ ...(0, import_ui11.bindPopover)(popupState)
845
984
  },
846
- /* @__PURE__ */ React10.createElement(
847
- import_editor_ui2.PopoverHeader,
985
+ /* @__PURE__ */ React12.createElement(
986
+ import_editor_ui3.PopoverHeader,
848
987
  {
849
988
  actions: hasActiveFilters ? [
850
- /* @__PURE__ */ React10.createElement(
989
+ /* @__PURE__ */ React12.createElement(
851
990
  ContentPanelClearFiltersButton,
852
991
  {
853
- ariaLabel: (0, import_i18n8.__)("Clear all", "elementor"),
992
+ ariaLabel: (0, import_i18n10.__)("Clear all", "elementor"),
854
993
  key: "clear-all-filters",
855
994
  onClear: clearStatusFilters,
856
- tooltipText: (0, import_i18n8.__)("Clear all", "elementor")
995
+ tooltipText: (0, import_i18n10.__)("Clear all", "elementor")
857
996
  }
858
997
  )
859
998
  ] : [],
860
- icon: /* @__PURE__ */ React10.createElement(import_icons9.FilterIcon, { fontSize: "tiny" }),
999
+ icon: /* @__PURE__ */ React12.createElement(import_icons10.FilterIcon, { fontSize: "tiny" }),
861
1000
  onClose: popupState.close,
862
- title: (0, import_i18n8.__)("Filters", "elementor")
1001
+ title: (0, import_i18n10.__)("Filters", "elementor")
863
1002
  }
864
1003
  ),
865
- /* @__PURE__ */ React10.createElement(import_ui9.Divider, { sx: { borderWidth: "1px 0 0 0" } }),
866
- /* @__PURE__ */ React10.createElement(import_editor_ui2.PopoverBody, { height: "auto", width: SITE_CONTENT_FILTER_POPOVER_WIDTH_PX }, /* @__PURE__ */ React10.createElement(ContentPanelStatusFilterList, { loadCounts: popupState.isOpen }))
1004
+ /* @__PURE__ */ React12.createElement(import_ui11.Divider, { sx: { borderWidth: "1px 0 0 0" } }),
1005
+ /* @__PURE__ */ React12.createElement(import_editor_ui3.PopoverBody, { height: "auto", width: SITE_CONTENT_FILTER_POPOVER_WIDTH_PX }, /* @__PURE__ */ React12.createElement(ContentPanelStatusFilterList, { loadCounts: popupState.isOpen }))
867
1006
  ));
868
1007
  }
869
1008
 
870
1009
  // src/components/panel/content-panel-toolbar.tsx
871
1010
  function ContentPanelToolbar() {
872
- return /* @__PURE__ */ React11.createElement(import_ui10.Box, { sx: contentPanelSearchBoxSx }, /* @__PURE__ */ React11.createElement(import_ui10.Stack, { gap: 0.75, width: "100%" }, /* @__PURE__ */ React11.createElement(import_ui10.Stack, { alignItems: "center", direction: "row", gap: 0.5, width: "100%" }, /* @__PURE__ */ React11.createElement(import_ui10.Box, { sx: { flexGrow: 1, minWidth: 0 } }, /* @__PURE__ */ React11.createElement(ContentPanelSearch, null)), /* @__PURE__ */ React11.createElement(ContentPanelStatusFilter, null), /* @__PURE__ */ React11.createElement(ContentPanelSort, null)), /* @__PURE__ */ React11.createElement(ContentPanelActiveFilters, null)));
1011
+ return /* @__PURE__ */ React13.createElement(import_ui12.Box, { sx: contentPanelSearchBoxSx }, /* @__PURE__ */ React13.createElement(import_ui12.Stack, { gap: 0.75, width: "100%" }, /* @__PURE__ */ React13.createElement(import_ui12.Stack, { alignItems: "center", direction: "row", gap: 0.5, width: "100%" }, /* @__PURE__ */ React13.createElement(import_ui12.Box, { sx: { flexGrow: 1, minWidth: 0 } }, /* @__PURE__ */ React13.createElement(ContentPanelSearch, null)), /* @__PURE__ */ React13.createElement(ContentPanelStatusFilter, null), /* @__PURE__ */ React13.createElement(ContentPanelSort, null)), /* @__PURE__ */ React13.createElement(ContentPanelActiveFilters, null)));
873
1012
  }
874
1013
 
875
1014
  // src/components/panel/error-snackbar.tsx
876
- var React12 = __toESM(require("react"));
877
- var import_ui11 = require("@elementor/ui");
1015
+ var React14 = __toESM(require("react"));
1016
+ var import_ui13 = require("@elementor/ui");
878
1017
  var ErrorSnackbar = ({ open, onClose }) => {
879
- return /* @__PURE__ */ React12.createElement(
880
- import_ui11.Snackbar,
1018
+ return /* @__PURE__ */ React14.createElement(
1019
+ import_ui13.Snackbar,
881
1020
  {
882
1021
  open,
883
1022
  onClose,
@@ -886,8 +1025,8 @@ var ErrorSnackbar = ({ open, onClose }) => {
886
1025
  horizontal: "left"
887
1026
  }
888
1027
  },
889
- /* @__PURE__ */ React12.createElement(import_ui11.Alert, { onClose, severity: "error", sx: { width: "100%" } }, /* @__PURE__ */ React12.createElement(
890
- import_ui11.Typography,
1028
+ /* @__PURE__ */ React14.createElement(import_ui13.Alert, { onClose, severity: "error", sx: { width: "100%" } }, /* @__PURE__ */ React14.createElement(
1029
+ import_ui13.Typography,
891
1030
  {
892
1031
  component: "span",
893
1032
  sx: {
@@ -901,12 +1040,12 @@ var ErrorSnackbar = ({ open, onClose }) => {
901
1040
  var error_snackbar_default = ErrorSnackbar;
902
1041
 
903
1042
  // src/components/panel/shell-panel-body-content.tsx
904
- var React35 = __toESM(require("react"));
905
- var import_ui24 = require("@elementor/ui");
1043
+ var React37 = __toESM(require("react"));
1044
+ var import_ui26 = require("@elementor/ui");
906
1045
 
907
1046
  // src/contexts/post-list-context.tsx
908
- var React13 = __toESM(require("react"));
909
- var import_react3 = require("react");
1047
+ var React15 = __toESM(require("react"));
1048
+ var import_react5 = require("react");
910
1049
  var defaultValues = {
911
1050
  type: "page",
912
1051
  editMode: { mode: "none", details: {} },
@@ -914,17 +1053,17 @@ var defaultValues = {
914
1053
  resetEditMode: () => null,
915
1054
  setError: () => null
916
1055
  };
917
- var PostListContext = (0, import_react3.createContext)(defaultValues);
1056
+ var PostListContext = (0, import_react5.createContext)(defaultValues);
918
1057
  var PostListContextProvider = ({
919
1058
  type,
920
1059
  setError,
921
1060
  children
922
1061
  }) => {
923
- const [editMode, setEditMode] = (0, import_react3.useState)(defaultValues.editMode);
1062
+ const [editMode, setEditMode] = (0, import_react5.useState)(defaultValues.editMode);
924
1063
  const resetEditMode = () => {
925
1064
  setEditMode(defaultValues.editMode);
926
1065
  };
927
- return /* @__PURE__ */ React13.createElement(
1066
+ return /* @__PURE__ */ React15.createElement(
928
1067
  PostListContext.Provider,
929
1068
  {
930
1069
  value: {
@@ -939,18 +1078,33 @@ var PostListContextProvider = ({
939
1078
  );
940
1079
  };
941
1080
  function usePostListContext() {
942
- const context = (0, import_react3.useContext)(PostListContext);
1081
+ const context = (0, import_react5.useContext)(PostListContext);
943
1082
  if (!context) {
944
1083
  throw new Error("The `usePostListContext()` hook must be used within an `<PostListContextProvider />`");
945
1084
  }
946
1085
  return context;
947
1086
  }
948
1087
 
1088
+ // src/site-content-sections.ts
1089
+ var registeredSections = /* @__PURE__ */ new Map();
1090
+ var DEFAULT_SECTION_PRIORITY = 0;
1091
+ function registerSiteContentSection(section) {
1092
+ registeredSections.set(section.id, section);
1093
+ }
1094
+ function getSiteContentSections() {
1095
+ return Array.from(registeredSections.values()).sort(
1096
+ (first, second) => (first.priority ?? DEFAULT_SECTION_PRIORITY) - (second.priority ?? DEFAULT_SECTION_PRIORITY)
1097
+ );
1098
+ }
1099
+ function resetSiteContentSections() {
1100
+ registeredSections.clear();
1101
+ }
1102
+
949
1103
  // src/components/panel/posts-list/posts-collapsible-list.tsx
950
- var React33 = __toESM(require("react"));
951
- var import_react11 = require("react");
952
- var import_ui22 = require("@elementor/ui");
953
- var import_i18n24 = require("@wordpress/i18n");
1104
+ var React35 = __toESM(require("react"));
1105
+ var import_react13 = require("react");
1106
+ var import_ui24 = require("@elementor/ui");
1107
+ var import_i18n26 = require("@wordpress/i18n");
954
1108
 
955
1109
  // src/hooks/use-homepage.ts
956
1110
  var import_query3 = require("@elementor/query");
@@ -980,7 +1134,7 @@ function useHomepage() {
980
1134
  }
981
1135
 
982
1136
  // src/hooks/use-post-list-pagination.ts
983
- var import_react4 = require("react");
1137
+ var import_react6 = require("react");
984
1138
  function usePostListPagination({
985
1139
  fetchNextPage,
986
1140
  hasNextPage,
@@ -989,13 +1143,13 @@ function usePostListPagination({
989
1143
  resetKey,
990
1144
  totalCount
991
1145
  }) {
992
- const [visibleCount, setVisibleCount] = (0, import_react4.useState)(POST_PER_PAGE);
993
- const pendingVisibleTargetRef = (0, import_react4.useRef)(null);
994
- (0, import_react4.useEffect)(() => {
1146
+ const [visibleCount, setVisibleCount] = (0, import_react6.useState)(POST_PER_PAGE);
1147
+ const pendingVisibleTargetRef = (0, import_react6.useRef)(null);
1148
+ (0, import_react6.useEffect)(() => {
995
1149
  setVisibleCount(POST_PER_PAGE);
996
1150
  pendingVisibleTargetRef.current = null;
997
1151
  }, [resetKey]);
998
- (0, import_react4.useEffect)(() => {
1152
+ (0, import_react6.useEffect)(() => {
999
1153
  const target = pendingVisibleTargetRef.current;
1000
1154
  if (target === null) {
1001
1155
  return;
@@ -1012,7 +1166,7 @@ function usePostListPagination({
1012
1166
  }, [isFetchingNextPage, loadedCount]);
1013
1167
  const canShowLess = visibleCount > POST_PER_PAGE;
1014
1168
  const canLoadMore = visibleCount < loadedCount || hasNextPage;
1015
- const handleLoadMore = (0, import_react4.useCallback)(() => {
1169
+ const handleLoadMore = (0, import_react6.useCallback)(() => {
1016
1170
  if (isFetchingNextPage || !canLoadMore) {
1017
1171
  return;
1018
1172
  }
@@ -1030,7 +1184,7 @@ function usePostListPagination({
1030
1184
  setVisibleCount(Math.min(visibleCount + POST_PER_PAGE, loadedCount));
1031
1185
  }
1032
1186
  }, [canLoadMore, fetchNextPage, hasNextPage, isFetchingNextPage, loadedCount, totalCount, visibleCount]);
1033
- const handleShowLess = (0, import_react4.useCallback)(() => {
1187
+ const handleShowLess = (0, import_react6.useCallback)(() => {
1034
1188
  pendingVisibleTargetRef.current = null;
1035
1189
  setVisibleCount(POST_PER_PAGE);
1036
1190
  }, []);
@@ -1099,18 +1253,18 @@ function usePostsBaselineTotal(postTypeSlug, enabled, status = "any") {
1099
1253
  }
1100
1254
 
1101
1255
  // src/components/panel/section-add-button.tsx
1102
- var React14 = __toESM(require("react"));
1103
- var import_i18n9 = require("@wordpress/i18n");
1256
+ var React16 = __toESM(require("react"));
1257
+ var import_i18n11 = require("@wordpress/i18n");
1104
1258
  function SectionAddButton({ onBeforeCreate }) {
1105
1259
  const { type, setEditMode } = usePostListContext();
1106
1260
  const canCreate = useCanCreate(type);
1107
1261
  const singularName = postTypesMap[type].labels.singular_name;
1108
- const ariaLabel = (0, import_i18n9.sprintf)(
1262
+ const ariaLabel = (0, import_i18n11.sprintf)(
1109
1263
  /* translators: %s: Post type singular name (e.g. Page, Post). */
1110
- (0, import_i18n9.__)("New %s", "elementor"),
1264
+ (0, import_i18n11.__)("New %s", "elementor"),
1111
1265
  singularName
1112
1266
  );
1113
- return /* @__PURE__ */ React14.createElement(
1267
+ return /* @__PURE__ */ React16.createElement(
1114
1268
  ContentPanelAddIconButton,
1115
1269
  {
1116
1270
  "aria-label": ariaLabel,
@@ -1125,10 +1279,10 @@ function SectionAddButton({ onBeforeCreate }) {
1125
1279
  }
1126
1280
 
1127
1281
  // src/components/panel/posts-list/collapsible-list.tsx
1128
- var React15 = __toESM(require("react"));
1129
- var import_react5 = require("react");
1130
- var import_editor_ui3 = require("@elementor/editor-ui");
1131
- var import_ui12 = require("@elementor/ui");
1282
+ var React17 = __toESM(require("react"));
1283
+ var import_react7 = require("react");
1284
+ var import_editor_ui4 = require("@elementor/editor-ui");
1285
+ var import_ui14 = require("@elementor/ui");
1132
1286
  var sectionHeaderListItemButtonSx = {
1133
1287
  flexGrow: 1,
1134
1288
  justifyContent: "flex-start",
@@ -1151,14 +1305,14 @@ function CollapsibleList({
1151
1305
  trailingActions,
1152
1306
  children
1153
1307
  }) {
1154
- const id = (0, import_react5.useId)();
1308
+ const id = (0, import_react7.useId)();
1155
1309
  const labelId = `label-${id}`;
1156
1310
  const contentId = `content-${id}`;
1157
1311
  const chipLabel = countChipLabel ?? count.toString();
1158
1312
  const sectionHeaderAriaLabel = getSectionHeaderAriaLabel(title, chipLabel);
1159
1313
  const handleClick = () => onOpenChange(!isOpen);
1160
- return /* @__PURE__ */ React15.createElement(React15.Fragment, null, /* @__PURE__ */ React15.createElement(
1161
- import_ui12.Box,
1314
+ return /* @__PURE__ */ React17.createElement(React17.Fragment, null, /* @__PURE__ */ React17.createElement(
1315
+ import_ui14.Box,
1162
1316
  {
1163
1317
  sx: {
1164
1318
  ...contentPanelSectionHeaderSx,
@@ -1168,8 +1322,8 @@ function CollapsibleList({
1168
1322
  width: "100%"
1169
1323
  }
1170
1324
  },
1171
- /* @__PURE__ */ React15.createElement(
1172
- import_ui12.ListItemButton,
1325
+ /* @__PURE__ */ React17.createElement(
1326
+ import_ui14.ListItemButton,
1173
1327
  {
1174
1328
  ref: headerRef,
1175
1329
  id: labelId,
@@ -1182,8 +1336,8 @@ function CollapsibleList({
1182
1336
  onClick: handleClick,
1183
1337
  sx: sectionHeaderListItemButtonSx
1184
1338
  },
1185
- /* @__PURE__ */ React15.createElement(import_ui12.Stack, { alignItems: "center", direction: "row", flexGrow: 1, gap: 0.5, minWidth: 0, width: "100%" }, /* @__PURE__ */ React15.createElement(import_ui12.Stack, { alignItems: "center", direction: "row", flex: 1, gap: 0.5, minWidth: 0 }, /* @__PURE__ */ React15.createElement(
1186
- import_ui12.ListItemText,
1339
+ /* @__PURE__ */ React17.createElement(import_ui14.Stack, { alignItems: "center", direction: "row", flexGrow: 1, gap: 0.5, minWidth: 0, width: "100%" }, /* @__PURE__ */ React17.createElement(import_ui14.Stack, { alignItems: "center", direction: "row", flex: 1, gap: 0.5, minWidth: 0 }, /* @__PURE__ */ React17.createElement(
1340
+ import_ui14.ListItemText,
1187
1341
  {
1188
1342
  secondary: title,
1189
1343
  secondaryTypographyProps: {
@@ -1193,10 +1347,10 @@ function CollapsibleList({
1193
1347
  },
1194
1348
  sx: { flexGrow: 0, flexShrink: 1, marginInlineEnd: 1 }
1195
1349
  }
1196
- ), /* @__PURE__ */ React15.createElement(import_ui12.Chip, { label: chipLabel, size: "tiny" })), /* @__PURE__ */ React15.createElement(import_editor_ui3.CollapseIcon, { color: "secondary", fontSize: "tiny", open: isOpen, sx: { flexShrink: 0 } }))
1350
+ ), /* @__PURE__ */ React17.createElement(import_ui14.Chip, { label: chipLabel, size: "tiny" })), /* @__PURE__ */ React17.createElement(import_editor_ui4.CollapseIcon, { color: "secondary", fontSize: "tiny", open: isOpen, sx: { flexShrink: 0 } }))
1197
1351
  ),
1198
- trailingActions && /* @__PURE__ */ React15.createElement(
1199
- import_ui12.Stack,
1352
+ trailingActions && /* @__PURE__ */ React17.createElement(
1353
+ import_ui14.Stack,
1200
1354
  {
1201
1355
  alignItems: "center",
1202
1356
  direction: "row",
@@ -1206,17 +1360,17 @@ function CollapsibleList({
1206
1360
  },
1207
1361
  trailingActions
1208
1362
  )
1209
- ), /* @__PURE__ */ React15.createElement(import_ui12.Collapse, { "aria-labelledby": labelId, id: contentId, in: isOpen, timeout: "auto", unmountOnExit: true }, /* @__PURE__ */ React15.createElement(import_ui12.List, { dense: true, disablePadding: true, sx: contentPanelListSectionListSx }, children)), /* @__PURE__ */ React15.createElement(import_ui12.Divider, null));
1363
+ ), /* @__PURE__ */ React17.createElement(import_ui14.Collapse, { "aria-labelledby": labelId, id: contentId, in: isOpen, timeout: "auto", unmountOnExit: true }, /* @__PURE__ */ React17.createElement(import_ui14.List, { dense: true, disablePadding: true, sx: contentPanelListSectionListSx }, children)), /* @__PURE__ */ React17.createElement(import_ui14.Divider, null));
1210
1364
  }
1211
1365
 
1212
1366
  // src/components/panel/posts-list/error-state.tsx
1213
- var React16 = __toESM(require("react"));
1214
- var import_icons10 = require("@elementor/icons");
1215
- var import_ui13 = require("@elementor/ui");
1216
- var import_i18n10 = require("@wordpress/i18n");
1367
+ var React18 = __toESM(require("react"));
1368
+ var import_icons11 = require("@elementor/icons");
1369
+ var import_ui15 = require("@elementor/ui");
1370
+ var import_i18n12 = require("@wordpress/i18n");
1217
1371
  function ErrorState() {
1218
- return /* @__PURE__ */ React16.createElement(
1219
- import_ui13.Box,
1372
+ return /* @__PURE__ */ React18.createElement(
1373
+ import_ui15.Box,
1220
1374
  {
1221
1375
  sx: {
1222
1376
  display: "flex",
@@ -1227,9 +1381,9 @@ function ErrorState() {
1227
1381
  gap: "16px"
1228
1382
  }
1229
1383
  },
1230
- /* @__PURE__ */ React16.createElement(import_icons10.Error404TemplateIcon, null),
1231
- /* @__PURE__ */ React16.createElement(
1232
- import_ui13.Box,
1384
+ /* @__PURE__ */ React18.createElement(import_icons11.Error404TemplateIcon, null),
1385
+ /* @__PURE__ */ React18.createElement(
1386
+ import_ui15.Box,
1233
1387
  {
1234
1388
  sx: {
1235
1389
  display: "flex",
@@ -1239,19 +1393,19 @@ function ErrorState() {
1239
1393
  gap: "8px"
1240
1394
  }
1241
1395
  },
1242
- /* @__PURE__ */ React16.createElement(import_ui13.Typography, { variant: "body1", color: "text.primary" }, (0, import_i18n10.__)("We couldn\u2019t display your pages.", "elementor")),
1243
- /* @__PURE__ */ React16.createElement(import_ui13.Box, null, /* @__PURE__ */ React16.createElement(import_ui13.Typography, { variant: "body2", color: "text.primary", sx: { textAlign: "center" } }, (0, import_i18n10.__)("It\u2019s probably a temporary issue.", "elementor")), /* @__PURE__ */ React16.createElement(import_ui13.Typography, { variant: "body2", color: "text.primary", sx: { textAlign: "center" } }, (0, import_i18n10.__)("If the problem persists,", "elementor"), " ", /* @__PURE__ */ React16.createElement(import_ui13.Link, { target: "_blank", href: "https://go.elementor.com/wp-editor-support-open-ticket/" }, "Notify support")))
1396
+ /* @__PURE__ */ React18.createElement(import_ui15.Typography, { variant: "body1", color: "text.primary" }, (0, import_i18n12.__)("We couldn\u2019t display your pages.", "elementor")),
1397
+ /* @__PURE__ */ React18.createElement(import_ui15.Box, null, /* @__PURE__ */ React18.createElement(import_ui15.Typography, { variant: "body2", color: "text.primary", sx: { textAlign: "center" } }, (0, import_i18n12.__)("It\u2019s probably a temporary issue.", "elementor")), /* @__PURE__ */ React18.createElement(import_ui15.Typography, { variant: "body2", color: "text.primary", sx: { textAlign: "center" } }, (0, import_i18n12.__)("If the problem persists,", "elementor"), " ", /* @__PURE__ */ React18.createElement(import_ui15.Link, { target: "_blank", href: "https://go.elementor.com/wp-editor-support-open-ticket/" }, "Notify support")))
1244
1398
  )
1245
1399
  );
1246
1400
  }
1247
1401
 
1248
1402
  // src/components/panel/posts-list/post-list-item.tsx
1249
- var React31 = __toESM(require("react"));
1403
+ var React33 = __toESM(require("react"));
1250
1404
 
1251
1405
  // src/components/panel/posts-list/list-items/list-item-create.tsx
1252
- var React18 = __toESM(require("react"));
1406
+ var React20 = __toESM(require("react"));
1253
1407
  var import_editor_documents = require("@elementor/editor-documents");
1254
- var import_i18n12 = require("@wordpress/i18n");
1408
+ var import_i18n14 = require("@wordpress/i18n");
1255
1409
 
1256
1410
  // src/hooks/use-posts-actions.ts
1257
1411
  var import_query7 = require("@elementor/query");
@@ -1332,11 +1486,11 @@ function useInvalidatePosts(postTypeSlug) {
1332
1486
  }
1333
1487
 
1334
1488
  // src/components/panel/posts-list/list-items/edit-mode-template.tsx
1335
- var React17 = __toESM(require("react"));
1336
- var import_react6 = require("react");
1337
- var import_icons11 = require("@elementor/icons");
1338
- var import_ui14 = require("@elementor/ui");
1339
- var import_i18n11 = require("@wordpress/i18n");
1489
+ var React19 = __toESM(require("react"));
1490
+ var import_react8 = require("react");
1491
+ var import_icons12 = require("@elementor/icons");
1492
+ var import_ui16 = require("@elementor/ui");
1493
+ var import_i18n13 = require("@wordpress/i18n");
1340
1494
  var EDIT_ROW_FOCUS_BORDER_WIDTH_PX = 2;
1341
1495
  var EDIT_ROW_MIN_HEIGHT_PX = 36;
1342
1496
  var editModeListItemButtonSx = {
@@ -1373,18 +1527,19 @@ var editRowInputSx = {
1373
1527
  padding: 0,
1374
1528
  width: "100%"
1375
1529
  };
1376
- function EditModeTemplate({ postTitle, isLoading, callback }) {
1530
+ function EditModeTemplate({ postTitle, isLoading, callback, onDismiss }) {
1377
1531
  const { resetEditMode } = usePostListContext();
1378
- const [title, setTitle] = (0, import_react6.useState)(postTitle);
1379
- const [touched, setTouched] = (0, import_react6.useState)(false);
1380
- const [inputError, setInputError] = (0, import_react6.useState)(null);
1381
- const closeButton = (0, import_react6.useRef)();
1532
+ const dismissEditMode = onDismiss ?? resetEditMode;
1533
+ const [title, setTitle] = (0, import_react8.useState)(postTitle);
1534
+ const [touched, setTouched] = (0, import_react8.useState)(false);
1535
+ const [inputError, setInputError] = (0, import_react8.useState)(null);
1536
+ const closeButton = (0, import_react8.useRef)();
1382
1537
  const onBlur = (e) => {
1383
1538
  if (closeButton.current === e.relatedTarget) {
1384
1539
  return;
1385
1540
  }
1386
1541
  if (!touched) {
1387
- resetEditMode();
1542
+ dismissEditMode();
1388
1543
  return;
1389
1544
  }
1390
1545
  runCallback();
@@ -1408,32 +1563,32 @@ function EditModeTemplate({ postTitle, isLoading, callback }) {
1408
1563
  }
1409
1564
  const value = e.target.value;
1410
1565
  if (!validateInput(value)) {
1411
- setInputError((0, import_i18n11.__)("Name is required", "elementor"));
1566
+ setInputError((0, import_i18n13.__)("Name is required", "elementor"));
1412
1567
  } else {
1413
1568
  setInputError(null);
1414
1569
  }
1415
1570
  setTitle(value);
1416
1571
  };
1417
- return /* @__PURE__ */ React17.createElement(React17.Fragment, null, /* @__PURE__ */ React17.createElement(
1418
- import_ui14.ListItem,
1572
+ return /* @__PURE__ */ React19.createElement(React19.Fragment, null, /* @__PURE__ */ React19.createElement(
1573
+ import_ui16.ListItem,
1419
1574
  {
1420
1575
  disablePadding: true,
1421
1576
  sx: contentPanelListRowPaddingSx,
1422
- secondaryAction: /* @__PURE__ */ React17.createElement(CloseButton, { isLoading, closeButton })
1577
+ secondaryAction: /* @__PURE__ */ React19.createElement(CloseButton, { isLoading, closeButton, onDismiss: dismissEditMode })
1423
1578
  },
1424
- /* @__PURE__ */ React17.createElement(
1425
- import_ui14.Box,
1579
+ /* @__PURE__ */ React19.createElement(
1580
+ import_ui16.Box,
1426
1581
  {
1427
1582
  component: "form",
1428
1583
  onSubmit: onFormSubmit,
1429
1584
  sx: { ...editModeListItemButtonSx, display: "flex", width: "100%" }
1430
1585
  },
1431
- /* @__PURE__ */ React17.createElement(import_ui14.Box, { sx: editRowIndicatorSx(!!inputError) }, /* @__PURE__ */ React17.createElement(
1432
- import_ui14.Box,
1586
+ /* @__PURE__ */ React19.createElement(import_ui16.Box, { sx: editRowIndicatorSx(!!inputError) }, /* @__PURE__ */ React19.createElement(
1587
+ import_ui16.Box,
1433
1588
  {
1434
1589
  autoFocus: true,
1435
1590
  "aria-invalid": !!inputError,
1436
- "aria-label": (0, import_i18n11.__)("Name", "elementor"),
1591
+ "aria-label": (0, import_i18n13.__)("Name", "elementor"),
1437
1592
  component: "input",
1438
1593
  disabled: isLoading,
1439
1594
  onBlur,
@@ -1444,11 +1599,10 @@ function EditModeTemplate({ postTitle, isLoading, callback }) {
1444
1599
  }
1445
1600
  ))
1446
1601
  )
1447
- ), inputError && /* @__PURE__ */ React17.createElement(import_ui14.ListItem, { disablePadding: true, sx: contentPanelListRowPaddingSx }, /* @__PURE__ */ React17.createElement(import_ui14.ListItemText, { sx: { color: "error.main", ...contentPanelListRowTitleSx } }, inputError)));
1602
+ ), inputError && /* @__PURE__ */ React19.createElement(import_ui16.ListItem, { disablePadding: true, sx: contentPanelListRowPaddingSx }, /* @__PURE__ */ React19.createElement(import_ui16.ListItemText, { sx: { color: "error.main", ...contentPanelListRowTitleSx } }, inputError)));
1448
1603
  }
1449
- function CloseButton({ isLoading, closeButton }) {
1450
- const { resetEditMode } = usePostListContext();
1451
- return /* @__PURE__ */ React17.createElement(import_ui14.IconButton, { size: "tiny", color: "secondary", onClick: resetEditMode, ref: closeButton, disabled: isLoading }, isLoading ? /* @__PURE__ */ React17.createElement(import_ui14.CircularProgress, { size: "1rem" }) : /* @__PURE__ */ React17.createElement(import_icons11.XIcon, { fontSize: "tiny" }));
1604
+ function CloseButton({ isLoading, closeButton, onDismiss }) {
1605
+ return /* @__PURE__ */ React19.createElement(import_ui16.IconButton, { size: "tiny", color: "secondary", onClick: onDismiss, ref: closeButton, disabled: isLoading }, isLoading ? /* @__PURE__ */ React19.createElement(import_ui16.CircularProgress, { size: "1rem" }) : /* @__PURE__ */ React19.createElement(import_icons12.XIcon, { fontSize: "tiny" }));
1452
1606
  }
1453
1607
 
1454
1608
  // src/components/panel/posts-list/list-items/list-item-create.tsx
@@ -1470,12 +1624,12 @@ function ListItemCreate() {
1470
1624
  resetEditMode();
1471
1625
  }
1472
1626
  };
1473
- const newItemLabel = (0, import_i18n12.sprintf)(
1627
+ const newItemLabel = (0, import_i18n14.sprintf)(
1474
1628
  /* translators: %s: Post type singular name (e.g. Page, Post). */
1475
- (0, import_i18n12.__)("New %s", "elementor"),
1629
+ (0, import_i18n14.__)("New %s", "elementor"),
1476
1630
  postTypesMap[type].labels.singular_name
1477
1631
  );
1478
- return /* @__PURE__ */ React18.createElement(
1632
+ return /* @__PURE__ */ React20.createElement(
1479
1633
  EditModeTemplate,
1480
1634
  {
1481
1635
  postTitle: newItemLabel,
@@ -1486,9 +1640,9 @@ function ListItemCreate() {
1486
1640
  }
1487
1641
 
1488
1642
  // src/components/panel/posts-list/list-items/list-item-duplicate.tsx
1489
- var React19 = __toESM(require("react"));
1643
+ var React21 = __toESM(require("react"));
1490
1644
  var import_editor_documents2 = require("@elementor/editor-documents");
1491
- var import_i18n13 = require("@wordpress/i18n");
1645
+ var import_i18n15 = require("@wordpress/i18n");
1492
1646
  function ListItemDuplicate() {
1493
1647
  const { type, editMode, resetEditMode } = usePostListContext();
1494
1648
  const navigateToDocument = (0, import_editor_documents2.__useNavigateToDocument)();
@@ -1510,10 +1664,10 @@ function ListItemDuplicate() {
1510
1664
  resetEditMode();
1511
1665
  }
1512
1666
  };
1513
- return /* @__PURE__ */ React19.createElement(
1667
+ return /* @__PURE__ */ React21.createElement(
1514
1668
  EditModeTemplate,
1515
1669
  {
1516
- postTitle: `${editMode.details.title} ${(0, import_i18n13.__)("copy", "elementor")}`,
1670
+ postTitle: `${editMode.details.title} ${(0, import_i18n15.__)("copy", "elementor")}`,
1517
1671
  isLoading: duplicatePost.isPending,
1518
1672
  callback: duplicatePostCallback
1519
1673
  }
@@ -1521,7 +1675,7 @@ function ListItemDuplicate() {
1521
1675
  }
1522
1676
 
1523
1677
  // src/components/panel/posts-list/list-items/list-item-rename.tsx
1524
- var React20 = __toESM(require("react"));
1678
+ var React22 = __toESM(require("react"));
1525
1679
  var import_editor_documents3 = require("@elementor/editor-documents");
1526
1680
 
1527
1681
  // src/hooks/use-rename-active-document.ts
@@ -1572,24 +1726,24 @@ function ListItemRename({ post }) {
1572
1726
  resetEditMode();
1573
1727
  }
1574
1728
  };
1575
- return /* @__PURE__ */ React20.createElement(EditModeTemplate, { postTitle: title, isLoading: updatePost.isPending, callback: renamePostCallback });
1729
+ return /* @__PURE__ */ React22.createElement(EditModeTemplate, { postTitle: title, isLoading: updatePost.isPending, callback: renamePostCallback });
1576
1730
  }
1577
1731
 
1578
1732
  // src/components/panel/posts-list/list-items/list-item-view.tsx
1579
- var React30 = __toESM(require("react"));
1580
- var import_react10 = require("react");
1733
+ var React32 = __toESM(require("react"));
1734
+ var import_react12 = require("react");
1581
1735
  var import_editor_documents5 = require("@elementor/editor-documents");
1582
- var import_icons19 = require("@elementor/icons");
1583
- var import_ui20 = require("@elementor/ui");
1584
- var import_i18n22 = require("@wordpress/i18n");
1736
+ var import_icons20 = require("@elementor/icons");
1737
+ var import_ui22 = require("@elementor/ui");
1738
+ var import_i18n24 = require("@wordpress/i18n");
1585
1739
 
1586
1740
  // src/components/shared/page-title-and-status.tsx
1587
- var React21 = __toESM(require("react"));
1588
- var import_ui15 = require("@elementor/ui");
1589
- var import_i18n14 = require("@wordpress/i18n");
1741
+ var React23 = __toESM(require("react"));
1742
+ var import_ui17 = require("@elementor/ui");
1743
+ var import_i18n16 = require("@wordpress/i18n");
1590
1744
 
1591
1745
  // src/hooks/use-reverse-html-entities.ts
1592
- var import_react7 = require("react");
1746
+ var import_react9 = require("react");
1593
1747
 
1594
1748
  // src/utils/post-title-plain.ts
1595
1749
  function getPostTitlePlain(renderedTitle) {
@@ -1603,7 +1757,7 @@ function getPostTitlePlain(renderedTitle) {
1603
1757
 
1604
1758
  // src/hooks/use-reverse-html-entities.ts
1605
1759
  function useReverseHtmlEntities(escapedHTML = "") {
1606
- return (0, import_react7.useMemo)(() => getPostTitlePlain(escapedHTML), [escapedHTML]);
1760
+ return (0, import_react9.useMemo)(() => getPostTitlePlain(escapedHTML), [escapedHTML]);
1607
1761
  }
1608
1762
 
1609
1763
  // src/components/shared/page-title-and-status.tsx
@@ -1613,19 +1767,19 @@ function humanizeStatusSlug(status) {
1613
1767
  var statusChipConfig = {
1614
1768
  draft: {
1615
1769
  color: "default",
1616
- label: (0, import_i18n14.__)("Draft", "elementor")
1770
+ label: (0, import_i18n16.__)("Draft", "elementor")
1617
1771
  },
1618
1772
  future: {
1619
1773
  color: "default",
1620
- label: (0, import_i18n14.__)("Scheduled", "elementor")
1774
+ label: (0, import_i18n16.__)("Scheduled", "elementor")
1621
1775
  },
1622
1776
  pending: {
1623
1777
  color: "warning",
1624
- label: (0, import_i18n14.__)("Pending Review", "elementor")
1778
+ label: (0, import_i18n16.__)("Pending Review", "elementor")
1625
1779
  },
1626
1780
  private: {
1627
1781
  color: "default",
1628
- label: (0, import_i18n14.__)("Private", "elementor")
1782
+ label: (0, import_i18n16.__)("Private", "elementor")
1629
1783
  }
1630
1784
  };
1631
1785
  function getStatusChipConfig(status) {
@@ -1647,8 +1801,8 @@ var PageStatus = ({ status }) => {
1647
1801
  }
1648
1802
  const { color, label } = getStatusChipConfig(status);
1649
1803
  const isKnownStatus = isKnownPanelStatus(status);
1650
- return /* @__PURE__ */ React21.createElement(
1651
- import_ui15.Chip,
1804
+ return /* @__PURE__ */ React23.createElement(
1805
+ import_ui17.Chip,
1652
1806
  {
1653
1807
  color,
1654
1808
  component: "span",
@@ -1672,8 +1826,8 @@ var PageStatus = ({ status }) => {
1672
1826
  };
1673
1827
  var PageTitle = ({ title }) => {
1674
1828
  const modifiedTitle = useReverseHtmlEntities(title);
1675
- return /* @__PURE__ */ React21.createElement(
1676
- import_ui15.Typography,
1829
+ return /* @__PURE__ */ React23.createElement(
1830
+ import_ui17.Typography,
1677
1831
  {
1678
1832
  component: "span",
1679
1833
  variant: "body2",
@@ -1681,60 +1835,62 @@ var PageTitle = ({ title }) => {
1681
1835
  noWrap: true,
1682
1836
  sx: {
1683
1837
  ...contentPanelListRowTitleSx,
1684
- flex: 1,
1685
1838
  flexBasis: "auto",
1686
- minWidth: 0
1839
+ flexShrink: 1,
1840
+ minWidth: 0,
1841
+ overflow: "hidden",
1842
+ textOverflow: "ellipsis"
1687
1843
  }
1688
1844
  },
1689
1845
  modifiedTitle
1690
1846
  );
1691
1847
  };
1692
1848
  function PageTitleAndStatus({ title, status }) {
1693
- return /* @__PURE__ */ React21.createElement(import_ui15.Box, { alignItems: "center", display: "flex", minWidth: 0 }, /* @__PURE__ */ React21.createElement(PageTitle, { title }), /* @__PURE__ */ React21.createElement(PageStatus, { status }));
1849
+ return /* @__PURE__ */ React23.createElement(import_ui17.Box, { alignItems: "center", display: "flex", minWidth: 0, sx: { overflow: "hidden" } }, /* @__PURE__ */ React23.createElement(PageTitle, { title }), /* @__PURE__ */ React23.createElement(PageStatus, { status }));
1694
1850
  }
1695
1851
 
1696
1852
  // src/components/panel/actions-menu/actions/delete.tsx
1697
- var React23 = __toESM(require("react"));
1698
- var import_react8 = require("react");
1853
+ var React25 = __toESM(require("react"));
1854
+ var import_react10 = require("react");
1699
1855
  var import_editor_documents4 = require("@elementor/editor-documents");
1700
- var import_icons12 = require("@elementor/icons");
1701
- var import_ui17 = require("@elementor/ui");
1702
- var import_i18n15 = require("@wordpress/i18n");
1856
+ var import_icons13 = require("@elementor/icons");
1857
+ var import_ui19 = require("@elementor/ui");
1858
+ var import_i18n17 = require("@wordpress/i18n");
1703
1859
 
1704
1860
  // src/components/panel/actions-menu/action-menu-item.tsx
1705
- var React22 = __toESM(require("react"));
1706
- var import_ui16 = require("@elementor/ui");
1861
+ var React24 = __toESM(require("react"));
1862
+ var import_ui18 = require("@elementor/ui");
1707
1863
  function ActionMenuItem({ description, icon: Icon, MenuItemProps, title }) {
1708
- return /* @__PURE__ */ React22.createElement(import_ui16.MenuItem, { ...MenuItemProps }, /* @__PURE__ */ React22.createElement(
1709
- import_ui16.ListItemIcon,
1864
+ return /* @__PURE__ */ React24.createElement(import_ui18.MenuItem, { ...MenuItemProps }, /* @__PURE__ */ React24.createElement(
1865
+ import_ui18.ListItemIcon,
1710
1866
  {
1711
1867
  sx: {
1712
1868
  color: "inherit"
1713
1869
  }
1714
1870
  },
1715
- /* @__PURE__ */ React22.createElement(Icon, null)
1716
- ), /* @__PURE__ */ React22.createElement(import_ui16.ListItemText, { primary: title, secondary: description }));
1871
+ /* @__PURE__ */ React24.createElement(Icon, null)
1872
+ ), /* @__PURE__ */ React24.createElement(import_ui18.ListItemText, { primary: title, secondary: description }));
1717
1873
  }
1718
1874
 
1719
1875
  // src/components/panel/actions-menu/actions/delete.tsx
1720
1876
  function Delete({ post }) {
1721
- const [isDialogOpen, setIsDialogOpen] = (0, import_react8.useState)(false);
1877
+ const [isDialogOpen, setIsDialogOpen] = (0, import_react10.useState)(false);
1722
1878
  const activeDocument = (0, import_editor_documents4.__useActiveDocument)();
1723
1879
  const isPostActive = activeDocument?.id === post.id;
1724
1880
  const userCanDelete = post.user_can.delete;
1725
1881
  const isDisabled = !userCanDelete || post.isHome || isPostActive;
1726
- return /* @__PURE__ */ React23.createElement(React23.Fragment, null, /* @__PURE__ */ React23.createElement(
1882
+ return /* @__PURE__ */ React25.createElement(React25.Fragment, null, /* @__PURE__ */ React25.createElement(
1727
1883
  ActionMenuItem,
1728
1884
  {
1729
- title: (0, import_i18n15.__)("Delete", "elementor"),
1730
- icon: import_icons12.TrashIcon,
1885
+ title: (0, import_i18n17.__)("Delete", "elementor"),
1886
+ icon: import_icons13.TrashIcon,
1731
1887
  MenuItemProps: {
1732
1888
  disabled: isDisabled,
1733
1889
  onClick: () => setIsDialogOpen(true),
1734
1890
  sx: { "&:hover": { color: "error.main" } }
1735
1891
  }
1736
1892
  }
1737
- ), isDialogOpen && /* @__PURE__ */ React23.createElement(DeleteDialog, { post, setIsDialogOpen }));
1893
+ ), isDialogOpen && /* @__PURE__ */ React25.createElement(DeleteDialog, { post, setIsDialogOpen }));
1738
1894
  }
1739
1895
  function DeleteDialog({
1740
1896
  post,
@@ -1743,11 +1899,11 @@ function DeleteDialog({
1743
1899
  const { type } = usePostListContext();
1744
1900
  const { deletePost } = usePostActions(type);
1745
1901
  const { setError } = usePostListContext();
1746
- const dialogTitle = (0, import_i18n15.sprintf)((0, import_i18n15.__)('Delete "%s"?', "elementor"), post.title.rendered);
1747
- const dialogBody = type === "post" ? (0, import_i18n15.__)(
1902
+ const dialogTitle = (0, import_i18n17.sprintf)((0, import_i18n17.__)('Delete "%s"?', "elementor"), post.title.rendered);
1903
+ const dialogBody = type === "post" ? (0, import_i18n17.__)(
1748
1904
  "The post and its content will be deleted forever and we won\u2019t be able to recover them.",
1749
1905
  "elementor"
1750
- ) : (0, import_i18n15.__)(
1906
+ ) : (0, import_i18n17.__)(
1751
1907
  "The page and its content will be deleted forever and we won\u2019t be able to recover them.",
1752
1908
  "elementor"
1753
1909
  );
@@ -1765,22 +1921,22 @@ function DeleteDialog({
1765
1921
  }
1766
1922
  setIsDialogOpen(false);
1767
1923
  };
1768
- return /* @__PURE__ */ React23.createElement(import_ui17.Dialog, { open: true, onClose: handleCancel, "aria-labelledby": "delete-dialog" }, /* @__PURE__ */ React23.createElement(import_ui17.DialogTitle, { noWrap: true }, dialogTitle), /* @__PURE__ */ React23.createElement(import_ui17.Divider, null), /* @__PURE__ */ React23.createElement(import_ui17.DialogContent, null, /* @__PURE__ */ React23.createElement(import_ui17.DialogContentText, null, dialogBody)), /* @__PURE__ */ React23.createElement(import_ui17.DialogActions, null, /* @__PURE__ */ React23.createElement(
1769
- import_ui17.Button,
1924
+ return /* @__PURE__ */ React25.createElement(import_ui19.Dialog, { open: true, onClose: handleCancel, "aria-labelledby": "delete-dialog" }, /* @__PURE__ */ React25.createElement(import_ui19.DialogTitle, { noWrap: true }, dialogTitle), /* @__PURE__ */ React25.createElement(import_ui19.Divider, null), /* @__PURE__ */ React25.createElement(import_ui19.DialogContent, null, /* @__PURE__ */ React25.createElement(import_ui19.DialogContentText, null, dialogBody)), /* @__PURE__ */ React25.createElement(import_ui19.DialogActions, null, /* @__PURE__ */ React25.createElement(
1925
+ import_ui19.Button,
1770
1926
  {
1771
1927
  variant: "contained",
1772
1928
  color: "secondary",
1773
1929
  onClick: handleCancel,
1774
1930
  disabled: deletePost.isPending
1775
1931
  },
1776
- (0, import_i18n15.__)("Cancel", "elementor")
1777
- ), /* @__PURE__ */ React23.createElement(import_ui17.Button, { variant: "contained", color: "error", onClick: deletePage, disabled: deletePost.isPending }, !deletePost.isPending ? (0, import_i18n15.__)("Delete", "elementor") : /* @__PURE__ */ React23.createElement(import_ui17.CircularProgress, null))));
1932
+ (0, import_i18n17.__)("Cancel", "elementor")
1933
+ ), /* @__PURE__ */ React25.createElement(import_ui19.Button, { variant: "contained", color: "error", onClick: deletePage, disabled: deletePost.isPending }, !deletePost.isPending ? (0, import_i18n17.__)("Delete", "elementor") : /* @__PURE__ */ React25.createElement(import_ui19.CircularProgress, null))));
1778
1934
  }
1779
1935
 
1780
1936
  // src/components/panel/actions-menu/actions/duplicate.tsx
1781
- var React24 = __toESM(require("react"));
1782
- var import_icons13 = require("@elementor/icons");
1783
- var import_i18n16 = require("@wordpress/i18n");
1937
+ var React26 = __toESM(require("react"));
1938
+ var import_icons14 = require("@elementor/icons");
1939
+ var import_i18n18 = require("@wordpress/i18n");
1784
1940
  function Duplicate({ post, popupState }) {
1785
1941
  const { setEditMode, type } = usePostListContext();
1786
1942
  const canCreate = useCanCreate(type);
@@ -1795,11 +1951,11 @@ function Duplicate({ post, popupState }) {
1795
1951
  });
1796
1952
  };
1797
1953
  const isDisabled = !canCreate;
1798
- return /* @__PURE__ */ React24.createElement(
1954
+ return /* @__PURE__ */ React26.createElement(
1799
1955
  ActionMenuItem,
1800
1956
  {
1801
- title: (0, import_i18n16.__)("Duplicate", "elementor"),
1802
- icon: import_icons13.CopyIcon,
1957
+ title: (0, import_i18n18.__)("Duplicate", "elementor"),
1958
+ icon: import_icons14.CopyIcon,
1803
1959
  MenuItemProps: {
1804
1960
  disabled: isDisabled,
1805
1961
  onClick
@@ -1809,25 +1965,25 @@ function Duplicate({ post, popupState }) {
1809
1965
  }
1810
1966
 
1811
1967
  // src/components/panel/actions-menu/actions/force-delete.tsx
1812
- var React25 = __toESM(require("react"));
1813
- var import_react9 = require("react");
1814
- var import_icons14 = require("@elementor/icons");
1815
- var import_ui18 = require("@elementor/ui");
1816
- var import_i18n17 = require("@wordpress/i18n");
1968
+ var React27 = __toESM(require("react"));
1969
+ var import_react11 = require("react");
1970
+ var import_icons15 = require("@elementor/icons");
1971
+ var import_ui20 = require("@elementor/ui");
1972
+ var import_i18n19 = require("@wordpress/i18n");
1817
1973
  function ForceDelete({ post }) {
1818
- const [isDialogOpen, setIsDialogOpen] = (0, import_react9.useState)(false);
1819
- return /* @__PURE__ */ React25.createElement(React25.Fragment, null, /* @__PURE__ */ React25.createElement(
1974
+ const [isDialogOpen, setIsDialogOpen] = (0, import_react11.useState)(false);
1975
+ return /* @__PURE__ */ React27.createElement(React27.Fragment, null, /* @__PURE__ */ React27.createElement(
1820
1976
  ActionMenuItem,
1821
1977
  {
1822
- icon: import_icons14.TrashIcon,
1978
+ icon: import_icons15.TrashIcon,
1823
1979
  MenuItemProps: {
1824
1980
  disabled: !post.user_can.delete,
1825
1981
  onClick: () => setIsDialogOpen(true),
1826
1982
  sx: { "&:hover": { color: "error.main" } }
1827
1983
  },
1828
- title: (0, import_i18n17.__)("Delete permanently", "elementor")
1984
+ title: (0, import_i18n19.__)("Delete permanently", "elementor")
1829
1985
  }
1830
- ), isDialogOpen && /* @__PURE__ */ React25.createElement(ForceDeleteDialog, { post, setIsDialogOpen }));
1986
+ ), isDialogOpen && /* @__PURE__ */ React27.createElement(ForceDeleteDialog, { post, setIsDialogOpen }));
1831
1987
  }
1832
1988
  function ForceDeleteDialog({
1833
1989
  post,
@@ -1835,8 +1991,8 @@ function ForceDeleteDialog({
1835
1991
  }) {
1836
1992
  const { setError, type } = usePostListContext();
1837
1993
  const { forceDeletePost } = usePostActions(type);
1838
- const dialogTitle = (0, import_i18n17.sprintf)((0, import_i18n17.__)('Delete "%s" permanently?', "elementor"), post.title.rendered);
1839
- const dialogBody = (0, import_i18n17.__)("This will permanently delete the item. You cannot undo this action.", "elementor");
1994
+ const dialogTitle = (0, import_i18n19.sprintf)((0, import_i18n19.__)('Delete "%s" permanently?', "elementor"), post.title.rendered);
1995
+ const dialogBody = (0, import_i18n19.__)("This will permanently delete the item. You cannot undo this action.", "elementor");
1840
1996
  const handleDelete = async () => {
1841
1997
  try {
1842
1998
  await forceDeletePost.mutateAsync(post.id);
@@ -1852,38 +2008,38 @@ function ForceDeleteDialog({
1852
2008
  }
1853
2009
  setIsDialogOpen(false);
1854
2010
  };
1855
- return /* @__PURE__ */ React25.createElement(import_ui18.Dialog, { "aria-labelledby": "force-delete-dialog", onClose: handleCancel, open: true }, /* @__PURE__ */ React25.createElement(import_ui18.DialogTitle, { noWrap: true }, dialogTitle), /* @__PURE__ */ React25.createElement(import_ui18.Divider, null), /* @__PURE__ */ React25.createElement(import_ui18.DialogContent, null, /* @__PURE__ */ React25.createElement(import_ui18.DialogContentText, null, dialogBody)), /* @__PURE__ */ React25.createElement(import_ui18.DialogActions, null, /* @__PURE__ */ React25.createElement(
1856
- import_ui18.Button,
2011
+ return /* @__PURE__ */ React27.createElement(import_ui20.Dialog, { "aria-labelledby": "force-delete-dialog", onClose: handleCancel, open: true }, /* @__PURE__ */ React27.createElement(import_ui20.DialogTitle, { noWrap: true }, dialogTitle), /* @__PURE__ */ React27.createElement(import_ui20.Divider, null), /* @__PURE__ */ React27.createElement(import_ui20.DialogContent, null, /* @__PURE__ */ React27.createElement(import_ui20.DialogContentText, null, dialogBody)), /* @__PURE__ */ React27.createElement(import_ui20.DialogActions, null, /* @__PURE__ */ React27.createElement(
2012
+ import_ui20.Button,
1857
2013
  {
1858
2014
  variant: "contained",
1859
2015
  color: "secondary",
1860
2016
  onClick: handleCancel,
1861
2017
  disabled: forceDeletePost.isPending
1862
2018
  },
1863
- (0, import_i18n17.__)("Cancel", "elementor")
1864
- ), /* @__PURE__ */ React25.createElement(
1865
- import_ui18.Button,
2019
+ (0, import_i18n19.__)("Cancel", "elementor")
2020
+ ), /* @__PURE__ */ React27.createElement(
2021
+ import_ui20.Button,
1866
2022
  {
1867
2023
  variant: "contained",
1868
2024
  color: "error",
1869
2025
  onClick: () => void handleDelete(),
1870
2026
  disabled: forceDeletePost.isPending
1871
2027
  },
1872
- !forceDeletePost.isPending ? (0, import_i18n17.__)("Delete permanently", "elementor") : /* @__PURE__ */ React25.createElement(import_ui18.CircularProgress, null)
2028
+ !forceDeletePost.isPending ? (0, import_i18n19.__)("Delete permanently", "elementor") : /* @__PURE__ */ React27.createElement(import_ui20.CircularProgress, null)
1873
2029
  )));
1874
2030
  }
1875
2031
 
1876
2032
  // src/components/panel/actions-menu/actions/rename.tsx
1877
- var React26 = __toESM(require("react"));
1878
- var import_icons15 = require("@elementor/icons");
1879
- var import_i18n18 = require("@wordpress/i18n");
2033
+ var React28 = __toESM(require("react"));
2034
+ var import_icons16 = require("@elementor/icons");
2035
+ var import_i18n20 = require("@wordpress/i18n");
1880
2036
  function Rename({ post }) {
1881
2037
  const { setEditMode } = usePostListContext();
1882
- return /* @__PURE__ */ React26.createElement(
2038
+ return /* @__PURE__ */ React28.createElement(
1883
2039
  ActionMenuItem,
1884
2040
  {
1885
- title: (0, import_i18n18.__)("Rename", "elementor"),
1886
- icon: import_icons15.EraseIcon,
2041
+ title: (0, import_i18n20.__)("Rename", "elementor"),
2042
+ icon: import_icons16.EraseIcon,
1887
2043
  MenuItemProps: {
1888
2044
  disabled: !post.user_can.edit,
1889
2045
  onClick: () => {
@@ -1900,9 +2056,9 @@ function Rename({ post }) {
1900
2056
  }
1901
2057
 
1902
2058
  // src/components/panel/actions-menu/actions/restore.tsx
1903
- var React27 = __toESM(require("react"));
1904
- var import_icons16 = require("@elementor/icons");
1905
- var import_i18n19 = require("@wordpress/i18n");
2059
+ var React29 = __toESM(require("react"));
2060
+ var import_icons17 = require("@elementor/icons");
2061
+ var import_i18n21 = require("@wordpress/i18n");
1906
2062
  function Restore({ post }) {
1907
2063
  const { setError, type } = usePostListContext();
1908
2064
  const { restorePost } = usePostActions(type);
@@ -1913,12 +2069,12 @@ function Restore({ post }) {
1913
2069
  setError();
1914
2070
  }
1915
2071
  };
1916
- return /* @__PURE__ */ React27.createElement(
2072
+ return /* @__PURE__ */ React29.createElement(
1917
2073
  ActionMenuItem,
1918
2074
  {
1919
- description: (0, import_i18n19.__)("Restored as draft", "elementor"),
1920
- title: (0, import_i18n19.__)("Restore", "elementor"),
1921
- icon: import_icons16.RefreshIcon,
2075
+ description: (0, import_i18n21.__)("Restored as draft", "elementor"),
2076
+ title: (0, import_i18n21.__)("Restore", "elementor"),
2077
+ icon: import_icons17.RefreshIcon,
1922
2078
  MenuItemProps: {
1923
2079
  disabled: restorePost.isPending || !post.user_can.delete,
1924
2080
  onClick: () => void handleClick()
@@ -1928,11 +2084,11 @@ function Restore({ post }) {
1928
2084
  }
1929
2085
 
1930
2086
  // src/components/panel/actions-menu/actions/set-home.tsx
1931
- var React28 = __toESM(require("react"));
1932
- var import_editor_ui4 = require("@elementor/editor-ui");
1933
- var import_icons17 = require("@elementor/icons");
1934
- var import_ui19 = require("@elementor/ui");
1935
- var import_i18n20 = require("@wordpress/i18n");
2087
+ var React30 = __toESM(require("react"));
2088
+ var import_editor_ui5 = require("@elementor/editor-ui");
2089
+ var import_icons18 = require("@elementor/icons");
2090
+ var import_ui21 = require("@elementor/ui");
2091
+ var import_i18n22 = require("@wordpress/i18n");
1936
2092
 
1937
2093
  // src/hooks/use-homepage-actions.ts
1938
2094
  var import_query8 = require("@elementor/query");
@@ -1981,12 +2137,12 @@ function SetHome({ post, closeMenu, onRequestRemoveHomepage }) {
1981
2137
  const isSetHomeDisabled = !canManageOptions || !isPostPublished || updateSettingsMutation.isPending;
1982
2138
  const isRemoveHomeDisabled = !canManageOptions || updateSettingsMutation.isPending;
1983
2139
  const isDisabled = isPostHomepage ? isRemoveHomeDisabled : isSetHomeDisabled;
1984
- const title = isPostHomepage ? (0, import_i18n20.__)("Remove as homepage", "elementor") : (0, import_i18n20.__)("Set as homepage", "elementor");
1985
- return /* @__PURE__ */ React28.createElement(
2140
+ const title = isPostHomepage ? (0, import_i18n22.__)("Remove as homepage", "elementor") : (0, import_i18n22.__)("Set as homepage", "elementor");
2141
+ return /* @__PURE__ */ React30.createElement(
1986
2142
  ActionMenuItem,
1987
2143
  {
1988
2144
  title,
1989
- icon: !updateSettingsMutation.isPending ? import_icons17.HomeIcon : import_ui19.CircularProgress,
2145
+ icon: !updateSettingsMutation.isPending ? import_icons18.HomeIcon : import_ui21.CircularProgress,
1990
2146
  MenuItemProps: {
1991
2147
  disabled: isDisabled,
1992
2148
  onClick: handleMenuClick
@@ -2019,12 +2175,12 @@ function RemoveHomepageDialog({ open, onClose }) {
2019
2175
  }
2020
2176
  };
2021
2177
  const isPending = updateSettingsMutation.isPending;
2022
- const removeHomepageLabel = (0, import_i18n20.__)("Remove as homepage", "elementor");
2023
- return /* @__PURE__ */ React28.createElement(import_editor_ui4.ConfirmationDialog, { open: true, onClose: handleCancel }, /* @__PURE__ */ React28.createElement(import_editor_ui4.ConfirmationDialog.Title, { iconColor: "secondary" }, (0, import_i18n20.__)("Remove this page as your homepage?", "elementor")), /* @__PURE__ */ React28.createElement(import_editor_ui4.ConfirmationDialog.Content, null, /* @__PURE__ */ React28.createElement(import_editor_ui4.ConfirmationDialog.ContentText, null, (0, import_i18n20.__)(
2178
+ const removeHomepageLabel = (0, import_i18n22.__)("Remove as homepage", "elementor");
2179
+ return /* @__PURE__ */ React30.createElement(import_editor_ui5.ConfirmationDialog, { open: true, onClose: handleCancel }, /* @__PURE__ */ React30.createElement(import_editor_ui5.ConfirmationDialog.Title, { iconColor: "secondary" }, (0, import_i18n22.__)("Remove this page as your homepage?", "elementor")), /* @__PURE__ */ React30.createElement(import_editor_ui5.ConfirmationDialog.Content, null, /* @__PURE__ */ React30.createElement(import_editor_ui5.ConfirmationDialog.ContentText, null, (0, import_i18n22.__)(
2024
2180
  "Your homepage will go back to showing your latest posts. You can set a page as your homepage again at any time.",
2025
2181
  "elementor"
2026
- ))), /* @__PURE__ */ React28.createElement(import_ui19.DialogActions, null, /* @__PURE__ */ React28.createElement(import_ui19.Button, { color: "secondary", disabled: isPending, onClick: handleCancel }, (0, import_i18n20.__)("Not now", "elementor")), /* @__PURE__ */ React28.createElement(
2027
- import_ui19.Button,
2182
+ ))), /* @__PURE__ */ React30.createElement(import_ui21.DialogActions, null, /* @__PURE__ */ React30.createElement(import_ui21.Button, { color: "secondary", disabled: isPending, onClick: handleCancel }, (0, import_i18n22.__)("Not now", "elementor")), /* @__PURE__ */ React30.createElement(
2183
+ import_ui21.Button,
2028
2184
  {
2029
2185
  color: "secondary",
2030
2186
  disabled: isPending,
@@ -2032,22 +2188,22 @@ function RemoveHomepageDialog({ open, onClose }) {
2032
2188
  sx: { ml: 1 },
2033
2189
  variant: "contained"
2034
2190
  },
2035
- !isPending ? removeHomepageLabel : /* @__PURE__ */ React28.createElement(import_ui19.CircularProgress, null)
2191
+ !isPending ? removeHomepageLabel : /* @__PURE__ */ React30.createElement(import_ui21.CircularProgress, null)
2036
2192
  )));
2037
2193
  }
2038
2194
 
2039
2195
  // src/components/panel/actions-menu/actions/view.tsx
2040
- var React29 = __toESM(require("react"));
2041
- var import_icons18 = require("@elementor/icons");
2042
- var import_i18n21 = require("@wordpress/i18n");
2196
+ var React31 = __toESM(require("react"));
2197
+ var import_icons19 = require("@elementor/icons");
2198
+ var import_i18n23 = require("@wordpress/i18n");
2043
2199
  function View({ post }) {
2044
2200
  const { type } = usePostListContext();
2045
- const title = (0, import_i18n21.__)("View %s", "elementor").replace("%s", postTypesMap[type].labels.singular_name);
2046
- return /* @__PURE__ */ React29.createElement(
2201
+ const title = (0, import_i18n23.__)("View %s", "elementor").replace("%s", postTypesMap[type].labels.singular_name);
2202
+ return /* @__PURE__ */ React31.createElement(
2047
2203
  ActionMenuItem,
2048
2204
  {
2049
2205
  title,
2050
- icon: import_icons18.EyeIcon,
2206
+ icon: import_icons19.EyeIcon,
2051
2207
  MenuItemProps: {
2052
2208
  onClick: () => window.open(post.link, "_blank")
2053
2209
  }
@@ -2070,17 +2226,17 @@ var DisabledPostTooltip = ({
2070
2226
  postTypeSlug
2071
2227
  }) => {
2072
2228
  if (isDisabled) {
2073
- const title = /* @__PURE__ */ React30.createElement(import_ui20.Typography, { variant: "caption" }, getCannotEditPanelItemMessage(postTypeSlug), /* @__PURE__ */ React30.createElement("br", null), (0, import_i18n22.__)("To edit it directly, contact the site owner", "elementor"));
2074
- return /* @__PURE__ */ React30.createElement(import_ui20.Tooltip, { title, placement: "bottom", arrow: false }, /* @__PURE__ */ React30.createElement("span", null, children));
2229
+ const title = /* @__PURE__ */ React32.createElement(import_ui22.Typography, { variant: "caption" }, getCannotEditPanelItemMessage(postTypeSlug), /* @__PURE__ */ React32.createElement("br", null), (0, import_i18n24.__)("To edit it directly, contact the site owner", "elementor"));
2230
+ return /* @__PURE__ */ React32.createElement(import_ui22.Tooltip, { title, placement: "bottom", arrow: false }, /* @__PURE__ */ React32.createElement("span", null, children));
2075
2231
  }
2076
- return /* @__PURE__ */ React30.createElement(React30.Fragment, null, children);
2232
+ return /* @__PURE__ */ React32.createElement(React32.Fragment, null, children);
2077
2233
  };
2078
2234
  function ListItemView({ post }) {
2079
2235
  const { type } = usePostListContext();
2080
- const [isRemoveHomeDialogOpen, setIsRemoveHomeDialogOpen] = (0, import_react10.useState)(false);
2236
+ const [isRemoveHomeDialogOpen, setIsRemoveHomeDialogOpen] = (0, import_react12.useState)(false);
2081
2237
  const activeDocument = (0, import_editor_documents5.__useActiveDocument)();
2082
2238
  const navigateToDocument = (0, import_editor_documents5.__useNavigateToDocument)();
2083
- const popupState = (0, import_ui20.usePopupState)({
2239
+ const popupState = (0, import_ui22.usePopupState)({
2084
2240
  variant: "popover",
2085
2241
  popupId: "post-actions",
2086
2242
  disableAutoFocus: true
@@ -2091,18 +2247,18 @@ function ListItemView({ post }) {
2091
2247
  const isTrashed = "trash" === post.status;
2092
2248
  const isEditBlocked = !post.user_can.edit && !isTrashed;
2093
2249
  const isRowDisabled = isEditBlocked || isTrashed;
2094
- const menuTriggerProps = (0, import_ui20.bindTrigger)(popupState);
2250
+ const menuTriggerProps = (0, import_ui22.bindTrigger)(popupState);
2095
2251
  const hasListItemActions = useSiteContentListItemActionsInjections().length > 0;
2096
2252
  const showListItemActions = isActive && post.user_can.edit && !isTrashed && hasListItemActions;
2097
- const listRow = /* @__PURE__ */ React30.createElement(
2098
- import_ui20.ListItem,
2253
+ const listRow = /* @__PURE__ */ React32.createElement(
2254
+ import_ui22.ListItem,
2099
2255
  {
2100
2256
  disablePadding: true,
2101
2257
  sx: getContentPanelListItemSx(showListItemActions),
2102
- secondaryAction: /* @__PURE__ */ React30.createElement(import_ui20.Stack, { alignItems: "center", direction: "row", spacing: 0 }, showListItemActions && /* @__PURE__ */ React30.createElement(SiteContentListItemActionsSlot, { post, title }), /* @__PURE__ */ React30.createElement(
2103
- import_ui20.IconButton,
2258
+ secondaryAction: /* @__PURE__ */ React32.createElement(import_ui22.Stack, { alignItems: "center", direction: "row", spacing: 0 }, showListItemActions && /* @__PURE__ */ React32.createElement(SiteContentListItemActionsSlot, { post, title }), /* @__PURE__ */ React32.createElement(
2259
+ import_ui22.IconButton,
2104
2260
  {
2105
- "aria-label": (0, import_i18n22.__)("More actions", "elementor"),
2261
+ "aria-label": (0, import_i18n24.__)("More actions", "elementor"),
2106
2262
  size: "tiny",
2107
2263
  ...menuTriggerProps,
2108
2264
  onClick: (event) => {
@@ -2110,11 +2266,11 @@ function ListItemView({ post }) {
2110
2266
  menuTriggerProps.onClick?.(event);
2111
2267
  }
2112
2268
  },
2113
- /* @__PURE__ */ React30.createElement(import_icons19.DotsVerticalIcon, { fontSize: "tiny" })
2269
+ /* @__PURE__ */ React32.createElement(import_icons20.DotsVerticalIcon, { fontSize: "tiny" })
2114
2270
  ))
2115
2271
  },
2116
- /* @__PURE__ */ React30.createElement(
2117
- import_ui20.ListItemButton,
2272
+ /* @__PURE__ */ React32.createElement(
2273
+ import_ui22.ListItemButton,
2118
2274
  {
2119
2275
  dense: true,
2120
2276
  disableGutters: true,
@@ -2129,18 +2285,18 @@ function ListItemView({ post }) {
2129
2285
  shape: "rounded",
2130
2286
  sx: contentPanelListItemButtonSx
2131
2287
  },
2132
- /* @__PURE__ */ React30.createElement(import_ui20.ListItemText, { disableTypography: true, sx: { flex: 1, minWidth: 0 } }, /* @__PURE__ */ React30.createElement(PageTitleAndStatus, { title, status })),
2133
- post.isHome && /* @__PURE__ */ React30.createElement(import_icons19.HomeIcon, { titleAccess: (0, import_i18n22.__)("Homepage", "elementor"), color: "disabled" })
2288
+ /* @__PURE__ */ React32.createElement(import_ui22.ListItemText, { disableTypography: true, sx: { flex: 1, minWidth: 0 } }, /* @__PURE__ */ React32.createElement(PageTitleAndStatus, { title, status })),
2289
+ post.isHome && /* @__PURE__ */ React32.createElement(import_icons20.HomeIcon, { titleAccess: (0, import_i18n24.__)("Homepage", "elementor"), color: "disabled" })
2134
2290
  )
2135
2291
  );
2136
- return /* @__PURE__ */ React30.createElement(React30.Fragment, null, isEditBlocked ? /* @__PURE__ */ React30.createElement(DisabledPostTooltip, { isDisabled: true, postTypeSlug: type }, listRow) : listRow, /* @__PURE__ */ React30.createElement(
2137
- import_ui20.Menu,
2292
+ return /* @__PURE__ */ React32.createElement(React32.Fragment, null, isEditBlocked ? /* @__PURE__ */ React32.createElement(DisabledPostTooltip, { isDisabled: true, postTypeSlug: type }, listRow) : listRow, /* @__PURE__ */ React32.createElement(
2293
+ import_ui22.Menu,
2138
2294
  {
2139
2295
  PaperProps: { sx: { mt: 2, width: 200 } },
2140
2296
  MenuListProps: { dense: true },
2141
- ...(0, import_ui20.bindMenu)(popupState)
2297
+ ...(0, import_ui22.bindMenu)(popupState)
2142
2298
  },
2143
- isTrashed ? /* @__PURE__ */ React30.createElement(React30.Fragment, null, /* @__PURE__ */ React30.createElement(Restore, { post }), /* @__PURE__ */ React30.createElement(ForceDelete, { post })) : /* @__PURE__ */ React30.createElement(React30.Fragment, null, /* @__PURE__ */ React30.createElement(Rename, { post }), /* @__PURE__ */ React30.createElement(Duplicate, { post, popupState }), /* @__PURE__ */ React30.createElement(Delete, { post }), /* @__PURE__ */ React30.createElement(View, { post }), type === "page" && /* @__PURE__ */ React30.createElement(React30.Fragment, null, /* @__PURE__ */ React30.createElement(import_ui20.Divider, null), /* @__PURE__ */ React30.createElement(
2299
+ isTrashed ? /* @__PURE__ */ React32.createElement(React32.Fragment, null, /* @__PURE__ */ React32.createElement(Restore, { post }), /* @__PURE__ */ React32.createElement(ForceDelete, { post })) : /* @__PURE__ */ React32.createElement(React32.Fragment, null, /* @__PURE__ */ React32.createElement(Rename, { post }), /* @__PURE__ */ React32.createElement(Duplicate, { post, popupState }), /* @__PURE__ */ React32.createElement(Delete, { post }), /* @__PURE__ */ React32.createElement(View, { post }), type === "page" && /* @__PURE__ */ React32.createElement(React32.Fragment, null, /* @__PURE__ */ React32.createElement(import_ui22.Divider, null), /* @__PURE__ */ React32.createElement(
2144
2300
  SetHome,
2145
2301
  {
2146
2302
  post,
@@ -2148,7 +2304,7 @@ function ListItemView({ post }) {
2148
2304
  onRequestRemoveHomepage: () => setIsRemoveHomeDialogOpen(true)
2149
2305
  }
2150
2306
  )))
2151
- ), /* @__PURE__ */ React30.createElement(
2307
+ ), /* @__PURE__ */ React32.createElement(
2152
2308
  RemoveHomepageDialog,
2153
2309
  {
2154
2310
  open: isRemoveHomeDialogOpen,
@@ -2161,25 +2317,25 @@ function ListItemView({ post }) {
2161
2317
  function PostListItem({ post }) {
2162
2318
  const { editMode } = usePostListContext();
2163
2319
  if ("rename" === editMode.mode && post?.id && post?.id === editMode.details.postId) {
2164
- return /* @__PURE__ */ React31.createElement(ListItemRename, { post });
2320
+ return /* @__PURE__ */ React33.createElement(ListItemRename, { post });
2165
2321
  }
2166
2322
  if ("create" === editMode.mode && !post) {
2167
- return /* @__PURE__ */ React31.createElement(ListItemCreate, null);
2323
+ return /* @__PURE__ */ React33.createElement(ListItemCreate, null);
2168
2324
  }
2169
2325
  if ("duplicate" === editMode.mode && !post) {
2170
- return /* @__PURE__ */ React31.createElement(ListItemDuplicate, null);
2326
+ return /* @__PURE__ */ React33.createElement(ListItemDuplicate, null);
2171
2327
  }
2172
2328
  if (!post) {
2173
2329
  return null;
2174
2330
  }
2175
- return /* @__PURE__ */ React31.createElement(ListItemView, { post });
2331
+ return /* @__PURE__ */ React33.createElement(ListItemView, { post });
2176
2332
  }
2177
2333
 
2178
2334
  // src/components/panel/posts-list/post-list-pagination-actions.tsx
2179
- var React32 = __toESM(require("react"));
2180
- var import_editor_ui5 = require("@elementor/editor-ui");
2181
- var import_ui21 = require("@elementor/ui");
2182
- var import_i18n23 = require("@wordpress/i18n");
2335
+ var React34 = __toESM(require("react"));
2336
+ var import_editor_ui6 = require("@elementor/editor-ui");
2337
+ var import_ui23 = require("@elementor/ui");
2338
+ var import_i18n25 = require("@wordpress/i18n");
2183
2339
  var listPaginationButtonProps = {
2184
2340
  color: "secondary",
2185
2341
  size: "small",
@@ -2196,28 +2352,28 @@ function PostListPaginationActions({
2196
2352
  if (!canLoadMore && !canShowLess) {
2197
2353
  return null;
2198
2354
  }
2199
- const loadMoreLabel = (0, import_i18n23.__)("Load more", "elementor");
2200
- const showLessLabel = (0, import_i18n23.__)("Show less", "elementor");
2201
- const loadMoreButton = /* @__PURE__ */ React32.createElement(
2202
- import_ui21.Button,
2355
+ const loadMoreLabel = (0, import_i18n25.__)("Load more", "elementor");
2356
+ const showLessLabel = (0, import_i18n25.__)("Show less", "elementor");
2357
+ const loadMoreButton = /* @__PURE__ */ React34.createElement(
2358
+ import_ui23.Button,
2203
2359
  {
2204
2360
  ...listPaginationButtonProps,
2205
2361
  ref: loadMoreButtonRef,
2206
2362
  "aria-label": loadMoreLabel,
2207
2363
  disabled: isLoadingMore,
2208
- endIcon: isLoadingMore ? void 0 : /* @__PURE__ */ React32.createElement(import_editor_ui5.CollapseIcon, { open: false }),
2364
+ endIcon: isLoadingMore ? void 0 : /* @__PURE__ */ React34.createElement(import_editor_ui6.CollapseIcon, { open: false }),
2209
2365
  fullWidth: true,
2210
2366
  onClick: onLoadMore,
2211
2367
  sx: { flex: 1, my: 0.5 }
2212
2368
  },
2213
- isLoadingMore ? /* @__PURE__ */ React32.createElement(import_ui21.CircularProgress, { size: 20 }) : loadMoreLabel
2369
+ isLoadingMore ? /* @__PURE__ */ React34.createElement(import_ui23.CircularProgress, { size: 20 }) : loadMoreLabel
2214
2370
  );
2215
- const showLessButton = /* @__PURE__ */ React32.createElement(
2216
- import_ui21.Button,
2371
+ const showLessButton = /* @__PURE__ */ React34.createElement(
2372
+ import_ui23.Button,
2217
2373
  {
2218
2374
  ...listPaginationButtonProps,
2219
2375
  "aria-label": showLessLabel,
2220
- endIcon: /* @__PURE__ */ React32.createElement(import_editor_ui5.CollapseIcon, { open: true }),
2376
+ endIcon: /* @__PURE__ */ React34.createElement(import_editor_ui6.CollapseIcon, { open: true }),
2221
2377
  fullWidth: true,
2222
2378
  onClick: onShowLess,
2223
2379
  sx: { flex: 1, my: 0.5 }
@@ -2225,9 +2381,9 @@ function PostListPaginationActions({
2225
2381
  showLessLabel
2226
2382
  );
2227
2383
  if (canShowLess && canLoadMore) {
2228
- return /* @__PURE__ */ React32.createElement(import_ui21.Box, { sx: { px: 2, width: "100%" } }, /* @__PURE__ */ React32.createElement(import_ui21.Stack, { direction: "row", spacing: 1 }, showLessButton, loadMoreButton));
2384
+ return /* @__PURE__ */ React34.createElement(import_ui23.Box, { sx: { px: 2, width: "100%" } }, /* @__PURE__ */ React34.createElement(import_ui23.Stack, { direction: "row", spacing: 1 }, showLessButton, loadMoreButton));
2229
2385
  }
2230
- return /* @__PURE__ */ React32.createElement(import_ui21.Box, { sx: { px: 2, width: "100%" } }, canShowLess ? showLessButton : loadMoreButton);
2386
+ return /* @__PURE__ */ React34.createElement(import_ui23.Box, { sx: { px: 2, width: "100%" } }, canShowLess ? showLessButton : loadMoreButton);
2231
2387
  }
2232
2388
 
2233
2389
  // src/components/panel/posts-list/posts-collapsible-list.tsx
@@ -2235,14 +2391,14 @@ var SEARCH_DEBOUNCE_MS = 300;
2235
2391
  function PostsCollapsibleList({ isOpenByDefault = false }) {
2236
2392
  const { type, editMode, resetEditMode, setEditMode } = usePostListContext();
2237
2393
  const { registerSection, searchQuery, siteContentSort, statusFilters, unregisterSection } = useContentPanelCoordinator();
2238
- const [isOpen, setIsOpen] = (0, import_react11.useState)(isOpenByDefault);
2394
+ const [isOpen, setIsOpen] = (0, import_react13.useState)(isOpenByDefault);
2239
2395
  const trimmedSearch = searchQuery.trim();
2240
- const [debouncedSearch, setDebouncedSearch] = (0, import_react11.useState)(trimmedSearch);
2241
- const focusAfterShowLessRef = (0, import_react11.useRef)(false);
2242
- const listTopRef = (0, import_react11.useRef)(null);
2243
- const loadMoreButtonRef = (0, import_react11.useRef)(null);
2244
- const sectionHeaderRef = (0, import_react11.useRef)(null);
2245
- (0, import_react11.useEffect)(() => {
2396
+ const [debouncedSearch, setDebouncedSearch] = (0, import_react13.useState)(trimmedSearch);
2397
+ const focusAfterShowLessRef = (0, import_react13.useRef)(false);
2398
+ const listTopRef = (0, import_react13.useRef)(null);
2399
+ const loadMoreButtonRef = (0, import_react13.useRef)(null);
2400
+ const sectionHeaderRef = (0, import_react13.useRef)(null);
2401
+ (0, import_react13.useEffect)(() => {
2246
2402
  const handle = window.setTimeout(() => setDebouncedSearch(trimmedSearch), SEARCH_DEBOUNCE_MS);
2247
2403
  return () => window.clearTimeout(handle);
2248
2404
  }, [trimmedSearch]);
@@ -2261,19 +2417,19 @@ function PostsCollapsibleList({ isOpenByDefault = false }) {
2261
2417
  const { data: homepageId } = useHomepage();
2262
2418
  const isPageType = type === "page";
2263
2419
  const statusFiltersKey = serializeSiteContentStatusFilters(statusFilters);
2264
- (0, import_react11.useEffect)(() => {
2420
+ (0, import_react13.useEffect)(() => {
2265
2421
  if (isTrashFilter) {
2266
2422
  resetEditMode();
2267
2423
  }
2268
2424
  }, [isTrashFilter, resetEditMode]);
2269
- (0, import_react11.useEffect)(() => {
2425
+ (0, import_react13.useEffect)(() => {
2270
2426
  registerSection(type, {
2271
2427
  setExpanded: setIsOpen,
2272
2428
  startCreate: () => setEditMode({ mode: "create", details: {} })
2273
2429
  });
2274
2430
  return () => unregisterSection(type);
2275
2431
  }, [registerSection, unregisterSection, type, setEditMode]);
2276
- const filteredPosts = (0, import_react11.useMemo)(() => {
2432
+ const filteredPosts = (0, import_react13.useMemo)(() => {
2277
2433
  if (!posts) {
2278
2434
  return [];
2279
2435
  }
@@ -2298,7 +2454,7 @@ function PostsCollapsibleList({ isOpenByDefault = false }) {
2298
2454
  resetKey: `${type}:${debouncedSearch}:${statusFiltersKey}:${siteContentSort}`,
2299
2455
  totalCount: total
2300
2456
  });
2301
- const displayedPosts = (0, import_react11.useMemo)(
2457
+ const displayedPosts = (0, import_react13.useMemo)(
2302
2458
  () => filteredPosts.slice(0, pagination.visibleCount),
2303
2459
  [filteredPosts, pagination.visibleCount]
2304
2460
  );
@@ -2310,7 +2466,7 @@ function PostsCollapsibleList({ isOpenByDefault = false }) {
2310
2466
  listTop.scrollIntoView({ block: "nearest" });
2311
2467
  }
2312
2468
  };
2313
- (0, import_react11.useEffect)(() => {
2469
+ (0, import_react13.useEffect)(() => {
2314
2470
  if (!focusAfterShowLessRef.current) {
2315
2471
  return;
2316
2472
  }
@@ -2322,22 +2478,22 @@ function PostsCollapsibleList({ isOpenByDefault = false }) {
2322
2478
  }
2323
2479
  sectionHeaderRef.current?.focus();
2324
2480
  }, [pagination.canLoadMore, pagination.visibleCount]);
2325
- (0, import_react11.useEffect)(() => {
2481
+ (0, import_react13.useEffect)(() => {
2326
2482
  if ((debouncedSearch || hasActiveSiteContentStatusFilters(statusFilters)) && filteredPosts.length > 0) {
2327
2483
  setIsOpen(true);
2328
2484
  }
2329
2485
  }, [debouncedSearch, filteredPosts.length, statusFilters]);
2330
2486
  if (postsError) {
2331
- return /* @__PURE__ */ React33.createElement(ErrorState, null);
2487
+ return /* @__PURE__ */ React35.createElement(ErrorState, null);
2332
2488
  }
2333
2489
  if (postsPending && !posts?.length) {
2334
- return /* @__PURE__ */ React33.createElement(import_ui22.Box, { sx: { px: 2 } }, /* @__PURE__ */ React33.createElement(import_ui22.Box, null, /* @__PURE__ */ React33.createElement(import_ui22.Skeleton, { sx: { my: 3 }, animation: "wave", variant: "rounded", width: "100%", height: "24px" }), /* @__PURE__ */ React33.createElement(import_ui22.Skeleton, { sx: { my: 3 }, animation: "wave", variant: "rounded", width: "70%", height: "24px" }), /* @__PURE__ */ React33.createElement(import_ui22.Skeleton, { sx: { my: 3 }, animation: "wave", variant: "rounded", width: "70%", height: "24px" }), /* @__PURE__ */ React33.createElement(import_ui22.Skeleton, { sx: { my: 3 }, animation: "wave", variant: "rounded", width: "70%", height: "24px" })));
2490
+ return /* @__PURE__ */ React35.createElement(import_ui24.Box, { sx: { px: 2 } }, /* @__PURE__ */ React35.createElement(import_ui24.Box, null, /* @__PURE__ */ React35.createElement(import_ui24.Skeleton, { sx: { my: 3 }, animation: "wave", variant: "rounded", width: "100%", height: "24px" }), /* @__PURE__ */ React35.createElement(import_ui24.Skeleton, { sx: { my: 3 }, animation: "wave", variant: "rounded", width: "70%", height: "24px" }), /* @__PURE__ */ React35.createElement(import_ui24.Skeleton, { sx: { my: 3 }, animation: "wave", variant: "rounded", width: "70%", height: "24px" }), /* @__PURE__ */ React35.createElement(import_ui24.Skeleton, { sx: { my: 3 }, animation: "wave", variant: "rounded", width: "70%", height: "24px" })));
2335
2491
  }
2336
2492
  const displayCount = total;
2337
2493
  const sectionTitle = postTypesMap[type].labels.plural_name;
2338
2494
  const showNoResults = (debouncedSearch || hasActiveSiteContentStatusFilters(statusFilters)) && filteredPosts.length === 0;
2339
2495
  const countChipLabel = isNarrowed && baselineTotal !== void 0 ? `${total} / ${baselineTotal}` : void 0;
2340
- return /* @__PURE__ */ React33.createElement(
2496
+ return /* @__PURE__ */ React35.createElement(
2341
2497
  CollapsibleList,
2342
2498
  {
2343
2499
  count: displayCount,
@@ -2346,15 +2502,15 @@ function PostsCollapsibleList({ isOpenByDefault = false }) {
2346
2502
  isOpen,
2347
2503
  onOpenChange: setIsOpen,
2348
2504
  title: sectionTitle,
2349
- trailingActions: isTrashFilter ? null : /* @__PURE__ */ React33.createElement(SectionAddButton, { onBeforeCreate: () => setIsOpen(true) })
2505
+ trailingActions: isTrashFilter ? null : /* @__PURE__ */ React35.createElement(SectionAddButton, { onBeforeCreate: () => setIsOpen(true) })
2350
2506
  },
2351
- showNoResults && /* @__PURE__ */ React33.createElement(import_ui22.Box, { sx: { py: 2, px: 2 } }, /* @__PURE__ */ React33.createElement(import_ui22.Typography, { variant: "body2", color: "text.secondary" }, (0, import_i18n24.__)("No results found", "elementor"))),
2352
- /* @__PURE__ */ React33.createElement(import_ui22.Box, { ref: listTopRef }),
2507
+ showNoResults && /* @__PURE__ */ React35.createElement(import_ui24.Box, { sx: { py: 2, px: 2 } }, /* @__PURE__ */ React35.createElement(import_ui24.Typography, { variant: "body2", color: "text.secondary" }, (0, import_i18n26.__)("No results found", "elementor"))),
2508
+ /* @__PURE__ */ React35.createElement(import_ui24.Box, { ref: listTopRef }),
2353
2509
  displayedPosts.map((post) => {
2354
- return /* @__PURE__ */ React33.createElement(PostListItem, { key: post.id, post });
2510
+ return /* @__PURE__ */ React35.createElement(PostListItem, { key: post.id, post });
2355
2511
  }),
2356
- !isTrashFilter && ["duplicate", "create"].includes(editMode.mode) && /* @__PURE__ */ React33.createElement(PostListItem, null),
2357
- /* @__PURE__ */ React33.createElement(
2512
+ !isTrashFilter && ["duplicate", "create"].includes(editMode.mode) && /* @__PURE__ */ React35.createElement(PostListItem, null),
2513
+ /* @__PURE__ */ React35.createElement(
2358
2514
  PostListPaginationActions,
2359
2515
  {
2360
2516
  canLoadMore: pagination.canLoadMore,
@@ -2369,11 +2525,11 @@ function PostsCollapsibleList({ isOpenByDefault = false }) {
2369
2525
  }
2370
2526
 
2371
2527
  // src/components/panel/user-load-error.tsx
2372
- var React34 = __toESM(require("react"));
2373
- var import_ui23 = require("@elementor/ui");
2374
- var import_i18n25 = require("@wordpress/i18n");
2528
+ var React36 = __toESM(require("react"));
2529
+ var import_ui25 = require("@elementor/ui");
2530
+ var import_i18n27 = require("@wordpress/i18n");
2375
2531
  function UserLoadError() {
2376
- return /* @__PURE__ */ React34.createElement(import_ui23.Box, { sx: { px: 2, py: 2 } }, /* @__PURE__ */ React34.createElement(import_ui23.Typography, { variant: "body2", color: "text.secondary" }, (0, import_i18n25.__)(
2532
+ return /* @__PURE__ */ React36.createElement(import_ui25.Box, { sx: { px: 2, py: 2 } }, /* @__PURE__ */ React36.createElement(import_ui25.Typography, { variant: "body2", color: "text.secondary" }, (0, import_i18n27.__)(
2377
2533
  "We couldn\u2019t load your content permissions. Try closing and reopening this panel.",
2378
2534
  "elementor"
2379
2535
  )));
@@ -2387,21 +2543,22 @@ function ShellPanelBodyContent({
2387
2543
  showUserLoadError
2388
2544
  }) {
2389
2545
  if (isUserPending) {
2390
- return /* @__PURE__ */ React35.createElement(import_ui24.Stack, { spacing: 1, sx: { px: 2, py: 1 } }, /* @__PURE__ */ React35.createElement(import_ui24.Skeleton, { animation: "wave", height: 28, variant: "rounded", width: "100%" }), /* @__PURE__ */ React35.createElement(import_ui24.Skeleton, { animation: "wave", height: 28, variant: "rounded", width: "80%" }));
2546
+ return /* @__PURE__ */ React37.createElement(import_ui26.Stack, { spacing: 1, sx: { px: 2, py: 1 } }, /* @__PURE__ */ React37.createElement(import_ui26.Skeleton, { animation: "wave", height: 28, variant: "rounded", width: "100%" }), /* @__PURE__ */ React37.createElement(import_ui26.Skeleton, { animation: "wave", height: 28, variant: "rounded", width: "80%" }));
2391
2547
  }
2392
2548
  if (showUserLoadError) {
2393
- return /* @__PURE__ */ React35.createElement(UserLoadError, null);
2549
+ return /* @__PURE__ */ React37.createElement(UserLoadError, null);
2394
2550
  }
2395
- return /* @__PURE__ */ React35.createElement(import_ui24.List, { dense: true, disablePadding: true, sx: { py: 0, width: "100%" } }, accessiblePostTypes.map((postTypeSlug, index) => /* @__PURE__ */ React35.createElement(PostListContextProvider, { key: postTypeSlug, type: postTypeSlug, setError: onListError }, /* @__PURE__ */ React35.createElement(PostsCollapsibleList, { isOpenByDefault: index === 0 }))));
2551
+ const extraSections = getSiteContentSections();
2552
+ return /* @__PURE__ */ React37.createElement(import_ui26.List, { dense: true, disablePadding: true, sx: { py: 0, width: "100%" } }, accessiblePostTypes.map((postTypeSlug, index) => /* @__PURE__ */ React37.createElement(PostListContextProvider, { key: postTypeSlug, type: postTypeSlug, setError: onListError }, /* @__PURE__ */ React37.createElement(PostsCollapsibleList, { isOpenByDefault: index === 0 }))), extraSections.map((section) => /* @__PURE__ */ React37.createElement(React37.Fragment, { key: section.id }, section.render())));
2396
2553
  }
2397
2554
 
2398
2555
  // src/components/panel/shell.tsx
2399
2556
  var Shell = () => {
2400
2557
  const sidebarPanelChrome = (0, import_editor_sidebar.isSidebarEnabled)();
2401
- const [isErrorSnackbarOpen, setIsErrorSnackbarOpen] = (0, import_react12.useState)(false);
2558
+ const [isErrorSnackbarOpen, setIsErrorSnackbarOpen] = (0, import_react14.useState)(false);
2402
2559
  const { accessiblePostTypes, isUserPending, showUserLoadError } = useAccessiblePanelPostTypes();
2403
- return /* @__PURE__ */ React36.createElement(ContentPanelCoordinatorProvider, null, /* @__PURE__ */ React36.createElement(import_editor_panels.Panel, null, /* @__PURE__ */ React36.createElement(import_editor_panels.PanelHeader, null, /* @__PURE__ */ React36.createElement(
2404
- import_ui25.Stack,
2560
+ return /* @__PURE__ */ React38.createElement(ContentPanelCoordinatorProvider, null, /* @__PURE__ */ React38.createElement(import_editor_panels.Panel, null, /* @__PURE__ */ React38.createElement(import_editor_panels.PanelHeader, null, /* @__PURE__ */ React38.createElement(
2561
+ import_ui27.Stack,
2405
2562
  {
2406
2563
  alignItems: "center",
2407
2564
  direction: "row",
@@ -2411,9 +2568,9 @@ var Shell = () => {
2411
2568
  ...sidebarPanelChrome ? {} : { p: 1, pl: 2 }
2412
2569
  }
2413
2570
  },
2414
- /* @__PURE__ */ React36.createElement(import_editor_panels.PanelHeaderTitle, { sx: { flex: 1, minWidth: 0, textAlign: "start" } }, (0, import_i18n26.__)("Site content", "elementor")),
2415
- /* @__PURE__ */ React36.createElement(ContentPanelHeaderAdd, null)
2416
- )), /* @__PURE__ */ React36.createElement(import_ui25.Divider, null), /* @__PURE__ */ React36.createElement(import_editor_panels.PanelBody, null, /* @__PURE__ */ React36.createElement(ContentPanelToolbar, null), /* @__PURE__ */ React36.createElement(import_ui25.Divider, null), /* @__PURE__ */ React36.createElement(
2571
+ /* @__PURE__ */ React38.createElement(import_editor_panels.PanelHeaderTitle, { sx: { flex: 1, minWidth: 0, textAlign: "start" } }, (0, import_i18n28.__)("Site content", "elementor")),
2572
+ /* @__PURE__ */ React38.createElement(ContentPanelHeaderAdd, null)
2573
+ )), /* @__PURE__ */ React38.createElement(import_ui27.Divider, null), /* @__PURE__ */ React38.createElement(import_editor_panels.PanelBody, null, /* @__PURE__ */ React38.createElement(ContentPanelToolbar, null), /* @__PURE__ */ React38.createElement(import_ui27.Divider, null), /* @__PURE__ */ React38.createElement(
2417
2574
  ShellPanelBodyContent,
2418
2575
  {
2419
2576
  accessiblePostTypes,
@@ -2421,7 +2578,7 @@ var Shell = () => {
2421
2578
  onListError: () => setIsErrorSnackbarOpen(true),
2422
2579
  showUserLoadError
2423
2580
  }
2424
- ), /* @__PURE__ */ React36.createElement(error_snackbar_default, { open: isErrorSnackbarOpen, onClose: () => setIsErrorSnackbarOpen(false) }))));
2581
+ ), /* @__PURE__ */ React38.createElement(error_snackbar_default, { open: isErrorSnackbarOpen, onClose: () => setIsErrorSnackbarOpen(false) }))));
2425
2582
  };
2426
2583
  var shell_default = Shell;
2427
2584
 
@@ -2432,26 +2589,26 @@ var { panel, usePanelStatus, usePanelActions } = (0, import_editor_panels2.creat
2432
2589
  });
2433
2590
 
2434
2591
  // src/components/top-bar/recently-edited.tsx
2435
- var React41 = __toESM(require("react"));
2592
+ var React43 = __toESM(require("react"));
2436
2593
  var import_editor_documents8 = require("@elementor/editor-documents");
2437
- var import_icons22 = require("@elementor/icons");
2438
- var import_ui30 = require("@elementor/ui");
2439
- var import_i18n28 = require("@wordpress/i18n");
2594
+ var import_icons23 = require("@elementor/icons");
2595
+ var import_ui32 = require("@elementor/ui");
2596
+ var import_i18n30 = require("@wordpress/i18n");
2440
2597
 
2441
2598
  // src/components/top-bar/create-post-list-item.tsx
2442
- var React37 = __toESM(require("react"));
2599
+ var React39 = __toESM(require("react"));
2443
2600
  var import_editor_documents6 = require("@elementor/editor-documents");
2444
2601
  var import_events = require("@elementor/events");
2445
- var import_icons20 = require("@elementor/icons");
2446
- var import_ui26 = require("@elementor/ui");
2447
- var import_i18n27 = require("@wordpress/i18n");
2602
+ var import_icons21 = require("@elementor/icons");
2603
+ var import_ui28 = require("@elementor/ui");
2604
+ var import_i18n29 = require("@wordpress/i18n");
2448
2605
 
2449
2606
  // src/hooks/use-create-page.ts
2450
- var import_react13 = require("react");
2607
+ var import_react15 = require("react");
2451
2608
  var import_api_fetch5 = __toESM(require("@wordpress/api-fetch"));
2452
2609
  var endpointPath = "/elementor/v1/site-navigation/add-new-post";
2453
2610
  function useCreatePage() {
2454
- const [isLoading, setIsLoading] = (0, import_react13.useState)(false);
2611
+ const [isLoading, setIsLoading] = (0, import_react15.useState)(false);
2455
2612
  return {
2456
2613
  create: () => {
2457
2614
  setIsLoading(true);
@@ -2474,8 +2631,8 @@ function CreatePostListItem({ closePopup, ...props }) {
2474
2631
  const navigateToDocument = (0, import_editor_documents6.__useNavigateToDocument)();
2475
2632
  const { data: user } = useUser();
2476
2633
  const { dispatchEvent, config } = (0, import_events.useMixpanel)();
2477
- return /* @__PURE__ */ React37.createElement(
2478
- import_ui26.MenuItem,
2634
+ return /* @__PURE__ */ React39.createElement(
2635
+ import_ui28.MenuItem,
2479
2636
  {
2480
2637
  disabled: isLoading || !user?.capabilities?.edit_pages,
2481
2638
  onClick: async () => {
@@ -2498,26 +2655,26 @@ function CreatePostListItem({ closePopup, ...props }) {
2498
2655
  },
2499
2656
  ...props
2500
2657
  },
2501
- /* @__PURE__ */ React37.createElement(import_ui26.ListItemIcon, null, isLoading ? /* @__PURE__ */ React37.createElement(import_ui26.CircularProgress, { size: "1.25rem" }) : /* @__PURE__ */ React37.createElement(import_icons20.PlusIcon, { fontSize: "small" })),
2502
- /* @__PURE__ */ React37.createElement(
2503
- import_ui26.ListItemText,
2658
+ /* @__PURE__ */ React39.createElement(import_ui28.ListItemIcon, null, isLoading ? /* @__PURE__ */ React39.createElement(import_ui28.CircularProgress, { size: "1.25rem" }) : /* @__PURE__ */ React39.createElement(import_icons21.PlusIcon, { fontSize: "small" })),
2659
+ /* @__PURE__ */ React39.createElement(
2660
+ import_ui28.ListItemText,
2504
2661
  {
2505
2662
  primaryTypographyProps: { variant: "body2" },
2506
- primary: (0, import_i18n27.__)("Add new page", "elementor")
2663
+ primary: (0, import_i18n29.__)("Add new page", "elementor")
2507
2664
  }
2508
2665
  )
2509
2666
  );
2510
2667
  }
2511
2668
 
2512
2669
  // src/components/top-bar/indicator.tsx
2513
- var React38 = __toESM(require("react"));
2514
- var import_ui27 = require("@elementor/ui");
2670
+ var React40 = __toESM(require("react"));
2671
+ var import_ui29 = require("@elementor/ui");
2515
2672
  function Indicator({ title, status }) {
2516
- return /* @__PURE__ */ React38.createElement(Tooltip5, { title }, /* @__PURE__ */ React38.createElement(import_ui27.Stack, { component: "span", direction: "row", alignItems: "center", spacing: 0.5 }, /* @__PURE__ */ React38.createElement(import_ui27.Typography, { component: "span", variant: "body2", sx: { maxWidth: "120px" }, noWrap: true }, title), status.value !== "publish" && /* @__PURE__ */ React38.createElement(import_ui27.Typography, { component: "span", variant: "body2", sx: { fontStyle: "italic" } }, "(", status.label, ")")));
2673
+ return /* @__PURE__ */ React40.createElement(Tooltip5, { title }, /* @__PURE__ */ React40.createElement(import_ui29.Stack, { component: "span", direction: "row", alignItems: "center", spacing: 0.5 }, /* @__PURE__ */ React40.createElement(import_ui29.Typography, { component: "span", variant: "body2", sx: { maxWidth: "120px" }, noWrap: true }, title), status.value !== "publish" && /* @__PURE__ */ React40.createElement(import_ui29.Typography, { component: "span", variant: "body2", sx: { fontStyle: "italic" } }, "(", status.label, ")")));
2517
2674
  }
2518
2675
  function Tooltip5(props) {
2519
- return /* @__PURE__ */ React38.createElement(
2520
- import_ui27.Tooltip,
2676
+ return /* @__PURE__ */ React40.createElement(
2677
+ import_ui29.Tooltip,
2521
2678
  {
2522
2679
  PopperProps: {
2523
2680
  sx: {
@@ -2532,21 +2689,21 @@ function Tooltip5(props) {
2532
2689
  }
2533
2690
 
2534
2691
  // src/components/top-bar/post-list-item.tsx
2535
- var React40 = __toESM(require("react"));
2692
+ var React42 = __toESM(require("react"));
2536
2693
  var import_editor_documents7 = require("@elementor/editor-documents");
2537
2694
  var import_events2 = require("@elementor/events");
2538
- var import_ui29 = require("@elementor/ui");
2695
+ var import_ui31 = require("@elementor/ui");
2539
2696
 
2540
2697
  // src/components/top-bar/chip-doc-type.tsx
2541
- var React39 = __toESM(require("react"));
2542
- var import_icons21 = require("@elementor/icons");
2543
- var import_ui28 = require("@elementor/ui");
2698
+ var React41 = __toESM(require("react"));
2699
+ var import_icons22 = require("@elementor/icons");
2700
+ var import_ui30 = require("@elementor/ui");
2544
2701
  var iconsMap2 = getIconsMap();
2545
2702
  function DocTypeChip({ postType, docType, label }) {
2546
2703
  const color = "elementor_library" === postType ? "global" : "accent";
2547
- const Icon = iconsMap2[docType] || import_icons21.PostTypeIcon;
2548
- return /* @__PURE__ */ React39.createElement(
2549
- import_ui28.Chip,
2704
+ const Icon = iconsMap2[docType] || import_icons22.PostTypeIcon;
2705
+ return /* @__PURE__ */ React41.createElement(
2706
+ import_ui30.Chip,
2550
2707
  {
2551
2708
  component: "span",
2552
2709
  size: "small",
@@ -2554,7 +2711,7 @@ function DocTypeChip({ postType, docType, label }) {
2554
2711
  label,
2555
2712
  "data-value": docType,
2556
2713
  color,
2557
- icon: /* @__PURE__ */ React39.createElement(Icon, null),
2714
+ icon: /* @__PURE__ */ React41.createElement(Icon, null),
2558
2715
  sx: { ml: 1, cursor: "inherit" }
2559
2716
  }
2560
2717
  );
@@ -2565,8 +2722,8 @@ function PostListItem2({ post, closePopup, ...props }) {
2565
2722
  const navigateToDocument = (0, import_editor_documents7.__useNavigateToDocument)();
2566
2723
  const postTitle = useReverseHtmlEntities(post.title);
2567
2724
  const { dispatchEvent, config } = (0, import_events2.useMixpanel)();
2568
- return /* @__PURE__ */ React40.createElement(
2569
- import_ui29.MenuItem,
2725
+ return /* @__PURE__ */ React42.createElement(
2726
+ import_ui31.MenuItem,
2570
2727
  {
2571
2728
  disabled: !post.user_can.edit,
2572
2729
  onClick: async () => {
@@ -2588,15 +2745,15 @@ function PostListItem2({ post, closePopup, ...props }) {
2588
2745
  },
2589
2746
  ...props
2590
2747
  },
2591
- /* @__PURE__ */ React40.createElement(
2592
- import_ui29.ListItemText,
2748
+ /* @__PURE__ */ React42.createElement(
2749
+ import_ui31.ListItemText,
2593
2750
  {
2594
2751
  sx: { flexGrow: 0 },
2595
2752
  primaryTypographyProps: { variant: "body2", noWrap: true },
2596
2753
  primary: postTitle
2597
2754
  }
2598
2755
  ),
2599
- /* @__PURE__ */ React40.createElement(DocTypeChip, { postType: post.type.post_type, docType: post.type.doc_type, label: post.type.label })
2756
+ /* @__PURE__ */ React42.createElement(DocTypeChip, { postType: post.type.post_type, docType: post.type.doc_type, label: post.type.label })
2600
2757
  );
2601
2758
  }
2602
2759
 
@@ -2613,7 +2770,7 @@ function RecentlyEdited() {
2613
2770
  return data.filter((post) => post.id !== document2?.id).splice(0, NUMBER_OF_RECENT_POSTS - 1);
2614
2771
  };
2615
2772
  const recentPosts = getRecentPosts();
2616
- const popupState = (0, import_ui30.usePopupState)({
2773
+ const popupState = (0, import_ui32.usePopupState)({
2617
2774
  variant: "popover",
2618
2775
  popupId: "elementor-v2-top-bar-recently-edited"
2619
2776
  });
@@ -2621,13 +2778,13 @@ function RecentlyEdited() {
2621
2778
  if (!document2) {
2622
2779
  return null;
2623
2780
  }
2624
- const buttonProps = (0, import_ui30.bindTrigger)(popupState);
2625
- return /* @__PURE__ */ React41.createElement(React41.Fragment, null, /* @__PURE__ */ React41.createElement(
2626
- import_ui30.Button,
2781
+ const buttonProps = (0, import_ui32.bindTrigger)(popupState);
2782
+ return /* @__PURE__ */ React43.createElement(React43.Fragment, null, /* @__PURE__ */ React43.createElement(
2783
+ import_ui32.Button,
2627
2784
  {
2628
2785
  color: "inherit",
2629
2786
  size: "small",
2630
- endIcon: /* @__PURE__ */ React41.createElement(import_icons22.ChevronDownIcon, { fontSize: "small" }),
2787
+ endIcon: /* @__PURE__ */ React43.createElement(import_icons23.ChevronDownIcon, { fontSize: "small" }),
2631
2788
  ...buttonProps,
2632
2789
  onClick: (e) => {
2633
2790
  const extendedWindow = window;
@@ -2646,41 +2803,41 @@ function RecentlyEdited() {
2646
2803
  buttonProps.onClick(e);
2647
2804
  }
2648
2805
  },
2649
- /* @__PURE__ */ React41.createElement(Indicator, { title: documentTitle, status: document2.status })
2650
- ), /* @__PURE__ */ React41.createElement(
2651
- import_ui30.Menu,
2806
+ /* @__PURE__ */ React43.createElement(Indicator, { title: documentTitle, status: document2.status })
2807
+ ), /* @__PURE__ */ React43.createElement(
2808
+ import_ui32.Menu,
2652
2809
  {
2653
2810
  MenuListProps: {
2654
- subheader: /* @__PURE__ */ React41.createElement(import_ui30.ListSubheader, { sx: { color: "accent.main", fontStyle: "italic", fontWeight: "300" } }, (0, import_i18n28.__)("Recent", "elementor"))
2811
+ subheader: /* @__PURE__ */ React43.createElement(import_ui32.ListSubheader, { sx: { color: "accent.main", fontStyle: "italic", fontWeight: "300" } }, (0, import_i18n30.__)("Recent", "elementor"))
2655
2812
  },
2656
2813
  PaperProps: { sx: { mt: 2.5, width: 320 } },
2657
- ...(0, import_ui30.bindMenu)(popupState)
2814
+ ...(0, import_ui32.bindMenu)(popupState)
2658
2815
  },
2659
- recentPosts.map((post) => /* @__PURE__ */ React41.createElement(PostListItem2, { key: post.id, post, closePopup: popupState.close })),
2660
- recentPosts.length === 0 && /* @__PURE__ */ React41.createElement(import_ui30.MenuItem, { disabled: true }, /* @__PURE__ */ React41.createElement(
2661
- import_ui30.ListItemText,
2816
+ recentPosts.map((post) => /* @__PURE__ */ React43.createElement(PostListItem2, { key: post.id, post, closePopup: popupState.close })),
2817
+ recentPosts.length === 0 && /* @__PURE__ */ React43.createElement(import_ui32.MenuItem, { disabled: true }, /* @__PURE__ */ React43.createElement(
2818
+ import_ui32.ListItemText,
2662
2819
  {
2663
2820
  primaryTypographyProps: {
2664
2821
  variant: "caption",
2665
2822
  fontStyle: "italic"
2666
2823
  },
2667
- primary: (0, import_i18n28.__)("There are no other pages or templates on this site yet.", "elementor")
2824
+ primary: (0, import_i18n30.__)("There are no other pages or templates on this site yet.", "elementor")
2668
2825
  }
2669
2826
  )),
2670
- /* @__PURE__ */ React41.createElement(import_ui30.Divider, { disabled: recentPosts.length === 0 }),
2671
- /* @__PURE__ */ React41.createElement(CreatePostListItem, { closePopup: popupState.close })
2827
+ /* @__PURE__ */ React43.createElement(import_ui32.Divider, { disabled: recentPosts.length === 0 }),
2828
+ /* @__PURE__ */ React43.createElement(CreatePostListItem, { closePopup: popupState.close })
2672
2829
  ));
2673
2830
  }
2674
2831
 
2675
2832
  // src/hooks/use-toggle-button-props.ts
2676
- var import_icons23 = require("@elementor/icons");
2677
- var import_i18n29 = require("@wordpress/i18n");
2833
+ var import_icons24 = require("@elementor/icons");
2834
+ var import_i18n31 = require("@wordpress/i18n");
2678
2835
  function useToggleButtonProps() {
2679
2836
  const { isOpen: selectedState, isBlocked } = usePanelStatus();
2680
2837
  const { open, close } = usePanelActions();
2681
2838
  return {
2682
- title: (0, import_i18n29.__)("Site content", "elementor"),
2683
- icon: import_icons23.PagesIcon,
2839
+ title: (0, import_i18n31.__)("Site content", "elementor"),
2840
+ icon: import_icons24.PagesIcon,
2684
2841
  onClick: () => {
2685
2842
  const extendedWindow = window;
2686
2843
  const config = extendedWindow?.elementorCommon?.eventsManager?.config;
@@ -2721,10 +2878,81 @@ function registerButton() {
2721
2878
  useProps: useToggleButtonProps
2722
2879
  });
2723
2880
  }
2881
+
2882
+ // src/components/panel/popups/popup-section-add-button.tsx
2883
+ var React44 = __toESM(require("react"));
2884
+ var import_react16 = require("react");
2885
+ var import_ui33 = require("@elementor/ui");
2886
+ var import_i18n32 = require("@wordpress/i18n");
2887
+ var PopupSectionAddButton = (0, import_react16.forwardRef)(
2888
+ ({ disabled, onBeforeCreate, onCreate }, ref) => {
2889
+ const promotionRef = (0, import_react16.useRef)(null);
2890
+ const canCreate = env.popups?.can_use ?? false;
2891
+ const togglePromotion = (0, import_react16.useCallback)(() => {
2892
+ promotionRef.current?.toggle();
2893
+ }, []);
2894
+ (0, import_react16.useImperativeHandle)(ref, () => ({ togglePromotion }), [togglePromotion]);
2895
+ const ariaLabel = (0, import_i18n32.sprintf)(
2896
+ /* translators: %s: Document type singular name. */
2897
+ (0, import_i18n32.__)("New %s", "elementor"),
2898
+ (0, import_i18n32.__)("Popup", "elementor")
2899
+ );
2900
+ if (canCreate) {
2901
+ return /* @__PURE__ */ React44.createElement(
2902
+ ContentPanelAddIconButton,
2903
+ {
2904
+ "aria-label": ariaLabel,
2905
+ disabled,
2906
+ onClick: (event) => {
2907
+ event.stopPropagation();
2908
+ onBeforeCreate?.();
2909
+ onCreate();
2910
+ }
2911
+ }
2912
+ );
2913
+ }
2914
+ return /* @__PURE__ */ React44.createElement(
2915
+ import_ui33.Stack,
2916
+ {
2917
+ alignItems: "center",
2918
+ direction: "row",
2919
+ onClick: (event) => {
2920
+ event.stopPropagation();
2921
+ onBeforeCreate?.();
2922
+ togglePromotion();
2923
+ },
2924
+ sx: { cursor: "pointer" }
2925
+ },
2926
+ /* @__PURE__ */ React44.createElement(ContentPanelAddIconButton, { "aria-label": ariaLabel, tabIndex: -1 }),
2927
+ /* @__PURE__ */ React44.createElement(SiteContentPopupsPromotionChip, { ref: promotionRef })
2928
+ );
2929
+ }
2930
+ );
2724
2931
  // Annotate the CommonJS export names for ESM import in node:
2725
2932
  0 && (module.exports = {
2933
+ ContentPanelAddIconButton,
2934
+ ContentPanelCoordinatorProvider,
2935
+ POPUPS_SITE_CONTENT_SECTION_ID,
2936
+ POST_PER_PAGE,
2937
+ PopupSectionAddButton,
2938
+ SiteContentCollapsibleList,
2939
+ SiteContentEditModeTemplate,
2940
+ SiteContentListErrorState,
2726
2941
  SiteContentListItemActionsSlot,
2942
+ SiteContentPageTitleAndStatus,
2943
+ SiteContentPaginationActions,
2944
+ contentPanelListItemButtonSx,
2945
+ contentPanelListRowPaddingSx,
2946
+ env,
2727
2947
  extendIconsMap,
2948
+ getSiteContentHeaderCreateItems,
2949
+ getSiteContentSections,
2728
2950
  init,
2729
- injectIntoSiteContentListItemActions
2951
+ injectIntoSiteContentListItemActions,
2952
+ registerSiteContentHeaderCreateItem,
2953
+ registerSiteContentSection,
2954
+ resetSiteContentHeaderCreateItems,
2955
+ resetSiteContentSections,
2956
+ useContentPanelCoordinator,
2957
+ usePostListPagination
2730
2958
  });