@elementor/editor-global-classes 3.32.0-91 → 3.32.0-93
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 +30 -20
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +30 -20
- package/dist/index.mjs.map +1 -1
- package/package.json +15 -15
- package/src/components/class-manager/global-classes-list.tsx +10 -2
package/dist/index.mjs
CHANGED
|
@@ -1619,27 +1619,37 @@ var GlobalClassesList = ({ disabled }) => {
|
|
|
1619
1619
|
if (notFoundType) {
|
|
1620
1620
|
return /* @__PURE__ */ React15.createElement(NotFound, { notFoundType });
|
|
1621
1621
|
}
|
|
1622
|
-
|
|
1623
|
-
|
|
1622
|
+
const isFiltersApplied = filters?.length || searchValue;
|
|
1623
|
+
const allowSorting = filteredCssClasses.length > 1 && !isFiltersApplied;
|
|
1624
|
+
return /* @__PURE__ */ React15.createElement(DeleteConfirmationProvider, null, /* @__PURE__ */ React15.createElement(List, { sx: { display: "flex", flexDirection: "column", gap: 0.5 } }, /* @__PURE__ */ React15.createElement(
|
|
1625
|
+
SortableProvider,
|
|
1624
1626
|
{
|
|
1625
|
-
|
|
1626
|
-
|
|
1627
|
-
|
|
1628
|
-
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1632
|
-
|
|
1633
|
-
|
|
1634
|
-
|
|
1635
|
-
|
|
1636
|
-
|
|
1637
|
-
|
|
1638
|
-
|
|
1639
|
-
|
|
1640
|
-
|
|
1641
|
-
|
|
1642
|
-
|
|
1627
|
+
value: classesOrder,
|
|
1628
|
+
onChange: reorderClasses,
|
|
1629
|
+
disableDragOverlay: !allowSorting
|
|
1630
|
+
},
|
|
1631
|
+
filteredCssClasses?.map(({ id: id2, label }) => /* @__PURE__ */ React15.createElement(SortableItem, { key: id2, id: id2 }, ({ isDragged, isDragPlaceholder, triggerProps, triggerStyle }) => /* @__PURE__ */ React15.createElement(
|
|
1632
|
+
ClassItem,
|
|
1633
|
+
{
|
|
1634
|
+
id: id2,
|
|
1635
|
+
label,
|
|
1636
|
+
renameClass: (newLabel) => {
|
|
1637
|
+
dispatch5(
|
|
1638
|
+
slice.actions.update({
|
|
1639
|
+
style: {
|
|
1640
|
+
id: id2,
|
|
1641
|
+
label: newLabel
|
|
1642
|
+
}
|
|
1643
|
+
})
|
|
1644
|
+
);
|
|
1645
|
+
},
|
|
1646
|
+
selected: isDragged,
|
|
1647
|
+
disabled: disabled || isDragPlaceholder,
|
|
1648
|
+
sortableTriggerProps: { ...triggerProps, style: triggerStyle },
|
|
1649
|
+
showSortIndicator: allowSorting
|
|
1650
|
+
}
|
|
1651
|
+
)))
|
|
1652
|
+
)));
|
|
1643
1653
|
};
|
|
1644
1654
|
var EmptyState = () => /* @__PURE__ */ React15.createElement(Stack7, { alignItems: "center", gap: 1.5, pt: 10, px: 0.5, maxWidth: "260px", margin: "auto" }, /* @__PURE__ */ React15.createElement(FlippedColorSwatchIcon, { fontSize: "large" }), /* @__PURE__ */ React15.createElement(StyledHeader, { variant: "subtitle2", component: "h2", color: "text.secondary" }, __12("There are no global classes yet.", "elementor")), /* @__PURE__ */ React15.createElement(Typography7, { align: "center", variant: "caption", color: "text.secondary" }, __12(
|
|
1645
1655
|
"CSS classes created in the editor panel will appear here. Once they are available, you can arrange their hierarchy, rename them, or delete them as needed.",
|