@elementor/editor-global-classes 3.32.0-92 → 3.32.0-94
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 +16 -16
- package/src/components/class-manager/global-classes-list.tsx +10 -2
package/dist/index.js
CHANGED
|
@@ -1574,27 +1574,37 @@ var GlobalClassesList = ({ disabled }) => {
|
|
|
1574
1574
|
if (notFoundType) {
|
|
1575
1575
|
return /* @__PURE__ */ React15.createElement(NotFound, { notFoundType });
|
|
1576
1576
|
}
|
|
1577
|
-
|
|
1578
|
-
|
|
1577
|
+
const isFiltersApplied = filters?.length || searchValue;
|
|
1578
|
+
const allowSorting = filteredCssClasses.length > 1 && !isFiltersApplied;
|
|
1579
|
+
return /* @__PURE__ */ React15.createElement(DeleteConfirmationProvider, null, /* @__PURE__ */ React15.createElement(import_ui13.List, { sx: { display: "flex", flexDirection: "column", gap: 0.5 } }, /* @__PURE__ */ React15.createElement(
|
|
1580
|
+
SortableProvider,
|
|
1579
1581
|
{
|
|
1580
|
-
|
|
1581
|
-
|
|
1582
|
-
|
|
1583
|
-
|
|
1584
|
-
|
|
1585
|
-
|
|
1586
|
-
|
|
1587
|
-
|
|
1588
|
-
|
|
1589
|
-
|
|
1590
|
-
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
|
|
1594
|
-
|
|
1595
|
-
|
|
1596
|
-
|
|
1597
|
-
|
|
1582
|
+
value: classesOrder,
|
|
1583
|
+
onChange: reorderClasses,
|
|
1584
|
+
disableDragOverlay: !allowSorting
|
|
1585
|
+
},
|
|
1586
|
+
filteredCssClasses?.map(({ id: id2, label }) => /* @__PURE__ */ React15.createElement(SortableItem, { key: id2, id: id2 }, ({ isDragged, isDragPlaceholder, triggerProps, triggerStyle }) => /* @__PURE__ */ React15.createElement(
|
|
1587
|
+
ClassItem,
|
|
1588
|
+
{
|
|
1589
|
+
id: id2,
|
|
1590
|
+
label,
|
|
1591
|
+
renameClass: (newLabel) => {
|
|
1592
|
+
dispatch5(
|
|
1593
|
+
slice.actions.update({
|
|
1594
|
+
style: {
|
|
1595
|
+
id: id2,
|
|
1596
|
+
label: newLabel
|
|
1597
|
+
}
|
|
1598
|
+
})
|
|
1599
|
+
);
|
|
1600
|
+
},
|
|
1601
|
+
selected: isDragged,
|
|
1602
|
+
disabled: disabled || isDragPlaceholder,
|
|
1603
|
+
sortableTriggerProps: { ...triggerProps, style: triggerStyle },
|
|
1604
|
+
showSortIndicator: allowSorting
|
|
1605
|
+
}
|
|
1606
|
+
)))
|
|
1607
|
+
)));
|
|
1598
1608
|
};
|
|
1599
1609
|
var EmptyState = () => /* @__PURE__ */ React15.createElement(import_ui13.Stack, { 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" }, (0, import_i18n12.__)("There are no global classes yet.", "elementor")), /* @__PURE__ */ React15.createElement(import_ui13.Typography, { align: "center", variant: "caption", color: "text.secondary" }, (0, import_i18n12.__)(
|
|
1600
1610
|
"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.",
|