Implement issue state change button

This commit is contained in:
Rūdolfs Ošiņš
2024-10-29 10:54:16 +01:00
parent 319b1502c6
commit daaef13ff2
5 changed files with 196 additions and 11 deletions
+29
View File
@@ -0,0 +1,29 @@
<script lang="ts" generics="T">
export let items: T[];
export let styleDropdownMinWidth: string | undefined = undefined;
</script>
<style>
.dropdown {
align-items: center;
border-radius: var(--border-radius-small);
max-height: 60vh;
overflow-y: auto;
}
.dropdown-item {
padding: 2px;
font-size: var(--font-size-small);
}
</style>
<div class="dropdown" style:min-width={styleDropdownMinWidth}>
{#each items as item}
<div class="dropdown-item">
<slot name="item" {item} />
</div>
{:else}
<div class="dropdown-item">
<slot name="empty" />
</div>
{/each}
</div>