@telecrypt-io/storage 0.2.1 → 0.2.2

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/README.md CHANGED
@@ -8,14 +8,14 @@ Files are encrypted on the client before upload. The server stores only opaque c
8
8
  never holds the decryption keys. Shared folders let multiple people add and read files, and a
9
9
  Recovery Key restores your files on a new device — even if you lose the original.
10
10
 
11
- **Status:** library source only. `@telecrypt-io/storage@0.2.0` is the current public release,
12
- published from this repository's protected `v0.2.0` tag with NPM Trusted Publishing/OIDC
11
+ **Status:** library source only. `@telecrypt-io/storage@0.2.2` is the current public release,
12
+ published from this repository's protected `v0.2.2` tag with NPM Trusted Publishing/OIDC
13
13
  provenance. The older `0.1.3` release is the immutable legacy combined library-and-CLI package.
14
14
 
15
15
  ## Install
16
16
 
17
17
  ```bash
18
- npm install @telecrypt-io/storage
18
+ npm install @telecrypt-io/storage@0.2.2
19
19
  ```
20
20
 
21
21
  This gives you the `TeleCryptIOStorage` library and its browser-safe `core` API.
@@ -28,11 +28,10 @@ export interface OidcTokenSet {
28
28
  *
29
29
  * NODE CALLERS: this internally constructs oidc-client-ts state that
30
30
  * requires `window.sessionStorage`/`window.localStorage` to exist (a real
31
- * browser has both natively). Under plain Node, wrap this ONE call in
32
- * `src/cli/oidcWindowPolyfill.ts`'s `withOidcWindowShim()` — see that file's
33
- * doc comment for why it must be scoped narrowly (a permanent global
34
- * `window` breaks the rust-crypto WASM's own environment detection) and why
35
- * it's safe here specifically (called once, before any crypto/WASM exists).
31
+ * browser has both natively). A Node adapter may install those only around
32
+ * this call: a permanent global `window` breaks rust-crypto WASM's own
33
+ * environment detection. The functional-test-only adapter is kept in
34
+ * `test/harness/oidcWindowShim.ts`, rather than in the production SDK.
36
35
  */
37
36
  export declare function discoverOidcIssuer(homeserverBaseUrl: string): Promise<OidcClientConfig>;
38
37
  /**
package/dist/core/oidc.js CHANGED
@@ -19,11 +19,10 @@ import { CliError } from "./errors.js";
19
19
  *
20
20
  * NODE CALLERS: this internally constructs oidc-client-ts state that
21
21
  * requires `window.sessionStorage`/`window.localStorage` to exist (a real
22
- * browser has both natively). Under plain Node, wrap this ONE call in
23
- * `src/cli/oidcWindowPolyfill.ts`'s `withOidcWindowShim()` — see that file's
24
- * doc comment for why it must be scoped narrowly (a permanent global
25
- * `window` breaks the rust-crypto WASM's own environment detection) and why
26
- * it's safe here specifically (called once, before any crypto/WASM exists).
22
+ * browser has both natively). A Node adapter may install those only around
23
+ * this call: a permanent global `window` breaks rust-crypto WASM's own
24
+ * environment detection. The functional-test-only adapter is kept in
25
+ * `test/harness/oidcWindowShim.ts`, rather than in the production SDK.
27
26
  */
28
27
  export async function discoverOidcIssuer(homeserverBaseUrl) {
29
28
  const client = createClient({ baseUrl: homeserverBaseUrl });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@telecrypt-io/storage",
3
- "version": "0.2.1",
3
+ "version": "0.2.2",
4
4
  "license": "BUSL-1.1",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -28,6 +28,7 @@
28
28
  "build": "tsc",
29
29
  "lint": "eslint src test --ext .ts",
30
30
  "test": "vitest run",
31
+ "test:unit": "vitest run --config vitest.unit.config.ts",
31
32
  "test:watch": "vitest",
32
33
  "synapse:up": "./throwaway_synapse/up.sh",
33
34
  "synapse:fresh": "./throwaway_synapse/up.sh --fresh",