@scality/data-browser-library 1.1.7 → 1.1.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.
|
@@ -1,7 +1,8 @@
|
|
|
1
|
+
import type { Feature } from '../types';
|
|
1
2
|
/**
|
|
2
3
|
* Hook to check if a feature is enabled in the S3 configuration.
|
|
3
4
|
*
|
|
4
5
|
* @param feature - The feature name to check
|
|
5
6
|
* @returns true if enabled, false if disabled, undefined if config not available
|
|
6
7
|
*/
|
|
7
|
-
export declare function useFeatures(feature:
|
|
8
|
+
export declare function useFeatures(feature: Feature): boolean | undefined;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -2,6 +2,10 @@ import type { S3ClientConfig } from '@aws-sdk/client-s3';
|
|
|
2
2
|
import type { AwsCredentialIdentity } from '@aws-sdk/types';
|
|
3
3
|
import type { ProxyConfiguration, S3EventType } from '../config/types';
|
|
4
4
|
export type { _Object, Bucket, BucketCannedACL, BucketLocationConstraint, CopyObjectCommandInput, CopyObjectCommandOutput, CreateBucketCommandInput, CreateBucketCommandOutput, DeleteBucketCommandInput, DeleteBucketCommandOutput, DeleteBucketCorsCommandOutput, DeleteBucketLifecycleCommandOutput, DeleteBucketPolicyCommandOutput, DeleteBucketReplicationCommandOutput, DeleteBucketTaggingCommandOutput, DeleteMarkerEntry, DeleteObjectCommandInput, DeleteObjectCommandOutput, DeleteObjectsCommandInput, DeleteObjectsCommandOutput, DeleteObjectTaggingCommandOutput, GetBucketAclCommandOutput, GetBucketCorsCommandOutput, GetBucketEncryptionCommandOutput, GetBucketLifecycleConfigurationCommandOutput, GetBucketLocationCommandInput, GetBucketLocationCommandOutput, GetBucketNotificationConfigurationCommandOutput, GetBucketPolicyCommandOutput, GetBucketReplicationCommandOutput, GetBucketTaggingCommandOutput, GetBucketVersioningCommandOutput, GetObjectAclCommandOutput, GetObjectAttributesCommandInput, GetObjectAttributesCommandOutput, GetObjectCommandInput, GetObjectCommandOutput, GetObjectLegalHoldCommandOutput, GetObjectLockConfigurationCommandOutput, GetObjectRetentionCommandOutput, GetObjectTaggingCommandOutput, GetObjectTorrentCommandOutput, HeadObjectCommandInput, HeadObjectCommandOutput, ListBucketsCommandOutput, ListMultipartUploadsCommandInput, ListMultipartUploadsCommandOutput, ListObjectsV2CommandInput, ListObjectsV2CommandOutput, ListObjectVersionsCommandInput, ListObjectVersionsCommandOutput, ObjectCannedACL, ObjectVersion, Owner, PutBucketAclCommandInput, PutBucketCorsCommandInput, PutBucketEncryptionCommandInput, PutBucketLifecycleConfigurationCommandInput, PutBucketNotificationConfigurationCommandInput, PutBucketPolicyCommandInput, PutBucketReplicationCommandInput, PutBucketTaggingCommandInput, PutBucketTaggingCommandOutput, PutBucketVersioningCommandInput, PutObjectAclCommandInput, PutObjectCommandInput, PutObjectCommandOutput, PutObjectLegalHoldCommandInput, PutObjectLockConfigurationCommandInput, PutObjectRetentionCommandInput, PutObjectTaggingCommandInput, RestoreObjectCommandInput, RestoreObjectCommandOutput, SelectObjectContentCommandInput, SelectObjectContentCommandOutput, Tag, } from '@aws-sdk/client-s3';
|
|
5
|
+
/**
|
|
6
|
+
* Known feature flags for the data browser.
|
|
7
|
+
*/
|
|
8
|
+
export type Feature = 'replicationAdvanced' | 'replicationV1' | 'metadatasearch' | 'ISV';
|
|
5
9
|
/**
|
|
6
10
|
* S3 backend capabilities configuration.
|
|
7
11
|
*/
|
|
@@ -22,7 +26,7 @@ export interface S3BrowserConfig extends Omit<S3ClientConfig, 'credentials'> {
|
|
|
22
26
|
proxy?: ProxyConfiguration;
|
|
23
27
|
publicAclIndicator?: string;
|
|
24
28
|
s3Capabilities?: S3Capabilities;
|
|
25
|
-
features?:
|
|
29
|
+
features?: Feature[];
|
|
26
30
|
/**
|
|
27
31
|
* Stable identifier for React Query cache isolation.
|
|
28
32
|
*
|