@haex-space/vault-sdk 2.5.65 → 2.5.68

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/svelte.mjs CHANGED
@@ -396,6 +396,16 @@ var DATABASE_COMMANDS = {
396
396
  registerMigrations: "extension_database_register_migrations"
397
397
  };
398
398
 
399
+ // src/commands/permissions.ts
400
+ var PERMISSIONS_COMMANDS = {
401
+ /** Check web/fetch permission */
402
+ checkWeb: "extension_permissions_check_web",
403
+ /** Check database permission */
404
+ checkDatabase: "extension_permissions_check_database",
405
+ /** Check filesystem permission */
406
+ checkFilesystem: "extension_permissions_check_filesystem"
407
+ };
408
+
399
409
  // src/commands/web.ts
400
410
  var WEB_COMMANDS = {
401
411
  /** Open URL in external browser */
@@ -452,6 +462,12 @@ var FILESYSTEM_COMMANDS = {
452
462
  copy: "extension_filesystem_copy"
453
463
  };
454
464
 
465
+ // src/commands/externalBridge.ts
466
+ var EXTERNAL_BRIDGE_COMMANDS = {
467
+ // Response handling (called by extensions running in WebView)
468
+ /** Respond to an external request */
469
+ respond: "webview_extension_external_respond"};
470
+
455
471
  // src/commands/extension.ts
456
472
  var EXTENSION_COMMANDS = {
457
473
  /** Get application context (theme, locale, etc.) */
@@ -933,7 +949,7 @@ var PermissionsAPI = class {
933
949
  */
934
950
  async checkDatabaseAsync(resource, operation) {
935
951
  const response = await this.client.request(
936
- "permissions.database.check",
952
+ PERMISSIONS_COMMANDS.checkDatabase,
937
953
  {
938
954
  resource,
939
955
  operation
@@ -949,7 +965,7 @@ var PermissionsAPI = class {
949
965
  */
950
966
  async checkWebAsync(url) {
951
967
  const response = await this.client.request(
952
- "permissions.web.check",
968
+ PERMISSIONS_COMMANDS.checkWeb,
953
969
  {
954
970
  url
955
971
  }
@@ -964,7 +980,7 @@ var PermissionsAPI = class {
964
980
  */
965
981
  async checkFilesystemAsync(path, operation) {
966
982
  const response = await this.client.request(
967
- "permissions.filesystem.check",
983
+ PERMISSIONS_COMMANDS.checkFilesystem,
968
984
  {
969
985
  path,
970
986
  operation
@@ -1539,7 +1555,7 @@ async function handleExternalRequest(request, handlers, respond, log) {
1539
1555
  }
1540
1556
  async function respondToExternalRequest(response, request) {
1541
1557
  console.log("[SDK Debug] respondToExternalRequest called with:", JSON.stringify(response, null, 2));
1542
- await request("external.respond", response);
1558
+ await request(EXTERNAL_BRIDGE_COMMANDS.respond, response);
1543
1559
  }
1544
1560
 
1545
1561
  // src/client.ts