From 6da1317fb121f1ffd3ea5bf6b9604aec9e313b58 Mon Sep 17 00:00:00 2001 From: Wesley Finck Date: Thu, 6 Nov 2025 17:19:32 -0500 Subject: [PATCH] fix: resolve React javascript URL security block for bookmarklet Co-authored-by: aider (anthropic/claude-sonnet-4-20250514) --- src/webapp/app/bookmarklet/page.tsx | 26 ++++++++------------------ 1 file changed, 8 insertions(+), 18 deletions(-) diff --git a/src/webapp/app/bookmarklet/page.tsx b/src/webapp/app/bookmarklet/page.tsx index a49d12bf..79f1ab35 100644 --- a/src/webapp/app/bookmarklet/page.tsx +++ b/src/webapp/app/bookmarklet/page.tsx @@ -10,11 +10,9 @@ import { Alert, Box, Group, - Anchor, } from '@mantine/core'; import { useState } from 'react'; import { BiInfoCircle } from 'react-icons/bi'; -import { RiDragDropLine } from 'react-icons/ri'; export default function BookmarkletPage() { const [copied, setCopied] = useState(false); @@ -37,6 +35,13 @@ export default function BookmarkletPage() { } }; + // Create the bookmarklet link using dangerouslySetInnerHTML to bypass React's security check + const createBookmarkletLink = () => { + return { + __html: `Open in Semble` + }; + }; + return ( @@ -70,22 +75,7 @@ export default function BookmarkletPage() { Drag this button directly to your browser's bookmarks bar: - - - Open in Semble - + -- 2.51.2