feat(chat): 区分角色对白与故事叙述

- digital-message.tsx: 统一流式与完成态展示,保留用户纯文本和停止后的尾部
- digital-message-format.ts: 解析星号叙述、中英文对白及旧版括号格式
- digital-home.tsx、digital.css: 接入独立消息组件并区分对白与叙述样式
- tests、README.md: 补齐累计流式、旧消息和文本安全回归及中文说明
This commit is contained in:
湛兮
2026-10-27 22:19:05 +08:00
parent cb5e004eb9
commit ebb8a50eb6
6 changed files with 388 additions and 66 deletions
+22
View File
@@ -1701,6 +1701,28 @@
font-size: 14px;
color: #e6dfe7;
}
.dh-message-prose {
white-space: normal;
}
.dh-message-prose > p {
margin: 0;
white-space: pre-wrap;
}
.dh-message-prose > p + p {
margin-top: 12px;
}
.dh-prose-dialogue {
color: #fff5fc;
}
.dh-prose-dialogue strong {
font-weight: 600;
}
.dh-prose-narration {
color: #c2b6c4;
}
.dh-prose-narration.dh-prose-latin {
font-style: italic;
}
.dh-message-user {
justify-content: flex-end;
}