Skip to content

Commit

Permalink
Add a default background to ColorSummary
Browse files Browse the repository at this point in the history
  • Loading branch information
ImperishableMe committed Sep 19, 2023
1 parent b8a45be commit 48840f5
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion components/ColorSummary/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,10 @@ const textFont = Inter({
subsets: ["latin"],
});

const DEFAULT_COLOR = "#ffffff";

export default function Component({ color, onClick }: ComponentProps) {

const styles = reactCSS({
default: {
container: {
Expand All @@ -25,7 +28,7 @@ export default function Component({ color, onClick }: ComponentProps) {
width: "36px",
height: "14px",
borderRadius: "2px",
background: color,
background: color ?? DEFAULT_COLOR,
},
swatch: {
padding: "5px",
Expand Down

0 comments on commit 48840f5

Please sign in to comment.