From cd0bc79c2b91f01ac60a9db9e66c27cc595bf1d8 Mon Sep 17 00:00:00 2001 From: Kirill Chernakov Date: Wed, 20 Nov 2024 16:07:52 +0400 Subject: [PATCH] fix: safe event capturing & security options for window opening --- keep-ui/app/read-only-banner.tsx | 18 +++++++++++++----- keep-ui/shared/lib/capture.ts | 9 +++++++++ 2 files changed, 22 insertions(+), 5 deletions(-) create mode 100644 keep-ui/shared/lib/capture.ts diff --git a/keep-ui/app/read-only-banner.tsx b/keep-ui/app/read-only-banner.tsx index fd29224e1..80af6cd19 100644 --- a/keep-ui/app/read-only-banner.tsx +++ b/keep-ui/app/read-only-banner.tsx @@ -3,7 +3,7 @@ import React from "react"; import { Text, Button } from "@tremor/react"; import Image from "next/image"; import KeepPng from "../keep.png"; -import posthog from "posthog-js"; +import { capture } from "@/shared/lib/capture"; const ReadOnlyBanner = () => { return ( @@ -23,10 +23,14 @@ const ReadOnlyBanner = () => {