@eightyfourthousand/client-graphql 2026.5.1 → 2026.5.2
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/index.d.ts +1 -1
- package/index.js +1 -1
- package/index.js.map +1 -1
- package/lib/functions/index.d.ts +2 -1
- package/lib/functions/index.js +2 -1
- package/lib/functions/index.js.map +1 -1
- package/lib/functions/lookup.d.ts +13 -0
- package/lib/functions/lookup.js +30 -0
- package/lib/functions/lookup.js.map +1 -0
- package/lib/generated/graphql.d.ts +38 -4
- package/lib/generated/graphql.js +11 -0
- package/lib/generated/graphql.js.map +1 -1
- package/package.json +2 -2
package/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
export { createGraphQLClient, resetGraphQLClient, setAccessTokenProvider, } from './lib/client';
|
|
2
|
-
export { getPassage, getTranslationBlocks, getTranslationBlocksAround, getTranslationTitles, getTranslationMetadataByUuid, getTranslationMetadataByToh, getTranslationsMetadata, getTranslationUuids, getTranslationToc, getTranslationImprint, getGlossaryInstance, getWorkGlossaryTerms, getWorkGlossaryTermsAround, searchWorkGlossaryTerms, type GlossaryTermSearchResult, type GlossaryTermsPage, getTermPassages, type GlossaryPassagesPage, getBibliographyEntry, getWorkBibliography, getWorkFolios, hasPermission, replace, savePassages, type TranslationBlocksPage, type Permission, type ReplaceType, type ReplacedPassage, } from './lib/functions';
|
|
2
|
+
export { getPassage, lookup, type LookupEntityType, type LookupResult, getTranslationBlocks, getTranslationBlocksAround, getTranslationTitles, getTranslationMetadataByUuid, getTranslationMetadataByToh, getTranslationsMetadata, getTranslationUuids, getTranslationToc, getTranslationImprint, getGlossaryInstance, getWorkGlossaryTerms, getWorkGlossaryTermsAround, searchWorkGlossaryTerms, type GlossaryTermSearchResult, type GlossaryTermsPage, getTermPassages, type GlossaryPassagesPage, getBibliographyEntry, getWorkBibliography, getWorkFolios, hasPermission, replace, savePassages, type TranslationBlocksPage, type Permission, type ReplaceType, type ReplacedPassage, } from './lib/functions';
|
|
3
3
|
export type { Passage, Passages, PassagesPage, PaginationDirection, BodyItemType, Annotation, Annotations, Alignment, Work, Title, Titles, TitleType, Toc, TocEntry, Imprint, GlossaryTermInstance, GlossaryLandingItem, GlossaryPageItem, BibliographyEntry, BibliographyEntryItem, BibliographyEntries, Folio, } from '@eightyfourthousand/data-access';
|
|
4
4
|
export { BODY_ITEM_TYPES, FRONT_MATTER, FRONT_MATTER_FILTER, BODY_MATTER, BODY_MATTER_FILTER, BACK_MATTER, BACK_MATTER_FILTER, COMPARE_MODE, COMPARE_MODE_FILTER, } from '@eightyfourthousand/data-access';
|
package/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// Client
|
|
2
2
|
export { createGraphQLClient, resetGraphQLClient, setAccessTokenProvider, } from './lib/client';
|
|
3
3
|
// Functions
|
|
4
|
-
export { getPassage, getTranslationBlocks, getTranslationBlocksAround, getTranslationTitles, getTranslationMetadataByUuid, getTranslationMetadataByToh, getTranslationsMetadata, getTranslationUuids, getTranslationToc, getTranslationImprint, getGlossaryInstance, getWorkGlossaryTerms, getWorkGlossaryTermsAround, searchWorkGlossaryTerms, getTermPassages, getBibliographyEntry, getWorkBibliography, getWorkFolios, hasPermission, replace, savePassages, } from './lib/functions';
|
|
4
|
+
export { getPassage, lookup, getTranslationBlocks, getTranslationBlocksAround, getTranslationTitles, getTranslationMetadataByUuid, getTranslationMetadataByToh, getTranslationsMetadata, getTranslationUuids, getTranslationToc, getTranslationImprint, getGlossaryInstance, getWorkGlossaryTerms, getWorkGlossaryTermsAround, searchWorkGlossaryTerms, getTermPassages, getBibliographyEntry, getWorkBibliography, getWorkFolios, hasPermission, replace, savePassages, } from './lib/functions';
|
|
5
5
|
// Re-export constants for passage filters
|
|
6
6
|
export { BODY_ITEM_TYPES, FRONT_MATTER, FRONT_MATTER_FILTER, BODY_MATTER, BODY_MATTER_FILTER, BACK_MATTER, BACK_MATTER_FILTER, COMPARE_MODE, COMPARE_MODE_FILTER, } from '@eightyfourthousand/data-access';
|
|
7
7
|
//# sourceMappingURL=index.js.map
|
package/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../libs/client-graphql/src/index.ts"],"names":[],"mappings":"AAAA,SAAS;AACT,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,sBAAsB,GACvB,MAAM,cAAc,CAAC;AAEtB,YAAY;AACZ,OAAO,EACL,UAAU,EACV,oBAAoB,EACpB,0BAA0B,EAC1B,oBAAoB,EACpB,4BAA4B,EAC5B,2BAA2B,EAC3B,uBAAuB,EACvB,mBAAmB,EACnB,iBAAiB,EACjB,qBAAqB,EACrB,mBAAmB,EACnB,oBAAoB,EACpB,0BAA0B,EAC1B,uBAAuB,EAGvB,eAAe,EAEf,oBAAoB,EACpB,mBAAmB,EACnB,aAAa,EACb,aAAa,EACb,OAAO,EACP,YAAY,GAKb,MAAM,iBAAiB,CAAC;AA4BzB,0CAA0C;AAC1C,OAAO,EACL,eAAe,EACf,YAAY,EACZ,mBAAmB,EACnB,WAAW,EACX,kBAAkB,EAClB,WAAW,EACX,kBAAkB,EAClB,YAAY,EACZ,mBAAmB,GACpB,MAAM,iCAAiC,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../libs/client-graphql/src/index.ts"],"names":[],"mappings":"AAAA,SAAS;AACT,OAAO,EACL,mBAAmB,EACnB,kBAAkB,EAClB,sBAAsB,GACvB,MAAM,cAAc,CAAC;AAEtB,YAAY;AACZ,OAAO,EACL,UAAU,EACV,MAAM,EAGN,oBAAoB,EACpB,0BAA0B,EAC1B,oBAAoB,EACpB,4BAA4B,EAC5B,2BAA2B,EAC3B,uBAAuB,EACvB,mBAAmB,EACnB,iBAAiB,EACjB,qBAAqB,EACrB,mBAAmB,EACnB,oBAAoB,EACpB,0BAA0B,EAC1B,uBAAuB,EAGvB,eAAe,EAEf,oBAAoB,EACpB,mBAAmB,EACnB,aAAa,EACb,aAAa,EACb,OAAO,EACP,YAAY,GAKb,MAAM,iBAAiB,CAAC;AA4BzB,0CAA0C;AAC1C,OAAO,EACL,eAAe,EACf,YAAY,EACZ,mBAAmB,EACnB,WAAW,EACX,kBAAkB,EAClB,WAAW,EACX,kBAAkB,EAClB,YAAY,EACZ,mBAAmB,GACpB,MAAM,iCAAiC,CAAC"}
|
package/lib/functions/index.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export { getPassage } from './get-passage';
|
|
2
|
+
export { lookup, type LookupEntityType, type LookupResult } from './lookup';
|
|
2
3
|
export { getTranslationBlocks, type TranslationBlocksPage, } from './get-translation-blocks';
|
|
3
4
|
export { getTranslationBlocksAround } from './get-translation-blocks-around';
|
|
4
5
|
export { getTranslationTitles } from './get-translation-titles';
|
|
@@ -11,7 +12,7 @@ export { getGlossaryInstance } from './get-glossary-instance';
|
|
|
11
12
|
export { getWorkGlossaryTerms, type GlossaryTermsPage, } from './get-work-glossary-terms';
|
|
12
13
|
export { getWorkGlossaryTermsAround } from './get-work-glossary-terms-around';
|
|
13
14
|
export { searchWorkGlossaryTerms, type GlossaryTermSearchResult, } from './search-work-glossary-terms';
|
|
14
|
-
export { getTermPassages, type GlossaryPassagesPage } from './get-term-passages';
|
|
15
|
+
export { getTermPassages, type GlossaryPassagesPage, } from './get-term-passages';
|
|
15
16
|
export { getBibliographyEntry } from './get-bibliography-entry';
|
|
16
17
|
export { getWorkBibliography } from './get-work-bibliography';
|
|
17
18
|
export { getWorkFolios } from './get-work-folios';
|
package/lib/functions/index.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
export { getPassage } from './get-passage';
|
|
2
|
+
export { lookup } from './lookup';
|
|
2
3
|
export { getTranslationBlocks, } from './get-translation-blocks';
|
|
3
4
|
export { getTranslationBlocksAround } from './get-translation-blocks-around';
|
|
4
5
|
export { getTranslationTitles } from './get-translation-titles';
|
|
@@ -11,7 +12,7 @@ export { getGlossaryInstance } from './get-glossary-instance';
|
|
|
11
12
|
export { getWorkGlossaryTerms, } from './get-work-glossary-terms';
|
|
12
13
|
export { getWorkGlossaryTermsAround } from './get-work-glossary-terms-around';
|
|
13
14
|
export { searchWorkGlossaryTerms, } from './search-work-glossary-terms';
|
|
14
|
-
export { getTermPassages } from './get-term-passages';
|
|
15
|
+
export { getTermPassages, } from './get-term-passages';
|
|
15
16
|
export { getBibliographyEntry } from './get-bibliography-entry';
|
|
16
17
|
export { getWorkBibliography } from './get-work-bibliography';
|
|
17
18
|
export { getWorkFolios } from './get-work-folios';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../libs/client-graphql/src/lib/functions/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EACL,oBAAoB,GAErB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,0BAA0B,EAAE,MAAM,iCAAiC,CAAC;AAC7E,OAAO,EAAE,oBAAoB,EAAE,MAAM,0BAA0B,CAAC;AAChE,OAAO,EACL,4BAA4B,EAC5B,2BAA2B,GAC5B,MAAM,4BAA4B,CAAC;AACpC,OAAO,EAAE,uBAAuB,EAAE,MAAM,6BAA6B,CAAC;AACtE,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAC9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAC1D,OAAO,EAAE,qBAAqB,EAAE,MAAM,2BAA2B,CAAC;AAClE,OAAO,EAAE,mBAAmB,EAAE,MAAM,yBAAyB,CAAC;AAC9D,OAAO,EACL,oBAAoB,GAErB,MAAM,2BAA2B,CAAC;AACnC,OAAO,EAAE,0BAA0B,EAAE,MAAM,kCAAkC,CAAC;AAC9E,OAAO,EACL,uBAAuB,GAExB,MAAM,8BAA8B,CAAC;AACtC,OAAO,
|
|
1
|
+
{"version":3,"file":"index.js","sour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'graphql-request';
|
|
2
|
+
export type LookupEntityType = 'work' | 'passage' | 'glossary' | 'bibliography';
|
|
3
|
+
export type LookupResult = {
|
|
4
|
+
uuid: string;
|
|
5
|
+
type: LookupEntityType;
|
|
6
|
+
};
|
|
7
|
+
export declare function lookup({ client, toh, uuid, xmlId, type, }: {
|
|
8
|
+
client: GraphQLClient;
|
|
9
|
+
toh?: string;
|
|
10
|
+
uuid?: string;
|
|
11
|
+
xmlId?: string;
|
|
12
|
+
type?: LookupEntityType;
|
|
13
|
+
}): Promise<LookupResult | null>;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { gql } from 'graphql-request';
|
|
2
|
+
const LOOKUP = gql `
|
|
3
|
+
query Lookup(
|
|
4
|
+
$toh: String
|
|
5
|
+
$uuid: ID
|
|
6
|
+
$xmlId: String
|
|
7
|
+
$type: LookupEntityType
|
|
8
|
+
) {
|
|
9
|
+
lookup(toh: $toh, uuid: $uuid, xmlId: $xmlId, type: $type) {
|
|
10
|
+
uuid
|
|
11
|
+
type
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
`;
|
|
15
|
+
export async function lookup({ client, toh, uuid, xmlId, type, }) {
|
|
16
|
+
try {
|
|
17
|
+
const response = await client.request(LOOKUP, {
|
|
18
|
+
toh,
|
|
19
|
+
uuid,
|
|
20
|
+
xmlId,
|
|
21
|
+
type,
|
|
22
|
+
});
|
|
23
|
+
return response.lookup;
|
|
24
|
+
}
|
|
25
|
+
catch (error) {
|
|
26
|
+
console.error('Error looking up entity:', error);
|
|
27
|
+
return null;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
//# sourceMappingURL=lookup.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"lookup.js","sourceRoot":"","sources":["../../../../../libs/client-graphql/src/lib/functions/lookup.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,GAAG,EAAE,MAAM,iBAAiB,CAAC;AAStC,MAAM,MAAM,GAAG,GAAG,CAAA;;;;;;;;;;;;CAYjB,CAAC;AAMF,MAAM,CAAC,KAAK,UAAU,MAAM,CAAC,EAC3B,MAAM,EACN,GAAG,EACH,IAAI,EACJ,KAAK,EACL,IAAI,GAOL;IACC,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,MAAM,MAAM,CAAC,OAAO,CAAiB,MAAM,EAAE;YAC5D,GAAG;YACH,IAAI;YACJ,KAAK;YACL,IAAI;SACL,CAAC,CAAC;QAEH,OAAO,QAAQ,CAAC,MAAM,CAAC;IACzB,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,OAAO,CAAC,KAAK,CAAC,0BAA0B,EAAE,KAAK,CAAC,CAAC;QACjD,OAAO,IAAI,CAAC;IACd,CAAC;AACH,CAAC"}
|
|
@@ -243,6 +243,12 @@ export type License = {
|
|
|
243
243
|
/** Name of the license (e.g., "CC BY-NC-ND 4.0") */
|
|
244
244
|
name?: Maybe<Scalars['String']['output']>;
|
|
245
245
|
};
|
|
246
|
+
export type LookupEntityType = 'bibliography' | 'glossary' | 'passage' | 'work';
|
|
247
|
+
export type LookupResult = {
|
|
248
|
+
__typename?: 'LookupResult';
|
|
249
|
+
type: LookupEntityType;
|
|
250
|
+
uuid: Scalars['ID']['output'];
|
|
251
|
+
};
|
|
246
252
|
/** Root Mutation type - extend this in other schema files */
|
|
247
253
|
export type Mutation = {
|
|
248
254
|
__typename?: 'Mutation';
|
|
@@ -268,6 +274,7 @@ export type MutationReplaceArgs = {
|
|
|
268
274
|
searchText: Scalars['String']['input'];
|
|
269
275
|
targetUuids: Array<Scalars['ID']['input']>;
|
|
270
276
|
type?: InputMaybe<ReplaceType>;
|
|
277
|
+
useRegex?: InputMaybe<Scalars['Boolean']['input']>;
|
|
271
278
|
};
|
|
272
279
|
/** Root Mutation type - extend this in other schema files */
|
|
273
280
|
export type MutationSavePassagesArgs = {
|
|
@@ -411,6 +418,11 @@ export type Query = {
|
|
|
411
418
|
hasPermission: Scalars['Boolean']['output'];
|
|
412
419
|
/** Health check query */
|
|
413
420
|
health: HealthStatus;
|
|
421
|
+
/**
|
|
422
|
+
* Resolve a known entity identifier to its canonical UUID and type.
|
|
423
|
+
* Identifier precedence is toh, uuid, then xmlId.
|
|
424
|
+
*/
|
|
425
|
+
lookup?: Maybe<LookupResult>;
|
|
414
426
|
/** Get the currently authenticated user (null if not authenticated) */
|
|
415
427
|
me?: Maybe<CurrentUser>;
|
|
416
428
|
/**
|
|
@@ -448,6 +460,13 @@ export type QueryHasPermissionArgs = {
|
|
|
448
460
|
permission: Permission;
|
|
449
461
|
};
|
|
450
462
|
/** Root Query type - extend this in other schema files */
|
|
463
|
+
export type QueryLookupArgs = {
|
|
464
|
+
toh?: InputMaybe<Scalars['String']['input']>;
|
|
465
|
+
type?: InputMaybe<LookupEntityType>;
|
|
466
|
+
uuid?: InputMaybe<Scalars['ID']['input']>;
|
|
467
|
+
xmlId?: InputMaybe<Scalars['String']['input']>;
|
|
468
|
+
};
|
|
469
|
+
/** Root Query type - extend this in other schema files */
|
|
451
470
|
export type QueryPassageArgs = {
|
|
452
471
|
uuid?: InputMaybe<Scalars['ID']['input']>;
|
|
453
472
|
xmlId?: InputMaybe<Scalars['String']['input']>;
|
|
@@ -494,6 +513,8 @@ export type SavePassagesResult = {
|
|
|
494
513
|
deletedCount?: Maybe<Scalars['Int']['output']>;
|
|
495
514
|
/** Error message if the save failed */
|
|
496
515
|
error?: Maybe<Scalars['String']['output']>;
|
|
516
|
+
/** Saved passages (after server-side normalization), used for client-side refresh. */
|
|
517
|
+
passages: Array<Passage>;
|
|
497
518
|
/** Number of passages saved */
|
|
498
519
|
savedCount: Scalars['Int']['output'];
|
|
499
520
|
/** Whether the save was successful */
|
|
@@ -618,10 +639,7 @@ export type Work = {
|
|
|
618
639
|
publicationVersion: Scalars['String']['output'];
|
|
619
640
|
/** Whether access to this work is restricted */
|
|
620
641
|
restriction: Scalars['Boolean']['output'];
|
|
621
|
-
/**
|
|
622
|
-
* Search glossary term instances for this work by English term (ILIKE prefix
|
|
623
|
-
* match, also searching alternatives). Results are ordered by term_number.
|
|
624
|
-
*/
|
|
642
|
+
/** Search glossary term instances for this work by English term. Results are ordered by term_number. */
|
|
625
643
|
searchGlossaryTerms: Array<GlossaryTermInstance>;
|
|
626
644
|
/** Section of the canon this work belongs to */
|
|
627
645
|
section: Scalars['String']['output'];
|
|
@@ -822,6 +840,20 @@ export type WorkFieldsFragment = {
|
|
|
822
840
|
restriction: boolean;
|
|
823
841
|
section: string;
|
|
824
842
|
};
|
|
843
|
+
export type LookupQueryVariables = Exact<{
|
|
844
|
+
toh?: InputMaybe<Scalars['String']['input']>;
|
|
845
|
+
uuid?: InputMaybe<Scalars['ID']['input']>;
|
|
846
|
+
xmlId?: InputMaybe<Scalars['String']['input']>;
|
|
847
|
+
type?: InputMaybe<LookupEntityType>;
|
|
848
|
+
}>;
|
|
849
|
+
export type LookupQuery = {
|
|
850
|
+
__typename?: 'Query';
|
|
851
|
+
lookup?: {
|
|
852
|
+
__typename?: 'LookupResult';
|
|
853
|
+
uuid: string;
|
|
854
|
+
type: LookupEntityType;
|
|
855
|
+
} | null;
|
|
856
|
+
};
|
|
825
857
|
export type GetPassagesQueryVariables = Exact<{
|
|
826
858
|
uuid: Scalars['ID']['input'];
|
|
827
859
|
cursor?: InputMaybe<Scalars['String']['input']>;
|
|
@@ -1044,6 +1076,7 @@ export declare const TocEntryFieldsFragmentDoc: import("graphql").DocumentNode;
|
|
|
1044
1076
|
export declare const TocEntryNestedFragmentDoc: import("graphql").DocumentNode;
|
|
1045
1077
|
export declare const TocFieldsFragmentDoc: import("graphql").DocumentNode;
|
|
1046
1078
|
export declare const WorkFieldsFragmentDoc: import("graphql").DocumentNode;
|
|
1079
|
+
export declare const LookupDocument: import("graphql").DocumentNode;
|
|
1047
1080
|
export declare const GetPassagesDocument: import("graphql").DocumentNode;
|
|
1048
1081
|
export declare const GetPassagesBasicDocument: import("graphql").DocumentNode;
|
|
1049
1082
|
export declare const GetPassagesWithJsonDocument: import("graphql").DocumentNode;
|
|
@@ -1058,6 +1091,7 @@ export declare const GetAllWorksDocument: import("graphql").DocumentNode;
|
|
|
1058
1091
|
export declare const GetWorkUuidsDocument: import("graphql").DocumentNode;
|
|
1059
1092
|
export type SdkFunctionWrapper = <T>(action: (requestHeaders?: Record<string, string>) => Promise<T>, operationName: string, operationType?: string, variables?: any) => Promise<T>;
|
|
1060
1093
|
export declare function getSdk(client: GraphQLClient, withWrapper?: SdkFunctionWrapper): {
|
|
1094
|
+
Lookup(variables?: LookupQueryVariables, requestHeaders?: GraphQLClientRequestHeaders, signal?: RequestInit["signal"]): Promise<LookupQuery>;
|
|
1061
1095
|
GetPassages(variables: GetPassagesQueryVariables, requestHeaders?: GraphQLClientRequestHeaders, signal?: RequestInit["signal"]): Promise<GetPassagesQuery>;
|
|
1062
1096
|
GetPassagesBasic(variables: GetPassagesBasicQueryVariables, requestHeaders?: GraphQLClientRequestHeaders, signal?: RequestInit["signal"]): Promise<GetPassagesBasicQuery>;
|
|
1063
1097
|
GetPassagesWithJson(variables: GetPassagesWithJsonQueryVariables, requestHeaders?: GraphQLClientRequestHeaders, signal?: RequestInit["signal"]): Promise<GetPassagesWithJsonQuery>;
|
package/lib/generated/graphql.js
CHANGED
|
@@ -151,6 +151,14 @@ export const WorkFieldsFragmentDoc = gql `
|
|
|
151
151
|
section
|
|
152
152
|
}
|
|
153
153
|
`;
|
|
154
|
+
export const LookupDocument = gql `
|
|
155
|
+
query Lookup($toh: String, $uuid: ID, $xmlId: String, $type: LookupEntityType) {
|
|
156
|
+
lookup(toh: $toh, uuid: $uuid, xmlId: $xmlId, type: $type) {
|
|
157
|
+
uuid
|
|
158
|
+
type
|
|
159
|
+
}
|
|
160
|
+
}
|
|
161
|
+
`;
|
|
154
162
|
export const GetPassagesDocument = gql `
|
|
155
163
|
query GetPassages($uuid: ID!, $cursor: String, $limit: Int, $direction: PaginationDirection, $filter: PassageFilter) {
|
|
156
164
|
work(uuid: $uuid) {
|
|
@@ -316,6 +324,9 @@ export const GetWorkUuidsDocument = gql `
|
|
|
316
324
|
const defaultWrapper = (action, _operationName, _operationType, _variables) => action();
|
|
317
325
|
export function getSdk(client, withWrapper = defaultWrapper) {
|
|
318
326
|
return {
|
|
327
|
+
Lookup(variables, requestHeaders, signal) {
|
|
328
|
+
return withWrapper((wrappedRequestHeaders) => client.request({ document: LookupDocument, variables, requestHeaders: { ...requestHeaders, ...wrappedRequestHeaders }, signal }), 'Lookup', 'query', variables);
|
|
329
|
+
},
|
|
319
330
|
GetPassages(variables, requestHeaders, signal) {
|
|
320
331
|
return withWrapper((wrappedRequestHeaders) => client.request({ document: GetPassagesDocument, variables, requestHeaders: { ...requestHeaders, ...wrappedRequestHeaders }, signal }), 'GetPassages', 'query', variables);
|
|
321
332
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"graphql.js","sourceRoot":"","sources":["../../../../../libs/client-graphql/src/lib/generated/graphql.ts"],"names":[],"mappings":"AACA,OAAO,GAAG,MAAM,aAAa,CAAC;
|
|
1
|
+
{"version":3,"file":"graphql.js","sourceRoot":"","sources":["../../../../../libs/client-graphql/src/lib/generated/graphql.ts"],"names":[],"mappings":"AACA,OAAO,GAAG,MAAM,aAAa,CAAC;AA09B9B,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAG,CAAA;;;;;;KAMtC,CAAC;AACN,MAAM,CAAC,MAAM,iCAAiC,GAAG,GAAG,CAAA;;;;;;;KAO/C,CAAC;AACN,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAG,CAAA;;;;;;;;;;;;;;;;;;;;;;KAsBtC,CAAC;AACN,MAAM,CAAC,MAAM,wBAAwB,GAAG,GAAG,CAAA;;;;;;;;;;KAUtC,CAAC;AACN,MAAM,CAAC,MAAM,2BAA2B,GAAG,GAAG,CAAA;;;;;;;;KAQzC,CAAC;AACN,MAAM,CAAC,MAAM,0BAA0B,GAAG,GAAG,CAAA;;;;;;;;KAQxC,CAAC;AACN,MA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AAC,EAAE,cAAc,EAAE,OAAO,EAAE,SAAS,CAAC,CAAC;QAC/O,CAAC;KACF,CAAC;AACJ,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eightyfourthousand/client-graphql",
|
|
3
|
-
"version": "2026.5.
|
|
3
|
+
"version": "2026.5.2",
|
|
4
4
|
"description": "GraphQL client helpers and typed query functions for 84000 applications.",
|
|
5
5
|
"private": false,
|
|
6
6
|
"repository": {
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
"access": "public"
|
|
18
18
|
},
|
|
19
19
|
"dependencies": {
|
|
20
|
-
"@eightyfourthousand/data-access": "^2026.5.
|
|
20
|
+
"@eightyfourthousand/data-access": "^2026.5.2",
|
|
21
21
|
"graphql-request": "^7.1.2",
|
|
22
22
|
"graphql-tag": "^2.12.6"
|
|
23
23
|
},
|