Remove text setting from dynamic filter component
This commit is contained in:
parent
07d45d8039
commit
837e70c9a8
|
@ -2662,12 +2662,6 @@
|
||||||
"key": "allowedFields",
|
"key": "allowedFields",
|
||||||
"placeholder": "All fields"
|
"placeholder": "All fields"
|
||||||
},
|
},
|
||||||
{
|
|
||||||
"type": "text",
|
|
||||||
"label": "Button text",
|
|
||||||
"key": "text",
|
|
||||||
"defaultValue": "Filter"
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"type": "select",
|
"type": "select",
|
||||||
"label": "Button size",
|
"label": "Button size",
|
||||||
|
|
|
@ -8,7 +8,6 @@
|
||||||
|
|
||||||
export let dataProvider
|
export let dataProvider
|
||||||
export let allowedFields
|
export let allowedFields
|
||||||
export let text = ""
|
|
||||||
export let size = "M"
|
export let size = "M"
|
||||||
|
|
||||||
const component = getContext("component")
|
const component = getContext("component")
|
||||||
|
@ -29,7 +28,6 @@
|
||||||
)
|
)
|
||||||
$: schema = dataProvider?.schema
|
$: schema = dataProvider?.schema
|
||||||
$: schemaFields = getSchemaFields(schema, allowedFields)
|
$: schemaFields = getSchemaFields(schema, allowedFields)
|
||||||
$: buttonText = text || "Filter"
|
|
||||||
|
|
||||||
// Add query extension to data provider
|
// Add query extension to data provider
|
||||||
$: {
|
$: {
|
||||||
|
@ -73,7 +71,7 @@
|
||||||
<Button
|
<Button
|
||||||
onClick={openEditor}
|
onClick={openEditor}
|
||||||
icon="Properties"
|
icon="Properties"
|
||||||
text={buttonText}
|
text="Filter"
|
||||||
{size}
|
{size}
|
||||||
type="secondary"
|
type="secondary"
|
||||||
quiet
|
quiet
|
||||||
|
@ -81,7 +79,7 @@
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Modal bind:this={modal}>
|
<Modal bind:this={modal}>
|
||||||
<ModalContent title={buttonText} size="XL" onConfirm={updateQuery}>
|
<ModalContent title="Edit filters" size="XL" onConfirm={updateQuery}>
|
||||||
<FilterModal bind:filters={tmpFilters} {schemaFields} />
|
<FilterModal bind:filters={tmpFilters} {schemaFields} />
|
||||||
</ModalContent>
|
</ModalContent>
|
||||||
</Modal>
|
</Modal>
|
||||||
|
|
Loading…
Reference in New Issue