Note to first-time contributors: Please open a discussion post in Discussions and describe your changes before submitting a pull request.
Before submitting, make sure you've checked the following:
Target branch: Please verify that the pull request targets the dev branch.
Description: Provide a concise description of the changes made in this pull request.
Changelog: Ensure a changelog entry following the format of Keep a Changelog is added at the bottom of the PR description.
Documentation: Have you updated relevant documentation Open WebUI Docs, or other documentation sources?
Dependencies: Are there any new dependencies? Have you updated the dependency versions in the documentation?
Testing: Have you written and run sufficient tests to validate the changes?
Code review: Have you performed a self-review of your code, addressing any coding standard issues and ensuring adherence to the project's coding standards?
Prefix: To clearly categorize this pull request, prefix the pull request title using one of the following:
BREAKING CHANGE: Significant changes that may affect compatibility
build: Changes that affect the build system or external dependencies
ci: Changes to our continuous integration processes or workflows
chore: Refactor, cleanup, or other non-functional code changes
docs: Documentation update or addition
feat: Introduces a new feature or enhancement to the codebase
fix: Bug fix or error correction
i18n: Internationalization or localization changes
perf: Performance improvement
refactor: Code restructuring for better maintainability, readability, or scalability
style: Changes that do not affect the meaning of the code (white space, formatting, missing semi-colons, etc.)
test: Adding missing tests or correcting existing tests
WIP: Work in progress, a temporary label for incomplete or ongoing work
The modal refactor simplifies and streamlines the tab rendering logic by replacing a long, repetitive set of conditional blocks with a scalable approach.
It replaces hardcoded {#if tabId === ...} blocks with a loop over searchData, which contains tab configuration data (e.g., id, title, icon, and displayTab).
Introduces a reusable <TabButton> component to reduce markup duplication and improve maintainability.
The new TabButton component is built to accomodate WCAG 2.1, helping ensure better support for screen readers and keyboard navigation.
role="tab": Explicitly defines the button as a tab in a tablist. See Understanding SC 4.1.2.
aria-selected={selected}: Indicates whether the tab is currently active. This is for screen reader users to understand which tab is selected. See Understanding SC 4.1.2.
aria-controls={${id}-content}: Links the tab to its corresponding tab panel by ID, allowing assistive tech to associate the tab with the content it controls. That is also why I've added a bunch of ids to content components. Understanding SC 1.3.1:
Added
Changed
This PR replaces a tab-style <button element that navigated to an external site with a standard anchor (<a>).
Using a button to navigate is not best practices when it comes to accessibility. Buttons are expected to trigger in-page actions, such as opening a modal or submitting a form, whereas navigation should be handled by links.
And, personally, I also think it was confusing that I clicked a tab and suddenly navigated to a new page, when all the other tabs changed the content of the modal.
Screen readers and other assistive technologies rely on semantic HTML to make the site make sense for users.
[Insert any additional context, notes, or explanations for the changes]
[Reference any related issues, commits, or other relevant information]
Screenshots or Videos
Hover link
Hover menu item
No hover
Contributor License Agreement
By submitting this pull request, I confirm that I have read and fully agree to the Contributor License Agreement (CLA), and I am providing my contributions under its terms.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.
## 📋 Pull Request Information
**Original PR:** https://github.com/open-webui/open-webui/pull/13879
**Author:** [@sinejespersen](https://github.com/sinejespersen)
**Created:** 5/14/2025
**Status:** ❌ Closed
**Base:** `dev` ← **Head:** `feature/settings-modal-restructure-and-accessibility`
---
### 📝 Commits (8)
- [`0d64a36`](https://github.com/open-webui/open-webui/commit/0d64a36b2e8829f1e626c9a635ce80e350601216) add tab button component
- [`8fd3d21`](https://github.com/open-webui/open-webui/commit/8fd3d2102f23976268ce468c71cd6f6e813307b4) add various icons
- [`0c1a469`](https://github.com/open-webui/open-webui/commit/0c1a46993bd6355680dc257269e237f65d86ac1b) add ids to modal content for aria-controls
- [`2fa2d7c`](https://github.com/open-webui/open-webui/commit/2fa2d7c93909363679eb086343a04ffb04734c69) use icons and tabbutton in settingsmodal
- [`5bb9216`](https://github.com/open-webui/open-webui/commit/5bb921612ced833e2505e0c408c7881b19afc19e) accessibility/contrast of tabbutton
- [`75b9cad`](https://github.com/open-webui/open-webui/commit/75b9cadf589c1f26c8ec5a1272e9411bbb32ec25) add lang typescript to tabbutton script tag
- [`c866c64`](https://github.com/open-webui/open-webui/commit/c866c6420dd51b91470032bd79efe439a4267520) add admin settings link
- [`5738b0f`](https://github.com/open-webui/open-webui/commit/5738b0f99eb28d5a247e68169aef3a21896214c9) add w-full to tab button classes
### 📊 Changes
**19 files changed** (+190 additions, -297 deletions)
<details>
<summary>View changed files</summary>
📝 `src/lib/components/chat/Settings/About.svelte` (+1 -1)
📝 `src/lib/components/chat/Settings/Account.svelte` (+1 -1)
📝 `src/lib/components/chat/Settings/Audio.svelte` (+1 -0)
📝 `src/lib/components/chat/Settings/Chats.svelte` (+1 -1)
📝 `src/lib/components/chat/Settings/Connections.svelte` (+1 -0)
📝 `src/lib/components/chat/Settings/General.svelte` (+1 -1)
📝 `src/lib/components/chat/Settings/Interface.svelte` (+1 -1)
📝 `src/lib/components/chat/Settings/Personalization.svelte` (+1 -0)
📝 `src/lib/components/chat/Settings/Tools.svelte` (+1 -0)
📝 `src/lib/components/chat/SettingsModal.svelte` (+83 -292)
➕ `src/lib/components/chat/TabButton.svelte` (+21 -0)
➕ `src/lib/components/icons/Audio.svelte` (+12 -0)
📝 `src/lib/components/icons/Bolt.svelte` (+1 -0)
➕ `src/lib/components/icons/BusinessCard.svelte` (+11 -0)
➕ `src/lib/components/icons/Cloud.svelte` (+9 -0)
➕ `src/lib/components/icons/InfoSolid.svelte` (+11 -0)
➕ `src/lib/components/icons/Monitor.svelte` (+11 -0)
➕ `src/lib/components/icons/SettingsWheel.svelte` (+11 -0)
➕ `src/lib/components/icons/SpeechBubble.svelte` (+11 -0)
</details>
### 📄 Description
# Pull Request Checklist
### Note to first-time contributors: Please open a discussion post in [Discussions](https://github.com/open-webui/open-webui/discussions) and describe your changes before submitting a pull request.
**Before submitting, make sure you've checked the following:**
- [x] **Target branch:** Please verify that the pull request targets the `dev` branch.
- [x] **Description:** Provide a concise description of the changes made in this pull request.
- [x] **Changelog:** Ensure a changelog entry following the format of [Keep a Changelog](https://keepachangelog.com/) is added at the bottom of the PR description.
- [ ] **Documentation:** Have you updated relevant documentation [Open WebUI Docs](https://github.com/open-webui/docs), or other documentation sources?
- [ ] **Dependencies:** Are there any new dependencies? Have you updated the dependency versions in the documentation?
- [ ] **Testing:** Have you written and run sufficient tests to validate the changes?
- [ ] **Code review:** Have you performed a self-review of your code, addressing any coding standard issues and ensuring adherence to the project's coding standards?
- [ ] **Prefix:** To clearly categorize this pull request, prefix the pull request title using one of the following:
- **BREAKING CHANGE**: Significant changes that may affect compatibility
- **build**: Changes that affect the build system or external dependencies
- **ci**: Changes to our continuous integration processes or workflows
- **chore**: Refactor, cleanup, or other non-functional code changes
- **docs**: Documentation update or addition
- **feat**: Introduces a new feature or enhancement to the codebase
- **fix**: Bug fix or error correction
- **i18n**: Internationalization or localization changes
- **perf**: Performance improvement
- **refactor**: Code restructuring for better maintainability, readability, or scalability
- **style**: Changes that do not affect the meaning of the code (white space, formatting, missing semi-colons, etc.)
- **test**: Adding missing tests or correcting existing tests
- **WIP**: Work in progress, a temporary label for incomplete or ongoing work
# Changelog Entry
### Description
As per https://github.com/open-webui/open-webui/discussions/8908
- Improve text contrast in settings modal by changing the look of "selected", so now the background color changes instead of the text color, and the unselected are not gray but does not have a specific background. See [1.4.3 – Contrast (Minimum) (Level AA)](https://www.w3.org/WAI/WCAG21/Understanding/contrast-minimum.html) and [1.4.6 – Contrast (Enhanced) (Level AAA)](https://www.w3.org/WAI/WCAG21/Understanding/contrast-enhanced.html)
The modal refactor simplifies and streamlines the tab rendering logic by replacing a long, repetitive set of conditional blocks with a scalable approach.
It replaces hardcoded `{#if tabId === ...}` blocks with a loop over searchData, which contains tab configuration data (e.g., `id`, `title`, `icon`, and `displayTab`).
Introduces a reusable `<TabButton>` component to reduce markup duplication and improve maintainability.
The new TabButton component is built to accomodate WCAG 2.1, helping ensure better support for screen readers and keyboard navigation.
- `role="tab"`: Explicitly defines the button as a tab in a tablist. See [Understanding SC 4.1.2](https://www.w3.org/WAI/WCAG21/Understanding/name-role-value.html).
- `aria-selected={selected}`: Indicates whether the tab is currently active. This is for screen reader users to understand which tab is selected. See [Understanding SC 4.1.2](https://www.w3.org/WAI/WCAG21/Understanding/name-role-value.html).
- `aria-controls={${id}-content}`: Links the tab to its corresponding tab panel by ID, allowing assistive tech to associate the tab with the content it controls. That is also why I've added a bunch of `id`s to content components. [Understanding SC 1.3.1: ](https://www.w3.org/WAI/WCAG21/Understanding/info-and-relationships)
### Added
### Changed
This PR replaces a tab-style `<button` element that navigated to an external site with a standard anchor (`<a>`).
Using a button to navigate is not best practices when it comes to accessibility. Buttons are expected to trigger in-page actions, such as opening a modal or submitting a form, whereas navigation should be handled by links.
And, personally, I also think it was confusing that I clicked a tab and suddenly navigated to a new page, when all the other tabs changed the content of the modal.
Screen readers and other assistive technologies rely on semantic HTML to make the site make sense for users.
See [Success Criterion 4.1.2](https://www.w3.org/WAI/WCAG21/Understanding/name-role-value.html)
### Deprecated
N/A
### Removed
N/A
### Fixed
N/A
### Security
N/A
### Breaking Changes
N/A
---
### Additional Information
- [Insert any additional context, notes, or explanations for the changes]
- [Reference any related issues, commits, or other relevant information]
### Screenshots or Videos
**Hover link**
<img width="924" alt="Screenshot 2025-05-14 at 21 35 27" src="https://github.com/user-attachments/assets/54150815-6b5a-4f62-a815-352b6e6d2626" />
**Hover menu item**
<img width="930" alt="Screenshot 2025-05-14 at 21 35 23" src="https://github.com/user-attachments/assets/8809efa7-d377-46bb-811d-71e3131cf836" />
**No hover**
<img width="932" alt="Screenshot 2025-05-14 at 21 35 19" src="https://github.com/user-attachments/assets/bc453c58-15a4-4e05-9255-b2c67bd27a1f" />
### Contributor License Agreement
By submitting this pull request, I confirm that I have read and fully agree to the [Contributor License Agreement (CLA)](/CONTRIBUTOR_LICENSE_AGREEMENT), and I am providing my contributions under its terms.
---
<sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
📋 Pull Request Information
Original PR: https://github.com/open-webui/open-webui/pull/13879
Author: @sinejespersen
Created: 5/14/2025
Status: ❌ Closed
Base:
dev← Head:feature/settings-modal-restructure-and-accessibility📝 Commits (8)
0d64a36add tab button component8fd3d21add various icons0c1a469add ids to modal content for aria-controls2fa2d7cuse icons and tabbutton in settingsmodal5bb9216accessibility/contrast of tabbutton75b9cadadd lang typescript to tabbutton script tagc866c64add admin settings link5738b0fadd w-full to tab button classes📊 Changes
19 files changed (+190 additions, -297 deletions)
View changed files
📝
src/lib/components/chat/Settings/About.svelte(+1 -1)📝
src/lib/components/chat/Settings/Account.svelte(+1 -1)📝
src/lib/components/chat/Settings/Audio.svelte(+1 -0)📝
src/lib/components/chat/Settings/Chats.svelte(+1 -1)📝
src/lib/components/chat/Settings/Connections.svelte(+1 -0)📝
src/lib/components/chat/Settings/General.svelte(+1 -1)📝
src/lib/components/chat/Settings/Interface.svelte(+1 -1)📝
src/lib/components/chat/Settings/Personalization.svelte(+1 -0)📝
src/lib/components/chat/Settings/Tools.svelte(+1 -0)📝
src/lib/components/chat/SettingsModal.svelte(+83 -292)➕
src/lib/components/chat/TabButton.svelte(+21 -0)➕
src/lib/components/icons/Audio.svelte(+12 -0)📝
src/lib/components/icons/Bolt.svelte(+1 -0)➕
src/lib/components/icons/BusinessCard.svelte(+11 -0)➕
src/lib/components/icons/Cloud.svelte(+9 -0)➕
src/lib/components/icons/InfoSolid.svelte(+11 -0)➕
src/lib/components/icons/Monitor.svelte(+11 -0)➕
src/lib/components/icons/SettingsWheel.svelte(+11 -0)➕
src/lib/components/icons/SpeechBubble.svelte(+11 -0)📄 Description
Pull Request Checklist
Note to first-time contributors: Please open a discussion post in Discussions and describe your changes before submitting a pull request.
Before submitting, make sure you've checked the following:
devbranch.Changelog Entry
Description
As per https://github.com/open-webui/open-webui/discussions/8908
The modal refactor simplifies and streamlines the tab rendering logic by replacing a long, repetitive set of conditional blocks with a scalable approach.
It replaces hardcoded
{#if tabId === ...}blocks with a loop over searchData, which contains tab configuration data (e.g.,id,title,icon, anddisplayTab).Introduces a reusable
<TabButton>component to reduce markup duplication and improve maintainability.The new TabButton component is built to accomodate WCAG 2.1, helping ensure better support for screen readers and keyboard navigation.
role="tab": Explicitly defines the button as a tab in a tablist. See Understanding SC 4.1.2.aria-selected={selected}: Indicates whether the tab is currently active. This is for screen reader users to understand which tab is selected. See Understanding SC 4.1.2.aria-controls={${id}-content}: Links the tab to its corresponding tab panel by ID, allowing assistive tech to associate the tab with the content it controls. That is also why I've added a bunch ofids to content components. Understanding SC 1.3.1:Added
Changed
This PR replaces a tab-style
<buttonelement that navigated to an external site with a standard anchor (<a>).Using a button to navigate is not best practices when it comes to accessibility. Buttons are expected to trigger in-page actions, such as opening a modal or submitting a form, whereas navigation should be handled by links.
And, personally, I also think it was confusing that I clicked a tab and suddenly navigated to a new page, when all the other tabs changed the content of the modal.
Screen readers and other assistive technologies rely on semantic HTML to make the site make sense for users.
See Success Criterion 4.1.2
Deprecated
N/A
Removed
N/A
Fixed
N/A
Security
N/A
Breaking Changes
N/A
Additional Information
Screenshots or Videos
Hover link
Hover menu item
No hover
Contributor License Agreement
By submitting this pull request, I confirm that I have read and fully agree to the Contributor License Agreement (CLA), and I am providing my contributions under its terms.
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.