Skip to content

Commit

Permalink
options fix
Browse files Browse the repository at this point in the history
  • Loading branch information
vradulescu-bd committed Sep 18, 2024
1 parent 685e971 commit a896f5b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion _src/blocks/products-sideview/products-sideview.js
Original file line number Diff line number Diff line change
Expand Up @@ -264,12 +264,13 @@ function updateBenefits(block) {
}

function renderSelector(block, ...options) {
const selectorOptions = options.filter((option) => option && !Number.isNaN(Number(option)));
const el = document.createElement('div');
el.classList.add('products-sideview-selector');

el.innerHTML = `
<select>
${options.map((opt, index) => `
${selectorOptions.map((opt, index) => `
<option value="${index}">${opt} members</option>
`).join(',')}
</select>
Expand Down

0 comments on commit a896f5b

Please sign in to comment.