Skip to content

armgit / dub

Public Imported from GitHub
0

The modern link attribution platform. Loved by world-class engineering teams at Twilio, Zillow, Jobber, Vercel, Raycast, and more.

Update og-section.tsx

Tim Wilsonb699490a01d6
diff --git a/apps/web/ui/modals/add-edit-link-modal/og-section.tsx b/apps/web/ui/modals/add-edit-link-modal/og-section.tsx
index 75db54e2e9..b21543ec14 100644
--- a/apps/web/ui/modals/add-edit-link-modal/og-section.tsx
+++ b/apps/web/ui/modals/add-edit-link-modal/og-section.tsx
@@ -12,7 +12,7 @@ import {
Switch,
Unsplash,
} from "@dub/ui";
-import { FADE_IN_ANIMATION_SETTINGS, resizeImage, truncate } from "@dub/utils";
+import { FADE_IN_ANIMATION_SETTINGS, truncate } from "@dub/utils";
import va from "@vercel/analytics";
import { useCompletion } from "ai/react";
import { motion } from "framer-motion";
@@ -142,21 +142,6 @@ export default function OGSection({
}
}, [completionDescription]);
- const [resizing, setResizing] = useState(false);
- const [dragActive, setDragActive] = useState(false);
-
- const onChangePicture = async (e: React.ChangeEvent<HTMLInputElement>) => {
- const file = e.target.files && e.target.files[0];
- if (!file) return;
- setResizing(true);
- const image = await resizeImage(file);
- setData((prev) => ({ ...prev, image }));
- // delay to prevent flickering
- setTimeout(() => {
- setResizing(false);
- }, 500);
- };
-
useEffect(() => {
if (proxy && props) {
// if custom OG is enabled