import React from "react"; import { Box } from "../components/Box"; import { Flex } from "../components/Flex"; const styles = { outsideContainer: { fontSize: "16px", WebkitFontSmoothing: "antialiased", WebkitTapHighlightColor: "rgba(0, 0, 0, 0)", }, insideContainer: { fontSize: "14px", lineHeight: "20px", }, headings: { paddingBottom: "20px", fontWeight: 700, color: "rgba(51, 51, 51, 0.6)", }, headingName: { flex: "0 0 30%", }, paletteTitle: { flex: "0 0 30%", lineHeight: "20px", marginTop: "5px", fontWeight: 700, color: "#333", }, paletteSwatches: { marginBottom: "30px", }, colorItems: { borderRadius: "4px", boxShadow: "rgba(0,0,0,0.10) 0 1px 3px 0", border: "1px solid #dee7ee", height: "50px", marginBottom: "5px", }, colorItemName: { fontSize: "12px", color: "rgba(51, 51, 51, 0.6)", }, }; export const CustomColorPalette = ({ title, colors, background = "#fff", }: { title: string; colors: { [key: string]: string }; background?: string; }) => { const colorKeys: string[] = Object.keys(colors); const colorValues: string[] = Object.values(colors); return ( Name Swatches {title} {colorValues.map((backgroundColor) => ( ))} {colorKeys.map((key) => ( {key} {colors[key]} ))} ); };