UNPKG

geostyler

Version:
40 lines (39 loc) 1.13 kB
import { jsxs as o, jsx as e } from "react/jsx-runtime"; /* empty css */ import { Divider as s, Tree as a, Button as c } from "antd"; import m from "../../Util/FilterUtil.js"; import { PlusOutlined as n } from "@ant-design/icons"; import { useGeoStylerLocale as f } from "../../context/GeoStylerContext/GeoStylerContext.js"; const x = ({ filter: r, onEditFilterClick: i = () => { } }) => { const l = f("FilterOverview"); let t = []; return r && (t = m.filterToTree(r)), /* @__PURE__ */ o("div", { className: "gs-filter-overview", children: [ /* @__PURE__ */ e("h2", { children: l.filterTitle }), /* @__PURE__ */ e(s, {}), r ? /* @__PURE__ */ e( a, { treeData: t, defaultExpandAll: !0, selectable: !1, showLine: { showLeafIcon: !1 }, onClick: i } ) : /* @__PURE__ */ e("div", { className: "gs-filter-overview-add", children: /* @__PURE__ */ e( c, { type: "text", icon: /* @__PURE__ */ e(n, {}), size: "large", onClick: i } ) }) ] }); }; export { x as FilterOverview };