@premai/reticle 0.5.0 → 0.5.1

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@premai/reticle",
3
3
  "type": "module",
4
- "version": "0.5.0",
4
+ "version": "0.5.1",
5
5
  "files": [
6
6
  "reticle_bg.wasm",
7
7
  "reticle.js",
package/reticle.d.ts CHANGED
@@ -129,7 +129,7 @@ export class ClientBuilder {
129
129
  */
130
130
  with_pcs(pcs: Pcs): ClientBuilder;
131
131
  /**
132
- * sets custom url for OPA policies index
132
+ * sets the confidential policy provider to URL source with the specified url
133
133
  */
134
134
  with_policies_url(url: string): ClientBuilder;
135
135
  }
package/reticle_bg.js CHANGED
@@ -386,7 +386,7 @@ export class ClientBuilder {
386
386
  return ClientBuilder.__wrap(ret);
387
387
  }
388
388
  /**
389
- * sets custom url for OPA policies index
389
+ * sets the confidential policy provider to URL source with the specified url
390
390
  * @param {string} url
391
391
  * @returns {ClientBuilder}
392
392
  */
@@ -395,7 +395,10 @@ export class ClientBuilder {
395
395
  const ptr0 = passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
396
396
  const len0 = WASM_VECTOR_LEN;
397
397
  const ret = wasm.clientbuilder_with_policies_url(ptr, ptr0, len0);
398
- return ClientBuilder.__wrap(ret);
398
+ if (ret[2]) {
399
+ throw takeFromExternrefTable0(ret[1]);
400
+ }
401
+ return ClientBuilder.__wrap(ret[0]);
399
402
  }
400
403
  }
401
404
  if (Symbol.dispose) ClientBuilder.prototype[Symbol.dispose] = ClientBuilder.prototype.free;
@@ -1258,10 +1261,6 @@ export function __wbg_azurequote_new(arg0) {
1258
1261
  const ret = AzureQuote.__wrap(arg0);
1259
1262
  return ret;
1260
1263
  }
