TickerBar.variant -> TickerBar.color

This commit is contained in:
Jörn-Michael Miehe 2022-09-13 01:56:45 +00:00
parent 2a569618ec
commit 1b6b421c57

View file

@ -1,5 +1,5 @@
<template>
<v-footer :color="variant" :dark="is_dark" fixed>
<v-footer :color="color" :dark="is_dark" fixed>
<span class="text-h6" :style="{ 'animation-duration': marqueeDuration }">
<div v-html="content" />
</span>
@ -16,7 +16,7 @@ export default class TickerBar extends Vue {
private readonly content!: string;
@Prop({ default: "primary" })
private readonly variant!: string;
private readonly color!: string;
private get is_dark(): boolean {
return this.footerColor.isDark();
@ -24,14 +24,14 @@ export default class TickerBar extends Vue {
private get footerColor(): Color {
// try getting from vuetify theme
let color = this.$vuetify.theme.themes.light[this.variant];
let color = this.$vuetify.theme.themes.light[this.color];
if (typeof color === "string") {
return Color(color);
}
// fallback: parse color directly
return Color(this.variant);
return Color(this.color);
}
private get marqueeDuration(): string {