Skip to content

Commit

Permalink
Merge pull request #99 from hlxsites/sidebar-customerquote
Browse files Browse the repository at this point in the history
Sidebar customerquote
  • Loading branch information
pardeepgera23 authored Nov 10, 2023
2 parents ec6f413 + c9e73da commit 5d88092
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 7 deletions.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
export default function decorate(block) {
const clonedBlock = block.cloneNode(true);
// const sidebarDiv = document.createElement('div');
// sidebarDiv.setAttribute('id', 'sidebar');
const pictureElement = clonedBlock.querySelector('picture');
const moduleDiv = document.createElement('div');
moduleDiv.classList.add('hs_cos_wrapper', 'hs_cos_wrapper_widget', 'hs_cos_wrapper_type_module', 'module-1');
Expand Down Expand Up @@ -34,15 +32,13 @@ export default function decorate(block) {
const imageWrapper = document.createElement('div');
imageWrapper.classList.add('testimonial-headshot', 'text-center');
const image = document.createElement('img');
image.setAttribute('width', 279);
image.setAttribute('height', 325);
image.setAttribute('alt', 'Starter Culture Graphic');
image.setAttribute('width', `${pictureElement.querySelector('img').width}`);
image.setAttribute('height', `${pictureElement.querySelector('img').height}`);
image.setAttribute('alt', `${pictureElement.querySelector('img').alt}`);
image.setAttribute('src', `${pictureElement.querySelector('img').src}`);
imageWrapper.append(image);
moduleDiv.append(quoteboxDiv);
moduleDiv.append(imageWrapper);
// sidebarDiv.append(moduleDiv);
block.textContent = '';
block.append(moduleDiv);
// block.append(sidebarDiv);
}

0 comments on commit 5d88092

Please sign in to comment.