mirror of
https://github.com/supermemoryai/supermemory.git
synced 2026-10-11 03:37:56 +00:00
The bulk-selection set (`selectedDocumentIds`) lived in AppExperience and was only cleared on explicit "clear", on successful bulk delete, or never. Switching spaces left the previous space's selected ids in the set while the grid rendered a different space, so the selection toolbar still showed them and "Delete selected" would permanently delete documents from another space that the user could no longer see. Clear the selection (and exit selection mode) whenever the active space changes. The functional updates return the previous reference when there is nothing to clear, so the initial mount doesn't cause needless re-renders. |
||
|---|---|---|
| .. | ||
| app | ||
| components | ||
| hooks | ||
| lib | ||
| public | ||
| stores | ||
| .env.example | ||
| .gitignore | ||
| biome.json | ||
| components.json | ||
| globals.css | ||
| instrumentation-client.ts | ||
| middleware.ts | ||
| next.config.ts | ||
| open-next.config.ts | ||
| package.json | ||
| postcss.config.mjs | ||
| README.md | ||
| tsconfig.json | ||
| wrangler.jsonc | ||