I'm seeing some inconsistency with the keyboard tabbing order when I use tabsets.

In [this example](https://github.com/360-info/report-global-education/blob/main/embed-bycountry.qmd), in which I've styled the tabs to appear at the bottom of the page ([deployed version available here](https://360info-studentflows.pages.dev/embed-bycountry)), the tabs have `tabindex="0"` and so are tabbable - but tabbing to put focus on them activates them, so it's impossible to then tab onto focusable elements within the tabset content (eg. checkboxes or dropdowns) unless you click on one of them first.

In the following example, the tabs aren't receiving any `tabindex` attribute at all and so aren't tabbable:

````
---
title: "Test tabs"
author: "jimjamslam"
---

Let's try some tabs!

::: {.panel-tabset}

## Tab A

This is just some explanatory text. No biggie...

## Tab B

Let's add some focusable controls here!

```{ojs}
viewof catSelect = Inputs.select(
  ["Apple", "Banana", "Orange", "Kiwi"],
  { label: "Choose a fruit"});

viewof numSelect = Inputs.range([1, 20], { label: "And a number" });
```

## Tab C

Some more text here! Could be lots of stuff.

```{ojs}
viewof check = Inputs.checkbox(
  ["Don't forget to check this!"],
  { label: "Options" })
```
## Tab D

Nah, this is all boring.

:::
````

Ideally, I expect that tabset tabs would be tabbable, but that tabbing onto a different tab would focus it without activating it so that I could continue on to any controls visible (unless I explicitly activated it as I might a hyperlink).

I'm not quite sure why the tabs in my first example have `tabindex` and the ones in my second don't, unless there's been a change in behaviour that I missed (although I believe I rendered them both with them same versions of everything). (Maybe the styling I used on the tabs in the first, adding `display: flex` and `flex-direction: column-reverse` to `.panel-tabset` to put the tabs below the content, did something weird?)

I think I've said "tab" enough for the rest of the year now 😂
2022-04-26T01:47:35Z
jimjam-slam
Future
open
Keyboard tabbing order of tabset tabs and focusable controls within tabset content
https://github.com/quarto-dev/quarto-cli/issues/730