@ycodium-ai/plugin-pull-requests 0.2.3220 → 0.2.3230
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/assets/ui.js +42 -16
- package/dist/index.js +1 -68
- package/package.json +3 -3
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
// src/index.ts
|
|
2
|
-
import { definePlugin
|
|
2
|
+
import { definePlugin } from "@ycodium-ai/plugin-api";
|
|
3
3
|
|
|
4
4
|
// src/hostProject.ts
|
|
5
5
|
var providerOf = (provider) => provider === "github" || provider === "gitlab" ? provider : "unknown";
|
|
@@ -4485,31 +4485,6 @@ var createPullRequestService = (options) => {
|
|
|
4485
4485
|
// src/index.ts
|
|
4486
4486
|
var as = (payload) => payload;
|
|
4487
4487
|
var DIFF_CHUNK_CHARS = 256 * 1024;
|
|
4488
|
-
var WORKSPACE_PROJECT_SCHEMA = {
|
|
4489
|
-
type: "object",
|
|
4490
|
-
additionalProperties: false,
|
|
4491
|
-
required: ["projectId", "title", "workspaceRoot"],
|
|
4492
|
-
properties: {
|
|
4493
|
-
projectId: { type: "string", minLength: 1 },
|
|
4494
|
-
title: { type: "string" },
|
|
4495
|
-
workspaceRoot: { type: "string" },
|
|
4496
|
-
archivedAt: { type: "string" },
|
|
4497
|
-
repositoryIdentity: {
|
|
4498
|
-
type: ["object", "null"],
|
|
4499
|
-
additionalProperties: false,
|
|
4500
|
-
properties: {
|
|
4501
|
-
provider: { type: "string" },
|
|
4502
|
-
canonicalKey: { type: "string" },
|
|
4503
|
-
remoteName: { type: "string" },
|
|
4504
|
-
remoteUrl: { type: "string" },
|
|
4505
|
-
displayName: { type: "string" },
|
|
4506
|
-
owner: { type: "string" },
|
|
4507
|
-
name: { type: "string" },
|
|
4508
|
-
rootPath: { type: "string" }
|
|
4509
|
-
}
|
|
4510
|
-
}
|
|
4511
|
-
}
|
|
4512
|
-
};
|
|
4513
4488
|
var DIFF_STREAM_ITEM_SCHEMA = {
|
|
4514
4489
|
oneOf: [
|
|
4515
4490
|
{
|
|
@@ -4687,48 +4662,6 @@ var index_default = definePlugin({
|
|
|
4687
4662
|
null,
|
|
4688
4663
|
(payload) => service.converse(as(payload))
|
|
4689
4664
|
);
|
|
4690
|
-
ctx.command({
|
|
4691
|
-
name: "workspaceProjects",
|
|
4692
|
-
description: "Unarchived git repositories in this machine's workspace, with their remote identity.",
|
|
4693
|
-
scope: "read",
|
|
4694
|
-
payloadSchema: { type: "object", properties: {}, additionalProperties: false },
|
|
4695
|
-
resultSchema: {
|
|
4696
|
-
type: "object",
|
|
4697
|
-
additionalProperties: false,
|
|
4698
|
-
required: ["projects"],
|
|
4699
|
-
properties: { projects: { type: "array", items: WORKSPACE_PROJECT_SCHEMA } }
|
|
4700
|
-
},
|
|
4701
|
-
handle: async () => {
|
|
4702
|
-
const projects = (await ctx.projects.list({})).map(workspaceShellOf);
|
|
4703
|
-
return {
|
|
4704
|
-
projects: projects.filter((project) => !isArchivedWorkspaceProject(project))
|
|
4705
|
-
};
|
|
4706
|
-
}
|
|
4707
|
-
});
|
|
4708
|
-
ctx.command({
|
|
4709
|
-
name: "workspaceProject",
|
|
4710
|
-
description: "One project of this machine's workspace by id, archived or not, with its archive time.",
|
|
4711
|
-
scope: "read",
|
|
4712
|
-
payloadSchema: {
|
|
4713
|
-
type: "object",
|
|
4714
|
-
additionalProperties: false,
|
|
4715
|
-
required: ["projectId"],
|
|
4716
|
-
properties: { projectId: { type: "string", minLength: 1 } }
|
|
4717
|
-
},
|
|
4718
|
-
resultSchema: {
|
|
4719
|
-
type: "object",
|
|
4720
|
-
additionalProperties: false,
|
|
4721
|
-
required: ["project"],
|
|
4722
|
-
properties: { project: { oneOf: [WORKSPACE_PROJECT_SCHEMA, { type: "null" }] } }
|
|
4723
|
-
},
|
|
4724
|
-
handle: async (payload) => {
|
|
4725
|
-
const project = await projectOrNull(
|
|
4726
|
-
ctx.projects,
|
|
4727
|
-
as(payload).projectId
|
|
4728
|
-
);
|
|
4729
|
-
return { project: project === null ? null : workspaceShellOf(project) };
|
|
4730
|
-
}
|
|
4731
|
-
});
|
|
4732
4665
|
ctx.settingsCard({
|
|
4733
4666
|
titleKey: "settings.card.title",
|
|
4734
4667
|
descriptionKey: "settings.card.description",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ycodium-ai/plugin-pull-requests",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.3230",
|
|
4
4
|
"description": "The pull request page, for GitHub and GitLab.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pull-requests",
|
|
@@ -30,8 +30,8 @@
|
|
|
30
30
|
"tailwindcss": "^4.0.0",
|
|
31
31
|
"typescript": "~6.0.3",
|
|
32
32
|
"vite-plus": "0.2.2",
|
|
33
|
-
"ycodium-
|
|
34
|
-
"
|
|
33
|
+
"@ycodium-ai/plugin-api": "0.2.3230",
|
|
34
|
+
"ycodium-markdown-fence": "0.0.0"
|
|
35
35
|
},
|
|
36
36
|
"ycodium": {
|
|
37
37
|
"plugin": "./dist/index.js",
|