@ggui-ai/gadgets 0.13.0 → 0.15.0
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/codegen.d.mts +1 -1
- package/dist/codegen.d.ts +1 -1
- package/dist/index.d.mts +2 -2
- package/dist/index.d.ts +2 -2
- package/dist/index.js +4 -4
- package/dist/index.mjs +2 -2
- package/package.json +4 -4
package/dist/codegen.d.mts
CHANGED
package/dist/codegen.d.ts
CHANGED
package/dist/index.d.mts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { GadgetHook, GadgetDescriptor, GadgetExportBase, JsonValue } from '@ggui-ai/protocol';
|
|
2
|
-
export { GadgetError, GadgetHook, GadgetStatus } from '@ggui-ai/protocol';
|
|
1
|
+
import { GadgetHook, GadgetDescriptor, GadgetExportBase, JsonValue } from '@ggui-ai/protocol/wire';
|
|
2
|
+
export { GadgetError, GadgetHook, GadgetStatus } from '@ggui-ai/protocol/wire';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* `createGguiGadget` — the plugin SDK factory for ggui client
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { GadgetHook, GadgetDescriptor, GadgetExportBase, JsonValue } from '@ggui-ai/protocol';
|
|
2
|
-
export { GadgetError, GadgetHook, GadgetStatus } from '@ggui-ai/protocol';
|
|
1
|
+
import { GadgetHook, GadgetDescriptor, GadgetExportBase, JsonValue } from '@ggui-ai/protocol/wire';
|
|
2
|
+
export { GadgetError, GadgetHook, GadgetStatus } from '@ggui-ai/protocol/wire';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* `createGguiGadget` — the plugin SDK factory for ggui client
|
package/dist/index.js
CHANGED
|
@@ -37,7 +37,7 @@ __export(index_exports, {
|
|
|
37
37
|
module.exports = __toCommonJS(index_exports);
|
|
38
38
|
|
|
39
39
|
// src/createGguiGadget.ts
|
|
40
|
-
var
|
|
40
|
+
var import_wire = require("@ggui-ai/protocol/wire");
|
|
41
41
|
var WrapperConformanceError = class extends Error {
|
|
42
42
|
code = "wrapper_conformance";
|
|
43
43
|
violations;
|
|
@@ -80,7 +80,7 @@ function createGguiGadget(spec) {
|
|
|
80
80
|
...packageFields,
|
|
81
81
|
exports: [hookExport]
|
|
82
82
|
};
|
|
83
|
-
const parsed =
|
|
83
|
+
const parsed = import_wire.strictGadgetDescriptorSchema.safeParse(descriptorDraft);
|
|
84
84
|
if (!parsed.success) {
|
|
85
85
|
for (const issue of parsed.error.issues) {
|
|
86
86
|
violations.push({
|
|
@@ -107,7 +107,7 @@ function createGguiGadget(spec) {
|
|
|
107
107
|
}
|
|
108
108
|
|
|
109
109
|
// src/defineGadgetPackage.ts
|
|
110
|
-
var
|
|
110
|
+
var import_wire2 = require("@ggui-ai/protocol/wire");
|
|
111
111
|
function defineGadgetPackage(spec) {
|
|
112
112
|
const { exports: exportSpecs, ...packageFields } = spec;
|
|
113
113
|
const violations = [];
|
|
@@ -133,7 +133,7 @@ function defineGadgetPackage(spec) {
|
|
|
133
133
|
};
|
|
134
134
|
return "hook" in entry ? { hook: entry.hook, ...teaching } : { component: entry.component, ...teaching };
|
|
135
135
|
});
|
|
136
|
-
const parsed =
|
|
136
|
+
const parsed = import_wire2.strictGadgetDescriptorSchema.safeParse({
|
|
137
137
|
...packageFields,
|
|
138
138
|
exports: exports2
|
|
139
139
|
});
|
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// src/createGguiGadget.ts
|
|
2
2
|
import {
|
|
3
3
|
strictGadgetDescriptorSchema
|
|
4
|
-
} from "@ggui-ai/protocol";
|
|
4
|
+
} from "@ggui-ai/protocol/wire";
|
|
5
5
|
var WrapperConformanceError = class extends Error {
|
|
6
6
|
code = "wrapper_conformance";
|
|
7
7
|
violations;
|
|
@@ -73,7 +73,7 @@ function createGguiGadget(spec) {
|
|
|
73
73
|
// src/defineGadgetPackage.ts
|
|
74
74
|
import {
|
|
75
75
|
strictGadgetDescriptorSchema as strictGadgetDescriptorSchema2
|
|
76
|
-
} from "@ggui-ai/protocol";
|
|
76
|
+
} from "@ggui-ai/protocol/wire";
|
|
77
77
|
function defineGadgetPackage(spec) {
|
|
78
78
|
const { exports: exportSpecs, ...packageFields } = spec;
|
|
79
79
|
const violations = [];
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ggui-ai/gadgets",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.15.0",
|
|
4
4
|
"description": "Browser-capability gadget hooks for ggui — declared via DataContract.clientCapabilities.gadgets, mounted by the UI generator's component code.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"keywords": [
|
|
@@ -60,14 +60,14 @@
|
|
|
60
60
|
"vitest": "^3.2.6"
|
|
61
61
|
},
|
|
62
62
|
"dependencies": {
|
|
63
|
-
"@ggui-ai/protocol": "0.
|
|
63
|
+
"@ggui-ai/protocol": "0.15.0"
|
|
64
64
|
},
|
|
65
65
|
"engines": {
|
|
66
|
-
"node": ">=
|
|
66
|
+
"node": ">=22.0.0"
|
|
67
67
|
},
|
|
68
68
|
"author": "ggui contributors <hello@ggui.ai>",
|
|
69
69
|
"scripts": {
|
|
70
|
-
"build": "TSUP_OUT_DIR=dist.staging tsup && node ../scripts/atomic-swap.mjs dist.staging dist",
|
|
70
|
+
"build": "TSUP_OUT_DIR=dist.staging-$$ tsup && node ../scripts/fix-esm-imports.mjs dist.staging-$$ && node ../scripts/atomic-swap.mjs dist.staging-$$ dist",
|
|
71
71
|
"typecheck": "tsc --noEmit",
|
|
72
72
|
"test": "vitest run",
|
|
73
73
|
"lint": "eslint src --ext .ts,.tsx --max-warnings 0",
|