From eed6089190f99b7f43368f340ae5492b981ab680 Mon Sep 17 00:00:00 2001 From: leonlai257 Date: Fri, 19 Jan 2024 01:18:24 -0500 Subject: [PATCH] feat(fix,-test): fixed some config, added a text for testing config --- package.json | 2 +- src/atoms/input.ts | 2 +- src/atoms/text.ts | 1 - src/atoms/textConfig.ts | 46 +++++++++++++++++++++++++++++++++++++++++ 4 files changed, 48 insertions(+), 3 deletions(-) create mode 100644 src/atoms/textConfig.ts diff --git a/package.json b/package.json index f644772..4e7da86 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@sidan-lab/sidan-ui", "description": "UI library from SIDAN Lab", - "version": "0.0.2", + "version": "0.0.3", "license": "Apache-2.0", "main": "dist/cjs/index.js", "module": "dist/mjs/index.js", diff --git a/src/atoms/input.ts b/src/atoms/input.ts index 757e049..a1da434 100644 --- a/src/atoms/input.ts +++ b/src/atoms/input.ts @@ -1,6 +1,6 @@ import { styled } from '../styles'; -export const InputField = styled('input', { +export const Input = styled('input', { boxShadow: 'none', borderStyle: 'none', border: '1px solid', diff --git a/src/atoms/text.ts b/src/atoms/text.ts index 048f29f..ade7255 100644 --- a/src/atoms/text.ts +++ b/src/atoms/text.ts @@ -3,7 +3,6 @@ import { styled } from '../styles'; export const Text = styled('div', { my: 'auto', textAlign: 'center', - fontFamily: '$primary', whiteSpace: 'nowrap', variants: { diff --git a/src/atoms/textConfig.ts b/src/atoms/textConfig.ts new file mode 100644 index 0000000..48c3df3 --- /dev/null +++ b/src/atoms/textConfig.ts @@ -0,0 +1,46 @@ +import { styled } from '../styles'; + +export const TextConfig = styled('div', { + my: 'auto', + textAlign: 'center', + whiteSpace: 'nowrap', + color: '$primary', + + variants: { + responsive: { + welcome: { + text: ['24px', '24px', '40px', '64px'], + fontWeight: 700, + }, + title: { + text: ['16px', '20px', '24px'], + fontWeight: 700, + }, + description: { + text: ['12px', '12px', '14px', '18px'], + }, + }, + style: { + warning: { + text: ['14px'], + fontWeight: 400, + color: '#FF9800', + }, + info: { + text: ['14px'], + fontWeight: 400, + color: '#2196F3', + }, + danger: { + text: ['14px'], + fontWeight: 400, + color: '#F44336', + }, + success: { + text: ['14px'], + fontWeight: 400, + color: '#04AA6D', + }, + }, + }, +});