Changesets · Branches · Tags · Compare
| Changeset | 3bd64ca0c761a9fb1b15bba33e25b48f90cb557f756461ad3fecec77f12d21d2 |
|---|---|
| Author | Patrick Erichsen <patrick.a.erichsen@gmail.com> · 2025-07-09 11:04 -07:00 |
| Committer | Patrick Erichsen <patrick.a.erichsen@gmail.com> · 2025-07-09 11:04 -07:00 |
| Parents | f96a5adcf583 |
2 files changed
deleted gui/src/components/dialogs/FeedbackDialog.tsx +0 −64
| @@ -1,64 +0,0 @@ | ||
| 1 | -import { usePostHog } from "posthog-js/react"; | |
| 2 | -import { setDialogMessage } from "../../redux/slices/uiSlice"; | |
| 3 | -import { useAppDispatch } from "../../redux/hooks"; | |
| 4 | - | |
| 5 | -export default function FeedbackDialog() { | |
| 6 | - const posthog = usePostHog(); | |
| 7 | - const dispatch = useAppDispatch(); | |
| 8 | - | |
| 9 | - return ( | |
| 10 | - <div className="p-4 text-center"> | |
| 11 | - 👋 Thanks for using Continue. We are always trying to improve and love | |
| 12 | - hearing from users. If you're interested in speaking, enter your name and | |
| 13 | - email. We won't use this information for anything other than reaching out. | |
| 14 | - <br /> | |
| 15 | - <br /> | |
| 16 | - <form | |
| 17 | - onSubmit={(e: any) => { | |
| 18 | - e.preventDefault(); | |
| 19 | - posthog?.capture("user_interest_form", { | |
| 20 | - name: e.target.elements[0].value, | |
| 21 | - email: e.target.elements[1].value, | |
| 22 | - }); | |
| 23 | - dispatch( | |
| 24 | - setDialogMessage( | |
| 25 | - <div className="p-4 text-center"> | |
| 26 | - Thanks! We'll be in touch soon. | |
| 27 | - </div>, | |
| 28 | - ), | |
| 29 | - ); | |
| 30 | - }} | |
| 31 | - style={{ | |
| 32 | - display: "flex", | |
| 33 | - flexDirection: "column", | |
| 34 | - gap: "10px", | |
| 35 | - }} | |
| 36 | - > | |
| 37 | - <input | |
| 38 | - style={{ padding: "10px", borderRadius: "5px" }} | |
| 39 | - type="text" | |
| 40 | - name="name" | |
| 41 | - placeholder="Name" | |
| 42 | - required | |
| 43 | - /> | |
| 44 | - <input | |
| 45 | - style={{ padding: "10px", borderRadius: "5px" }} | |
| 46 | - type="email" | |
| 47 | - name="email" | |
| 48 | - placeholder="Email" | |
| 49 | - required | |
| 50 | - /> | |
| 51 | - <button | |
| 52 | - style={{ | |
| 53 | - padding: "10px", | |
| 54 | - borderRadius: "5px", | |
| 55 | - cursor: "pointer", | |
| 56 | - }} | |
| 57 | - type="submit" | |
| 58 | - > | |
| 59 | - Submit | |
| 60 | - </button> | |
| 61 | - </form> | |
| 62 | - </div> | |
| 63 | - ); | |
| 64 | -} |
modified gui/src/pages/gui/Chat.tsx +0 −20
| @@ -16,7 +16,6 @@ | ||
| 16 | 16 | import { ErrorBoundary } from "react-error-boundary"; |
| 17 | 17 | import styled from "styled-components"; |
| 18 | 18 | import { Button, lightGray, vscBackground } from "../../components"; |
| 19 | -import FeedbackDialog from "../../components/dialogs/FeedbackDialog"; | |
| 20 | 19 | import { useFindWidget } from "../../components/find/FindWidget"; |
| 21 | 20 | import TimelineItem from "../../components/gui/TimelineItem"; |
| 22 | 21 | import { NewSessionButton } from "../../components/mainInput/belowMainInput/NewSessionButton"; |
| @@ -37,18 +36,12 @@ | ||
| 37 | 36 | newSession, |
| 38 | 37 | updateToolCallOutput, |
| 39 | 38 | } from "../../redux/slices/sessionSlice"; |
| 40 | -import { | |
| 41 | - setDialogEntryOn, | |
| 42 | - setDialogMessage, | |
| 43 | - setShowDialog, | |
| 44 | -} from "../../redux/slices/uiSlice"; | |
| 45 | 39 | import { streamEditThunk } from "../../redux/thunks/edit"; |
| 46 | 40 | import { loadLastSession } from "../../redux/thunks/session"; |
| 47 | 41 | import { streamResponseThunk } from "../../redux/thunks/streamResponse"; |
| 48 | 42 | import { isJetBrains, isMetaEquivalentKeyPressed } from "../../util"; |
| 49 | 43 | |
| 50 | 44 | import { cancelStream } from "../../redux/thunks/cancelStream"; |
| 51 | -import { getLocalStorage, setLocalStorage } from "../../util/localStorage"; | |
| 52 | 45 | import { EmptyChatBody } from "./EmptyChatBody"; |
| 53 | 46 | import { ExploreDialogWatcher } from "./ExploreDialogWatcher"; |
| 54 | 47 | import { ToolCallDiv } from "./ToolCallDiv"; |
| @@ -221,19 +214,6 @@ | ||
| 221 | 214 | editorToClearOnSend.commands.clearContent(); |
| 222 | 215 | } |
| 223 | 216 | } |
| 224 | - | |
| 225 | - // Increment localstorage counter for popup | |
| 226 | - const currentCount = getLocalStorage("mainTextEntryCounter"); | |
| 227 | - if (currentCount) { | |
| 228 | - setLocalStorage("mainTextEntryCounter", currentCount + 1); | |
| 229 | - if (currentCount === 300) { | |
| 230 | - dispatch(setDialogMessage(<FeedbackDialog />)); | |
| 231 | - dispatch(setDialogEntryOn(false)); | |
| 232 | - dispatch(setShowDialog(true)); | |
| 233 | - } | |
| 234 | - } else { | |
| 235 | - setLocalStorage("mainTextEntryCounter", 1); | |
| 236 | - } | |
| 237 | 217 | }, |
| 238 | 218 | [ |
| 239 | 219 | history, |