Open source Loom alternative. Beautiful, shareable screen recordings.
Rust appcapcossloommacnextjsnextjs15open-sourceossreactrecordrustscreen-capturescreen-recorderscreenshotsolidjstauritauri-apptypescriptvite
feat(web): add anonymous views toggle to notification settings UI
Richie McIlroyee9a373f0cb6
diff --git a/apps/web/app/(org)/dashboard/_components/Notifications/SettingsDropdown.tsx b/apps/web/app/(org)/dashboard/_components/Notifications/SettingsDropdown.tsxindex 0e0af8031..7e894f537 100644--- a/apps/web/app/(org)/dashboard/_components/Notifications/SettingsDropdown.tsx+++ b/apps/web/app/(org)/dashboard/_components/Notifications/SettingsDropdown.tsx@@ -5,6 +5,7 @@ import {faCog,faComment,faEye,+ faEyeSlash,faReply,faThumbsUp,type IconDefinition,@@ -20,13 +21,19 @@ import { useDashboardContext } from "../../Contexts";type NotificationOption = {icon: IconDefinition;label: string;- value: "pauseComments" | "pauseViews" | "pauseReactions" | "pauseReplies";+ value:+ | "pauseComments"+ | "pauseViews"+ | "pauseReactions"+ | "pauseReplies"+ | "pauseAnonViews";};const notificationOptions: NotificationOption[] = [{ icon: faComment, label: "Comments", value: "pauseComments" },{ icon: faReply, label: "Replies", value: "pauseReplies" },{ icon: faEye, label: "Views", value: "pauseViews" },+ { icon: faEyeSlash, label: "Anonymous views", value: "pauseAnonViews" },{ icon: faThumbsUp, label: "Reactions", value: "pauseReactions" },];@@ -41,6 +48,7 @@ export const SettingsDropdown = () => {pauseReplies: false,pauseViews: false,pauseReactions: false,+ pauseAnonViews: false,};await updatePreferences({@@ -131,7 +139,7 @@ export const SettingsDropdown = () => {</p></div>- {userPreferences?.notifications[option.value] && (+ {userPreferences?.notifications?.[option.value] && (<FontAwesomeIconicon={faCheck}className="text-gray-10 size-2.5 transition-colors group-hover:text-gray-12"