Repository navigation
Conversation
Styleguidist caches a stylesheet by component name, and the Markdown table and the props table are both called TableRenderer. Whichever rendered first in a session styled both, so after a page with a table in its documentation every props, events and slots table lost its padding, borders and column widths. The Markdown table now renders under its own name with the same styles. Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Remko <remko@conduction.nl>
Renders a row of tabs and the panel of the selected tab, for switching between views in the app content. The tabs are passed as data and the selected one is bound with v-model; each panel is a panel-<id> slot and only the selected one is rendered. A tab can have an icon, a count and be disabled. Follows the ARIA tabs pattern: arrow keys, Home and End move between the enabled tabs and select them. The tabs look like the sidebar tabs, with the icon above the name and the tabs sharing the width of the row, including their older look before Nextcloud 34. The row scrolls when the tabs do not fit. Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Remko <remko@conduction.nl>
…h the shown tab The row of tabs scrolls, so it clipped the focus outline of the tabs, almost entirely in the look before Nextcloud 34. It now leaves room for the outline. In forced colors the selected tab looked like the others; its bar is now drawn in the system highlight color. When the model is a disabled, unknown or removed tab, the first enabled tab is shown and now also becomes the model. The tablist can be named by a visible heading with the new ariaLabelledby prop. The ellipsis rules that never applied are removed. Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Remko <remko@conduction.nl>
The element ids were built from the tab ids, so a tab id with whitespace broke aria-controls and aria-labelledby, which are lists of ids. They are now built from the position of the tab. The docs also say that a panel starts afresh each time its tab is selected. Assisted-by: ClaudeCode:claude-opus-5-5 Signed-off-by: Remko <remko@conduction.nl>
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #9143 +/- ##
==========================================
+ Coverage 59.11% 59.59% +0.48%
==========================================
Files 125 126 +1
Lines 4520 4574 +54
Branches 1347 1370 +23
==========================================
+ Hits 2672 2726 +54
Misses 1570 1570
Partials 278 278 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
| defineEmits<{ | ||
| /** | ||
| * Another tab was selected. | ||
| * | ||
| * @param id - The `id` of the selected tab | ||
| */ | ||
| 'update:modelValue': [id: string] | ||
| }>() |
There was a problem hiding this comment.
|
|
||
| // When the model is a disabled, unknown or removed tab, another tab is shown: make that | ||
| // the model, so the parent, and for example the URL, hold the tab that is shown | ||
| watch(activeTab, (tab) => { |
There was a problem hiding this comment.
Should we really write the model back? If a tab is disabled while loading, a ?tab=sharing deep link would get lost. Maybe just show the fallback and let the parent handle it?
| :aria-selected="tab === activeTab ? 'true' : 'false'" | ||
| :aria-controls="tab === activeTab ? panelElementId(tab) : undefined" | ||
| :tabindex="tab === activeTab ? 0 : -1" | ||
| :disabled="tab.disabled" |
There was a problem hiding this comment.
With the native disabled, keyboard and screen reader users never land on a disabled tab, so they don't know it's there. Would aria-disabled="true" and keeping it focusable work better? That's what the APG suggests.
| <div | ||
| v-if="activeTab" | ||
| :id="panelElementId(activeTab)" | ||
| :key="activeTab.id" |
There was a problem hiding this comment.
Arrowing through the tabs remounts every panel on the way, which could mean a request per keypress for heavy panels. What about arrows only moving focus, and Enter/Space selecting?
☑️ Resolves
v-model#panel-<id>)Note:
NcAppSidebarTabstays for the sidebar. NcTabs is for tabs in the app content.🖼️ Screenshots
🏁 Checklist
stable8for maintained Vue 2 version or not applicableAI (if applicable)