mirror of
https://github.com/home-assistant/frontend.git
synced 2025-12-24 20:55:49 +00:00
Save default panel at user and system level (#27899)
* Save default panel in user data * Change logic for default panel * Fix types * Fix typings * Fix user and local storage * Use user data and system data * Update url path and update dashboard settings * Fix tests * Wait for panels and user/system data to be loaded * Update comment * Update comment * Set empty object instead of null * Update comment * Feedbacks * Apply suggestions from code review * format --------- Co-authored-by: Petar Petrov <MindFreeze@users.noreply.github.com>
This commit is contained in:
@@ -24,7 +24,7 @@ describe("ha-pref-storage", () => {
|
||||
window.localStorage.setItem = vi.fn();
|
||||
|
||||
storeState(mockHass as unknown as HomeAssistant);
|
||||
expect(window.localStorage.setItem).toHaveBeenCalledTimes(8);
|
||||
expect(window.localStorage.setItem).toHaveBeenCalledTimes(7);
|
||||
expect(window.localStorage.setItem).toHaveBeenCalledWith(
|
||||
"dockedSidebar",
|
||||
JSON.stringify("auto")
|
||||
|
||||
Reference in New Issue
Block a user