fix(storage-browser): rename S3-specific storage browser interfaces to generic storage types

This commit is contained in:
2026-03-14 17:10:20 +00:00
parent c55eb948fe
commit eb055e7214
9 changed files with 34 additions and 27 deletions

View File

@@ -1,15 +1,15 @@
/**
* S3 Data Provider interface - implement this to connect the S3 browser to your backend
* Storage Data Provider interface - implement this to connect the storage browser to your backend
*/
export interface IS3Object {
export interface IStorageObject {
key: string;
size?: number;
lastModified?: string;
isPrefix?: boolean;
}
export interface IS3ChangeEvent {
export interface IStorageChangeEvent {
type: 'add' | 'modify' | 'delete';
key: string;
bucket: string;
@@ -17,8 +17,8 @@ export interface IS3ChangeEvent {
lastModified?: Date;
}
export interface IS3DataProvider {
listObjects(bucket: string, prefix?: string, delimiter?: string): Promise<{ objects: IS3Object[]; prefixes: string[] }>;
export interface IStorageDataProvider {
listObjects(bucket: string, prefix?: string, delimiter?: string): Promise<{ objects: IStorageObject[]; prefixes: string[] }>;
getObject(bucket: string, key: string): Promise<{ content: string; contentType: string; size: number; lastModified: string }>;
putObject(bucket: string, key: string, base64Content: string, contentType: string): Promise<boolean>;
deleteObject(bucket: string, key: string): Promise<boolean>;
@@ -30,7 +30,7 @@ export interface IS3DataProvider {
export interface IColumn {
prefix: string;
objects: IS3Object[];
objects: IStorageObject[];
prefixes: string[];
selectedItem: string | null;
width: number;