@makeswift/runtime 0.28.7-canary.1 → 0.28.7-canary.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/api/api-resources-client.js +160 -0
- package/dist/cjs/api/api-resources-client.js.map +1 -0
- package/dist/cjs/api/client.js +20 -182
- package/dist/cjs/api/client.js.map +1 -1
- package/dist/cjs/api-handler/handlers/manifest.js +1 -1
- package/dist/cjs/client/index.js +3 -3
- package/dist/cjs/controls/index.js +2 -2
- package/dist/cjs/controls/index.js.map +1 -1
- package/dist/cjs/next/api-handler/config/pages-router.js +1 -1
- package/dist/cjs/next/api-handler/config/pages-router.js.map +1 -1
- package/dist/cjs/next/fetch.js.map +1 -1
- package/dist/cjs/runtimes/react/hooks/use-cache-data.js +1 -1
- package/dist/cjs/runtimes/react/hooks/use-cache-data.js.map +1 -1
- package/dist/cjs/runtimes/react/hooks/use-resource-resolver.js +11 -32
- package/dist/cjs/runtimes/react/hooks/use-resource-resolver.js.map +1 -1
- package/dist/cjs/runtimes/react/resource-resolver.js +52 -0
- package/dist/cjs/runtimes/react/resource-resolver.js.map +1 -0
- package/dist/cjs/runtimes/react/runtime-core.js.map +1 -1
- package/dist/cjs/slate/InlinePlugin/index.js +1 -1
- package/dist/cjs/slate/InlinePlugin/index.js.map +1 -1
- package/dist/cjs/slate/InlinePlugin/types.js +3 -3
- package/dist/cjs/slate/InlinePlugin/types.js.map +1 -1
- package/dist/cjs/slate/TextAlignPlugin/index.js +5 -5
- package/dist/cjs/slate/TextAlignPlugin/index.js.map +1 -1
- package/dist/cjs/state/actions/internal/read-write-actions.js.map +1 -1
- package/dist/cjs/state/api-client/client-store.js +81 -0
- package/dist/cjs/state/api-client/client-store.js.map +1 -0
- package/dist/cjs/state/{makeswift-api-client.js → api-client/fetch-api-resource.js} +15 -101
- package/dist/cjs/state/api-client/fetch-api-resource.js.map +1 -0
- package/dist/cjs/state/api-client/state.js +89 -0
- package/dist/cjs/state/api-client/state.js.map +1 -0
- package/dist/cjs/state/api-client/store.js +36 -0
- package/dist/cjs/state/api-client/store.js.map +1 -0
- package/dist/cjs/state/middleware/makeswift-api-client-sync.js +1 -1
- package/dist/cjs/state/middleware/makeswift-api-client-sync.js.map +1 -1
- package/dist/esm/api/api-resources-client.js +127 -0
- package/dist/esm/api/api-resources-client.js.map +1 -0
- package/dist/esm/api/client.js +19 -171
- package/dist/esm/api/client.js.map +1 -1
- package/dist/esm/api-handler/handlers/manifest.js +1 -1
- package/dist/esm/client/index.js +3 -3
- package/dist/esm/controls/index.js +2 -2
- package/dist/esm/controls/index.js.map +1 -1
- package/dist/esm/next/api-handler/config/pages-router.js +1 -1
- package/dist/esm/next/api-handler/config/pages-router.js.map +1 -1
- package/dist/esm/next/fetch.js.map +1 -1
- package/dist/esm/runtimes/react/hooks/use-cache-data.js +1 -1
- package/dist/esm/runtimes/react/hooks/use-cache-data.js.map +1 -1
- package/dist/esm/runtimes/react/hooks/use-resource-resolver.js +11 -22
- package/dist/esm/runtimes/react/hooks/use-resource-resolver.js.map +1 -1
- package/dist/esm/runtimes/react/resource-resolver.js +28 -0
- package/dist/esm/runtimes/react/resource-resolver.js.map +1 -0
- package/dist/esm/runtimes/react/runtime-core.js.map +1 -1
- package/dist/esm/slate/InlinePlugin/index.js +2 -2
- package/dist/esm/slate/InlinePlugin/index.js.map +1 -1
- package/dist/esm/slate/InlinePlugin/types.js +4 -4
- package/dist/esm/slate/InlinePlugin/types.js.map +1 -1
- package/dist/esm/slate/TextAlignPlugin/index.js +6 -6
- package/dist/esm/slate/TextAlignPlugin/index.js.map +1 -1
- package/dist/esm/state/actions/internal/read-write-actions.js.map +1 -1
- package/dist/esm/state/api-client/client-store.js +49 -0
- package/dist/esm/state/api-client/client-store.js.map +1 -0
- package/dist/esm/state/api-client/fetch-api-resource.js +93 -0
- package/dist/esm/state/api-client/fetch-api-resource.js.map +1 -0
- package/dist/esm/state/api-client/state.js +52 -0
- package/dist/esm/state/api-client/state.js.map +1 -0
- package/dist/esm/state/api-client/store.js +12 -0
- package/dist/esm/state/api-client/store.js.map +1 -0
- package/dist/esm/state/middleware/makeswift-api-client-sync.js +1 -1
- package/dist/esm/state/middleware/makeswift-api-client-sync.js.map +1 -1
- package/dist/types/api/api-resources-client.d.ts +57 -0
- package/dist/types/api/api-resources-client.d.ts.map +1 -0
- package/dist/types/api/client.d.ts +10 -42
- package/dist/types/api/client.d.ts.map +1 -1
- package/dist/types/client/index.d.ts +9 -9
- package/dist/types/controls/index.d.ts +1 -1
- package/dist/types/controls/index.d.ts.map +1 -1
- package/dist/types/next/fetch.d.ts +1 -1
- package/dist/types/next/fetch.d.ts.map +1 -1
- package/dist/types/runtimes/react/hooks/use-resource-resolver.d.ts.map +1 -1
- package/dist/types/runtimes/react/resource-resolver.d.ts +10 -0
- package/dist/types/runtimes/react/resource-resolver.d.ts.map +1 -0
- package/dist/types/runtimes/react/runtime-core.d.ts +3 -3
- package/dist/types/runtimes/react/runtime-core.d.ts.map +1 -1
- package/dist/types/slate/InlinePlugin/types.d.ts +3 -3
- package/dist/types/slate/InlinePlugin/types.d.ts.map +1 -1
- package/dist/types/slate/TextAlignPlugin/index.d.ts.map +1 -1
- package/dist/types/state/actions/internal/read-write-actions.d.ts +1 -1
- package/dist/types/state/actions/internal/read-write-actions.d.ts.map +1 -1
- package/dist/types/state/api-client/client-store.d.ts +6 -0
- package/dist/types/state/api-client/client-store.d.ts.map +1 -0
- package/dist/types/state/api-client/fetch-api-resource.d.ts +11 -0
- package/dist/types/state/api-client/fetch-api-resource.d.ts.map +1 -0
- package/dist/types/state/api-client/state.d.ts +30 -0
- package/dist/types/state/api-client/state.d.ts.map +1 -0
- package/dist/types/state/api-client/store.d.ts +18 -0
- package/dist/types/state/api-client/store.d.ts.map +1 -0
- package/package.json +3 -3
- package/dist/cjs/state/makeswift-api-client.js.map +0 -1
- package/dist/esm/state/makeswift-api-client.js +0 -179
- package/dist/esm/state/makeswift-api-client.js.map +0 -1
- package/dist/types/state/makeswift-api-client.d.ts +0 -51
- package/dist/types/state/makeswift-api-client.d.ts.map +0 -1
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { type FetchableValue } from '@makeswift/controls';
|
|
2
|
+
import { type Store as ApiClientStore } from '../state/api-client/store';
|
|
3
|
+
import * as ApiClientState from '../state/api-client/state';
|
|
4
|
+
import { type File, type GlobalElement, type LocalizedGlobalElement, type Page, type PagePathnameSlice, type Site, type Snippet, type Swatch, type Table, type Typography, APIResourceType } from './types';
|
|
5
|
+
export type CacheData = ApiClientState.SerializedState;
|
|
6
|
+
export declare const CacheData: {
|
|
7
|
+
empty(): CacheData;
|
|
8
|
+
};
|
|
9
|
+
export declare abstract class ApiResourcesClient {
|
|
10
|
+
readonly store: ApiClientStore;
|
|
11
|
+
readonly subscribe: ApiClientStore['subscribe'];
|
|
12
|
+
constructor({ store }: {
|
|
13
|
+
store: ApiClientStore;
|
|
14
|
+
});
|
|
15
|
+
abstract fetchSwatch(swatchId: string): Promise<Swatch | null>;
|
|
16
|
+
readSwatch(swatchId: string): Swatch | null;
|
|
17
|
+
resolveSwatch(swatchId: string | undefined): FetchableValue<Swatch | null>;
|
|
18
|
+
abstract fetchFile(fileId: string): Promise<File | null>;
|
|
19
|
+
readFile(fileId: string): File | null;
|
|
20
|
+
resolveFile(fileId: string | undefined): FetchableValue<File | null>;
|
|
21
|
+
abstract fetchTypography(typographyId: string): Promise<Typography | null>;
|
|
22
|
+
readTypography(typographyId: string): Typography | null;
|
|
23
|
+
resolveTypography(typographyId: string | undefined): FetchableValue<Typography | null>;
|
|
24
|
+
abstract fetchGlobalElement(globalElementId: string): Promise<GlobalElement | null>;
|
|
25
|
+
readGlobalElement(globalElementId: string): GlobalElement | null;
|
|
26
|
+
abstract fetchLocalizedGlobalElement({ globalElementId, locale, }: {
|
|
27
|
+
globalElementId: string;
|
|
28
|
+
locale: string;
|
|
29
|
+
}): Promise<LocalizedGlobalElement | null>;
|
|
30
|
+
readLocalizedGlobalElement({ globalElementId, locale, }: {
|
|
31
|
+
globalElementId: string;
|
|
32
|
+
locale: string;
|
|
33
|
+
}): LocalizedGlobalElement | null;
|
|
34
|
+
readPagePathnameSlice({ pageId, locale, }: {
|
|
35
|
+
pageId: string;
|
|
36
|
+
locale: string | null;
|
|
37
|
+
}): PagePathnameSlice | null;
|
|
38
|
+
abstract fetchPagePathnameSlice({ pageId, locale, }: {
|
|
39
|
+
pageId: string;
|
|
40
|
+
locale: string | null;
|
|
41
|
+
}): Promise<PagePathnameSlice | null>;
|
|
42
|
+
resolvePagePathnameSlice({ pageId, locale, }: {
|
|
43
|
+
pageId: string | undefined;
|
|
44
|
+
locale: string | null;
|
|
45
|
+
}): FetchableValue<PagePathnameSlice | null>;
|
|
46
|
+
resolveResource<R>(type: APIResourceType, { id, read, fetch, }: {
|
|
47
|
+
id: string | undefined;
|
|
48
|
+
read: (id: string) => R | null;
|
|
49
|
+
fetch: (id: string) => Promise<R | null>;
|
|
50
|
+
}): FetchableValue<R | null>;
|
|
51
|
+
abstract fetchTable(tableId: string): Promise<Table | null>;
|
|
52
|
+
readTable(tableId: string): Table | null;
|
|
53
|
+
readSite(siteId: string): Site | null;
|
|
54
|
+
readPage(pageId: string): Page | null;
|
|
55
|
+
readSnippet(snippetId: string): Snippet | null;
|
|
56
|
+
}
|
|
57
|
+
//# sourceMappingURL=api-resources-client.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"api-resources-client.d.ts","sourceRoot":"","sources":["../../../src/api/api-resources-client.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,qBAAqB,CAAA;AAEzD,OAAO,EAAE,KAAK,KAAK,IAAI,cAAc,EAAE,MAAM,2BAA2B,CAAA;AACxE,OAAO,KAAK,cAAc,MAAM,2BAA2B,CAAA;AAE3D,OAAO,EACL,KAAK,IAAI,EACT,KAAK,aAAa,EAClB,KAAK,sBAAsB,EAC3B,KAAK,IAAI,E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AAO,CAAC,CAAC,GAAG,IAAI,CAAC,CAAA;KACzC,GACA,cAAc,CAAC,CAAC,GAAG,IAAI,CAAC;IAc3B,QAAQ,CAAC,UAAU,CAAC,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,KAAK,GAAG,IAAI,CAAC;IAE3D,SAAS,CAAC,OAAO,EAAE,MAAM,GAAG,KAAK,GAAG,IAAI;IAIxC,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI;IAIrC,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,IAAI,GAAG,IAAI;IAIrC,WAAW,CAAC,SAAS,EAAE,MAAM,GAAG,OAAO,GAAG,IAAI;CAG/C"}
|
|
@@ -1,11 +1,9 @@
|
|
|
1
|
-
import { type
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
1
|
+
import { type State as ApiClientState } from '../state/api-client/state';
|
|
2
|
+
import { type HttpFetch } from '../state/api-client/fetch-api-resource';
|
|
3
|
+
import { type File, type GlobalElement, type LocalizedGlobalElement, type PagePathnameSlice, type Swatch, type Table, type Typography } from './types';
|
|
4
4
|
import { GraphQLClient } from './graphql/client';
|
|
5
|
-
|
|
6
|
-
export
|
|
7
|
-
empty(): CacheData;
|
|
8
|
-
};
|
|
5
|
+
import { ApiResourcesClient } from './api-resources-client';
|
|
6
|
+
export { CacheData } from './api-resources-client';
|
|
9
7
|
/**
|
|
10
8
|
* NOTE(miguel): This "client" is used to fetch Makeswift API resources needed for the host. For
|
|
11
9
|
* example, swatches, files, typographies, etc. Ideally it's internal to the runtime and is only
|
|
@@ -25,57 +23,27 @@ export declare const CacheData: {
|
|
|
25
23
|
* client of the host's API, not Makeswift's, intended to build and continuously maintain a realtime
|
|
26
24
|
* snapshot for use in the builder, not the lives pages.
|
|
27
25
|
*/
|
|
28
|
-
export declare class MakeswiftHostApiClient {
|
|
29
|
-
graphqlClient: GraphQLClient;
|
|
30
|
-
|
|
31
|
-
subscribe: MakeswiftApiClient.Store['subscribe'];
|
|
32
|
-
fetch: MakeswiftApiClient.HttpFetch;
|
|
26
|
+
export declare class MakeswiftHostApiClient extends ApiResourcesClient {
|
|
27
|
+
readonly graphqlClient: GraphQLClient;
|
|
28
|
+
readonly fetch: HttpFetch;
|
|
33
29
|
constructor({ uri, fetch, preloadedState, }: {
|
|
34
30
|
uri: string;
|
|
35
|
-
fetch:
|
|
36
|
-
preloadedState: Partial<
|
|
31
|
+
fetch: HttpFetch;
|
|
32
|
+
preloadedState: Partial<ApiClientState>;
|
|
37
33
|
});
|
|
38
|
-
readSwatch(swatchId: string): Swatch | null;
|
|
39
34
|
fetchSwatch(swatchId: string): Promise<Swatch | null>;
|
|
40
|
-
resolveSwatch(swatchId: string | undefined): FetchableValue<Swatch | null>;
|
|
41
|
-
readFile(fileId: string): File | null;
|
|
42
35
|
fetchFile(fileId: string): Promise<File | null>;
|
|
43
|
-
resolveFile(fileId: string | undefined): FetchableValue<File | null>;
|
|
44
|
-
readTypography(typographyId: string): Typography | null;
|
|
45
36
|
fetchTypography(typographyId: string): Promise<Typography | null>;
|
|
46
|
-
resolveTypography(typographyId: string | undefined): FetchableValue<Typography | null>;
|
|
47
|
-
readGlobalElement(globalElementId: string): GlobalElement | null;
|
|
48
37
|
fetchGlobalElement(globalElementId: string): Promise<GlobalElement | null>;
|
|
49
|
-
readLocalizedGlobalElement({ globalElementId, locale, }: {
|
|
50
|
-
globalElementId: string;
|
|
51
|
-
locale: string;
|
|
52
|
-
}): LocalizedGlobalElement | null;
|
|
53
38
|
fetchLocalizedGlobalElement({ globalElementId, locale, }: {
|
|
54
39
|
globalElementId: string;
|
|
55
40
|
locale: string;
|
|
56
41
|
}): Promise<LocalizedGlobalElement | null>;
|
|
57
|
-
readPagePathnameSlice({ pageId, locale, }: {
|
|
58
|
-
pageId: string;
|
|
59
|
-
locale: string | null;
|
|
60
|
-
}): PagePathnameSlice | null;
|
|
61
42
|
fetchPagePathnameSlice({ pageId, locale, }: {
|
|
62
43
|
pageId: string;
|
|
63
44
|
locale: string | null;
|
|
64
45
|
}): Promise<PagePathnameSlice | null>;
|
|
65
|
-
resolvePagePathnameSlice({ pageId, locale, }: {
|
|
66
|
-
pageId: string | undefined;
|
|
67
|
-
locale: string | null;
|
|
68
|
-
}): FetchableValue<PagePathnameSlice | null>;
|
|
69
|
-
resolveResource<R>(type: APIResourceType, { id, read, fetch, }: {
|
|
70
|
-
id: string | undefined;
|
|
71
|
-
read: (id: string) => R | null;
|
|
72
|
-
fetch: (id: string) => Promise<R | null>;
|
|
73
|
-
}): FetchableValue<R | null>;
|
|
74
|
-
readTable(tableId: string): Table | null;
|
|
75
46
|
fetchTable(tableId: string): Promise<Table | null>;
|
|
76
47
|
createTableRecord(tableId: string, columns: any): Promise<void>;
|
|
77
|
-
readSite(siteId: string): Site | null;
|
|
78
|
-
readPage(pageId: string): Page | null;
|
|
79
|
-
readSnippet(snippetId: string): Snippet | null;
|
|
80
48
|
}
|
|
81
49
|
//# sourceMappingURL=client.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/api/client.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../src/api/client.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,KAAK,IAAI,cAAc,EAAE,MAAM,2BAA2B,CAAA;AACxE,OAAO,EAAE,KAAK,SAAS,EAAoB,MAAM,wCAAwC,CAAA;AAGzF,OAAO,EACL,KAAK,IAAI,EACT,KAAK,aAAa,EAClB,KAAK,sBAAsB,EAC3B,KAAK,iBAAiB,EACtB,KAAK,MAAM,EACX,KAAK,KAAK,EACV,KAAK,UAAU,EAEhB,MAAM,SAAS,CAAA;AAEhB,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAA;AAOhD,OAAO,EAAE,kBAAkB,EAAE,MAAM,wBAAwB,CAAA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,8 @@ declare const makeswiftPageResultSchema: z.ZodObject<{
|
|
|
36
36
|
path: string;
|
|
37
37
|
id: string;
|
|
38
38
|
locale: string;
|
|
39
|
-
description: string | null;
|
|
40
39
|
title: string | null;
|
|
40
|
+
description: string | null;
|
|
41
41
|
canonicalUrl: string | null;
|
|
42
42
|
socialImageUrl: string | null;
|
|
43
43
|
sitemapPriority: number | null;
|
|
@@ -55,8 +55,8 @@ declare const makeswiftPageResultSchema: z.ZodObject<{
|
|
|
55
55
|
path: string;
|
|
56
56
|
id: string;
|
|
57
57
|
locale: string;
|
|
58
|
-
description: string | null;
|
|
59
58
|
title: string | null;
|
|
59
|
+
description: string | null;
|
|
60
60
|
canonicalUrl: string | null;
|
|
61
61
|
socialImageUrl: string | null;
|
|
62
62
|
sitemapPriority: number | null;
|
|
@@ -101,8 +101,8 @@ declare const makeswiftGetPagesResultAPISchema: z.ZodObject<{
|
|
|
101
101
|
path: string;
|
|
102
102
|
id: string;
|
|
103
103
|
locale: string;
|
|
104
|
-
description: string | null;
|
|
105
104
|
title: string | null;
|
|
105
|
+
description: string | null;
|
|
106
106
|
canonicalUrl: string | null;
|
|
107
107
|
socialImageUrl: string | null;
|
|
108
108
|
sitemapPriority: number | null;
|
|
@@ -120,8 +120,8 @@ declare const makeswiftGetPagesResultAPISchema: z.ZodObject<{
|
|
|
120
120
|
path: string;
|
|
121
121
|
id: string;
|
|
122
122
|
locale: string;
|
|
123
|
-
description: string | null;
|
|
124
123
|
title: string | null;
|
|
124
|
+
description: string | null;
|
|
125
125
|
canonicalUrl: string | null;
|
|
126
126
|
socialImageUrl: string | null;
|
|
127
127
|
sitemapPriority: number | null;
|
|
@@ -142,8 +142,8 @@ declare const makeswiftGetPagesResultAPISchema: z.ZodObject<{
|
|
|
142
142
|
path: string;
|
|
143
143
|
id: string;
|
|
144
144
|
locale: string;
|
|
145
|
-
description: string | null;
|
|
146
145
|
title: string | null;
|
|
146
|
+
description: string | null;
|
|
147
147
|
canonicalUrl: string | null;
|
|
148
148
|
socialImageUrl: string | null;
|
|
149
149
|
sitemapPriority: number | null;
|
|
@@ -164,8 +164,8 @@ declare const makeswiftGetPagesResultAPISchema: z.ZodObject<{
|
|
|
164
164
|
path: string;
|
|
165
165
|
id: string;
|
|
166
166
|
locale: string;
|
|
167
|
-
description: string | null;
|
|
168
167
|
title: string | null;
|
|
168
|
+
description: string | null;
|
|
169
169
|
canonicalUrl: string | null;
|
|
170
170
|
socialImageUrl: string | null;
|
|
171
171
|
sitemapPriority: number | null;
|
|
@@ -649,7 +649,7 @@ export declare class MakeswiftClient {
|
|
|
649
649
|
} & {
|
|
650
650
|
limit?: number | undefined;
|
|
651
651
|
after?: string | undefined;
|
|
652
|
-
sortBy?: "path" | "
|
|
652
|
+
sortBy?: "path" | "title" | "description" | "createdAt" | "updatedAt" | undefined;
|
|
653
653
|
sortDirection?: "desc" | "asc" | undefined;
|
|
654
654
|
includeOffline?: boolean | undefined;
|
|
655
655
|
pathPrefix?: string | undefined;
|
|
@@ -659,8 +659,8 @@ export declare class MakeswiftClient {
|
|
|
659
659
|
path: string;
|
|
660
660
|
id: string;
|
|
661
661
|
locale: string;
|
|
662
|
-
description: string | null;
|
|
663
662
|
title: string | null;
|
|
663
|
+
description: string | null;
|
|
664
664
|
canonicalUrl: string | null;
|
|
665
665
|
socialImageUrl: string | null;
|
|
666
666
|
sitemapPriority: number | null;
|
|
@@ -680,8 +680,8 @@ export declare class MakeswiftClient {
|
|
|
680
680
|
path: string;
|
|
681
681
|
id: string;
|
|
682
682
|
locale: string;
|
|
683
|
-
description: string | null;
|
|
684
683
|
title: string | null;
|
|
684
|
+
description: string | null;
|
|
685
685
|
canonicalUrl: string | null;
|
|
686
686
|
socialImageUrl: string | null;
|
|
687
687
|
sitemapPriority: number | null;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export * from './control';
|
|
2
|
-
export { ControlDefinition, Checkbox, CheckboxDefinition, Code, CodeDefinition, Color, ColorDefinition, Combobox, ComboboxDefinition, Font, FontDefinition, Group, GroupDefinition, GroupControl, IconRadioGroupDefinition, type IconRadioGroupIcon,
|
|
2
|
+
export { ControlDefinition, Checkbox, CheckboxDefinition, Code, CodeDefinition, Color, ColorDefinition, Combobox, ComboboxDefinition, Font, FontDefinition, Group, GroupDefinition, GroupControl, IconRadioGroup, IconRadioGroupDefinition, type IconRadioGroupIcon, Image, ImageDefinition, List, ListDefinition, ListControl, Number, NumberDefinition, Select, SelectDefinition, Shape, ShapeDefinition, ShapeControl, Slider, SliderDefinition, Style, StyleDefinition, type StyleProperty, StyleControl, TextInput, TextInputDefinition, TextArea, TextAreaDefinition, unstable_Typography, unstable_TypographyDefinition, } from '@makeswift/controls';
|
|
3
3
|
export { Link, LinkDefinition } from './link';
|
|
4
4
|
export { RichTextV1Definition, RichTextV1Control } from './rich-text';
|
|
5
5
|
export { RichText, RichTextV2Definition, RichTextV2Control } from './rich-text-v2';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/controls/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAA;AAEzB,OAAO,EACL,iBAAiB,EACjB,QAAQ,EACR,kBAAkB,EAClB,IAAI,EACJ,cAAc,EACd,KAAK,EACL,eAAe,EACf,QAAQ,EACR,kBAAkB,EAClB,IAAI,EACJ,cAAc,EACd,KAAK,EACL,eAAe,EACf,YAAY,EACZ,wBAAwB,EACxB,KAAK,kBAAkB,EACvB,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/controls/index.ts"],"names":[],"mappings":"AAAA,cAAc,WAAW,CAAA;AAEzB,OAAO,EACL,iBAAiB,EACjB,QAAQ,EACR,kBAAkB,EAClB,IAAI,EACJ,cAAc,EACd,KAAK,EACL,eAAe,EACf,QAAQ,EACR,kBAAkB,EAClB,IAAI,EACJ,cAAc,EACd,KAAK,EACL,eAAe,EACf,YAAY,EACZ,cAAc,EACd,wBAAwB,EACxB,KAAK,kBAAkB,EACvB,KAAK,EACL,eAAe,EACf,IAAI,EACJ,cAAc,EACd,WAAW,EACX,MAAM,EACN,gBAAgB,EAChB,MAAM,EACN,gBAAgB,EAChB,KAAK,EACL,eAAe,EACf,YAAY,EACZ,MAAM,EACN,gBAAgB,EAChB,KAAK,EACL,eAAe,EACf,KAAK,aAAa,EAClB,YAAY,EACZ,SAAS,EACT,mBAAmB,EACnB,QAAQ,EACR,kBAAkB,EAClB,mBAAmB,EACnB,6BAA6B,GAC9B,MAAM,qBAAqB,CAAA;AAE5B,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,MAAM,QAAQ,CAAA;AAC7C,OAAO,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,MAAM,aAAa,CAAA;AACrE,OAAO,EAAE,QAAQ,EAAE,oBAAoB,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAA;AAClF,OAAO,EAAE,IAAI,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,QAAQ,CAAA;AAC1D,OAAO,EAAE,gBAAgB,EAAE,iBAAiB,EAAE,cAAc,EAAE,MAAM,qBAAqB,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../../../src/next/fetch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM
|
|
1
|
+
{"version":3,"file":"fetch.d.ts","sourceRoot":"","sources":["../../../src/next/fetch.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,wCAAwC,CAAA;AAIvE,eAAO,MAAM,KAAK,EAAE,SACuD,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"use-resource-resolver.d.ts","sourceRoot":"","sources":["../../../../../src/runtimes/react/hooks/use-resource-resolver.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;
|
|
1
|
+
{"version":3,"file":"use-resource-resolver.d.ts","sourceRoot":"","sources":["../../../../../src/runtimes/react/hooks/use-resource-resolver.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AAQ3D,wBAAgB,mBAAmB,IAAI,gBAAgB,CAiBtD"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type ResourceResolver } from '@makeswift/controls';
|
|
2
|
+
import { ApiResourcesClient } from '../../api/api-resources-client';
|
|
3
|
+
import { Store } from '../../state/store';
|
|
4
|
+
export declare const createResourceResolver: ({ store, apiClient, documentKey, locale, }: {
|
|
5
|
+
store: Store;
|
|
6
|
+
apiClient: ApiResourcesClient;
|
|
7
|
+
documentKey: string | null;
|
|
8
|
+
locale: string | null;
|
|
9
|
+
}) => ResourceResolver;
|
|
10
|
+
//# sourceMappingURL=resource-resolver.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resource-resolver.d.ts","sourceRoot":"","sources":["../../../../src/runtimes/react/resource-resolver.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,gBAAgB,EAAE,MAAM,qBAAqB,CAAA;AAG3D,OAAO,EAAE,kBAAkB,EAAE,MAAM,gCAAgC,CAAA;AACnE,OAAO,EAAE,KAAK,EAAE,MAAM,mBAAmB,CAAA;AAEzC,eAAO,MAAM,sBAAsB,GAAI,4CAKpC;IACD,KAAK,EAAE,KAAK,CAAA;IACZ,SAAS,EAAE,kBAAkB,CAAA;IAC7B,WAAW,EAAE,MAAM,GAAG,IAAI,CAAA;IAC1B,MAAM,EAAE,MAAM,GAAG,IAAI,CAAA;CACtB,KAAG,gBAmBF,CAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { type SerializableReplacementContext } from '@makeswift/controls';
|
|
2
|
-
import
|
|
2
|
+
import { type HttpFetch } from '../../state/api-client/fetch-api-resource';
|
|
3
3
|
import { type SiteVersion } from '../../api/site-version';
|
|
4
4
|
import { Breakpoints, BreakpointsInput } from '../../state/modules/breakpoints';
|
|
5
5
|
import { type Element, type ElementData } from '../../state/read-only-state';
|
|
@@ -14,13 +14,13 @@ export declare class RuntimeCore {
|
|
|
14
14
|
readonly appOrigin: string;
|
|
15
15
|
readonly apiOrigin: string;
|
|
16
16
|
readonly requestKey: StoreKey | undefined;
|
|
17
|
-
readonly fetch:
|
|
17
|
+
readonly fetch: HttpFetch;
|
|
18
18
|
constructor({ appOrigin, apiOrigin, breakpoints, requestKey, fetch, }: {
|
|
19
19
|
appOrigin?: string;
|
|
20
20
|
apiOrigin?: string;
|
|
21
21
|
breakpoints?: BreakpointsInput;
|
|
22
22
|
requestKey?: StoreKey;
|
|
23
|
-
fetch:
|
|
23
|
+
fetch: HttpFetch;
|
|
24
24
|
});
|
|
25
25
|
getOrCreateStore({ siteVersion, locale }: StoreKey): Store;
|
|
26
26
|
retainStore({ siteVersion, locale }: StoreKey, store: Store): void;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"runtime-core.d.ts","sourceRoot":"","sources":["../../../../src/runtimes/react/runtime-core.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,8BAA8B,EAAE,MAAM,qBAAqB,CAAA;AAGzE,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"runtime-core.d.ts","sourceRoot":"","sources":["../../../../src/runtimes/react/runtime-core.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,8BAA8B,EAAE,MAAM,qBAAqB,CAAA;AAGzE,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,2CAA2C,CAAA;AAC1E,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,wBAAwB,CAAA;AAEzD,OAAO,EACL,WAAW,EACX,gBAAgB,EAEjB,MAAM,iCAAiC,CAAA;AAIxC,OAAO,EAAkB,KAAK,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,6BAA6B,CAAA;AAC5F,OAAO,EAGL,KAAK,UAAU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Type, 'link'>;
|
|
4
4
|
export type SupportedInline = Exclude<Slate.Inline, Slate.LinkElement>;
|
|
5
5
|
export declare const supportedInlineOptions: readonly [{
|
|
6
|
-
readonly icon: "
|
|
6
|
+
readonly icon: "Superscript";
|
|
7
7
|
readonly label: "Superscript";
|
|
8
8
|
readonly value: "superscript";
|
|
9
9
|
}, {
|
|
10
|
-
readonly icon: "
|
|
10
|
+
readonly icon: "Subscript";
|
|
11
11
|
readonly label: "Subscript";
|
|
12
12
|
readonly value: "subscript";
|
|
13
13
|
}, {
|
|
14
|
-
readonly icon: "
|
|
14
|
+
readonly icon: "Code";
|
|
15
15
|
readonly label: "Code";
|
|
16
16
|
readonly value: "code";
|
|
17
17
|
}];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/slate/InlinePlugin/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/slate/InlinePlugin/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,EAAkB,MAAM,qBAAqB,CAAA;AAC3D,OAAO,EAAE,IAAI,EAAE,SAAS,EAAE,MAAM,OAAO,CAAA;AAEvC,MAAM,MAAM,mBAAmB,GAAG,OAAO,CAAC,KAAK,CAAC,UAAU,EAAE,MAAM,CAAC,CAAA;AACnE,MAAM,MAAM,eAAe,GAAG,OAAO,CAAC,KAAK,CAAC,MAAM,EAAE,KAAK,CAAC,WAAW,CAAC,CAAA;AAEtE,eAAO,MAAM,sBAAsB;;;;;;;;;;;;EAgBzB,CAAA;AAEV,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,KAAK,CAAC,UAAU,GAAG,MAAM,IAAI,mBAAmB,CAE7F;AAED,wBAAgB,qBAAqB,CAAC,IAAI,EAAE,IAAI,GAAG,IAAI,IAAI,eAAe,CAEzE;AAED,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,SAAS,CAAC,IAAI,CAAC,GACrB,KAAK,IAAI,SAAS,CAAC,eAAe,CAAC,CAErC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/slate/TextAlignPlugin/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAsB,MAAM,OAAO,CAAA;AAClD,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/slate/TextAlignPlugin/index.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAsB,MAAM,OAAO,CAAA;AAClD,OAAO,EAAkB,KAAK,EAAE,MAAM,qBAAqB,CAAA;AAS3D,eAAO,MAAM,aAAa,GAAI,QAAQ,MAAM,iCAc3C,CAAA;AAED,wBAAgB,eAAe;;;;;;;;EAuD9B"}
|
|
@@ -3,7 +3,7 @@ import { type ThunkAction } from '@reduxjs/toolkit';
|
|
|
3
3
|
import { type Measurable } from '../../modules/read-write/box-models';
|
|
4
4
|
import { type DescriptorsByComponentType } from '../../modules/prop-controllers';
|
|
5
5
|
import { type DocumentPayload } from '../../shared-api';
|
|
6
|
-
import { type SerializedState as APIClientCache } from '../../
|
|
6
|
+
import { type SerializedState as APIClientCache } from '../../api-client/state';
|
|
7
7
|
export declare const ReadWriteActionTypes: {
|
|
8
8
|
readonly CHANGE_ELEMENT_TREE: "CHANGE_ELEMENT_TREE";
|
|
9
9
|
readonly REGISTER_MEASURABLE: "REGISTER_MEASURABLE";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"read-write-actions.d.ts","sourceRoot":"","sources":["../../../../../src/state/actions/internal/read-write-actions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,UAAU,CAAA;AACzC,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAEnD,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,qCAAqC,CAAA;AACrE,OAAO,EAAE,KAAK,0BAA0B,EAAE,MAAM,gCAAgC,CAAA;AAEhF,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,kBAAkB,CAAA;AACvD,OAAO,EAAE,KAAK,eAAe,IAAI,cAAc,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"read-write-actions.d.ts","sourceRoot":"","sources":["../../../../../src/state/actions/internal/read-write-actions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,UAAU,CAAA;AACzC,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAEnD,OAAO,EAAE,KAAK,UAAU,EAAE,MAAM,qCAAqC,CAAA;AACrE,OAAO,EAAE,KAAK,0BAA0B,EAAE,MAAM,gCAAgC,CAAA;AAEhF,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,kBAAkB,CAAA;AACvD,OAAO,EAAE,KAAK,eAAe,IAAI,cAAc,EAAE,MAAM,wBAAwB,CAAA;AAE/E,eAAO,MAAM,oBAAoB;;;;;;CAOvB,CAAA;AAEV,KAAK,uBAAuB,GAAG;IAC7B,IAAI,EAAE,OAAO,oBAAoB,CAAC,mBAAmB,CAAA;IACrD,OAAO,EAAE;QACP,WAAW,EAAE,eAAe,CAAA;QAC5B,WAAW,EAAE,eAAe,CAAA;QAC5B,WAAW,EAAE,0BAA0B,CAAA;QACvC,SAAS,EAAE,SAAS,CAAA;KACrB,CAAA;CACF,CAAA;AAED,KAAK,wBAAwB,GAAG;IAC9B,IAAI,EAAE,OAAO,oBAAoB,CAAC,mBAAmB,CAAA;IACrD,OAAO,EAAE;QAAE,WAAW,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,UAAU,CAAA;KAAE,CAAA;CAC7E,CAAA;AAED,KAAK,0BAA0B,GAAG;IAChC,IAAI,EAAE,OAAO,oBAAoB,CAAC,qBAAqB,CAAA;IACvD,OAAO,EAAE;QAAE,WAAW,EAAE,MAAM,CAAC;QAAC,UAAU,EAAE,MAAM,CAAA;KAAE,CAAA;CACrD,CAAA;AAED,KAAK,oBAAoB,GAAG;IAC1B,IAAI,EAAE,OAAO,oBAAoB,CAAC,uBAAuB,CAAA;IACzD,OAAO,EAAE,cAAc,CAAA;CACxB,CAAA;AAED,KAAK,mBAAmB,GAAG;IACzB,IAAI,EAAE,OAAO,oBAAoB,CAAC,sBAAsB,CAAA;CACzD,CAAA;AAED,MAAM,MAAM,eAAe,GACvB,uBAAuB,GACvB,wBAAwB,GACxB,0BAA0B,GAC1B,oBAAoB,GACpB,mBAAmB,CAAA;AAEvB,wBAAgB,iBAAiB,CAC/B,OAAO,EAAE,uBAAuB,CAAC,SAAS,CAAC,GAC1C,uBAAuB,CAKzB;AAED,wBAAgB,kBAAkB,CAChC,WAAW,EAAE,MAAM,EACnB,UAAU,EAAE,MAAM,EAClB,UAAU,EAAE,UAAU,GACrB,wBAAwB,CAK1B;AAED,wBAAgB,oBAAoB,CAClC,WAAW,EAAE,MAAM,EACnB,UAAU,EAAE,MAAM,GACjB,0BAA0B,CAE5B;AAED,wBAAgB,wBAAwB,CACtC,WAAW,EAAE,MAAM,EACnB,UAAU,EAAE,MAAM,EAClB,UAAU,EAAE,UAAU,GACrB,WAAW,CAAC,MAAM,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,eAAe,CAAC,CAQ5D;AAED,wBAAgB,oBAAoB,CAAC,OAAO,EAAE,cAAc,GAAG,oBAAoB,CAElF;AAED,wBAAgB,mBAAmB,IAAI,mBAAmB,CAEzD"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"client-store.d.ts","sourceRoot":"","sources":["../../../../src/state/api-client/client-store.ts"],"names":[],"mappings":"AAWA,OAAO,EAAE,KAAK,KAAK,EAAW,MAAM,SAAS,CAAA;AAC7C,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,SAAS,CAAA;AA2BpC,wBAAgB,oBAAoB,CAAC,EACnC,cAAc,GACf,EAAE;IACD,cAAc,EAAE,OAAO,CAAC,KAAK,CAAC,CAAA;CAC/B,GAAG,KAAK,CAiBR"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type ThunkAction } from '@reduxjs/toolkit';
|
|
2
|
+
import { type Action } from '../actions';
|
|
3
|
+
import { APIResourceType, type APIResource, type APIResourceLocale } from '../../api';
|
|
4
|
+
import { type State } from './state';
|
|
5
|
+
export type HttpFetch = (url: string | URL, init?: RequestInit) => Promise<Response>;
|
|
6
|
+
type Thunk<ReturnType> = ThunkAction<ReturnType, State, unknown, Action>;
|
|
7
|
+
export declare function fetchAPIResource<T extends APIResourceType>(resourceType: T, resourceId: string, fetch: HttpFetch, locale?: APIResourceLocale<T>): Thunk<Promise<Extract<APIResource, {
|
|
8
|
+
__typename: T;
|
|
9
|
+
}> | null>>;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=fetch-api-resource.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fetch-api-resource.d.ts","sourceRoot":"","sources":["../../../../src/state/api-client/fetch-api-resource.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,WAAW,EAAE,MAAM,kBAAkB,CAAA;AAMnD,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,YAAY,CAAA;AAIxC,OAAO,EACL,eAAe,EACf,KAAK,WAAW,EAQhB,KAAK,iBAAiB,EACvB,MAAM,WAAW,CAAA;AAElB,OAAO,EAAE,KAAK,KAAK,EAA6D,MAAM,SAAS,CAAA;AAE/F,MAAM,MAAM,SAAS,GAAG,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,EAAE,IAAI,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAA;AAEpF,KAAK,KAAK,CAAC,UAAU,IAAI,WAAW,CAAC,UAAU,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,CAAC,CAAA;AAExE,wBAAgB,gBAAgB,CAAC,CAAC,SAAS,eAAe,EACxD,YAAY,EAAE,CAAC,EACf,UAAU,EAAE,MAAM,EAClB,KAAK,EAAE,SAAS,EAChB,MAAM,CAAC,EAAE,iBAAiB,CAAC,CAAC,CAAC,GAC5B,KAAK,CAAC,OAAO,CAAC,OAAO,CAAC,WAAW,EAAE;IAAE,UAAU,EAAE,CAAC,CAAA;CAAE,CAAC,GAAG,IAAI,CAAC,CAAC,CAsGhE"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { type ThunkDispatch } from '@reduxjs/toolkit';
|
|
2
|
+
import * as SiteVersionState from '../modules/site-version';
|
|
3
|
+
import * as LocaleState from '../modules/locale';
|
|
4
|
+
import * as APIResources from '../modules/api-resources';
|
|
5
|
+
import * as LocalizedResourcesMap from '../modules/localized-resources-map';
|
|
6
|
+
import { type Action } from '../actions';
|
|
7
|
+
import { APIResourceType, type APIResource, type APIResourceLocale } from '../../api';
|
|
8
|
+
export declare const reducer: import("@reduxjs/toolkit").Reducer<{
|
|
9
|
+
siteVersion: SiteVersionState.State;
|
|
10
|
+
locale: LocaleState.State;
|
|
11
|
+
apiResources: APIResources.State;
|
|
12
|
+
localizedResourcesMap: Map<string, Map<string, string | null>>;
|
|
13
|
+
}, Action | import("@reduxjs/toolkit").UnknownAction, Partial<{
|
|
14
|
+
siteVersion: SiteVersionState.State | undefined;
|
|
15
|
+
locale: LocaleState.State | undefined;
|
|
16
|
+
apiResources: APIResources.State | undefined;
|
|
17
|
+
localizedResourcesMap: Map<string, Map<string, string | null>> | undefined;
|
|
18
|
+
}>>;
|
|
19
|
+
export type State = ReturnType<typeof reducer>;
|
|
20
|
+
export type Dispatch = ThunkDispatch<State, unknown, Action>;
|
|
21
|
+
export type SerializedState = {
|
|
22
|
+
apiResources: APIResources.SerializedState;
|
|
23
|
+
localizedResourcesMap: LocalizedResourcesMap.SerializedState;
|
|
24
|
+
};
|
|
25
|
+
export declare function getLocalizedResourceId(state: State, locale: string, resourceId: string): string | undefined | null;
|
|
26
|
+
export declare function getHasAPIResource<T extends APIResourceType>(state: State, resourceType: APIResourceType, resourceId: string, locale?: APIResourceLocale<T>): boolean;
|
|
27
|
+
export declare function getAPIResource<T extends APIResourceType>(state: State, resourceType: T, resourceId: string, locale?: APIResourceLocale<T>): Extract<APIResource, {
|
|
28
|
+
__typename: T;
|
|
29
|
+
}> | null;
|
|
30
|
+
//# sourceMappingURL=state.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"state.d.ts","sourceRoot":"","sources":["../../../../src/state/api-client/state.ts"],"names":[],"mappings":"AAAA,OAAO,EAAmB,KAAK,aAAa,EAAE,MAAM,kBAAkB,CAAA;AAEtE,OAAO,KAAK,gBAAgB,MAAM,yBAAyB,CAAA;AAC3D,OAAO,KAAK,WAAW,MAAM,mBAAmB,CAAA;AAChD,OAAO,KAAK,YAAY,MAAM,0BAA0B,CAAA;AACxD,OAAO,KAAK,qBAAqB,MAAM,oCAAoC,CAAA;AAE3E,OAAO,EAAE,KAAK,MAAM,EAAE,MAAM,YAAY,CAAA;AAExC,OAAO,EAAE,eAAe,EAAE,KAAK,WAAW,EAAE,KAAK,iBAAiB,EAAE,MAAM,WAAW,CAAA;AAErF,eAAO,MAAM,OAAO;;;;;;;;;;GAKlB,CAAA;AAEF,MAAM,MAAM,KAAK,GAAG,UAAU,CAAC,OAAO,OAAO,CAAC,CAAA;AAC9C,MAAM,MAAM,QAAQ,GAAG,aAAa,CAAC,KAAK,EAAE,OAAO,EAAE,MAAM,CAAC,CAAA;AAE5D,MAAM,MAAM,eAAe,GAAG;IAC5B,YAAY,EAAE,YAAY,CAAC,eAAe,CAAA;IAC1C,qBAAqB,EAAE,qBAAqB,CAAC,eAAe,CAAA;CAC7D,CAAA;AAED,wBAAgB,sBAAsB,CACpC,KAAK,EAAE,KAAK,EACZ,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,MAAM,GACjB,MAAM,GAAG,SAAS,GAAG,IAAI,CAM3B;AAED,wBAAgB,iBAAiB,CAAC,CAAC,SAAS,eAAe,EACzD,KAAK,EAAE,KAAK,EACZ,YAAY,EAAE,eAAe,EAC7B,UAAU,EAAE,MAAM,EAClB,MAAM,CAAC,EAAE,iBAAiB,CAAC,CAAC,CAAC,GAC5B,OAAO,CAiBT;AAED,wBAAgB,cAAc,CAAC,CAAC,SAAS,eAAe,EACtD,KAAK,EAAE,KAAK,EACZ,YAAY,EAAE,CAAC,EACf,UAAU,EAAE,MAAM,EAClB,MAAM,CAAC,EAAE,iBAAiB,CAAC,CAAC,CAAC,GAC5B,OAAO,CAAC,WAAW,EAAE;IAAE,UAAU,EAAE,CAAC,CAAA;CAAE,CAAC,GAAG,IAAI,CAgBhD"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type State } from './state';
|
|
2
|
+
export declare function configureStore({ preloadedState }: {
|
|
3
|
+
preloadedState: Partial<State>;
|
|
4
|
+
}): import("@reduxjs/toolkit").EnhancedStore<{
|
|
5
|
+
siteVersion: import("../modules/site-version").State;
|
|
6
|
+
locale: import("../modules/locale").State;
|
|
7
|
+
apiResources: import("../modules/api-resources").State;
|
|
8
|
+
localizedResourcesMap: Map<string, Map<string, string | null>>;
|
|
9
|
+
}, import("../actions").Action | import("@reduxjs/toolkit").UnknownAction, import("@reduxjs/toolkit").Tuple<[import("@reduxjs/toolkit").StoreEnhancer<{
|
|
10
|
+
dispatch: import("@reduxjs/toolkit").ThunkDispatch<{
|
|
11
|
+
siteVersion: import("../modules/site-version").State;
|
|
12
|
+
locale: import("../modules/locale").State;
|
|
13
|
+
apiResources: import("../modules/api-resources").State;
|
|
14
|
+
localizedResourcesMap: Map<string, Map<string, string | null>>;
|
|
15
|
+
}, undefined, import("@reduxjs/toolkit").UnknownAction>;
|
|
16
|
+
}>, import("@reduxjs/toolkit").StoreEnhancer]>>;
|
|
17
|
+
export type Store = ReturnType<typeof configureStore>;
|
|
18
|
+
//# sourceMappingURL=store.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"store.d.ts","sourceRoot":"","sources":["../../../../src/state/api-client/store.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,KAAK,EAAW,MAAM,SAAS,CAAA;AAE7C,wBAAgB,cAAc,CAAC,EAAE,cAAc,EAAE,EAAE;IAAE,cAAc,EAAE,OAAO,CAAC,KAAK,CAAC,CAAA;CAAE;;;;;;;;;;;;gDAKpF;AAED,MAAM,MAAM,KAAK,GAAG,UAAU,CAAC,OAAO,cAAc,CAAC,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@makeswift/runtime",
|
|
3
|
-
"version": "0.28.7-canary.
|
|
3
|
+
"version": "0.28.7-canary.3",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"repository": {
|
|
6
6
|
"url": "makeswift/makeswift",
|
|
@@ -238,9 +238,9 @@
|
|
|
238
238
|
"use-sync-external-store": "^1.5.0",
|
|
239
239
|
"uuid": "^9.0.0",
|
|
240
240
|
"zod": "^3.21.4",
|
|
241
|
-
"@makeswift/controls": "0.1.20-canary.
|
|
241
|
+
"@makeswift/controls": "0.1.20-canary.2",
|
|
242
242
|
"@makeswift/next-plugin": "0.6.1",
|
|
243
|
-
"@makeswift/prop-controllers": "0.4.14-canary.
|
|
243
|
+
"@makeswift/prop-controllers": "0.4.14-canary.2"
|
|
244
244
|
},
|
|
245
245
|
"devDependencies": {
|
|
246
246
|
"@emotion/jest": "^11.11.0",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../src/state/makeswift-api-client.ts"],"sourcesContent":["import {\n configureStore as configureReduxStore,\n combineReducers,\n type ThunkAction,\n type ThunkMiddleware,\n type ThunkDispatch,\n UnknownAction,\n} from '@reduxjs/toolkit'\n\nimport { type SiteVersion, ApiHandlerHeaders, serializeSiteVersion } from '../api/site-version'\n\nimport * as SiteVersionState from './modules/site-version'\nimport * as LocaleState from './modules/locale'\nimport * as APIResources from './modules/api-resources'\nimport * as LocalizedResourcesMap from './modules/localized-resources-map'\n\nimport { type Action, ActionTypes } from './actions'\nimport { apiResourceFulfilled } from './actions/internal/read-only-actions'\nimport { setLocalizedResourceId } from './host-api'\nimport { actionMiddleware, middlewareOptions, devToolsConfig } from './toolkit'\n\nimport {\n APIResourceType,\n type APIResource,\n type Swatch,\n type File,\n type Typography,\n type GlobalElement,\n type PagePathnameSlice,\n type Table,\n type LocalizedGlobalElement,\n type APIResourceLocale,\n} from '../api'\n\nconst reducer = combineReducers({\n siteVersion: SiteVersionState.reducer,\n locale: LocaleState.reducer,\n apiResources: APIResources.reducer,\n localizedResourcesMap: LocalizedResourcesMap.reducer,\n})\n\nexport type State = ReturnType<typeof reducer>\nexport type Dispatch = ThunkDispatch<State, unknown, Action>\nexport type HttpFetch = (url: string | URL, init?: RequestInit) => Promise<Response>\n\nexport type SerializedState = {\n apiResources: APIResources.SerializedState\n localizedResourcesMap: LocalizedResourcesMap.SerializedState\n}\n\nfunction getLocalizedResourceId(\n state: State,\n locale: string,\n resourceId: string,\n): string | undefined | null {\n return LocalizedResourcesMap.getLocalizedResourceId(\n state.localizedResourcesMap,\n locale,\n resourceId,\n )\n}\n\nexport function getHasAPIResource<T extends APIResourceType>(\n state: State,\n resourceType: APIResourceType,\n resourceId: string,\n locale?: APIResourceLocale<T>,\n): boolean {\n switch (resourceType) {\n case APIResourceType.LocalizedGlobalElement:\n if (locale == null) {\n console.error(`Attempt to access ${resourceType} ${resourceId} without a locale`)\n return false\n }\n\n const localizedId = getLocalizedResourceId(state, locale, resourceId)\n return (\n localizedId != null &&\n APIResources.getHasAPIResource(state.apiResources, resourceType, localizedId, locale)\n )\n\n default:\n return APIResources.getHasAPIResource(state.apiResources, resourceType, resourceId, locale)\n }\n}\n\nexport function getAPIResource<T extends APIResourceType>(\n state: State,\n resourceType: T,\n resourceId: string,\n locale?: APIResourceLocale<T>,\n): Extract<APIResource, { __typename: T }> | null {\n switch (resourceType) {\n case APIResourceType.LocalizedGlobalElement:\n if (locale == null) {\n console.error(`Attempt to access ${resourceType} ${resourceId} without a locale`)\n return null\n }\n\n const localizedId = getLocalizedResourceId(state, locale, resourceId)\n return localizedId != null\n ? APIResources.getAPIResource(state.apiResources, resourceType, localizedId, locale)\n : null\n\n default:\n return APIResources.getAPIResource(state.apiResources, resourceType, resourceId, locale)\n }\n}\n\ntype Thunk<ReturnType> = ThunkAction<ReturnType, State, unknown, Action>\n\nexport function fetchAPIResource<T extends APIResourceType>(\n resourceType: T,\n resourceId: string,\n fetch: HttpFetch,\n locale?: APIResourceLocale<T>,\n): Thunk<Promise<Extract<APIResource, { __typename: T }> | null>> {\n const fetchVersioned = async <T>(url: string, version: SiteVersion | null): Promise<T | null> => {\n const response = await fetch(url, {\n headers: {\n 'Content-Type': 'application/json',\n ...(version != null\n ? { [ApiHandlerHeaders.SiteVersion]: serializeSiteVersion(version) }\n : {}),\n },\n })\n\n if (response.status === 404) return null\n if (!response.ok) throw new Error(response.statusText)\n\n if (response.headers.get('content-type')?.includes('application/json') !== true) {\n throw new Error(\n `Expected JSON response from \"${url}\" but got \"${response.headers.get('content-type')}\"`,\n )\n }\n\n return response.json()\n }\n\n return async (dispatch, getState) => {\n const state = getState()\n const version = SiteVersionState.getSiteVersion(state.siteVersion)\n\n if (getHasAPIResource(state, resourceType, resourceId, locale)) {\n return getAPIResource(state, resourceType, resourceId, locale)\n }\n\n let resource: APIResource | null\n\n switch (resourceType) {\n case APIResourceType.Swatch:\n resource = await fetchVersioned<Swatch>(`/api/makeswift/swatches/${resourceId}`, version)\n break\n\n case APIResourceType.File:\n resource = await fetchVersioned<File>(`/api/makeswift/files/${resourceId}`, version)\n break\n\n case APIResourceType.Typography:\n resource = await fetchVersioned<Typography>(\n `/api/makeswift/typographies/${resourceId}`,\n version,\n )\n break\n\n case APIResourceType.GlobalElement:\n resource = await fetchVersioned<GlobalElement>(\n `/api/makeswift/global-elements/${resourceId}`,\n version,\n )\n break\n\n case APIResourceType.LocalizedGlobalElement: {\n if (locale == null) throw new Error('Locale is required to fetch LocalizedGlobalElement')\n\n // If `getLocalizedResourceId` returns null, it means we have tried to fetch the resource,\n // but the resource is not available. If we haven't fetched it yet, it'll return undefined.\n if (getLocalizedResourceId(state, locale, resourceId) === null) {\n return null\n }\n\n resource = await fetchVersioned<LocalizedGlobalElement>(\n `/api/makeswift/localized-global-elements/${resourceId}/${locale}`,\n version,\n )\n\n dispatch(\n setLocalizedResourceId({\n locale,\n resourceId,\n localizedResourceId: resource?.id ?? null,\n }),\n )\n\n break\n }\n\n case APIResourceType.PagePathnameSlice: {\n const url = new URL(`/api/makeswift/page-pathname-slices/${resourceId}`, 'http://n')\n\n if (locale != null) url.searchParams.set('locale', locale)\n\n resource = await fetchVersioned<PagePathnameSlice>(url.pathname + url.search, version)\n break\n }\n\n case APIResourceType.Table:\n resource = await fetchVersioned<Table>(`/api/makeswift/tables/${resourceId}`, version)\n break\n\n default:\n resource = null\n }\n\n dispatch(apiResourceFulfilled(resourceType, resourceId, resource, locale))\n\n return resource as Extract<APIResource, { __typename: T }> | null\n }\n}\n\n// FIXME: this middleware can be removed once we've upgraded the builder\n// to always provide the locale when dispatching resource actions\nfunction defaultLocaleMiddleware(): ThunkMiddleware<State, UnknownAction> {\n return actionMiddleware(({ getState }) => next => {\n return (action: Action) => {\n switch (action.type) {\n case ActionTypes.CHANGE_API_RESOURCE:\n case ActionTypes.EVICT_API_RESOURCE:\n case ActionTypes.SET_LOCALIZED_RESOURCE_ID: {\n const { locale } = action.payload\n return next({\n ...action,\n payload: {\n ...action.payload,\n locale: locale ?? LocaleState.getLocale(getState().locale),\n },\n } as Action)\n }\n }\n\n return next(action)\n }\n })\n}\n\nexport function configureStore({ preloadedState }: { preloadedState: Partial<State> }) {\n return configureReduxStore({\n reducer,\n preloadedState,\n\n middleware: getDefaultMiddleware =>\n getDefaultMiddleware(middlewareOptions).concat(defaultLocaleMiddleware()),\n\n devTools: devToolsConfig({\n name: `API client store (${new Date().toISOString()})`,\n actionsDenylist: [\n ActionTypes.BUILDER_POINTER_MOVE,\n ActionTypes.HANDLE_POINTER_MOVE,\n ActionTypes.ELEMENT_FROM_POINT_CHANGE,\n ],\n }),\n })\n}\n\nexport type Store = ReturnType<typeof configureStore>\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,qBAOO;AAEP,0BAA0E;AAE1E,uBAAkC;AAClC,kBAA6B;AAC7B,mBAA8B;AAC9B,4BAAuC;AAEvC,qBAAyC;AACzC,+BAAqC;AACrC,sBAAuC;AACvC,IAAAA,kBAAoE;AAEpE,iBAWO;AAEP,MAAM,cAAU,gCAAgB;AAAA,EAC9B,aAAa,iBAAiB;AAAA,EAC9B,QAAQ,YAAY;AAAA,EACpB,cAAc,aAAa;AAAA,EAC3B,uBAAuB,sBAAsB;AAC/C,CAAC;AAWD,SAAS,uBACP,OACA,QACA,YAC2B;AAC3B,SAAO,sBAAsB;AAAA,IAC3B,MAAM;AAAA,IACN;AAAA,IACA;AAAA,EACF;AACF;AAEO,SAAS,kBACd,OACA,cACA,YACA,QACS;AACT,UAAQ,cAAc;AAAA,IACpB,KAAK,2BAAgB;AACnB,UAAI,UAAU,MAAM;AAClB,gBAAQ,MAAM,qBAAqB,YAAY,IAAI,UAAU,mBAAmB;AAChF,eAAO;AAAA,MACT;AAEA,YAAM,cAAc,uBAAuB,OAAO,QAAQ,UAAU;AACpE,aACE,eAAe,QACf,aAAa,kBAAkB,MAAM,cAAc,cAAc,aAAa,MAAM;AAAA,IAGxF;AACE,aAAO,aAAa,kBAAkB,MAAM,cAAc,cAAc,YAAY,MAAM;AAAA,EAC9F;AACF;AAEO,SAAS,eACd,OACA,cACA,YACA,QACgD;AAChD,UAAQ,cAAc;AAAA,IACpB,KAAK,2BAAgB;AACnB,UAAI,UAAU,MAAM;AAClB,gBAAQ,MAAM,q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