footer margin

This commit is contained in:
Jörn-Michael Miehe 2022-09-24 02:19:38 +00:00
parent 738be6e667
commit daa87c0255
2 changed files with 27 additions and 17 deletions

View file

@ -4,7 +4,7 @@
<TitleBar /> <TitleBar />
<Dashboard> <Dashboard>
<template slot="message"> <template slot="message">
<div class="d-flex flex-column fill-height pb-sm-12"> <div class="d-flex flex-column fill-height">
<Message :html="message_html" /> <Message :html="message_html" />
<ImageCarousel <ImageCarousel
class="mt-auto" class="mt-auto"
@ -19,7 +19,6 @@
<template slot="calendars"> <template slot="calendars">
<CalendarCarousel :speed="calendar_speed" :data="calendar_data" /> <CalendarCarousel :speed="calendar_speed" :data="calendar_data" />
<DashboardInfo <DashboardInfo
class="pb-12 pb-sm-0"
:server_host="server_host" :server_host="server_host"
:server_name="server_name" :server_name="server_name"
:version="dashboard_version" :version="dashboard_version"

View file

@ -1,9 +1,12 @@
<template> <template>
<div>
<v-footer :color="color" :dark="is_dark" fixed> <v-footer :color="color" :dark="is_dark" fixed>
<span ref="marquee" class="text-h6"> <span ref="marquee" class="text-h6" v-html="content" />
<div ref="content" v-html="content" />
</span>
</v-footer> </v-footer>
<v-footer>
<span class="text-h6" v-html="content" />
</v-footer>
</div>
</template> </template>
<script lang="ts"> <script lang="ts">
@ -43,9 +46,12 @@ export default class TickerBar extends Vue {
@Watch("content", { immediate: true }) @Watch("content", { immediate: true })
private set_marquee_duration(): void { private set_marquee_duration(): void {
this.$nextTick((): void => { this.$nextTick((): void => {
const width = parseFloat( const style = window.getComputedStyle(this._marquee);
window.getComputedStyle(this._content).getPropertyValue("width")
); const width =
parseFloat(style.getPropertyValue("width")) -
parseFloat(style.getPropertyValue("padding-left")) -
parseFloat(style.getPropertyValue("padding-right"));
// 10 seconds + another second per 40px // 10 seconds + another second per 40px
const duration = 10 + Math.round(width / 40); const duration = 10 + Math.round(width / 40);
@ -69,6 +75,10 @@ export default class TickerBar extends Vue {
.v-footer { .v-footer {
white-space: nowrap; white-space: nowrap;
overflow: hidden; overflow: hidden;
z-index: 0;
&:first-child {
z-index: 999;
> span { > span {
display: inline-block; display: inline-block;
@ -80,6 +90,7 @@ export default class TickerBar extends Vue {
animation-play-state: paused; animation-play-state: paused;
} }
} }
}
:deep() * { :deep() * {
margin: 0 !important; margin: 0 !important;