chore: deprecate action filtering in advanced targeting (#2877)

This commit is contained in:
Matti Nannt
2024-07-11 13:57:03 +02:00
committed by GitHub
parent 7b2470cce6
commit 2fc78c9219
2 changed files with 16 additions and 8 deletions

View File

@@ -17,11 +17,17 @@ export const metadata = {
# Advanced Targeting
Advanced Targeting allows you to show surveys to the right group of people. You can target surveys based on user attributes, user events, and more instead of spraying and praying. This helps you get more relevant feedback and make data-driven decisions. All of this without writing a single line of code.
<Note>
Targeting based on actions is deprecated in Advanced Targeting and will be removed soon. We recommend using
filters on user attributes to target the survey only to specific groups of users.
</Note>
<ResponsiveVideo title="Formbricks Multi-language Surveys"
src="https://www.youtube-nocookie.com/embed/0BQp6N4cXzU?si=KeBM7G7Ch1xtrsOm&amp;controls=0" />
Advanced Targeting allows you to show surveys to the right group of people. You can target surveys based on user attributes, device type, and more instead of spraying and praying. This helps you get more relevant feedback and make data-driven decisions. All of this without writing a single line of code.
<ResponsiveVideo
title="Formbricks Multi-language Surveys"
src="https://www.youtube-nocookie.com/embed/0BQp6N4cXzU?si=KeBM7G7Ch1xtrsOm&amp;controls=0"
/>
## How to setup Advanced Targeting

View File

@@ -245,16 +245,18 @@ export function AddFilterModal({
icon?: React.ReactNode;
}[] = [
{ id: "all", label: "All" },
{ id: "actions", label: "Actions", icon: <MousePointerClick className="h-4 w-4" /> },
{ id: "attributes", label: "Person & Attributes", icon: <TagIcon className="h-4 w-4" /> },
{ id: "segments", label: "Segments", icon: <Users2Icon className="h-4 w-4" /> },
{ id: "devices", label: "Devices", icon: <MonitorSmartphoneIcon className="h-4 w-4" /> },
];
const devices = [
{ id: "phone", name: "Phone" },
{ id: "desktop", name: "Desktop" },
];
const devices = useMemo(
() => [
{ id: "phone", name: "Phone" },
{ id: "desktop", name: "Desktop" },
],
[]
);
const actionClassesFiltered = useMemo(() => {
if (!searchValue) return actionClasses;