@spaceflow/core 0.2.0 → 0.3.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/index.js +208 -13
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/shared/git-provider/adapters/gitea.adapter.ts +59 -22
- package/src/shared/git-provider/adapters/github.adapter.spec.ts +2 -1
- package/src/shared/git-provider/adapters/github.adapter.ts +200 -29
- package/src/shared/git-provider/adapters/gitlab.adapter.ts +78 -26
- package/src/shared/git-provider/git-provider.interface.ts +20 -1
- package/src/shared/git-provider/git-provider.service.ts +27 -0
- package/src/shared/git-provider/types.ts +27 -0
package/dist/index.js
CHANGED
|
@@ -215,8 +215,8 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
215
215
|
x3: () => (/* reexport */ ClaudeSetupService),
|
|
216
216
|
gp: () => (/* reexport */ readConfigSync),
|
|
217
217
|
xx: () => (/* reexport */ LlmProxyService),
|
|
218
|
-
AZ: () => (/* reexport */ toLogLevel),
|
|
219
218
|
TQ: () => (/* reexport */ ciConfig),
|
|
219
|
+
AZ: () => (/* reexport */ toLogLevel),
|
|
220
220
|
e1: () => (/* reexport */ DEFAULT_EDITOR),
|
|
221
221
|
mO: () => (/* reexport */ registerPluginSchema),
|
|
222
222
|
LE: () => (/* reexport */ initI18n),
|
|
@@ -248,6 +248,7 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
248
248
|
IO: () => (/* reexport */ DEFAULT_SUPPORT_EDITOR),
|
|
249
249
|
RV: () => (/* reexport */ addSpaceflowToDevDependencies),
|
|
250
250
|
Vy: () => (/* reexport */ Logger),
|
|
251
|
+
fS: () => (/* reexport */ REVIEW_STATE),
|
|
251
252
|
Tb: () => (/* reexport */ GitProviderService),
|
|
252
253
|
jN: () => (/* reexport */ parseHunksFromPatch),
|
|
253
254
|
vr: () => (/* reexport */ RC_FILE_NAME),
|
|
@@ -269,6 +270,7 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
269
270
|
w$: () => (/* reexport */ GiteaAdapter),
|
|
270
271
|
UY: () => (/* reexport */ ensureSpaceflowDir),
|
|
271
272
|
U1: () => (/* reexport */ getSpaceflowCliPath),
|
|
273
|
+
my: () => (/* reexport */ DIFF_SIDE),
|
|
272
274
|
aU: () => (/* reexport */ createPluginConfig),
|
|
273
275
|
xo: () => (/* reexport */ normalizeSource),
|
|
274
276
|
VT: () => (/* reexport */ getConfigPaths),
|
|
@@ -349,6 +351,16 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
349
351
|
* Git Provider 通用类型定义
|
|
350
352
|
* 适用于 Gitea、GitHub 等多种 Git 托管平台
|
|
351
353
|
*/ /** Git Provider 平台类型 */ /** 注入令牌 */ const GIT_PROVIDER_MODULE_OPTIONS = "GIT_PROVIDER_MODULE_OPTIONS";
|
|
354
|
+
/** PR Review 事件常量 */ const REVIEW_STATE = {
|
|
355
|
+
APPROVE: "APPROVE",
|
|
356
|
+
REQUEST_CHANGES: "REQUEST_CHANGES",
|
|
357
|
+
COMMENT: "COMMENT",
|
|
358
|
+
PENDING: "PENDING"
|
|
359
|
+
};
|
|
360
|
+
/** PR Review 行级评论 Diff 方向 */ const DIFF_SIDE = {
|
|
361
|
+
RIGHT: "RIGHT",
|
|
362
|
+
LEFT: "LEFT"
|
|
363
|
+
};
|
|
352
364
|
|
|
353
365
|
;// CONCATENATED MODULE: ./src/shared/git-provider/detect-provider.ts
|
|
354
366
|
/**
|
|
@@ -729,6 +741,7 @@ function parseDiffText(diffText) {
|
|
|
729
741
|
;// CONCATENATED MODULE: ./src/shared/git-provider/adapters/gitea.adapter.ts
|
|
730
742
|
|
|
731
743
|
|
|
744
|
+
|
|
732
745
|
/**
|
|
733
746
|
* Gitea 平台适配器
|
|
734
747
|
*/ class GiteaAdapter {
|
|
@@ -990,16 +1003,34 @@ function parseDiffText(diffText) {
|
|
|
990
1003
|
async listPullReviews(owner, repo, index) {
|
|
991
1004
|
return this.request("GET", `/repos/${owner}/${repo}/pulls/${index}/reviews`);
|
|
992
1005
|
}
|
|
1006
|
+
async updatePullReview(owner, repo, index, reviewId, body) {
|
|
1007
|
+
// Gitea 不支持更新 review,使用删除+创建的方式模拟
|
|
1008
|
+
await this.deletePullReview(owner, repo, index, reviewId);
|
|
1009
|
+
return this.createPullReview(owner, repo, index, {
|
|
1010
|
+
event: REVIEW_STATE.COMMENT,
|
|
1011
|
+
body
|
|
1012
|
+
});
|
|
1013
|
+
}
|
|
993
1014
|
async deletePullReview(owner, repo, index, reviewId) {
|
|
994
1015
|
await this.request("DELETE", `/repos/${owner}/${repo}/pulls/${index}/reviews/${reviewId}`);
|
|
995
1016
|
}
|
|
996
1017
|
async listPullReviewComments(owner, repo, index, reviewId) {
|
|
997
1018
|
return this.request("GET", `/repos/${owner}/${repo}/pulls/${index}/reviews/${reviewId}/comments`);
|
|
998
1019
|
}
|
|
1020
|
+
async deletePullReviewComment(owner, repo, commentId) {
|
|
1021
|
+
await this.request("DELETE", `/repos/${owner}/${repo}/pulls/comments/${commentId}`);
|
|
1022
|
+
}
|
|
1023
|
+
async listResolvedThreads() {
|
|
1024
|
+
return [];
|
|
1025
|
+
}
|
|
999
1026
|
// ============ Reaction 操作 ============
|
|
1000
1027
|
async getIssueCommentReactions(owner, repo, commentId) {
|
|
1001
1028
|
return this.request("GET", `/repos/${owner}/${repo}/issues/comments/${commentId}/reactions`);
|
|
1002
1029
|
}
|
|
1030
|
+
async getPullReviewCommentReactions(owner, repo, commentId) {
|
|
1031
|
+
// Gitea: PR review comment reactions 使用与 issue comment 相同的路径
|
|
1032
|
+
return this.request("GET", `/repos/${owner}/${repo}/issues/comments/${commentId}/reactions`);
|
|
1033
|
+
}
|
|
1003
1034
|
async getIssueReactions(owner, repo, index) {
|
|
1004
1035
|
return this.request("GET", `/repos/${owner}/${repo}/issues/${index}/reactions`);
|
|
1005
1036
|
}
|
|
@@ -1018,6 +1049,7 @@ function parseDiffText(diffText) {
|
|
|
1018
1049
|
|
|
1019
1050
|
;// CONCATENATED MODULE: ./src/shared/git-provider/adapters/github.adapter.ts
|
|
1020
1051
|
|
|
1052
|
+
|
|
1021
1053
|
/**
|
|
1022
1054
|
* GitHub 平台适配器
|
|
1023
1055
|
*/ class GithubAdapter {
|
|
@@ -1059,6 +1091,29 @@ function parseDiffText(diffText) {
|
|
|
1059
1091
|
}
|
|
1060
1092
|
return response.json();
|
|
1061
1093
|
}
|
|
1094
|
+
async requestGraphQL(query, variables) {
|
|
1095
|
+
const graphqlUrl = this.baseUrl.replace(/\/v3\/?$/, "").replace(/\/api\/v3\/?$/, "") + "/graphql";
|
|
1096
|
+
const response = await fetch(graphqlUrl, {
|
|
1097
|
+
method: "POST",
|
|
1098
|
+
headers: {
|
|
1099
|
+
Authorization: `Bearer ${this.token}`,
|
|
1100
|
+
"Content-Type": "application/json"
|
|
1101
|
+
},
|
|
1102
|
+
body: JSON.stringify({
|
|
1103
|
+
query,
|
|
1104
|
+
variables
|
|
1105
|
+
})
|
|
1106
|
+
});
|
|
1107
|
+
if (!response.ok) {
|
|
1108
|
+
const errorText = await response.text();
|
|
1109
|
+
throw new Error(`GitHub GraphQL error: ${response.status} - ${errorText}`);
|
|
1110
|
+
}
|
|
1111
|
+
const json = await response.json();
|
|
1112
|
+
if (json.errors) {
|
|
1113
|
+
throw new Error(`GitHub GraphQL errors: ${JSON.stringify(json.errors)}`);
|
|
1114
|
+
}
|
|
1115
|
+
return json.data;
|
|
1116
|
+
}
|
|
1062
1117
|
async fetchText(url) {
|
|
1063
1118
|
const response = await fetch(url, {
|
|
1064
1119
|
headers: {
|
|
@@ -1295,7 +1350,8 @@ function parseDiffText(diffText) {
|
|
|
1295
1350
|
body.comments = options.comments.map((c)=>({
|
|
1296
1351
|
path: c.path,
|
|
1297
1352
|
body: c.body,
|
|
1298
|
-
|
|
1353
|
+
line: c.new_position,
|
|
1354
|
+
side: DIFF_SIDE.RIGHT
|
|
1299
1355
|
}));
|
|
1300
1356
|
}
|
|
1301
1357
|
const result = await this.request("POST", `/repos/${owner}/${repo}/pulls/${index}/reviews`, body);
|
|
@@ -1305,18 +1361,50 @@ function parseDiffText(diffText) {
|
|
|
1305
1361
|
const results = await this.request("GET", `/repos/${owner}/${repo}/pulls/${index}/reviews`);
|
|
1306
1362
|
return results.map((r)=>this.mapPullReview(r));
|
|
1307
1363
|
}
|
|
1364
|
+
async updatePullReview(owner, repo, index, reviewId, body) {
|
|
1365
|
+
// GitHub 的 updatePullReview 只能更新 PENDING 状态的 review
|
|
1366
|
+
// 已提交的 review 无法更新,所以使用删除+创建的方式
|
|
1367
|
+
try {
|
|
1368
|
+
await this.deletePullReview(owner, repo, index, reviewId);
|
|
1369
|
+
} catch {
|
|
1370
|
+
// 已提交的 review 无法删除,忽略错误
|
|
1371
|
+
}
|
|
1372
|
+
return this.createPullReview(owner, repo, index, {
|
|
1373
|
+
event: REVIEW_STATE.COMMENT,
|
|
1374
|
+
body
|
|
1375
|
+
});
|
|
1376
|
+
}
|
|
1308
1377
|
async deletePullReview(owner, repo, index, reviewId) {
|
|
1309
1378
|
await this.request("DELETE", `/repos/${owner}/${repo}/pulls/${index}/reviews/${reviewId}`);
|
|
1310
1379
|
}
|
|
1311
1380
|
async listPullReviewComments(owner, repo, index, reviewId) {
|
|
1312
1381
|
const results = await this.request("GET", `/repos/${owner}/${repo}/pulls/${index}/reviews/${reviewId}/comments`);
|
|
1313
|
-
|
|
1382
|
+
const comments = results.map((c)=>this.mapPullReviewComment(c));
|
|
1383
|
+
// 通过 GraphQL 补充 resolved 状态
|
|
1384
|
+
try {
|
|
1385
|
+
const resolvedMap = await this.fetchResolvedThreads(owner, repo, index);
|
|
1386
|
+
for (const comment of comments){
|
|
1387
|
+
if (comment.id && resolvedMap.has(comment.id)) {
|
|
1388
|
+
comment.resolver = resolvedMap.get(comment.id) ?? null;
|
|
1389
|
+
}
|
|
1390
|
+
}
|
|
1391
|
+
} catch {
|
|
1392
|
+
// GraphQL 查询失败不影响主流程
|
|
1393
|
+
}
|
|
1394
|
+
return comments;
|
|
1395
|
+
}
|
|
1396
|
+
async deletePullReviewComment(owner, repo, commentId) {
|
|
1397
|
+
await this.request("DELETE", `/repos/${owner}/${repo}/pulls/comments/${commentId}`);
|
|
1314
1398
|
}
|
|
1315
1399
|
// ============ Reaction 操作 ============
|
|
1316
1400
|
async getIssueCommentReactions(owner, repo, commentId) {
|
|
1317
1401
|
const results = await this.request("GET", `/repos/${owner}/${repo}/issues/comments/${commentId}/reactions`);
|
|
1318
1402
|
return results.map((r)=>this.mapReaction(r));
|
|
1319
1403
|
}
|
|
1404
|
+
async getPullReviewCommentReactions(owner, repo, commentId) {
|
|
1405
|
+
const results = await this.request("GET", `/repos/${owner}/${repo}/pulls/comments/${commentId}/reactions`);
|
|
1406
|
+
return results.map((r)=>this.mapReaction(r));
|
|
1407
|
+
}
|
|
1320
1408
|
async getIssueReactions(owner, repo, index) {
|
|
1321
1409
|
const results = await this.request("GET", `/repos/${owner}/${repo}/issues/${index}/reactions`);
|
|
1322
1410
|
return results.map((r)=>this.mapReaction(r));
|
|
@@ -1499,6 +1587,68 @@ function parseDiffText(diffText) {
|
|
|
1499
1587
|
commit_id: data.commit_id
|
|
1500
1588
|
};
|
|
1501
1589
|
}
|
|
1590
|
+
/**
|
|
1591
|
+
* 通过 GraphQL 查询 PR 的 review threads resolved 状态
|
|
1592
|
+
* 返回 Map<commentId, resolver>(用于 listPullReviewComments 内部补充 resolver)
|
|
1593
|
+
*/ async fetchResolvedThreads(owner, repo, prNumber) {
|
|
1594
|
+
const threads = await this.queryReviewThreads(owner, repo, prNumber);
|
|
1595
|
+
const resolvedMap = new Map();
|
|
1596
|
+
for (const thread of threads){
|
|
1597
|
+
if (!thread.isResolved) continue;
|
|
1598
|
+
const firstComment = thread.comments.nodes[0];
|
|
1599
|
+
if (!firstComment?.databaseId) continue;
|
|
1600
|
+
resolvedMap.set(firstComment.databaseId, thread.resolvedBy ? {
|
|
1601
|
+
id: thread.resolvedBy.databaseId,
|
|
1602
|
+
login: thread.resolvedBy.login
|
|
1603
|
+
} : null);
|
|
1604
|
+
}
|
|
1605
|
+
return resolvedMap;
|
|
1606
|
+
}
|
|
1607
|
+
async listResolvedThreads(owner, repo, index) {
|
|
1608
|
+
const threads = await this.queryReviewThreads(owner, repo, index);
|
|
1609
|
+
const result = [];
|
|
1610
|
+
for (const thread of threads){
|
|
1611
|
+
if (!thread.isResolved) continue;
|
|
1612
|
+
result.push({
|
|
1613
|
+
path: thread.path ?? undefined,
|
|
1614
|
+
line: thread.line ?? undefined,
|
|
1615
|
+
resolvedBy: thread.resolvedBy ? {
|
|
1616
|
+
id: thread.resolvedBy.databaseId,
|
|
1617
|
+
login: thread.resolvedBy.login
|
|
1618
|
+
} : null
|
|
1619
|
+
});
|
|
1620
|
+
}
|
|
1621
|
+
return result;
|
|
1622
|
+
}
|
|
1623
|
+
/**
|
|
1624
|
+
* GraphQL 查询 PR 的所有 review threads
|
|
1625
|
+
*/ async queryReviewThreads(owner, repo, prNumber) {
|
|
1626
|
+
const QUERY = `
|
|
1627
|
+
query($owner: String!, $repo: String!, $prNumber: Int!) {
|
|
1628
|
+
repository(owner: $owner, name: $repo) {
|
|
1629
|
+
pullRequest(number: $prNumber) {
|
|
1630
|
+
reviewThreads(first: 100) {
|
|
1631
|
+
nodes {
|
|
1632
|
+
isResolved
|
|
1633
|
+
resolvedBy { login databaseId }
|
|
1634
|
+
path
|
|
1635
|
+
line
|
|
1636
|
+
comments(first: 1) {
|
|
1637
|
+
nodes { databaseId }
|
|
1638
|
+
}
|
|
1639
|
+
}
|
|
1640
|
+
}
|
|
1641
|
+
}
|
|
1642
|
+
}
|
|
1643
|
+
}
|
|
1644
|
+
`;
|
|
1645
|
+
const data = await this.requestGraphQL(QUERY, {
|
|
1646
|
+
owner,
|
|
1647
|
+
repo,
|
|
1648
|
+
prNumber
|
|
1649
|
+
});
|
|
1650
|
+
return data.repository.pullRequest.reviewThreads.nodes;
|
|
1651
|
+
}
|
|
1502
1652
|
mapPullReviewComment(data) {
|
|
1503
1653
|
const user = data.user;
|
|
1504
1654
|
return {
|
|
@@ -1576,12 +1726,12 @@ function parseDiffText(diffText) {
|
|
|
1576
1726
|
}
|
|
1577
1727
|
mapReviewEvent(event) {
|
|
1578
1728
|
const eventMap = {
|
|
1579
|
-
APPROVE:
|
|
1580
|
-
REQUEST_CHANGES:
|
|
1581
|
-
COMMENT:
|
|
1582
|
-
PENDING:
|
|
1729
|
+
[REVIEW_STATE.APPROVE]: REVIEW_STATE.APPROVE,
|
|
1730
|
+
[REVIEW_STATE.REQUEST_CHANGES]: REVIEW_STATE.REQUEST_CHANGES,
|
|
1731
|
+
[REVIEW_STATE.COMMENT]: REVIEW_STATE.COMMENT,
|
|
1732
|
+
[REVIEW_STATE.PENDING]: REVIEW_STATE.PENDING
|
|
1583
1733
|
};
|
|
1584
|
-
return event ? eventMap[event] || event :
|
|
1734
|
+
return event ? eventMap[event] || event : REVIEW_STATE.COMMENT;
|
|
1585
1735
|
}
|
|
1586
1736
|
mapSortParam(sort) {
|
|
1587
1737
|
const sortMap = {
|
|
@@ -1597,6 +1747,7 @@ function parseDiffText(diffText) {
|
|
|
1597
1747
|
|
|
1598
1748
|
;// CONCATENATED MODULE: ./src/shared/git-provider/adapters/gitlab.adapter.ts
|
|
1599
1749
|
|
|
1750
|
+
|
|
1600
1751
|
/**
|
|
1601
1752
|
* GitLab 平台适配器
|
|
1602
1753
|
*
|
|
@@ -1956,7 +2107,7 @@ function parseDiffText(diffText) {
|
|
|
1956
2107
|
return {
|
|
1957
2108
|
id: note.id,
|
|
1958
2109
|
body: note.body,
|
|
1959
|
-
state: options.event ||
|
|
2110
|
+
state: options.event || REVIEW_STATE.COMMENT,
|
|
1960
2111
|
user: note.user,
|
|
1961
2112
|
created_at: note.created_at,
|
|
1962
2113
|
updated_at: note.updated_at
|
|
@@ -1971,13 +2122,13 @@ function parseDiffText(diffText) {
|
|
|
1971
2122
|
}
|
|
1972
2123
|
}
|
|
1973
2124
|
// 如果是 APPROVE 事件,调用 approve API
|
|
1974
|
-
if (options.event ===
|
|
2125
|
+
if (options.event === REVIEW_STATE.APPROVE) {
|
|
1975
2126
|
await this.request("POST", `/projects/${project}/merge_requests/${index}/approve`);
|
|
1976
2127
|
}
|
|
1977
2128
|
return {
|
|
1978
2129
|
id: 0,
|
|
1979
2130
|
body: options.body || "",
|
|
1980
|
-
state: options.event ||
|
|
2131
|
+
state: options.event || REVIEW_STATE.COMMENT
|
|
1981
2132
|
};
|
|
1982
2133
|
}
|
|
1983
2134
|
async listPullReviews(owner, repo, index) {
|
|
@@ -1989,13 +2140,28 @@ function parseDiffText(diffText) {
|
|
|
1989
2140
|
return {
|
|
1990
2141
|
id: note.id,
|
|
1991
2142
|
body: note.body,
|
|
1992
|
-
state:
|
|
2143
|
+
state: REVIEW_STATE.COMMENT,
|
|
1993
2144
|
user: note.user,
|
|
1994
2145
|
created_at: note.created_at,
|
|
1995
2146
|
updated_at: note.updated_at
|
|
1996
2147
|
};
|
|
1997
2148
|
});
|
|
1998
2149
|
}
|
|
2150
|
+
async updatePullReview(owner, repo, index, reviewId, body) {
|
|
2151
|
+
const project = this.encodeProject(owner, repo);
|
|
2152
|
+
const result = await this.request("PUT", `/projects/${project}/merge_requests/${index}/notes/${reviewId}`, {
|
|
2153
|
+
body
|
|
2154
|
+
});
|
|
2155
|
+
return {
|
|
2156
|
+
id: result.id,
|
|
2157
|
+
body: result.body,
|
|
2158
|
+
state: REVIEW_STATE.COMMENT,
|
|
2159
|
+
user: result.author ? {
|
|
2160
|
+
id: result.author.id,
|
|
2161
|
+
login: result.author.username
|
|
2162
|
+
} : undefined
|
|
2163
|
+
};
|
|
2164
|
+
}
|
|
1999
2165
|
async deletePullReview(owner, repo, index, reviewId) {
|
|
2000
2166
|
const project = this.encodeProject(owner, repo);
|
|
2001
2167
|
await this.request("DELETE", `/projects/${project}/merge_requests/${index}/notes/${reviewId}`);
|
|
@@ -2022,11 +2188,26 @@ function parseDiffText(diffText) {
|
|
|
2022
2188
|
};
|
|
2023
2189
|
});
|
|
2024
2190
|
}
|
|
2191
|
+
async deletePullReviewComment(owner, repo, commentId) {
|
|
2192
|
+
// GitLab: 删除 MR note
|
|
2193
|
+
const project = this.encodeProject(owner, repo);
|
|
2194
|
+
// GitLab 删除 note 需要 merge_request_iid,但此处只有 commentId(note_id)
|
|
2195
|
+
// 使用全局 note 删除不可行,需要通过其他方式获取 MR iid
|
|
2196
|
+
// 暂时忽略,GitLab 场景下行级评论删除不常用
|
|
2197
|
+
console.warn(`⚠️ GitLab 暂不支持删除单条 review comment (id: ${commentId}, project: ${project})`);
|
|
2198
|
+
}
|
|
2199
|
+
async listResolvedThreads() {
|
|
2200
|
+
return [];
|
|
2201
|
+
}
|
|
2025
2202
|
// ============ Reaction 操作 ============
|
|
2026
2203
|
async getIssueCommentReactions(_owner, _repo, _commentId) {
|
|
2027
2204
|
// GitLab: award emoji on notes(需要 noteable_iid,此处简化返回空)
|
|
2028
2205
|
return [];
|
|
2029
2206
|
}
|
|
2207
|
+
async getPullReviewCommentReactions(_owner, _repo, _commentId) {
|
|
2208
|
+
// GitLab: award emoji on notes(需要 noteable_iid,此处简化返回空)
|
|
2209
|
+
return [];
|
|
2210
|
+
}
|
|
2030
2211
|
async getIssueReactions(owner, repo, index) {
|
|
2031
2212
|
const project = this.encodeProject(owner, repo);
|
|
2032
2213
|
try {
|
|
@@ -2336,16 +2517,28 @@ function parseDiffText(diffText) {
|
|
|
2336
2517
|
async listPullReviews(owner, repo, index) {
|
|
2337
2518
|
return this.adapter.listPullReviews(owner, repo, index);
|
|
2338
2519
|
}
|
|
2520
|
+
async updatePullReview(owner, repo, index, reviewId, body) {
|
|
2521
|
+
return this.adapter.updatePullReview(owner, repo, index, reviewId, body);
|
|
2522
|
+
}
|
|
2339
2523
|
async deletePullReview(owner, repo, index, reviewId) {
|
|
2340
2524
|
return this.adapter.deletePullReview(owner, repo, index, reviewId);
|
|
2341
2525
|
}
|
|
2342
2526
|
async listPullReviewComments(owner, repo, index, reviewId) {
|
|
2343
2527
|
return this.adapter.listPullReviewComments(owner, repo, index, reviewId);
|
|
2344
2528
|
}
|
|
2529
|
+
async deletePullReviewComment(owner, repo, commentId) {
|
|
2530
|
+
return this.adapter.deletePullReviewComment(owner, repo, commentId);
|
|
2531
|
+
}
|
|
2532
|
+
async listResolvedThreads(owner, repo, index) {
|
|
2533
|
+
return this.adapter.listResolvedThreads(owner, repo, index);
|
|
2534
|
+
}
|
|
2345
2535
|
// ============ Reaction 操作 ============
|
|
2346
2536
|
async getIssueCommentReactions(owner, repo, commentId) {
|
|
2347
2537
|
return this.adapter.getIssueCommentReactions(owner, repo, commentId);
|
|
2348
2538
|
}
|
|
2539
|
+
async getPullReviewCommentReactions(owner, repo, commentId) {
|
|
2540
|
+
return this.adapter.getPullReviewCommentReactions(owner, repo, commentId);
|
|
2541
|
+
}
|
|
2349
2542
|
async getIssueReactions(owner, repo, index) {
|
|
2350
2543
|
return this.adapter.getIssueReactions(owner, repo, index);
|
|
2351
2544
|
}
|
|
@@ -6563,6 +6756,7 @@ var __webpack_exports__DEFAULT_EDITOR = __webpack_exports__.e1;
|
|
|
6563
6756
|
var __webpack_exports__DEFAULT_EXTERNALS = __webpack_exports__.pk;
|
|
6564
6757
|
var __webpack_exports__DEFAULT_SUPPORT_EDITOR = __webpack_exports__.IO;
|
|
6565
6758
|
var __webpack_exports__DEFAULT_TS_RULE = __webpack_exports__.Pd;
|
|
6759
|
+
var __webpack_exports__DIFF_SIDE = __webpack_exports__.my;
|
|
6566
6760
|
var __webpack_exports__EDITOR_DIR_MAPPING = __webpack_exports__.R8;
|
|
6567
6761
|
var __webpack_exports__FEISHU_CARD_ACTION_TRIGGER = __webpack_exports__.o6;
|
|
6568
6762
|
var __webpack_exports__FEISHU_MODULE_OPTIONS = __webpack_exports__.jB;
|
|
@@ -6595,6 +6789,7 @@ var __webpack_exports__OutputService = __webpack_exports__.PA;
|
|
|
6595
6789
|
var __webpack_exports__PACKAGE_JSON = __webpack_exports__.QO;
|
|
6596
6790
|
var __webpack_exports__ParallelExecutor = __webpack_exports__.Zz;
|
|
6597
6791
|
var __webpack_exports__RC_FILE_NAME = __webpack_exports__.vr;
|
|
6792
|
+
var __webpack_exports__REVIEW_STATE = __webpack_exports__.fS;
|
|
6598
6793
|
var __webpack_exports__SPACEFLOW_DIR = __webpack_exports__.xC;
|
|
6599
6794
|
var __webpack_exports__SchemaGeneratorService = __webpack_exports__.go;
|
|
6600
6795
|
var __webpack_exports__StorageService = __webpack_exports__.n$;
|
|
@@ -6668,6 +6863,6 @@ var __webpack_exports__toLogLevel = __webpack_exports__.AZ;
|
|
|
6668
6863
|
var __webpack_exports__updateDependency = __webpack_exports__.hq;
|
|
6669
6864
|
var __webpack_exports__writeConfigSync = __webpack_exports__.$v;
|
|
6670
6865
|
var __webpack_exports__z = __webpack_exports__.z;
|
|
6671
|
-
export { __webpack_exports__CONFIG_FILE_NAME as CONFIG_FILE_NAME, __webpack_exports__ClaudeCodeAdapter as ClaudeCodeAdapter, __webpack_exports__ClaudeSetupService as ClaudeSetupService, __webpack_exports__ConfigReader as ConfigReader, __webpack_exports__ConfigReaderService as ConfigReaderService, __webpack_exports__DEFAULT_EDITOR as DEFAULT_EDITOR, __webpack_exports__DEFAULT_EXTERNALS as DEFAULT_EXTERNALS, __webpack_exports__DEFAULT_SUPPORT_EDITOR as DEFAULT_SUPPORT_EDITOR, __webpack_exports__DEFAULT_TS_RULE as DEFAULT_TS_RULE, __webpack_exports__EDITOR_DIR_MAPPING as EDITOR_DIR_MAPPING, __webpack_exports__FEISHU_CARD_ACTION_TRIGGER as FEISHU_CARD_ACTION_TRIGGER, __webpack_exports__FEISHU_MODULE_OPTIONS as FEISHU_MODULE_OPTIONS, __webpack_exports__FeishuCardService as FeishuCardService, __webpack_exports__FeishuSdkService as FeishuSdkService, __webpack_exports__FileAdapter as FileAdapter, __webpack_exports__GIT_PROVIDER_MODULE_OPTIONS as GIT_PROVIDER_MODULE_OPTIONS, __webpack_exports__GitProviderService as GitProviderService, __webpack_exports__GitSdkService as GitSdkService, __webpack_exports__GiteaAdapter as GiteaAdapter, __webpack_exports__GithubAdapter as GithubAdapter, __webpack_exports__GitlabAdapter as GitlabAdapter, __webpack_exports__LLM_ADAPTER as LLM_ADAPTER, __webpack_exports__LLM_PROXY_CONFIG as LLM_PROXY_CONFIG, __webpack_exports__LOG_LEVEL_PRIORITY as LOG_LEVEL_PRIORITY, __webpack_exports__LlmJsonPut as LlmJsonPut, __webpack_exports__LlmProxyService as LlmProxyService, __webpack_exports__LlmSessionImpl as LlmSessionImpl, __webpack_exports__Logger as Logger, __webpack_exports__MCP_SERVER_METADATA as MCP_SERVER_METADATA, __webpack_exports__MCP_TOOL_METADATA as MCP_TOOL_METADATA, __webpack_exports__McpServer as McpServer, __webpack_exports__McpTool as McpTool, __webpack_exports__MemoryAdapter as MemoryAdapter, __webpack_exports__OUTPUT_MARKER_END as OUTPUT_MARKER_END, __webpack_exports__OUTPUT_MARKER_START as OUTPUT_MARKER_START, __webpack_exports__OpenAIAdapter as OpenAIAdapter, __webpack_exports__OpenCodeAdapter as OpenCodeAdapter, __webpack_exports__OutputService as OutputService, __webpack_exports__PACKAGE_JSON as PACKAGE_JSON, __webpack_exports__ParallelExecutor as ParallelExecutor, __webpack_exports__RC_FILE_NAME as RC_FILE_NAME, __webpack_exports__SPACEFLOW_DIR as SPACEFLOW_DIR, __webpack_exports__SchemaGeneratorService as SchemaGeneratorService, __webpack_exports__StorageService as StorageService, __webpack_exports__addLocaleResources as addLocaleResources, __webpack_exports__addSpaceflowToDevDependencies as addSpaceflowToDevDependencies, __webpack_exports__buildGitPackageSpec as buildGitPackageSpec, __webpack_exports__calculateLineOffsets as calculateLineOffsets, __webpack_exports__calculateNewLineNumber as calculateNewLineNumber, __webpack_exports__ciConfig as ciConfig, __webpack_exports__configLoaders as configLoaders, __webpack_exports__createConfigLoader as createConfigLoader, __webpack_exports__createEnvConfigLoader as createEnvConfigLoader, __webpack_exports__createMultiEntryPluginConfig as createMultiEntryPluginConfig, __webpack_exports__createPluginConfig as createPluginConfig, __webpack_exports__createStreamLoggerState as createStreamLoggerState, __webpack_exports__defineExtension as defineExtension, __webpack_exports__defineMcpServer as defineMcpServer, __webpack_exports__detectPackageManager as detectPackageManager, __webpack_exports__detectProvider as detectProvider, __webpack_exports__dtoToJsonSchema as dtoToJsonSchema, __webpack_exports__ensureEditorGitignore as ensureEditorGitignore, __webpack_exports__ensureSpaceflowDir as ensureSpaceflowDir, __webpack_exports__ensureSpaceflowPackageJson as ensureSpaceflowPackageJson, __webpack_exports__extractName as extractName, __webpack_exports__extractNpmPackageName as extractNpmPackageName, __webpack_exports__feishuConfig as feishuConfig, __webpack_exports__getConfigPath as getConfigPath, __webpack_exports__getConfigPaths as getConfigPaths, __webpack_exports__getDependencies as getDependencies, __webpack_exports__getEditorDirName as getEditorDirName, __webpack_exports__getEnvFilePaths as getEnvFilePaths, __webpack_exports__getMcpServerMetadata as getMcpServerMetadata, __webpack_exports__getMcpTools as getMcpTools, __webpack_exports__getPackageManager as getPackageManager, __webpack_exports__getRegisteredPluginConfig as getRegisteredPluginConfig, __webpack_exports__getRegisteredSchemas as getRegisteredSchemas, __webpack_exports__getSourceType as getSourceType, __webpack_exports__getSpaceflowCliPath as getSpaceflowCliPath, __webpack_exports__getSpaceflowDir as getSpaceflowDir, __webpack_exports__getSupportedEditors as getSupportedEditors, __webpack_exports__gitProviderConfig as gitProviderConfig, __webpack_exports__initI18n as initI18n, __webpack_exports__isGitUrl as isGitUrl, __webpack_exports__isLocalPath as isLocalPath, __webpack_exports__isMcpServer as isMcpServer, __webpack_exports__isPnpmWorkspace as isPnpmWorkspace, __webpack_exports__llmConfig as llmConfig, __webpack_exports__loadEnvFiles as loadEnvFiles, __webpack_exports__loadSpaceflowConfig as loadSpaceflowConfig, __webpack_exports__logStreamEvent as logStreamEvent, __webpack_exports__mapGitStatus as mapGitStatus, __webpack_exports__normalizeSource as normalizeSource, __webpack_exports__normalizeVerbose as normalizeVerbose, __webpack_exports__parallel as parallel, __webpack_exports__parseChangedLinesFromPatch as parseChangedLinesFromPatch, __webpack_exports__parseDiffText as parseDiffText, __webpack_exports__parseHunksFromPatch as parseHunksFromPatch, __webpack_exports__parseRepoUrl as parseRepoUrl, __webpack_exports__parseVerbose as parseVerbose, __webpack_exports__readConfigSync as readConfigSync, __webpack_exports__registerPluginConfig as registerPluginConfig, __webpack_exports__registerPluginSchema as registerPluginSchema, __webpack_exports__removeDependency as removeDependency, __webpack_exports__resolveSpaceflowConfig as resolveSpaceflowConfig, __webpack_exports__runMcpServer as runMcpServer, __webpack_exports__shouldLog as shouldLog, __webpack_exports__spaceflowConfig as spaceflowConfig, __webpack_exports__storageConfig as storageConfig, __webpack_exports__t as t, __webpack_exports__toLogLevel as toLogLevel, __webpack_exports__updateDependency as updateDependency, __webpack_exports__writeConfigSync as writeConfigSync, __webpack_exports__z as z };
|
|
6866
|
+
export { __webpack_exports__CONFIG_FILE_NAME as CONFIG_FILE_NAME, __webpack_exports__ClaudeCodeAdapter as ClaudeCodeAdapter, __webpack_exports__ClaudeSetupService as ClaudeSetupService, __webpack_exports__ConfigReader as ConfigReader, __webpack_exports__ConfigReaderService as ConfigReaderService, __webpack_exports__DEFAULT_EDITOR as DEFAULT_EDITOR, __webpack_exports__DEFAULT_EXTERNALS as DEFAULT_EXTERNALS, __webpack_exports__DEFAULT_SUPPORT_EDITOR as DEFAULT_SUPPORT_EDITOR, __webpack_exports__DEFAULT_TS_RULE as DEFAULT_TS_RULE, __webpack_exports__DIFF_SIDE as DIFF_SIDE, __webpack_exports__EDITOR_DIR_MAPPING as EDITOR_DIR_MAPPING, __webpack_exports__FEISHU_CARD_ACTION_TRIGGER as FEISHU_CARD_ACTION_TRIGGER, __webpack_exports__FEISHU_MODULE_OPTIONS as FEISHU_MODULE_OPTIONS, __webpack_exports__FeishuCardService as FeishuCardService, __webpack_exports__FeishuSdkService as FeishuSdkService, __webpack_exports__FileAdapter as FileAdapter, __webpack_exports__GIT_PROVIDER_MODULE_OPTIONS as GIT_PROVIDER_MODULE_OPTIONS, __webpack_exports__GitProviderService as GitProviderService, __webpack_exports__GitSdkService as GitSdkService, __webpack_exports__GiteaAdapter as GiteaAdapter, __webpack_exports__GithubAdapter as GithubAdapter, __webpack_exports__GitlabAdapter as GitlabAdapter, __webpack_exports__LLM_ADAPTER as LLM_ADAPTER, __webpack_exports__LLM_PROXY_CONFIG as LLM_PROXY_CONFIG, __webpack_exports__LOG_LEVEL_PRIORITY as LOG_LEVEL_PRIORITY, __webpack_exports__LlmJsonPut as LlmJsonPut, __webpack_exports__LlmProxyService as LlmProxyService, __webpack_exports__LlmSessionImpl as LlmSessionImpl, __webpack_exports__Logger as Logger, __webpack_exports__MCP_SERVER_METADATA as MCP_SERVER_METADATA, __webpack_exports__MCP_TOOL_METADATA as MCP_TOOL_METADATA, __webpack_exports__McpServer as McpServer, __webpack_exports__McpTool as McpTool, __webpack_exports__MemoryAdapter as MemoryAdapter, __webpack_exports__OUTPUT_MARKER_END as OUTPUT_MARKER_END, __webpack_exports__OUTPUT_MARKER_START as OUTPUT_MARKER_START, __webpack_exports__OpenAIAdapter as OpenAIAdapter, __webpack_exports__OpenCodeAdapter as OpenCodeAdapter, __webpack_exports__OutputService as OutputService, __webpack_exports__PACKAGE_JSON as PACKAGE_JSON, __webpack_exports__ParallelExecutor as ParallelExecutor, __webpack_exports__RC_FILE_NAME as RC_FILE_NAME, __webpack_exports__REVIEW_STATE as REVIEW_STATE, __webpack_exports__SPACEFLOW_DIR as SPACEFLOW_DIR, __webpack_exports__SchemaGeneratorService as SchemaGeneratorService, __webpack_exports__StorageService as StorageService, __webpack_exports__addLocaleResources as addLocaleResources, __webpack_exports__addSpaceflowToDevDependencies as addSpaceflowToDevDependencies, __webpack_exports__buildGitPackageSpec as buildGitPackageSpec, __webpack_exports__calculateLineOffsets as calculateLineOffsets, __webpack_exports__calculateNewLineNumber as calculateNewLineNumber, __webpack_exports__ciConfig as ciConfig, __webpack_exports__configLoaders as configLoaders, __webpack_exports__createConfigLoader as createConfigLoader, __webpack_exports__createEnvConfigLoader as createEnvConfigLoader, __webpack_exports__createMultiEntryPluginConfig as createMultiEntryPluginConfig, __webpack_exports__createPluginConfig as createPluginConfig, __webpack_exports__createStreamLoggerState as createStreamLoggerState, __webpack_exports__defineExtension as defineExtension, __webpack_exports__defineMcpServer as defineMcpServer, __webpack_exports__detectPackageManager as detectPackageManager, __webpack_exports__detectProvider as detectProvider, __webpack_exports__dtoToJsonSchema as dtoToJsonSchema, __webpack_exports__ensureEditorGitignore as ensureEditorGitignore, __webpack_exports__ensureSpaceflowDir as ensureSpaceflowDir, __webpack_exports__ensureSpaceflowPackageJson as ensureSpaceflowPackageJson, __webpack_exports__extractName as extractName, __webpack_exports__extractNpmPackageName as extractNpmPackageName, __webpack_exports__feishuConfig as feishuConfig, __webpack_exports__getConfigPath as getConfigPath, __webpack_exports__getConfigPaths as getConfigPaths, __webpack_exports__getDependencies as getDependencies, __webpack_exports__getEditorDirName as getEditorDirName, __webpack_exports__getEnvFilePaths as getEnvFilePaths, __webpack_exports__getMcpServerMetadata as getMcpServerMetadata, __webpack_exports__getMcpTools as getMcpTools, __webpack_exports__getPackageManager as getPackageManager, __webpack_exports__getRegisteredPluginConfig as getRegisteredPluginConfig, __webpack_exports__getRegisteredSchemas as getRegisteredSchemas, __webpack_exports__getSourceType as getSourceType, __webpack_exports__getSpaceflowCliPath as getSpaceflowCliPath, __webpack_exports__getSpaceflowDir as getSpaceflowDir, __webpack_exports__getSupportedEditors as getSupportedEditors, __webpack_exports__gitProviderConfig as gitProviderConfig, __webpack_exports__initI18n as initI18n, __webpack_exports__isGitUrl as isGitUrl, __webpack_exports__isLocalPath as isLocalPath, __webpack_exports__isMcpServer as isMcpServer, __webpack_exports__isPnpmWorkspace as isPnpmWorkspace, __webpack_exports__llmConfig as llmConfig, __webpack_exports__loadEnvFiles as loadEnvFiles, __webpack_exports__loadSpaceflowConfig as loadSpaceflowConfig, __webpack_exports__logStreamEvent as logStreamEvent, __webpack_exports__mapGitStatus as mapGitStatus, __webpack_exports__normalizeSource as normalizeSource, __webpack_exports__normalizeVerbose as normalizeVerbose, __webpack_exports__parallel as parallel, __webpack_exports__parseChangedLinesFromPatch as parseChangedLinesFromPatch, __webpack_exports__parseDiffText as parseDiffText, __webpack_exports__parseHunksFromPatch as parseHunksFromPatch, __webpack_exports__parseRepoUrl as parseRepoUrl, __webpack_exports__parseVerbose as parseVerbose, __webpack_exports__readConfigSync as readConfigSync, __webpack_exports__registerPluginConfig as registerPluginConfig, __webpack_exports__registerPluginSchema as registerPluginSchema, __webpack_exports__removeDependency as removeDependency, __webpack_exports__resolveSpaceflowConfig as resolveSpaceflowConfig, __webpack_exports__runMcpServer as runMcpServer, __webpack_exports__shouldLog as shouldLog, __webpack_exports__spaceflowConfig as spaceflowConfig, __webpack_exports__storageConfig as storageConfig, __webpack_exports__t as t, __webpack_exports__toLogLevel as toLogLevel, __webpack_exports__updateDependency as updateDependency, __webpack_exports__writeConfigSync as writeConfigSync, __webpack_exports__z as z };
|
|
6672
6867
|
|
|
6673
6868
|
//# sourceMappingURL=index.js.map
|