1261
- export function __wbg_call_13665d9f14390edc() { return handleError(function (arg0, arg1) {
1262
- const ret = arg0.call(arg1);
1263
- return ret;
1264
- }, arguments); }
1265
1264
  export function __wbg_call_dfde26266607c996() { return handleError(function (arg0, arg1, arg2) {
1266
1265
  const ret = arg0.call(arg1, arg2);
1267
1266
  return ret;
@@ -1270,10 +1269,6 @@ export function __wbg_clearTimeout_333bba87532ab9d3(arg0) {
1270
1269
  const ret = clearTimeout(arg0);
1271
1270
  return ret;
1272
1271
  }
1273
- export function __wbg_clearTimeout_6b8d9a38b9263d65(arg0) {
1274
- const ret = clearTimeout(arg0);
1275
- return ret;
1276
- }
1277
1272
  export function __wbg_client_new(arg0) {
1278
1273
  const ret = Client.__wrap(arg0);
1279
1274
  return ret;
@@ -1302,20 +1297,16 @@ export function __wbg_fetch_074561c3e313c86f(arg0) {
1302
1297
  const ret = fetch(arg0);
1303
1298
  return ret;
1304
1299
  }
1305
- export function __wbg_fetch_13f5dce13e2a3778(arg0, arg1) {
1306
- const ret = globalThis.fetch(arg0, arg1);
1307
- return ret;
1308
- }
1309
1300
  export function __wbg_fetch_2998af8c54e0997c(arg0, arg1) {
1310
1301
  const ret = arg0.fetch(arg1);
1311
1302
  return ret;
1312
1303
  }
1313
- export function __wbg_fetch_9dad4fe911207b37(arg0) {
1314
- const ret = fetch(arg0);
1304
+ export function __wbg_fetch_8319d82c48626664(arg0) {
1305
+ const ret = globalThis.fetch(arg0);
1315
1306
  return ret;
1316
1307
  }
1317
- export function __wbg_fetch_ee414d53c87db3c9(arg0) {
1318
- const ret = globalThis.fetch(arg0);
1308
+ export function __wbg_fetch_afeeccd67d9f27cd(arg0, arg1) {
1309
+ const ret = globalThis.fetch(arg0, arg1);
1319
1310
  return ret;
1320
1311
  }
1321
1312
  export function __wbg_gatewayerror_new(arg0) {
@@ -1332,10 +1323,6 @@ export function __wbg_getTime_09f1dd40a44edb30(arg0) {
1332
1323
  const ret = arg0.getTime();
1333
1324
  return ret;
1334
1325
  }
1335
- export function __wbg_get_3e9a707ab7d352eb() { return handleError(function (arg0, arg1) {
1336
- const ret = Reflect.get(arg0, arg1);
1337
- return ret;
1338
- }, arguments); }
1339
1326
  export function __wbg_get_98fdf51d029a75eb(arg0, arg1) {
1340
1327
  const ret = arg0[arg1 >>> 0];
1341
1328
  return ret;
@@ -1372,10 +1359,6 @@ export function __wbg_isArray_94898ed3aad6947b(arg0) {
1372
1359
  const ret = Array.isArray(arg0);
1373
1360
  return ret;
1374
1361
  }
1375
- export function __wbg_iterator_1441b47f341dc34f() {
1376
- const ret = Symbol.iterator;
1377
- return ret;
1378
- }
1379
1362
  export function __wbg_keychain_new(arg0) {
1380
1363
  const ret = KeyChain.__wrap(arg0);
1381
1364
  return ret;
@@ -1446,10 +1429,6 @@ export function __wbg_new_with_str_and_init_ffe9977c986ea039() { return handleEr
1446
1429
  const ret = new Request(getStringFromWasm0(arg0, arg1), arg2);
1447
1430
  return ret;
1448
1431
  }, arguments); }
1449
- export function __wbg_next_2a4e19f4f5083b0f(arg0) {
1450
- const ret = arg0.next;
1451
- return ret;
1452
- }
1453
1432
  export function __wbg_next_6429a146bf756f93() { return handleError(function (arg0) {
1454
1433
  const ret = arg0.next();
1455
1434
  return ret;
@@ -1499,10 +1478,6 @@ export function __wbg_setTimeout_3a808dd861dd3c12(arg0, arg1) {
1499
1478
  const ret = setTimeout(arg0, arg1);
1500
1479
  return ret;
1501
1480
  }
1502
- export function __wbg_setTimeout_f757f00851f76c42(arg0, arg1) {
1503
- const ret = setTimeout(arg0, arg1);
1504
- return ret;
1505
- }
1506
1481
  export function __wbg_set_a0e911be3da02782() { return handleError(function (arg0, arg1, arg2) {
1507
1482
  const ret = Reflect.set(arg0, arg1, arg2);
1508
1483
  return ret;
@@ -1562,10 +1537,6 @@ export function __wbg_status_0853c9f5752c7ee2(arg0) {
1562
1537
  const ret = arg0.status;
1563
1538
  return ret;
1564
1539
  }
1565
- export function __wbg_stringify_ef0c105b1ccc3849() { return handleError(function (arg0) {
1566
- const ret = JSON.stringify(arg0);
1567
- return ret;
1568
- }, arguments); }
1569
1540
  export function __wbg_subarray_7c6a0da8f3b4a1ba(arg0, arg1, arg2) {
1570
1541
  const ret = arg0.subarray(arg1 >>> 0, arg2 >>> 0);
1571
1542
  return ret;
@@ -1613,31 +1584,26 @@ export function __wbg_versions_215a3ab1c9d5745a(arg0) {
1613
1584
  return ret;
1614
1585
  }
1615
1586
  export function __wbindgen_cast_0000000000000001(arg0, arg1) {
1616
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 2326, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
1587
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 2325, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
1617
1588
  const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__hf4a21e70682c3774);
1618
1589
  return ret;
1619
1590
  }
1620
1591
  export function __wbindgen_cast_0000000000000002(arg0, arg1) {
1621
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 1607, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
1622
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h20881e39b0eb6131);
1592
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 2101, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
1593
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__hc164a5141a8f3733);
1623
1594
  return ret;
1624
1595
  }
1625
1596
  export function __wbindgen_cast_0000000000000003(arg0, arg1) {
1626
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 2103, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
1627
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3c4a7dcd6cb00983);
1628
- return ret;
1629
- }
1630
- export function __wbindgen_cast_0000000000000004(arg0, arg1) {
1631
1597
  // Cast intrinsic for `Ref(Slice(U8)) -> NamedExternref("Uint8Array")`.
1632
1598
  const ret = getArrayU8FromWasm0(arg0, arg1);
1633
1599
  return ret;
1634
1600
  }
1635
- export function __wbindgen_cast_0000000000000005(arg0, arg1) {
1601
+ export function __wbindgen_cast_0000000000000004(arg0, arg1) {
1636
1602
  // Cast intrinsic for `Ref(String) -> Externref`.
1637
1603
  const ret = getStringFromWasm0(arg0, arg1);
1638
1604
  return ret;
1639
1605
  }
1640
- export function __wbindgen_cast_0000000000000006(arg0, arg1) {
1606
+ export function __wbindgen_cast_0000000000000005(arg0, arg1) {
1641
1607
  var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
1642
1608
  wasm.__wbindgen_free(arg0, arg1 * 4, 4);
1643
1609
  // Cast intrinsic for `Vector(NamedExternref("string")) -> Externref`.
@@ -1653,12 +1619,8 @@ export function __wbindgen_init_externref_table() {
1653
1619
  table.set(offset + 2, true);
1654
1620
  table.set(offset + 3, false);
1655
1621
  }
1656
- function wasm_bindgen__convert__closures_____invoke__h20881e39b0eb6131(arg0, arg1) {
1657
- wasm.wasm_bindgen__convert__closures_____invoke__h20881e39b0eb6131(arg0, arg1);
1658
- }
1659
-
1660
- function wasm_bindgen__convert__closures_____invoke__h3c4a7dcd6cb00983(arg0, arg1) {
1661
- wasm.wasm_bindgen__convert__closures_____invoke__h3c4a7dcd6cb00983(arg0, arg1);
1622
+ function wasm_bindgen__convert__closures_____invoke__hc164a5141a8f3733(arg0, arg1) {
1623
+ wasm.wasm_bindgen__convert__closures_____invoke__hc164a5141a8f3733(arg0, arg1);
1662
1624
  }
1663
1625
 
1664
1626
  function wasm_bindgen__convert__closures_____invoke__hf4a21e70682c3774(arg0, arg1, arg2) {
package/reticle_bg.wasm CHANGED
Binary file
package/reticle_main.cjs CHANGED
@@ -394,7 +394,7 @@ class ClientBuilder {
394
394
  return ClientBuilder.__wrap(ret);
395
395
  }
396
396
  /**
397
- * sets custom url for OPA policies index
397
+ * sets the confidential policy provider to URL source with the specified url
398
398
  * @param {string} url
399
399
  * @returns {ClientBuilder}
400
400
  */
@@ -403,7 +403,10 @@ class ClientBuilder {
403
403
  const ptr0 = passStringToWasm0(url, wasm.__wbindgen_malloc, wasm.__wbindgen_realloc);
404
404
  const len0 = WASM_VECTOR_LEN;
405
405
  const ret = wasm.clientbuilder_with_policies_url(ptr, ptr0, len0);
406
- return ClientBuilder.__wrap(ret);
406
+ if (ret[2]) {
407
+ throw takeFromExternrefTable0(ret[1]);
408
+ }
409
+ return ClientBuilder.__wrap(ret[0]);
407
410
  }
408
411
  }
409
412
  if (Symbol.dispose) ClientBuilder.prototype[Symbol.dispose] = ClientBuilder.prototype.free;
@@ -1293,10 +1296,6 @@ function __wbg_get_imports() {
1293
1296
  const ret = AzureQuote.__wrap(arg0);
1294
1297
  return ret;
1295
1298
  },
1296
- __wbg_call_13665d9f14390edc: function() { return handleError(function (arg0, arg1) {
1297
- const ret = arg0.call(arg1);
1298
- return ret;
1299
- }, arguments); },
1300
1299
  __wbg_call_dfde26266607c996: function() { return handleError(function (arg0, arg1, arg2) {
1301
1300
  const ret = arg0.call(arg1, arg2);
1302
1301
  return ret;
@@ -1305,10 +1304,6 @@ function __wbg_get_imports() {
1305
1304
  const ret = clearTimeout(arg0);
1306
1305
  return ret;
1307
1306
  },
1308
- __wbg_clearTimeout_6b8d9a38b9263d65: function(arg0) {
1309
- const ret = clearTimeout(arg0);
1310
- return ret;
1311
- },
1312
1307
  __wbg_client_new: function(arg0) {
1313
1308
  const ret = Client.__wrap(arg0);
1314
1309
  return ret;
@@ -1337,20 +1332,16 @@ function __wbg_get_imports() {
1337
1332
  const ret = fetch(arg0);
1338
1333
  return ret;
1339
1334
  },
1340
- __wbg_fetch_13f5dce13e2a3778: function(arg0, arg1) {
1341
- const ret = globalThis.fetch(arg0, arg1);
1342
- return ret;
1343
- },
1344
1335
  __wbg_fetch_2998af8c54e0997c: function(arg0, arg1) {
1345
1336
  const ret = arg0.fetch(arg1);
1346
1337
  return ret;
1347
1338
  },
1348
- __wbg_fetch_9dad4fe911207b37: function(arg0) {
1349
- const ret = fetch(arg0);
1339
+ __wbg_fetch_8319d82c48626664: function(arg0) {
1340
+ const ret = globalThis.fetch(arg0);
1350
1341
  return ret;
1351
1342
  },
1352
- __wbg_fetch_ee414d53c87db3c9: function(arg0) {
1353
- const ret = globalThis.fetch(arg0);
1343
+ __wbg_fetch_afeeccd67d9f27cd: function(arg0, arg1) {
1344
+ const ret = globalThis.fetch(arg0, arg1);
1354
1345
  return ret;
1355
1346
  },
1356
1347
  __wbg_gatewayerror_new: function(arg0) {
@@ -1367,10 +1358,6 @@ function __wbg_get_imports() {
1367
1358
  const ret = arg0.getTime();
1368
1359
  return ret;
1369
1360
  },
1370
- __wbg_get_3e9a707ab7d352eb: function() { return handleError(function (arg0, arg1) {
1371
- const ret = Reflect.get(arg0, arg1);
1372
- return ret;
1373
- }, arguments); },
1374
1361
  __wbg_get_98fdf51d029a75eb: function(arg0, arg1) {
1375
1362
  const ret = arg0[arg1 >>> 0];
1376
1363
  return ret;
@@ -1407,10 +1394,6 @@ function __wbg_get_imports() {
1407
1394
  const ret = Array.isArray(arg0);
1408
1395
  return ret;
1409
1396
  },
1410
- __wbg_iterator_1441b47f341dc34f: function() {
1411
- const ret = Symbol.iterator;
1412
- return ret;
1413
- },
1414
1397
  __wbg_keychain_new: function(arg0) {
1415
1398
  const ret = KeyChain.__wrap(arg0);
1416
1399
  return ret;
@@ -1481,10 +1464,6 @@ function __wbg_get_imports() {
1481
1464
  const ret = new Request(getStringFromWasm0(arg0, arg1), arg2);
1482
1465
  return ret;
1483
1466
  }, arguments); },
1484
- __wbg_next_2a4e19f4f5083b0f: function(arg0) {
1485
- const ret = arg0.next;
1486
- return ret;
1487
- },
1488
1467
  __wbg_next_6429a146bf756f93: function() { return handleError(function (arg0) {
1489
1468
  const ret = arg0.next();
1490
1469
  return ret;
@@ -1534,10 +1513,6 @@ function __wbg_get_imports() {
1534
1513
  const ret = setTimeout(arg0, arg1);
1535
1514
  return ret;
1536
1515
  },
1537
- __wbg_setTimeout_f757f00851f76c42: function(arg0, arg1) {
1538
- const ret = setTimeout(arg0, arg1);
1539
- return ret;
1540
- },
1541
1516
  __wbg_set_a0e911be3da02782: function() { return handleError(function (arg0, arg1, arg2) {
1542
1517
  const ret = Reflect.set(arg0, arg1, arg2);
1543
1518
  return ret;
@@ -1597,10 +1572,6 @@ function __wbg_get_imports() {
1597
1572
  const ret = arg0.status;
1598
1573
  return ret;
1599
1574
  },
1600
- __wbg_stringify_ef0c105b1ccc3849: function() { return handleError(function (arg0) {
1601
- const ret = JSON.stringify(arg0);
1602
- return ret;
1603
- }, arguments); },
1604
1575
  __wbg_subarray_7c6a0da8f3b4a1ba: function(arg0, arg1, arg2) {
1605
1576
  const ret = arg0.subarray(arg1 >>> 0, arg2 >>> 0);
1606
1577
  return ret;
@@ -1648,31 +1619,26 @@ function __wbg_get_imports() {
1648
1619
  return ret;
1649
1620
  },
1650
1621
  __wbindgen_cast_0000000000000001: function(arg0, arg1) {
1651
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 2326, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
1622
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [Externref], shim_idx: 2325, ret: Result(Unit), inner_ret: Some(Result(Unit)) }, mutable: true }) -> Externref`.
1652
1623
  const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__hf4a21e70682c3774);
1653
1624
  return ret;
1654
1625
  },
1655
1626
  __wbindgen_cast_0000000000000002: function(arg0, arg1) {
1656
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 1607, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
1657
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h20881e39b0eb6131);
1627
+ // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 2101, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
1628
+ const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__hc164a5141a8f3733);
1658
1629
  return ret;
1659
1630
  },
1660
1631
  __wbindgen_cast_0000000000000003: function(arg0, arg1) {
1661
- // Cast intrinsic for `Closure(Closure { owned: true, function: Function { arguments: [], shim_idx: 2103, ret: Unit, inner_ret: Some(Unit) }, mutable: true }) -> Externref`.
1662
- const ret = makeMutClosure(arg0, arg1, wasm_bindgen__convert__closures_____invoke__h3c4a7dcd6cb00983);
1663
- return ret;
1664
- },
1665
- __wbindgen_cast_0000000000000004: function(arg0, arg1) {
1666
1632
  // Cast intrinsic for `Ref(Slice(U8)) -> NamedExternref("Uint8Array")`.
1667
1633
  const ret = getArrayU8FromWasm0(arg0, arg1);
1668
1634
  return ret;
1669
1635
  },
1670
- __wbindgen_cast_0000000000000005: function(arg0, arg1) {
1636
+ __wbindgen_cast_0000000000000004: function(arg0, arg1) {
1671
1637
  // Cast intrinsic for `Ref(String) -> Externref`.
1672
1638
  const ret = getStringFromWasm0(arg0, arg1);
1673
1639
  return ret;
1674
1640
  },
1675
- __wbindgen_cast_0000000000000006: function(arg0, arg1) {
1641
+ __wbindgen_cast_0000000000000005: function(arg0, arg1) {
1676
1642
  var v0 = getArrayJsValueFromWasm0(arg0, arg1).slice();
1677
1643
  wasm.__wbindgen_free(arg0, arg1 * 4, 4);
1678
1644
  // Cast intrinsic for `Vector(NamedExternref("string")) -> Externref`.
@@ -1695,12 +1661,8 @@ function __wbg_get_imports() {
1695
1661
  };
1696
1662
  }
1697
1663
 
1698
- function wasm_bindgen__convert__closures_____invoke__h20881e39b0eb6131(arg0, arg1) {
1699
- wasm.wasm_bindgen__convert__closures_____invoke__h20881e39b0eb6131(arg0, arg1);
1700
- }
1701
-
1702
- function wasm_bindgen__convert__closures_____invoke__h3c4a7dcd6cb00983(arg0, arg1) {
1703
- wasm.wasm_bindgen__convert__closures_____invoke__h3c4a7dcd6cb00983(arg0, arg1);
1664
+ function wasm_bindgen__convert__closures_____invoke__hc164a5141a8f3733(arg0, arg1) {
1665
+ wasm.wasm_bindgen__convert__closures_____invoke__hc164a5141a8f3733(arg0, arg1);
1704
1666
  }
1705
1667
 
1706
1668
  function wasm_bindgen__convert__closures_____invoke__hf4a21e70682c3774(arg0, arg1, arg2) {