I am unable to tab through q-tabs. It allows you to tab into the first, selected one,…
- User
I am unable to tab through q-tabs. It allows you to tab into the first, selected one, but I can't tab into the rest. <q-tab style="width: 100%" :disable="!loaded" :name="instance.label" v-for="(instance, index) in instances" @click="switchTab(index)" :id="instance.label + '-button'">{{ instance.label }} <q-tab v-if="isSuper && instances.length < 3" icon="add" :disable="!loaded" @click="openAdd()">
- Assistant
You can use the "tabindex" attribute to make the q-tabs focusable and enable tabbing through them. Here's an example of how you can modify your code to enable tabbing through all q-tabs:
code<q-tabs v-model="activeInstance" dense style="background-color: #efefef;" class="tabs" active-class="bg-negative text-white" indicator-color="negative" align="justify"> <q-tab v-for="(instance, index) in instances" :key="index" :disable="!loaded" :name="instance.label" :id="instance.label + '-button'" :tabindex="activeInstance === instance.label ? 0 : -1"> {{ instance.label }} </q-tab> <!-- For adding dev test or prod--> <q-tab v-if="isSuper && instances.length < 3" icon="add" :disable="!loaded" @click="openAdd()" :tabindex="instances.length"></q-tab> </q-tabs>