@cnbcool/cnb-api-generate 2.17.0 → 2.17.1
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.
|
@@ -12,11 +12,13 @@ type SummaryExtractor = (item: any) => any;
|
|
|
12
12
|
* - 数组响应:对 data 中每个元素应用提取函数
|
|
13
13
|
*/
|
|
14
14
|
const SUMMARY_EXTRACTORS: Record<string, SummaryExtractor> = {
|
|
15
|
-
// Issue
|
|
15
|
+
// Issue 详情摘要:保留标题、状态、私密性、标签和正文
|
|
16
16
|
// 过滤: number, state_reason, assignees, author, created_at, updated_at 等
|
|
17
17
|
'issues/get-issue': (item) => ({
|
|
18
18
|
title: item.title,
|
|
19
19
|
state: item.state,
|
|
20
|
+
// Preserve the API privacy value; missing must not become false.
|
|
21
|
+
invisible: item.invisible,
|
|
20
22
|
labels: item.labels?.map?.((l: any) => l.name).filter(Boolean) || [],
|
|
21
23
|
body: item.body,
|
|
22
24
|
}),
|