From 44296e529368140ec06a937383e05f3074b19ee2 Mon Sep 17 00:00:00 2001 From: Niklas von Hertzen Date: Sun, 11 Jul 2021 22:11:29 +0800 Subject: [PATCH] fix: text-decoration-line fallback (#2088) (#2567) --- src/css/index.ts | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/css/index.ts b/src/css/index.ts index fd3ef68..af794d6 100644 --- a/src/css/index.ts +++ b/src/css/index.ts @@ -191,8 +191,11 @@ export class CSSParsedDeclaration { this.paddingLeft = parse(paddingLeft, declaration.paddingLeft); this.position = parse(position, declaration.position); this.textAlign = parse(textAlign, declaration.textAlign); - this.textDecorationColor = parse(textDecorationColor, declaration.textDecorationColor || declaration.color); - this.textDecorationLine = parse(textDecorationLine, declaration.textDecorationLine); + this.textDecorationColor = parse(textDecorationColor, declaration.textDecorationColor ?? declaration.color); + this.textDecorationLine = parse( + textDecorationLine, + declaration.textDecorationLine ?? declaration.textDecoration + ); this.textShadow = parse(textShadow, declaration.textShadow); this.textTransform = parse(textTransform, declaration.textTransform); this.transform = parse(transform, declaration.transform);