super-productivity/src
Johannes Millan 0065d291cc
fix(task-view-customizer): reset sort/group/filter on work context change (#7263)
* fix(task-view-customizer): reset sort/group/filter on work context change

The TaskViewCustomizerService persisted its sort/group/filter options in
localStorage and never reset them when the active work context changed,
causing customizations to leak across projects, tags and the Today view.
Users reported that switching to a project or tag still applied the
previous filter, forcing a manual "Reset all" click.

Subscribe to activeWorkContextTypeAndId$ (skipping the initial emission so
persisted state survives across reloads in the same context) and call
resetAll() whenever the context changes.

Fixes #7262

* refactor(task-view-customizer): persist sort/group/filter per work context

Replace the three global localStorage keys with a single map keyed by
work-context (`${type}:${id}`). Each context now has its own independent
customization state — filters set in Project A stay with Project A, and
returning to it restores them. This replaces the previous blanket
"reset on context change" fix, which neutralized persistence entirely
after the first context switch.

Orphaned LS keys (TASK_VIEW_CUSTOMIZER_SORT/GROUP/FILTER) are dropped;
users will lose any previously-persisted state once, which was already
unreliable in 18.2.0+ due to #7262.

Refs #7262

---------

Co-authored-by: Claude <noreply@anthropic.com>
2026-04-18 18:55:12 +02:00
..
app fix(task-view-customizer): reset sort/group/filter on work context change (#7263) 2026-04-18 18:55:12 +02:00
assets fix(config): restore plural for collapse/expand sub-task labels 2026-04-17 19:44:56 +02:00
environments 18.2.2 2026-04-17 22:51:53 +02:00
static
styles feat: change very small container to 356px 2026-04-01 20:23:45 +02:00
test-helpers
typings
_common.scss
favicon.ico
hammer-config.class.ts
index.html
karma.conf.js
main.ts fix(sync): scope interval timer to file-based providers and drop unneeded migration 2026-04-14 22:09:02 +02:00
manifest.json
polyfills.ts
styles.scss
test.ts
tsconfig.app.json
tsconfig.spec.json
tsconfig.worker.json