@l3mpire/ui 2.24.1 → 2.25.0

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
@@ -46,6 +46,7 @@ __export(index_exports, {
46
46
  DEFAULT_OPERATOR_BY_TYPE: () => DEFAULT_OPERATOR_BY_TYPE,
47
47
  DataTable: () => DataTable,
48
48
  DataTablePagination: () => DataTablePagination,
49
+ DataTableSettingsModal: () => DataTableSettingsModal,
49
50
  DateCell: () => DateCell,
50
51
  DatePicker: () => DatePicker,
51
52
  DatePickerCalendar: () => DatePickerCalendar,
@@ -4422,7 +4423,7 @@ var RowActions = ({ children, className }) => /* @__PURE__ */ (0, import_jsx_run
4422
4423
  RowActions.displayName = "RowActions";
4423
4424
 
4424
4425
  // src/components/ui/data-table.tsx
4425
- var React36 = __toESM(require("react"));
4426
+ var React37 = __toESM(require("react"));
4426
4427
  var import_react_table = require("@tanstack/react-table");
4427
4428
  var import_core = require("@dnd-kit/core");
4428
4429
  var import_sortable = require("@dnd-kit/sortable");
@@ -4520,8 +4521,176 @@ var TableCaption = React35.forwardRef(({ className, ...props }, ref) => /* @__PU
4520
4521
  ));
4521
4522
  TableCaption.displayName = "TableCaption";
4522
4523
 
4523
- // src/components/ui/data-table.tsx
4524
+ // src/components/ui/data-table-settings-modal.tsx
4525
+ var React36 = __toESM(require("react"));
4524
4526
  var import_jsx_runtime36 = require("react/jsx-runtime");
4527
+ function getColKey(col) {
4528
+ return col.id ?? col.accessorKey ?? "";
4529
+ }
4530
+ function getColLabel(col) {
4531
+ const h = col.header;
4532
+ if (typeof h === "string") return h;
4533
+ return getColKey(col);
4534
+ }
4535
+ function inferLockedIds(columns) {
4536
+ const ids = ["select"];
4537
+ for (const c of columns) {
4538
+ if (c.enableHiding === false) {
4539
+ const key = getColKey(c);
4540
+ if (key) ids.push(key);
4541
+ }
4542
+ }
4543
+ return ids;
4544
+ }
4545
+ function DataTableSettingsModal({
4546
+ open,
4547
+ onOpenChange,
4548
+ columns,
4549
+ columnVisibility,
4550
+ onApply,
4551
+ lockedColumnIds,
4552
+ title = "Manage table",
4553
+ className
4554
+ }) {
4555
+ const [draft, setDraft] = React36.useState(columnVisibility);
4556
+ const [search, setSearch] = React36.useState("");
4557
+ const prevOpen = React36.useRef(open);
4558
+ if (open && !prevOpen.current) {
4559
+ setDraft(columnVisibility);
4560
+ setSearch("");
4561
+ }
4562
+ prevOpen.current = open;
4563
+ const lockedIds = React36.useMemo(
4564
+ () => lockedColumnIds ?? inferLockedIds(columns),
4565
+ [lockedColumnIds, columns]
4566
+ );
4567
+ const editable = React36.useMemo(
4568
+ () => columns.filter((c) => {
4569
+ const key = getColKey(c);
4570
+ return key && !lockedIds.includes(key);
4571
+ }),
4572
+ [columns, lockedIds]
4573
+ );
4574
+ const filtered = React36.useMemo(() => {
4575
+ if (!search) return editable;
4576
+ const q = search.toLowerCase();
4577
+ return editable.filter((c) => getColLabel(c).toLowerCase().includes(q));
4578
+ }, [editable, search]);
4579
+ const visibleCount = editable.filter(
4580
+ (c) => draft[getColKey(c)] !== false
4581
+ ).length;
4582
+ const totalCount = editable.length;
4583
+ const toggle = (key) => setDraft((p) => ({ ...p, [key]: p[key] === false ? true : false }));
4584
+ const showAll = () => {
4585
+ const next = { ...draft };
4586
+ for (const c of editable) next[getColKey(c)] = true;
4587
+ setDraft(next);
4588
+ };
4589
+ const hideAll = () => {
4590
+ const next = { ...draft };
4591
+ for (const c of editable) next[getColKey(c)] = false;
4592
+ setDraft(next);
4593
+ };
4594
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Modal, { open, onOpenChange, children: /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(ModalContent, { size: "sm", className, children: [
4595
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(ModalHeader, { onClose: () => onOpenChange(false), children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(ModalTitle, { children: title }) }),
4596
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(ModalBody, { children: /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex flex-col gap-md", children: [
4597
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex items-center justify-between gap-base", children: [
4598
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("span", { className: "text-sm font-medium text-table-cell-text-secondary", children: [
4599
+ "Columns ",
4600
+ visibleCount,
4601
+ " / ",
4602
+ totalCount
4603
+ ] }),
4604
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex items-center gap-sm", children: [
4605
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4606
+ "button",
4607
+ {
4608
+ type: "button",
4609
+ onClick: showAll,
4610
+ className: "text-xs font-medium text-link-brand-text-default hover:text-link-brand-text-hover hover:underline cursor-pointer bg-transparent border-0 p-0",
4611
+ children: "Show all"
4612
+ }
4613
+ ),
4614
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { className: "text-xs text-table-cell-text-secondary", children: "\xB7" }),
4615
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4616
+ "button",
4617
+ {
4618
+ type: "button",
4619
+ onClick: hideAll,
4620
+ className: "text-xs font-medium text-link-brand-text-default hover:text-link-brand-text-hover hover:underline cursor-pointer bg-transparent border-0 p-0",
4621
+ children: "Hide all"
4622
+ }
4623
+ )
4624
+ ] })
4625
+ ] }),
4626
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4627
+ SearchBar,
4628
+ {
4629
+ size: "sm",
4630
+ placeholder: "Search columns",
4631
+ value: search,
4632
+ onChange: (e) => setSearch(e.target.value),
4633
+ onClear: () => setSearch("")
4634
+ }
4635
+ ),
4636
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4637
+ "div",
4638
+ {
4639
+ className: cn(
4640
+ "flex flex-col max-h-[360px] overflow-auto rounded-base",
4641
+ "border border-table-border"
4642
+ ),
4643
+ children: filtered.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "py-md text-center text-sm text-table-cell-text-secondary", children: "No columns found" }) : filtered.map((c) => {
4644
+ const key = getColKey(c);
4645
+ const label = getColLabel(c);
4646
+ const checked = draft[key] !== false;
4647
+ return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
4648
+ "label",
4649
+ {
4650
+ className: cn(
4651
+ "flex items-center gap-base px-base py-sm cursor-pointer",
4652
+ "border-b border-table-border last:border-b-0",
4653
+ "hover:bg-table-row-bg-hover transition-colors"
4654
+ ),
4655
+ children: [
4656
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4657
+ Checkbox,
4658
+ {
4659
+ checked,
4660
+ onCheckedChange: () => toggle(key)
4661
+ }
4662
+ ),
4663
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { className: "text-sm text-table-cell-text-primary", children: label })
4664
+ ]
4665
+ },
4666
+ key
4667
+ );
4668
+ })
4669
+ }
4670
+ )
4671
+ ] }) }),
4672
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(ModalFooter, { children: [
4673
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(ModalClose, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(Button, { appearance: "ghost", intent: "brand", size: "md", children: "Cancel" }) }),
4674
+ /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4675
+ Button,
4676
+ {
4677
+ appearance: "solid",
4678
+ intent: "brand",
4679
+ size: "md",
4680
+ onClick: () => {
4681
+ onApply(draft);
4682
+ onOpenChange(false);
4683
+ },
4684
+ children: "Apply"
4685
+ }
4686
+ )
4687
+ ] })
4688
+ ] }) });
4689
+ }
4690
+ DataTableSettingsModal.displayName = "DataTableSettingsModal";
4691
+
4692
+ // src/components/ui/data-table.tsx
4693
+ var import_jsx_runtime37 = require("react/jsx-runtime");
4525
4694
  var filterOperatorsByType = {
4526
4695
  string: [
4527
4696
  { value: "contains", label: "Contains" },
@@ -4571,12 +4740,12 @@ function ColumnFilterPopover({
4571
4740
  children
4572
4741
  }) {
4573
4742
  const operators = filterOperatorsByType[filterType] ?? filterOperatorsByType.string;
4574
- const [operator, setOperator] = React36.useState(
4743
+ const [operator, setOperator] = React37.useState(
4575
4744
  operators[0].value
4576
4745
  );
4577
- const [inputValue, setInputValue] = React36.useState("");
4578
- const [open, setOpen] = React36.useState(false);
4579
- React36.useEffect(() => {
4746
+ const [inputValue, setInputValue] = React37.useState("");
4747
+ const [open, setOpen] = React37.useState(false);
4748
+ React37.useEffect(() => {
4580
4749
  if (open && filterValue && typeof filterValue === "object") {
4581
4750
  const fv = filterValue;
4582
4751
  if (fv.operator) setOperator(fv.operator);
@@ -4586,9 +4755,9 @@ function ColumnFilterPopover({
4586
4755
  setInputValue("");
4587
4756
  }
4588
4757
  }, [open, filterValue, operators]);
4589
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(PopoverPrimitive2.Root, { open, onOpenChange: setOpen, children: [
4590
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(PopoverPrimitive2.Trigger, { asChild: true, children }),
4591
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(PopoverPrimitive2.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4758
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(PopoverPrimitive2.Root, { open, onOpenChange: setOpen, children: [
4759
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(PopoverPrimitive2.Trigger, { asChild: true, children }),
4760
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(PopoverPrimitive2.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4592
4761
  PopoverPrimitive2.Content,
4593
4762
  {
4594
4763
  align: "start",
@@ -4598,9 +4767,9 @@ function ColumnFilterPopover({
4598
4767
  "animate-in fade-in-0 zoom-in-95"
4599
4768
  ),
4600
4769
  onClick: (e) => e.stopPropagation(),
4601
- children: /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex flex-col gap-sm", children: [
4602
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { className: "text-xs font-medium text-table-head-text", children: "Filter" }),
4603
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4770
+ children: /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: "flex flex-col gap-sm", children: [
4771
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "text-xs font-medium text-table-head-text", children: "Filter" }),
4772
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4604
4773
  "select",
4605
4774
  {
4606
4775
  className: cn(
@@ -4610,10 +4779,10 @@ function ColumnFilterPopover({
4610
4779
  ),
4611
4780
  value: operator,
4612
4781
  onChange: (e) => setOperator(e.target.value),
4613
- children: operators.map((op) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("option", { value: op.value, children: op.label }, op.value))
4782
+ children: operators.map((op) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("option", { value: op.value, children: op.label }, op.value))
4614
4783
  }
4615
4784
  ),
4616
- !noValueOperators.has(operator) && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4785
+ !noValueOperators.has(operator) && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4617
4786
  "input",
4618
4787
  {
4619
4788
  type: filterType === "number" ? "number" : filterType === "date" ? "date" : "text",
@@ -4633,8 +4802,8 @@ function ColumnFilterPopover({
4633
4802
  }
4634
4803
  }
4635
4804
  ),
4636
- /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex items-center justify-end gap-xs pt-xs", children: [
4637
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4805
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: "flex items-center justify-end gap-xs pt-xs", children: [
4806
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4638
4807
  Button,
4639
4808
  {
4640
4809
  appearance: "ghost",
@@ -4647,7 +4816,7 @@ function ColumnFilterPopover({
4647
4816
  children: "Clear"
4648
4817
  }
4649
4818
  ),
4650
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4819
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4651
4820
  Button,
4652
4821
  {
4653
4822
  appearance: "solid",
@@ -4680,7 +4849,7 @@ function DraggableHeaderCell({
4680
4849
  const leadingIcon = meta?.icon;
4681
4850
  const canDrag = isDragEnabled && meta?.enableDrag !== false;
4682
4851
  const filterType = meta?.filterType ?? "string";
4683
- const [isHovered, setIsHovered] = React36.useState(false);
4852
+ const [isHovered, setIsHovered] = React37.useState(false);
4684
4853
  const {
4685
4854
  attributes,
4686
4855
  listeners,
@@ -4702,7 +4871,7 @@ function DraggableHeaderCell({
4702
4871
  opacity: isDragging ? 0.5 : 1,
4703
4872
  zIndex: isDragging ? 1 : void 0
4704
4873
  };
4705
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
4874
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
4706
4875
  TableHead,
4707
4876
  {
4708
4877
  ref: setNodeRef,
@@ -4716,15 +4885,15 @@ function DraggableHeaderCell({
4716
4885
  onMouseEnter: () => setIsHovered(true),
4717
4886
  onMouseLeave: () => setIsHovered(false),
4718
4887
  children: [
4719
- /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex items-center gap-xs", children: [
4720
- leadingIcon && (canDrag ? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4888
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: "flex items-center gap-xs", children: [
4889
+ leadingIcon && (canDrag ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4721
4890
  "div",
4722
4891
  {
4723
4892
  ...attributes,
4724
4893
  ...listeners,
4725
4894
  className: "shrink-0 flex items-center cursor-grab",
4726
4895
  onClick: (e) => e.stopPropagation(),
4727
- children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4896
+ children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4728
4897
  import_icons24.Icon,
4729
4898
  {
4730
4899
  icon: isHovered ? import_icons24.faGripDotsVerticalSolid : leadingIcon,
@@ -4733,7 +4902,7 @@ function DraggableHeaderCell({
4733
4902
  }
4734
4903
  )
4735
4904
  }
4736
- ) : /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4905
+ ) : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4737
4906
  import_icons24.Icon,
4738
4907
  {
4739
4908
  icon: leadingIcon,
@@ -4741,14 +4910,14 @@ function DraggableHeaderCell({
4741
4910
  className: "shrink-0 text-table-head-icon"
4742
4911
  }
4743
4912
  )),
4744
- !leadingIcon && canDrag && isHovered && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4913
+ !leadingIcon && canDrag && isHovered && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4745
4914
  "div",
4746
4915
  {
4747
4916
  ...attributes,
4748
4917
  ...listeners,
4749
4918
  className: "shrink-0 flex items-center cursor-grab",
4750
4919
  onClick: (e) => e.stopPropagation(),
4751
- children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4920
+ children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4752
4921
  import_icons24.Icon,
4753
4922
  {
4754
4923
  icon: import_icons24.faGripDotsVerticalSolid,
@@ -4758,11 +4927,11 @@ function DraggableHeaderCell({
4758
4927
  )
4759
4928
  }
4760
4929
  ),
4761
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { className: "flex-1 truncate", children: header.isPlaceholder ? null : (0, import_react_table.flexRender)(
4930
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "flex-1 truncate", children: header.isPlaceholder ? null : (0, import_react_table.flexRender)(
4762
4931
  header.column.columnDef.header,
4763
4932
  header.getContext()
4764
4933
  ) }),
4765
- canSort && (isSorted || isHovered) && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4934
+ canSort && (isSorted || isHovered) && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4766
4935
  import_icons24.Icon,
4767
4936
  {
4768
4937
  icon: isSorted === "asc" ? import_icons24.faSortUpSolid : isSorted === "desc" ? import_icons24.faSortDownSolid : import_icons24.faSortSolid,
@@ -4770,20 +4939,20 @@ function DraggableHeaderCell({
4770
4939
  className: "shrink-0 text-table-head-icon"
4771
4940
  }
4772
4941
  ),
4773
- enableFiltering && (isFiltered || isHovered) && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4942
+ enableFiltering && (isFiltered || isHovered) && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4774
4943
  ColumnFilterPopover,
4775
4944
  {
4776
4945
  filterType,
4777
4946
  filterValue: header.column.getFilterValue(),
4778
4947
  onApply: (val) => header.column.setFilterValue(val),
4779
4948
  onClear: () => header.column.setFilterValue(void 0),
4780
- children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4949
+ children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4781
4950
  "button",
4782
4951
  {
4783
4952
  type: "button",
4784
4953
  onClick: (e) => e.stopPropagation(),
4785
4954
  className: "shrink-0 p-0 border-0 bg-transparent cursor-pointer",
4786
- children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4955
+ children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4787
4956
  import_icons24.Icon,
4788
4957
  {
4789
4958
  icon: isFiltered ? import_icons24.faFilterSolid : import_icons24.faFilterOutline,
@@ -4796,7 +4965,7 @@ function DraggableHeaderCell({
4796
4965
  }
4797
4966
  )
4798
4967
  ] }),
4799
- enableColumnResizing && header.column.getCanResize() && /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
4968
+ enableColumnResizing && header.column.getCanResize() && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
4800
4969
  "div",
4801
4970
  {
4802
4971
  onMouseDown: header.getResizeHandler(),
@@ -4894,6 +5063,9 @@ function DataTableInner({
4894
5063
  enableColumnPinning = false,
4895
5064
  enableColumnResizing = false,
4896
5065
  enableColumnDrag = false,
5066
+ enableTableSettings = false,
5067
+ lockedColumnIds,
5068
+ tableSettingsTitle,
4897
5069
  sorting: sortingProp,
4898
5070
  onSortingChange,
4899
5071
  columnFilters: columnFiltersProp,
@@ -4914,17 +5086,19 @@ function DataTableInner({
4914
5086
  emptyMessage = "No results.",
4915
5087
  bordered = false
4916
5088
  }) {
4917
- const [internalSorting, setInternalSorting] = React36.useState([]);
4918
- const [internalColumnFilters, setInternalColumnFilters] = React36.useState([]);
4919
- const [internalPagination, setInternalPagination] = React36.useState({ pageIndex: 0, pageSize: 10 });
4920
- const [internalRowSelection, setInternalRowSelection] = React36.useState({});
4921
- const [internalColumnVisibility, setInternalColumnVisibility] = React36.useState({});
4922
- const [internalColumnOrder, setInternalColumnOrder] = React36.useState([]);
4923
- const [internalColumnPinning, setInternalColumnPinning] = React36.useState({});
4924
- const [internalColumnSizing, setInternalColumnSizing] = React36.useState({});
5089
+ const effectiveColumnVisibility = enableColumnVisibility || enableTableSettings;
5090
+ const [tableSettingsOpen, setTableSettingsOpen] = React37.useState(false);
5091
+ const [internalSorting, setInternalSorting] = React37.useState([]);
5092
+ const [internalColumnFilters, setInternalColumnFilters] = React37.useState([]);
5093
+ const [internalPagination, setInternalPagination] = React37.useState({ pageIndex: 0, pageSize: 10 });
5094
+ const [internalRowSelection, setInternalRowSelection] = React37.useState({});
5095
+ const [internalColumnVisibility, setInternalColumnVisibility] = React37.useState({});
5096
+ const [internalColumnOrder, setInternalColumnOrder] = React37.useState([]);
5097
+ const [internalColumnPinning, setInternalColumnPinning] = React37.useState({});
5098
+ const [internalColumnSizing, setInternalColumnSizing] = React37.useState({});
4925
5099
  const columnOrder = columnOrderProp ?? internalColumnOrder;
4926
5100
  const setColumnOrder = onColumnOrderChange ?? setInternalColumnOrder;
4927
- React36.useEffect(() => {
5101
+ React37.useEffect(() => {
4928
5102
  if (enableColumnDrag && columnOrder.length === 0) {
4929
5103
  const ids = columns.map((c) => {
4930
5104
  if ("accessorKey" in c && c.accessorKey) return String(c.accessorKey);
@@ -4968,7 +5142,7 @@ function DataTableInner({
4968
5142
  onRowSelectionChange: onRowSelectionChange ?? setInternalRowSelection
4969
5143
  },
4970
5144
  // Column visibility
4971
- ...enableColumnVisibility && {
5145
+ ...effectiveColumnVisibility && {
4972
5146
  onColumnVisibilityChange: onColumnVisibilityChange ?? setInternalColumnVisibility
4973
5147
  },
4974
5148
  // Column order (always wire up for drag reorder)
@@ -4997,7 +5171,7 @@ function DataTableInner({
4997
5171
  ...enableRowSelection && {
4998
5172
  rowSelection: rowSelectionProp ?? internalRowSelection
4999
5173
  },
5000
- ...enableColumnVisibility && {
5174
+ ...effectiveColumnVisibility && {
5001
5175
  columnVisibility: columnVisibilityProp ?? internalColumnVisibility
5002
5176
  },
5003
5177
  columnOrder,
@@ -5018,7 +5192,7 @@ function DataTableInner({
5018
5192
  }),
5019
5193
  (0, import_core.useSensor)(import_core.KeyboardSensor)
5020
5194
  );
5021
- const handleDragEnd = React36.useCallback(
5195
+ const handleDragEnd = React37.useCallback(
5022
5196
  (event) => {
5023
5197
  const { active, over } = event;
5024
5198
  if (!over || active.id === over.id) return;
@@ -5032,12 +5206,12 @@ function DataTableInner({
5032
5206
  },
5033
5207
  [table, setColumnOrder]
5034
5208
  );
5035
- const columnIds = React36.useMemo(
5209
+ const columnIds = React37.useMemo(
5036
5210
  () => table.getAllLeafColumns().map((c) => c.id),
5037
5211
  // eslint-disable-next-line react-hooks/exhaustive-deps
5038
5212
  [table.getAllLeafColumns().length, columnOrder]
5039
5213
  );
5040
- const columnSizeVars = React36.useMemo(() => {
5214
+ const columnSizeVars = React37.useMemo(() => {
5041
5215
  if (!enableColumnResizing) return {};
5042
5216
  const headers = table.getFlatHeaders();
5043
5217
  const vars = {};
@@ -5048,52 +5222,72 @@ function DataTableInner({
5048
5222
  return vars;
5049
5223
  }, [enableColumnResizing, table.getState().columnSizing]);
5050
5224
  const totalSize = enableColumnResizing ? table.getTotalSize() : void 0;
5051
- const tableContent = /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: cn("w-full", className), style: columnSizeVars, children: [
5052
- /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
5225
+ const tableContent = /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: cn("w-full", className), style: columnSizeVars, children: [
5226
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
5053
5227
  Table,
5054
5228
  {
5055
5229
  style: totalSize ? { width: totalSize, tableLayout: "fixed" } : void 0,
5056
5230
  className: totalSize ? "w-auto" : void 0,
5057
5231
  children: [
5058
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5232
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5059
5233
  TableHeader,
5060
5234
  {
5061
5235
  className: cn(bordered && "border-t border-table-border"),
5062
- children: table.getHeaderGroups().map((headerGroup) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(TableRow, { children: enableColumnDrag ? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5063
- import_sortable.SortableContext,
5064
- {
5065
- items: columnIds,
5066
- strategy: import_sortable.horizontalListSortingStrategy,
5067
- children: headerGroup.headers.map((header) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5068
- DraggableHeaderCell,
5069
- {
5070
- header,
5071
- enableSorting,
5072
- enableFiltering,
5073
- enableColumnResizing,
5074
- isDragEnabled: enableColumnDrag
5075
- },
5076
- header.id
5077
- ))
5078
- }
5079
- ) : headerGroup.headers.map((header) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5080
- DraggableHeaderCell,
5081
- {
5082
- header,
5083
- enableSorting,
5084
- enableFiltering,
5085
- enableColumnResizing,
5086
- isDragEnabled: false
5087
- },
5088
- header.id
5089
- )) }, headerGroup.id))
5236
+ children: table.getHeaderGroups().map((headerGroup) => /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(TableRow, { children: [
5237
+ enableColumnDrag ? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5238
+ import_sortable.SortableContext,
5239
+ {
5240
+ items: columnIds,
5241
+ strategy: import_sortable.horizontalListSortingStrategy,
5242
+ children: headerGroup.headers.map((header) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5243
+ DraggableHeaderCell,
5244
+ {
5245
+ header,
5246
+ enableSorting,
5247
+ enableFiltering,
5248
+ enableColumnResizing,
5249
+ isDragEnabled: enableColumnDrag
5250
+ },
5251
+ header.id
5252
+ ))
5253
+ }
5254
+ ) : headerGroup.headers.map((header) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5255
+ DraggableHeaderCell,
5256
+ {
5257
+ header,
5258
+ enableSorting,
5259
+ enableFiltering,
5260
+ enableColumnResizing,
5261
+ isDragEnabled: false
5262
+ },
5263
+ header.id
5264
+ )),
5265
+ enableTableSettings && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5266
+ "th",
5267
+ {
5268
+ role: "button",
5269
+ "aria-label": tableSettingsTitle ?? "Manage table",
5270
+ onClick: () => setTableSettingsOpen(true),
5271
+ className: cn(
5272
+ "sticky right-0 z-[4] w-10 min-w-10 p-0 cursor-pointer",
5273
+ "bg-table-head-bg-default border-b border-l border-table-border",
5274
+ "text-table-head-icon",
5275
+ "opacity-0 pointer-events-none",
5276
+ "transition-[opacity,color,background-color] duration-150",
5277
+ "group-hover/row:opacity-100 group-hover/row:pointer-events-auto",
5278
+ "hover:bg-table-head-bg-hover hover:text-table-cell-text-primary"
5279
+ ),
5280
+ children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "flex items-center justify-center h-full", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(import_icons24.Icon, { icon: import_icons24.faEllipsisVerticalSolid, size: "xs" }) })
5281
+ }
5282
+ )
5283
+ ] }, headerGroup.id))
5090
5284
  }
5091
5285
  ),
5092
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(TableBody, { children: table.getRowModel().rows?.length ? table.getRowModel().rows.map((row) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5286
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableBody, { children: table.getRowModel().rows?.length ? table.getRowModel().rows.map((row) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5093
5287
  TableRow,
5094
5288
  {
5095
5289
  "data-state": row.getIsSelected() ? "selected" : void 0,
5096
- children: row.getVisibleCells().map((cell) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5290
+ children: row.getVisibleCells().map((cell) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5097
5291
  TableCell,
5098
5292
  {
5099
5293
  style: enableColumnResizing ? { width: `var(--col-${cell.column.id}-size)` } : void 0,
@@ -5107,21 +5301,36 @@ function DataTableInner({
5107
5301
  ))
5108
5302
  },
5109
5303
  row.id
5110
- )) : /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(TableRow, { className: "hover:bg-transparent", children: /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5304
+ )) : /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(TableRow, { className: "hover:bg-transparent", children: /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5111
5305
  TableCell,
5112
5306
  {
5113
5307
  colSpan: columns.length,
5114
5308
  className: "h-48 text-center border-b-0",
5115
- children: emptyState ?? /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { className: "text-sm text-table-cell-text-secondary", children: emptyMessage })
5309
+ children: emptyState ?? /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "text-sm text-table-cell-text-secondary", children: emptyMessage })
5116
5310
  }
5117
5311
  ) }) })
5118
5312
  ]
5119
5313
  }
5120
5314
  ),
5121
- children?.(table)
5315
+ children?.(table),
5316
+ enableTableSettings && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5317
+ DataTableSettingsModal,
5318
+ {
5319
+ open: tableSettingsOpen,
5320
+ onOpenChange: setTableSettingsOpen,
5321
+ columns,
5322
+ columnVisibility: columnVisibilityProp ?? internalColumnVisibility,
5323
+ onApply: (next) => {
5324
+ const apply = onColumnVisibilityChange ?? setInternalColumnVisibility;
5325
+ apply(next);
5326
+ },
5327
+ lockedColumnIds,
5328
+ title: tableSettingsTitle
5329
+ }
5330
+ )
5122
5331
  ] });
5123
5332
  if (enableColumnDrag) {
5124
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5333
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5125
5334
  import_core.DndContext,
5126
5335
  {
5127
5336
  sensors,
@@ -5142,7 +5351,7 @@ function DataTablePagination({
5142
5351
  const totalCount = table.getFilteredRowModel().rows.length;
5143
5352
  const pageIndex = table.getState().pagination.pageIndex;
5144
5353
  const pageCount = table.getPageCount();
5145
- return /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)(
5354
+ return /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(
5146
5355
  "div",
5147
5356
  {
5148
5357
  className: cn(
@@ -5150,16 +5359,16 @@ function DataTablePagination({
5150
5359
  className
5151
5360
  ),
5152
5361
  children: [
5153
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("div", { className: "text-xs text-table-cell-text-secondary", children: selectedCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("span", { children: [
5362
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("div", { className: "text-xs text-table-cell-text-secondary", children: selectedCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("span", { children: [
5154
5363
  selectedCount,
5155
5364
  " of ",
5156
5365
  totalCount,
5157
5366
  " row(s) selected"
5158
5367
  ] }) }),
5159
- /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex items-center gap-lg", children: [
5160
- /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex items-center gap-sm", children: [
5161
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("span", { className: "text-xs text-table-cell-text-secondary whitespace-nowrap", children: "Rows per page" }),
5162
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5368
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: "flex items-center gap-lg", children: [
5369
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: "flex items-center gap-sm", children: [
5370
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("span", { className: "text-xs text-table-cell-text-secondary whitespace-nowrap", children: "Rows per page" }),
5371
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5163
5372
  "select",
5164
5373
  {
5165
5374
  className: cn(
@@ -5169,18 +5378,18 @@ function DataTablePagination({
5169
5378
  ),
5170
5379
  value: table.getState().pagination.pageSize,
5171
5380
  onChange: (e) => table.setPageSize(Number(e.target.value)),
5172
- children: pageSizeOptions.map((size) => /* @__PURE__ */ (0, import_jsx_runtime36.jsx)("option", { value: size, children: size }, size))
5381
+ children: pageSizeOptions.map((size) => /* @__PURE__ */ (0, import_jsx_runtime37.jsx)("option", { value: size, children: size }, size))
5173
5382
  }
5174
5383
  )
5175
5384
  ] }),
