From 68c727d13c9a951f8e792334850bd91aac411c42 Mon Sep 17 00:00:00 2001 From: Yossi Saadi Date: Tue, 17 Dec 2024 14:42:23 +0200 Subject: [PATCH] feat(StatusTag): allow New tag --- .../components/status-tag/__stories__/status-tag.stories.tsx | 1 + .../src/components/status-tag/status-tag.module.scss | 5 +++++ .../src/components/status-tag/status-tag.tsx | 3 ++- 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/packages/storybook-blocks/src/components/status-tag/__stories__/status-tag.stories.tsx b/packages/storybook-blocks/src/components/status-tag/__stories__/status-tag.stories.tsx index 93b89af6ad..3b3f5a486a 100644 --- a/packages/storybook-blocks/src/components/status-tag/__stories__/status-tag.stories.tsx +++ b/packages/storybook-blocks/src/components/status-tag/__stories__/status-tag.stories.tsx @@ -21,6 +21,7 @@ export const Types: Story = { + ), diff --git a/packages/storybook-blocks/src/components/status-tag/status-tag.module.scss b/packages/storybook-blocks/src/components/status-tag/status-tag.module.scss index 3bd3f150de..761ae6cbda 100644 --- a/packages/storybook-blocks/src/components/status-tag/status-tag.module.scss +++ b/packages/storybook-blocks/src/components/status-tag/status-tag.module.scss @@ -9,6 +9,11 @@ border-color: var(--sb-brand-color); } + &.new { + color: var(--sb-positive-color); + border-color: var(--sb-positive-color); + } + &.deprecated { color: var(--sb-negative-color); border-color: var(--sb-negative-color); diff --git a/packages/storybook-blocks/src/components/status-tag/status-tag.tsx b/packages/storybook-blocks/src/components/status-tag/status-tag.tsx index 0d0986c7a6..8031706ddc 100644 --- a/packages/storybook-blocks/src/components/status-tag/status-tag.tsx +++ b/packages/storybook-blocks/src/components/status-tag/status-tag.tsx @@ -2,13 +2,14 @@ import { FC } from 'react'; import styles from './status-tag.module.scss'; import cx from 'classnames'; -export type StatusTagType = 'alpha' | 'beta' | 'deprecated'; +export type StatusTagType = 'alpha' | 'beta' | 'new' | 'deprecated'; interface StatusTagProps { type: StatusTagType; } const StatusTag: FC = ({ type }) => { + console.log('type', type); return ; };