Commit Graph

918 Commits

Author SHA1 Message Date
G30
202f47ece8 fix(ui): stop sidebar chat rows flickering while the pointer moves across them (#27474) 2026-07-26 17:57:44 -04:00
Classic298
ba4c92c4f0 fix: make sidebar section headers keyboard operable (WCAG 2.1.1, 4.1.2) (#27489)
On latest `dev`, each sidebar section header in `Sidebar/Section.svelte` is a real `<button>` carrying `aria-expanded` and `aria-controls`, but it has **no activation handler**. The toggle comes only from `on:pointerup` on the wrapper inside `common/Collapsible.svelte`.

Keyboard activation dispatches a synthetic `click`, never `pointerup`, and that wrapper's own `on:click` handler calls `stopPropagation()`. So pressing Enter or Space on the header does nothing at all, while `aria-expanded` tells assistive technology this is a working disclosure control.

This affects every section in the sidebar: Models, Notes, Channels, Folders and Chats. Section state is persisted to `localStorage`, so a user whose section was collapsed on a previous visit has no keyboard way to open it again, and the content stays unreachable.

Breaks WCAG 2.1.1 Keyboard (Level A), and 4.1.2 Name, Role, Value (Level A), because the exposed expanded state belongs to a control that cannot be operated.

Fix: handle activation on the header button itself, where focus actually lands, and stop the now duplicate pointer path so a mouse click does not toggle twice. The existing inline `onChange` body is extracted to `setOpen` so the `change` dispatch and the `localStorage` write stay in one place and fire exactly once per toggle in both input modes. The adjacent "+" (`onAdd`) button already stops both `pointerup` and `click`, so it still does not toggle the section.

`Collapsible`'s wrapper cannot simply become a `<button>` instead, because its slot receives buttons from this component and others, so the fix belongs here.

`common/Folder.svelte` and `Sidebar/RecursiveFolder.svelte` have the same latent defect and are not touched by this PR.

Severity: Critical. Sidebar navigation cannot be expanded without a mouse.

### Contributor License Agreement

<!--
🚨 DO NOT DELETE THE TEXT BELOW 🚨
Keep the "Contributor License Agreement" confirmation text intact.
Deleting it will trigger the CLA-Bot to INVALIDATE your PR.

Your PR will NOT be reviewed or merged until you check the box below confirming that you have read and agree to the terms of the CLA.
-->

- [x] By submitting this pull request, I confirm that I have read and fully agree to the [Contributor License Agreement (CLA)](https://github.com/open-webui/open-webui/blob/main/CONTRIBUTOR_LICENSE_AGREEMENT), and I am providing my contributions under its terms.

> [!NOTE]
> Deleting the CLA section will lead to immediate closure of your PR and it will not be merged in.
2026-07-26 17:38:06 -04:00
G30
4ac22b89fd fix: don't wipe sidebar folder chat list when a refresh overlaps an in-flight fetch (#27535) 2026-07-26 17:28:15 -04:00
G30
29499cb4ba perf: dedupe folder refetches and chat-list sweeps on sidebar folder selection (#27540) 2026-07-26 17:27:33 -04:00
G30
4d576c1aa2 chore: remove no-op stopPropagation statement from folder title click handler (#27542) 2026-07-26 17:27:12 -04:00
G30
65209b0235 fix: enforce a single open chat hover preview across sidebar chat items (#27549) 2026-07-26 17:26:49 -04:00
G30
06d2189b26 fix(chat): keep sidebar chat selection in sync with the active chat (#26977)
When navigating from a chat to a non-chat route (e.g. the admin panel),
the previously-viewed chat stayed selected in the sidebar and
deleting/archiving it wrongly redirected back to the new-chat page.
Cloning a chat also left the source chat highlighted alongside the new
clone, so two chats appeared selected at once.

Two independent sources kept the stale selection:

- The chatId store was never cleared when the Chat component unmounted,
  so $chatId still pointed at the last-viewed chat (this drove the
  delete/archive redirect). Clear chatId/chatTitle in Chat's onDestroy.
- The sidebar's optimistic selectedChatId highlight, set on click, was
  only cleared on window blur (hence it appeared to fix itself after a
  tab switch) and never followed programmatic navigation. Bind it to the
  chatId store so it tracks the active chat for leave, delete and clone.
2026-07-24 01:45:37 -05:00
Timothy Jaeryang Baek
381ababeba refac 2026-07-24 00:40:21 -04:00
G30
4fca375ad4 chore: remove unused ArchivedChatsModal component (#27308) 2026-07-23 21:54:45 -04:00
Timothy Jaeryang Baek
e769f9ff4f refac 2026-07-23 17:53:13 -04:00
Timothy Jaeryang Baek
93bd05271c refac 2026-07-23 13:40:30 -04:00
Timothy Jaeryang Baek
3026ac64a2 refac 2026-07-23 13:36:35 -04:00
Timothy Jaeryang Baek
1513ddaf58 refac 2026-07-23 12:25:17 -04:00
Timothy Jaeryang Baek
aaf2834db7 refac 2026-07-23 12:03:26 -04:00
Timothy Jaeryang Baek
d0f7da4f45 refac 2026-07-23 04:45:27 -04:00
Timothy Jaeryang Baek
409fb39717 refac 2026-07-21 13:53:30 -04:00
Timothy Jaeryang Baek
743b9fd3ce refac 2026-07-16 21:57:43 -04:00
Timothy Jaeryang Baek
d7f33996ee refac 2026-07-16 02:49:21 -04:00
Timothy Jaeryang Baek
2e857a82d7 refac 2026-07-16 02:47:51 -04:00
Timothy Jaeryang Baek
f0eea61155 refac 2026-07-16 02:21:46 -04:00
Timothy Jaeryang Baek
dc5a250068 refac 2026-07-16 02:07:47 -04:00
Timothy Jaeryang Baek
c1e228d6ad refac 2026-07-16 00:10:28 -04:00
Timothy Jaeryang Baek
ba067258de refac 2026-07-15 17:50:26 -04:00
Timothy Jaeryang Baek
db934a3b4f refac 2026-07-15 16:51:08 -04:00
Timothy Jaeryang Baek
86f55d04ec refac 2026-07-15 16:21:47 -04:00
Timothy Jaeryang Baek
946487a3ba refac 2026-07-15 16:04:08 -04:00
Timothy Jaeryang Baek
3ce3c52936 refac 2026-07-15 05:17:41 -04:00
Timothy Jaeryang Baek
343eb1d659 refac 2026-07-15 04:52:06 -04:00
Timothy Jaeryang Baek
91277726cd refac 2026-07-15 04:35:52 -04:00
Timothy Jaeryang Baek
9499587c33 refac 2026-07-15 04:25:51 -04:00
Timothy Jaeryang Baek
622767d724 refac 2026-07-15 02:49:46 -04:00
Timothy Jaeryang Baek
43e792a8f4 refac 2026-07-15 01:16:06 -04:00
Timothy Jaeryang Baek
e05f9fa17e refac 2026-07-15 00:30:28 -04:00
Timothy Jaeryang Baek
63ada24706 refac 2026-07-15 00:14:01 -04:00
Timothy Jaeryang Baek
254888cf15 refac 2026-07-14 23:20:15 -04:00
Timothy Jaeryang Baek
6772b1cb4f refac 2026-07-14 14:41:12 -04:00
Timothy Jaeryang Baek
9f17c5960a refac 2026-07-14 14:33:10 -04:00
Timothy Jaeryang Baek
3be493f5b0 refac 2026-07-14 04:53:37 -04:00
Timothy Jaeryang Baek
7b2efdff08 refac 2026-07-14 04:20:28 -04:00
Timothy Jaeryang Baek
aedb6bef4e refac 2026-07-14 04:15:20 -04:00
Timothy Jaeryang Baek
5929bf2061 refac 2026-07-14 04:02:42 -04:00
Timothy Jaeryang Baek
1b64ccbaa0 refac 2026-07-14 04:02:28 -04:00
Timothy Jaeryang Baek
2e8d92c7b1 refac 2026-07-14 03:43:34 -04:00
Timothy Jaeryang Baek
d475cb9174 refac 2026-07-14 03:10:12 -04:00
Timothy Jaeryang Baek
d8131d1091 refac 2026-07-14 02:37:21 -04:00
Timothy Jaeryang Baek
b9d5462ed0 refac 2026-07-14 02:11:38 -04:00
Timothy Jaeryang Baek
b012d683d8 refac 2026-07-14 01:40:58 -04:00
Timothy Jaeryang Baek
6e14d0d627 refac 2026-07-14 01:39:40 -04:00
Timothy Jaeryang Baek
f1584b5a37 refac 2026-07-14 00:48:40 -04:00
Timothy Jaeryang Baek
009715cd63 refac 2026-07-14 00:22:00 -04:00