fix: bug#16114
This commit is contained in:
parent
0d26cdbd93
commit
26502e78a5
|
@ -1,5 +1,5 @@
|
||||||
<template>
|
<template>
|
||||||
<div class='full-page-warp' ref='fullPage' :style='{ minHeight: `calc(100vh - ${y + 24}px)`}'>
|
<div ref='fullPage' :style="{ minHeight: MinHeight}" class='full-page-warp' >
|
||||||
<div class="full-page-warp-content">
|
<div class="full-page-warp-content">
|
||||||
<slot></slot>
|
<slot></slot>
|
||||||
</div>
|
</div>
|
||||||
|
@ -9,9 +9,21 @@
|
||||||
<script setup lang='ts' name='FullPage'>
|
<script setup lang='ts' name='FullPage'>
|
||||||
import { useElementBounding } from '@vueuse/core'
|
import { useElementBounding } from '@vueuse/core'
|
||||||
|
|
||||||
|
const props = defineProps({
|
||||||
|
extraHeight: {
|
||||||
|
type: Number,
|
||||||
|
default: 0
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
const fullPage = ref(null)
|
const fullPage = ref(null)
|
||||||
const { y } = useElementBounding(fullPage)
|
const { y } = useElementBounding(fullPage)
|
||||||
|
|
||||||
|
const MinHeight = computed(() => {
|
||||||
|
const _y = (y.value < 0 ? 0 : y.value) + props.extraHeight
|
||||||
|
return `calc(100vh - ${_y + 24}px)`
|
||||||
|
})
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<style scoped lang="less">
|
<style scoped lang="less">
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
@search="(params:any)=>queryParams = {...params}"
|
@search="(params:any)=>queryParams = {...params}"
|
||||||
style='margin-bottom: 0;'
|
style='margin-bottom: 0;'
|
||||||
/>
|
/>
|
||||||
<FullPage>
|
<FullPage :extraHeight="24">
|
||||||
<j-pro-table
|
<j-pro-table
|
||||||
ref="tableRef"
|
ref="tableRef"
|
||||||
:request="table.requestFun"
|
:request="table.requestFun"
|
||||||
|
|
Loading…
Reference in New Issue