5176
- /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("span", { className: "text-xs text-table-cell-text-secondary whitespace-nowrap", children: [
5385
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("span", { className: "text-xs text-table-cell-text-secondary whitespace-nowrap", children: [
5177
5386
  "Page ",
5178
5387
  pageIndex + 1,
5179
5388
  " of ",
5180
5389
  pageCount
5181
5390
  ] }),
5182
- /* @__PURE__ */ (0, import_jsx_runtime36.jsxs)("div", { className: "flex items-center gap-xs", children: [
5183
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5391
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)("div", { className: "flex items-center gap-xs", children: [
5392
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5184
5393
  Button,
5185
5394
  {
5186
5395
  appearance: "outlined",
@@ -5192,7 +5401,7 @@ function DataTablePagination({
5192
5401
  "aria-label": "Previous page"
5193
5402
  }
5194
5403
  ),
5195
- /* @__PURE__ */ (0, import_jsx_runtime36.jsx)(
5404
+ /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5196
5405
  Button,
5197
5406
  {
5198
5407
  appearance: "outlined",
@@ -5214,15 +5423,15 @@ var DataTable = Object.assign(DataTableInner, { displayName: "DataTable" });
5214
5423
  Object.assign(DataTablePagination, { displayName: "DataTablePagination" });
5215
5424
 
5216
5425
  // src/components/ui/side-panel.tsx
5217
- var React37 = __toESM(require("react"));
5426
+ var React38 = __toESM(require("react"));
5218
5427
  var DialogPrimitive2 = __toESM(require("@radix-ui/react-dialog"));
5219
- var import_jsx_runtime37 = require("react/jsx-runtime");
5428
+ var import_jsx_runtime38 = require("react/jsx-runtime");
5220
5429
  var SidePanel = DialogPrimitive2.Root;
5221
5430
  var SidePanelTrigger = DialogPrimitive2.Trigger;
5222
5431
  var SidePanelClose = DialogPrimitive2.Close;
5223
- var SidePanelContent = React37.forwardRef(({ className, overlay = true, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime37.jsxs)(DialogPrimitive2.Portal, { children: [
5224
- overlay && /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(ModalOverlay, {}),
5225
- /* @__PURE__ */ (0, import_jsx_runtime37.jsx)(
5432
+ var SidePanelContent = React38.forwardRef(({ className, overlay = true, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(DialogPrimitive2.Portal, { children: [
5433
+ overlay && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(ModalOverlay, {}),
5434
+ /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
5226
5435
  DialogPrimitive2.Content,
5227
5436
  {
5228
5437
  ref,
@@ -5243,11 +5452,11 @@ var SidePanelContent = React37.forwardRef(({ className, overlay = true, children
5243
5452
  SidePanelContent.displayName = "SidePanelContent";
5244
5453
 
5245
5454
  // src/components/ui/filter/filter-chip-segment.tsx
5246
- var React38 = __toESM(require("react"));
5455
+ var React39 = __toESM(require("react"));
5247
5456
  var TooltipPrimitive3 = __toESM(require("@radix-ui/react-tooltip"));
5248
5457
  var import_class_variance_authority19 = require("class-variance-authority");
5249
5458
  var import_icons25 = require("@l3mpire/icons");
5250
- var import_jsx_runtime38 = require("react/jsx-runtime");
5459
+ var import_jsx_runtime39 = require("react/jsx-runtime");
5251
5460
  var filterChipSegmentVariants = (0, import_class_variance_authority19.cva)(
5252
5461
  ["flex items-center shrink-0 transition-colors"],
5253
5462
  {
@@ -5275,15 +5484,15 @@ function TruncatedLabel({
5275
5484
  truncate,
5276
5485
  className
5277
5486
  }) {
5278
- const textRef = React38.useRef(null);
5279
- const [isTruncated, setIsTruncated] = React38.useState(false);
5280
- React38.useEffect(() => {
5487
+ const textRef = React39.useRef(null);
5488
+ const [isTruncated, setIsTruncated] = React39.useState(false);
5489
+ React39.useEffect(() => {
5281
5490
  const el = textRef.current;
5282
5491
  if (el && truncate) {
5283
5492
  setIsTruncated(el.scrollWidth > el.clientWidth);
5284
5493
  }
5285
5494
  }, [label, truncate]);
5286
- const span = /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
5495
+ const span = /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
5287
5496
  "span",
5288
5497
  {
5289
5498
  ref: textRef,
@@ -5292,22 +5501,22 @@ function TruncatedLabel({
5292
5501
  }
5293
5502
  );
5294
5503
  if (!isTruncated) return span;
5295
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(TooltipPrimitive3.Provider, { delayDuration: 300, children: /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(TooltipPrimitive3.Root, { children: [
5296
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(TooltipPrimitive3.Trigger, { asChild: true, children: span }),
5297
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(TooltipPrimitive3.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
5504
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TooltipPrimitive3.Provider, { delayDuration: 300, children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(TooltipPrimitive3.Root, { children: [
5505
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TooltipPrimitive3.Trigger, { asChild: true, children: span }),
5506
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TooltipPrimitive3.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
5298
5507
  TooltipPrimitive3.Content,
5299
5508
  {
5300
5509
  sideOffset: 4,
5301
5510
  className: "z-50 px-base py-sm rounded-md shadow-lg bg-tooltip-default-bg text-tooltip-default-text text-sm font-regular leading-sm max-w-[320px] data-[state=delayed-open]:animate-[tooltip-in_150ms_ease-out] data-[state=closed]:animate-[tooltip-out_100ms_ease-in]",
5302
5511
  children: [
5303
5512
  label,
5304
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(TooltipPrimitive3.Arrow, { className: "fill-tooltip-default-bg" })
5513
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(TooltipPrimitive3.Arrow, { className: "fill-tooltip-default-bg" })
5305
5514
  ]
5306
5515
  }
5307
5516
  ) })
5308
5517
  ] }) });
5309
5518
  }
5310
- var FilterChipSegment = React38.forwardRef(
5519
+ var FilterChipSegment = React39.forwardRef(
5311
5520
  ({
5312
5521
  className,
5313
5522
  segmentType = "property",
@@ -5321,24 +5530,24 @@ var FilterChipSegment = React38.forwardRef(
5321
5530
  ...props
5322
5531
  }, ref) => {
5323
5532
  if (segmentType === "button") {
5324
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
5533
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
5325
5534
  "div",
5326
5535
  {
5327
5536
  ref,
5328
5537
  className: cn(filterChipSegmentVariants({ type: "button", hasBorder: false }), className),
5329
5538
  ...props,
5330
5539
  children: [
5331
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
5540
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
5332
5541
  "button",
5333
5542
  {
5334
5543
  type: "button",
5335
5544
  onClick: onKebabClick,
5336
5545
  className: "flex items-center justify-center p-sm cursor-pointer hover:bg-filter-chip-segment-bg-hover active:bg-filter-chip-segment-bg-pressed transition-colors",
5337
5546
  "aria-label": "Filter actions",
5338
- children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "size-5 flex items-center justify-center text-sm leading-sm text-filter-chip-kebab-text", children: /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "currentColor", children: [
5339
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("circle", { cx: "10", cy: "4.5", r: "1.5" }),
5340
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("circle", { cx: "10", cy: "10", r: "1.5" }),
5341
- /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("circle", { cx: "10", cy: "15.5", r: "1.5" })
5547
+ children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "size-5 flex items-center justify-center text-sm leading-sm text-filter-chip-kebab-text", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)("svg", { width: "20", height: "20", viewBox: "0 0 20 20", fill: "currentColor", children: [
5548
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("circle", { cx: "10", cy: "4.5", r: "1.5" }),
5549
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("circle", { cx: "10", cy: "10", r: "1.5" }),
5550
+ /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("circle", { cx: "10", cy: "15.5", r: "1.5" })
5342
5551
  ] }) })
5343
5552
  }
5344
5553
  ),
@@ -5347,7 +5556,7 @@ var FilterChipSegment = React38.forwardRef(
5347
5556
  }
5348
5557
  );
5349
5558
  }
5350
- return /* @__PURE__ */ (0, import_jsx_runtime38.jsxs)(
5559
+ return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
5351
5560
  "div",
5352
5561
  {
5353
5562
  ref,
@@ -5358,8 +5567,8 @@ var FilterChipSegment = React38.forwardRef(
5358
5567
  ),
5359
5568
  ...props,
5360
5569
  children: [
5361
- adornment && segmentType === "value" && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "shrink-0 inline-flex items-center justify-center leading-none", children: adornment }),
5362
- icon && segmentType === "property" && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
5570
+ adornment && segmentType === "value" && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "shrink-0 inline-flex items-center justify-center leading-none", children: adornment }),
5571
+ icon && segmentType === "property" && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
5363
5572
  import_icons25.Icon,
5364
5573
  {
5365
5574
  icon,
@@ -5367,7 +5576,7 @@ var FilterChipSegment = React38.forwardRef(
5367
5576
  className: "shrink-0 text-filter-chip-segment-icon"
5368
5577
  }
5369
5578
  ),
5370
- label && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)(
5579
+ label && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
5371
5580
  TruncatedLabel,
5372
5581
  {
5373
5582
  label,
@@ -5378,7 +5587,7 @@ var FilterChipSegment = React38.forwardRef(
5378
5587
  )
5379
5588
  }
5380
5589
  ),
5381
- badgeCount != null && badgeCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "flex items-center gap-2xs p-2xs rounded-xs bg-filter-chip-badge-bg", children: /* @__PURE__ */ (0, import_jsx_runtime38.jsx)("span", { className: "text-[10px] font-medium leading-2xs text-filter-chip-badge-text", children: badgeCount }) }),
5590
+ badgeCount != null && badgeCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "flex items-center gap-2xs p-2xs rounded-xs bg-filter-chip-badge-bg", children: /* @__PURE__ */ (0, import_jsx_runtime39.jsx)("span", { className: "text-[10px] font-medium leading-2xs text-filter-chip-badge-text", children: badgeCount }) }),
5382
5591
  children
5383
5592
  ]
5384
5593
  }
@@ -5388,9 +5597,9 @@ var FilterChipSegment = React38.forwardRef(
5388
5597
  FilterChipSegment.displayName = "FilterChipSegment";
5389
5598
 
5390
5599
  // src/components/ui/filter/filter-chip.tsx
5391
- var React39 = __toESM(require("react"));
5392
- var import_jsx_runtime39 = require("react/jsx-runtime");
5393
- var FilterChip = React39.forwardRef(
5600
+ var React40 = __toESM(require("react"));
5601
+ var import_jsx_runtime40 = require("react/jsx-runtime");
5602
+ var FilterChip = React40.forwardRef(
5394
5603
  ({
5395
5604
  className,
5396
5605
  icon,
@@ -5407,7 +5616,7 @@ var FilterChip = React39.forwardRef(
5407
5616
  }, ref) => {
5408
5617
  const hasOperator = !!operator;
5409
5618
  const hasValue = hasOperator && value != null;
5410
- return /* @__PURE__ */ (0, import_jsx_runtime39.jsxs)(
5619
+ return /* @__PURE__ */ (0, import_jsx_runtime40.jsxs)(
5411
5620
  "div",
5412
5621
  {
5413
5622
  ref,
@@ -5418,7 +5627,7 @@ var FilterChip = React39.forwardRef(
5418
5627
  ),
5419
5628
  ...props,
5420
5629
  children: [
5421
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
5630
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
5422
5631
  FilterChipSegment,
5423
5632
  {
5424
5633
  segmentType: "property",
@@ -5428,7 +5637,7 @@ var FilterChip = React39.forwardRef(
5428
5637
  onClick: onPropertyClick
5429
5638
  }
5430
5639
  ),
5431
- /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
5640
+ /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
5432
5641
  FilterChipSegment,
5433
5642
  {
5434
5643
  segmentType: hasOperator ? "operator" : "placeholder",
@@ -5437,7 +5646,7 @@ var FilterChip = React39.forwardRef(
5437
5646
  onClick: onOperatorClick
5438
5647
  }
5439
5648
  ),
5440
- hasOperator && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
5649
+ hasOperator && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
5441
5650
  FilterChipSegment,
5442
5651
  {
5443
5652
  segmentType: hasValue ? "value" : "placeholder",
@@ -5448,7 +5657,7 @@ var FilterChip = React39.forwardRef(
5448
5657
  onClick: onValueClick
5449
5658
  }
5450
5659
  ),
5451
- hasOperator && /* @__PURE__ */ (0, import_jsx_runtime39.jsx)(
5660
+ hasOperator && /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
5452
5661
  FilterChipSegment,
5453
5662
  {
5454
5663
  segmentType: "button",
@@ -5710,10 +5919,10 @@ function countConditions(nodes) {
5710
5919
  }
5711
5920
 
5712
5921
  // src/components/ui/filter/filter-bar.tsx
5713
- var React40 = __toESM(require("react"));
5714
- var import_jsx_runtime40 = require("react/jsx-runtime");
5715
- var FilterBar = React40.forwardRef(
5716
- ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
5922
+ var React41 = __toESM(require("react"));
5923
+ var import_jsx_runtime41 = require("react/jsx-runtime");
5924
+ var FilterBar = React41.forwardRef(
5925
+ ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
5717
5926
  "div",
5718
5927
  {
5719
5928
  ref,
@@ -5730,8 +5939,8 @@ var FilterBar = React40.forwardRef(
5730
5939
  )
5731
5940
  );
5732
5941
  FilterBar.displayName = "FilterBar";
5733
- var FilterBarLeft = React40.forwardRef(
5734
- ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
5942
+ var FilterBarLeft = React41.forwardRef(
5943
+ ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
5735
5944
  "div",
5736
5945
  {
5737
5946
  ref,
@@ -5742,8 +5951,8 @@ var FilterBarLeft = React40.forwardRef(
5742
5951
  )
5743
5952
  );
5744
5953
  FilterBarLeft.displayName = "FilterBarLeft";
5745
- var FilterBarRight = React40.forwardRef(
5746
- ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime40.jsx)(
5954
+ var FilterBarRight = React41.forwardRef(
5955
+ ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
5747
5956
  "div",
5748
5957
  {
5749
5958
  ref,
@@ -5756,11 +5965,11 @@ var FilterBarRight = React40.forwardRef(
5756
5965
  FilterBarRight.displayName = "FilterBarRight";
5757
5966
 
5758
5967
  // src/components/ui/filter/sort-button.tsx
5759
- var React41 = __toESM(require("react"));
5968
+ var React42 = __toESM(require("react"));
5760
5969
  var PopoverPrimitive3 = __toESM(require("@radix-ui/react-popover"));
5761
5970
  var import_icons26 = require("@l3mpire/icons");
5762
5971
  var import_icons27 = require("@l3mpire/icons");
5763
- var import_jsx_runtime41 = require("react/jsx-runtime");
5972
+ var import_jsx_runtime42 = require("react/jsx-runtime");
5764
5973
  var SortButton = ({
5765
5974
  className,
5766
5975
  fields,
@@ -5770,11 +5979,11 @@ var SortButton = ({
5770
5979
  iconOnly = false,
5771
5980
  ...props
5772
5981
  }) => {
5773
- const [open, setOpen] = React41.useState(false);
5982
+ const [open, setOpen] = React42.useState(false);
5774
5983
  const activeFieldDef = fields.find((f) => f.id === activeField);
5775
5984
  const activeLabel = activeFieldDef?.label ?? activeField;
5776
- return /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(PopoverPrimitive3.Root, { open, onOpenChange: setOpen, children: [
5777
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(PopoverPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(
5985
+ return /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(PopoverPrimitive3.Root, { open, onOpenChange: setOpen, children: [
5986
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(PopoverPrimitive3.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
5778
5987
  "button",
5779
5988
  {
5780
5989
  type: "button",
@@ -5789,7 +5998,7 @@ var SortButton = ({
5789
5998
  className
5790
5999
  ),
5791
6000
  children: [
5792
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
6001
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5793
6002
  import_icons26.Icon,
5794
6003
  {
5795
6004
  icon: direction === "asc" ? import_icons27.faArrowUpSmallBigOutline : import_icons27.faArrowDownBigSmallOutline,
@@ -5797,17 +6006,17 @@ var SortButton = ({
5797
6006
  className: "shrink-0 text-foreground"
5798
6007
  }
5799
6008
  ),
5800
- !iconOnly && /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap", children: [
5801
- /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("span", { className: "text-muted-foreground", children: [
6009
+ !iconOnly && /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap", children: [
6010
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("span", { className: "text-muted-foreground", children: [
5802
6011
  "Sort by",
5803
6012
  " "
5804
6013
  ] }),
5805
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("span", { className: "text-foreground", children: activeLabel })
6014
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "text-foreground", children: activeLabel })
5806
6015
  ] })
5807
6016
  ]
5808
6017
  }
5809
6018
  ) }),
5810
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(PopoverPrimitive3.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(
6019
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(PopoverPrimitive3.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
5811
6020
  PopoverPrimitive3.Content,
5812
6021
  {
5813
6022
  sideOffset: 4,
@@ -5821,7 +6030,7 @@ var SortButton = ({
5821
6030
  "min-w-[180px]"
5822
6031
  ),
5823
6032
  children: [
5824
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { className: "flex flex-col", children: fields.map((field) => /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(
6033
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: "flex flex-col", children: fields.map((field) => /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
5825
6034
  "button",
5826
6035
  {
5827
6036
  type: "button",
@@ -5835,7 +6044,7 @@ var SortButton = ({
5835
6044
  field.id === activeField ? "bg-dropdown-item-hover" : ""
5836
6045
  ),
5837
6046
  children: [
5838
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
6047
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5839
6048
  import_icons26.Icon,
5840
6049
  {
5841
6050
  icon: field.icon,
@@ -5846,7 +6055,7 @@ var SortButton = ({
5846
6055
  )
5847
6056
  }
5848
6057
  ),
5849
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
6058
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5850
6059
  "span",
5851
6060
  {
5852
6061
  className: cn(
@@ -5860,9 +6069,9 @@ var SortButton = ({
5860
6069
  },
5861
6070
  field.id
5862
6071
  )) }),
5863
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)("div", { className: "h-px bg-border" }),
5864
- /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)("div", { className: "flex flex-col", children: [
5865
- /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(
6072
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("div", { className: "h-px bg-border" }),
6073
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)("div", { className: "flex flex-col", children: [
6074
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
5866
6075
  "button",
5867
6076
  {
5868
6077
  type: "button",
@@ -5876,7 +6085,7 @@ var SortButton = ({
5876
6085
  direction === "asc" ? "bg-dropdown-item-hover" : ""
5877
6086
  ),
5878
6087
  children: [
5879
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
6088
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5880
6089
  import_icons26.Icon,
5881
6090
  {
5882
6091
  icon: import_icons27.faArrowUpSmallBigOutline,
@@ -5887,7 +6096,7 @@ var SortButton = ({
5887
6096
  )
5888
6097
  }
5889
6098
  ),
5890
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
6099
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5891
6100
  "span",
5892
6101
  {
5893
6102
  className: cn(
@@ -5900,7 +6109,7 @@ var SortButton = ({
5900
6109
  ]
5901
6110
  }
5902
6111
  ),
5903
- /* @__PURE__ */ (0, import_jsx_runtime41.jsxs)(
6112
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
5904
6113
  "button",
5905
6114
  {
5906
6115
  type: "button",
@@ -5914,7 +6123,7 @@ var SortButton = ({
5914
6123
  direction === "desc" ? "bg-dropdown-item-hover" : ""
5915
6124
  ),
5916
6125
  children: [
5917
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
6126
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5918
6127
  import_icons26.Icon,
5919
6128
  {
5920
6129
  icon: import_icons27.faArrowDownBigSmallOutline,
@@ -5925,7 +6134,7 @@ var SortButton = ({
5925
6134
  )
5926
6135
  }
5927
6136
  ),
5928
- /* @__PURE__ */ (0, import_jsx_runtime41.jsx)(
6137
+ /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
5929
6138
  "span",
5930
6139
  {
5931
6140
  className: cn(
@@ -5947,10 +6156,10 @@ var SortButton = ({
5947
6156
  SortButton.displayName = "SortButton";
5948
6157
 
5949
6158
  // src/components/ui/filter/filter-bar-button.tsx
5950
- var React42 = __toESM(require("react"));
6159
+ var React43 = __toESM(require("react"));
5951
6160
  var import_icons28 = require("@l3mpire/icons");
5952
- var import_jsx_runtime42 = require("react/jsx-runtime");
5953
- var FilterBarButton = React42.forwardRef(({ className, count, iconOnly = false, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime42.jsxs)(
6161
+ var import_jsx_runtime43 = require("react/jsx-runtime");
6162
+ var FilterBarButton = React43.forwardRef(({ className, count, iconOnly = false, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
5954
6163
  "button",
5955
6164
  {
5956
6165
  ref,
@@ -5967,7 +6176,7 @@ var FilterBarButton = React42.forwardRef(({ className, count, iconOnly = false,
5967
6176
  ),
5968
6177
  ...props,
5969
6178
  children: [
5970
- /* @__PURE__ */ (0, import_jsx_runtime42.jsx)(
6179
+ /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
5971
6180
  import_icons28.Icon,
5972
6181
  {
5973
6182
  icon: import_icons28.faFilterOutline,
@@ -5975,18 +6184,18 @@ var FilterBarButton = React42.forwardRef(({ className, count, iconOnly = false,
5975
6184
  className: "shrink-0 text-foreground"
5976
6185
  }
5977
6186
  ),
5978
- !iconOnly && /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap text-foreground", children: children ?? "Filters" }),
5979
- count != null && count > 0 && /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "flex items-center p-2xs rounded-xs bg-filter-chip-badge-bg", children: /* @__PURE__ */ (0, import_jsx_runtime42.jsx)("span", { className: "text-[10px] font-medium leading-2xs text-filter-chip-badge-text", children: count }) })
6187
+ !iconOnly && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap text-foreground", children: children ?? "Filters" }),
6188
+ count != null && count > 0 && /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "flex items-center p-2xs rounded-xs bg-filter-chip-badge-bg", children: /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "text-[10px] font-medium leading-2xs text-filter-chip-badge-text", children: count }) })
5980
6189
  ]
5981
6190
  }
5982
6191
  ));
5983
6192
  FilterBarButton.displayName = "FilterBarButton";
5984
6193
 
5985
6194
  // src/components/ui/filter/save-view-button.tsx
5986
- var React43 = __toESM(require("react"));
6195
+ var React44 = __toESM(require("react"));
5987
6196
  var import_icons29 = require("@l3mpire/icons");
5988
- var import_jsx_runtime43 = require("react/jsx-runtime");
5989
- var SaveViewButton = React43.forwardRef(
6197
+ var import_jsx_runtime44 = require("react/jsx-runtime");
6198
+ var SaveViewButton = React44.forwardRef(
5990
6199
  ({ className, label = "Save view", onSave, onDropdown, ...props }, ref) => {
5991
6200
  const sharedStyle = [
5992
6201
  "relative flex items-center justify-center",
@@ -5996,14 +6205,14 @@ var SaveViewButton = React43.forwardRef(
5996
6205
  "shadow-sm cursor-pointer transition-colors",
5997
6206
  "hover:from-btn-solid-brand-bg-hover hover:to-btn-solid-brand-bg-gradient-to-hover"
5998
6207
  ];
5999
- return /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
6208
+ return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
6000
6209
  "div",
6001
6210
  {
6002
6211
  ref,
6003
6212
  className: cn("flex items-center", className),
6004
6213
  ...props,
6005
6214
  children: [
6006
- /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
6215
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
6007
6216
  "button",
6008
6217
  {
6009
6218
  type: "button",
@@ -6014,12 +6223,12 @@ var SaveViewButton = React43.forwardRef(
6014
6223
  "rounded-l-md -mr-px"
6015
6224
  ),
6016
6225
  children: [
6017
- /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap text-btn-solid-brand-text-default", children: label }),
6018
- /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "absolute inset-0 rounded-l-[11px] border border-btn-solid-brand-inner-border-default shadow-sm pointer-events-none" })
6226
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap text-btn-solid-brand-text-default", children: label }),
6227
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "absolute inset-0 rounded-l-[11px] border border-btn-solid-brand-inner-border-default shadow-sm pointer-events-none" })
6019
6228
  ]
6020
6229
  }
6021
6230
  ),
6022
- /* @__PURE__ */ (0, import_jsx_runtime43.jsxs)(
6231
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
6023
6232
  "button",
6024
6233
  {
6025
6234
  type: "button",
@@ -6030,7 +6239,7 @@ var SaveViewButton = React43.forwardRef(
6030
6239
  "rounded-r-md -ml-px"
6031
6240
  ),
6032
6241
  children: [
6033
- /* @__PURE__ */ (0, import_jsx_runtime43.jsx)(
6242
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
6034
6243
  import_icons29.Icon,
6035
6244
  {
6036
6245
  icon: import_icons29.faChevronDownOutline,
@@ -6038,7 +6247,7 @@ var SaveViewButton = React43.forwardRef(
6038
6247
  className: "text-btn-solid-brand-text-default"
6039
6248
  }
6040
6249
  ),
6041
- /* @__PURE__ */ (0, import_jsx_runtime43.jsx)("span", { className: "absolute inset-0 rounded-r-[11px] border border-btn-solid-brand-inner-border-default shadow-sm pointer-events-none" })
6250
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "absolute inset-0 rounded-r-[11px] border border-btn-solid-brand-inner-border-default shadow-sm pointer-events-none" })
6042
6251
  ]
6043
6252
  }
6044
6253
  )
@@ -6051,7 +6260,7 @@ SaveViewButton.displayName = "SaveViewButton";
6051
6260
 
6052
6261
  // src/components/ui/filter/operator-selector.tsx
6053
6262
  var PopoverPrimitive4 = __toESM(require("@radix-ui/react-popover"));
6054
- var import_jsx_runtime44 = require("react/jsx-runtime");
6263
+ var import_jsx_runtime45 = require("react/jsx-runtime");
6055
6264
  var OperatorSelector = ({
6056
6265
  dataType,
6057
6266
  activeOperator,
@@ -6061,9 +6270,9 @@ var OperatorSelector = ({
6061
6270
  children
6062
6271
  }) => {
6063
6272
  const operators = OPERATORS_BY_TYPE[dataType];
6064
- return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(PopoverPrimitive4.Root, { open, onOpenChange, children: [
6065
- /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(PopoverPrimitive4.Trigger, { asChild: true, children }),
6066
- /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(PopoverPrimitive4.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
6273
+ return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(PopoverPrimitive4.Root, { open, onOpenChange, children: [
6274
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(PopoverPrimitive4.Trigger, { asChild: true, children }),
6275
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(PopoverPrimitive4.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
6067
6276
  PopoverPrimitive4.Content,
6068
6277
  {
6069
6278
  sideOffset: 4,
@@ -6076,7 +6285,7 @@ var OperatorSelector = ({
6076
6285
  "data-[side=bottom]:slide-in-from-top-2",
6077
6286
  "min-w-[180px]"
6078
6287
  ),
6079
- children: operators.map((op) => /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
6288
+ children: operators.map((op) => /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)(
6080
6289
  "button",
6081
6290
  {
6082
6291
  type: "button",
@@ -6087,7 +6296,7 @@ var OperatorSelector = ({
6087
6296
  op === activeOperator && "bg-dropdown-item-hover"
6088
6297
  ),
6089
6298
  children: [
6090
- /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
6299
+ /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
6091
6300
  "span",
6092
6301
  {
6093
6302
  className: cn(
@@ -6097,7 +6306,7 @@ var OperatorSelector = ({
6097
6306
  children: op
6098
6307
  }
6099
6308
  ),
6100
- isNoValueOperator(op) && /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("span", { className: "ml-auto text-xs text-muted-foreground", children: "instant" })
6309
+ isNoValueOperator(op) && /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("span", { className: "ml-auto text-xs text-muted-foreground", children: "instant" })
6101
6310
  ]
6102
6311
  },
6103
6312
  op
@@ -6113,7 +6322,7 @@ var OperatorList = ({
6113
6322
  onSelect
6114
6323
  }) => {
6115
6324
  const operators = OPERATORS_BY_TYPE[dataType];
6116
- return /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("div", { className: "flex flex-col", children: operators.map((op) => /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
6325
+ return /* @__PURE__ */ (0, import_jsx_runtime45.jsx)("div", { className: "flex flex-col", children: operators.map((op) => /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
6117
6326
  "button",
6118
6327
  {
6119
6328
  type: "button",
@@ -6123,7 +6332,7 @@ var OperatorList = ({
6123
6332
  "hover:bg-dropdown-item-hover",
6124
6333
  op === activeOperator && "bg-dropdown-item-hover"
6125
6334
  ),
6126
- children: /* @__PURE__ */ (0, import_jsx_runtime44.jsx)(
6335
+ children: /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
6127
6336
  "span",
6128
6337
  {
6129
6338
  className: cn(
@@ -6153,7 +6362,7 @@ var halfInputClasses = [
6153
6362
  ].join(" ");
6154
6363
 
6155
6364
  // src/components/ui/filter/value-inputs/text-value-input.tsx
6156
- var import_jsx_runtime45 = require("react/jsx-runtime");
6365
+ var import_jsx_runtime46 = require("react/jsx-runtime");
6157
6366
  var TextValueInput = ({
6158
6367
  value,
6159
6368
  onChange,
@@ -6163,8 +6372,8 @@ var TextValueInput = ({
6163
6372
  const handleKeyDown = (e) => {
6164
6373
  if (e.key === "Enter") onSubmit?.();
6165
6374
  };
6166
- return /* @__PURE__ */ (0, import_jsx_runtime45.jsxs)("div", { className: cn("flex flex-col gap-base p-xs", className), children: [
6167
- /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(
6375
+ return /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("div", { className: cn("flex flex-col gap-base p-xs", className), children: [
6376
+ /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
6168
6377
  "input",
6169
6378
  {
6170
6379
  type: "text",
@@ -6176,13 +6385,13 @@ var TextValueInput = ({
6176
6385
  className: inputClasses
6177
6386
  }
6178
6387
  ),
6179
- /* @__PURE__ */ (0, import_jsx_runtime45.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
6388
+ /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
6180
6389
  ] });
6181
6390
  };
6182
6391
  TextValueInput.displayName = "TextValueInput";
6183
6392
 
6184
6393
  // src/components/ui/filter/value-inputs/number-value-input.tsx
6185
- var import_jsx_runtime46 = require("react/jsx-runtime");
6394
+ var import_jsx_runtime47 = require("react/jsx-runtime");
6186
6395
  var NumberValueInput = ({
6187
6396
  value,
6188
6397
  onChange,
@@ -6192,8 +6401,8 @@ var NumberValueInput = ({
6192
6401
  const handleKeyDown = (e) => {
6193
6402
  if (e.key === "Enter") onSubmit?.();
6194
6403
  };
6195
- return /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("div", { className: cn("flex flex-col gap-base p-xs", className), children: [
6196
- /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
6404
+ return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: cn("flex flex-col gap-base p-xs", className), children: [
6405
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6197
6406
  "input",
6198
6407
  {
6199
6408
  type: "number",
@@ -6205,7 +6414,7 @@ var NumberValueInput = ({
6205
6414
  className: inputClasses
6206
6415
  }
6207
6416
  ),
6208
- /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
6417
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
6209
6418
  ] });
6210
6419
  };
6211
6420
  NumberValueInput.displayName = "NumberValueInput";
@@ -6216,9 +6425,9 @@ var NumberRangeValueInput = ({
6216
6425
  className
6217
6426
  }) => {
6218
6427
  const rangeVal = value ?? [0, 0];
6219
- return /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("div", { className: cn("flex flex-col gap-base p-xs", className), children: [
6220
- /* @__PURE__ */ (0, import_jsx_runtime46.jsxs)("div", { className: "flex items-center gap-base", children: [
6221
- /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
6428
+ return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: cn("flex flex-col gap-base p-xs", className), children: [
6429
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex items-center gap-base", children: [
6430
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6222
6431
  "input",
6223
6432
  {
6224
6433
  type: "number",
@@ -6229,8 +6438,8 @@ var NumberRangeValueInput = ({
6229
6438
  className: halfInputClasses
6230
6439
  }
6231
6440
  ),
6232
- /* @__PURE__ */ (0, import_jsx_runtime46.jsx)("span", { className: "text-sm text-muted-foreground", children: "and" }),
6233
- /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
6441
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "text-sm text-muted-foreground", children: "and" }),
6442
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6234
6443
  "input",
6235
6444
  {
6236
6445
  type: "number",
@@ -6241,19 +6450,19 @@ var NumberRangeValueInput = ({
6241
6450
  }
6242
6451
  )
6243
6452
  ] }),
6244
- /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
6453
+ /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
6245
6454
  ] });
6246
6455
  };
6247
6456
  NumberRangeValueInput.displayName = "NumberRangeValueInput";
6248
6457
 
6249
6458
  // src/components/ui/filter/value-inputs/date-value-input.tsx
6250
- var React45 = __toESM(require("react"));
6459
+ var React46 = __toESM(require("react"));
6251
6460
 
6252
6461
  // src/components/ui/date-picker.tsx
6253
- var React44 = __toESM(require("react"));
6462
+ var React45 = __toESM(require("react"));
6254
6463
  var PopoverPrimitive5 = __toESM(require("@radix-ui/react-popover"));
6255
6464
  var import_icons30 = require("@l3mpire/icons");
6256
- var import_jsx_runtime47 = require("react/jsx-runtime");
6465
+ var import_jsx_runtime48 = require("react/jsx-runtime");
6257
6466
  function getDaysInMonth(year, month) {
6258
6467
  return new Date(year, month + 1, 0).getDate();
6259
6468
  }
@@ -6285,16 +6494,16 @@ var MONTH_NAMES = [
6285
6494
  "November",
6286
6495
  "December"
6287
6496
  ];
6288
- var DatePickerContext = React44.createContext(
6497
+ var DatePickerContext = React45.createContext(
6289
6498
  null
6290
6499
  );
6291
6500
  function useDatePickerContext() {
6292
- const ctx = React44.useContext(DatePickerContext);
6501
+ const ctx = React45.useContext(DatePickerContext);
6293
6502
  if (!ctx)
6294
6503
  throw new Error("DatePicker compound components must be used within <DatePicker>");
6295
6504
  return ctx;
6296
6505
  }
6297
- var DatePicker = React44.forwardRef(
6506
+ var DatePicker = React45.forwardRef(
6298
6507
  ({
6299
6508
  className,
6300
6509
  mode = "single",
@@ -6305,22 +6514,22 @@ var DatePicker = React44.forwardRef(
6305
6514
  children,
6306
6515
  ...props
6307
6516
  }, ref) => {
6308
- const today = React44.useMemo(() => startOfDay(/* @__PURE__ */ new Date()), []);
6309
- const initialDate = React44.useMemo(() => {
6517
+ const today = React45.useMemo(() => startOfDay(/* @__PURE__ */ new Date()), []);
6518
+ const initialDate = React45.useMemo(() => {
6310
6519
  if (value) {
6311
6520
  if (value instanceof Date) return value;
6312
6521
  return value.from;
6313
6522
  }
6314
6523
  return today;
6315
6524
  }, []);
6316
- const [month, setMonth] = React44.useState(
6525
+ const [month, setMonth] = React45.useState(
6317
6526
  defaultMonth ?? initialDate.getMonth()
6318
6527
  );
6319
- const [year, setYear] = React44.useState(
6528
+ const [year, setYear] = React45.useState(
6320
6529
  defaultYear ?? initialDate.getFullYear()
6321
6530
  );
6322
- const [hoveredDate, setHoveredDate] = React44.useState();
6323
- const goToPrevMonth = React44.useCallback(() => {
6531
+ const [hoveredDate, setHoveredDate] = React45.useState();
6532
+ const goToPrevMonth = React45.useCallback(() => {
6324
6533
  setMonth((m) => {
6325
6534
  if (m === 0) {
6326
6535
  setYear((y) => y - 1);
@@ -6329,7 +6538,7 @@ var DatePicker = React44.forwardRef(
6329
6538
  return m - 1;
6330
6539
  });
6331
6540
  }, []);
6332
- const goToNextMonth = React44.useCallback(() => {
6541
+ const goToNextMonth = React45.useCallback(() => {
6333
6542
  setMonth((m) => {
6334
6543
  if (m === 11) {
6335
6544
  setYear((y) => y + 1);
@@ -6338,7 +6547,7 @@ var DatePicker = React44.forwardRef(
6338
6547
  return m + 1;
6339
6548
  });
6340
6549
  }, []);
6341
- const onSelect = React44.useCallback(
6550
+ const onSelect = React45.useCallback(
6342
6551
  (date) => {
6343
6552
  if (mode === "single") {
6344
6553
  onValueChange?.(date);
@@ -6357,7 +6566,7 @@ var DatePicker = React44.forwardRef(
6357
6566
  },
6358
6567
  [mode, value, onValueChange]
6359
6568
  );
6360
- const ctxValue = React44.useMemo(
6569
+ const ctxValue = React45.useMemo(
6361
6570
  () => ({
6362
6571
  mode,
6363
6572
  selected: value,
@@ -6384,7 +6593,7 @@ var DatePicker = React44.forwardRef(
6384
6593
  hoveredDate
6385
6594
  ]
6386
6595
  );
6387
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(DatePickerContext.Provider, { value: ctxValue, children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6596
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(DatePickerContext.Provider, { value: ctxValue, children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6388
6597
  "div",
6389
6598
  {
6390
6599
  ref,
@@ -6407,22 +6616,22 @@ function defaultFormatDate(date) {
6407
6616
  year: "numeric"
6408
6617
  });
6409
6618
  }
6410
- var DatePickerSelects = React44.forwardRef(({ className, formatDate = defaultFormatDate, ...props }, ref) => {
6619
+ var DatePickerSelects = React45.forwardRef(({ className, formatDate = defaultFormatDate, ...props }, ref) => {
6411
6620
  const { selected } = useDatePickerContext();
6412
6621
  const fromDate = selected instanceof Date ? selected : selected?.from;
6413
6622
  const toDate = selected instanceof Date ? void 0 : selected?.to;
6414
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6623
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6415
6624
  "div",
6416
6625
  {
6417
6626
  ref,
6418
6627
  className: cn("flex flex-col items-start pt-lg px-lg", className),
6419
6628
  ...props,
6420
- children: /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex items-center gap-base w-full", children: [
6421
- /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex-1 flex items-center gap-base min-w-0 px-base py-sm bg-gradient-to-t from-[var(--color-select-bg-default)] to-[var(--color-select-bg-gradient-to)] border border-[var(--color-select-border-default)] rounded-base shadow-sm", children: [
6422
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-datepicker-header-text truncate", children: fromDate ? formatDate(fromDate) : "Start date" }),
6423
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_icons30.Icon, { icon: import_icons30.faCalendarOutline, size: "sm", className: "shrink-0 text-datepicker-header-text" })
6629
+ children: /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)("div", { className: "flex items-center gap-base w-full", children: [
6630
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)("div", { className: "flex-1 flex items-center gap-base min-w-0 px-base py-sm bg-gradient-to-t from-[var(--color-select-bg-default)] to-[var(--color-select-bg-gradient-to)] border border-[var(--color-select-border-default)] rounded-base shadow-sm", children: [
6631
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-datepicker-header-text truncate", children: fromDate ? formatDate(fromDate) : "Start date" }),
6632
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(import_icons30.Icon, { icon: import_icons30.faCalendarOutline, size: "sm", className: "shrink-0 text-datepicker-header-text" })
6424
6633
  ] }),
6425
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6634
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6426
6635
  import_icons30.Icon,
6427
6636
  {
6428
6637
  icon: import_icons30.faArrowRightOutline,
@@ -6430,9 +6639,9 @@ var DatePickerSelects = React44.forwardRef(({ className, formatDate = defaultFor
6430
6639
  className: "shrink-0 text-datepicker-header-weekday"
6431
6640
  }
6432
6641
  ),
6433
- /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex-1 flex items-center gap-base min-w-0 px-base py-sm bg-gradient-to-t from-[var(--color-select-bg-default)] to-[var(--color-select-bg-gradient-to)] border border-[var(--color-select-border-default)] rounded-base shadow-sm", children: [
6434
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-datepicker-header-text truncate", children: toDate ? formatDate(toDate) : "End date" }),
6435
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_icons30.Icon, { icon: import_icons30.faCalendarOutline, size: "sm", className: "shrink-0 text-datepicker-header-text" })
6642
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)("div", { className: "flex-1 flex items-center gap-base min-w-0 px-base py-sm bg-gradient-to-t from-[var(--color-select-bg-default)] to-[var(--color-select-bg-gradient-to)] border border-[var(--color-select-border-default)] rounded-base shadow-sm", children: [
6643
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-datepicker-header-text truncate", children: toDate ? formatDate(toDate) : "End date" }),
6644
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(import_icons30.Icon, { icon: import_icons30.faCalendarOutline, size: "sm", className: "shrink-0 text-datepicker-header-text" })
6436
6645
  ] })
6437
6646
  ] })
6438
6647
  }
@@ -6448,7 +6657,7 @@ var DatePickerDay = ({ date, isOutside }) => {
6448
6657
  const inRange = mode === "range" && selected && !(selected instanceof Date) && selected.from && selected.to && !isSelected && isInRange(date, selected.from, selected.to);
6449
6658
  const inPreviewRange = mode === "range" && selected && !(selected instanceof Date) && selected.from && !selected.to && hoveredDate && !isSelected && hoveredDate.getTime() > selected.from.getTime() && isInRange(date, selected.from, hoveredDate);
6450
6659
  const isInRangeOrPreview = inRange || inPreviewRange;
6451
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(
6660
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
6452
6661
  "button",
6453
6662
  {
6454
6663
  type: "button",
@@ -6472,14 +6681,14 @@ var DatePickerDay = ({ date, isOutside }) => {
6472
6681
  ),
6473
6682
  children: [
6474
6683
  date.getDate(),
6475
- isToday && !isOutside && /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "absolute bottom-0.5 left-1/2 -translate-x-1/2 size-1.5 rounded-full bg-datepicker-day-today" })
6684
+ isToday && !isOutside && /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "absolute bottom-0.5 left-1/2 -translate-x-1/2 size-1.5 rounded-full bg-datepicker-day-today" })
6476
6685
  ]
6477
6686
  }
6478
6687
  );
6479
6688
  };
6480
- var DatePickerCalendar = React44.forwardRef(({ className, header, ...props }, ref) => {
6689
+ var DatePickerCalendar = React45.forwardRef(({ className, header, ...props }, ref) => {
6481
6690
  const { month, year, goToPrevMonth, goToNextMonth } = useDatePickerContext();
6482
- const weeks = React44.useMemo(() => {
6691
+ const weeks = React45.useMemo(() => {
6483
6692
  const firstDay = new Date(year, month, 1);
6484
6693
  const startOffset = getWeekdayIndex(firstDay);
6485
6694
  const daysInMonth = getDaysInMonth(year, month);
@@ -6519,7 +6728,7 @@ var DatePickerCalendar = React44.forwardRef(({ className, header, ...props }, re
6519
6728
  }
6520
6729
  return result;
6521
6730
  }, [month, year]);
6522
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(
6731
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
6523
6732
  "div",
6524
6733
  {
6525
6734
  ref,
@@ -6527,38 +6736,38 @@ var DatePickerCalendar = React44.forwardRef(({ className, header, ...props }, re
6527
6736
  ...props,
6528
6737
  children: [
6529
6738
  header,
6530
- /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex flex-col gap-lg p-lg", children: [
6531
- /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex items-center justify-between", children: [
6532
- /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("span", { className: "text-base font-medium leading-base text-datepicker-header-text", children: [
6739
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)("div", { className: "flex flex-col gap-lg p-lg", children: [
6740
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)("div", { className: "flex items-center justify-between", children: [
6741
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)("span", { className: "text-base font-medium leading-base text-datepicker-header-text", children: [
6533
6742
  MONTH_NAMES[month],
6534
6743
  " ",
6535
6744
  year
6536
6745
  ] }),
6537
- /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex items-center gap-xs", children: [
6538
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6746
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)("div", { className: "flex items-center gap-xs", children: [
6747
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6539
6748
  "button",
6540
6749
  {
6541
6750
  type: "button",
6542
6751
  onClick: goToPrevMonth,
6543
6752
  className: "flex items-center justify-center p-xs rounded-base hover:bg-datepicker-day-bg-hover transition-colors cursor-pointer",
6544
6753
  "aria-label": "Previous month",
6545
- children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_icons30.Icon, { icon: import_icons30.faChevronLeftOutline, size: "xs", className: "text-datepicker-header-nav" })
6754
+ children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(import_icons30.Icon, { icon: import_icons30.faChevronLeftOutline, size: "xs", className: "text-datepicker-header-nav" })
6546
6755
  }
6547
6756
  ),
6548
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6757
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6549
6758
  "button",
6550
6759
  {
6551
6760
  type: "button",
6552
6761
  onClick: goToNextMonth,
6553
6762
  className: "flex items-center justify-center p-xs rounded-base hover:bg-datepicker-day-bg-hover transition-colors cursor-pointer",
6554
6763
  "aria-label": "Next month",
6555
- children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(import_icons30.Icon, { icon: import_icons30.faChevronRightOutline, size: "xs", className: "text-datepicker-header-nav" })
6764
+ children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(import_icons30.Icon, { icon: import_icons30.faChevronRightOutline, size: "xs", className: "text-datepicker-header-nav" })
6556
6765
  }
6557
6766
  )
6558
6767
  ] })
6559
6768
  ] }),
6560
- /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)("div", { className: "flex flex-col", children: [
6561
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "grid grid-cols-7 gap-base py-sm", children: WEEKDAYS.map((day) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6769
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)("div", { className: "flex flex-col", children: [
6770
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "grid grid-cols-7 gap-base py-sm", children: WEEKDAYS.map((day) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6562
6771
  "span",
6563
6772
  {
6564
6773
  className: "w-9 text-center text-xs font-regular leading-xs text-datepicker-header-weekday",
@@ -6566,7 +6775,7 @@ var DatePickerCalendar = React44.forwardRef(({ className, header, ...props }, re
6566
6775
  },
6567
6776
  day
6568
6777
  )) }),
6569
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "flex flex-col", children: weeks.map((week, wi) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "grid grid-cols-7 gap-base", children: week.map((day, di) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6778
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "flex flex-col", children: weeks.map((week, wi) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "grid grid-cols-7 gap-base", children: week.map((day, di) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6570
6779
  DatePickerDay,
6571
6780
  {
6572
6781
  date: day.date,
@@ -6581,10 +6790,10 @@ var DatePickerCalendar = React44.forwardRef(({ className, header, ...props }, re
6581
6790
  );
6582
6791
  });
6583
6792
  DatePickerCalendar.displayName = "DatePickerCalendar";
6584
- var DatePickerSuggestions = React44.forwardRef(
6793
+ var DatePickerSuggestions = React45.forwardRef(
6585
6794
  ({ className, suggestions, formatDate = defaultFormatDate, ...props }, ref) => {
6586
6795
  const { onSelect, mode } = useDatePickerContext();
6587
- const onValueChange = React44.useContext(DatePickerContext) ? void 0 : void 0;
6796
+ const onValueChange = React45.useContext(DatePickerContext) ? void 0 : void 0;
6588
6797
  const ctx = useDatePickerContext();
6589
6798
  const handleClick = (suggestion) => {
6590
6799
  const val = suggestion.getValue();
@@ -6606,7 +6815,7 @@ var DatePickerSuggestions = React44.forwardRef(
6606
6815
  const to = val.to ? formatDate(val.to) : "";
6607
6816
  return to ? `${from} - ${to}` : from;
6608
6817
  };
6609
- return /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(
6818
+ return /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
6610
6819
  "div",
6611
6820
  {
6612
6821
  ref,
@@ -6616,16 +6825,16 @@ var DatePickerSuggestions = React44.forwardRef(
6616
6825
  ),
6617
6826
  ...props,
6618
6827
  children: [
6619
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "pt-lg px-base", children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "flex items-center p-base rounded-base", children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "flex-1 text-xs font-medium leading-xs text-datepicker-suggestion-heading uppercase truncate", children: "Suggestions" }) }) }),
6620
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("div", { className: "flex flex-1 flex-col p-base min-w-[222px]", children: suggestions.map((suggestion, i) => /* @__PURE__ */ (0, import_jsx_runtime47.jsxs)(
6828
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "pt-lg px-base", children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "flex items-center p-base rounded-base", children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "flex-1 text-xs font-medium leading-xs text-datepicker-suggestion-heading uppercase truncate", children: "Suggestions" }) }) }),
6829
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "flex flex-1 flex-col p-base min-w-[222px]", children: suggestions.map((suggestion, i) => /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
6621
6830
  "button",
6622
6831
  {
6623
6832
  type: "button",
6624
6833
  onClick: () => handleClick(suggestion),
6625
6834
  className: "flex items-center gap-sm p-base rounded-base hover:bg-datepicker-suggestion-hover transition-colors cursor-pointer text-left",
6626
6835
  children: [
6627
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "text-sm font-regular leading-sm text-datepicker-suggestion-text truncate shrink-0", children: suggestion.label }),
6628
- /* @__PURE__ */ (0, import_jsx_runtime47.jsx)("span", { className: "text-xs font-regular leading-xs text-datepicker-suggestion-date truncate", children: formatSuggestionDate(suggestion) })
6836
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "text-sm font-regular leading-sm text-datepicker-suggestion-text truncate shrink-0", children: suggestion.label }),
6837
+ /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "text-xs font-regular leading-xs text-datepicker-suggestion-date truncate", children: formatSuggestionDate(suggestion) })
6629
6838
  ]
6630
6839
  },
6631
6840
  i
@@ -6636,8 +6845,8 @@ var DatePickerSuggestions = React44.forwardRef(
6636
6845
  }
6637
6846
  );
6638
6847
  DatePickerSuggestions.displayName = "DatePickerSuggestions";
6639
- var DatePickerFooter = React44.forwardRef(
6640
- ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6848
+ var DatePickerFooter = React45.forwardRef(
6849
+ ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6641
6850
  "div",
6642
6851
  {
6643
6852
  ref,
@@ -6653,8 +6862,8 @@ var DatePickerFooter = React44.forwardRef(
6653
6862
  )
6654
6863
  );
6655
6864
  DatePickerFooter.displayName = "DatePickerFooter";
6656
- var DatePickerPanel = React44.forwardRef(
6657
- ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6865
+ var DatePickerPanel = React45.forwardRef(
6866
+ ({ className, children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6658
6867
  "div",
6659
6868
  {
6660
6869
  ref,
@@ -6667,7 +6876,7 @@ var DatePickerPanel = React44.forwardRef(
6667
6876
  DatePickerPanel.displayName = "DatePickerPanel";
6668
6877
  var DatePickerRoot = PopoverPrimitive5.Root;
6669
6878
  var DatePickerTrigger = PopoverPrimitive5.Trigger;
6670
- var DatePickerPopover = React44.forwardRef(({ className, sideOffset = 4, align = "start", children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(PopoverPrimitive5.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime47.jsx)(
6879
+ var DatePickerPopover = React45.forwardRef(({ className, sideOffset = 4, align = "start", children, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(PopoverPrimitive5.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
6671
6880
  PopoverPrimitive5.Content,
6672
6881
  {
6673
6882
  ref,
@@ -6743,7 +6952,7 @@ function getDefaultSuggestions(referenceDate) {
6743
6952
  }
6744
6953
 
6745
6954
  // src/components/ui/filter/value-inputs/date-value-input.tsx
6746
- var import_jsx_runtime48 = require("react/jsx-runtime");
6955
+ var import_jsx_runtime49 = require("react/jsx-runtime");
6747
6956
  var RELATIVE_DATE_PRESETS = [
6748
6957
  { group: "Past", options: ["Today", "Yesterday", "Last 7 days", "Last 14 days", "Last 30 days", "Last 90 days"] },
6749
6958
  { group: "Current", options: ["This week", "This month", "This quarter", "This year"] },
@@ -6757,7 +6966,7 @@ var DateCalendarValueInput = ({
6757
6966
  className
6758
6967
  }) => {
6759
6968
  const isRange = operator === "is between";
6760
- const pickerValue = React45.useMemo(() => {
6969
+ const pickerValue = React46.useMemo(() => {
6761
6970
  if (isRange) {
6762
6971
  if (Array.isArray(value) && value.length === 2) {
6763
6972
  const [from, to] = value;
@@ -6782,22 +6991,22 @@ var DateCalendarValueInput = ({
6782
6991
  }
6783
6992
  }
6784
6993
  };
6785
- const suggestions = React45.useMemo(() => getDefaultSuggestions(), []);
6786
- return /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: cn("flex flex-col", className), children: /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(
6994
+ const suggestions = React46.useMemo(() => getDefaultSuggestions(), []);
6995
+ return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("div", { className: cn("flex flex-col", className), children: /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
6787
6996
  DatePicker,
6788
6997
  {
6789
6998
  mode: isRange ? "range" : "single",
6790
6999
  value: pickerValue,
6791
7000
  onValueChange: handleValueChange,
6792
7001
  children: [
6793
- isRange && /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(DatePickerSelects, {}),
6794
- isRange ? /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(DatePickerPanel, { children: [
6795
- /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(DatePickerCalendar, {}),
6796
- /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(DatePickerSuggestions, { suggestions })
6797
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(DatePickerCalendar, {}),
6798
- isRange && /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)(DatePickerFooter, { children: [
6799
- /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", {}),
6800
- /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", onClick: onSubmit, children: "Apply" })
7002
+ isRange && /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DatePickerSelects, {}),
7003
+ isRange ? /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(DatePickerPanel, { children: [
7004
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DatePickerCalendar, {}),
7005
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DatePickerSuggestions, { suggestions })
7006
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(DatePickerCalendar, {}),
7007
+ isRange && /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(DatePickerFooter, { children: [
7008
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("div", {}),
7009
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", onClick: onSubmit, children: "Apply" })
6801
7010
  ] })
6802
7011
  ]
6803
7012
  }
@@ -6809,9 +7018,9 @@ var PresetTagsValueInput = ({
6809
7018
  onChange,
6810
7019
  onSubmit,
6811
7020
  className
6812
- }) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: cn("flex flex-col gap-base p-xs max-w-[280px]", className), children: RELATIVE_DATE_PRESETS.map((group) => /* @__PURE__ */ (0, import_jsx_runtime48.jsxs)("div", { className: "flex flex-col gap-xs", children: [
6813
- /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground uppercase px-xs", children: group.group }),
6814
- /* @__PURE__ */ (0, import_jsx_runtime48.jsx)("div", { className: "flex flex-wrap gap-xs", children: group.options.map((preset) => /* @__PURE__ */ (0, import_jsx_runtime48.jsx)(
7021
+ }) => /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("div", { className: cn("flex flex-col gap-base p-xs max-w-[280px]", className), children: RELATIVE_DATE_PRESETS.map((group) => /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "flex flex-col gap-xs", children: [
7022
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground uppercase px-xs", children: group.group }),
7023
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("div", { className: "flex flex-wrap gap-xs", children: group.options.map((preset) => /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
6815
7024
  "button",
6816
7025
  {
6817
7026
  type: "button",
@@ -6832,7 +7041,7 @@ PresetTagsValueInput.displayName = "PresetTagsValueInput";
6832
7041
 
6833
7042
  // src/components/ui/filter/value-inputs/select-value-input.tsx
6834
7043
  var import_icons31 = require("@l3mpire/icons");
6835
- var import_jsx_runtime49 = require("react/jsx-runtime");
7044
+ var import_jsx_runtime50 = require("react/jsx-runtime");
6836
7045
  var intentDotClass = {
6837
7046
  primary: "bg-primary",
6838
7047
  success: "bg-success",
@@ -6840,7 +7049,7 @@ var intentDotClass = {
6840
7049
  critical: "bg-destructive",
6841
7050
  neutral: "bg-muted-foreground"
6842
7051
  };
6843
- var IntentDot = ({ intent }) => /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
7052
+ var IntentDot = ({ intent }) => /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
6844
7053
  "span",
6845
7054
  {
6846
7055
  className: cn(
@@ -6852,7 +7061,7 @@ var IntentDot = ({ intent }) => /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
6852
7061
  );
6853
7062
  var OptionLeading = ({ option }) => {
6854
7063
  if (option.icon) {
6855
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
7064
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
6856
7065
  import_icons31.Icon,
6857
7066
  {
6858
7067
  icon: option.icon,
@@ -6862,7 +7071,7 @@ var OptionLeading = ({ option }) => {
6862
7071
  );
6863
7072
  }
6864
7073
  if (option.intent) {
6865
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(IntentDot, { intent: option.intent });
7074
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(IntentDot, { intent: option.intent });
6866
7075
  }
6867
7076
  return null;
6868
7077
  };
@@ -6871,7 +7080,7 @@ var DynamicOptionRow = ({
6871
7080
  selected,
6872
7081
  multi,
6873
7082
  onClick
6874
- }) => /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
7083
+ }) => /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
6875
7084
  "button",
6876
7085
  {
6877
7086
  type: "button",
@@ -6882,14 +7091,14 @@ var DynamicOptionRow = ({
6882
7091
  selected && "bg-dropdown-item-hover"
6883
7092
  ),
6884
7093
  children: [
6885
- multi && /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
7094
+ multi && /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
6886
7095
  "span",
6887
7096
  {
6888
7097
  className: cn(
6889
7098
  "mt-[2px] flex items-center justify-center size-4 rounded-xs border transition-colors shrink-0",
6890
7099
  selected ? "bg-primary border-primary" : "border-input bg-background"
6891
7100
  ),
6892
- children: selected && /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("svg", { width: "10", height: "10", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
7101
+ children: selected && /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("svg", { width: "10", height: "10", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
6893
7102
  "path",
6894
7103
  {
6895
7104
  d: "M2 5L4 7L8 3",
@@ -6901,9 +7110,9 @@ var DynamicOptionRow = ({
6901
7110
  ) })
6902
7111
  }
6903
7112
  ),
6904
- /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("span", { className: "flex-1 flex flex-col gap-2xs min-w-0", children: [
6905
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground truncate", children: option.label }),
6906
- option.description && /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "text-xs font-regular leading-xs text-muted-foreground", children: option.description })
7113
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("span", { className: "flex-1 flex flex-col gap-2xs min-w-0", children: [
7114
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground truncate", children: option.label }),
7115
+ option.description && /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("span", { className: "text-xs font-regular leading-xs text-muted-foreground", children: option.description })
6907
7116
  ] })
6908
7117
  ]
6909
7118
  }
@@ -6920,7 +7129,7 @@ var SingleSelectValueInput = ({
6920
7129
  onChange(v);
6921
7130
  onSubmit?.();
6922
7131
  };
6923
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
7132
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
6924
7133
  "div",
6925
7134
  {
6926
7135
  className: cn(
@@ -6928,7 +7137,7 @@ var SingleSelectValueInput = ({
6928
7137
  className
6929
7138
  ),
6930
7139
  children: [
6931
- dynamicOptions?.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
7140
+ dynamicOptions?.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
6932
7141
  DynamicOptionRow,
6933
7142
  {
6934
7143
  option: opt,
@@ -6940,7 +7149,7 @@ var SingleSelectValueInput = ({
6940
7149
  )),
6941
7150
  options.map((rawOpt) => {
6942
7151
  const opt = resolveEnumOption(rawOpt);
6943
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
7152
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
6944
7153
  "button",
6945
7154
  {
6946
7155
  type: "button",
@@ -6951,8 +7160,8 @@ var SingleSelectValueInput = ({
6951
7160
  value === opt.value && "bg-dropdown-item-hover"
6952
7161
  ),
6953
7162
  children: [
6954
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(OptionLeading, { option: opt }),
6955
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground truncate", children: opt.label })
7163
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(OptionLeading, { option: opt }),
7164
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground truncate", children: opt.label })
6956
7165
  ]
6957
7166
  },
6958
7167
  opt.value
@@ -6976,9 +7185,9 @@ var MultiSelectValueInput = ({
6976
7185
  const next = selected.includes(v) ? selected.filter((s) => s !== v) : [...selected, v];
6977
7186
  onChange(next);
6978
7187
  };
6979
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: cn("flex flex-col gap-xs p-xs", className), children: [
6980
- /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)("div", { className: "flex flex-col max-h-[240px] overflow-y-auto", children: [
6981
- dynamicOptions?.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
7188
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: cn("flex flex-col gap-xs p-xs", className), children: [
7189
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: "flex flex-col max-h-[240px] overflow-y-auto", children: [
7190
+ dynamicOptions?.map((opt) => /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
6982
7191
  DynamicOptionRow,
6983
7192
  {
6984
7193
  option: opt,
@@ -6991,7 +7200,7 @@ var MultiSelectValueInput = ({
6991
7200
  options.map((rawOpt) => {
6992
7201
  const opt = resolveEnumOption(rawOpt);
6993
7202
  const isSelected = selected.includes(opt.value);
6994
- return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
7203
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
6995
7204
  "button",
6996
7205
  {
6997
7206
  type: "button",
@@ -7001,14 +7210,14 @@ var MultiSelectValueInput = ({
7001
7210
  "hover:bg-dropdown-item-hover"
7002
7211
  ),
7003
7212
  children: [
7004
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
7213
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
7005
7214
  "span",
7006
7215
  {
7007
7216
  className: cn(
7008
7217
  "flex items-center justify-center size-4 rounded-xs border transition-colors shrink-0",
7009
7218
  isSelected ? "bg-primary border-primary" : "border-input bg-background"
7010
7219
  ),
7011
- children: isSelected && /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("svg", { width: "10", height: "10", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
7220
+ children: isSelected && /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("svg", { width: "10", height: "10", viewBox: "0 0 10 10", fill: "none", children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
7012
7221
  "path",
7013
7222
  {
7014
7223
  d: "M2 5L4 7L8 3",
@@ -7020,21 +7229,21 @@ var MultiSelectValueInput = ({
7020
7229
  ) })
7021
7230
  }
7022
7231
  ),
7023
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(OptionLeading, { option: opt }),
7024
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground truncate", children: opt.label })
7232
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(OptionLeading, { option: opt }),
7233
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground truncate", children: opt.label })
7025
7234
  ]
7026
7235
  },
7027
7236
  opt.value
7028
7237
  );
7029
7238
  })
7030
7239
  ] }),
7031
- /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
7240
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
7032
7241
  ] });
7033
7242
  };
7034
7243
  MultiSelectValueInput.displayName = "MultiSelectValueInput";
7035
7244
 
7036
7245
  // src/components/ui/filter/value-inputs/relation-value-input.tsx
7037
- var import_jsx_runtime50 = require("react/jsx-runtime");
7246
+ var import_jsx_runtime51 = require("react/jsx-runtime");
7038
7247
  var RelationValueInput = ({
7039
7248
  value,
7040
7249
  onChange,
@@ -7044,8 +7253,8 @@ var RelationValueInput = ({
7044
7253
  const handleKeyDown = (e) => {
7045
7254
  if (e.key === "Enter") onSubmit?.();
7046
7255
  };
7047
- return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)("div", { className: cn("flex flex-col gap-base p-xs", className), children: [
7048
- /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
7256
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)("div", { className: cn("flex flex-col gap-base p-xs", className), children: [
7257
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
7049
7258
  "input",
7050
7259
  {
7051
7260
  type: "text",
@@ -7057,13 +7266,13 @@ var RelationValueInput = ({
7057
7266
  className: inputClasses
7058
7267
  }
7059
7268
  ),
7060
- /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
7269
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Button, { appearance: "solid", intent: "brand", size: "sm", className: "self-end", onClick: onSubmit, children: "Apply" })
7061
7270
  ] });
7062
7271
  };
7063
7272
  RelationValueInput.displayName = "RelationValueInput";
7064
7273
 
7065
7274
  // src/components/ui/filter/value-input.tsx
7066
- var import_jsx_runtime51 = require("react/jsx-runtime");
7275
+ var import_jsx_runtime52 = require("react/jsx-runtime");
7067
7276
  var ValueInput = ({
7068
7277
  dataType,
7069
7278
  operator,
@@ -7078,13 +7287,13 @@ var ValueInput = ({
7078
7287
  if (!inputType) return null;
7079
7288
  switch (inputType) {
7080
7289
  case "TextInput":
7081
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(TextValueInput, { value, onChange, onSubmit, className });
7290
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(TextValueInput, { value, onChange, onSubmit, className });
7082
7291
  case "NumberInput":
7083
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(NumberValueInput, { value, onChange, onSubmit, className });
7292
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(NumberValueInput, { value, onChange, onSubmit, className });
7084
7293
  case "NumberRange":
7085
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(NumberRangeValueInput, { value, onChange, onSubmit, className });
7294
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(NumberRangeValueInput, { value, onChange, onSubmit, className });
7086
7295
  case "SingleSelect":
7087
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
7296
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7088
7297
  SingleSelectValueInput,
7089
7298
  {
7090
7299
  value,
@@ -7096,7 +7305,7 @@ var ValueInput = ({
7096
7305
  }
7097
7306
  );
7098
7307
  case "MultiSelect":
7099
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
7308
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7100
7309
  MultiSelectValueInput,
7101
7310
  {
7102
7311
  value,
@@ -7109,7 +7318,7 @@ var ValueInput = ({
7109
7318
  );
7110
7319
  case "DatePicker":
7111
7320
  case "DateRange":
7112
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
7321
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7113
7322
  DateCalendarValueInput,
7114
7323
  {
7115
7324
  operator,
@@ -7121,7 +7330,7 @@ var ValueInput = ({
7121
7330
  );
7122
7331
  case "RelationPicker":
7123
7332
  case "MultiRelationPicker":
7124
- return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(RelationValueInput, { value, onChange, onSubmit, className });
7333
+ return /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(RelationValueInput, { value, onChange, onSubmit, className });
7125
7334
  default:
7126
7335
  return null;
7127
7336
  }
@@ -7129,13 +7338,13 @@ var ValueInput = ({
7129
7338
  ValueInput.displayName = "ValueInput";
7130
7339
 
7131
7340
  // src/components/ui/filter/property-selector.tsx
7132
- var React46 = __toESM(require("react"));
7341
+ var React47 = __toESM(require("react"));
7133
7342
  var PopoverPrimitive6 = __toESM(require("@radix-ui/react-popover"));
7134
7343
  var import_icons32 = require("@l3mpire/icons");
7135
- var import_jsx_runtime52 = require("react/jsx-runtime");
7136
- var AdvancedFilterFooter = ({ onClick, count }) => /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "shrink-0 flex flex-col", children: [
7137
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("div", { className: "h-px bg-dropdown-border mx-xs" }),
7138
- /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
7344
+ var import_jsx_runtime53 = require("react/jsx-runtime");
7345
+ var AdvancedFilterFooter = ({ onClick, count }) => /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "shrink-0 flex flex-col", children: [
7346
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "h-px bg-dropdown-border mx-xs" }),
7347
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7139
7348
  "button",
7140
7349
  {
7141
7350
  type: "button",
@@ -7143,7 +7352,7 @@ var AdvancedFilterFooter = ({ onClick, count }) => /* @__PURE__ */ (0, import_js
7143
7352
  onClick,
7144
7353
  className: "flex items-center gap-base p-base rounded-base cursor-pointer transition-colors hover:bg-dropdown-item-hover",
7145
7354
  children: [
7146
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7355
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7147
7356
  import_icons32.Icon,
7148
7357
  {
7149
7358
  icon: import_icons32.faFilterOutline,
@@ -7151,8 +7360,8 @@ var AdvancedFilterFooter = ({ onClick, count }) => /* @__PURE__ */ (0, import_js
7151
7360
  className: "shrink-0 text-dropdown-item-icon"
7152
7361
  }
7153
7362
  ),
7154
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: "Advanced filter" }),
7155
- count > 0 && /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("span", { className: "text-xs font-regular leading-xs text-muted-foreground", children: [
7363
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: "Advanced filter" }),
7364
+ count > 0 && /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("span", { className: "text-xs font-regular leading-xs text-muted-foreground", children: [
7156
7365
  count,
7157
7366
  " ",
7158
7367
  count === 1 ? "rule" : "rules"
@@ -7176,26 +7385,26 @@ var PropertySelector = ({
7176
7385
  onAdvancedFilter?.();
7177
7386
  };
7178
7387
  const showAdvancedFooter = !!onAdvancedFilter;
7179
- const [activeGroup, setActiveGroup] = React46.useState(null);
7180
- const [search, setSearch] = React46.useState("");
7181
- React46.useEffect(() => {
7388
+ const [activeGroup, setActiveGroup] = React47.useState(null);
7389
+ const [search, setSearch] = React47.useState("");
7390
+ React47.useEffect(() => {
7182
7391
  if (!open) {
7183
7392
  setActiveGroup(null);
7184
7393
  setSearch("");
7185
7394
  }
7186
7395
  }, [open]);
7187
- const pinnedGroupIds = React46.useMemo(() => {
7396
+ const pinnedGroupIds = React47.useMemo(() => {
7188
7397
  const set = /* @__PURE__ */ new Set();
7189
7398
  for (const p of properties) {
7190
7399
  if (p.groupPinned) set.add(p.group);
7191
7400
  }
7192
7401
  return set;
7193
7402
  }, [properties]);
7194
- const pinnedProperties = React46.useMemo(
7403
+ const pinnedProperties = React47.useMemo(
7195
7404
  () => properties.filter((p) => pinnedGroupIds.has(p.group)),
7196
7405
  [properties, pinnedGroupIds]
7197
7406
  );
7198
- const groups = React46.useMemo(() => {
7407
+ const groups = React47.useMemo(() => {
7199
7408
  const map = /* @__PURE__ */ new Map();
7200
7409
  for (const prop of properties) {
7201
7410
  if (pinnedGroupIds.has(prop.group)) continue;
@@ -7213,14 +7422,14 @@ var PropertySelector = ({
7213
7422
  }
7214
7423
  return Array.from(map.values());
7215
7424
  }, [properties, pinnedGroupIds]);
7216
- const filteredPinnedProperties = React46.useMemo(() => {
7425
+ const filteredPinnedProperties = React47.useMemo(() => {
7217
7426
  if (!search || activeGroup) return pinnedProperties;
7218
7427
  const lower = search.toLowerCase();
7219
7428
  return pinnedProperties.filter(
7220
7429
  (p) => p.label.toLowerCase().includes(lower)
7221
7430
  );
7222
7431
  }, [pinnedProperties, search, activeGroup]);
7223
- const filteredGroups = React46.useMemo(() => {
7432
+ const filteredGroups = React47.useMemo(() => {
7224
7433
  if (!search || activeGroup) return groups;
7225
7434
  const lower = search.toLowerCase();
7226
7435
  return groups.filter(
@@ -7229,7 +7438,7 @@ var PropertySelector = ({
7229
7438
  )
7230
7439
  );
7231
7440
  }, [groups, properties, search, activeGroup]);
7232
- const filteredProperties = React46.useMemo(() => {
7441
+ const filteredProperties = React47.useMemo(() => {
7233
7442
  if (!activeGroup) return [];
7234
7443
  const groupProps = properties.filter((p) => p.group === activeGroup);
7235
7444
  if (!search) return groupProps;
@@ -7237,16 +7446,16 @@ var PropertySelector = ({
7237
7446
  return groupProps.filter((p) => p.label.toLowerCase().includes(lower));
7238
7447
  }, [properties, activeGroup, search]);
7239
7448
  const activeGroupInfo = groups.find((g) => g.group === activeGroup);
7240
- const nonPinnedSearchResults = React46.useMemo(() => {
7449
+ const nonPinnedSearchResults = React47.useMemo(() => {
7241
7450
  if (!search || activeGroup) return [];
7242
7451
  const lower = search.toLowerCase();
7243
7452
  return properties.filter(
7244
7453
  (p) => !pinnedGroupIds.has(p.group) && p.label.toLowerCase().includes(lower)
7245
7454
  );
7246
7455
  }, [properties, search, activeGroup, pinnedGroupIds]);
7247
- return /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(PopoverPrimitive6.Root, { open, onOpenChange, children: [
7248
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(PopoverPrimitive6.Trigger, { asChild: true, children }),
7249
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(PopoverPrimitive6.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
7456
+ return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(PopoverPrimitive6.Root, { open, onOpenChange, children: [
7457
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(PopoverPrimitive6.Trigger, { asChild: true, children }),
7458
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(PopoverPrimitive6.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7250
7459
  PopoverPrimitive6.Content,
7251
7460
  {
7252
7461
  sideOffset: 4,
@@ -7263,9 +7472,9 @@ var PropertySelector = ({
7263
7472
  children: [
7264
7473
  activeGroup === null ? (
7265
7474
  /* ── Level 1: Search + (pinned props) + Categories ──────── */
7266
- /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "flex flex-col gap-xs flex-1 min-h-0", children: [
7267
- /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "shrink-0 flex items-center gap-base px-md py-base border border-input rounded-md", children: [
7268
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7475
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex flex-col gap-xs flex-1 min-h-0", children: [
7476
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "shrink-0 flex items-center gap-base px-md py-base border border-input rounded-md", children: [
7477
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7269
7478
  import_icons32.Icon,
7270
7479
  {
7271
7480
  icon: import_icons32.faMagnifyingGlassOutline,
@@ -7273,7 +7482,7 @@ var PropertySelector = ({
7273
7482
  className: "shrink-0 text-muted-foreground"
7274
7483
  }
7275
7484
  ),
7276
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7485
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7277
7486
  "input",
7278
7487
  {
7279
7488
  type: "text",
@@ -7285,8 +7494,8 @@ var PropertySelector = ({
7285
7494
  }
7286
7495
  )
7287
7496
  ] }),
7288
- /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "flex flex-col flex-1 min-h-0 overflow-y-auto", children: [
7289
- filteredPinnedProperties.map((prop) => /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
7497
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex flex-col flex-1 min-h-0 overflow-y-auto", children: [
7498
+ filteredPinnedProperties.map((prop) => /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7290
7499
  "button",
7291
7500
  {
7292
7501
  type: "button",
@@ -7296,7 +7505,7 @@ var PropertySelector = ({
7296
7505
  },
7297
7506
  className: "flex items-center gap-base p-base rounded-base cursor-pointer transition-colors hover:bg-dropdown-item-hover",
7298
7507
  children: [
7299
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7508
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7300
7509
  import_icons32.Icon,
7301
7510
  {
7302
7511
  icon: prop.icon,
@@ -7304,14 +7513,14 @@ var PropertySelector = ({
7304
7513
  className: "shrink-0 text-dropdown-item-icon"
7305
7514
  }
7306
7515
  ),
7307
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: prop.label })
7516
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: prop.label })
7308
7517
  ]
7309
7518
  },
7310
7519
  prop.id
7311
7520
  )),
7312
7521
  search ? (
7313
7522
  /* ── Flat matches across non-pinned groups ────────── */
7314
- nonPinnedSearchResults.map((prop) => /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
7523
+ nonPinnedSearchResults.map((prop) => /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7315
7524
  "button",
7316
7525
  {
7317
7526
  type: "button",
@@ -7321,7 +7530,7 @@ var PropertySelector = ({
7321
7530
  },
7322
7531
  className: "flex items-center gap-base p-base rounded-base cursor-pointer transition-colors hover:bg-dropdown-item-hover",
7323
7532
  children: [
7324
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7533
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7325
7534
  import_icons32.Icon,
7326
7535
  {
7327
7536
  icon: prop.icon,
@@ -7329,15 +7538,15 @@ var PropertySelector = ({
7329
7538
  className: "shrink-0 text-dropdown-item-icon"
7330
7539
  }
7331
7540
  ),
7332
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: prop.label }),
7333
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "text-xs font-regular leading-xs text-muted-foreground", children: prop.groupLabel })
7541
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: prop.label }),
7542
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "text-xs font-regular leading-xs text-muted-foreground", children: prop.groupLabel })
7334
7543
  ]
7335
7544
  },
7336
7545
  prop.id
7337
7546
  ))
7338
7547
  ) : (
7339
7548
  /* ── Category list ────────────────────────────────── */
7340
- filteredGroups.map((g) => /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
7549
+ filteredGroups.map((g) => /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7341
7550
  "button",
7342
7551
  {
7343
7552
  type: "button",
@@ -7347,7 +7556,7 @@ var PropertySelector = ({
7347
7556
  },
7348
7557
  className: "flex items-center gap-base p-base rounded-base cursor-pointer transition-colors hover:bg-dropdown-item-hover",
7349
7558
  children: [
7350
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7559
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7351
7560
  import_icons32.Icon,
7352
7561
  {
7353
7562
  icon: g.groupIcon,
@@ -7355,9 +7564,9 @@ var PropertySelector = ({
7355
7564
  className: "shrink-0 text-dropdown-item-icon"
7356
7565
  }
7357
7566
  ),
7358
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: g.groupLabel }),
7359
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: g.count }),
7360
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7567
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: g.groupLabel }),
7568
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: g.count }),
7569
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7361
7570
  import_icons32.Icon,
7362
7571
  {
7363
7572
  icon: import_icons32.faChevronRightOutline,
@@ -7370,13 +7579,13 @@ var PropertySelector = ({
7370
7579
  g.group
7371
7580
  ))
7372
7581
  ),
7373
- filteredPinnedProperties.length === 0 && (search ? nonPinnedSearchResults.length === 0 : filteredGroups.length === 0) && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "p-base text-sm text-muted-foreground", children: "No results" })
7582
+ filteredPinnedProperties.length === 0 && (search ? nonPinnedSearchResults.length === 0 : filteredGroups.length === 0) && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "p-base text-sm text-muted-foreground", children: "No results" })
7374
7583
  ] })
7375
7584
  ] })
7376
7585
  ) : (
7377
7586
  /* ── Level 2: Properties ─────────────────────────────────── */
7378
- /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "flex flex-col gap-xs flex-1 min-h-0", children: [
7379
- /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
7587
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex flex-col gap-xs flex-1 min-h-0", children: [
7588
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7380
7589
  "button",
7381
7590
  {
7382
7591
  type: "button",
@@ -7386,7 +7595,7 @@ var PropertySelector = ({
7386
7595
  },
7387
7596
  className: "shrink-0 flex items-center gap-base p-base rounded-base cursor-pointer transition-colors hover:bg-dropdown-item-hover",
7388
7597
  children: [
7389
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7598
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7390
7599
  import_icons32.Icon,
7391
7600
  {
7392
7601
  icon: import_icons32.faChevronLeftOutline,
@@ -7394,12 +7603,12 @@ var PropertySelector = ({
7394
7603
  className: "shrink-0 text-dropdown-item-icon"
7395
7604
  }
7396
7605
  ),
7397
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "flex-1 text-xs font-medium leading-xs text-muted-foreground text-left truncate", children: activeGroupInfo?.groupLabel })
7606
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1 text-xs font-medium leading-xs text-muted-foreground text-left truncate", children: activeGroupInfo?.groupLabel })
7398
7607
  ]
7399
7608
  }
7400
7609
  ),
7401
- /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "shrink-0 flex items-center gap-base px-md py-base border border-input rounded-md", children: [
7402
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7610
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "shrink-0 flex items-center gap-base px-md py-base border border-input rounded-md", children: [
7611
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7403
7612
  import_icons32.Icon,
7404
7613
  {
7405
7614
  icon: import_icons32.faMagnifyingGlassOutline,
@@ -7407,7 +7616,7 @@ var PropertySelector = ({
7407
7616
  className: "shrink-0 text-muted-foreground"
7408
7617
  }
7409
7618
  ),
7410
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7619
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7411
7620
  "input",
7412
7621
  {
7413
7622
  type: "text",
@@ -7419,8 +7628,8 @@ var PropertySelector = ({
7419
7628
  }
7420
7629
  )
7421
7630
  ] }),
7422
- /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)("div", { className: "flex flex-col flex-1 min-h-0 overflow-y-auto", children: [
7423
- filteredProperties.map((prop) => /* @__PURE__ */ (0, import_jsx_runtime52.jsxs)(
7631
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex flex-col flex-1 min-h-0 overflow-y-auto", children: [
7632
+ filteredProperties.map((prop) => /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7424
7633
  "button",
7425
7634
  {
7426
7635
  type: "button",
@@ -7430,7 +7639,7 @@ var PropertySelector = ({
7430
7639
  },
7431
7640
  className: "flex items-center gap-base p-base rounded-base cursor-pointer transition-colors hover:bg-dropdown-item-hover",
7432
7641
  children: [
7433
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7642
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7434
7643
  import_icons32.Icon,
7435
7644
  {
7436
7645
  icon: prop.icon,
@@ -7438,16 +7647,16 @@ var PropertySelector = ({
7438
7647
  className: "shrink-0 text-dropdown-item-icon"
7439
7648
  }
7440
7649
  ),
7441
- /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: prop.label })
7650
+ /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "flex-1 text-sm font-regular leading-sm text-dropdown-item-text text-left truncate", children: prop.label })
7442
7651
  ]
7443
7652
  },
7444
7653
  prop.id
7445
7654
  )),
7446
- filteredProperties.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)("span", { className: "p-base text-sm text-muted-foreground", children: "No results" })
7655
+ filteredProperties.length === 0 && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "p-base text-sm text-muted-foreground", children: "No results" })
7447
7656
  ] })
7448
7657
  ] })
7449
7658
  ),
7450
- showAdvancedFooter && /* @__PURE__ */ (0, import_jsx_runtime52.jsx)(
7659
+ showAdvancedFooter && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7451
7660
  AdvancedFilterFooter,
7452
7661
  {
7453
7662
  onClick: handleAdvancedClick,
@@ -7464,7 +7673,7 @@ PropertySelector.displayName = "PropertySelector";
7464
7673
  // src/components/ui/filter/kebab-menu.tsx
7465
7674
  var PopoverPrimitive7 = __toESM(require("@radix-ui/react-popover"));
7466
7675
  var import_icons33 = require("@l3mpire/icons");
7467
- var import_jsx_runtime53 = require("react/jsx-runtime");
7676
+ var import_jsx_runtime54 = require("react/jsx-runtime");
7468
7677
  var KebabMenu = ({
7469
7678
  onConvertToAdvanced,
7470
7679
  hasAdvancedFilters = false,
@@ -7472,9 +7681,9 @@ var KebabMenu = ({
7472
7681
  open,
7473
7682
  onOpenChange,
7474
7683
  children
7475
- }) => /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(PopoverPrimitive7.Root, { open, onOpenChange, children: [
7476
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(PopoverPrimitive7.Trigger, { asChild: true, children }),
7477
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(PopoverPrimitive7.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7684
+ }) => /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(PopoverPrimitive7.Root, { open, onOpenChange, children: [
7685
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(PopoverPrimitive7.Trigger, { asChild: true, children }),
7686
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(PopoverPrimitive7.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
7478
7687
  PopoverPrimitive7.Content,
7479
7688
  {
7480
7689
  sideOffset: 4,
@@ -7488,7 +7697,7 @@ var KebabMenu = ({
7488
7697
  "min-w-[210px]"
7489
7698
  ),
7490
7699
  children: [
7491
- onConvertToAdvanced && /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7700
+ onConvertToAdvanced && /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
7492
7701
  "button",
7493
7702
  {
7494
7703
  type: "button",
@@ -7498,7 +7707,7 @@ var KebabMenu = ({
7498
7707
  },
7499
7708
  className: "flex items-center gap-base p-base rounded-base cursor-pointer transition-colors hover:bg-dropdown-item-hover",
7500
7709
  children: [
7501
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7710
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
7502
7711
  import_icons33.Icon,
7503
7712
  {
7504
7713
  icon: import_icons33.faArrowRightOutline,
@@ -7506,12 +7715,12 @@ var KebabMenu = ({
7506
7715
  className: "shrink-0 text-dropdown-item-icon"
7507
7716
  }
7508
7717
  ),
7509
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "text-sm font-regular leading-sm text-dropdown-item-text", children: hasAdvancedFilters ? "Add to advanced filters" : "Convert to advanced" })
7718
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "text-sm font-regular leading-sm text-dropdown-item-text", children: hasAdvancedFilters ? "Add to advanced filters" : "Convert to advanced" })
7510
7719
  ]
7511
7720
  }
7512
7721
  ),
7513
- onConvertToAdvanced && onDelete && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: "h-px mx-base my-xs bg-border" }),
7514
- onDelete && /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
7722
+ onConvertToAdvanced && onDelete && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "h-px mx-base my-xs bg-border" }),
7723
+ onDelete && /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
7515
7724
  "button",
7516
7725
  {
7517
7726
  type: "button",
@@ -7521,7 +7730,7 @@ var KebabMenu = ({
7521
7730
  },
7522
7731
  className: "flex items-center gap-base p-base rounded-base cursor-pointer transition-colors hover:bg-dropdown-item-hover",
7523
7732
  children: [
7524
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
7733
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
7525
7734
  import_icons33.Icon,
7526
7735
  {
7527
7736
  icon: import_icons33.faTrashOutline,
@@ -7529,7 +7738,7 @@ var KebabMenu = ({
7529
7738
  className: "shrink-0 text-destructive"
7530
7739
  }
7531
7740
  ),
7532
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: "text-sm font-regular leading-sm text-destructive", children: "Delete filter" })
7741
+ /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "text-sm font-regular leading-sm text-destructive", children: "Delete filter" })
7533
7742
  ]
7534
7743
  }
7535
7744
  )
@@ -7540,10 +7749,10 @@ var KebabMenu = ({
7540
7749
  KebabMenu.displayName = "KebabMenu";
7541
7750
 
7542
7751
  // src/components/ui/filter/filter-editor.tsx
7543
- var React47 = __toESM(require("react"));
7752
+ var React48 = __toESM(require("react"));
7544
7753
  var PopoverPrimitive8 = __toESM(require("@radix-ui/react-popover"));
7545
7754
  var import_icons34 = require("@l3mpire/icons");
7546
- var import_jsx_runtime54 = require("react/jsx-runtime");
7755
+ var import_jsx_runtime55 = require("react/jsx-runtime");
7547
7756
  var FilterEditor = ({
7548
7757
  propertyDef,
7549
7758
  condition,
@@ -7554,16 +7763,16 @@ var FilterEditor = ({
7554
7763
  onOpenChange,
7555
7764
  children
7556
7765
  }) => {
7557
- const [view, setView] = React47.useState(
7766
+ const [view, setView] = React48.useState(
7558
7767
  mode === "add" ? "value" : "operator"
7559
7768
  );
7560
- const [localOperator, setLocalOperator] = React47.useState(
7769
+ const [localOperator, setLocalOperator] = React48.useState(
7561
7770
  condition.operator
7562
7771
  );
7563
- const [localValue, setLocalValue] = React47.useState(
7772
+ const [localValue, setLocalValue] = React48.useState(
7564
7773
  condition.value
7565
7774
  );
7566
- React47.useEffect(() => {
7775
+ React48.useEffect(() => {
7567
7776
  if (open) {
7568
7777
  setView(mode === "add" ? "value" : "operator");
7569
7778
  setLocalOperator(condition.operator);
@@ -7588,9 +7797,9 @@ var FilterEditor = ({
7588
7797
  onOpenChange?.(false);
7589
7798
  onClose();
7590
7799
  };
7591
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(PopoverPrimitive8.Root, { open, onOpenChange, children: [
7592
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(PopoverPrimitive8.Trigger, { asChild: true, children }),
7593
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(PopoverPrimitive8.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
7800
+ return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(PopoverPrimitive8.Root, { open, onOpenChange, children: [
7801
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(PopoverPrimitive8.Trigger, { asChild: true, children }),
7802
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(PopoverPrimitive8.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
7594
7803
  PopoverPrimitive8.Content,
7595
7804
  {
7596
7805
  sideOffset: 4,
@@ -7604,8 +7813,8 @@ var FilterEditor = ({
7604
7813
  "min-w-[240px]"
7605
7814
  ),
7606
7815
  children: [
7607
- /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)("div", { className: "flex items-center gap-base px-base pt-base pb-xs border-b border-border", children: [
7608
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
7816
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)("div", { className: "flex items-center gap-base px-base pt-base pb-xs border-b border-border", children: [
7817
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
7609
7818
  import_icons34.Icon,
7610
7819
  {
7611
7820
  icon: propertyDef.icon,
@@ -7613,8 +7822,8 @@ var FilterEditor = ({
7613
7822
  className: "shrink-0 text-dropdown-item-icon"
7614
7823
  }
7615
7824
  ),
7616
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("span", { className: "text-sm font-medium leading-sm text-foreground", children: propertyDef.label }),
7617
- localOperator && view === "value" && /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
7825
+ /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("span", { className: "text-sm font-medium leading-sm text-foreground", children: propertyDef.label }),
7826
+ localOperator && view === "value" && /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
7618
7827
  "button",
7619
7828
  {
7620
7829
  type: "button",
@@ -7627,14 +7836,14 @@ var FilterEditor = ({
7627
7836
  }
7628
7837
  )
7629
7838
  ] }),
7630
- view === "operator" ? /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("div", { className: "p-xs", children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
7839
+ view === "operator" ? /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "p-xs", children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
7631
7840
  OperatorList,
7632
7841
  {
7633
7842
  dataType: propertyDef.type,
7634
7843
  activeOperator: localOperator,
7635
7844
  onSelect: handleOperatorSelect
7636
7845
  }
7637
- ) }) : localOperator && /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
7846
+ ) }) : localOperator && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
7638
7847
  ValueInput,
7639
7848
  {
7640
7849
  dataType: propertyDef.type,
@@ -7654,10 +7863,10 @@ var FilterEditor = ({
7654
7863
  FilterEditor.displayName = "FilterEditor";
7655
7864
 
7656
7865
  // src/components/ui/filter/interactive-filter-chip.tsx
7657
- var React48 = __toESM(require("react"));
7866
+ var React49 = __toESM(require("react"));
7658
7867
  var PopoverPrimitive9 = __toESM(require("@radix-ui/react-popover"));
7659
7868
  var import_icons35 = require("@l3mpire/icons");
7660
- var import_jsx_runtime55 = require("react/jsx-runtime");
7869
+ var import_jsx_runtime56 = require("react/jsx-runtime");
7661
7870
  var SegmentPopover = ({
7662
7871
  open,
7663
7872
  onOpenChange,
@@ -7665,9 +7874,9 @@ var SegmentPopover = ({
7665
7874
  children,
7666
7875
  align = "start",
7667
7876
  minWidth = "240px"
7668
- }) => /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(PopoverPrimitive9.Root, { open, onOpenChange, children: [
7669
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(PopoverPrimitive9.Trigger, { asChild: true, children: trigger }),
7670
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(PopoverPrimitive9.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
7877
+ }) => /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(PopoverPrimitive9.Root, { open, onOpenChange, children: [
7878
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(PopoverPrimitive9.Trigger, { asChild: true, children: trigger }),
7879
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(PopoverPrimitive9.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7671
7880
  PopoverPrimitive9.Content,
7672
7881
  {
7673
7882
  sideOffset: 4,
@@ -7697,19 +7906,19 @@ var InteractiveFilterChip = ({
7697
7906
  hasAdvancedFilters = false,
7698
7907
  className
7699
7908
  }) => {
7700
- const [operatorOpen, setOperatorOpen] = React48.useState(false);
7701
- const [valueOpen, setValueOpen] = React48.useState(false);
7702
- const [propertyOpen, setPropertyOpen] = React48.useState(false);
7703
- const [kebabOpen, setKebabOpen] = React48.useState(false);
7704
- const [pendingValueOpen, setPendingValueOpen] = React48.useState(false);
7705
- const autoOpenHandled = React48.useRef(false);
7706
- React48.useEffect(() => {
7909
+ const [operatorOpen, setOperatorOpen] = React49.useState(false);
7910
+ const [valueOpen, setValueOpen] = React49.useState(false);
7911
+ const [propertyOpen, setPropertyOpen] = React49.useState(false);
7912
+ const [kebabOpen, setKebabOpen] = React49.useState(false);
7913
+ const [pendingValueOpen, setPendingValueOpen] = React49.useState(false);
7914
+ const autoOpenHandled = React49.useRef(false);
7915
+ React49.useEffect(() => {
7707
7916
  if (autoOpen && !autoOpenHandled.current && condition.operator && !isNoValueOperator(condition.operator)) {
7708
7917
  autoOpenHandled.current = true;
7709
7918
  setValueOpen(true);
7710
7919
  }
7711
7920
  }, [autoOpen, condition.operator]);
7712
- React48.useEffect(() => {
7921
+ React49.useEffect(() => {
7713
7922
  if (!operatorOpen && pendingValueOpen) {
7714
7923
  setPendingValueOpen(false);
7715
7924
  setValueOpen(true);
@@ -7743,13 +7952,13 @@ var InteractiveFilterChip = ({
7743
7952
  );
7744
7953
  const hasValue = hasOperator && displayValue != null;
7745
7954
  const badgeCount = getBadgeCount(condition.value);
7746
- const valueLeading = React48.useMemo(() => {
7955
+ const valueLeading = React49.useMemo(() => {
7747
7956
  const v = condition.value;
7748
7957
  const raw = typeof v === "string" ? v : Array.isArray(v) && typeof v[0] === "string" ? v[0] : null;
7749
7958
  if (!raw) return null;
7750
7959
  const opt = findEnumOption(raw, propertyDef.options);
7751
7960
  if (opt?.icon) {
7752
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
7961
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7753
7962
  import_icons35.Icon,
7754
7963
  {
7755
7964
  icon: opt.icon,
@@ -7760,7 +7969,7 @@ var InteractiveFilterChip = ({
7760
7969
  }
7761
7970
  return null;
7762
7971
  }, [condition.value, propertyDef.options]);
7763
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
7972
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(
7764
7973
  "div",
7765
7974
  {
7766
7975
  className: cn(
@@ -7769,7 +7978,7 @@ var InteractiveFilterChip = ({
7769
7978
  className
7770
7979
  ),
7771
7980
  children: [
7772
- properties ? /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
7981
+ properties ? /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7773
7982
  PropertySelector,
7774
7983
  {
7775
7984
  properties,
@@ -7779,7 +7988,7 @@ var InteractiveFilterChip = ({
7779
7988
  },
7780
7989
  open: propertyOpen,
7781
7990
  onOpenChange: setPropertyOpen,
7782
- children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
7991
+ children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7783
7992
  FilterChipSegment,
7784
7993
  {
7785
7994
  segmentType: "property",
@@ -7790,7 +7999,7 @@ var InteractiveFilterChip = ({
7790
7999
  }
7791
8000
  ) })
7792
8001
  }
7793
- ) : /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8002
+ ) : /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7794
8003
  FilterChipSegment,
7795
8004
  {
7796
8005
  segmentType: "property",
@@ -7799,13 +8008,13 @@ var InteractiveFilterChip = ({
7799
8008
  label: propertyDef.label
7800
8009
  }
7801
8010
  ),
7802
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8011
+ /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7803
8012
  SegmentPopover,
7804
8013
  {
7805
8014
  open: operatorOpen,
7806
8015
  onOpenChange: setOperatorOpen,
7807
8016
  minWidth: "180px",
7808
- trigger: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8017
+ trigger: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7809
8018
  FilterChipSegment,
7810
8019
  {
7811
8020
  segmentType: hasOperator ? "operator" : "placeholder",
@@ -7814,7 +8023,7 @@ var InteractiveFilterChip = ({
7814
8023
  onClick: () => setOperatorOpen(true)
7815
8024
  }
7816
8025
  ) }),
7817
- children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "p-xs", children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8026
+ children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: "p-xs", children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7818
8027
  OperatorList,
7819
8028
  {
7820
8029
  dataType: propertyDef.type,
@@ -7827,13 +8036,13 @@ var InteractiveFilterChip = ({
7827
8036
  hasOperator && condition.operator && !isNoValueOperator(condition.operator) && (() => {
7828
8037
  const inputType = getValueInputType(propertyDef.type, condition.operator);
7829
8038
  const dateWide = inputType === "DatePicker" || inputType === "DateRange";
7830
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8039
+ return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7831
8040
  SegmentPopover,
7832
8041
  {
7833
8042
  open: valueOpen,
7834
8043
  onOpenChange: setValueOpen,
7835
8044
  minWidth: dateWide ? "auto" : "240px",
7836
- trigger: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8045
+ trigger: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7837
8046
  FilterChipSegment,
7838
8047
  {
7839
8048
  segmentType: hasValue ? "value" : "placeholder",
@@ -7844,7 +8053,7 @@ var InteractiveFilterChip = ({
7844
8053
  onClick: () => setValueOpen(true)
7845
8054
  }
7846
8055
  ) }),
7847
- children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8056
+ children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7848
8057
  ValueInput,
7849
8058
  {
7850
8059
  dataType: propertyDef.type,
@@ -7859,7 +8068,7 @@ var InteractiveFilterChip = ({
7859
8068
  }
7860
8069
  );
7861
8070
  })(),
7862
- hasOperator && condition.operator && isNoValueOperator(condition.operator) && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8071
+ hasOperator && condition.operator && isNoValueOperator(condition.operator) && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7863
8072
  FilterChipSegment,
7864
8073
  {
7865
8074
  segmentType: "value",
@@ -7867,7 +8076,7 @@ var InteractiveFilterChip = ({
7867
8076
  label: condition.operator
7868
8077
  }
7869
8078
  ),
7870
- hasOperator && /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8079
+ hasOperator && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7871
8080
  KebabMenu,
7872
8081
  {
7873
8082
  open: kebabOpen,
@@ -7875,7 +8084,7 @@ var InteractiveFilterChip = ({
7875
8084
  onConvertToAdvanced,
7876
8085
  hasAdvancedFilters,
7877
8086
  onDelete,
7878
- children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
8087
+ children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
7879
8088
  FilterChipSegment,
7880
8089
  {
7881
8090
  segmentType: "button",
@@ -7894,13 +8103,13 @@ var InteractiveFilterChip = ({
7894
8103
  InteractiveFilterChip.displayName = "InteractiveFilterChip";
7895
8104
 
7896
8105
  // src/components/ui/filter/filter-system.tsx
7897
- var React56 = __toESM(require("react"));
8106
+ var React57 = __toESM(require("react"));
7898
8107
  var import_icons42 = require("@l3mpire/icons");
7899
8108
 
7900
8109
  // src/components/ui/filter/advanced-chip.tsx
7901
- var React49 = __toESM(require("react"));
8110
+ var React50 = __toESM(require("react"));
7902
8111
  var import_icons36 = require("@l3mpire/icons");
7903
- var import_jsx_runtime56 = require("react/jsx-runtime");
8112
+ var import_jsx_runtime57 = require("react/jsx-runtime");
7904
8113
  var btnBase = [
7905
8114
  "flex items-center justify-center",
7906
8115
  "min-h-[32px] max-h-[32px]",
@@ -7909,9 +8118,9 @@ var btnBase = [
7909
8118
  "cursor-pointer transition-colors",
7910
8119
  "hover:from-btn-outlined-neutral-bg-hover hover:to-btn-outlined-neutral-bg-gradient-to-hover"
7911
8120
  ];
7912
- var AdvancedChip = React49.forwardRef(
7913
- ({ className, count, onClear, onClick, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)("div", { className: cn("inline-flex items-center", className), children: [
7914
- /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(
8121
+ var AdvancedChip = React50.forwardRef(
8122
+ ({ className, count, onClear, onClick, ...props }, ref) => /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: cn("inline-flex items-center", className), children: [
8123
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(
7915
8124
  "button",
7916
8125
  {
7917
8126
  ref,
@@ -7924,7 +8133,7 @@ var AdvancedChip = React49.forwardRef(
7924
8133
  ),
7925
8134
  ...props,
7926
8135
  children: [
7927
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
8136
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
7928
8137
  import_icons36.Icon,
7929
8138
  {
7930
8139
  icon: import_icons36.faFilterOutline,
@@ -7932,12 +8141,12 @@ var AdvancedChip = React49.forwardRef(
7932
8141
  className: "shrink-0 text-foreground"
7933
8142
  }
7934
8143
  ),
7935
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap text-foreground", children: "Advanced filters" }),
7936
- count > 0 && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("span", { className: "flex items-center p-2xs rounded-xs bg-filter-chip-badge-bg", children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("span", { className: "text-[10px] font-medium leading-2xs text-filter-chip-badge-text", children: count }) })
8144
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap text-foreground", children: "Advanced filters" }),
8145
+ count > 0 && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: "flex items-center p-2xs rounded-xs bg-filter-chip-badge-bg", children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: "text-[10px] font-medium leading-2xs text-filter-chip-badge-text", children: count }) })
7937
8146
  ]
7938
8147
  }
7939
8148
  ),
7940
- onClear && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
8149
+ onClear && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
7941
8150
  "button",
7942
8151
  {
7943
8152
  type: "button",
@@ -7951,7 +8160,7 @@ var AdvancedChip = React49.forwardRef(
7951
8160
  "rounded-r-md -ml-px"
7952
8161
  ),
7953
8162
  "aria-label": "Clear all advanced filters",
7954
- children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_icons36.Icon, { icon: import_icons36.faXmarkOutline, size: "sm", className: "text-foreground" })
8163
+ children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(import_icons36.Icon, { icon: import_icons36.faXmarkOutline, size: "sm", className: "text-foreground" })
7955
8164
  }
7956
8165
  )
7957
8166
  ] })
@@ -7959,28 +8168,28 @@ var AdvancedChip = React49.forwardRef(
7959
8168
  AdvancedChip.displayName = "AdvancedChip";
7960
8169
 
7961
8170
  // src/components/ui/filter/advanced-popover.tsx
7962
- var React53 = __toESM(require("react"));
8171
+ var React54 = __toESM(require("react"));
7963
8172
  var PopoverPrimitive12 = __toESM(require("@radix-ui/react-popover"));
7964
8173
  var import_icons40 = require("@l3mpire/icons");
7965
8174
 
7966
8175
  // src/components/ui/filter/advanced-row.tsx
7967
- var React51 = __toESM(require("react"));
8176
+ var React52 = __toESM(require("react"));
7968
8177
  var PopoverPrimitive11 = __toESM(require("@radix-ui/react-popover"));
7969
8178
  var TooltipPrimitive4 = __toESM(require("@radix-ui/react-tooltip"));
7970
8179
  var import_icons38 = require("@l3mpire/icons");
7971
8180
 
7972
8181
  // src/components/ui/filter/filter-node-actions.tsx
7973
- var React50 = __toESM(require("react"));
8182
+ var React51 = __toESM(require("react"));
7974
8183
  var PopoverPrimitive10 = __toESM(require("@radix-ui/react-popover"));
7975
8184
  var import_icons37 = require("@l3mpire/icons");
7976
- var import_jsx_runtime57 = require("react/jsx-runtime");
8185
+ var import_jsx_runtime58 = require("react/jsx-runtime");
7977
8186
  var FilterNodeActions = ({
7978
8187
  nodeType,
7979
8188
  onDuplicate,
7980
8189
  onConvert,
7981
8190
  onDelete
7982
8191
  }) => {
7983
- const [open, setOpen] = React50.useState(false);
8192
+ const [open, setOpen] = React51.useState(false);
7984
8193
  const items = [
7985
8194
  {
7986
8195
  label: "Duplicate",
@@ -7999,14 +8208,14 @@ var FilterNodeActions = ({
7999
8208
  destructive: true
8000
8209
  }
8001
8210
  ];
8002
- return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(PopoverPrimitive10.Root, { open, onOpenChange: setOpen, children: [
8003
- /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(PopoverPrimitive10.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
8211
+ return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(PopoverPrimitive10.Root, { open, onOpenChange: setOpen, children: [
8212
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(PopoverPrimitive10.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8004
8213
  "button",
8005
8214
  {
8006
8215
  type: "button",
8007
8216
  className: "shrink-0 flex items-center justify-center p-sm rounded-md cursor-pointer transition-colors hover:bg-accent",
8008
8217
  "aria-label": "More actions",
8009
- children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
8218
+ children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8010
8219
  import_icons37.Icon,
8011
8220
  {
8012
8221
  icon: import_icons37.faEllipsisOutline,
@@ -8016,7 +8225,7 @@ var FilterNodeActions = ({
8016
8225
  )
8017
8226
  }
8018
8227
  ) }),
8019
- /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(PopoverPrimitive10.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
8228
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(PopoverPrimitive10.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8020
8229
  PopoverPrimitive10.Content,
8021
8230
  {
8022
8231
  sideOffset: 4,
@@ -8028,7 +8237,7 @@ var FilterNodeActions = ({
8028
8237
  "data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95",
8029
8238
  "min-w-[180px]"
8030
8239
  ),
8031
- children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(
8240
+ children: items.map((item) => /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
8032
8241
  "button",
8033
8242
  {
8034
8243
  type: "button",
@@ -8042,7 +8251,7 @@ var FilterNodeActions = ({
8042
8251
  item.destructive && "text-destructive"
8043
8252
  ),
8044
8253
  children: [
8045
- /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
8254
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8046
8255
  import_icons37.Icon,
8047
8256
  {
8048
8257
  icon: item.icon,
@@ -8053,7 +8262,7 @@ var FilterNodeActions = ({
8053
8262
  )
8054
8263
  }
8055
8264
  ),
8056
- /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
8265
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8057
8266
  "span",
8058
8267
  {
8059
8268
  className: cn(
@@ -8074,7 +8283,7 @@ var FilterNodeActions = ({
8074
8283
  FilterNodeActions.displayName = "FilterNodeActions";
8075
8284
 
8076
8285
  // src/components/ui/filter/advanced-row.tsx
8077
- var import_jsx_runtime58 = require("react/jsx-runtime");
8286
+ var import_jsx_runtime59 = require("react/jsx-runtime");
8078
8287
  var selectBtnStyle = [
8079
8288
  "flex items-center gap-base",
8080
8289
  "px-base py-sm",
@@ -8095,10 +8304,10 @@ var AdvancedRow = ({
8095
8304
  onDuplicate,
8096
8305
  onTurnIntoGroup
8097
8306
  }) => {
8098
- const [operatorOpen, setOperatorOpen] = React51.useState(false);
8099
- const [propertyOpen, setPropertyOpen] = React51.useState(false);
8100
- const [valueOpen, setValueOpen] = React51.useState(false);
8101
- const { pinnedProperties, unpinnedProperties } = React51.useMemo(() => {
8307
+ const [operatorOpen, setOperatorOpen] = React52.useState(false);
8308
+ const [propertyOpen, setPropertyOpen] = React52.useState(false);
8309
+ const [valueOpen, setValueOpen] = React52.useState(false);
8310
+ const { pinnedProperties, unpinnedProperties } = React52.useMemo(() => {
8102
8311
  const pinnedGroups = /* @__PURE__ */ new Set();
8103
8312
  for (const p of properties) {
8104
8313
  if (p.groupPinned) pinnedGroups.add(p.group);
@@ -8129,7 +8338,7 @@ var AdvancedRow = ({
8129
8338
  false,
8130
8339
  propertyDef.options
8131
8340
  );
8132
- const valueLeadingIcon = React51.useMemo(() => {
8341
+ const valueLeadingIcon = React52.useMemo(() => {
8133
8342
  const v = condition.value;
8134
8343
  const raw = typeof v === "string" ? v : Array.isArray(v) && typeof v[0] === "string" ? v[0] : null;
8135
8344
  if (!raw) return null;
@@ -8137,28 +8346,28 @@ var AdvancedRow = ({
8137
8346
  }, [condition.value, propertyDef.options]);
8138
8347
  const badgeCount = getBadgeCount(condition.value);
8139
8348
  const hasValue = displayValue != null;
8140
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex items-center gap-base w-full min-w-0", children: [
8141
- connector === "Where" ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: "Where" }) }) : /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(TooltipPrimitive4.Provider, { delayDuration: 200, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(TooltipPrimitive4.Root, { children: [
8142
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(TooltipPrimitive4.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground cursor-default", children: connector }) }),
8143
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(TooltipPrimitive4.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
8349
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "flex items-center gap-base w-full min-w-0", children: [
8350
+ connector === "Where" ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: "Where" }) }) : /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive4.Provider, { delayDuration: 200, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(TooltipPrimitive4.Root, { children: [
8351
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive4.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground cursor-default", children: connector }) }),
8352
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive4.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
8144
8353
  TooltipPrimitive4.Content,
8145
8354
  {
8146
8355
  sideOffset: 4,
8147
8356
  className: "z-50 px-base py-sm rounded-md shadow-lg bg-tooltip-default-bg text-tooltip-default-text text-sm font-regular leading-sm data-[state=delayed-open]:animate-[tooltip-in_150ms_ease-out] data-[state=closed]:animate-[tooltip-out_100ms_ease-in]",
8148
8357
  children: [
8149
8358
  '"Or" operator coming soon',
8150
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(TooltipPrimitive4.Arrow, { className: "fill-tooltip-default-bg" })
8359
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive4.Arrow, { className: "fill-tooltip-default-bg" })
8151
8360
  ]
8152
8361
  }
8153
8362
  ) })
8154
8363
  ] }) }) }),
8155
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(PopoverPrimitive11.Root, { open: propertyOpen, onOpenChange: setPropertyOpen, children: [
8156
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(PopoverPrimitive11.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("button", { type: "button", className: cn(selectBtnStyle, "min-w-0"), children: [
8157
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_icons38.Icon, { icon: propertyDef.icon, size: "sm", className: "shrink-0 text-muted-foreground" }),
8158
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground whitespace-nowrap truncate", children: propertyDef.label }),
8159
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_icons38.Icon, { icon: import_icons38.faChevronDownOutline, size: "xs", className: "shrink-0 text-foreground" })
8364
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(PopoverPrimitive11.Root, { open: propertyOpen, onOpenChange: setPropertyOpen, children: [
8365
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(PopoverPrimitive11.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("button", { type: "button", className: cn(selectBtnStyle, "min-w-0"), children: [
8366
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_icons38.Icon, { icon: propertyDef.icon, size: "sm", className: "shrink-0 text-muted-foreground" }),
8367
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground whitespace-nowrap truncate", children: propertyDef.label }),
8368
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_icons38.Icon, { icon: import_icons38.faChevronDownOutline, size: "xs", className: "shrink-0 text-foreground" })
8160
8369
  ] }) }),
8161
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(PopoverPrimitive11.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
8370
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(PopoverPrimitive11.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
8162
8371
  PopoverPrimitive11.Content,
8163
8372
  {
8164
8373
  sideOffset: 4,
@@ -8171,7 +8380,7 @@ var AdvancedRow = ({
8171
8380
  "min-w-[200px]"
8172
8381
  ),
8173
8382
  children: [
8174
- pinnedProperties.map((p) => /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
8383
+ pinnedProperties.map((p) => /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
8175
8384
  "button",
8176
8385
  {
8177
8386
  type: "button",
@@ -8185,13 +8394,13 @@ var AdvancedRow = ({
8185
8394
  p.id === condition.propertyId && "bg-dropdown-item-hover"
8186
8395
  ),
8187
8396
  children: [
8188
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_icons38.Icon, { icon: p.icon, size: "sm", className: "shrink-0 text-dropdown-item-icon" }),
8189
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "text-sm font-regular leading-sm text-dropdown-item-text truncate", children: p.label })
8397
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_icons38.Icon, { icon: p.icon, size: "sm", className: "shrink-0 text-dropdown-item-icon" }),
8398
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-sm font-regular leading-sm text-dropdown-item-text truncate", children: p.label })
8190
8399
  ]
8191
8400
  },
8192
8401
  p.id
8193
8402
  )),
8194
- unpinnedProperties.map((p) => /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
8403
+ unpinnedProperties.map((p) => /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
8195
8404
  "button",
8196
8405
  {
8197
8406
  type: "button",
@@ -8205,9 +8414,9 @@ var AdvancedRow = ({
8205
8414
  p.id === condition.propertyId && "bg-dropdown-item-hover"
8206
8415
  ),
8207
8416
  children: [
8208
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_icons38.Icon, { icon: p.icon, size: "sm", className: "shrink-0 text-dropdown-item-icon" }),
8209
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "text-sm font-regular leading-sm text-dropdown-item-text truncate", children: p.label }),
8210
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "ml-auto text-xs font-regular leading-xs text-muted-foreground", children: p.groupLabel })
8417
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_icons38.Icon, { icon: p.icon, size: "sm", className: "shrink-0 text-dropdown-item-icon" }),
8418
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-sm font-regular leading-sm text-dropdown-item-text truncate", children: p.label }),
8419
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "ml-auto text-xs font-regular leading-xs text-muted-foreground", children: p.groupLabel })
8211
8420
  ]
8212
8421
  },
8213
8422
  p.id
@@ -8216,12 +8425,12 @@ var AdvancedRow = ({
8216
8425
  }
8217
8426
  ) })
8218
8427
  ] }),
8219
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(PopoverPrimitive11.Root, { open: operatorOpen, onOpenChange: setOperatorOpen, children: [
8220
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(PopoverPrimitive11.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("button", { type: "button", className: cn(selectBtnStyle, "min-w-0"), children: [
8221
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground whitespace-nowrap truncate text-left", children: condition.operator ?? "Select" }),
8222
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(import_icons38.Icon, { icon: import_icons38.faChevronDownOutline, size: "xs", className: "shrink-0 text-foreground" })
8428
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(PopoverPrimitive11.Root, { open: operatorOpen, onOpenChange: setOperatorOpen, children: [
8429
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(PopoverPrimitive11.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("button", { type: "button", className: cn(selectBtnStyle, "min-w-0"), children: [
8430
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-sm font-regular leading-sm text-foreground whitespace-nowrap truncate text-left", children: condition.operator ?? "Select" }),
8431
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_icons38.Icon, { icon: import_icons38.faChevronDownOutline, size: "xs", className: "shrink-0 text-foreground" })
8223
8432
  ] }) }),
8224
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(PopoverPrimitive11.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8433
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(PopoverPrimitive11.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8225
8434
  PopoverPrimitive11.Content,
8226
8435
  {
8227
8436
  sideOffset: 4,
@@ -8233,7 +8442,7 @@ var AdvancedRow = ({
8233
8442
  "data-[state=closed]:animate-out data-[state=closed]:fade-out-0",
8234
8443
  "min-w-[160px]"
8235
8444
  ),
8236
- children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8445
+ children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8237
8446
  OperatorList,
8238
8447
  {
8239
8448
  dataType: propertyDef.type,
@@ -8248,7 +8457,7 @@ var AdvancedRow = ({
8248
8457
  const inputType = getValueInputType(propertyDef.type, condition.operator);
8249
8458
  const isInline = inputType === "TextInput" || inputType === "NumberInput";
8250
8459
  if (isInline) {
8251
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8460
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8252
8461
  "input",
8253
8462
  {
8254
8463
  type: inputType === "NumberInput" ? "number" : "text",
@@ -8273,15 +8482,15 @@ var AdvancedRow = ({
8273
8482
  const dyn = propertyDef.dynamicOptions?.find((o) => o.value === v);
8274
8483
  return dyn ? dyn.label : v;
8275
8484
  }) : null;
8276
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(PopoverPrimitive11.Root, { open: valueOpen, onOpenChange: setValueOpen, children: [
8277
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(PopoverPrimitive11.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
8485
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(PopoverPrimitive11.Root, { open: valueOpen, onOpenChange: setValueOpen, children: [
8486
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(PopoverPrimitive11.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
8278
8487
  "button",
8279
8488
  {
8280
8489
  type: "button",
8281
8490
  className: cn(selectBtnStyle, "flex-1 min-w-[80px] justify-between overflow-hidden"),
8282
8491
  children: [
8283
- multiTags && multiTags.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(ValueTagRow, { tags: multiTags }) : /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(import_jsx_runtime58.Fragment, { children: [
8284
- valueLeadingIcon && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8492
+ multiTags && multiTags.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(ValueTagRow, { tags: multiTags }) : /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(import_jsx_runtime59.Fragment, { children: [
8493
+ valueLeadingIcon && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8285
8494
  import_icons38.Icon,
8286
8495
  {
8287
8496
  icon: valueLeadingIcon,
@@ -8289,7 +8498,7 @@ var AdvancedRow = ({
8289
8498
  className: "shrink-0 text-foreground"
8290
8499
  }
8291
8500
  ),
8292
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8501
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8293
8502
  "span",
8294
8503
  {
8295
8504
  className: cn(
@@ -8301,7 +8510,7 @@ var AdvancedRow = ({
8301
8510
  }
8302
8511
  )
8303
8512
  ] }),
8304
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8513
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8305
8514
  import_icons38.Icon,
8306
8515
  {
8307
8516
  icon: import_icons38.faChevronDownOutline,
@@ -8312,7 +8521,7 @@ var AdvancedRow = ({
8312
8521
  ]
8313
8522
  }
8314
8523
  ) }),
8315
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(PopoverPrimitive11.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8524
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(PopoverPrimitive11.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8316
8525
  PopoverPrimitive11.Content,
8317
8526
  {
8318
8527
  sideOffset: 4,
@@ -8324,7 +8533,7 @@ var AdvancedRow = ({
8324
8533
  "data-[state=closed]:animate-out data-[state=closed]:fade-out-0"
8325
8534
  ),
8326
8535
  style: { minWidth: dateWide ? "auto" : "240px" },
8327
- children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8536
+ children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8328
8537
  ValueInput,
8329
8538
  {
8330
8539
  dataType: propertyDef.type,
@@ -8340,7 +8549,7 @@ var AdvancedRow = ({
8340
8549
  ) })
8341
8550
  ] });
8342
8551
  })(),
8343
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8552
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8344
8553
  FilterNodeActions,
8345
8554
  {
8346
8555
  nodeType: "condition",
@@ -8361,10 +8570,10 @@ var tagChip = cn(
8361
8570
  "h-5"
8362
8571
  );
8363
8572
  function ValueTagRow({ tags }) {
8364
- const containerRef = React51.useRef(null);
8365
- const measureRef = React51.useRef(null);
8366
- const [visibleCount, setVisibleCount] = React51.useState(tags.length);
8367
- React51.useLayoutEffect(() => {
8573
+ const containerRef = React52.useRef(null);
8574
+ const measureRef = React52.useRef(null);
8575
+ const [visibleCount, setVisibleCount] = React52.useState(tags.length);
8576
+ React52.useLayoutEffect(() => {
8368
8577
  const container = containerRef.current;
8369
8578
  const measureRow = measureRef.current;
8370
8579
  if (!container || !measureRow) return;
@@ -8396,32 +8605,32 @@ function ValueTagRow({ tags }) {
8396
8605
  }, [tags]);
8397
8606
  const overflowCount = tags.length - visibleCount;
8398
8607
  const overflowTags = tags.slice(visibleCount);
8399
- return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "flex flex-1 items-center gap-xs min-w-0 overflow-hidden relative", children: [
8400
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
8608
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "flex flex-1 items-center gap-xs min-w-0 overflow-hidden relative", children: [
8609
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8401
8610
  "div",
8402
8611
  {
8403
8612
  ref: measureRef,
8404
8613
  "aria-hidden": true,
8405
8614
  className: "absolute flex items-center gap-xs pointer-events-none",
8406
8615
  style: { visibility: "hidden", whiteSpace: "nowrap", top: 0, left: 0 },
8407
- children: tags.map((t) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: tagChip, children: t }, t))
8616
+ children: tags.map((t) => /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: tagChip, children: t }, t))
8408
8617
  }
8409
8618
  ),
8410
- /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { ref: containerRef, className: "flex flex-1 items-center gap-xs overflow-hidden", children: [
8411
- tags.slice(0, visibleCount).map((t) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { className: tagChip, children: t }, t)),
8412
- overflowCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(TooltipPrimitive4.Provider, { delayDuration: 200, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(TooltipPrimitive4.Root, { children: [
8413
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(TooltipPrimitive4.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("span", { className: cn(tagChip, "cursor-default bg-filter-chip-badge-bg text-filter-chip-badge-text"), children: [
8619
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { ref: containerRef, className: "flex flex-1 items-center gap-xs overflow-hidden", children: [
8620
+ tags.slice(0, visibleCount).map((t) => /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: tagChip, children: t }, t)),
8621
+ overflowCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive4.Provider, { delayDuration: 200, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(TooltipPrimitive4.Root, { children: [
8622
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive4.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("span", { className: cn(tagChip, "cursor-default bg-filter-chip-badge-bg text-filter-chip-badge-text"), children: [
8414
8623
  "+",
8415
8624
  overflowCount
8416
8625
  ] }) }),
8417
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(TooltipPrimitive4.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)(
8626
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive4.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
8418
8627
  TooltipPrimitive4.Content,
8419
8628
  {
8420
8629
  sideOffset: 4,
8421
8630
  className: "z-50 px-base py-sm rounded-md shadow-lg bg-tooltip-default-bg text-tooltip-default-text text-xs font-regular leading-xs flex flex-col gap-xs data-[state=delayed-open]:animate-[tooltip-in_150ms_ease-out] data-[state=closed]:animate-[tooltip-out_100ms_ease-in]",
8422
8631
  children: [
8423
- overflowTags.map((t) => /* @__PURE__ */ (0, import_jsx_runtime58.jsx)("span", { children: t }, t)),
8424
- /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(TooltipPrimitive4.Arrow, { className: "fill-tooltip-default-bg" })
8632
+ overflowTags.map((t) => /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { children: t }, t)),
8633
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive4.Arrow, { className: "fill-tooltip-default-bg" })
8425
8634
  ]
8426
8635
  }
8427
8636
  ) })
@@ -8431,10 +8640,10 @@ function ValueTagRow({ tags }) {
8431
8640
  }
8432
8641
 
8433
8642
  // src/components/ui/filter/advanced-group.tsx
8434
- var React52 = __toESM(require("react"));
8643
+ var React53 = __toESM(require("react"));
8435
8644
  var TooltipPrimitive5 = __toESM(require("@radix-ui/react-tooltip"));
8436
8645
  var import_icons39 = require("@l3mpire/icons");
8437
- var import_jsx_runtime59 = require("react/jsx-runtime");
8646
+ var import_jsx_runtime60 = require("react/jsx-runtime");
8438
8647
  var AdvancedGroup = ({
8439
8648
  connector,
8440
8649
  onConnectorToggle,
@@ -8445,25 +8654,25 @@ var AdvancedGroup = ({
8445
8654
  properties,
8446
8655
  children
8447
8656
  }) => {
8448
- const [addOpen, setAddOpen] = React52.useState(false);
8449
- return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "flex items-start gap-base w-full min-w-0", children: [
8450
- connector === "Where" ? /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end pt-base", children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: "Where" }) }) : /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end pt-base", children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive5.Provider, { delayDuration: 200, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(TooltipPrimitive5.Root, { children: [
8451
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive5.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground cursor-default", children: connector }) }),
8452
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive5.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
8657
+ const [addOpen, setAddOpen] = React53.useState(false);
8658
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex items-start gap-base w-full min-w-0", children: [
8659
+ connector === "Where" ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end pt-base", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: "Where" }) }) : /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end pt-base", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(TooltipPrimitive5.Provider, { delayDuration: 200, children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(TooltipPrimitive5.Root, { children: [
8660
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(TooltipPrimitive5.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground cursor-default", children: connector }) }),
8661
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(TooltipPrimitive5.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
8453
8662
  TooltipPrimitive5.Content,
8454
8663
  {
8455
8664
  sideOffset: 4,
8456
8665
  className: "z-50 px-base py-sm rounded-md shadow-lg bg-tooltip-default-bg text-tooltip-default-text text-sm font-regular leading-sm data-[state=delayed-open]:animate-[tooltip-in_150ms_ease-out] data-[state=closed]:animate-[tooltip-out_100ms_ease-in]",
8457
8666
  children: [
8458
8667
  '"Or" operator coming soon',
8459
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(TooltipPrimitive5.Arrow, { className: "fill-tooltip-default-bg" })
8668
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(TooltipPrimitive5.Arrow, { className: "fill-tooltip-default-bg" })
8460
8669
  ]
8461
8670
  }
8462
8671
  ) })
8463
8672
  ] }) }) }),
8464
- /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)("div", { className: "flex-1 min-w-0 flex flex-col gap-base p-base border border-border rounded-md bg-secondary", children: [
8673
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex-1 min-w-0 flex flex-col gap-base p-base border border-border rounded-md bg-secondary", children: [
8465
8674
  children,
8466
- onAddFilter && properties && /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8675
+ onAddFilter && properties && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
8467
8676
  PropertySelector,
8468
8677
  {
8469
8678
  properties,
@@ -8473,13 +8682,13 @@ var AdvancedGroup = ({
8473
8682
  },
8474
8683
  open: addOpen,
8475
8684
  onOpenChange: setAddOpen,
8476
- children: /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
8685
+ children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
8477
8686
  "button",
8478
8687
  {
8479
8688
  type: "button",
8480
8689
  className: "flex items-center gap-sm px-base py-sm text-sm font-medium leading-sm text-muted-foreground cursor-pointer transition-colors rounded-md hover:bg-accent hover:text-foreground w-fit",
8481
8690
  children: [
8482
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(import_icons39.Icon, { icon: import_icons39.faPlusOutline, size: "sm" }),
8691
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_icons39.Icon, { icon: import_icons39.faPlusOutline, size: "sm" }),
8483
8692
  "Add filter"
8484
8693
  ]
8485
8694
  }
@@ -8487,7 +8696,7 @@ var AdvancedGroup = ({
8487
8696
  }
8488
8697
  )
8489
8698
  ] }),
8490
- /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("div", { className: "shrink-0 pt-base", children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
8699
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "shrink-0 pt-base", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
8491
8700
  FilterNodeActions,
8492
8701
  {
8493
8702
  nodeType: "group",
@@ -8501,7 +8710,7 @@ var AdvancedGroup = ({
8501
8710
  AdvancedGroup.displayName = "AdvancedGroup";
8502
8711
 
8503
8712
  // src/components/ui/filter/advanced-popover.tsx
8504
- var import_jsx_runtime60 = (
8713
+ var import_jsx_runtime61 = (
8505
8714
  /* Draft row in empty group */
8506
8715
  require("react/jsx-runtime")
8507
8716
  );
@@ -8520,9 +8729,9 @@ var AdvancedPopover = ({
8520
8729
  children,
8521
8730
  collisionBoundary
8522
8731
  }) => {
8523
- const [addSelectorOpen, setAddSelectorOpen] = React53.useState(false);
8524
- const [draftPickerOpen, setDraftPickerOpen] = React53.useState(false);
8525
- const [groupSelectorOpen, setGroupSelectorOpen] = React53.useState(false);
8732
+ const [addSelectorOpen, setAddSelectorOpen] = React54.useState(false);
8733
+ const [draftPickerOpen, setDraftPickerOpen] = React54.useState(false);
8734
+ const [groupSelectorOpen, setGroupSelectorOpen] = React54.useState(false);
8526
8735
  const getPropertyDef = (propertyId) => properties.find((p) => p.id === propertyId);
8527
8736
  const handleAddFilter = (property) => {
8528
8737
  const newFilter = createFilterWithDefaults(property.id, property.type);
@@ -8609,7 +8818,7 @@ var AdvancedPopover = ({
8609
8818
  const renderNode = (node, index) => {
8610
8819
  const connector = index === 0 ? "Where" : (node.logicOperator ?? "and") === "and" ? "And" : "Or";
8611
8820
  if (isFilterGroup(node)) {
8612
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
8821
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
8613
8822
  AdvancedGroup,
8614
8823
  {
8615
8824
  connector,
@@ -8622,7 +8831,7 @@ var AdvancedPopover = ({
8622
8831
  const newFilter = createFilterWithDefaults(prop.id, prop.type);
8623
8832
  handleGroupChildrenChange(node.id, [...node.children, newFilter]);
8624
8833
  },
8625
- children: node.children.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
8834
+ children: node.children.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
8626
8835
  DraftRow,
8627
8836
  {
8628
8837
  properties,
@@ -8638,7 +8847,7 @@ var AdvancedPopover = ({
8638
8847
  }
8639
8848
  const propDef = getPropertyDef(node.propertyId);
8640
8849
  if (!propDef) return null;
8641
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
8850
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
8642
8851
  AdvancedRow,
8643
8852
  {
8644
8853
  connector,
@@ -8658,9 +8867,9 @@ var AdvancedPopover = ({
8658
8867
  node.id
8659
8868
  );
8660
8869
  };
8661
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(PopoverPrimitive12.Root, { open, onOpenChange, children: [
8662
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(PopoverPrimitive12.Trigger, { asChild: true, children }),
8663
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(PopoverPrimitive12.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
8870
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(PopoverPrimitive12.Root, { open, onOpenChange, children: [
8871
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(PopoverPrimitive12.Trigger, { asChild: true, children }),
8872
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(PopoverPrimitive12.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
8664
8873
  PopoverPrimitive12.Content,
8665
8874
  {
8666
8875
  sideOffset: 4,
@@ -8677,7 +8886,7 @@ var AdvancedPopover = ({
8677
8886
  collisionBoundary ? "w-[min(640px,var(--radix-popover-content-available-width))] min-w-0" : "w-[min(640px,calc(100vw-32px))] min-w-[360px]"
8678
8887
  ),
8679
8888
  children: [
8680
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "flex flex-col gap-base p-base", children: filters.length > 0 ? filters.map((node, i) => renderNode(node, i)) : /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
8889
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "flex flex-col gap-base p-base", children: filters.length > 0 ? filters.map((node, i) => renderNode(node, i)) : /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
8681
8890
  DraftRow,
8682
8891
  {
8683
8892
  properties,
@@ -8686,42 +8895,42 @@ var AdvancedPopover = ({
8686
8895
  onOpenChange: setDraftPickerOpen
8687
8896
  }
8688
8897
  ) }),
8689
- /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex items-center justify-between p-base border-t border-border", children: [
8690
- /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex items-center gap-sm", children: [
8691
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
8898
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex items-center justify-between p-base border-t border-border", children: [
8899
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex items-center gap-sm", children: [
8900
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
8692
8901
  PropertySelector,
8693
8902
  {
8694
8903
  properties,
8695
8904
  onSelect: handleAddFilter,
8696
8905
  open: addSelectorOpen,
8697
8906
  onOpenChange: setAddSelectorOpen,
8698
- children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("button", { type: "button", className: cn(ghostBtn, "text-foreground"), children: [
8699
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_icons40.Icon, { icon: import_icons40.faPlusOutline, size: "sm", className: "text-foreground" }),
8907
+ children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("button", { type: "button", className: cn(ghostBtn, "text-foreground"), children: [
8908
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_icons40.Icon, { icon: import_icons40.faPlusOutline, size: "sm", className: "text-foreground" }),
8700
8909
  "Add filter"
8701
8910
  ] })
8702
8911
  }
8703
8912
  ),
8704
- /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
8913
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
8705
8914
  "button",
8706
8915
  {
8707
8916
  type: "button",
8708
8917
  onClick: handleAddGroup,
8709
8918
  className: cn(ghostBtn, "text-foreground"),
8710
8919
  children: [
8711
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_icons40.Icon, { icon: import_icons40.faPlusOutline, size: "sm", className: "text-foreground" }),
8920
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_icons40.Icon, { icon: import_icons40.faPlusOutline, size: "sm", className: "text-foreground" }),
8712
8921
  "Add filters group"
8713
8922
  ]
8714
8923
  }
8715
8924
  )
8716
8925
  ] }),
8717
- filters.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
8926
+ filters.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
8718
8927
  "button",
8719
8928
  {
8720
8929
  type: "button",
8721
8930
  onClick: handleClearAll,
8722
8931
  className: cn(ghostBtn, "text-destructive"),
8723
8932
  children: [
8724
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(import_icons40.Icon, { icon: import_icons40.faXmarkOutline, size: "sm", className: "text-destructive" }),
8933
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_icons40.Icon, { icon: import_icons40.faXmarkOutline, size: "sm", className: "text-destructive" }),
8725
8934
  "Clear filters"
8726
8935
  ]
8727
8936
  }
@@ -8739,16 +8948,16 @@ var DraftRow = ({
8739
8948
  open: openProp,
8740
8949
  onOpenChange
8741
8950
  }) => {
8742
- const [internalOpen, setInternalOpen] = React53.useState(false);
8951
+ const [internalOpen, setInternalOpen] = React54.useState(false);
8743
8952
  const isControlled = openProp !== void 0;
8744
8953
  const open = isControlled ? openProp : internalOpen;
8745
8954
  const setOpen = (v) => {
8746
8955
  if (!isControlled) setInternalOpen(v);
8747
8956
  onOpenChange?.(v);
8748
8957
  };
8749
- return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex items-center gap-base w-full min-w-0", children: [
8750
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: "Where" }) }),
8751
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
8958
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex items-center gap-base w-full min-w-0", children: [
8959
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: "Where" }) }),
8960
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
8752
8961
  PropertySelector,
8753
8962
  {
8754
8963
  properties,
@@ -8758,7 +8967,7 @@ var DraftRow = ({
8758
8967
  },
8759
8968
  open,
8760
8969
  onOpenChange: setOpen,
8761
- children: /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
8970
+ children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
8762
8971
  "button",
8763
8972
  {
8764
8973
  type: "button",
@@ -8770,8 +8979,8 @@ var DraftRow = ({
8770
8979
  "hover:from-btn-outlined-neutral-bg-hover hover:to-btn-outlined-neutral-bg-gradient-to-hover"
8771
8980
  ),
8772
8981
  children: [
8773
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { className: "text-sm font-regular leading-sm text-muted-foreground whitespace-nowrap", children: "Select property" }),
8774
- /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
8982
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { className: "text-sm font-regular leading-sm text-muted-foreground whitespace-nowrap", children: "Select property" }),
8983
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
8775
8984
  import_icons40.Icon,
8776
8985
  {
8777
8986
  icon: import_icons40.faChevronDownOutline,
@@ -8788,11 +8997,11 @@ var DraftRow = ({
8788
8997
  };
8789
8998
 
8790
8999
  // src/components/ui/filter/summary-chip.tsx
8791
- var React54 = __toESM(require("react"));
9000
+ var React55 = __toESM(require("react"));
8792
9001
  var PopoverPrimitive13 = __toESM(require("@radix-ui/react-popover"));
8793
9002
  var TooltipPrimitive6 = __toESM(require("@radix-ui/react-tooltip"));
8794
9003
  var import_icons41 = require("@l3mpire/icons");
8795
- var import_jsx_runtime61 = require("react/jsx-runtime");
9004
+ var import_jsx_runtime62 = require("react/jsx-runtime");
8796
9005
  var ghostBtn2 = [
8797
9006
  "flex items-center gap-sm px-base py-sm",
8798
9007
  "min-h-[32px]",
@@ -8812,15 +9021,15 @@ var SummaryChip = ({
8812
9021
  collisionBoundary,
8813
9022
  tooltipContent
8814
9023
  }) => {
8815
- const [uncontrolledOpen, setUncontrolledOpen] = React54.useState(false);
9024
+ const [uncontrolledOpen, setUncontrolledOpen] = React55.useState(false);
8816
9025
  const isControlled = openProp !== void 0;
8817
9026
  const open = isControlled ? openProp : uncontrolledOpen;
8818
9027
  const setOpen = (v) => {
8819
9028
  if (!isControlled) setUncontrolledOpen(v);
8820
9029
  onOpenChange?.(v);
8821
9030
  };
8822
- const [addSelectorOpen, setAddSelectorOpen] = React54.useState(false);
8823
- const [draftPickerOpen, setDraftPickerOpen] = React54.useState(false);
9031
+ const [addSelectorOpen, setAddSelectorOpen] = React55.useState(false);
9032
+ const [draftPickerOpen, setDraftPickerOpen] = React55.useState(false);
8824
9033
  const getPropertyDef = (propertyId) => properties.find((p) => p.id === propertyId);
8825
9034
  const handleAddFilter = (property) => {
8826
9035
  const newFilter = createFilterWithDefaults(property.id, property.type);
@@ -8902,7 +9111,7 @@ var SummaryChip = ({
8902
9111
  const renderNode = (node, index) => {
8903
9112
  const connector = index === 0 ? "Where" : (node.logicOperator ?? "and") === "and" ? "And" : "Or";
8904
9113
  if (isFilterGroup(node)) {
8905
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
9114
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
8906
9115
  AdvancedGroup,
8907
9116
  {
8908
9117
  connector,
@@ -8915,7 +9124,7 @@ var SummaryChip = ({
8915
9124
  const newFilter = createFilterWithDefaults(prop.id, prop.type);
8916
9125
  handleGroupChildrenChange(node.id, [...node.children, newFilter]);
8917
9126
  },
8918
- children: node.children.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
9127
+ children: node.children.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
8919
9128
  DraftRow2,
8920
9129
  {
8921
9130
  properties,
@@ -8931,7 +9140,7 @@ var SummaryChip = ({
8931
9140
  }
8932
9141
  const propDef = getPropertyDef(node.propertyId);
8933
9142
  if (!propDef) return null;
8934
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
9143
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
8935
9144
  AdvancedRow,
8936
9145
  {
8937
9146
  connector,
@@ -8951,7 +9160,7 @@ var SummaryChip = ({
8951
9160
  node.id
8952
9161
  );
8953
9162
  };
8954
- const trigger = children ?? /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
9163
+ const trigger = children ?? /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
8955
9164
  "button",
8956
9165
  {
8957
9166
  type: "button",
@@ -8965,27 +9174,27 @@ var SummaryChip = ({
8965
9174
  className
8966
9175
  ),
8967
9176
  children: [
8968
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_icons41.Icon, { icon: import_icons41.faFilterOutline, size: "sm", className: "shrink-0 text-foreground" }),
8969
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap text-foreground", children: "Filters" }),
8970
- count > 0 && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { className: "flex items-center p-2xs rounded-xs bg-filter-chip-badge-bg", children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { className: "text-[10px] font-medium leading-2xs text-filter-chip-badge-text", children: count }) })
9177
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_icons41.Icon, { icon: import_icons41.faFilterOutline, size: "sm", className: "shrink-0 text-foreground" }),
9178
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "text-sm font-medium leading-sm whitespace-nowrap text-foreground", children: "Filters" }),
9179
+ count > 0 && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "flex items-center p-2xs rounded-xs bg-filter-chip-badge-bg", children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "text-[10px] font-medium leading-2xs text-filter-chip-badge-text", children: count }) })
8971
9180
  ]
8972
9181
  }
8973
9182
  );
8974
9183
  const hasTooltip = tooltipContent && !open;
8975
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(TooltipPrimitive6.Provider, { delayDuration: 300, children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(TooltipPrimitive6.Root, { open: hasTooltip ? void 0 : false, children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(PopoverPrimitive13.Root, { open, onOpenChange: setOpen, children: [
8976
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(TooltipPrimitive6.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(PopoverPrimitive13.Trigger, { asChild: true, children: trigger }) }),
8977
- hasTooltip && /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(TooltipPrimitive6.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
9184
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(TooltipPrimitive6.Provider, { delayDuration: 300, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(TooltipPrimitive6.Root, { open: hasTooltip ? void 0 : false, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(PopoverPrimitive13.Root, { open, onOpenChange: setOpen, children: [
9185
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(TooltipPrimitive6.Trigger, { asChild: true, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(PopoverPrimitive13.Trigger, { asChild: true, children: trigger }) }),
9186
+ hasTooltip && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(TooltipPrimitive6.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
8978
9187
  TooltipPrimitive6.Content,
8979
9188
  {
8980
9189
  sideOffset: 4,
8981
9190
  className: "z-50 px-base py-sm rounded-md shadow-lg bg-tooltip-default-bg text-tooltip-default-text text-sm font-regular leading-sm max-w-[320px] data-[state=delayed-open]:animate-[tooltip-in_150ms_ease-out] data-[state=closed]:animate-[tooltip-out_100ms_ease-in]",
8982
9191
  children: [
8983
9192
  tooltipContent,
8984
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(TooltipPrimitive6.Arrow, { className: "fill-tooltip-default-bg" })
9193
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(TooltipPrimitive6.Arrow, { className: "fill-tooltip-default-bg" })
8985
9194
  ]
8986
9195
  }
8987
9196
  ) }),
8988
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(PopoverPrimitive13.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
9197
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(PopoverPrimitive13.Portal, { children: /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
8989
9198
  PopoverPrimitive13.Content,
8990
9199
  {
8991
9200
  sideOffset: 4,
@@ -9002,7 +9211,7 @@ var SummaryChip = ({
9002
9211
  collisionBoundary ? "w-[min(640px,var(--radix-popover-content-available-width))]" : "w-[min(640px,calc(100vw-32px))]"
9003
9212
  ),
9004
9213
  children: [
9005
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "flex flex-col gap-base p-base", children: filters.length > 0 ? filters.map((node, i) => renderNode(node, i)) : /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
9214
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "flex flex-col gap-base p-base", children: filters.length > 0 ? filters.map((node, i) => renderNode(node, i)) : /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9006
9215
  DraftRow2,
9007
9216
  {
9008
9217
  properties,
@@ -9011,27 +9220,27 @@ var SummaryChip = ({
9011
9220
  onOpenChange: setDraftPickerOpen
9012
9221
  }
9013
9222
  ) }),
9014
- /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex items-center justify-between p-base border-t border-border", children: [
9015
- /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex items-center gap-sm", children: [
9016
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
9223
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "flex items-center justify-between p-base border-t border-border", children: [
9224
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "flex items-center gap-sm", children: [
9225
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9017
9226
  PropertySelector,
9018
9227
  {
9019
9228
  properties,
9020
9229
  onSelect: handleAddFilter,
9021
9230
  open: addSelectorOpen,
9022
9231
  onOpenChange: setAddSelectorOpen,
9023
- children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("button", { type: "button", className: cn(ghostBtn2, "text-foreground"), children: [
9024
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_icons41.Icon, { icon: import_icons41.faPlusOutline, size: "sm", className: "text-foreground" }),
9232
+ children: /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("button", { type: "button", className: cn(ghostBtn2, "text-foreground"), children: [
9233
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_icons41.Icon, { icon: import_icons41.faPlusOutline, size: "sm", className: "text-foreground" }),
9025
9234
  "Add filter"
9026
9235
  ] })
9027
9236
  }
9028
9237
  ),
9029
- /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("button", { type: "button", onClick: handleAddGroup, className: cn(ghostBtn2, "text-foreground"), children: [
9030
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_icons41.Icon, { icon: import_icons41.faPlusOutline, size: "sm", className: "text-foreground" }),
9238
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("button", { type: "button", onClick: handleAddGroup, className: cn(ghostBtn2, "text-foreground"), children: [
9239
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_icons41.Icon, { icon: import_icons41.faPlusOutline, size: "sm", className: "text-foreground" }),
9031
9240
  "Add filters group"
9032
9241
  ] })
9033
9242
  ] }),
9034
- filters.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
9243
+ filters.length > 0 && /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
9035
9244
  "button",
9036
9245
  {
9037
9246
  type: "button",
@@ -9041,7 +9250,7 @@ var SummaryChip = ({
9041
9250
  },
9042
9251
  className: cn(ghostBtn2, "text-destructive"),
9043
9252
  children: [
9044
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_icons41.Icon, { icon: import_icons41.faXmarkOutline, size: "sm", className: "text-destructive" }),
9253
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_icons41.Icon, { icon: import_icons41.faXmarkOutline, size: "sm", className: "text-destructive" }),
9045
9254
  "Clear filters"
9046
9255
  ]
9047
9256
  }
@@ -9054,19 +9263,19 @@ var SummaryChip = ({
9054
9263
  };
9055
9264
  SummaryChip.displayName = "SummaryChip";
9056
9265
  var DraftRow2 = ({ properties, onSelect, open: openProp, onOpenChange }) => {
9057
- const [internalOpen, setInternalOpen] = React54.useState(false);
9266
+ const [internalOpen, setInternalOpen] = React55.useState(false);
9058
9267
  const isCtrl = openProp !== void 0;
9059
9268
  const open = isCtrl ? openProp : internalOpen;
9060
9269
  const setOpen = (v) => {
9061
9270
  if (!isCtrl) setInternalOpen(v);
9062
9271
  onOpenChange?.(v);
9063
9272
  };
9064
- return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)("div", { className: "flex items-center gap-base w-full min-w-0", children: [
9065
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: "Where" }) }),
9066
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(PropertySelector, { properties, onSelect: (p) => {
9273
+ return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { className: "flex items-center gap-base w-full min-w-0", children: [
9274
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "shrink-0 w-[64px] flex items-center justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "text-xs font-medium leading-xs text-muted-foreground", children: "Where" }) }),
9275
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(PropertySelector, { properties, onSelect: (p) => {
9067
9276
  onSelect(p);
9068
9277
  setOpen(false);
9069
- }, open, onOpenChange: setOpen, children: /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(
9278
+ }, open, onOpenChange: setOpen, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(
9070
9279
  "button",
9071
9280
  {
9072
9281
  type: "button",
@@ -9077,8 +9286,8 @@ var DraftRow2 = ({ properties, onSelect, open: openProp, onOpenChange }) => {
9077
9286
  "hover:from-btn-outlined-neutral-bg-hover hover:to-btn-outlined-neutral-bg-gradient-to-hover"
9078
9287
  ),
9079
9288
  children: [
9080
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)("span", { className: "text-sm font-regular leading-sm text-muted-foreground whitespace-nowrap", children: "Select property" }),
9081
- /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(import_icons41.Icon, { icon: import_icons41.faChevronDownOutline, size: "xs", className: "shrink-0 text-foreground" })
9289
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "text-sm font-regular leading-sm text-muted-foreground whitespace-nowrap", children: "Select property" }),
9290
+ /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_icons41.Icon, { icon: import_icons41.faChevronDownOutline, size: "xs", className: "shrink-0 text-foreground" })
9082
9291
  ]
9083
9292
  }
9084
9293
  ) })
@@ -9086,11 +9295,11 @@ var DraftRow2 = ({ properties, onSelect, open: openProp, onOpenChange }) => {
9086
9295
  };
9087
9296
 
9088
9297
  // src/components/ui/filter/use-filter-bar-mode.ts
9089
- var React55 = __toESM(require("react"));
9298
+ var React56 = __toESM(require("react"));
9090
9299
  var DEFAULT_BREAKPOINT = 600;
9091
9300
  function useFilterBarMode(ref, override, breakpoint = DEFAULT_BREAKPOINT) {
9092
- const [mode, setMode] = React55.useState("default");
9093
- React55.useEffect(() => {
9301
+ const [mode, setMode] = React56.useState("default");
9302
+ React56.useEffect(() => {
9094
9303
  if (override) return;
9095
9304
  const el = ref.current;
9096
9305
  if (!el) return;
@@ -9105,7 +9314,7 @@ function useFilterBarMode(ref, override, breakpoint = DEFAULT_BREAKPOINT) {
9105
9314
  }
9106
9315
 
9107
9316
  // src/components/ui/filter/filter-system.tsx
9108
- var import_jsx_runtime62 = require("react/jsx-runtime");
9317
+ var import_jsx_runtime63 = require("react/jsx-runtime");
9109
9318
  var FilterSystem = ({
9110
9319
  properties,
9111
9320
  filterState,
@@ -9116,16 +9325,39 @@ var FilterSystem = ({
9116
9325
  bounded = false,
9117
9326
  children,
9118
9327
  actions,
9328
+ filterActions,
9329
+ defaultFiltersRowExpanded = true,
9330
+ filtersRowExpanded,
9331
+ onFiltersRowExpandedChange,
9119
9332
  className
9120
9333
  }) => {
9121
- const containerRef = React56.useRef(null);
9334
+ const containerRef = React57.useRef(null);
9122
9335
  const mode = useFilterBarMode(containerRef, modeOverride, breakpoint);
9123
9336
  const collisionBoundary = bounded ? containerRef.current : void 0;
9124
- const [propertySelectorOpen, setPropertySelectorOpen] = React56.useState(false);
9125
- const [advancedOpen, setAdvancedOpen] = React56.useState(false);
9126
- const [summaryOpen, setSummaryOpen] = React56.useState(false);
9127
- const [pendingFilterId, setPendingFilterId] = React56.useState(null);
9337
+ const [propertySelectorOpen, setPropertySelectorOpen] = React57.useState(false);
9338
+ const [advancedOpen, setAdvancedOpen] = React57.useState(false);
9339
+ const [summaryOpen, setSummaryOpen] = React57.useState(false);
9340
+ const [pendingFilterId, setPendingFilterId] = React57.useState(null);
9341
+ const [internalExpanded, setInternalExpanded] = React57.useState(
9342
+ defaultFiltersRowExpanded
9343
+ );
9344
+ const isExpandedControlled = filtersRowExpanded !== void 0;
9345
+ const rowExpanded = isExpandedControlled ? filtersRowExpanded : internalExpanded;
9346
+ const setRowExpanded = React57.useCallback(
9347
+ (next) => {
9348
+ if (!isExpandedControlled) setInternalExpanded(next);
9349
+ onFiltersRowExpandedChange?.(next);
9350
+ },
9351
+ [isExpandedControlled, onFiltersRowExpandedChange]
9352
+ );
9128
9353
  const totalCount = filterState.basicFilters.length + countConditions(filterState.advancedFilters);
9354
+ const prevTotalCount = React57.useRef(totalCount);
9355
+ React57.useEffect(() => {
9356
+ if (prevTotalCount.current === 0 && totalCount > 0) {
9357
+ setRowExpanded(true);
9358
+ }
9359
+ prevTotalCount.current = totalCount;
9360
+ }, [totalCount, setRowExpanded]);
9129
9361
  const handleAddFilter = (property) => {
9130
9362
  const newFilter = createFilterWithDefaults(property.id, property.type);
9131
9363
  if (newFilter.operator && isNoValueOperator(newFilter.operator)) {
@@ -9211,120 +9443,171 @@ var FilterSystem = ({
9211
9443
  };
9212
9444
  const advancedFilterCount = filterState.advancedFilters.length;
9213
9445
  const showAdvancedChip = hasAdvanced || advancedOpen;
9214
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(FilterBar, { ref: containerRef, className, children: [
9215
- /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(FilterBarLeft, { className: "flex-wrap flex-1 min-w-0", children: [
9216
- children,
9217
- sortFields && filterState.sort && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9218
- SortButton,
9219
- {
9220
- fields: sortFields,
9221
- activeField: filterState.sort.field,
9222
- direction: filterState.sort.direction,
9223
- onChange: handleSortChange,
9224
- iconOnly: isMinimal
9225
- }
9226
- ),
9227
- isMinimal ? /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_jsx_runtime62.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9228
- SummaryChip,
9229
- {
9230
- count: totalCount,
9231
- filters: [...filterState.basicFilters, ...filterState.advancedFilters],
9232
- properties,
9233
- onFiltersChange: (nodes) => {
9234
- onFilterStateChange({
9235
- ...filterState,
9236
- basicFilters: [],
9237
- advancedFilters: nodes
9238
- });
9239
- },
9240
- onClearAll: handleClearAll,
9241
- open: summaryOpen,
9242
- onOpenChange: setSummaryOpen,
9243
- collisionBoundary,
9244
- tooltipContent: totalCount > 0 ? buildFilterTooltip([...filterState.basicFilters, ...filterState.advancedFilters], properties) : void 0,
9245
- children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9246
- FilterBarButton,
9247
- {
9248
- iconOnly: isIconOnly,
9249
- count: totalCount > 0 ? totalCount : void 0
9250
- }
9251
- )
9252
- }
9253
- ) }) : (
9254
- /* ── DEFAULT MODE ────────────────────────────────────── */
9255
- /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)(import_jsx_runtime62.Fragment, { children: [
9256
- showAdvancedChip && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9257
- AdvancedPopover,
9258
- {
9259
- filters: filterState.advancedFilters,
9260
- properties,
9261
- onFiltersChange: handleAdvancedFiltersChange,
9262
- open: advancedOpen,
9263
- onOpenChange: setAdvancedOpen,
9264
- collisionBoundary,
9265
- children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9266
- AdvancedChip,
9267
- {
9268
- count: filterState.advancedFilters.length,
9269
- onClick: () => setAdvancedOpen(true),
9270
- onClear: handleClearAdvanced
9271
- }
9272
- )
9273
- }
9274
- ),
9275
- filterState.basicFilters.map((filter) => {
9276
- const propDef = getPropertyDef(filter.propertyId);
9277
- if (!propDef) return null;
9278
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9279
- InteractiveFilterChip,
9446
+ const showFiltersRow = !isMinimal && totalCount > 0 && rowExpanded;
9447
+ const filtersButton = totalCount === 0 ? /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9448
+ PropertySelector,
9449
+ {
9450
+ properties,
9451
+ onSelect: handleAddFilter,
9452
+ open: propertySelectorOpen,
9453
+ onOpenChange: setPropertySelectorOpen,
9454
+ onAdvancedFilter: handleOpenAdvanced,
9455
+ advancedFilterCount,
9456
+ children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(FilterBarButton, {})
9457
+ }
9458
+ ) : /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9459
+ FilterBarButton,
9460
+ {
9461
+ count: totalCount,
9462
+ onClick: () => setRowExpanded(!rowExpanded),
9463
+ "aria-expanded": rowExpanded
9464
+ }
9465
+ );
9466
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(
9467
+ "div",
9468
+ {
9469
+ ref: containerRef,
9470
+ className: cn("w-full flex flex-col", className),
9471
+ children: [
9472
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(FilterBar, { children: [
9473
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(FilterBarLeft, { className: "flex-wrap flex-1 min-w-0", children: [
9474
+ children,
9475
+ sortFields && filterState.sort && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9476
+ SortButton,
9280
9477
  {
9281
- propertyDef: propDef,
9282
- condition: filter,
9478
+ fields: sortFields,
9479
+ activeField: filterState.sort.field,
9480
+ direction: filterState.sort.direction,
9481
+ onChange: handleSortChange,
9482
+ iconOnly: isMinimal
9483
+ }
9484
+ ),
9485
+ isMinimal ? /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9486
+ SummaryChip,
9487
+ {
9488
+ count: totalCount,
9489
+ filters: [...filterState.basicFilters, ...filterState.advancedFilters],
9283
9490
  properties,
9284
- mode: pendingFilterId === filter.id ? "add" : "edit",
9285
- autoOpen: pendingFilterId === filter.id,
9286
- onUpdate: handleUpdateFilter,
9287
- onPropertyChange: (newProp) => handlePropertyChange(filter.id, newProp),
9288
- onDelete: () => handleDeleteFilter(filter.id),
9289
- onConvertToAdvanced: () => handleConvertToAdvanced(filter.id),
9290
- hasAdvancedFilters: hasAdvanced
9291
- },
9292
- filter.id
9293
- );
9294
- }),
9295
- /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9296
- PropertySelector,
9297
- {
9298
- properties,
9299
- onSelect: handleAddFilter,
9300
- open: propertySelectorOpen,
9301
- onOpenChange: setPropertySelectorOpen,
9302
- onAdvancedFilter: handleOpenAdvanced,
9303
- advancedFilterCount,
9304
- children: totalCount > 0 ? /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9305
- "button",
9306
- {
9307
- type: "button",
9308
- className: "shrink-0 inline-flex items-center justify-center size-8 rounded-md border border-btn-outlined-neutral-border-default bg-gradient-to-t from-btn-outlined-neutral-bg-default from-[10%] to-btn-outlined-neutral-bg-gradient-to-default shadow-sm cursor-pointer transition-colors hover:from-btn-outlined-neutral-bg-hover hover:to-btn-outlined-neutral-bg-gradient-to-hover",
9309
- children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(import_icons42.Icon, { icon: import_icons42.faPlusOutline, size: "sm", className: "text-foreground" })
9310
- }
9311
- ) : /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(FilterBarButton, {})
9312
- }
9313
- )
9314
- ] })
9315
- ),
9316
- totalCount > 0 && !isIconOnly && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(
9317
- "button",
9318
- {
9319
- type: "button",
9320
- onClick: handleClearAll,
9321
- className: "shrink-0 flex items-center gap-sm px-base py-sm min-h-[32px] max-h-[32px] rounded-md cursor-pointer transition-colors text-btn-ghost-brand-text-default hover:bg-btn-ghost-brand-bg-hover hover:text-btn-ghost-brand-text-hover active:bg-btn-ghost-brand-bg-pressed active:text-btn-ghost-brand-text-pressed",
9322
- children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "text-sm font-medium leading-sm", children: "Clear" })
9323
- }
9324
- )
9325
- ] }),
9326
- actions && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)(FilterBarRight, { className: "shrink-0", children: actions })
9327
- ] });
9491
+ onFiltersChange: (nodes) => {
9492
+ onFilterStateChange({
9493
+ ...filterState,
9494
+ basicFilters: [],
9495
+ advancedFilters: nodes
9496
+ });
9497
+ },
9498
+ onClearAll: handleClearAll,
9499
+ open: summaryOpen,
9500
+ onOpenChange: setSummaryOpen,
9501
+ collisionBoundary,
9502
+ tooltipContent: totalCount > 0 ? buildFilterTooltip([...filterState.basicFilters, ...filterState.advancedFilters], properties) : void 0,
9503
+ children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9504
+ FilterBarButton,
9505
+ {
9506
+ iconOnly: isIconOnly,
9507
+ count: totalCount > 0 ? totalCount : void 0
9508
+ }
9509
+ )
9510
+ }
9511
+ ) : (
9512
+ /* ── FULL MODE — Filters button only on Row 1 ────────── */
9513
+ filtersButton
9514
+ ),
9515
+ isMinimal && !isIconOnly && totalCount > 0 && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9516
+ "button",
9517
+ {
9518
+ type: "button",
9519
+ onClick: handleClearAll,
9520
+ className: "shrink-0 flex items-center gap-sm px-base py-sm min-h-[32px] max-h-[32px] rounded-md cursor-pointer transition-colors text-btn-ghost-brand-text-default hover:bg-btn-ghost-brand-bg-hover hover:text-btn-ghost-brand-text-hover active:bg-btn-ghost-brand-bg-pressed active:text-btn-ghost-brand-text-pressed",
9521
+ children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { className: "text-sm font-medium leading-sm", children: "Clear" })
9522
+ }
9523
+ )
9524
+ ] }),
9525
+ actions && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(FilterBarRight, { className: "shrink-0", children: actions })
9526
+ ] }),
9527
+ showFiltersRow && /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)(
9528
+ "div",
9529
+ {
9530
+ className: "flex items-start justify-between w-full pt-sm pb-md",
9531
+ role: "toolbar",
9532
+ "aria-label": "Active filters",
9533
+ children: [
9534
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("div", { className: "flex items-center gap-base flex-wrap flex-1 min-w-0", children: [
9535
+ showAdvancedChip && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9536
+ AdvancedPopover,
9537
+ {
9538
+ filters: filterState.advancedFilters,
9539
+ properties,
9540
+ onFiltersChange: handleAdvancedFiltersChange,
9541
+ open: advancedOpen,
9542
+ onOpenChange: setAdvancedOpen,
9543
+ collisionBoundary,
9544
+ children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9545
+ AdvancedChip,
9546
+ {
9547
+ count: filterState.advancedFilters.length,
9548
+ onClick: () => setAdvancedOpen(true),
9549
+ onClear: handleClearAdvanced
9550
+ }
9551
+ )
9552
+ }
9553
+ ),
9554
+ filterState.basicFilters.map((filter) => {
9555
+ const propDef = getPropertyDef(filter.propertyId);
9556
+ if (!propDef) return null;
9557
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9558
+ InteractiveFilterChip,
9559
+ {
9560
+ propertyDef: propDef,
9561
+ condition: filter,
9562
+ properties,
9563
+ mode: pendingFilterId === filter.id ? "add" : "edit",
9564
+ autoOpen: pendingFilterId === filter.id,
9565
+ onUpdate: handleUpdateFilter,
9566
+ onPropertyChange: (newProp) => handlePropertyChange(filter.id, newProp),
9567
+ onDelete: () => handleDeleteFilter(filter.id),
9568
+ onConvertToAdvanced: () => handleConvertToAdvanced(filter.id),
9569
+ hasAdvancedFilters: hasAdvanced
9570
+ },
9571
+ filter.id
9572
+ );
9573
+ }),
9574
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9575
+ PropertySelector,
9576
+ {
9577
+ properties,
9578
+ onSelect: handleAddFilter,
9579
+ open: propertySelectorOpen,
9580
+ onOpenChange: setPropertySelectorOpen,
9581
+ onAdvancedFilter: handleOpenAdvanced,
9582
+ advancedFilterCount,
9583
+ children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9584
+ "button",
9585
+ {
9586
+ type: "button",
9587
+ className: "shrink-0 inline-flex items-center justify-center size-8 rounded-md border border-btn-outlined-neutral-border-default bg-gradient-to-t from-btn-outlined-neutral-bg-default from-[10%] to-btn-outlined-neutral-bg-gradient-to-default shadow-sm cursor-pointer transition-colors hover:from-btn-outlined-neutral-bg-hover hover:to-btn-outlined-neutral-bg-gradient-to-hover",
9588
+ "aria-label": "Add filter",
9589
+ children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(import_icons42.Icon, { icon: import_icons42.faPlusOutline, size: "sm", className: "text-foreground" })
9590
+ }
9591
+ )
9592
+ }
9593
+ ),
9594
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)(
9595
+ "button",
9596
+ {
9597
+ type: "button",
9598
+ onClick: handleClearAll,
9599
+ className: "shrink-0 flex items-center gap-sm px-base py-sm min-h-[32px] max-h-[32px] rounded-md cursor-pointer transition-colors text-btn-ghost-brand-text-default hover:bg-btn-ghost-brand-bg-hover hover:text-btn-ghost-brand-text-hover active:bg-btn-ghost-brand-bg-pressed active:text-btn-ghost-brand-text-pressed",
9600
+ children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { className: "text-sm font-medium leading-sm", children: "Clear" })
9601
+ }
9602
+ )
9603
+ ] }),
9604
+ filterActions && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: "flex items-center shrink-0 gap-sm", children: filterActions })
9605
+ ]
9606
+ }
9607
+ )
9608
+ ]
9609
+ }
9610
+ );
9328
9611
  };
9329
9612
  FilterSystem.displayName = "FilterSystem";
9330
9613
  function buildFilterTooltip(nodes, properties) {
@@ -9336,7 +9619,7 @@ function buildFilterTooltip(nodes, properties) {
9336
9619
  if ("children" in node && node.type === "group") {
9337
9620
  if (connector) {
9338
9621
  result.push(
9339
- /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { style: { paddingLeft: depth * 8 }, children: /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "opacity-50 text-xs", children: connector }) }, `${node.id}-conn`)
9622
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { style: { paddingLeft: depth * 8 }, children: /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { className: "opacity-50 text-xs", children: connector }) }, `${node.id}-conn`)
9340
9623
  );
9341
9624
  }
9342
9625
  result.push(...renderNodes(node.children, depth + 1));
@@ -9346,23 +9629,23 @@ function buildFilterTooltip(nodes, properties) {
9346
9629
  if (!prop) continue;
9347
9630
  const val = formatFilterValue(f.value, prop.dynamicOptions, true);
9348
9631
  result.push(
9349
- /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("div", { style: { paddingLeft: depth * 8 }, children: [
9350
- connector && /* @__PURE__ */ (0, import_jsx_runtime62.jsxs)("span", { className: "opacity-50 text-xs", children: [
9632
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("div", { style: { paddingLeft: depth * 8 }, children: [
9633
+ connector && /* @__PURE__ */ (0, import_jsx_runtime63.jsxs)("span", { className: "opacity-50 text-xs", children: [
9351
9634
  connector,
9352
9635
  " "
9353
9636
  ] }),
9354
- /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "font-medium", children: prop.label }),
9637
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { className: "font-medium", children: prop.label }),
9355
9638
  " ",
9356
- /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { className: "opacity-60", children: f.operator }),
9639
+ /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { className: "opacity-60", children: f.operator }),
9357
9640
  " ",
9358
- val && /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("span", { children: val })
9641
+ val && /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("span", { children: val })
9359
9642
  ] }, f.id)
9360
9643
  );
9361
9644
  }
9362
9645
  }
9363
9646
  return result;
9364
9647
  };
9365
- return /* @__PURE__ */ (0, import_jsx_runtime62.jsx)("div", { className: "flex flex-col gap-2xs", children: renderNodes(nodes, 0) });
9648
+ return /* @__PURE__ */ (0, import_jsx_runtime63.jsx)("div", { className: "flex flex-col gap-2xs", children: renderNodes(nodes, 0) });
9366
9649
  }
9367
9650
  // Annotate the CommonJS export names for ESM import in node:
9368
9651
  0 && (module.exports = {
@@ -9382,6 +9665,7 @@ function buildFilterTooltip(nodes, properties) {
9382
9665
  DEFAULT_OPERATOR_BY_TYPE,
9383
9666
  DataTable,
9384
9667
  DataTablePagination,
9668
+ DataTableSettingsModal,
9385
9669
  DateCell,
9386
9670
  DatePicker,
9387
9671
  DatePickerCalendar,