mirror of
https://github.com/vbenjs/gf-vben-admin.git
synced 2025-01-24 04:10:20 +08:00
fix(modal): fullscreen height calculation error #203
This commit is contained in:
parent
ca4f1a8faf
commit
b45f8c5021
@ -36,8 +36,8 @@
|
|||||||
props: {
|
props: {
|
||||||
loading: propTypes.bool,
|
loading: propTypes.bool,
|
||||||
useWrapper: propTypes.bool.def(true),
|
useWrapper: propTypes.bool.def(true),
|
||||||
modalHeaderHeight: propTypes.number.def(50),
|
modalHeaderHeight: propTypes.number.def(57),
|
||||||
modalFooterHeight: propTypes.number.def(54),
|
modalFooterHeight: propTypes.number.def(74),
|
||||||
minHeight: propTypes.number.def(200),
|
minHeight: propTypes.number.def(200),
|
||||||
height: propTypes.number,
|
height: propTypes.number,
|
||||||
footerOffset: propTypes.number.def(0),
|
footerOffset: propTypes.number.def(0),
|
||||||
@ -137,7 +137,7 @@
|
|||||||
|
|
||||||
if (props.fullScreen) {
|
if (props.fullScreen) {
|
||||||
realHeightRef.value =
|
realHeightRef.value =
|
||||||
window.innerHeight - props.modalFooterHeight - props.modalHeaderHeight;
|
window.innerHeight - props.modalFooterHeight - props.modalHeaderHeight - 28;
|
||||||
} else {
|
} else {
|
||||||
realHeightRef.value = props.height
|
realHeightRef.value = props.height
|
||||||
? props.height
|
? props.height
|
||||||
@ -145,6 +145,9 @@
|
|||||||
? maxHeight
|
? maxHeight
|
||||||
: realHeight;
|
: realHeight;
|
||||||
}
|
}
|
||||||
|
console.log('======================');
|
||||||
|
console.log(realHeightRef.value, props);
|
||||||
|
console.log('======================');
|
||||||
emit('height-change', unref(realHeightRef));
|
emit('height-change', unref(realHeightRef));
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
|
Loading…
Reference in New Issue
Block a user