code: function scrollOnePage(element, downward) {
  
    // Determine the item visible just at the edge of direction we're heading.
    // We'll select that item if it's not already selected.
    const scrollTarget = element.scrollTarget;
    const edge = scrollTarget.scrollTop + (downward ? scrollTarget.clientHeight : 0);
    const indexOfItemAtEdge = getIndexOfItemAtY(element, edge, downward);
  
    const selectedIndex = element.selectedIndex;
    let newIndex;
    if (indexOfItemAtEdge && selectedIndex === indexOfItemAtEdge) {
      // The item at the edge was already selected, so scroll in the indicated
      // direction by one page. Leave the new item at that edge selected.
      const delta = (downward ? 1 : -1) * scrollTarget.clientHeight;
      newIndex = getIndexOfItemAtY(element, edge + delta, downward);
    }
    else {
      // The item at the edge wasn't selected yet. Instead of scrolling, we'll
      // just select that item. That is, the first attempt to page up/down
      // usually just moves the selection to the edge in that direction.
      newIndex = indexOfItemAtEdge;
    }
  
    if (!newIndex) {
      // We can't find an item in the direction we want to travel. Select the
      // last item (if moving downward) or first item (if moving upward).
      newIndex = (downward ? element.items.length - 1 : 0);
    }
  
    if (newIndex !== selectedIndex) {
      element.selectedIndex = newIndex;
      return true; // We handled the page up/down ourselves.
    }
    else {
      return false; // We didn't do anything.
    }
  }
docs: Move by one page downward (if downward is true), or upward (if false). Return true if we ended up changing the selection, false if not. TODO: Better support for horizontal lists.