@milaboratories/pl-client 3.16.0 → 3.16.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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capabilities.cjs","names":[],"sources":["../../src/core/capabilities.ts"],"sourcesContent":["/**\n * Backend capability tokens advertised by pl in\n * `MaintenanceAPI.Ping.Response.capabilities`.\n * Capabilities affect behaviour of inner ML mechanisms and allow\n * to detect incompatibilities between blocks and backend via\n * via `TemplateDataV3.requiredCapabilities`.\n *\n * Keep tokens in sync with the backend's advertised list. Format is\n * `<feature>:<version>`; bump the version when wire semantics change.\n *\n * Shared across:\n * - `@milaboratories/pl-client` — client-side capability checks\n * - `@platforma-sdk/tengo-builder` — populates `requiredCapabilities` at compile time\n * - `@platforma-sdk/block-tools` — copies it onto the published manifest\n * - `@milaboratories/pl-middle-layer` — checks it at install time\n */\nexport type BackendCapability =\n | \"auth:v2\"\n | \"treeFilter:v2\"\n | \"wasm:v1\"\n // Project-sharing capability tokens.\n | \"crossTreeRefs:v1\" // cross-color field attach (accept a foreign-colored shared envelope)\n | \"userListing:v1\" // list users for the recipient picker\n | \"publicGrants:v1\" // public (everyone) grants allowed for any role\n | \"txListGrants:v1\"; // list grants inside a transaction (batched recipient reads)\n\n/** True iff `capabilities` advertises the requested token. */\nexport function hasCapability(\n capabilities: readonly string[] | undefined,\n capability: BackendCapability,\n): boolean {\n return capabilities?.includes(capability) ?? false;\n}\n"],"mappings":";;
|
|
1
|
+
{"version":3,"file":"capabilities.cjs","names":[],"sources":["../../src/core/capabilities.ts"],"sourcesContent":["/**\n * Backend capability tokens advertised by pl in\n * `MaintenanceAPI.Ping.Response.capabilities`.\n * Capabilities affect behaviour of inner ML mechanisms and allow\n * to detect incompatibilities between blocks and backend via\n * via `TemplateDataV3.requiredCapabilities`.\n *\n * Keep tokens in sync with the backend's advertised list. Format is\n * `<feature>:<version>`; bump the version when wire semantics change.\n *\n * Shared across:\n * - `@milaboratories/pl-client` — client-side capability checks\n * - `@platforma-sdk/tengo-builder` — populates `requiredCapabilities` at compile time\n * - `@platforma-sdk/block-tools` — copies it onto the published manifest\n * - `@milaboratories/pl-middle-layer` — checks it at install time\n */\nexport type BackendCapability =\n | \"auth:v2\"\n | \"treeFilter:v2\"\n | \"wasm:v1\"\n // Advertised only where the deployment actually has scratch storage, not merely where the\n // build understands a 'scratchFreeSpace' request: a client that sees this stops arranging\n // its own temporary storage. Off unless pl was started with --has-scratch-space.\n | \"scratchSpace:v1\"\n // Project-sharing capability tokens.\n | \"crossTreeRefs:v1\" // cross-color field attach (accept a foreign-colored shared envelope)\n | \"userListing:v1\" // list users for the recipient picker\n | \"publicGrants:v1\" // public (everyone) grants allowed for any role\n | \"txListGrants:v1\"; // list grants inside a transaction (batched recipient reads)\n\n/** True iff `capabilities` advertises the requested token. */\nexport function hasCapability(\n capabilities: readonly string[] | undefined,\n capability: BackendCapability,\n): boolean {\n return capabilities?.includes(capability) ?? false;\n}\n"],"mappings":";;AA+BA,SAAgB,cACd,cACA,YACS;CACT,OAAO,cAAc,SAAS,UAAU,KAAK;AAC/C"}
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
* - `@platforma-sdk/block-tools` — copies it onto the published manifest
|
|
16
16
|
* - `@milaboratories/pl-middle-layer` — checks it at install time
|
|
17
17
|
*/
|
|
18
|
-
export type BackendCapability = "auth:v2" | "treeFilter:v2" | "wasm:v1" | "crossTreeRefs:v1" | "userListing:v1" | "publicGrants:v1" | "txListGrants:v1";
|
|
18
|
+
export type BackendCapability = "auth:v2" | "treeFilter:v2" | "wasm:v1" | "scratchSpace:v1" | "crossTreeRefs:v1" | "userListing:v1" | "publicGrants:v1" | "txListGrants:v1";
|
|
19
19
|
/** True iff `capabilities` advertises the requested token. */
|
|
20
20
|
export declare function hasCapability(capabilities: readonly string[] | undefined, capability: BackendCapability): boolean;
|
|
21
21
|
//#endregion
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capabilities.d.ts","names":[],"sources":["../../src/core/capabilities.ts"],"mappings":";;;;;;;;;;;;;;;;;YAgBY;;
|
|
1
|
+
{"version":3,"file":"capabilities.d.ts","names":[],"sources":["../../src/core/capabilities.ts"],"mappings":";;;;;;;;;;;;;;;;;YAgBY;;wBAeI,cACd,6CACA,YAAY"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"capabilities.js","names":[],"sources":["../../src/core/capabilities.ts"],"sourcesContent":["/**\n * Backend capability tokens advertised by pl in\n * `MaintenanceAPI.Ping.Response.capabilities`.\n * Capabilities affect behaviour of inner ML mechanisms and allow\n * to detect incompatibilities between blocks and backend via\n * via `TemplateDataV3.requiredCapabilities`.\n *\n * Keep tokens in sync with the backend's advertised list. Format is\n * `<feature>:<version>`; bump the version when wire semantics change.\n *\n * Shared across:\n * - `@milaboratories/pl-client` — client-side capability checks\n * - `@platforma-sdk/tengo-builder` — populates `requiredCapabilities` at compile time\n * - `@platforma-sdk/block-tools` — copies it onto the published manifest\n * - `@milaboratories/pl-middle-layer` — checks it at install time\n */\nexport type BackendCapability =\n | \"auth:v2\"\n | \"treeFilter:v2\"\n | \"wasm:v1\"\n // Project-sharing capability tokens.\n | \"crossTreeRefs:v1\" // cross-color field attach (accept a foreign-colored shared envelope)\n | \"userListing:v1\" // list users for the recipient picker\n | \"publicGrants:v1\" // public (everyone) grants allowed for any role\n | \"txListGrants:v1\"; // list grants inside a transaction (batched recipient reads)\n\n/** True iff `capabilities` advertises the requested token. */\nexport function hasCapability(\n capabilities: readonly string[] | undefined,\n capability: BackendCapability,\n): boolean {\n return capabilities?.includes(capability) ?? false;\n}\n"],"mappings":";;
|
|
1
|
+
{"version":3,"file":"capabilities.js","names":[],"sources":["../../src/core/capabilities.ts"],"sourcesContent":["/**\n * Backend capability tokens advertised by pl in\n * `MaintenanceAPI.Ping.Response.capabilities`.\n * Capabilities affect behaviour of inner ML mechanisms and allow\n * to detect incompatibilities between blocks and backend via\n * via `TemplateDataV3.requiredCapabilities`.\n *\n * Keep tokens in sync with the backend's advertised list. Format is\n * `<feature>:<version>`; bump the version when wire semantics change.\n *\n * Shared across:\n * - `@milaboratories/pl-client` — client-side capability checks\n * - `@platforma-sdk/tengo-builder` — populates `requiredCapabilities` at compile time\n * - `@platforma-sdk/block-tools` — copies it onto the published manifest\n * - `@milaboratories/pl-middle-layer` — checks it at install time\n */\nexport type BackendCapability =\n | \"auth:v2\"\n | \"treeFilter:v2\"\n | \"wasm:v1\"\n // Advertised only where the deployment actually has scratch storage, not merely where the\n // build understands a 'scratchFreeSpace' request: a client that sees this stops arranging\n // its own temporary storage. Off unless pl was started with --has-scratch-space.\n | \"scratchSpace:v1\"\n // Project-sharing capability tokens.\n | \"crossTreeRefs:v1\" // cross-color field attach (accept a foreign-colored shared envelope)\n | \"userListing:v1\" // list users for the recipient picker\n | \"publicGrants:v1\" // public (everyone) grants allowed for any role\n | \"txListGrants:v1\"; // list grants inside a transaction (batched recipient reads)\n\n/** True iff `capabilities` advertises the requested token. */\nexport function hasCapability(\n capabilities: readonly string[] | undefined,\n capability: BackendCapability,\n): boolean {\n return capabilities?.includes(capability) ?? false;\n}\n"],"mappings":";;AA+BA,SAAgB,cACd,cACA,YACS;CACT,OAAO,cAAc,SAAS,UAAU,KAAK;AAC/C"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@milaboratories/pl-client",
|
|
3
|
-
"version": "3.16.
|
|
3
|
+
"version": "3.16.1",
|
|
4
4
|
"description": "New TS/JS client for Platform API",
|
|
5
5
|
"files": [
|
|
6
6
|
"./dist/**/*",
|
|
@@ -30,9 +30,9 @@
|
|
|
30
30
|
"undici": "~7.16.0",
|
|
31
31
|
"utility-types": "^3.11.0",
|
|
32
32
|
"yaml": "^2.8.0",
|
|
33
|
-
"@milaboratories/pl-http": "1.2.4",
|
|
34
33
|
"@milaboratories/pl-model-common": "1.48.0",
|
|
35
|
-
"@milaboratories/ts-helpers": "1.8.6"
|
|
34
|
+
"@milaboratories/ts-helpers": "1.8.6",
|
|
35
|
+
"@milaboratories/pl-http": "1.2.4"
|
|
36
36
|
},
|
|
37
37
|
"devDependencies": {
|
|
38
38
|
"@protobuf-ts/plugin": "2.11.1",
|
package/src/core/capabilities.ts
CHANGED
|
@@ -18,6 +18,10 @@ export type BackendCapability =
|
|
|
18
18
|
| "auth:v2"
|
|
19
19
|
| "treeFilter:v2"
|
|
20
20
|
| "wasm:v1"
|
|
21
|
+
// Advertised only where the deployment actually has scratch storage, not merely where the
|
|
22
|
+
// build understands a 'scratchFreeSpace' request: a client that sees this stops arranging
|
|
23
|
+
// its own temporary storage. Off unless pl was started with --has-scratch-space.
|
|
24
|
+
| "scratchSpace:v1"
|
|
21
25
|
// Project-sharing capability tokens.
|
|
22
26
|
| "crossTreeRefs:v1" // cross-color field attach (accept a foreign-colored shared envelope)
|
|
23
27
|
| "userListing:v1" // list users for the recipient picker
|