refactor(core): adjust core struct (#8218)

packages/frontend/core/src

hooks -> components/hooks
atoms -> components/atoms
layouts -> components/layouts
providers -> components/providers
mixpanel -> @affine/track
~~shared~~
~~unexpected-application-state~~
This commit is contained in:
EYHN
2024-09-13 11:31:21 +00:00
parent fc7e7a37ee
commit 5e56ec65e3
274 changed files with 552 additions and 902 deletions

View File

@@ -1,6 +1,5 @@
import { mixpanel } from '@affine/core/mixpanel';
import type { EventProps } from '@affine/core/mixpanel/types';
import type { QuotaQuery } from '@affine/graphql';
import { mixpanel } from '@affine/track';
import type { GlobalContextService } from '@toeverything/infra';
import { ApplicationStarted, OnEvent, Service } from '@toeverything/infra';
@@ -72,7 +71,7 @@ export class TelemetryService extends Service {
);
}
extractGlobalContext(): EventProps {
extractGlobalContext(): { page?: string } {
const globalContext = this.globalContextService.globalContext;
const page = globalContext.isDoc.get()
? globalContext.isTrashDoc.get()