nb-js-client 0.0.34 → 0.0.36

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.
Files changed (57) hide show
  1. package/dist/api/auth-api.service.d.ts +20 -0
  2. package/dist/api/connections-api.service.d.ts +20 -0
  3. package/dist/api/discovery-api.service.d.ts +8 -0
  4. package/dist/api/divide-api.service.d.ts +19 -0
  5. package/dist/api/extensions-api.service.d.ts +33 -0
  6. package/dist/api/extensions-external-api.service.d.ts +14 -0
  7. package/dist/api/fca-api.service.d.ts +21 -0
  8. package/dist/api/gateway-api.service.d.ts +25 -0
  9. package/dist/api/group-api.service.d.ts +20 -0
  10. package/dist/api/index.d.ts +22 -0
  11. package/dist/api/license-api.service.d.ts +13 -0
  12. package/dist/api/links-api.service.d.ts +18 -0
  13. package/dist/api/logstash-api.service.d.ts +15 -0
  14. package/dist/api/notification-api.service.d.ts +25 -0
  15. package/dist/api/role-api.service.d.ts +20 -0
  16. package/dist/api/share-api.service.d.ts +15 -0
  17. package/dist/api/storage-element-api.service.d.ts +62 -0
  18. package/dist/api/storage-files-api.service.d.ts +23 -0
  19. package/dist/api/storage-instance-api.service.d.ts +7 -0
  20. package/dist/api/storage-share-api.service.d.ts +11 -0
  21. package/dist/api/storage-trash-api.service.d.ts +11 -0
  22. package/dist/api/user-api.service.d.ts +57 -0
  23. package/dist/api/version-api.service.d.ts +19 -0
  24. package/dist/bundle.cjs.js +1 -0
  25. package/dist/bundle.esm.js +1 -0
  26. package/dist/classes/client.d.ts +41 -0
  27. package/dist/classes/index.d.ts +3 -0
  28. package/dist/classes/rest.d.ts +24 -0
  29. package/dist/classes/token-update.d.ts +10 -0
  30. package/dist/index.d.ts +1315 -0
  31. package/dist/tools/apply-interceptors.d.ts +4 -0
  32. package/dist/tools/get-cookie-value.d.ts +1 -0
  33. package/dist/tools/index.d.ts +4 -0
  34. package/dist/tools/make-url-params.d.ts +1 -0
  35. package/dist/tools/normalize-headers.d.ts +1 -0
  36. package/dist/types/access-rights.d.ts +36 -0
  37. package/dist/types/access-token.d.ts +15 -0
  38. package/dist/types/auth.d.ts +9 -0
  39. package/dist/types/base.d.ts +48 -0
  40. package/dist/types/connection.d.ts +36 -0
  41. package/dist/types/discovery.d.ts +15 -0
  42. package/dist/types/divide.d.ts +82 -0
  43. package/dist/types/extension.d.ts +80 -0
  44. package/dist/types/index.d.ts +19 -0
  45. package/dist/types/interceptor.d.ts +4 -0
  46. package/dist/types/license.d.ts +23 -0
  47. package/dist/types/lock-screen.d.ts +4 -0
  48. package/dist/types/notification.d.ts +92 -0
  49. package/dist/types/permission.d.ts +10 -0
  50. package/dist/types/request.d.ts +44 -0
  51. package/dist/types/restriction.d.ts +9 -0
  52. package/dist/types/setting.d.ts +58 -0
  53. package/dist/types/storage-trash.d.ts +25 -0
  54. package/dist/types/storage.d.ts +114 -0
  55. package/dist/types/user-log.d.ts +9 -0
  56. package/dist/types/user.d.ts +74 -0
  57. package/package.json +3 -2
