mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-09-09 16:05:42 +00:00
* improve collapsible link * do not show superadmin ws link when already in it * improve OAuth UI * sso/oauth instance settings ui * refactor instance settings alerts WIP * Indexer and Oauth to brand guidelines * refactor ws error handler page * Create a tab SMTP in the Instance Settings * Ractivity isssue fix for tabs * nit * Add smtp settings status in Error handler * Add smtp configuration status * Display teams connection status for instance alerts * nit * Add critical alerts description * nit * nit * improve ee display * nit * nit * fix typo * nit * restore vit config --------- Co-authored-by: Alexander Petric <alex@windmill.dev>
50 lines
1.2 KiB
Svelte
50 lines
1.2 KiB
Svelte
<script lang="ts">
|
|
import { Button } from './common'
|
|
import { X, Plus } from 'lucide-svelte'
|
|
|
|
export let extra_params: Record<string, string> = {}
|
|
|
|
let extra_params_vec: [string, string][] = Object.entries(extra_params)
|
|
|
|
function sync() {
|
|
extra_params = Object.fromEntries(extra_params_vec)
|
|
}
|
|
</script>
|
|
|
|
{#each extra_params_vec as o}
|
|
<div class="flex flex-row max-w-md mb-2 gap-2">
|
|
<input type="text" on:keyup={sync} bind:value={o[0]} />
|
|
<input type="text" on:keyup={sync} bind:value={o[1]} />
|
|
<Button
|
|
variant="subtle"
|
|
destructive
|
|
unifiedSize="md"
|
|
on:click={() => {
|
|
extra_params_vec = extra_params_vec.filter((e) => e[0] != o[0])
|
|
sync()
|
|
}}
|
|
startIcon={{ icon: X }}
|
|
iconOnly
|
|
/>
|
|
</div>
|
|
{/each}
|
|
<div class="flex items-center mt-1">
|
|
<Button
|
|
variant="default"
|
|
hover="yo"
|
|
size="sm"
|
|
endIcon={{ icon: Plus }}
|
|
on:click={() => {
|
|
extra_params_vec = (extra_params_vec ?? []).concat([['key', 'value']])
|
|
sync()
|
|
}}
|
|
>
|
|
Add item
|
|
</Button>
|
|
{#if (extra_params_vec ?? []).length > 0}
|
|
<span class="ml-2 text-2xs text-secondary">
|
|
({(extra_params_vec ?? []).length} item{(extra_params_vec ?? []).length > 1 ? 's' : ''})
|
|
</span>
|
|
{/if}
|
|
</div>
|