<script>
    import Icon from './Icon.svelte';
    export let icon = null;
</script>

<button on:click class="text-gray-200 bg-indigo-600 hover:bg-indigo-700 px-2 py-1 rounded-md">
    {#if icon}<Icon name={icon} class="w-4 text-gray-200" />{/if}
    <slot></slot>
</button>