synapse-react-client 3.3.6 → 3.3.8
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/index.cjs +24 -21
- package/dist/index.d.ts +71 -3
- package/dist/index.js +11714 -11069
- package/dist/style/base/_core.scss +0 -43
- package/dist/style/components/_query-wrapper-plot-nav.scss +1 -0
- package/dist/umd/synapse-react-client.development.css +1 -36
- package/dist/umd/synapse-react-client.development.js +2288 -1391
- package/dist/umd/synapse-react-client.production.min.css +1 -1
- package/dist/umd/synapse-react-client.production.min.js +196 -193
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -276,6 +276,7 @@ import { UserGroupHeaderResponse } from '@sage-bionetworks/synapse-types';
|
|
|
276
276
|
import { UserGroupHeaderResponsePage } from '@sage-bionetworks/synapse-types';
|
|
277
277
|
import { UserProfile } from '@sage-bionetworks/synapse-types';
|
|
278
278
|
import { UseStorageValueResult } from '@react-hookz/web/cjs/useStorageValue';
|
|
279
|
+
import { UseSuspenseQueryResult } from '@tanstack/react-query';
|
|
279
280
|
import { ValidateDefiningSqlResponse } from '@sage-bionetworks/synapse-types';
|
|
280
281
|
import { ValidationResults } from '@sage-bionetworks/synapse-types';
|
|
281
282
|
import { VerificationSubmission } from '@sage-bionetworks/synapse-types';
|
|
@@ -832,6 +833,20 @@ declare function createColumnModels(accessToken: string, columnModels: SetOption
|
|
|
832
833
|
*/
|
|
833
834
|
declare const createEntity: <T extends Entity>(entity: T, accessToken: string | undefined) => Promise<T>;
|
|
834
835
|
|
|
836
|
+
/**
|
|
837
|
+
* Create a new Access Control List (ACL), overriding inheritance.
|
|
838
|
+
*
|
|
839
|
+
* By default, Entities such as FileEntity and Folder inherit their permission from their containing Project. For such
|
|
840
|
+
* Entities the Project is the Entity's 'benefactor'. This permission inheritance can be overridden by creating an ACL
|
|
841
|
+
* for the Entity. When this occurs the Entity becomes its own benefactor and all permission are determined by its own ACL.
|
|
842
|
+
*
|
|
843
|
+
* If the ACL of an Entity is deleted, then its benefactor will automatically be set to its parent's benefactor.
|
|
844
|
+
*
|
|
845
|
+
* Note: The caller must be granted ACCESS_TYPE.CHANGE_PERMISSIONS on the Entity to call this method.
|
|
846
|
+
* https://rest-docs.synapse.org/rest/POST/entity/id/acl.html
|
|
847
|
+
*/
|
|
848
|
+
declare const createEntityACL: (acl: AccessControlList, accessToken?: string | undefined) => Promise<AccessControlList>;
|
|
849
|
+
|
|
835
850
|
/**
|
|
836
851
|
* Create an evaluation queue
|
|
837
852
|
* https://rest-docs.synapse.org/rest/POST/evaluation.html
|
|
@@ -1076,6 +1091,21 @@ declare const deleteEmail: (accessToken: string | undefined, email: string) => P
|
|
|
1076
1091
|
|
|
1077
1092
|
declare const deleteEntity: (accessToken: string | undefined, entityId: string | number) => Promise<void>;
|
|
1078
1093
|
|
|
1094
|
+
/**
|
|
1095
|
+
* Delete the Access Control List (ACL) for a given Entity.
|
|
1096
|
+
*
|
|
1097
|
+
* By default, Entities such as FileEntity and Folder inherit their permission from their containing Project. For such
|
|
1098
|
+
* Entities the Project is the Entity's 'benefactor'. This permission inheritance can be overridden by creating an ACL
|
|
1099
|
+
* for the Entity. When this occurs the Entity becomes its own benefactor and all permission are determined by its own ACL.
|
|
1100
|
+
*
|
|
1101
|
+
* If the ACL of an Entity is deleted, then its benefactor will automatically be set to its parent's benefactor. The ACL
|
|
1102
|
+
* for a Project cannot be deleted.
|
|
1103
|
+
*
|
|
1104
|
+
* Note: The caller must be granted ACCESS_TYPE.CHANGE_PERMISSIONS on the Entity to call this method.
|
|
1105
|
+
* https://rest-docs.synapse.org/rest/PUT/entity/id/acl.html
|
|
1106
|
+
*/
|
|
1107
|
+
declare const deleteEntityACL: (id: string, accessToken?: string | undefined) => Promise<void>;
|
|
1108
|
+
|
|
1079
1109
|
/**
|
|
1080
1110
|
* Delete an existing evaluation queue
|
|
1081
1111
|
* https://rest-docs.synapse.org/rest/PUT/evaluation/evalId.html
|
|
@@ -1498,7 +1528,11 @@ declare const EXPERIMENTAL_MODE_COOKIE = "SynapseTestWebsite";
|
|
|
1498
1528
|
|
|
1499
1529
|
declare const EXPERIMENTAL_TOOL: string;
|
|
1500
1530
|
|
|
1501
|
-
export declare const ExperimentalMode: default_2.
|
|
1531
|
+
export declare const ExperimentalMode: default_2.FunctionComponent<ExperimentalModeProps>;
|
|
1532
|
+
|
|
1533
|
+
declare type ExperimentalModeProps = {
|
|
1534
|
+
onExperimentalModeToggle?: (newValue: boolean) => void;
|
|
1535
|
+
};
|
|
1502
1536
|
|
|
1503
1537
|
declare const EXPLORE: string;
|
|
1504
1538
|
|
|
@@ -2727,6 +2761,8 @@ declare type ImmutableTableQueryResult = {
|
|
|
2727
2761
|
currentQueryRequest: ReadonlyDeep<QueryBundleRequest>;
|
|
2728
2762
|
/** The next (uncommitted) query request. This will become the current query request when commitChanges is called, or the configured debounced timer elapses. */
|
|
2729
2763
|
nextQueryRequest: ReadonlyDeep<QueryBundleRequest>;
|
|
2764
|
+
/** Resets the debounce timer to delay committing changes in `nextQueryRequest` */
|
|
2765
|
+
resetDebounceTimer: () => void;
|
|
2730
2766
|
/** Update the currentQueryRequest to be the nextQueryRequest */
|
|
2731
2767
|
commitChanges: () => void;
|
|
2732
2768
|
getInitQueryRequest: () => QueryBundleRequest;
|
|
@@ -3667,6 +3703,7 @@ export declare type QueryContextType<TIncludedFields extends OptionalQueryBundle
|
|
|
3667
3703
|
executeQueryRequest: ImmutableTableQueryResult['setQuery'];
|
|
3668
3704
|
/** Resets the query to its initial state, clearing all filters added by the user */
|
|
3669
3705
|
resetQuery: ImmutableTableQueryResult['resetQuery'];
|
|
3706
|
+
resetDebounceTimer: ImmutableTableQueryResult['resetDebounceTimer'];
|
|
3670
3707
|
addValueToSelectedFacet: ImmutableTableQueryResult['addValueToSelectedFacet'];
|
|
3671
3708
|
setRangeFacetValue: ImmutableTableQueryResult['setRangeFacetValue'];
|
|
3672
3709
|
removeSelectedFacet: ImmutableTableQueryResult['removeSelectedFacet'];
|
|
@@ -4413,7 +4450,9 @@ declare namespace SynapseClient {
|
|
|
4413
4450
|
getEntityHeaders,
|
|
4414
4451
|
getEntityAlias,
|
|
4415
4452
|
getEntityHeader,
|
|
4453
|
+
createEntityACL,
|
|
4416
4454
|
updateEntityACL,
|
|
4455
|
+
deleteEntityACL,
|
|
4417
4456
|
updateEntity,
|
|
4418
4457
|
deleteEntity,
|
|
4419
4458
|
getEntityBundleV2,
|
|
@@ -5280,11 +5319,16 @@ declare namespace SynapseQueries {
|
|
|
5280
5319
|
useGetEntityAlias,
|
|
5281
5320
|
useGetEntityEvaluations,
|
|
5282
5321
|
useGetEntityPermissions,
|
|
5322
|
+
useCreateEntityACL,
|
|
5283
5323
|
useUpdateEntityACL,
|
|
5324
|
+
useDeleteEntityACL,
|
|
5325
|
+
useSuspenseGetEntityBenefactorACL,
|
|
5284
5326
|
useUpdateTableColumns,
|
|
5285
5327
|
useGetSchemaBinding,
|
|
5286
5328
|
useGetValidationResults,
|
|
5329
|
+
useGetEntityBundleQueryOptions,
|
|
5287
5330
|
useGetEntityBundle,
|
|
5331
|
+
useSuspenseGetEntityBundle,
|
|
5288
5332
|
useGetEntityActionsRequired,
|
|
5289
5333
|
useGetEntityChallenge,
|
|
5290
5334
|
useGetEntityChildren,
|
|
@@ -5342,6 +5386,7 @@ declare namespace SynapseQueries {
|
|
|
5342
5386
|
useGetProjectsInfinite,
|
|
5343
5387
|
useGetNotificationEmail,
|
|
5344
5388
|
useGetCurrentUserProfile,
|
|
5389
|
+
useSuspenseGetCurrentUserProfile,
|
|
5345
5390
|
useGetUserBundle,
|
|
5346
5391
|
useGetCurrentUserBundle,
|
|
5347
5392
|
useGetUserProfile,
|
|
@@ -5812,6 +5857,8 @@ declare function useCreateAccessRequirementACL(options?: UseMutationOptions<Acce
|
|
|
5812
5857
|
|
|
5813
5858
|
declare function useCreateEntity(options?: UseMutationOptions<Entity, SynapseClientError, Pick<Entity, 'name' | 'description' | 'parentId' | 'concreteType'>>): UseMutationResult<Entity, SynapseClientError, Pick<Entity, "name" | "description" | "concreteType" | "parentId">, unknown>;
|
|
5814
5859
|
|
|
5860
|
+
declare function useCreateEntityACL(options?: Partial<UseMutationOptions<AccessControlList, SynapseClientError, AccessControlList>>): UseMutationResult<AccessControlList, SynapseClientError, AccessControlList, unknown>;
|
|
5861
|
+
|
|
5815
5862
|
declare function useCreateLockAccessRequirement(options?: Partial<UseMutationOptions<AccessRequirement, SynapseClientError, string>>): UseMutationResult<AccessRequirement, SynapseClientError, string, unknown>;
|
|
5816
5863
|
|
|
5817
5864
|
declare function useCreateOAuthClient(options?: Partial<UseMutationOptions<OAuthClient, SynapseClientError, OAuthClient>>): UseMutationResult<OAuthClient, SynapseClientError, OAuthClient, unknown>;
|
|
@@ -5839,6 +5886,8 @@ declare function useDeleteAccessRequirementACL(options?: UseMutationOptions<void
|
|
|
5839
5886
|
|
|
5840
5887
|
declare function useDeleteEntity(options?: Partial<UseMutationOptions<void, SynapseClientError, string>>): UseMutationResult<void, SynapseClientError, string, unknown>;
|
|
5841
5888
|
|
|
5889
|
+
declare function useDeleteEntityACL(options?: Partial<UseMutationOptions<void, SynapseClientError, string>>): UseMutationResult<void, SynapseClientError, string, unknown>;
|
|
5890
|
+
|
|
5842
5891
|
declare function useDeleteOAuthClient(options?: Partial<UseMutationOptions<void, SynapseClientError, string>>): UseMutationResult<void, SynapseClientError, string, unknown>;
|
|
5843
5892
|
|
|
5844
5893
|
declare function useDeleteTeamMembership(options?: Partial<UseMutationOptions<void, SynapseClientError, TeamMembershipParam>>): UseMutationResult<void, SynapseClientError, TeamMembershipParam, unknown>;
|
|
@@ -5918,7 +5967,12 @@ declare function useGetEntityActionsRequired(entityId: string, options?: Partial
|
|
|
5918
5967
|
|
|
5919
5968
|
declare function useGetEntityAlias(alias: string, options?: Partial<UseQueryOptions<EntityId | null, SynapseClientError>>): UseQueryResult<EntityId | null, SynapseClientError>;
|
|
5920
5969
|
|
|
5921
|
-
declare function useGetEntityBundle<T extends EntityBundleRequest = typeof ALL_ENTITY_BUNDLE_FIELDS
|
|
5970
|
+
declare function useGetEntityBundle<T extends EntityBundleRequest = typeof ALL_ENTITY_BUNDLE_FIELDS, TSelect = EntityBundle<T>>(entityId: string, version?: number, bundleRequest?: T, options?: Partial<UseQueryOptions<EntityBundle<T>, SynapseClientError, TSelect>>): UseQueryResult<TSelect, SynapseClientError>;
|
|
5971
|
+
|
|
5972
|
+
declare function useGetEntityBundleQueryOptions<T extends EntityBundleRequest = typeof ALL_ENTITY_BUNDLE_FIELDS>(entityId: string, version?: number, bundleRequest?: T): {
|
|
5973
|
+
queryKey: QueryKey;
|
|
5974
|
+
queryFn: () => Promise<EntityBundle<T>>;
|
|
5975
|
+
};
|
|
5922
5976
|
|
|
5923
5977
|
declare function useGetEntityChallenge(entityId: string, options?: Partial<UseQueryOptions<Challenge, SynapseClientError>>): UseQueryResult<Challenge, SynapseClientError>;
|
|
5924
5978
|
|
|
@@ -6049,7 +6103,7 @@ declare function useGetUserGroupHeader(principalId: string, options?: Partial<Us
|
|
|
6049
6103
|
/**
|
|
6050
6104
|
* Get an array of UserGroupHeaders, utilizing a react-query cache. This is always an unauthenticated call
|
|
6051
6105
|
* (the users current email addresses will never be returned in the result).
|
|
6052
|
-
* @param
|
|
6106
|
+
* @param principalIds
|
|
6053
6107
|
* @param options
|
|
6054
6108
|
* @returns
|
|
6055
6109
|
*/
|
|
@@ -6405,6 +6459,20 @@ request: CreateSubmissionRequest;
|
|
|
6405
6459
|
accessRequirementId: string;
|
|
6406
6460
|
}, unknown>;
|
|
6407
6461
|
|
|
6462
|
+
declare function useSuspenseGetCurrentUserProfile(options?: Partial<UseQueryOptions<UserProfile, SynapseClientError>>): UseSuspenseQueryResult<UserProfile, SynapseClientError>;
|
|
6463
|
+
|
|
6464
|
+
/**
|
|
6465
|
+
* Retrieve the ACL of an entity. This call will succeed even for entities where the caller
|
|
6466
|
+
* does not have READ permission.
|
|
6467
|
+
* @param entityId
|
|
6468
|
+
* @param options
|
|
6469
|
+
*/
|
|
6470
|
+
declare function useSuspenseGetEntityBenefactorACL(entityId: string, options?: Partial<UseQueryOptions<EntityBundle<{
|
|
6471
|
+
includeBenefactorACL: true;
|
|
6472
|
+
}>, SynapseClientError, AccessControlList>>): UseSuspenseQueryResult<AccessControlList, SynapseClientError>;
|
|
6473
|
+
|
|
6474
|
+
declare function useSuspenseGetEntityBundle<T extends EntityBundleRequest = typeof ALL_ENTITY_BUNDLE_FIELDS>(entityId: string, version?: number, bundleRequest?: T, options?: Partial<UseQueryOptions<EntityBundle<T>, SynapseClientError>>): UseSuspenseQueryResult<EntityBundle<T>, SynapseClientError>;
|
|
6475
|
+
|
|
6408
6476
|
export declare function useSynapseContext(): SynapseContextType;
|
|
6409
6477
|
|
|
6410
6478
|
declare function useUpdateAccessRequirement<T extends AccessRequirement>(options?: UseMutationOptions<T, SynapseClientError, T>): UseMutationResult<T, SynapseClientError, T, unknown>;
|