Localize user-facing UI, agent output, and backend messages to Simplified Chinese
ci / go (push) Waiting to run
ci / go-db (agent) (push) Waiting to run
ci / go-db (config) (push) Waiting to run
ci / go-db (db) (push) Waiting to run
ci / go-db (evidence) (push) Waiting to run
ci / go-db (llmrec) (push) Waiting to run
ci / go-db (server) (push) Waiting to run
detections / detections (push) Waiting to run
docs / links (push) Waiting to run
web / web (push) Waiting to run
ci / go (push) Waiting to run
ci / go-db (agent) (push) Waiting to run
ci / go-db (config) (push) Waiting to run
ci / go-db (db) (push) Waiting to run
ci / go-db (evidence) (push) Waiting to run
ci / go-db (llmrec) (push) Waiting to run
ci / go-db (server) (push) Waiting to run
detections / detections (push) Waiting to run
docs / links (push) Waiting to run
web / web (push) Waiting to run
This commit is contained in:
+8
-8
@@ -43,7 +43,7 @@ func htmlBody(m Message, maxRunes int) string {
|
||||
b.WriteString(htmlItem(m.Items[0], true))
|
||||
}
|
||||
if m.HomeURL != "" {
|
||||
fmt.Fprintf(&b, `<p style="margin:16px 0 0;"><a href="%s" style="color:#1677ff;">플랫폼에서 전체 보기</a></p>`, htmlEscapeAttr(m.HomeURL))
|
||||
fmt.Fprintf(&b, `<p style="margin:16px 0 0;"><a href="%s" style="color:#1677ff;">在平台查看全部</a></p>`, htmlEscapeAttr(m.HomeURL))
|
||||
}
|
||||
b.WriteString(`</div>`)
|
||||
return TruncateHTML(b.String(), maxRunes)
|
||||
@@ -53,9 +53,9 @@ func htmlBody(m Message, maxRunes int) string {
|
||||
func htmlBatchIntro(m Message) string {
|
||||
var b strings.Builder
|
||||
if m.WindowMinutes > 0 {
|
||||
fmt.Fprintf(&b, `<h2 style="font-size:16px;margin:0 0 4px;">최근 %d분간 신규 취약점 %d건</h2>`, m.WindowMinutes, len(m.Items))
|
||||
fmt.Fprintf(&b, `<h2 style="font-size:16px;margin:0 0 4px;">最近 %d 分钟新增漏洞 %d 条</h2>`, m.WindowMinutes, len(m.Items))
|
||||
} else {
|
||||
fmt.Fprintf(&b, `<h2 style="font-size:16px;margin:0 0 4px;">신규 취약점 %d건</h2>`, len(m.Items))
|
||||
fmt.Fprintf(&b, `<h2 style="font-size:16px;margin:0 0 4px;">新增漏洞 %d 条</h2>`, len(m.Items))
|
||||
}
|
||||
counts := map[string]int{}
|
||||
for _, it := range m.Items {
|
||||
@@ -103,20 +103,20 @@ func htmlItem(it Item, full bool) string {
|
||||
}
|
||||
|
||||
if it.IsStatusChange() {
|
||||
fmt.Fprintf(&b, `<div><b>상태 변경</b>: %s → %s</div>`,
|
||||
fmt.Fprintf(&b, `<div><b>状态变更</b>:%s → %s</div>`,
|
||||
htmlEscape(StatusLabel(it.FromStatus)), htmlEscape(StatusLabel(it.ToStatus)))
|
||||
}
|
||||
if it.VulnClass != "" && it.VulnClass != it.Title() {
|
||||
fmt.Fprintf(&b, `<div><b>유형</b>: %s</div>`, htmlEscape(it.VulnClass))
|
||||
fmt.Fprintf(&b, `<div><b>类型</b>:%s</div>`, htmlEscape(it.VulnClass))
|
||||
}
|
||||
if a := assetLine(it.Assets, maxAssetsShown); a != "" {
|
||||
fmt.Fprintf(&b, `<div><b>자산</b>: %s</div>`, htmlEscape(a))
|
||||
fmt.Fprintf(&b, `<div><b>资产</b>:%s</div>`, htmlEscape(a))
|
||||
}
|
||||
if s := OneLine(it.Summary, maxSummaryRunes); s != "" {
|
||||
fmt.Fprintf(&b, `<div><b>개요</b>: %s</div>`, htmlEscape(s))
|
||||
fmt.Fprintf(&b, `<div><b>概要</b>:%s</div>`, htmlEscape(s))
|
||||
}
|
||||
if it.DetailURL != "" {
|
||||
fmt.Fprintf(&b, `<div style="margin-top:6px;"><a href="%s" style="color:#1677ff;">상세 보기</a></div>`, htmlEscapeAttr(it.DetailURL))
|
||||
fmt.Fprintf(&b, `<div style="margin-top:6px;"><a href="%s" style="color:#1677ff;">查看详情</a></div>`, htmlEscapeAttr(it.DetailURL))
|
||||
}
|
||||
b.WriteString(`</div>`)
|
||||
return b.String()
|
||||
|
||||
Reference in New Issue
Block a user