@@ -0,0 +1,4 @@
1
+ export declare const applyInterceptors: <T>(interceptors: {
2
+ fulfilled: (arg: T) => T | Promise<T>;
3
+ rejected?: (error: any) => T | Promise<T>;
4
+ }[], arg: T) => Promise<T>;
@@ -0,0 +1 @@
1
+ export declare function getCookieValue(name: string): string | null;
@@ -0,0 +1,4 @@
1
+ export * from './apply-interceptors';
2
+ export * from './get-cookie-value';
3
+ export * from './make-url-params';
4
+ export * from './normalize-headers';
@@ -0,0 +1 @@
1
+ export declare const makeUrlParams: (params: Record<string, any>) => URLSearchParams;
@@ -0,0 +1 @@
1
+ export declare function normalizeHeaders(headers: Headers | [string, string][] | Record<string, string>): Record<string, string>;
@@ -0,0 +1,36 @@
1
+ export declare enum AccessRights {
2
+ LicenseRead = "license_read",// Просмотр
3
+ LicenseManage = "license_edit",// Управление лицензией
4
+ UsersRead = "users_read",// Просмотр
5
+ UsersCreate = "users_create",// Создание/редактирование
6
+ UsersActivate = "users_activate",// Активация/деактивация
7
+ GroupsRead = "groups_read",// Просмотр
8
+ GroupsCreate = "groups_create",// Создание/редактирование
9
+ RolesRead = "roles_read",// Просмотр списка
10
+ RolesCreate = "roles_create",// Создание/редактирование
11
+ Share = "share",// Шаринг доступа по ссылке
12
+ Divide = "divide",// Предоставление доступа
13
+ ExtensionsRead = "extensions_read",// Просмотр
14
+ ExtensionsManage = "extensions_write",// Управление расширениями
15
+ RestrictionShareRead = "restriction_share_read",// Просмотр
16
+ RestrictionShareWrite = "restriction_share_write",// Управление шарингом
17
+ RestrictionDivideRead = "restriction_divide_read",// Просмотр
18
+ RestrictionDivideWrite = "restriction_divide_write",// Управление доступами
19
+ ReadUserLogs = "read_user_logs",// Просмотр пользовательских логов
20
+ ReadSystemLogs = "read_system_logs",// Просмотр системных логов
21
+ ConnectionsRead = "connections_read",// Просмотр
22
+ ConnectionsDividing = "connections_dividing",// Предоставление доступа(поделиться)
23
+ ConnectionsYandexDisk = "connections_yandex_disk",// Yandex диск
24
+ ConnectionsSsh = "connections_ssh",// Ssh
25
+ ConnectionsMail = "connections_mail",// Почта
26
+ ConnectionsS3 = "connections_s3",// S3
27
+ ConnectionsDiscord = "connections_discord",// Discord
28
+ ConnectionsWebdav = "connections_webdav",// Webdav
29
+ ConnectionsNextcloud = "connections_nextcloud",// Nextcloud
30
+ ConnectionsNextbox = "connections_nextbox",// Nextbox
31
+ ConnectionsHttpProxy = "connections_http_proxy",// Http proxy
32
+ SystemInfoServiceList = "system_info_service_list",// Просмотр
33
+ SettingsRead = "settings_read",// Просмотр
34
+ SettingsWrite = "settings_write"
35
+ }
36
+ export declare const CONNECTIONS_PERMISSION: AccessRights[];
@@ -0,0 +1,15 @@
1
+ import { AccessRights } from './access-rights';
2
+ import { UserType } from './user';
3
+ export interface AccessToken {
4
+ exp: number;
5
+ iat: number;
6
+ login: string;
7
+ user_id: number;
8
+ is_remember: boolean;
9
+ with_cookie: boolean;
10
+ grant_access_all: boolean;
11
+ user_type: UserType;
12
+ permissions: {
13
+ [key: string]: AccessRights[];
14
+ };
15
+ }
@@ -0,0 +1,9 @@
1
+ export interface AuthToken {
2
+ access_token: string;
3
+ refresh_token: string;
4
+ }
5
+ export interface AuthType {
6
+ classic: boolean;
7
+ basic: boolean;
8
+ ldap: boolean;
9
+ }
@@ -0,0 +1,48 @@
1
+ import { RequestAuthTokenParams } from '../api';
2
+ import { PermissionType } from './divide';
3
+ export interface NbClientParams {
4
+ host?: string;
5
+ version?: string;
6
+ }
7
+ export interface NbRequestParams {
8
+ path: string;
9
+ headers?: Record<string, any>;
10
+ query?: Record<string, any>;
11
+ body?: any;
12
+ cache?: RequestCache;
13
+ }
14
+ export interface NbAppState {
15
+ clientParams: NbClientParams;
16
+ requestParams: NbRequestParams;
17
+ authToken: Map<number, RequestAuthTokenParams> | null;
18
+ skipInterceptors: boolean;
19
+ }
20
+ export interface ResponseItem<T> {
21
+ row: T;
22
+ }
23
+ export interface ResponseList<T> {
24
+ rows: T[];
25
+ total: number;
26
+ current?: {
27
+ access_mode: PermissionType;
28
+ };
29
+ }
30
+ export interface RequestBaseParams {
31
+ limit: number;
32
+ offset?: number;
33
+ order_by?: string;
34
+ order_direction?: OrderDirection;
35
+ }
36
+ export declare enum OrderDirection {
37
+ DEFAULT = "",
38
+ ASC = "asc",
39
+ DESC = "desc"
40
+ }
41
+ export type Lang = {
42
+ [key: string]: string;
43
+ };
44
+ export declare enum EngineType {
45
+ WebSocket = "websocket",
46
+ PostMessage = "postmessage",
47
+ Empty = ""
48
+ }
@@ -0,0 +1,36 @@
1
+ import { PermissionType } from './divide';
2
+ export interface Connection {
3
+ id: number;
4
+ name: string;
5
+ type: ConnectionType;
6
+ address: string;
7
+ login: string;
8
+ password: string;
9
+ port: number;
10
+ root_path: string;
11
+ group_name: ConnectionGroup;
12
+ owner_id: number;
13
+ divide_id?: number;
14
+ access_mode?: PermissionType;
15
+ update_date: string;
16
+ create_date: string;
17
+ expire_in: string;
18
+ to_user_group_id?: number;
19
+ }
20
+ export declare enum ConnectionGroup {
21
+ Storages = "storages_connections_group",
22
+ Webhooks = "webhooks_connections_group",
23
+ Unknown = "unknown_connections_group",
24
+ Proxy = "proxy_connections_group"
25
+ }
26
+ export declare enum ConnectionType {
27
+ SSH = "ssh_connection",
28
+ YandexDisk = "yandex_disk",
29
+ Mail = "mail",
30
+ Discord = "discord",
31
+ Webdav = "webdav_connection",
32
+ Nextcloud = "nextcloud_connection",
33
+ NextBox = "nextbox_connection",
34
+ HttpProxy = "http_proxy_connection",
35
+ S3 = "s3_connection"
36
+ }
@@ -0,0 +1,15 @@
1
+ export interface Discovery {
2
+ id: number;
3
+ create_date: string;
4
+ update_date: string;
5
+ active: boolean;
6
+ back_url: string;
7
+ front_url: string;
8
+ instance_number: number;
9
+ name: string;
10
+ route: null;
11
+ route_name: string;
12
+ with_swagger: boolean;
13
+ dynamic_config_path?: string;
14
+ version: string;
15
+ }
@@ -0,0 +1,82 @@
1
+ import { ResponseList } from './base';
2
+ import { StorageElement, StorageElementType } from './storage';
3
+ export declare enum DivideScope {
4
+ Storage = "/storage/element",
5
+ Connection = "/connections"
6
+ }
7
+ export type DivideResourceType = string | number;
8
+ export declare enum PermissionType {
9
+ CLOSE = "",
10
+ READ = "r",
11
+ WRITE = "rw"
12
+ }
13
+ export declare enum RestrictionStatus {
14
+ WAITING = "waiting",
15
+ APPROVED = "approved",
16
+ REJECTED = "rejected"
17
+ }
18
+ export declare enum RestrictionBooleanStatus {
19
+ TRUE = "true",
20
+ FALSE = "false"
21
+ }
22
+ export declare enum DivideMode {
23
+ User = "to_user_id",
24
+ Group = "to_user_group_id"
25
+ }
26
+ export interface ShareInfo extends DivideParams {
27
+ id: number;
28
+ token: string;
29
+ access_mode: PermissionType;
30
+ expire_delta: number | null;
31
+ expire_in?: string;
32
+ with_password: boolean;
33
+ share_sub_type: StorageElementType;
34
+ create_date: string;
35
+ update_date: string;
36
+ owner_id: number;
37
+ resource: string;
38
+ file_info: StorageElement;
39
+ short_url: string;
40
+ }
41
+ export interface UnionRestriction extends UserDivide, ShareInfo {
42
+ }
43
+ export interface UserDivide extends DivideParams {
44
+ access_mode: PermissionType;
45
+ create_date: string;
46
+ id: number;
47
+ name: string;
48
+ owner_id: number;
49
+ resource: string;
50
+ to_user_group_id: number;
51
+ to_user_id: number;
52
+ type: StorageElementType;
53
+ update_date: string;
54
+ file_info: StorageElement;
55
+ }
56
+ export declare enum RestrictionModeKey {
57
+ Divide = "divide",
58
+ Share = "share"
59
+ }
60
+ interface DivideParams {
61
+ restriction_status: RestrictionStatus;
62
+ moderator_id?: number;
63
+ comment: string;
64
+ }
65
+ export interface RequestUserDivideParams {
66
+ is_to_user_group: boolean;
67
+ access_mode?: PermissionType;
68
+ limit?: number;
69
+ offset?: number;
70
+ search_field?: string;
71
+ }
72
+ export type DivideResponseList = ResponseList<UserDivide> & {
73
+ total_r: number;
74
+ total_rw: number;
75
+ };
76
+ export interface ShareModel {
77
+ token: string;
78
+ access_mode: PermissionType;
79
+ password: string | null;
80
+ expire_delta: number | null;
81
+ }
82
+ export {};
@@ -0,0 +1,80 @@
1
+ import { EngineType, Lang } from './base';
2
+ import { Setting, SettingValue } from './setting';
3
+ export interface ExtensionDefault {
4
+ ext_value: string;
5
+ extension_meta_uniq_key: string;
6
+ icon_path: string;
7
+ devlocal?: boolean;
8
+ }
9
+ export declare enum ExtensionType {
10
+ App = "app",
11
+ File = "file",
12
+ WorkDir = "work_dir"
13
+ }
14
+ export declare enum ExtensionFileMode {
15
+ Read = "read",
16
+ ReadAndWrite = "read_and_write",
17
+ Write = "write"
18
+ }
19
+ export interface Extension {
20
+ id: number;
21
+ create_date: string;
22
+ update_date: string;
23
+ with_settings?: boolean;
24
+ name: Lang;
25
+ devlocal?: boolean;
26
+ dev_frame_params?: {
27
+ engine: EngineType;
28
+ host?: string;
29
+ port?: number;
30
+ };
31
+ version: string;
32
+ latest_repo_version?: string;
33
+ description: Lang;
34
+ uniq_key: string;
35
+ icon: string;
36
+ type: ExtensionType;
37
+ path: string;
38
+ file?: {
39
+ mode: ExtensionFileMode;
40
+ ext: string[];
41
+ default_ext?: string;
42
+ index: string;
43
+ };
44
+ app?: {
45
+ menu: {
46
+ index: string;
47
+ icon: string;
48
+ label: Lang;
49
+ };
50
+ };
51
+ work_dir?: {
52
+ index: string;
53
+ };
54
+ settings?: SettingValue[];
55
+ settings_template?: Setting[];
56
+ }
57
+ export interface ExtensionMetaPayload {
58
+ uniq_key: string;
59
+ }
60
+ export interface ExtensionExternalInList {
61
+ id: number;
62
+ create_date: string;
63
+ update_date: string;
64
+ name: string;
65
+ description: string;
66
+ uniq_key: string;
67
+ version: string;
68
+ tags: string[];
69
+ links: string[];
70
+ }
71
+ export interface ExtensionExternal extends ExtensionExternalInList {
72
+ versions: VersionExtension[];
73
+ images?: string[];
74
+ with_readme?: boolean;
75
+ }
76
+ interface VersionExtension {
77
+ version: string;
78
+ size: number;
79
+ }
80
+ export {};
@@ -0,0 +1,19 @@
1
+ export * from './access-rights';
2
+ export * from './access-token';
3
+ export * from './auth';
4
+ export * from './base';
5
+ export * from './connection';
6
+ export * from './discovery';
7
+ export * from './extension';
8
+ export * from './divide';
9
+ export * from './license';
10
+ export * from './lock-screen';
11
+ export * from './notification';
12
+ export * from './permission';
13
+ export * from './request';
14
+ export * from './restriction';
15
+ export * from './user';
16
+ export * from './user-log';
17
+ export * from './setting';
18
+ export * from './storage';
19
+ export * from './storage-trash';
@@ -0,0 +1,4 @@
1
+ export type Interceptor<T = any> = {
2
+ fulfilled: (value: T) => T | Promise<T>;
3
+ rejected: (error: any) => any;
4
+ };
@@ -0,0 +1,23 @@
1
+ export interface License {
2
+ custom_max_users_count: number | null;
3
+ expire_in: string;
4
+ key: string | null;
5
+ plan: Tariff;
6
+ error?: LicenseError | string;
7
+ }
8
+ export interface ChangeLicenseParams {
9
+ key: string;
10
+ domain: string;
11
+ }
12
+ export declare enum Tariff {
13
+ Free = "free",
14
+ Business = "business",
15
+ Enterprise = "enterprise"
16
+ }
17
+ export declare enum LicenseError {
18
+ NotActivated = "License not activated",
19
+ Blocked = "License blocked",
20
+ Expired = "License has been expired",
21
+ NotValid = "License not valid",
22
+ NotFound = "license file not found"
23
+ }
@@ -0,0 +1,4 @@
1
+ export interface LockScreen {
2
+ enabled: boolean;
3
+ duration: number;
4
+ }
@@ -0,0 +1,92 @@
1
+ import { PermissionType } from './divide';
2
+ import { StorageElementType } from './storage';
3
+ import { UserLabel } from './user';
4
+ export interface UserNotification {
5
+ id: number;
6
+ create_date: string;
7
+ update_date: string;
8
+ entity_type: NotificationEntityType;
9
+ action: NotificationAction;
10
+ title: string;
11
+ msg: string;
12
+ transition: boolean;
13
+ read: boolean;
14
+ style: NotificationStyle;
15
+ payload: NotificationPayload;
16
+ from_user_id?: number;
17
+ owner?: UserLabel;
18
+ }
19
+ export declare enum NotificationEntityType {
20
+ Dir = "dir",
21
+ File = "file",
22
+ User = "user",
23
+ Other = "other",
24
+ WorkDir = "work_dir",
25
+ License = "license",
26
+ Extension = "extension",
27
+ Connection = "connection"
28
+ }
29
+ export declare enum NotificationAction {
30
+ SecurityCheckNegative = "action_security_check_negative",
31
+ SecurityCheckPositive = "action_security_check_positive",
32
+ OpenSharing = "open_sharing",
33
+ ChangeSharing = "change_sharing",
34
+ CancelSharing = "cancel_sharing",
35
+ DivideDirAddFileToOwner = "divide_dir_add_file_to_owner",
36
+ DivideDirAddDirToOwner = "divide_dir_add_dir_to_owner",
37
+ DivideDirAddWorkDirToOwner = "divide_dir_add_work_dir_to_owner",
38
+ DivideConnectionAddFileToOwner = "divide_connection_add_file_to_owner",
39
+ DivideConnectionAddDirToOwner = "divide_connection_add_dir_to_owner",
40
+ CancelDivideDir = "cancel_divide_dir",
41
+ CancelDivideFile = "cancel_divide_file",
42
+ CancelDivideWorkDir = "cancel_divide_work_dir",
43
+ CancelDivideConnection = "cancel_divide_connection",
44
+ DeleteExtension = "delete_extension",
45
+ NewVersionExtension = "new_version_extension",
46
+ TransferData = "transfer_data",
47
+ AllowInternalAccessUser = "allow_internal_access_to_user",
48
+ BlockInternalAccessUser = "block_internal_access_to_user",
49
+ WaitInternalAccessUser = "wait_internal_access_to_user",
50
+ WaitInternalAccessUserCreate = "wait_internal_access_to_user_create",
51
+ AllowInternalAccessGroup = "allow_internal_access_to_group",
52
+ BlockInternalAccessGroup = "block_internal_access_to_group",
53
+ WaitInternalAccessGroup = "wait_internal_access_to_group",
54
+ WaitInternalAccessGroupCreate = "wait_internal_access_to_group_create",
55
+ AllowSharing = "allow_sharing",
56
+ BlockSharing = "block_sharing",
57
+ WaitSharing = "wait_sharing",
58
+ WaitSharingCreate = "wait_sharing_create",
59
+ Other = "other"
60
+ }
61
+ export declare enum NotificationRowAction {
62
+ Read = "read",
63
+ Unread = "unread",
64
+ Delete = "delete"
65
+ }
66
+ export declare enum NotificationStyle {
67
+ Plain = "plain",
68
+ Success = "success",
69
+ Info = "info",
70
+ Warning = "warning",
71
+ Error = "error"
72
+ }
73
+ export type NotificationActionGroup = {
74
+ [key: string]: NotificationActionEnabledGroup;
75
+ };
76
+ interface NotificationActionEnabledGroup {
77
+ enabled_system: boolean;
78
+ enabled_mail: boolean;
79
+ }
80
+ export type NotificationPayload = PayloadFile | any;
81
+ export interface PayloadFile {
82
+ access_mode: PermissionType;
83
+ create_date: string;
84
+ id: number;
85
+ name: string;
86
+ owner_id: number;
87
+ path: string;
88
+ to_user_id: number;
89
+ type: StorageElementType;
90
+ update_date: string;
91
+ }
92
+ export {};
@@ -0,0 +1,10 @@
1
+ import { Lang } from './base';
2
+ export interface Permission {
3
+ group_name: Lang;
4
+ permissions: PermissionItem[];
5
+ }
6
+ export interface PermissionItem {
7
+ id: number;
8
+ priority: number;
9
+ title: Lang;
10
+ }
@@ -0,0 +1,44 @@
1
+ export declare enum ResponseType {
2
+ ArrayBuffer = "arraybuffer",
3
+ Blob = "blob",
4
+ Json = "json",
5
+ Text = "text"
6
+ }
7
+ export declare enum RequestMethod {
8
+ GET = "GET",
9
+ POST = "POST",
10
+ PUT = "PUT",
11
+ PATCH = "PATCH",
12
+ DELETE = "DELETE"
13
+ }
14
+ export declare enum RequestObserve {
15
+ Body = "body",
16
+ Response = "response"
17
+ }
18
+ export interface HttpResponse<T> {
19
+ status: number;
20
+ statusText: string;
21
+ headers: Headers;
22
+ body: T;
23
+ }
24
+ export interface HttpEvent<T> {
25
+ loaded?: number;
26
+ total?: number;
27
+ body?: HttpResponse<T>;
28
+ error?: any;
29
+ }
30
+ export interface RequestConfig {
31
+ params?: Record<string, string>;
32
+ body?: any;
33
+ cache?: RequestCache;
34
+ headers?: HeadersInit;
35
+ observe?: RequestObserve;
36
+ responseType?: ResponseType;
37
+ signal?: AbortSignal | null;
38
+ onUploadProgress?: OnUploadProgress;
39
+ }
40
+ export interface ProgressEvent {
41
+ loaded: number;
42
+ total: number;
43
+ }
44
+ export type OnUploadProgress = (progressEvent: ProgressEvent) => void;
@@ -0,0 +1,9 @@
1
+ export declare enum RestrictionSharing {
2
+ NONE = "none",
3
+ SOFT = "soft",
4
+ HARD = "hard"
5
+ }
6
+ export interface Restriction {
7
+ sharing: RestrictionSharing;
8
+ divide: RestrictionSharing;
9
+ }
@@ -0,0 +1,58 @@
1
+ import { Lang } from './base';
2
+ export type SettingLang = string | Lang | null;
3
+ export declare enum SettingControlType {
4
+ Text = "text",
5
+ String = "string",
6
+ Number = "number",
7
+ CheckBox = "checkbox",
8
+ Select = "select",
9
+ RadioList = "radio_list",
10
+ ConnectionChoose = "connection_choose",
11
+ MultiConnectionChoose = "multi_connection_choose"
12
+ }
13
+ export interface Setting {
14
+ fields: SettingField[];
15
+ title?: SettingLang;
16
+ name?: string;
17
+ context?: string;
18
+ toggle_box?: boolean;
19
+ collapsed_box?: boolean;
20
+ activity_switch?: boolean;
21
+ }
22
+ export interface SettingVariant {
23
+ label?: SettingLang;
24
+ value: any;
25
+ }
26
+ export interface SettingField {
27
+ name: string;
28
+ value: any;
29
+ label?: SettingLang;
30
+ help?: SettingLang;
31
+ placeholder?: SettingLang;
32
+ view?: SettingFieldView;
33
+ disabled?: boolean;
34
+ control: {
35
+ type: SettingControlType;
36
+ filter?: Record<string, any>;
37
+ variants?: SettingVariant[];
38
+ };
39
+ }
40
+ export type SettingFieldView = SettingViewConnectionChoose | SettingViewSelect | any;
41
+ export interface SettingViewConnectionChoose {
42
+ id: number;
43
+ name: string;
44
+ owner_id: number;
45
+ }
46
+ export interface SettingViewSelect {
47
+ show_clear?: boolean;
48
+ }
49
+ export interface SettingValueField {
50
+ name: string;
51
+ value: any;
52
+ }
53
+ export interface SettingValue {
54
+ name: string;
55
+ context?: string;
56
+ fields: SettingValueField[];
57
+ activity_switch?: boolean;
58
+ }
@@ -0,0 +1,25 @@
1
+ import { StorageElementContentType, StorageElementType } from './storage';
2
+ export interface StorageTrashElement {
3
+ content_type: StorageElementContentType;
4
+ del_group_id: number;
5
+ file_name_ext: string;
6
+ full_path: string;
7
+ name: string;
8
+ path: string;
9
+ size: number;
10
+ type: StorageElementType;
11
+ update_date: string;
12
+ version: VersionStorageTrashElement;
13
+ with_preview: boolean;
14
+ }
15
+ interface VersionStorageTrashElement {
16
+ create_date: string;
17
+ description: string;
18
+ id: string;
19
+ name: string | null;
20
+ size: number;
21
+ update_date: string;
22
+ user_id: number;
23
+ }
24
+ export type StorageTrashItem = Pick<StorageTrashElement, 'del_group_id' | 'path'>;
25
+ export {};