mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-08-21 16:02:28 +00:00
fix select in table default value
This commit is contained in:
@@ -585,6 +585,7 @@
|
||||
{:else if actionButton.type == 'selectcomponent'}
|
||||
<div class="w-40">
|
||||
<AppSelect
|
||||
noDefault
|
||||
noInitialize
|
||||
extraKey={'idx' + rowIndex}
|
||||
{render}
|
||||
@@ -631,6 +632,7 @@
|
||||
{:else if actionButton.type == 'selectcomponent'}
|
||||
<div class="w-40">
|
||||
<AppSelect
|
||||
noDefault
|
||||
noInitialize
|
||||
--font-size="10px"
|
||||
extraKey={'idx' + rowIndex}
|
||||
|
||||
@@ -33,6 +33,7 @@
|
||||
export let noInitialize = false
|
||||
export let controls: { left: () => boolean; right: () => boolean | string } | undefined =
|
||||
undefined
|
||||
export let noDefault = false
|
||||
|
||||
const {
|
||||
app,
|
||||
@@ -68,7 +69,7 @@
|
||||
result: undefined as string | undefined
|
||||
})
|
||||
|
||||
let value: string | undefined = outputs?.result.peak()
|
||||
let value: string | undefined = noDefault ? undefined : outputs?.result.peak()
|
||||
|
||||
$: resolvedConfig.items && handleItems()
|
||||
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
<div
|
||||
class={classNames(
|
||||
'w-full text-xs font-bold gap-1 truncate py-1.5 px-2 cursor-pointer transition-all justify-between flex items-center border border-gray-3 rounded-md',
|
||||
'bg-surface border-gray-300 hover:bg-gray-100 focus:bg-gray-100 text-secondary',
|
||||
'bg-surface hover:bg-tertiary focus:border-primary text-secondary',
|
||||
$selectedComponent?.includes(component.id) ? 'outline outline-blue-500 bg-red-400' : ''
|
||||
)}
|
||||
on:click={() => {
|
||||
|
||||
@@ -173,7 +173,11 @@ export type ListContext = Writable<{
|
||||
disabled: boolean
|
||||
}>
|
||||
|
||||
export type ListInputs = { set: (id: string, value: any) => void; remove: (id: string) => void }
|
||||
export type ListInputs = {
|
||||
set: (id: string, value: any) => void
|
||||
remove: (id: string) => void
|
||||
get: (id: string) => void
|
||||
}
|
||||
|
||||
export type GroupContext = Writable<Record<string, any>>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user