dify/web/app/components/billing/apps-full-in-dialog
yyh 72b96ba972
refactor(web): remove mutateCurrentWorkspace from AppContext, use service-layer invalidation hook
The previous implementation stored query invalidation logic (mutateCurrentWorkspace) and
isFetching state (isValidatingCurrentWorkspace) in React Context, causing QuotaPanel to
flash a loading spinner on every settings tab switch due to a useEffect calling
invalidateQueries on mount. This violated separation of concerns and React best practices.

- Remove mutateCurrentWorkspace and isValidatingCurrentWorkspace from AppContext
- Add useInvalidateCurrentWorkspace hook in service layer (consistent with project pattern)
- Remove redundant useEffect + invalidateQueries in ModelProviderPage
- QuotaPanel now derives loading from !currentWorkspace.id instead of external prop
- Update custom-web-app-brand to use the new service-layer hook
2026-02-09 18:32:15 +08:00
..
index.spec.tsx refactor(web): remove mutateCurrentWorkspace from AppContext, use service-layer invalidation hook 2026-02-09 18:32:15 +08:00
index.tsx refactor(i18n): use JSON with flattened key and namespace (#30114) 2025-12-29 14:52:32 +08:00
style.module.css Enhance Code Consistency Across Repository with .editorconfig (#19023) 2025-04-29 18:04:33 +08:00