From 3591297f3da815165ab564086df4cac45dbd8018 Mon Sep 17 00:00:00 2001 From: Yashvardhan Jagnani Date: Wed, 1 May 2024 00:05:53 +0530 Subject: [PATCH 1/2] !fix: storybook build --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 85dce2bc..6c150628 100644 --- a/package.json +++ b/package.json @@ -34,7 +34,7 @@ "scripts": { "build:library": "vite build && npm run build:library-css", "build:library-css": "tailwindcss -m -i ./src/tailwind-input.css -o ./dist/styles.css --minify", - "build:storybook": "storybook build && npm run build:storybook-css", + "build:storybook": "npm run build:library && npm run build:storybook-css && storybook build", "build:storybook-css": "tailwindcss -m -i ./src/tailwind-input.css -o ./src/tailwind-output.css --minify", "bundle-size": "npx vite-bundle-visualizer", "dev": "concurrently -n \"storybook-css,storybook\" -c \"blue,red\" \"npm run dev:css\" \"storybook dev -p 6006\"", From 2965b598c75d7ec7e4ab3b23c4a013aeb5272fa6 Mon Sep 17 00:00:00 2001 From: Yashvardhan Jagnani Date: Wed, 1 May 2024 00:06:10 +0530 Subject: [PATCH 2/2] fix: misc css --- src/components/Atoms/TokenAvatar/TokenAvatar.tsx | 6 +++--- .../Molecules/NFTs/NFTFloorPrice/NFTFloorPrice.tsx | 2 +- .../XYK/XYKTokenDetailView/XYKTokenDetailView.tsx | 4 ++-- src/components/ui/button.tsx | 8 ++++---- src/components/ui/dialog.tsx | 2 +- src/components/ui/skeleton.tsx | 14 +++++++------- 6 files changed, 18 insertions(+), 18 deletions(-) diff --git a/src/components/Atoms/TokenAvatar/TokenAvatar.tsx b/src/components/Atoms/TokenAvatar/TokenAvatar.tsx index 6f2bcd90..2e916795 100644 --- a/src/components/Atoms/TokenAvatar/TokenAvatar.tsx +++ b/src/components/Atoms/TokenAvatar/TokenAvatar.tsx @@ -93,14 +93,14 @@ export const TokenAvatar: React.FC = ({
) : (
Token Image { e.currentTarget.src = "https://goldrush.vercel.app/icons/token.svg"; @@ -114,7 +114,7 @@ export const TokenAvatar: React.FC = ({ background: chain_color ? chain_color : "grey", padding: "1px", }} - className={`${SUB_SIZE} absolute -bottom-2 -left-3 rounded-[100%] p-0.5`} + className={`${SUB_SIZE} absolute -bottom-2 -left-3 rounded-full p-0.5`} onError={(e) => { e.currentTarget.src = "https://goldrush.vercel.app/icons/token.svg"; diff --git a/src/components/Molecules/NFTs/NFTFloorPrice/NFTFloorPrice.tsx b/src/components/Molecules/NFTs/NFTFloorPrice/NFTFloorPrice.tsx index e5572875..981f213d 100644 --- a/src/components/Molecules/NFTs/NFTFloorPrice/NFTFloorPrice.tsx +++ b/src/components/Molecules/NFTs/NFTFloorPrice/NFTFloorPrice.tsx @@ -110,7 +110,7 @@ export const NFTFloorPrice: React.FC = ({ }); return ( -
+
Floor Price
diff --git a/src/components/Organisms/XYK/XYKTokenDetailView/XYKTokenDetailView.tsx b/src/components/Organisms/XYK/XYKTokenDetailView/XYKTokenDetailView.tsx index 5f3b562b..f6d887c6 100644 --- a/src/components/Organisms/XYK/XYKTokenDetailView/XYKTokenDetailView.tsx +++ b/src/components/Organisms/XYK/XYKTokenDetailView/XYKTokenDetailView.tsx @@ -63,8 +63,8 @@ export const XYKTokenDetailView: React.FC = ({ {maybeResult.match({ None: () => (
-
-
+
+
), Some: (result) => ( diff --git a/src/components/ui/button.tsx b/src/components/ui/button.tsx index 1cd44e22..b72ebdab 100644 --- a/src/components/ui/button.tsx +++ b/src/components/ui/button.tsx @@ -4,21 +4,21 @@ import { cva, type VariantProps } from "class-variance-authority"; import { cn } from "@/utils/functions"; const buttonVariants = cva( - "inline-flex items-center justify-center whitespace-nowrap rounded-md text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50", + "inline-flex items-center justify-center whitespace-nowrap rounded text-sm font-medium transition-colors focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-ring disabled:pointer-events-none disabled:opacity-50", { variants: { variant: { primary: "bg-primary-light dark:bg-primary-dark text-foreground-light dark:text-foreground-dark shadow hover:bg-opacity-90", outline: - "border border-input bg-background-light dark:bg-background-dark shadow-sm hover:bg-primary-light border-secondary-light dark:border-secondary-dark", + "text-foreground-light dark:text-foreground-dark border bg-background-light dark:bg-background-dark hover:bg-primary-light dark:hover:bg-primary-dark border-secondary-light dark:border-secondary-dark shadow-sm", ghost: "hover:bg-primary-light hover:text-foreground-light dark:hover:bg-primary-dark dark:hover:text-foreground-dark", link: "text-primary-light dark:text-primary-dark underline-offset-4 hover:underline", }, size: { default: "h-9 px-4 py-2", - sm: "h-8 rounded-md px-3 text-xs", - lg: "h-10 rounded-md px-8", + sm: "h-8 rounded px-3 text-xs", + lg: "h-10 rounded px-8", icon: "h-9 w-9", }, }, diff --git a/src/components/ui/dialog.tsx b/src/components/ui/dialog.tsx index c0c4a20e..af82e040 100644 --- a/src/components/ui/dialog.tsx +++ b/src/components/ui/dialog.tsx @@ -35,7 +35,7 @@ const DialogContent = forwardRef< { switch (size) { case "lg": - return "w-[100px] h-[30px]"; + return "w-28 h-8"; case "md": - return "w-[50px] h-[20px]"; + return "w-12 h-5"; case "sm": - return "w-[40px] h-[20px]"; + return "w-10 h-5"; case "xs": - return "w-[30px] h-[20px]"; + return "w-8 h-5"; case "xxs": - return "w-[20px] h-[20px]"; + return "w-5 h-5"; default: - return "w-[100px] h-[20px]"; + return "w-28 h-5"; } }, []); return (