@manta-eu/client 0.8.1 → 0.10.0

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.
@@ -1128,6 +1128,25 @@ export type GQLGoogleBrandSuggestion = {
1128
1128
  urls: Array<Scalars["String"]["output"]>;
1129
1129
  };
1130
1130
 
1131
+ export type GQLGoogleMerchantCenterAccount = {
1132
+ __typename?: "GoogleMerchantCenterAccount";
1133
+ advanced?: Maybe<Scalars["Boolean"]["output"]>;
1134
+ externalId?: Maybe<Scalars["String"]["output"]>;
1135
+ id: Scalars["String"]["output"];
1136
+ isConnectable?: Maybe<Scalars["Boolean"]["output"]>;
1137
+ name?: Maybe<Scalars["String"]["output"]>;
1138
+ parent?: Maybe<Scalars["String"]["output"]>;
1139
+ testAccount?: Maybe<Scalars["Boolean"]["output"]>;
1140
+ unavailableReason?: Maybe<GQLSetupAccountUnavailableReason>;
1141
+ };
1142
+
1143
+ export type GQLGoogleMerchantCenterSetupProgress = {
1144
+ __typename?: "GoogleMerchantCenterSetupProgress";
1145
+ accounts?: Maybe<Array<GQLGoogleMerchantCenterAccount>>;
1146
+ lastError?: Maybe<GQLGoogleSetupLastError>;
1147
+ state: Array<GQLGoogleSetupStateEnum>;
1148
+ };
1149
+
1131
1150
  export type GQLGoogleSetupLastError = {
1132
1151
  __typename?: "GoogleSetupLastError";
1133
1152
  message: Scalars["String"]["output"];
@@ -1284,6 +1303,7 @@ export enum GQLIntegration {
1284
1303
  Figma = "FIGMA",
1285
1304
  Google = "GOOGLE",
1286
1305
  GoogleAnalytics = "GOOGLE_ANALYTICS",
1306
+ GoogleMerchantCenter = "GOOGLE_MERCHANT_CENTER",
1287
1307
  Linkedin = "LINKEDIN",
1288
1308
  Meta = "META",
1289
1309
  MicrosoftAds = "MICROSOFT_ADS",
@@ -1477,8 +1497,10 @@ export type GQLManualActionChangeAssigneesPayload = {
1477
1497
 
1478
1498
  export type GQLManualActionProgressResult = {
1479
1499
  __typename?: "ManualActionProgressResult";
1500
+ ended: Scalars["Boolean"]["output"];
1480
1501
  manualAction?: Maybe<GQLManualActionResult>;
1481
1502
  state: Array<Scalars["String"]["output"]>;
1503
+ workflowStatus?: Maybe<Scalars["String"]["output"]>;
1482
1504
  };
1483
1505
 
1484
1506
  export type GQLManualActionResolvePayload = {
@@ -1748,6 +1770,7 @@ export type GQLMutation = {
1748
1770
  forgetUserName: GQLForgetUserNameResponse;
1749
1771
  generateStructuredData: GQLStructuredDataResponse;
1750
1772
  googleAnalyticsSetupConnect: GQLGoogleAnalyticsSetupProgress;
1773
+ googleMerchantCenterSetupConnect: GQLGoogleMerchantCenterSetupProgress;
1751
1774
  googleSetupConnect: GQLGoogleSetupProgress;
1752
1775
  grantOperatorRole: GQLGrantOperatorRoleResponse;
1753
1776
  initiateUpload: GQLInitiateUploadResponse;
@@ -1981,6 +2004,10 @@ export type GQLMutationGoogleAnalyticsSetupConnectArgs = {
1981
2004
  propertyIds: Array<Scalars["String"]["input"]>;
1982
2005
  };
1983
2006
 
2007
+ export type GQLMutationGoogleMerchantCenterSetupConnectArgs = {
2008
+ accountIds: Array<Scalars["String"]["input"]>;
2009
+ };
2010
+
1984
2011
  export type GQLMutationGoogleSetupConnectArgs = {
1985
2012
  accountIds: Array<Scalars["String"]["input"]>;
1986
2013
  };
@@ -2089,6 +2116,7 @@ export type GQLMutationRefreshResourcesArgs = {
2089
2116
 
2090
2117
  export type GQLMutationRegisterDatastoreArgs = {
2091
2118
  datastoreId: Scalars["String"]["input"];
2119
+ launchProvisioning?: InputMaybe<Scalars["Boolean"]["input"]>;
2092
2120
  };
2093
2121
 
2094
2122
  export type GQLMutationReleaseRuleOwnershipArgs = {
@@ -2375,11 +2403,13 @@ export type GQLQuery = {
2375
2403
  gmailIntegrations: Array<GQLGmailIntegration>;
2376
2404
  googleAnalyticsSetupProgress: GQLGoogleAnalyticsSetupProgress;
2377
2405
  googleBrandSuggestions: Array<GQLGoogleBrandSuggestion>;
2406
+ googleMerchantCenterSetupProgress: GQLGoogleMerchantCenterSetupProgress;
2378
2407
  googleSetupProgress: GQLGoogleSetupProgress;
2379
2408
  inferalIntegrations: Array<GQLInferalIntegration>;
2380
2409
  knowledgeGraphState: GQLKnowledgeGraphState;
2381
2410
  ldesStreams: Array<GQLLdesStream>;
2382
2411
  linkedinSetupProgress?: Maybe<GQLLinkedinSetupProgress>;
2412
+ manualActionProgress?: Maybe<GQLManualActionProgressResult>;
2383
2413
  memories: GQLMemoriesResponse;
2384
2414
  memoryRedundancyReview: GQLMemoryRedundancyResult;
2385
2415
  memoryReplaySeries: GQLMemoryReplaySeriesResult;
@@ -2530,6 +2560,11 @@ export type GQLQueryKnowledgeGraphStateArgs = {
2530
2560
  dataVersion?: InputMaybe<Scalars["String"]["input"]>;
2531
2561
  };
2532
2562
 
2563
+ export type GQLQueryManualActionProgressArgs = {
2564
+ namedGraphIri: Scalars["String"]["input"];
2565
+ subjectIri: Scalars["String"]["input"];
2566
+ };
2567
+
2533
2568
  export type GQLQueryMemoriesArgs = {
2534
2569
  includeArchived?: InputMaybe<Scalars["Boolean"]["input"]>;
2535
2570
  includeOutOfWindow?: InputMaybe<Scalars["Boolean"]["input"]>;
@@ -2696,6 +2731,7 @@ export enum GQLRefreshWorkflowStatus {
2696
2731
  export type GQLRegisterDatastoreResponse = {
2697
2732
  __typename?: "RegisterDatastoreResponse";
2698
2733
  error?: Maybe<Scalars["String"]["output"]>;
2734
+ pending: Scalars["Boolean"]["output"];
2699
2735
  success: Scalars["Boolean"]["output"];
2700
2736
  };
2701
2737
 
@@ -2939,6 +2975,7 @@ export type GQLSessionUser = {
2939
2975
 
2940
2976
  export enum GQLSetupAccountUnavailableReason {
2941
2977
  InsufficientPermissions = "INSUFFICIENT_PERMISSIONS",
2978
+ TermsNotAccepted = "TERMS_NOT_ACCEPTED",
2942
2979
  }
2943
2980
 
2944
2981
  export enum GQLShaclSeverity {
@@ -3149,6 +3186,7 @@ export type GQLTeamMember = {
3149
3186
  federated?: Maybe<Scalars["Boolean"]["output"]>;
3150
3187
  id: Scalars["String"]["output"];
3151
3188
  inviteUrl?: Maybe<Scalars["String"]["output"]>;
3189
+ lastSignInAt?: Maybe<Scalars["DateTime"]["output"]>;
3152
3190
  managed?: Maybe<Scalars["Boolean"]["output"]>;
3153
3191
  name?: Maybe<Scalars["String"]["output"]>;
3154
3192
  pending: Scalars["Boolean"]["output"];
@@ -3241,6 +3279,7 @@ export type GQLTriplewhaleProviderInput = {
3241
3279
 
3242
3280
  export type GQLUnlinkedDatastore = {
3243
3281
  __typename?: "UnlinkedDatastore";
3282
+ built: Scalars["Boolean"]["output"];
3244
3283
  id: Scalars["String"]["output"];
3245
3284
  };
3246
3285
 
@@ -4015,6 +4054,30 @@ export type GQLGoogleAnalyticsSetupConnectMutation = {
4015
4054
  };
4016
4055
  };
4017
4056
 
4057
+ export type GQLGoogleMerchantCenterSetupConnectMutationVariables = Exact<{
4058
+ accountIds: Array<Scalars["String"]["input"]> | Scalars["String"]["input"];
4059
+ }>;
4060
+
4061
+ export type GQLGoogleMerchantCenterSetupConnectMutation = {
4062
+ __typename?: "Mutation";
4063
+ googleMerchantCenterSetupConnect: {
4064
+ __typename?: "GoogleMerchantCenterSetupProgress";
4065
+ state: Array<GQLGoogleSetupStateEnum>;
4066
+ accounts?: Array<{
4067
+ __typename?: "GoogleMerchantCenterAccount";
4068
+ id: string;
4069
+ name?: string | null;
4070
+ parent?: string | null;
4071
+ }> | null;
4072
+ lastError?: {
4073
+ __typename?: "GoogleSetupLastError";
4074
+ severity: string;
4075
+ title?: string | null;
4076
+ message: string;
4077
+ } | null;
4078
+ };
4079
+ };
4080
+
4018
4081
  export type GQLGoogleSetupConnectMutationVariables = Exact<{
4019
4082
  accountIds: Array<Scalars["String"]["input"]> | Scalars["String"]["input"];
4020
4083
  }>;
@@ -4125,6 +4188,7 @@ export type GQLLinkUnlinkedDatastoreMutation = {
4125
4188
  datastoreId?: string | null;
4126
4189
  name?: string | null;
4127
4190
  path?: string | null;
4191
+ pending: boolean;
4128
4192
  providerWarning?: string | null;
4129
4193
  };
4130
4194
  };
@@ -4157,7 +4221,12 @@ export type GQLChangeManualActionAssigneesMutation = {
4157
4221
  manualActionProgress: {
4158
4222
  __typename?: "ManualActionProgressResult";
4159
4223
  state: Array<string>;
4160
- manualAction?: { __typename?: "ManualActionResult"; status?: string | null; assignees: Array<string> } | null;
4224
+ manualAction?: {
4225
+ __typename?: "ManualActionResult";
4226
+ status?: string | null;
4227
+ assignees: Array<string>;
4228
+ resolvedBy?: string | null;
4229
+ } | null;
4161
4230
  };
4162
4231
  } | null;
4163
4232
  };
@@ -4176,7 +4245,12 @@ export type GQLResolveManualActionMutation = {
4176
4245
  manualActionProgress: {
4177
4246
  __typename?: "ManualActionProgressResult";
4178
4247
  state: Array<string>;
4179
- manualAction?: { __typename?: "ManualActionResult"; status?: string | null; assignees: Array<string> } | null;
4248
+ manualAction?: {
4249
+ __typename?: "ManualActionResult";
4250
+ status?: string | null;
4251
+ assignees: Array<string>;
4252
+ resolvedBy?: string | null;
4253
+ } | null;
4180
4254
  };
4181
4255
  } | null;
4182
4256
  };
@@ -4356,11 +4430,17 @@ export type GQLRefreshResourcesMutation = {
4356
4430
 
4357
4431
  export type GQLRegisterDatastoreMutationVariables = Exact<{
4358
4432
  datastoreId: Scalars["String"]["input"];
4433
+ launchProvisioning?: InputMaybe<Scalars["Boolean"]["input"]>;
4359
4434
  }>;
4360
4435
 
4361
4436
  export type GQLRegisterDatastoreMutation = {
4362
4437
  __typename?: "Mutation";
4363
- registerDatastore: { __typename?: "RegisterDatastoreResponse"; success: boolean; error?: string | null };
4438
+ registerDatastore: {
4439
+ __typename?: "RegisterDatastoreResponse";
4440
+ success: boolean;
4441
+ error?: string | null;
4442
+ pending: boolean;
4443
+ };
4364
4444
  };
4365
4445
 
4366
4446
  export type GQLReleaseRuleOwnershipMutationVariables = Exact<{
@@ -5590,6 +5670,33 @@ export type GQLGoogleBrandSuggestionsQuery = {
5590
5670
  }>;
5591
5671
  };
5592
5672
 
5673
+ export type GQLGoogleMerchantCenterSetupProgressQueryVariables = Exact<{ [key: string]: never }>;
5674
+
5675
+ export type GQLGoogleMerchantCenterSetupProgressQuery = {
5676
+ __typename?: "Query";
5677
+ googleMerchantCenterSetupProgress: {
5678
+ __typename?: "GoogleMerchantCenterSetupProgress";
5679
+ state: Array<GQLGoogleSetupStateEnum>;
5680
+ accounts?: Array<{
5681
+ __typename?: "GoogleMerchantCenterAccount";
5682
+ id: string;
5683
+ name?: string | null;
5684
+ parent?: string | null;
5685
+ externalId?: string | null;
5686
+ advanced?: boolean | null;
5687
+ testAccount?: boolean | null;
5688
+ isConnectable?: boolean | null;
5689
+ unavailableReason?: GQLSetupAccountUnavailableReason | null;
5690
+ }> | null;
5691
+ lastError?: {
5692
+ __typename?: "GoogleSetupLastError";
5693
+ severity: string;
5694
+ title?: string | null;
5695
+ message: string;
5696
+ } | null;
5697
+ };
5698
+ };
5699
+
5593
5700
  export type GQLGoogleSetupProgressQueryVariables = Exact<{ [key: string]: never }>;
5594
5701
 
5595
5702
  export type GQLGoogleSetupProgressQuery = {
@@ -5688,6 +5795,27 @@ export type GQLLinkedinSetupProgressQuery = {
5688
5795
  } | null;
5689
5796
  };
5690
5797
 
5798
+ export type GQLManualActionProgressQueryVariables = Exact<{
5799
+ namedGraphIri: Scalars["String"]["input"];
5800
+ subjectIri: Scalars["String"]["input"];
5801
+ }>;
5802
+
5803
+ export type GQLManualActionProgressQuery = {
5804
+ __typename?: "Query";
5805
+ manualActionProgress?: {
5806
+ __typename?: "ManualActionProgressResult";
5807
+ state: Array<string>;
5808
+ ended: boolean;
5809
+ workflowStatus?: string | null;
5810
+ manualAction?: {
5811
+ __typename?: "ManualActionResult";
5812
+ status?: string | null;
5813
+ assignees: Array<string>;
5814
+ resolvedBy?: string | null;
5815
+ } | null;
5816
+ } | null;
5817
+ };
5818
+
5691
5819
  export type GQLMemoriesQueryVariables = Exact<{
5692
5820
  includeArchived?: InputMaybe<Scalars["Boolean"]["input"]>;
5693
5821
  includeOutOfWindow?: InputMaybe<Scalars["Boolean"]["input"]>;
@@ -6269,6 +6397,7 @@ export type GQLTeamMembersQuery = {
6269
6397
  federated?: boolean | null;
6270
6398
  enabled: boolean;
6271
6399
  managed?: boolean | null;
6400
+ lastSignInAt?: Date | string | null;
6272
6401
  }>;
6273
6402
  };
6274
6403
  };
@@ -6303,7 +6432,7 @@ export type GQLUnlinkedDatastoresQueryVariables = Exact<{ [key: string]: never }
6303
6432
 
6304
6433
  export type GQLUnlinkedDatastoresQuery = {
6305
6434
  __typename?: "Query";
6306
- unlinkedDatastores: Array<{ __typename?: "UnlinkedDatastore"; id: string }>;
6435
+ unlinkedDatastores: Array<{ __typename?: "UnlinkedDatastore"; id: string; built: boolean }>;
6307
6436
  };
6308
6437
 
6309
6438
  export type GQLUserPreferencesQueryVariables = Exact<{ [key: string]: never }>;
@@ -7799,6 +7928,52 @@ export const useGoogleAnalyticsSetupConnectMutation = <TError = unknown, TContex
7799
7928
  });
7800
7929
  };
7801
7930
 
7931
+ export const GoogleMerchantCenterSetupConnectDocument = `
7932
+ mutation GoogleMerchantCenterSetupConnect($accountIds: [String!]!) {
7933
+ googleMerchantCenterSetupConnect(accountIds: $accountIds) {
7934
+ state
7935
+ accounts {
7936
+ id
7937
+ name
7938
+ parent
7939
+ }
7940
+ lastError {
7941
+ severity
7942
+ title
7943
+ message
7944
+ }
7945
+ }
7946
+ }
7947
+ `;
7948
+
7949
+ export const useGoogleMerchantCenterSetupConnectMutation = <TError = unknown, TContext = unknown>(
7950
+ client: GraphQLClient,
7951
+ options?: UseMutationOptions<
7952
+ GQLGoogleMerchantCenterSetupConnectMutation,
7953
+ TError,
7954
+ GQLGoogleMerchantCenterSetupConnectMutationVariables,
7955
+ TContext
7956
+ >,
7957
+ headers?: RequestInit["headers"],
7958
+ ) => {
7959
+ return useMutation<
7960
+ GQLGoogleMerchantCenterSetupConnectMutation,
7961
+ TError,
7962
+ GQLGoogleMerchantCenterSetupConnectMutationVariables,
7963
+ TContext
7964
+ >({
7965
+ mutationKey: ["GoogleMerchantCenterSetupConnect"],
7966
+ mutationFn: (variables?: GQLGoogleMerchantCenterSetupConnectMutationVariables) =>
7967
+ fetcher<GQLGoogleMerchantCenterSetupConnectMutation, GQLGoogleMerchantCenterSetupConnectMutationVariables>(
7968
+ client,
7969
+ GoogleMerchantCenterSetupConnectDocument,
7970
+ variables,
7971
+ headers,
7972
+ )(),
7973
+ ...options,
7974
+ });
7975
+ };
7976
+
7802
7977
  export const GoogleSetupConnectDocument = `
7803
7978
  mutation GoogleSetupConnect($accountIds: [String!]!) {
7804
7979
  googleSetupConnect(accountIds: $accountIds) {
@@ -8017,6 +8192,7 @@ export const LinkUnlinkedDatastoreDocument = `
8017
8192
  datastoreId
8018
8193
  name
8019
8194
  path
8195
+ pending
8020
8196
  providerWarning
8021
8197
  }
8022
8198
  }
@@ -8098,6 +8274,7 @@ export const ChangeManualActionAssigneesDocument = `
8098
8274
  manualAction {
8099
8275
  status
8100
8276
  assignees
8277
+ resolvedBy
8101
8278
  }
8102
8279
  }
8103
8280
  }
@@ -8145,6 +8322,7 @@ export const ResolveManualActionDocument = `
8145
8322
  manualAction {
8146
8323
  status
8147
8324
  assignees
8325
+ resolvedBy
8148
8326
  }
8149
8327
  }
8150
8328
  }
@@ -8470,10 +8648,14 @@ export const useRefreshResourcesMutation = <TError = unknown, TContext = unknown
8470
8648
  };
8471
8649
 
8472
8650
  export const RegisterDatastoreDocument = `
8473
- mutation RegisterDatastore($datastoreId: String!) {
8474
- registerDatastore(datastoreId: $datastoreId) {
8651
+ mutation RegisterDatastore($datastoreId: String!, $launchProvisioning: Boolean) {
8652
+ registerDatastore(
8653
+ datastoreId: $datastoreId
8654
+ launchProvisioning: $launchProvisioning
8655
+ ) {
8475
8656
  success
8476
8657
  error
8658
+ pending
8477
8659
  }
8478
8660
  }
8479
8661
  `;
@@ -11259,6 +11441,91 @@ useSuspenseGoogleBrandSuggestionsQuery.getKey = (variables: GQLGoogleBrandSugges
11259
11441
  variables,
11260
11442
  ];
11261
11443
 
11444
+ export const GoogleMerchantCenterSetupProgressDocument = `
11445
+ query GoogleMerchantCenterSetupProgress {
11446
+ googleMerchantCenterSetupProgress {
11447
+ state
11448
+ accounts {
11449
+ id
11450
+ name
11451
+ parent
11452
+ externalId
11453
+ advanced
11454
+ testAccount
11455
+ isConnectable
11456
+ unavailableReason
11457
+ }
11458
+ lastError {
11459
+ severity
11460
+ title
11461
+ message
11462
+ }
11463
+ }
11464
+ }
11465
+ `;
11466
+
11467
+ export const useGoogleMerchantCenterSetupProgressQuery = <
11468
+ TData = GQLGoogleMerchantCenterSetupProgressQuery,
11469
+ TError = unknown,
11470
+ >(
11471
+ client: GraphQLClient,
11472
+ variables?: GQLGoogleMerchantCenterSetupProgressQueryVariables,
11473
+ options?: Omit<UseQueryOptions<GQLGoogleMerchantCenterSetupProgressQuery, TError, TData>, "queryKey"> & {
11474
+ queryKey?: UseQueryOptions<GQLGoogleMerchantCenterSetupProgressQuery, TError, TData>["queryKey"];
11475
+ },
11476
+ headers?: RequestInit["headers"],
11477
+ ) => {
11478
+ return useQuery<GQLGoogleMerchantCenterSetupProgressQuery, TError, TData>({
11479
+ queryKey:
11480
+ variables === undefined
11481
+ ? ["GoogleMerchantCenterSetupProgress"]
11482
+ : ["GoogleMerchantCenterSetupProgress", variables],
11483
+ queryFn: fetcher<GQLGoogleMerchantCenterSetupProgressQuery, GQLGoogleMerchantCenterSetupProgressQueryVariables>(
11484
+ client,
11485
+ GoogleMerchantCenterSetupProgressDocument,
11486
+ variables,
11487
+ headers,
11488
+ ),
11489
+ ...options,
11490
+ });
11491
+ };
11492
+
11493
+ useGoogleMerchantCenterSetupProgressQuery.getKey = (variables?: GQLGoogleMerchantCenterSetupProgressQueryVariables) =>
11494
+ variables === undefined ? ["GoogleMerchantCenterSetupProgress"] : ["GoogleMerchantCenterSetupProgress", variables];
11495
+
11496
+ export const useSuspenseGoogleMerchantCenterSetupProgressQuery = <
11497
+ TData = GQLGoogleMerchantCenterSetupProgressQuery,
11498
+ TError = unknown,
11499
+ >(
11500
+ client: GraphQLClient,
11501
+ variables?: GQLGoogleMerchantCenterSetupProgressQueryVariables,
11502
+ options?: Omit<UseSuspenseQueryOptions<GQLGoogleMerchantCenterSetupProgressQuery, TError, TData>, "queryKey"> & {
11503
+ queryKey?: UseSuspenseQueryOptions<GQLGoogleMerchantCenterSetupProgressQuery, TError, TData>["queryKey"];
11504
+ },
11505
+ headers?: RequestInit["headers"],
11506
+ ) => {
11507
+ return useSuspenseQuery<GQLGoogleMerchantCenterSetupProgressQuery, TError, TData>({
11508
+ queryKey:
11509
+ variables === undefined
11510
+ ? ["GoogleMerchantCenterSetupProgressSuspense"]
11511
+ : ["GoogleMerchantCenterSetupProgressSuspense", variables],
11512
+ queryFn: fetcher<GQLGoogleMerchantCenterSetupProgressQuery, GQLGoogleMerchantCenterSetupProgressQueryVariables>(
11513
+ client,
11514
+ GoogleMerchantCenterSetupProgressDocument,
11515
+ variables,
11516
+ headers,
11517
+ ),
11518
+ ...options,
11519
+ });
11520
+ };
11521
+
11522
+ useSuspenseGoogleMerchantCenterSetupProgressQuery.getKey = (
11523
+ variables?: GQLGoogleMerchantCenterSetupProgressQueryVariables,
11524
+ ) =>
11525
+ variables === undefined
11526
+ ? ["GoogleMerchantCenterSetupProgressSuspense"]
11527
+ : ["GoogleMerchantCenterSetupProgressSuspense", variables];
11528
+
11262
11529
  export const GoogleSetupProgressDocument = `
11263
11530
  query GoogleSetupProgress {
11264
11531
  googleSetupProgress {
@@ -11585,6 +11852,71 @@ export const useSuspenseLinkedinSetupProgressQuery = <TData = GQLLinkedinSetupPr
11585
11852
  useSuspenseLinkedinSetupProgressQuery.getKey = (variables?: GQLLinkedinSetupProgressQueryVariables) =>
11586
11853
  variables === undefined ? ["LinkedinSetupProgressSuspense"] : ["LinkedinSetupProgressSuspense", variables];
11587
11854
 
11855
+ export const ManualActionProgressDocument = `
11856
+ query ManualActionProgress($namedGraphIri: String!, $subjectIri: String!) {
11857
+ manualActionProgress(namedGraphIri: $namedGraphIri, subjectIri: $subjectIri) {
11858
+ state
11859
+ ended
11860
+ workflowStatus
11861
+ manualAction {
11862
+ status
11863
+ assignees
11864
+ resolvedBy
11865
+ }
11866
+ }
11867
+ }
11868
+ `;
11869
+
11870
+ export const useManualActionProgressQuery = <TData = GQLManualActionProgressQuery, TError = unknown>(
11871
+ client: GraphQLClient,
11872
+ variables: GQLManualActionProgressQueryVariables,
11873
+ options?: Omit<UseQueryOptions<GQLManualActionProgressQuery, TError, TData>, "queryKey"> & {
11874
+ queryKey?: UseQueryOptions<GQLManualActionProgressQuery, TError, TData>["queryKey"];
11875
+ },
11876
+ headers?: RequestInit["headers"],
11877
+ ) => {
11878
+ return useQuery<GQLManualActionProgressQuery, TError, TData>({
11879
+ queryKey: ["ManualActionProgress", variables],
11880
+ queryFn: fetcher<GQLManualActionProgressQuery, GQLManualActionProgressQueryVariables>(
11881
+ client,
11882
+ ManualActionProgressDocument,
11883
+ variables,
11884
+ headers,
11885
+ ),
11886
+ ...options,
11887
+ });
11888
+ };
11889
+
11890
+ useManualActionProgressQuery.getKey = (variables: GQLManualActionProgressQueryVariables) => [
11891
+ "ManualActionProgress",
11892
+ variables,
11893
+ ];
11894
+
11895
+ export const useSuspenseManualActionProgressQuery = <TData = GQLManualActionProgressQuery, TError = unknown>(
11896
+ client: GraphQLClient,
11897
+ variables: GQLManualActionProgressQueryVariables,
11898
+ options?: Omit<UseSuspenseQueryOptions<GQLManualActionProgressQuery, TError, TData>, "queryKey"> & {
11899
+ queryKey?: UseSuspenseQueryOptions<GQLManualActionProgressQuery, TError, TData>["queryKey"];
11900
+ },
11901
+ headers?: RequestInit["headers"],
11902
+ ) => {
11903
+ return useSuspenseQuery<GQLManualActionProgressQuery, TError, TData>({
11904
+ queryKey: ["ManualActionProgressSuspense", variables],
11905
+ queryFn: fetcher<GQLManualActionProgressQuery, GQLManualActionProgressQueryVariables>(
11906
+ client,
11907
+ ManualActionProgressDocument,
11908
+ variables,
11909
+ headers,
11910
+ ),
11911
+ ...options,
11912
+ });
11913
+ };
11914
+
11915
+ useSuspenseManualActionProgressQuery.getKey = (variables: GQLManualActionProgressQueryVariables) => [
11916
+ "ManualActionProgressSuspense",
11917
+ variables,
11918
+ ];
11919
+
11588
11920
  export const MemoriesDocument = `
11589
11921
  query Memories($includeArchived: Boolean, $includeOutOfWindow: Boolean) {
11590
11922
  memories(
@@ -13041,6 +13373,7 @@ export const TeamMembersDocument = `
13041
13373
  federated
13042
13374
  enabled
13043
13375
  managed
13376
+ lastSignInAt
13044
13377
  }
13045
13378
  }
13046
13379
  }
@@ -13202,6 +13535,7 @@ export const UnlinkedDatastoresDocument = `
13202
13535
  query UnlinkedDatastores {
13203
13536
  unlinkedDatastores {
13204
13537
  id
13538
+ built
13205
13539
  }
13206
13540
  }
13207
13541
  `;
@@ -8,6 +8,8 @@ export const datastoreQueryParam = "datastore";
8
8
 
9
9
  export const redirectRoutePath = "/redirect";
10
10
 
11
+ export const imageRoutePath = "/image";
12
+
11
13
  export type DatastoreLocation = { datastoreId: string | undefined; path: string };
12
14
 
13
15
  const datastorePathPattern = new RegExp(`^${datastoreRoutePrefix}/([^/]+)(/.*)?$`);
@@ -0,0 +1,47 @@
1
+ import { datastoreRoutePrefix, imageRoutePath } from "./datastore-path";
2
+
3
+ export const imageWidths = [160, 320, 480, 640, 960, 1280, 1920] as const;
4
+
5
+ export type ImageWidth = (typeof imageWidths)[number];
6
+
7
+ const resizableImageTypes: ReadonlySet<string> = new Set([
8
+ "image/png",
9
+ "image/jpeg",
10
+ "image/pjpeg",
11
+ "image/gif",
12
+ "image/webp",
13
+ ]);
14
+
15
+ const smallestImageWidth: ImageWidth = 160;
16
+ const largestImageWidth: ImageWidth = 1920;
17
+
18
+ export function isImageWidth(value: unknown): value is ImageWidth {
19
+ return typeof value === "number" && (imageWidths as readonly number[]).includes(value);
20
+ }
21
+
22
+ export function isResizableImageType(mediaType: string): boolean {
23
+ return resizableImageTypes.has(mediaType.split(";")[0]!.trim().toLowerCase());
24
+ }
25
+
26
+ export function imageWidthFor(cssWidth: number, devicePixelRatio = 1): ImageWidth {
27
+ const needed = Math.ceil(cssWidth * Math.min(Math.max(devicePixelRatio, 1), 3));
28
+ if (!Number.isFinite(needed)) return smallestImageWidth;
29
+
30
+ return imageWidths.find((width) => width >= needed) ?? largestImageWidth;
31
+ }
32
+
33
+ // Name the datastore when the file may sit outside the session's own, since an <img> sends no datastore header.
34
+ // `datastorePrefix` is where the app mounts datastore-scoped routes: "/d" on the platform's own origin.
35
+ export type ImageScope = { datastoreId?: string | null; datastorePrefix?: string };
36
+
37
+ export function imagePath(iri: string, width: ImageWidth, scope: ImageScope = {}): string {
38
+ const { datastoreId, datastorePrefix = datastoreRoutePrefix } = scope;
39
+ const route = datastoreId ? `${datastorePrefix}/${encodeURIComponent(datastoreId)}${imageRoutePath}` : imageRoutePath;
40
+
41
+ return `${route}?iri=${encodeURIComponent(iri)}&width=${width}`;
42
+ }
43
+
44
+ // Every ladder width as `srcset` candidates; pair it with `sizes` so the browser picks the width itself.
45
+ export function imageSrcSet(iri: string, scope: ImageScope = {}): string {
46
+ return imageWidths.map((width) => `${imagePath(iri, width, scope)} ${width}w`).join(", ");
47
+ }
@@ -16,6 +16,7 @@ export type TeamMember = {
16
16
  // Keycloak deletes a managed member's account when they leave the organization.
17
17
  managed?: true;
18
18
  enabled: boolean;
19
+ lastSignInAt?: string;
19
20
  };
20
21
 
21
22
  export type TeamOrganization = {
@@ -1,9 +1,12 @@
1
1
  import { getExtension } from "@manta-eu/lib/file";
2
+ import { isPresent } from "@manta-eu/lib/present";
2
3
  import mime from "mime";
3
4
  import { MIMEType } from "whatwg-mimetype";
4
5
 
5
6
  export const uploadPartSize = 8 * 1024 * 1024;
6
7
 
8
+ export const maxUploadBytes = 5 * 1024 * 1024 * 1024;
9
+
7
10
  export function bytesToHex(buffer: ArrayBuffer) {
8
11
  return [...new Uint8Array(buffer)].map((byte) => byte.toString(16).padStart(2, "0")).join("");
9
12
  }
@@ -48,6 +51,16 @@ export function isFileNameTooLong(fileName: string) {
48
51
  return new TextEncoder().encode(fileName).length > maxFileNameBytes;
49
52
  }
50
53
 
54
+ // Recorded on the file as ingest:uploadPurpose; kgc ingests only "file" uploads.
55
+ export type UploadPurposeValue = "file" | "bundle";
56
+
57
+ // The file types kgc ingests into the knowledge graph; anything else is stored but never ingested.
58
+ export const ingestableExtensions = new Set(["csv", "parquet", "ttl", "nt"]);
59
+
60
+ export function isIngestableExtension(extension: string | undefined) {
61
+ return isPresent(extension) && ingestableExtensions.has(extension.toLowerCase());
62
+ }
63
+
51
64
  export function mediaTypeFromExtension(extension: string | undefined) {
52
65
  return (extension ? mime.getType(extension) : undefined) ?? "application/octet-stream";
53
66
  }