function setSiblingsInert(element) {
  const parentChildren = /** @type {HTMLCollection} */ (element.parentElement?.children);
  for (let i = 0; i < parentChildren.length; i += 1) {
    const sibling = parentChildren[i];

    if (sibling !== element) {
      sibling.setAttribute('inert', '');
      sibling.setAttribute('aria-hidden', 'true');
    }
  }
}
Makes sibling elements inert, sets the inert attribute and aria-hidden for
screen readers.
@param {HTMLElement} element