From c1c24f429fc8dd8c27871c8d9c45c1a934f8b88b Mon Sep 17 00:00:00 2001
From: Yuval Adam <_@yuv.al>
Date: Mon, 10 Mar 2025 11:26:42 +0100
Subject: Remove dynamic canonical

---
 src/pages/embed/EmbedPage.tsx | 19 ++++++++-----------
 1 file changed, 8 insertions(+), 11 deletions(-)

(limited to 'src/pages/embed/EmbedPage.tsx')

diff --git a/src/pages/embed/EmbedPage.tsx b/src/pages/embed/EmbedPage.tsx
index c75a4f7..35417c0 100644
--- a/src/pages/embed/EmbedPage.tsx
+++ b/src/pages/embed/EmbedPage.tsx
@@ -3,26 +3,23 @@ import MorseGame from '../../components/MorseGame';
 import '../../styles.css';
 
 const EmbedPage = () => {
-  // Add meta tag for WebView compatibility
+  // Add meta tag for WebView compatibility and set page title
   useEffect(() => {
     // Set viewport for better mobile display
     const viewportMeta = document.createElement('meta');
     viewportMeta.name = 'viewport';
     viewportMeta.content = 'width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no';
     document.head.appendChild(viewportMeta);
-    
-    // Set canonical URL
-    const canonicalLink = document.createElement('link');
-    canonicalLink.rel = 'canonical';
-    canonicalLink.href = 'https://morsehero.com/embed';
-    document.head.appendChild(canonicalLink);
-    
+
     // Set page title
     document.title = 'Morse Hero | Embed';
-    
+
     return () => {
-      document.head.removeChild(viewportMeta);
-      document.head.removeChild(canonicalLink);
+      // Remove viewport meta tag when component unmounts
+      const metaTag = document.querySelector('meta[name="viewport"]');
+      if (metaTag && metaTag.parentNode) {
+        metaTag.parentNode.removeChild(metaTag);
+      }
     };
   }, []);
 
-- 
cgit v1.3.1

