import React from 'react';
import clsx from 'clsx';
import {ButtonBase} from '../buttons/button-base';
type Props = {
onChange?: (e: string) => void;
value?: string;
colors: string[];
};
export function ColorSwatch({onChange, value, colors}: Props) {
const presetButtons = colors.map(color => {
const isSelected = value === color;
return (