diff --git a/packages/filter/src/views/filter-group-container.tsx b/packages/filter/src/views/filter-group-container.tsx index afdb07b..0613ab8 100644 --- a/packages/filter/src/views/filter-group-container.tsx +++ b/packages/filter/src/views/filter-group-container.tsx @@ -3,7 +3,6 @@ import type { ReactNode } from "react"; export type FilterGroupContainerProps = { filterGroup: FilterGroup; - isRoot: boolean; children?: ReactNode; }; diff --git a/packages/filter/src/views/filter-group.tsx b/packages/filter/src/views/filter-group.tsx index 4cab939..00d6858 100644 --- a/packages/filter/src/views/filter-group.tsx +++ b/packages/filter/src/views/filter-group.tsx @@ -8,11 +8,7 @@ export type FilterGroupProps = { }; export const FilterGroupView = ({ rule: filterGroup }: FilterGroupProps) => { - const { - ruleState: { isRoot }, - appendChildRule, - appendChildGroup, - } = useFilterGroup(filterGroup); + const { appendChildRule, appendChildGroup } = useFilterGroup(filterGroup); const { Button: ButtonView } = useView("components"); const { FilterGroupContainer, @@ -22,7 +18,7 @@ export const FilterGroupView = ({ rule: filterGroup }: FilterGroupProps) => { const count = filterGroup.conditions.length; if (count <= 0) { return ( - + { appendChildRule(); @@ -42,7 +38,7 @@ export const FilterGroupView = ({ rule: filterGroup }: FilterGroupProps) => { } return ( - + {filterGroup.conditions.map((childRule, groupIdx) => { if (childRule.type === "Filter") { return (