From 673d689de21f6d5d31f17e864b585c8d546e2d83 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9C=A8=E8=8D=A3?= <372638156@qq.com> Date: Mon, 4 Jul 2022 11:38:37 +0800 Subject: [PATCH] fix(useCssVar): remove spaces at both ends fix #1738 --- packages/core/useCssVar/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/core/useCssVar/index.ts b/packages/core/useCssVar/index.ts index e51a52a34ee..1ba0da3379a 100644 --- a/packages/core/useCssVar/index.ts +++ b/packages/core/useCssVar/index.ts @@ -25,7 +25,7 @@ export function useCssVar( [elRef, () => unref(prop)], ([el, prop]) => { if (el && window) - variable.value = window.getComputedStyle(el).getPropertyValue(prop) + variable.value = window.getComputedStyle(el).getPropertyValue(prop).trimStart().trimEnd() }, { immediate: true }, )