diff --git a/frontend/common/types/requests.ts b/frontend/common/types/requests.ts index 2c664f232427..85bbaa43f168 100644 --- a/frontend/common/types/requests.ts +++ b/frontend/common/types/requests.ts @@ -27,6 +27,7 @@ export type Req = { q?: string projectId: number | string identity?: number + include_feature_specific?: boolean }> deleteSegment: { projectId: number | string; id: number } updateSegment: { projectId: number | string; segment: Segment } diff --git a/frontend/web/components/pages/SegmentsPage.tsx b/frontend/web/components/pages/SegmentsPage.tsx index dd433acd0418..961efa1a7630 100644 --- a/frontend/web/components/pages/SegmentsPage.tsx +++ b/frontend/web/components/pages/SegmentsPage.tsx @@ -64,6 +64,7 @@ const SegmentsPage: FC = (props) => { const [showFeatureSpecific, setShowFeatureSpecific] = useState(false) const { data, error, isLoading, refetch } = useGetSegmentsQuery({ + include_feature_specific: showFeatureSpecific, page, page_size: 100, projectId, @@ -246,9 +247,15 @@ const SegmentsPage: FC = (props) => { ) preselect.current = null } + + // TODO: remove this check + // I'm leaving this here for now so that we can deploy the FE and + // API independently, but we should remove this once PR #3430 is + // merged and released. if (feature && !showFeatureSpecific) { return null } + return renderWithPermission( manageSegmentsPermission, 'Manage segments',