fixes height issue with grid component
This commit is contained in:
parent
3f2d1aed30
commit
2a8aebeb16
|
@ -238,7 +238,10 @@
|
||||||
"material"
|
"material"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"height": "number",
|
"height": {
|
||||||
|
"type": "number",
|
||||||
|
"default": "500"
|
||||||
|
},
|
||||||
"pagination": "bool"
|
"pagination": "bool"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
export let datasource = {}
|
export let datasource = {}
|
||||||
export let editable
|
export let editable
|
||||||
export let theme = "alpine"
|
export let theme = "alpine"
|
||||||
export let height
|
export let height = 500
|
||||||
export let pagination
|
export let pagination
|
||||||
|
|
||||||
let dataLoaded = false
|
let dataLoaded = false
|
||||||
|
@ -115,7 +115,7 @@
|
||||||
href="https://cdn.jsdelivr.net/npm/flatpickr/dist/flatpickr.min.css" />
|
href="https://cdn.jsdelivr.net/npm/flatpickr/dist/flatpickr.min.css" />
|
||||||
</svelte:head>
|
</svelte:head>
|
||||||
|
|
||||||
<div class="container" style="--grid-height: {height}px">
|
<div style="--grid-height: {height}px">
|
||||||
{#if dataLoaded}
|
{#if dataLoaded}
|
||||||
{#if editable}
|
{#if editable}
|
||||||
<div class="controls">
|
<div class="controls">
|
||||||
|
@ -139,9 +139,6 @@
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
.container {
|
|
||||||
--grid-height: 800px;
|
|
||||||
}
|
|
||||||
.container :global(form) {
|
.container :global(form) {
|
||||||
display: grid;
|
display: grid;
|
||||||
grid-template-columns: repeat(2);
|
grid-template-columns: repeat(2);
|
||||||
|
|
Loading…
Reference in New Issue