From bf906e87081b6c090ef64045fd970d92c223d094 Mon Sep 17 00:00:00 2001 From: Christopher Heintzman Date: Fri, 15 Dec 2023 10:47:00 -0500 Subject: [PATCH 1/3] Changed decorate(block) to use getBaseConfigPath() to create adp-logo href --- blocks/adp-header/adp-header.js | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/blocks/adp-header/adp-header.js b/blocks/adp-header/adp-header.js index b9864550..7774ab8e 100644 --- a/blocks/adp-header/adp-header.js +++ b/blocks/adp-header/adp-header.js @@ -105,13 +105,24 @@ function toggleMenu(nav, navSections, forceExpanded = null) { */ export default async function decorate(block) { block.textContent = ''; + + // Kaleidoscope + let logoHome = null; + + if (await window.adobeIMS?.getProfile() != null) { + logoHome = `${getBaseConfigPath()}/` + 'assets'; + } else { + logoHome = `${getBaseConfigPath()}/`; + } + console.log(logoHome); + // decorate nav DOM const nav = document.createElement('nav'); nav.id = 'nav'; nav.innerHTML = `