Add subtitle support to pickers

This commit is contained in:
Andrew Kingston 2023-11-24 16:19:39 +00:00
parent d8b646de29
commit 016ed56c19
2 changed files with 7 additions and 3 deletions

View File

@ -10,8 +10,9 @@
export let getOptionLabel = option => option
export let getOptionValue = option => option
export let getOptionIcon = () => null
export let useOptionIconImage = false
export let getOptionColour = () => null
export let getOptionSubtitle = () => null
export let useOptionIconImage = false
export let isOptionEnabled
export let readonly = false
export let quiet = false
@ -82,8 +83,9 @@
{getOptionLabel}
{getOptionValue}
{getOptionIcon}
{useOptionIconImage}
{getOptionColour}
{getOptionSubtitle}
{useOptionIconImage}
{isOptionEnabled}
{autocomplete}
{sort}

View File

@ -13,9 +13,10 @@
export let options = []
export let getOptionLabel = option => extractProperty(option, "label")
export let getOptionValue = option => extractProperty(option, "value")
export let getOptionSubtitle = option => option?.subtitle
export let getOptionIcon = option => option?.icon
export let useOptionIconImage = false
export let getOptionColour = option => option?.colour
export let useOptionIconImage = false
export let isOptionEnabled
export let quiet = false
export let autoWidth = false
@ -58,6 +59,7 @@
{getOptionValue}
{getOptionIcon}
{getOptionColour}
{getOptionSubtitle}
{useOptionIconImage}
{isOptionEnabled}
{autocomplete}