@youngonesworks/ui 1.0.7 → 1.0.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
interface IBadgeProps {
|
|
2
|
-
styleVariant?: 'green-light' | 'red' | 'accent-blue' | 'warning' | 'gray' | 'black' | 'dark-gray' | 'purple' | 'secondary' | 'secondary-light' | 'gray' | 'white';
|
|
2
|
+
styleVariant?: 'primary' | 'green-light' | 'red' | 'accent-blue' | 'warning' | 'gray' | 'black' | 'dark-gray' | 'purple' | 'purple-light' | 'secondary' | 'secondary-light' | 'gray' | 'white';
|
|
3
3
|
color?: 'dark' | 'gray' | 'red' | 'secondary' | 'grape' | 'violet' | 'indigo' | 'blue' | 'cyan' | 'green' | 'lime' | 'yellow' | 'orange' | 'teal';
|
|
4
4
|
favorite?: boolean;
|
|
5
5
|
children?: React.ReactNode;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { Ref, RefCallback } from 'react';
|
|
1
|
+
import { type Ref, type RefCallback } from 'react';
|
|
2
2
|
export declare function useMergeRefs<T>(...refs: (Ref<T> | undefined)[]): RefCallback<T>;
|
package/dist/index.cjs
CHANGED
|
@@ -752,19 +752,21 @@ const Badge = ({ styleVariant = COLOR.ACCENT_BLUE, className, favorite, children
|
|
|
752
752
|
"bg-accent-blue-light text-accent-blue": styleVariant === COLOR.ACCENT_BLUE,
|
|
753
753
|
"bg-green-light text-green": styleVariant === COLOR.GREEN_LIGHT,
|
|
754
754
|
"bg-red-50 text-red-500": styleVariant === COLOR.RED,
|
|
755
|
-
"bg-purple-light text-purple": styleVariant === COLOR.PURPLE,
|
|
755
|
+
"bg-purple-light text-black border border-purple": styleVariant === COLOR.PURPLE,
|
|
756
|
+
"bg-purple-light text-purple": styleVariant === COLOR.PURPLE_LIGHT,
|
|
756
757
|
"bg-warning-light text-warning": styleVariant === COLOR.WARNING,
|
|
757
758
|
"bg-gray-50 text-black": styleVariant === COLOR.DARK_GRAY,
|
|
758
759
|
"bg-black text-white": styleVariant === COLOR.BLACK,
|
|
759
760
|
"bg-gray-50 text-gray-800": styleVariant === COLOR.GRAY,
|
|
760
761
|
"bg-secondary-light text-secondary": styleVariant === COLOR.SECONDARY_LIGHT,
|
|
761
762
|
"bg-secondary text-white": styleVariant === COLOR.SECONDARY,
|
|
762
|
-
"bg-white text-black": styleVariant === COLOR.WHITE
|
|
763
|
+
"bg-white text-black": styleVariant === COLOR.WHITE,
|
|
764
|
+
"bg-turquoise-50 text-black border border-primary": styleVariant === COLOR.PRIMARY
|
|
763
765
|
}, className),
|
|
764
766
|
...props,
|
|
765
767
|
children: /* @__PURE__ */ (0, react_jsx_runtime.jsx)("span", {
|
|
766
768
|
"data-testid": "badge-content",
|
|
767
|
-
className: cn("block h-
|
|
769
|
+
className: cn("block h-[22px] overflow-hidden text-ellipsis whitespace-nowrap text-inherit", { "flex items-center": favorite }),
|
|
768
770
|
children
|
|
769
771
|
})
|
|
770
772
|
});
|