From edd26acaa6d1ab6be8d4be5eba6e6c9bbe2e2844 Mon Sep 17 00:00:00 2001 From: Dave Nichols Date: Tue, 23 Jan 2024 11:48:16 +0000 Subject: [PATCH] Adding link to Danaher Unified Search --- blocks/header/header.js | 13 ++++++++++++- styles/gcse.css | 12 ++++++++++++ 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/blocks/header/header.js b/blocks/header/header.js index 01de1286..e9c9b8cd 100644 --- a/blocks/header/header.js +++ b/blocks/header/header.js @@ -48,6 +48,13 @@ function createHeadingElement(input) { return heading; } +function createUnifiedElement(input) { + const unified = document.createElement('span'); + unified.innerHTML = `Want to Search across all Life Sciences Companies of Danaher? Explore Danaher Unified Search`; + unified.classList.add('search-unified'); + return unified; +} + function createCountElement(resultsLength, total) { const count = document.createElement('p'); count.className = 'search-info'; @@ -164,6 +171,9 @@ function createSearchResultsBlock(results, input, total) { // Create GCSE box container const gcseBox = createGcseBox(); + // Create Unified Search element + const unified = createUnifiedElement(input); + // Create heading element const heading = createHeadingElement(input); @@ -173,8 +183,9 @@ function createSearchResultsBlock(results, input, total) { // Append elements to the searchResultsBlock const outer = gcseBox.querySelector('.mmg-gcse-outer'); outer.appendChild(heading); + outer.appendChild(unified); outer.appendChild(count); - + // Create individual result elements results.forEach((result) => { const link = createResultLink(result); diff --git a/styles/gcse.css b/styles/gcse.css index 1f981bc0..946a5be0 100644 --- a/styles/gcse.css +++ b/styles/gcse.css @@ -140,6 +140,18 @@ body.mmg-search-active { padding: 40px 0 } +#mmg-gcse .search-unified { + display: block; + padding: 0 0 15px; + font-size: 16px; + color: white +} + +#mmg-gcse .search-unified a { + font-size: 16px; + color: yellow +} + #mmg-gcse .search-title { padding: 0 0 5px; font-size: 32px;