@haex-space/vault-sdk 2.5.68 → 2.5.71
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/{client-C_0ajqhQ.d.ts → client-CrTdKfuP.d.ts} +2 -2
- package/dist/{client-DTXGxFqD.d.mts → client-DvW2oZYC.d.mts} +2 -2
- package/dist/index.d.mts +33 -37
- package/dist/index.d.ts +33 -37
- package/dist/index.js +35 -31
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +35 -31
- package/dist/index.mjs.map +1 -1
- package/dist/react.d.mts +1 -1
- package/dist/react.d.ts +1 -1
- package/dist/react.js +24 -18
- package/dist/react.js.map +1 -1
- package/dist/react.mjs +24 -18
- package/dist/react.mjs.map +1 -1
- package/dist/runtime/nuxt.plugin.client.d.mts +1 -1
- package/dist/runtime/nuxt.plugin.client.d.ts +1 -1
- package/dist/runtime/nuxt.plugin.client.js +24 -18
- package/dist/runtime/nuxt.plugin.client.js.map +1 -1
- package/dist/runtime/nuxt.plugin.client.mjs +24 -18
- package/dist/runtime/nuxt.plugin.client.mjs.map +1 -1
- package/dist/svelte.d.mts +1 -1
- package/dist/svelte.d.ts +1 -1
- package/dist/svelte.js +24 -18
- package/dist/svelte.js.map +1 -1
- package/dist/svelte.mjs +24 -18
- package/dist/svelte.mjs.map +1 -1
- package/dist/vue.d.mts +1 -1
- package/dist/vue.d.ts +1 -1
- package/dist/vue.js +24 -18
- package/dist/vue.js.map +1 -1
- package/dist/vue.mjs +24 -18
- package/dist/vue.mjs.map +1 -1
- package/package.json +1 -1
|
@@ -445,14 +445,14 @@ declare class BackendManagement {
|
|
|
445
445
|
* @param request - Backend configuration
|
|
446
446
|
* @returns Created backend info
|
|
447
447
|
*/
|
|
448
|
-
add(
|
|
448
|
+
add(backendRequest: AddBackendRequest): Promise<StorageBackendInfo>;
|
|
449
449
|
/**
|
|
450
450
|
* Update a storage backend
|
|
451
451
|
* Only provided fields are updated. Credentials are preserved if not provided.
|
|
452
452
|
* @param request - Update request with backendId and fields to update
|
|
453
453
|
* @returns Updated backend info
|
|
454
454
|
*/
|
|
455
|
-
update(
|
|
455
|
+
update(updateRequest: UpdateBackendRequest): Promise<StorageBackendInfo>;
|
|
456
456
|
/**
|
|
457
457
|
* Remove a storage backend
|
|
458
458
|
* @param backendId - Backend ID to remove
|
|
@@ -445,14 +445,14 @@ declare class BackendManagement {
|
|
|
445
445
|
* @param request - Backend configuration
|
|
446
446
|
* @returns Created backend info
|
|
447
447
|
*/
|
|
448
|
-
add(
|
|
448
|
+
add(backendRequest: AddBackendRequest): Promise<StorageBackendInfo>;
|
|
449
449
|
/**
|
|
450
450
|
* Update a storage backend
|
|
451
451
|
* Only provided fields are updated. Credentials are preserved if not provided.
|
|
452
452
|
* @param request - Update request with backendId and fields to update
|
|
453
453
|
* @returns Updated backend info
|
|
454
454
|
*/
|
|
455
|
-
update(
|
|
455
|
+
update(updateRequest: UpdateBackendRequest): Promise<StorageBackendInfo>;
|
|
456
456
|
/**
|
|
457
457
|
* Remove a storage backend
|
|
458
458
|
* @param backendId - Backend ID to remove
|
package/dist/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { H as HaexVaultSdk } from './client-
|
|
2
|
-
export { D as DatabaseAPI, b as DirEntry, a as FileStat, F as FilesystemAPI, P as PermissionsAPI, A as RemoteAddBackendRequest, f as RemoteS3Config, g as RemoteS3PublicConfig, R as RemoteStorageAPI, e as RemoteStorageBackendInfo, h as RemoteStorageObjectInfo, U as RemoteUpdateBackendRequest, d as SelectFileOptions, c as SelectFolderOptions, W as WebAPI } from './client-
|
|
1
|
+
import { H as HaexVaultSdk } from './client-DvW2oZYC.mjs';
|
|
2
|
+
export { D as DatabaseAPI, b as DirEntry, a as FileStat, F as FilesystemAPI, P as PermissionsAPI, A as RemoteAddBackendRequest, f as RemoteS3Config, g as RemoteS3PublicConfig, R as RemoteStorageAPI, e as RemoteStorageBackendInfo, h as RemoteStorageObjectInfo, U as RemoteUpdateBackendRequest, d as SelectFileOptions, c as SelectFolderOptions, W as WebAPI } from './client-DvW2oZYC.mjs';
|
|
3
3
|
import { E as ExtensionManifest, H as HaexHubConfig } from './types-DiXJ5SF6.mjs';
|
|
4
4
|
export { A as ApplicationContext, t as AuthorizedClient, B as BlockedClient, C as ContextChangedEvent, F as DEFAULT_TIMEOUT, o as DatabaseColumnInfo, m as DatabaseExecuteParams, k as DatabasePermission, d as DatabasePermissionRequest, l as DatabaseQueryParams, D as DatabaseQueryResult, n as DatabaseTableInfo, U as EXTERNAL_EVENTS, z as ErrorCode, g as EventCallback, a as ExtensionInfo, v as ExternalAuthDecision, x as ExternalConnection, J as ExternalConnectionErrorCode, I as ExternalConnectionState, V as ExternalEvent, s as ExternalRequest, r as ExternalRequestEvent, e as ExternalRequestHandler, f as ExternalResponse, O as HAEXTENSION_EVENTS, j as HaexHubEvent, h as HaexHubRequest, i as HaexHubResponse, N as HaexVaultSdkError, Q as HaextensionEvent, u as PendingAuthorization, P as PermissionResponse, y as PermissionStatus, R as RequestedExtension, p as SearchQuery, q as SearchRequestEvent, S as SearchResult, w as SessionAuthorization, T as TABLE_SEPARATOR, W as WebRequestOptions, c as WebResponse, L as canExternalClientSendRequests, G as getTableName, K as isExternalClientConnected } from './types-DiXJ5SF6.mjs';
|
|
5
5
|
export { H as HaextensionConfig } from './config-D_HXjsEV.mjs';
|
|
@@ -223,41 +223,37 @@ declare const FILESYSTEM_COMMANDS: {
|
|
|
223
223
|
*
|
|
224
224
|
* Commands for the external bridge (browser extension communication).
|
|
225
225
|
*
|
|
226
|
-
*
|
|
227
|
-
* - `webview_extension_external_` - WebView-specific (respond to requests)
|
|
228
|
-
* - `external_` - Bridge management commands
|
|
229
|
-
*
|
|
230
|
-
* TODO: Migrate all to `extension_external_bridge_` prefix for consistency.
|
|
226
|
+
* Naming convention: `external_bridge_<action>`
|
|
231
227
|
*/
|
|
232
228
|
declare const EXTERNAL_BRIDGE_COMMANDS: {
|
|
233
229
|
/** Respond to an external request */
|
|
234
|
-
readonly respond: "
|
|
230
|
+
readonly respond: "external_bridge_respond";
|
|
235
231
|
/** Start the external bridge server */
|
|
236
|
-
readonly
|
|
232
|
+
readonly start: "external_bridge_start";
|
|
237
233
|
/** Stop the external bridge server */
|
|
238
|
-
readonly
|
|
234
|
+
readonly stop: "external_bridge_stop";
|
|
239
235
|
/** Get bridge server status */
|
|
240
|
-
readonly
|
|
236
|
+
readonly getStatus: "external_bridge_get_status";
|
|
241
237
|
/** Allow a client connection */
|
|
242
|
-
readonly clientAllow: "
|
|
238
|
+
readonly clientAllow: "external_bridge_client_allow";
|
|
243
239
|
/** Block a client connection */
|
|
244
|
-
readonly clientBlock: "
|
|
240
|
+
readonly clientBlock: "external_bridge_client_block";
|
|
245
241
|
/** Get list of authorized clients */
|
|
246
|
-
readonly getAuthorizedClients: "
|
|
242
|
+
readonly getAuthorizedClients: "external_bridge_get_authorized_clients";
|
|
247
243
|
/** Revoke client authorization */
|
|
248
|
-
readonly revokeClient: "
|
|
244
|
+
readonly revokeClient: "external_bridge_revoke_client";
|
|
249
245
|
/** Get session authorizations */
|
|
250
|
-
readonly getSessionAuthorizations: "
|
|
246
|
+
readonly getSessionAuthorizations: "external_bridge_get_session_authorizations";
|
|
251
247
|
/** Revoke session authorization */
|
|
252
|
-
readonly revokeSessionAuthorization: "
|
|
248
|
+
readonly revokeSessionAuthorization: "external_bridge_revoke_session_authorization";
|
|
253
249
|
/** Get list of blocked clients */
|
|
254
|
-
readonly getBlockedClients: "
|
|
250
|
+
readonly getBlockedClients: "external_bridge_get_blocked_clients";
|
|
255
251
|
/** Unblock a client */
|
|
256
|
-
readonly unblockClient: "
|
|
252
|
+
readonly unblockClient: "external_bridge_unblock_client";
|
|
257
253
|
/** Check if client is blocked */
|
|
258
|
-
readonly isClientBlocked: "
|
|
254
|
+
readonly isClientBlocked: "external_bridge_is_client_blocked";
|
|
259
255
|
/** Get pending authorization requests */
|
|
260
|
-
readonly getPendingAuthorizations: "
|
|
256
|
+
readonly getPendingAuthorizations: "external_bridge_get_pending_authorizations";
|
|
261
257
|
};
|
|
262
258
|
|
|
263
259
|
/**
|
|
@@ -274,7 +270,7 @@ declare const EXTENSION_COMMANDS: {
|
|
|
274
270
|
/** Get extension info (manifest, id, etc.) */
|
|
275
271
|
readonly getInfo: "extension_get_info";
|
|
276
272
|
/** Get application context (theme, locale, etc.) */
|
|
277
|
-
readonly getContext: "
|
|
273
|
+
readonly getContext: "extension_context_get";
|
|
278
274
|
};
|
|
279
275
|
|
|
280
276
|
/**
|
|
@@ -368,24 +364,24 @@ declare const TAURI_COMMANDS: {
|
|
|
368
364
|
readonly copy: "extension_filesystem_copy";
|
|
369
365
|
};
|
|
370
366
|
readonly externalBridge: {
|
|
371
|
-
readonly respond: "
|
|
372
|
-
readonly
|
|
373
|
-
readonly
|
|
374
|
-
readonly
|
|
375
|
-
readonly clientAllow: "
|
|
376
|
-
readonly clientBlock: "
|
|
377
|
-
readonly getAuthorizedClients: "
|
|
378
|
-
readonly revokeClient: "
|
|
379
|
-
readonly getSessionAuthorizations: "
|
|
380
|
-
readonly revokeSessionAuthorization: "
|
|
381
|
-
readonly getBlockedClients: "
|
|
382
|
-
readonly unblockClient: "
|
|
383
|
-
readonly isClientBlocked: "
|
|
384
|
-
readonly getPendingAuthorizations: "
|
|
367
|
+
readonly respond: "external_bridge_respond";
|
|
368
|
+
readonly start: "external_bridge_start";
|
|
369
|
+
readonly stop: "external_bridge_stop";
|
|
370
|
+
readonly getStatus: "external_bridge_get_status";
|
|
371
|
+
readonly clientAllow: "external_bridge_client_allow";
|
|
372
|
+
readonly clientBlock: "external_bridge_client_block";
|
|
373
|
+
readonly getAuthorizedClients: "external_bridge_get_authorized_clients";
|
|
374
|
+
readonly revokeClient: "external_bridge_revoke_client";
|
|
375
|
+
readonly getSessionAuthorizations: "external_bridge_get_session_authorizations";
|
|
376
|
+
readonly revokeSessionAuthorization: "external_bridge_revoke_session_authorization";
|
|
377
|
+
readonly getBlockedClients: "external_bridge_get_blocked_clients";
|
|
378
|
+
readonly unblockClient: "external_bridge_unblock_client";
|
|
379
|
+
readonly isClientBlocked: "external_bridge_is_client_blocked";
|
|
380
|
+
readonly getPendingAuthorizations: "external_bridge_get_pending_authorizations";
|
|
385
381
|
};
|
|
386
382
|
readonly extension: {
|
|
387
383
|
readonly getInfo: "extension_get_info";
|
|
388
|
-
readonly getContext: "
|
|
384
|
+
readonly getContext: "extension_context_get";
|
|
389
385
|
};
|
|
390
386
|
readonly remoteStorage: {
|
|
391
387
|
readonly listBackends: "extension_remote_storage_list_backends";
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { H as HaexVaultSdk } from './client-
|
|
2
|
-
export { D as DatabaseAPI, b as DirEntry, a as FileStat, F as FilesystemAPI, P as PermissionsAPI, A as RemoteAddBackendRequest, f as RemoteS3Config, g as RemoteS3PublicConfig, R as RemoteStorageAPI, e as RemoteStorageBackendInfo, h as RemoteStorageObjectInfo, U as RemoteUpdateBackendRequest, d as SelectFileOptions, c as SelectFolderOptions, W as WebAPI } from './client-
|
|
1
|
+
import { H as HaexVaultSdk } from './client-CrTdKfuP.js';
|
|
2
|
+
export { D as DatabaseAPI, b as DirEntry, a as FileStat, F as FilesystemAPI, P as PermissionsAPI, A as RemoteAddBackendRequest, f as RemoteS3Config, g as RemoteS3PublicConfig, R as RemoteStorageAPI, e as RemoteStorageBackendInfo, h as RemoteStorageObjectInfo, U as RemoteUpdateBackendRequest, d as SelectFileOptions, c as SelectFolderOptions, W as WebAPI } from './client-CrTdKfuP.js';
|
|
3
3
|
import { E as ExtensionManifest, H as HaexHubConfig } from './types-DiXJ5SF6.js';
|
|
4
4
|
export { A as ApplicationContext, t as AuthorizedClient, B as BlockedClient, C as ContextChangedEvent, F as DEFAULT_TIMEOUT, o as DatabaseColumnInfo, m as DatabaseExecuteParams, k as DatabasePermission, d as DatabasePermissionRequest, l as DatabaseQueryParams, D as DatabaseQueryResult, n as DatabaseTableInfo, U as EXTERNAL_EVENTS, z as ErrorCode, g as EventCallback, a as ExtensionInfo, v as ExternalAuthDecision, x as ExternalConnection, J as ExternalConnectionErrorCode, I as ExternalConnectionState, V as ExternalEvent, s as ExternalRequest, r as ExternalRequestEvent, e as ExternalRequestHandler, f as ExternalResponse, O as HAEXTENSION_EVENTS, j as HaexHubEvent, h as HaexHubRequest, i as HaexHubResponse, N as HaexVaultSdkError, Q as HaextensionEvent, u as PendingAuthorization, P as PermissionResponse, y as PermissionStatus, R as RequestedExtension, p as SearchQuery, q as SearchRequestEvent, S as SearchResult, w as SessionAuthorization, T as TABLE_SEPARATOR, W as WebRequestOptions, c as WebResponse, L as canExternalClientSendRequests, G as getTableName, K as isExternalClientConnected } from './types-DiXJ5SF6.js';
|
|
5
5
|
export { H as HaextensionConfig } from './config-D_HXjsEV.js';
|
|
@@ -223,41 +223,37 @@ declare const FILESYSTEM_COMMANDS: {
|
|
|
223
223
|
*
|
|
224
224
|
* Commands for the external bridge (browser extension communication).
|
|
225
225
|
*
|
|
226
|
-
*
|
|
227
|
-
* - `webview_extension_external_` - WebView-specific (respond to requests)
|
|
228
|
-
* - `external_` - Bridge management commands
|
|
229
|
-
*
|
|
230
|
-
* TODO: Migrate all to `extension_external_bridge_` prefix for consistency.
|
|
226
|
+
* Naming convention: `external_bridge_<action>`
|
|
231
227
|
*/
|
|
232
228
|
declare const EXTERNAL_BRIDGE_COMMANDS: {
|
|
233
229
|
/** Respond to an external request */
|
|
234
|
-
readonly respond: "
|
|
230
|
+
readonly respond: "external_bridge_respond";
|
|
235
231
|
/** Start the external bridge server */
|
|
236
|
-
readonly
|
|
232
|
+
readonly start: "external_bridge_start";
|
|
237
233
|
/** Stop the external bridge server */
|
|
238
|
-
readonly
|
|
234
|
+
readonly stop: "external_bridge_stop";
|
|
239
235
|
/** Get bridge server status */
|
|
240
|
-
readonly
|
|
236
|
+
readonly getStatus: "external_bridge_get_status";
|
|
241
237
|
/** Allow a client connection */
|
|
242
|
-
readonly clientAllow: "
|
|
238
|
+
readonly clientAllow: "external_bridge_client_allow";
|
|
243
239
|
/** Block a client connection */
|
|
244
|
-
readonly clientBlock: "
|
|
240
|
+
readonly clientBlock: "external_bridge_client_block";
|
|
245
241
|
/** Get list of authorized clients */
|
|
246
|
-
readonly getAuthorizedClients: "
|
|
242
|
+
readonly getAuthorizedClients: "external_bridge_get_authorized_clients";
|
|
247
243
|
/** Revoke client authorization */
|
|
248
|
-
readonly revokeClient: "
|
|
244
|
+
readonly revokeClient: "external_bridge_revoke_client";
|
|
249
245
|
/** Get session authorizations */
|
|
250
|
-
readonly getSessionAuthorizations: "
|
|
246
|
+
readonly getSessionAuthorizations: "external_bridge_get_session_authorizations";
|
|
251
247
|
/** Revoke session authorization */
|
|
252
|
-
readonly revokeSessionAuthorization: "
|
|
248
|
+
readonly revokeSessionAuthorization: "external_bridge_revoke_session_authorization";
|
|
253
249
|
/** Get list of blocked clients */
|
|
254
|
-
readonly getBlockedClients: "
|
|
250
|
+
readonly getBlockedClients: "external_bridge_get_blocked_clients";
|
|
255
251
|
/** Unblock a client */
|
|
256
|
-
readonly unblockClient: "
|
|
252
|
+
readonly unblockClient: "external_bridge_unblock_client";
|
|
257
253
|
/** Check if client is blocked */
|
|
258
|
-
readonly isClientBlocked: "
|
|
254
|
+
readonly isClientBlocked: "external_bridge_is_client_blocked";
|
|
259
255
|
/** Get pending authorization requests */
|
|
260
|
-
readonly getPendingAuthorizations: "
|
|
256
|
+
readonly getPendingAuthorizations: "external_bridge_get_pending_authorizations";
|
|
261
257
|
};
|
|
262
258
|
|
|
263
259
|
/**
|
|
@@ -274,7 +270,7 @@ declare const EXTENSION_COMMANDS: {
|
|
|
274
270
|
/** Get extension info (manifest, id, etc.) */
|
|
275
271
|
readonly getInfo: "extension_get_info";
|
|
276
272
|
/** Get application context (theme, locale, etc.) */
|
|
277
|
-
readonly getContext: "
|
|
273
|
+
readonly getContext: "extension_context_get";
|
|
278
274
|
};
|
|
279
275
|
|
|
280
276
|
/**
|
|
@@ -368,24 +364,24 @@ declare const TAURI_COMMANDS: {
|
|
|
368
364
|
readonly copy: "extension_filesystem_copy";
|
|
369
365
|
};
|
|
370
366
|
readonly externalBridge: {
|
|
371
|
-
readonly respond: "
|
|
372
|
-
readonly
|
|
373
|
-
readonly
|
|
374
|
-
readonly
|
|
375
|
-
readonly clientAllow: "
|
|
376
|
-
readonly clientBlock: "
|
|
377
|
-
readonly getAuthorizedClients: "
|
|
378
|
-
readonly revokeClient: "
|
|
379
|
-
readonly getSessionAuthorizations: "
|
|
380
|
-
readonly revokeSessionAuthorization: "
|
|
381
|
-
readonly getBlockedClients: "
|
|
382
|
-
readonly unblockClient: "
|
|
383
|
-
readonly isClientBlocked: "
|
|
384
|
-
readonly getPendingAuthorizations: "
|
|
367
|
+
readonly respond: "external_bridge_respond";
|
|
368
|
+
readonly start: "external_bridge_start";
|
|
369
|
+
readonly stop: "external_bridge_stop";
|
|
370
|
+
readonly getStatus: "external_bridge_get_status";
|
|
371
|
+
readonly clientAllow: "external_bridge_client_allow";
|
|
372
|
+
readonly clientBlock: "external_bridge_client_block";
|
|
373
|
+
readonly getAuthorizedClients: "external_bridge_get_authorized_clients";
|
|
374
|
+
readonly revokeClient: "external_bridge_revoke_client";
|
|
375
|
+
readonly getSessionAuthorizations: "external_bridge_get_session_authorizations";
|
|
376
|
+
readonly revokeSessionAuthorization: "external_bridge_revoke_session_authorization";
|
|
377
|
+
readonly getBlockedClients: "external_bridge_get_blocked_clients";
|
|
378
|
+
readonly unblockClient: "external_bridge_unblock_client";
|
|
379
|
+
readonly isClientBlocked: "external_bridge_is_client_blocked";
|
|
380
|
+
readonly getPendingAuthorizations: "external_bridge_get_pending_authorizations";
|
|
385
381
|
};
|
|
386
382
|
readonly extension: {
|
|
387
383
|
readonly getInfo: "extension_get_info";
|
|
388
|
-
readonly getContext: "
|
|
384
|
+
readonly getContext: "extension_context_get";
|
|
389
385
|
};
|
|
390
386
|
readonly remoteStorage: {
|
|
391
387
|
readonly listBackends: "extension_remote_storage_list_backends";
|
package/dist/index.js
CHANGED
|
@@ -553,41 +553,41 @@ var FILESYSTEM_COMMANDS = {
|
|
|
553
553
|
|
|
554
554
|
// src/commands/externalBridge.ts
|
|
555
555
|
var EXTERNAL_BRIDGE_COMMANDS = {
|
|
556
|
-
// Response handling (called by extensions
|
|
556
|
+
// Response handling (called by extensions)
|
|
557
557
|
/** Respond to an external request */
|
|
558
|
-
respond: "
|
|
558
|
+
respond: "external_bridge_respond",
|
|
559
559
|
// Bridge server management
|
|
560
560
|
/** Start the external bridge server */
|
|
561
|
-
|
|
561
|
+
start: "external_bridge_start",
|
|
562
562
|
/** Stop the external bridge server */
|
|
563
|
-
|
|
563
|
+
stop: "external_bridge_stop",
|
|
564
564
|
/** Get bridge server status */
|
|
565
|
-
|
|
565
|
+
getStatus: "external_bridge_get_status",
|
|
566
566
|
// Client authorization (unified API with remember flag)
|
|
567
567
|
/** Allow a client connection */
|
|
568
|
-
clientAllow: "
|
|
568
|
+
clientAllow: "external_bridge_client_allow",
|
|
569
569
|
/** Block a client connection */
|
|
570
|
-
clientBlock: "
|
|
570
|
+
clientBlock: "external_bridge_client_block",
|
|
571
571
|
// Authorized clients management (permanent - stored in database)
|
|
572
572
|
/** Get list of authorized clients */
|
|
573
|
-
getAuthorizedClients: "
|
|
573
|
+
getAuthorizedClients: "external_bridge_get_authorized_clients",
|
|
574
574
|
/** Revoke client authorization */
|
|
575
|
-
revokeClient: "
|
|
575
|
+
revokeClient: "external_bridge_revoke_client",
|
|
576
576
|
// Session-based authorizations (temporary - cleared when haex-vault restarts)
|
|
577
577
|
/** Get session authorizations */
|
|
578
|
-
getSessionAuthorizations: "
|
|
578
|
+
getSessionAuthorizations: "external_bridge_get_session_authorizations",
|
|
579
579
|
/** Revoke session authorization */
|
|
580
|
-
revokeSessionAuthorization: "
|
|
580
|
+
revokeSessionAuthorization: "external_bridge_revoke_session_authorization",
|
|
581
581
|
// Blocked clients management
|
|
582
582
|
/** Get list of blocked clients */
|
|
583
|
-
getBlockedClients: "
|
|
583
|
+
getBlockedClients: "external_bridge_get_blocked_clients",
|
|
584
584
|
/** Unblock a client */
|
|
585
|
-
unblockClient: "
|
|
585
|
+
unblockClient: "external_bridge_unblock_client",
|
|
586
586
|
/** Check if client is blocked */
|
|
587
|
-
isClientBlocked: "
|
|
587
|
+
isClientBlocked: "external_bridge_is_client_blocked",
|
|
588
588
|
// Pending authorizations
|
|
589
589
|
/** Get pending authorization requests */
|
|
590
|
-
getPendingAuthorizations: "
|
|
590
|
+
getPendingAuthorizations: "external_bridge_get_pending_authorizations"
|
|
591
591
|
};
|
|
592
592
|
|
|
593
593
|
// src/commands/extension.ts
|
|
@@ -595,7 +595,7 @@ var EXTENSION_COMMANDS = {
|
|
|
595
595
|
/** Get extension info (manifest, id, etc.) */
|
|
596
596
|
getInfo: "extension_get_info",
|
|
597
597
|
/** Get application context (theme, locale, etc.) */
|
|
598
|
-
getContext: "
|
|
598
|
+
getContext: "extension_context_get"
|
|
599
599
|
};
|
|
600
600
|
|
|
601
601
|
// src/commands/remoteStorage.ts
|
|
@@ -1332,9 +1332,11 @@ var RemoteStorageAPI = class {
|
|
|
1332
1332
|
async upload(backendId, key, data) {
|
|
1333
1333
|
const base64 = arrayBufferToBase64(data);
|
|
1334
1334
|
await this.client.request(REMOTE_STORAGE_COMMANDS.upload, {
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1335
|
+
request: {
|
|
1336
|
+
backendId,
|
|
1337
|
+
key,
|
|
1338
|
+
data: base64
|
|
1339
|
+
}
|
|
1338
1340
|
});
|
|
1339
1341
|
}
|
|
1340
1342
|
/**
|
|
@@ -1346,7 +1348,7 @@ var RemoteStorageAPI = class {
|
|
|
1346
1348
|
async download(backendId, key) {
|
|
1347
1349
|
const base64 = await this.client.request(
|
|
1348
1350
|
REMOTE_STORAGE_COMMANDS.download,
|
|
1349
|
-
{ backendId, key }
|
|
1351
|
+
{ request: { backendId, key } }
|
|
1350
1352
|
);
|
|
1351
1353
|
return base64ToArrayBuffer(base64);
|
|
1352
1354
|
}
|
|
@@ -1357,8 +1359,10 @@ var RemoteStorageAPI = class {
|
|
|
1357
1359
|
*/
|
|
1358
1360
|
async delete(backendId, key) {
|
|
1359
1361
|
await this.client.request(REMOTE_STORAGE_COMMANDS.delete, {
|
|
1360
|
-
|
|
1361
|
-
|
|
1362
|
+
request: {
|
|
1363
|
+
backendId,
|
|
1364
|
+
key
|
|
1365
|
+
}
|
|
1362
1366
|
});
|
|
1363
1367
|
}
|
|
1364
1368
|
/**
|
|
@@ -1370,7 +1374,7 @@ var RemoteStorageAPI = class {
|
|
|
1370
1374
|
async list(backendId, prefix) {
|
|
1371
1375
|
return this.client.request(
|
|
1372
1376
|
REMOTE_STORAGE_COMMANDS.list,
|
|
1373
|
-
{ backendId, prefix }
|
|
1377
|
+
{ request: { backendId, prefix } }
|
|
1374
1378
|
);
|
|
1375
1379
|
}
|
|
1376
1380
|
};
|
|
@@ -1391,10 +1395,10 @@ var BackendManagement = class {
|
|
|
1391
1395
|
* @param request - Backend configuration
|
|
1392
1396
|
* @returns Created backend info
|
|
1393
1397
|
*/
|
|
1394
|
-
async add(
|
|
1398
|
+
async add(backendRequest) {
|
|
1395
1399
|
return this.client.request(
|
|
1396
1400
|
REMOTE_STORAGE_COMMANDS.addBackend,
|
|
1397
|
-
request
|
|
1401
|
+
{ request: backendRequest }
|
|
1398
1402
|
);
|
|
1399
1403
|
}
|
|
1400
1404
|
/**
|
|
@@ -1403,10 +1407,10 @@ var BackendManagement = class {
|
|
|
1403
1407
|
* @param request - Update request with backendId and fields to update
|
|
1404
1408
|
* @returns Updated backend info
|
|
1405
1409
|
*/
|
|
1406
|
-
async update(
|
|
1410
|
+
async update(updateRequest) {
|
|
1407
1411
|
return this.client.request(
|
|
1408
1412
|
REMOTE_STORAGE_COMMANDS.updateBackend,
|
|
1409
|
-
request
|
|
1413
|
+
{ request: updateRequest }
|
|
1410
1414
|
);
|
|
1411
1415
|
}
|
|
1412
1416
|
/**
|
|
@@ -1415,7 +1419,7 @@ var BackendManagement = class {
|
|
|
1415
1419
|
*/
|
|
1416
1420
|
async remove(backendId) {
|
|
1417
1421
|
await this.client.request(REMOTE_STORAGE_COMMANDS.removeBackend, {
|
|
1418
|
-
backendId
|
|
1422
|
+
request: { backendId }
|
|
1419
1423
|
});
|
|
1420
1424
|
}
|
|
1421
1425
|
/**
|
|
@@ -1424,7 +1428,7 @@ var BackendManagement = class {
|
|
|
1424
1428
|
*/
|
|
1425
1429
|
async test(backendId) {
|
|
1426
1430
|
await this.client.request(REMOTE_STORAGE_COMMANDS.testBackend, {
|
|
1427
|
-
backendId
|
|
1431
|
+
request: { backendId }
|
|
1428
1432
|
});
|
|
1429
1433
|
}
|
|
1430
1434
|
};
|
|
@@ -1529,8 +1533,8 @@ function getTauriEvent() {
|
|
|
1529
1533
|
}
|
|
1530
1534
|
async function initNativeMode(ctx, log, onEvent, onContextChange) {
|
|
1531
1535
|
const { invoke } = getTauriCore();
|
|
1532
|
-
const extensionInfo = await invoke(
|
|
1533
|
-
const context = await invoke(
|
|
1536
|
+
const extensionInfo = await invoke(EXTENSION_COMMANDS.getInfo);
|
|
1537
|
+
const context = await invoke(EXTENSION_COMMANDS.getContext);
|
|
1534
1538
|
ctx.state.isNativeWindow = true;
|
|
1535
1539
|
ctx.state.initialized = true;
|
|
1536
1540
|
ctx.state.extensionInfo = extensionInfo;
|