@springbrand/message-panel 0.2.0-alpha.53 → 0.2.0-alpha.55
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.
|
@@ -35,7 +35,7 @@ export interface CloudOsMessageMetadata extends UnknownRecord {
|
|
|
35
35
|
}
|
|
36
36
|
|
|
37
37
|
export interface CloudOsRequestedCapability {
|
|
38
|
-
kind: "skill" | "tool" | "plan";
|
|
38
|
+
kind: "skill" | "tool" | "plan" | "plugin";
|
|
39
39
|
name: string;
|
|
40
40
|
label: string;
|
|
41
41
|
}
|
|
@@ -194,12 +194,17 @@ export function requestedCapabilitiesOf(
|
|
|
194
194
|
typeof capability.label !== "string" ||
|
|
195
195
|
!capability.label.trim()
|
|
196
196
|
) return [];
|
|
197
|
-
const
|
|
197
|
+
const resourceId = typeof capability.resourceId === "string"
|
|
198
|
+
? capability.resourceId.trim()
|
|
199
|
+
: "";
|
|
200
|
+
const kind = resourceId ? "plugin" : capability.kind;
|
|
201
|
+
const name = resourceId || capability.name;
|
|
202
|
+
const key = `${kind}:${name}`;
|
|
198
203
|
if (seen.has(key)) return [];
|
|
199
204
|
seen.add(key);
|
|
200
205
|
return [{
|
|
201
|
-
kind
|
|
202
|
-
name
|
|
206
|
+
kind,
|
|
207
|
+
name,
|
|
203
208
|
label: capability.label,
|
|
204
209
|
}];
|
|
205
210
|
});
|