From faba14ff9f4d5fc6d583e58fe075aa0091022fcf Mon Sep 17 00:00:00 2001 From: jflheureux <2000200+jflheureux@users.noreply.github.com> Date: Sun, 12 Nov 2023 22:18:23 -0500 Subject: [PATCH] Connect to live Sitecore XM Cloud Pages URLs --- .github/scripts/start.js | 2 +- popup/app.tsx | 8 +++++++- public/manifest.json | 4 +++- public/manifestv2.json | 4 +++- 4 files changed, 14 insertions(+), 4 deletions(-) diff --git a/.github/scripts/start.js b/.github/scripts/start.js index 0d87bf2..0e939a5 100644 --- a/.github/scripts/start.js +++ b/.github/scripts/start.js @@ -32,7 +32,7 @@ async function startBrowser (browserName) { await browser.installAddOn(extension.toString('base64'), true) } - await browser.url('https://perdu.com') + await browser.url('https://pages.sitecorecloud.io') } const browserName = process.argv.slice(2).pop() || 'chrome' diff --git a/popup/app.tsx b/popup/app.tsx index 81151eb..d6a9cfb 100644 --- a/popup/app.tsx +++ b/popup/app.tsx @@ -36,7 +36,13 @@ const App = () => { const popupHeight = useRef(''); function isSupportedUrl(url) { - return url?.startsWith('https://perdu.com') + if (!url) { + return false + } + + return url.startsWith('https://pages.sitecorecloud.io') || + url.startsWith('https://pages.sitecore.io') || + url.startsWith('https://symphony.sitecorecloud.io') } function handleInfoButtonClick() { diff --git a/public/manifest.json b/public/manifest.json index 7446359..09b603c 100644 --- a/public/manifest.json +++ b/public/manifest.json @@ -22,7 +22,9 @@ "scripting" ], "host_permissions": [ - "https://perdu.com/*" + "https://pages.sitecorecloud.io/*", + "https://pages.sitecore.io/*", + "https://symphony.sitecorecloud.io/*" ], "icons": { "72": "icon-72x72.png", diff --git a/public/manifestv2.json b/public/manifestv2.json index 893237f..5198f1c 100644 --- a/public/manifestv2.json +++ b/public/manifestv2.json @@ -17,7 +17,9 @@ }, "permissions": [ "scripting", - "https://perdu.com/*" + "https://pages.sitecorecloud.io/*", + "https://pages.sitecore.io/*", + "https://symphony.sitecorecloud.io/*" ], "icons": { "72": "icon-72x72.png",