@yaklabs-ai/plugin-protocol 0.50.0 → 0.51.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/README.md +1 -1
- package/THIRD-PARTY-INVENTORY.json +1 -1
- package/dist/index.d.ts +27 -1
- package/dist/index.js +19 -10
- package/package.json +1 -1
package/README.md
CHANGED
package/dist/index.d.ts
CHANGED
|
@@ -3230,6 +3230,12 @@ declare const canonicalContributionSchemas: {
|
|
|
3230
3230
|
panel: z.ZodOptional<z.ZodObject<{
|
|
3231
3231
|
body: z.ZodString;
|
|
3232
3232
|
}, z.core.$strict>>;
|
|
3233
|
+
featureFlagVariant: z.ZodOptional<z.ZodObject<{
|
|
3234
|
+
flag: z.ZodString;
|
|
3235
|
+
title: z.ZodOptional<z.ZodString>;
|
|
3236
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
3237
|
+
panel: z.ZodOptional<z.ZodLiteral<false>>;
|
|
3238
|
+
}, z.core.$strict>>;
|
|
3233
3239
|
}, z.core.$strict>;
|
|
3234
3240
|
UiToastPreviewContribution: z.ZodObject<{
|
|
3235
3241
|
rule: z.ZodString;
|
|
@@ -4744,8 +4750,10 @@ export declare const KAY_PLUGIN_PROTOCOL_VERSION: "kay.plugin.v1";
|
|
|
4744
4750
|
*
|
|
4745
4751
|
* 0.50.0 adds explicit cross-plugin endpoint calls on both backend targets. The URI-only 0.49.0
|
|
4746
4752
|
* contract remains served.
|
|
4753
|
+
*
|
|
4754
|
+
* 0.51.0 adds flag-dependent title, icon and panel presence on rail entries.
|
|
4747
4755
|
*/
|
|
4748
|
-
export declare const KAY_PLUGIN_SDK_VERSION: "0.
|
|
4756
|
+
export declare const KAY_PLUGIN_SDK_VERSION: "0.51.0";
|
|
4749
4757
|
|
|
4750
4758
|
export declare const KAY_PLUGIN_TARGET_NAMES: readonly ["kay.agent", "kay.app", "kay.ui"];
|
|
4751
4759
|
|
|
@@ -6721,6 +6729,12 @@ export declare const KayPluginManifestV1: z.ZodObject<{
|
|
|
6721
6729
|
panel: z.ZodOptional<z.ZodObject<{
|
|
6722
6730
|
body: z.ZodString;
|
|
6723
6731
|
}, z.core.$strict>>;
|
|
6732
|
+
featureFlagVariant: z.ZodOptional<z.ZodObject<{
|
|
6733
|
+
flag: z.ZodString;
|
|
6734
|
+
title: z.ZodOptional<z.ZodString>;
|
|
6735
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
6736
|
+
panel: z.ZodOptional<z.ZodLiteral<false>>;
|
|
6737
|
+
}, z.core.$strict>>;
|
|
6724
6738
|
}, z.core.$strict>>>;
|
|
6725
6739
|
toastPreviews: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
6726
6740
|
rule: z.ZodString;
|
|
@@ -7902,6 +7916,12 @@ export declare const KayUiTargetManifest: z.ZodObject<{
|
|
|
7902
7916
|
panel: z.ZodOptional<z.ZodObject<{
|
|
7903
7917
|
body: z.ZodString;
|
|
7904
7918
|
}, z.core.$strict>>;
|
|
7919
|
+
featureFlagVariant: z.ZodOptional<z.ZodObject<{
|
|
7920
|
+
flag: z.ZodString;
|
|
7921
|
+
title: z.ZodOptional<z.ZodString>;
|
|
7922
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
7923
|
+
panel: z.ZodOptional<z.ZodLiteral<false>>;
|
|
7924
|
+
}, z.core.$strict>>;
|
|
7905
7925
|
}, z.core.$strict>>>;
|
|
7906
7926
|
toastPreviews: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
7907
7927
|
rule: z.ZodString;
|
|
@@ -16072,6 +16092,12 @@ export declare const UiRailEntryContribution: z.ZodObject<{
|
|
|
16072
16092
|
panel: z.ZodOptional<z.ZodObject<{
|
|
16073
16093
|
body: z.ZodString;
|
|
16074
16094
|
}, z.core.$strict>>;
|
|
16095
|
+
featureFlagVariant: z.ZodOptional<z.ZodObject<{
|
|
16096
|
+
flag: z.ZodString;
|
|
16097
|
+
title: z.ZodOptional<z.ZodString>;
|
|
16098
|
+
icon: z.ZodOptional<z.ZodString>;
|
|
16099
|
+
panel: z.ZodOptional<z.ZodLiteral<false>>;
|
|
16100
|
+
}, z.core.$strict>>;
|
|
16075
16101
|
}, z.core.$strict>;
|
|
16076
16102
|
|
|
16077
16103
|
export declare type UiRailEntryContribution = z.infer<typeof UiRailEntryContribution>;
|
package/dist/index.js
CHANGED
|
@@ -30,6 +30,12 @@ function declaredUiIconPaths(manifest) {
|
|
|
30
30
|
const contributes = manifest.targets?.kay?.ui?.contributes;
|
|
31
31
|
return [
|
|
32
32
|
...(contributes?.railEntries ?? []).flatMap((entry) => entry.icon === void 0 ? [] : [{ label: `kay.ui rail entry '${entry.id}' icon`, path: entry.icon }]),
|
|
33
|
+
...(contributes?.railEntries ?? []).flatMap((entry) => entry.featureFlagVariant?.icon === void 0 ? [] : [
|
|
34
|
+
{
|
|
35
|
+
label: "kay.ui rail variant icon",
|
|
36
|
+
path: entry.featureFlagVariant.icon
|
|
37
|
+
}
|
|
38
|
+
]),
|
|
33
39
|
...(contributes?.pages ?? []).flatMap((page) => page.icon === void 0 ? [] : [{ label: `kay.ui page '${page.id}' icon`, path: page.icon }]),
|
|
34
40
|
...(contributes?.commands ?? []).flatMap((command) => command.icon === void 0 ? [] : [
|
|
35
41
|
{
|
|
@@ -260,8 +266,11 @@ var JsonSchema = z4.record(z4.string(), JsonValue);
|
|
|
260
266
|
var KAY_PLUGIN_MANIFEST_SIZE_CAP_BYTES = 1024 * 1024;
|
|
261
267
|
var KAY_PLUGIN_PROTOCOL_VERSION = "kay.plugin.v1";
|
|
262
268
|
var KAY_PLUGIN_PROTOCOL_PACKAGE_NAME = "@bonsai/plugin-protocol";
|
|
263
|
-
var KAY_PLUGIN_SDK_VERSION = "0.
|
|
264
|
-
var KAY_PLUGIN_COMPATIBLE_SDK_VERSIONS = [
|
|
269
|
+
var KAY_PLUGIN_SDK_VERSION = "0.51.0";
|
|
270
|
+
var KAY_PLUGIN_COMPATIBLE_SDK_VERSIONS = [
|
|
271
|
+
"0.50.0",
|
|
272
|
+
"0.49.0"
|
|
273
|
+
];
|
|
265
274
|
var KAY_PLUGIN_TARGET_NAMES = [
|
|
266
275
|
"kay.agent",
|
|
267
276
|
"kay.app",
|
|
@@ -4252,6 +4261,7 @@ function createContributionsSchemas(canonical) {
|
|
|
4252
4261
|
// Draws Bonsai's markdown document view in the app's page (`BonsaiMarkdownDocumentView`).
|
|
4253
4262
|
// It reads and saves nothing: the app supplies the text and keeps the edits.
|
|
4254
4263
|
"markdown.document-view",
|
|
4264
|
+
"models.complete",
|
|
4255
4265
|
// Draws links the host resolves and opens (`BonsaiReferencePill`, `BonsaiReferenceRow`,
|
|
4256
4266
|
// `BonsaiReferenceMarkdown`). A person's click on one can open a session or another plugin's page.
|
|
4257
4267
|
"references.open",
|
|
@@ -4327,7 +4337,13 @@ function createContributionsSchemas(canonical) {
|
|
|
4327
4337
|
order: z12.number().finite().optional(),
|
|
4328
4338
|
section: z12.enum(["primary", "plugins"]).optional(),
|
|
4329
4339
|
badge: UiRailBadge.optional(),
|
|
4330
|
-
panel: z12.strictObject({ body: LocalContributionId2 }).optional()
|
|
4340
|
+
panel: z12.strictObject({ body: LocalContributionId2 }).optional(),
|
|
4341
|
+
featureFlagVariant: z12.strictObject({
|
|
4342
|
+
flag: NonEmptyString3,
|
|
4343
|
+
title: NonEmptyString3.optional(),
|
|
4344
|
+
icon: PackageAssetPath2.optional(),
|
|
4345
|
+
panel: z12.literal(false).optional()
|
|
4346
|
+
}).optional()
|
|
4331
4347
|
});
|
|
4332
4348
|
const UiToastPreviewContribution2 = z12.strictObject({
|
|
4333
4349
|
rule: LocalContributionId2,
|
|
@@ -5193,13 +5209,6 @@ function createManifestSchemas(canonical) {
|
|
|
5193
5209
|
message: `rail entry ${entry.id} counts ${entry.badge.source}, which is not one of this plugin's data sources with a rows store`
|
|
5194
5210
|
});
|
|
5195
5211
|
}
|
|
5196
|
-
if (manifest.targets?.kay?.ui?.entrypoint === void 0) {
|
|
5197
|
-
ctx.addIssue({
|
|
5198
|
-
code: "custom",
|
|
5199
|
-
path,
|
|
5200
|
-
message: `rail entry ${entry.id} declares a badge, so its plugin needs a kay.ui entrypoint: the window starts a plugin's data sources when it loads that code`
|
|
5201
|
-
});
|
|
5202
|
-
}
|
|
5203
5212
|
}
|
|
5204
5213
|
for (const source of declaredAppDataSources) {
|
|
5205
5214
|
if (materializedAppDataSources.has(source) || declaredAppDataStores.has(source))
|
package/package.json
CHANGED