unsloth/studio/frontend/src/features/auth
Daniel Han 494e0e6fe4
studio: let users change their password from Settings (#6520)
* studio: let users change their password from Settings

The only day-to-day way to change credentials was the destructive console command
'unsloth studio reset-password' (it deletes auth.db); the in-app change-password
page is the forced first-login flow and bounces non-forced users to /login.

Add a Change password control to Settings > General > Account: a small dialog
that takes the current and new password and calls the existing
POST /api/auth/change-password, then stores the rotated tokens it returns.
Username changes remain out of scope.

The dialog uses authFetch, so an expired access token is refreshed and the
request retried instead of failing with a spurious expired-token error for a user
who left Studio open past the token lifetime. The row is hidden in the Tauri
desktop app, which authenticates via desktop auto-auth with a generated secret:
there is no user-entered password to change there, and changing it would clear
the desktop secret.

* studio: harden settings password change

* studio: harden settings password dialog UX

---------

Co-authored-by: wasimysaid <wasimysdev@gmail.com>
2026-06-22 07:49:13 -07:00
..
components Studio: UI polish for sidebar, menus, hub and toasts (#6288) 2026-06-13 03:50:36 -07:00
api.ts Studio: llama.cpp update banner redesign, About tab license info, UI polish (#6196) 2026-06-11 09:27:34 -07:00
change-password-page.tsx Tone down the green glow on the login and password setup pages (#6185) 2026-06-10 23:55:20 -07:00
index.ts studio: let users change their password from Settings (#6520) 2026-06-22 07:49:13 -07:00
login-page.tsx Studio: login card polish and sidebar label alignment (#6242) 2026-06-12 04:15:49 -07:00
session.ts Studio frontend: reduce and tighten code comments (#6099) 2026-06-08 23:10:35 -07:00
tauri-auto-auth.ts Studio: llama.cpp update banner redesign, About tab license info, UI polish (#6196) 2026-06-11 09:27:34 -07:00