Added dynamic calc for height

This commit is contained in:
FrankRua 2022-01-19 13:48:55 -05:00
parent 48171bb8c0
commit a0b5d1ff61
2 changed files with 8 additions and 3 deletions

View file

@ -47,6 +47,13 @@ export default {
components: {
listButton,
},
updated() {
// Dynamically account for the header height.
var element = document.getElementsByClassName('overflow-scroll')[0];
element.style.height = 'calc(100% - ' + element.offsetTop + 'px)';
}
};
</script>
@ -55,8 +62,6 @@ export default {
height: calc(100vh - 280px);
.overflow-scroll {
// Height will be determined by overall height of content above list
height: calc(100% - 320px);
-webkit-overflow-scrolling: touch;
}
}

View file

@ -1,5 +1,5 @@
<template>
<div class="funnel-header d-flex justify-content-center align-items-center" v-if="imageSrc">
<div class="funnel-header d-flex justify-content-center align-items-center flex-column" v-if="imageSrc">
<img class="logo-image img-fluid" :src="imageSrc" alt="Safelite logo" />
<alert v-if="displayGlobalAlert" :alertClass="globalAlertMessage.type" :alertHeadline="globalAlertMessage.messageCopy" :alertCopy="globalAlertMessage.messageHeadline" v-bind:isDismissible="globalAlertMessage.isDismissible" />
</div>