From fdebe0d0fe7d4e238578ede6b6d0b85f63321bc0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E8=97=8D+85CD?= <50108258+kwaa@users.noreply.github.com> Date: Fri, 27 Oct 2023 00:02:32 +0800 Subject: [PATCH] =?UTF-8?q?refactor(shiraha-ve):=20=F0=9F=92=84=20update?= =?UTF-8?q?=20text-wrap?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- packages/shiraha-ve/src/base/html.global.css.ts | 1 + .../shiraha-ve/src/typography/heading/styles.ts | 17 +++++------------ 2 files changed, 6 insertions(+), 12 deletions(-) diff --git a/packages/shiraha-ve/src/base/html.global.css.ts b/packages/shiraha-ve/src/base/html.global.css.ts index 4133812..bfc1e7d 100644 --- a/packages/shiraha-ve/src/base/html.global.css.ts +++ b/packages/shiraha-ve/src/base/html.global.css.ts @@ -13,6 +13,7 @@ globalStyle('html', { lineHeight: 1.5, overflowWrap: 'break-word', tabSize: 4, + textWrap: 'pretty', wordWrap: 'break-word', }) diff --git a/packages/shiraha-ve/src/typography/heading/styles.ts b/packages/shiraha-ve/src/typography/heading/styles.ts index 11eb312..f0f9ab2 100644 --- a/packages/shiraha-ve/src/typography/heading/styles.ts +++ b/packages/shiraha-ve/src/typography/heading/styles.ts @@ -3,18 +3,11 @@ import type { ComplexStyleRule } from '@vanilla-extract/css' import OP from 'open-props' export const h = { - '@supports': { - '(text-wrap: pretty)': { - textWrap: 'pretty', - }, - 'not (text-wrap: pretty)': { - textWrap: 'balance', - }, - }, - 'fontWeight': OP.fontWeight6, - 'letterSpacing': '-0.025em', - 'paddingBottom': 8, - 'scrollMargin': 80, + fontWeight: OP.fontWeight6, + letterSpacing: '-0.025em', + paddingBottom: 8, + scrollMargin: 80, + textWrap: 'balance', } as const satisfies ComplexStyleRule export const h123NotFirstChild = {