style: handle height based on number of toolbars
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
gitea/salix-front/pipeline/pr-dev This commit looks good
Details
This commit is contained in:
parent
96bcc04d78
commit
8c9a863d71
|
@ -117,7 +117,15 @@ const $props = defineProps({
|
|||
},
|
||||
tableHeight: {
|
||||
type: String,
|
||||
default: '90vh',
|
||||
default: () => {
|
||||
let height = 100;
|
||||
Array.from(document.querySelectorAll('[role="toolbar"]'))
|
||||
.filter((element) => window.getComputedStyle(element).display !== 'none')
|
||||
.forEach(() => {
|
||||
height -= 10;
|
||||
});
|
||||
return height + 'vh';
|
||||
},
|
||||
},
|
||||
footer: {
|
||||
type: Boolean,
|
||||
|
@ -627,6 +635,7 @@ const rowCtrlClickFunction = computed(() => {
|
|||
});
|
||||
</script>
|
||||
<template>
|
||||
{{ $props.tableHeight }}
|
||||
<RightMenu v-if="$props.rightSearch" :overlay="overlay">
|
||||
<template #right-panel>
|
||||
<VnTableFilter
|
||||
|
|
Loading…
Reference in New Issue