feat: 实现 DOCX 主题令牌归一化

This commit is contained in:
SkyJourney
2026-07-30 22:57:46 +08:00
parent d2acc9c5ce
commit 7f72258126
18 changed files with 1571 additions and 25 deletions
@@ -47,7 +47,7 @@ describe("DOCX 主题映射配置", () => {
})
);
expect(result).toMatchObject({
mode: "explicit",
mode: "auto-with-overrides",
basePreset: "technical",
overrides: { body: { sizePt: 11 } },
legacyPreset: true
@@ -88,6 +88,7 @@ describe("DOCX 主题引擎契约", () => {
lineHeight: "24px",
letterSpacing: "normal",
textAlign: "start",
direction: "ltr",
textIndent: "0px",
textDecorationLine: "none",
marginTop: "0px",
@@ -104,10 +105,17 @@ describe("DOCX 主题引擎契约", () => {
borderLeft: "0px none rgb(0, 0, 0)",
width: "100px",
maxWidth: "none",
minHeight: "0px",
height: "24px",
breakBefore: "auto",
breakAfter: "auto",
breakInside: "auto",
display: "block"
display: "block",
flexDirection: "row",
alignItems: "normal",
justifyContent: "normal",
outline: "0px none rgb(0, 0, 0)",
outlineOffset: "0px"
};
const result = docxThemeStyleSnapshotSchema.safeParse({
schemaVersion: 1,