Message component (mainly styling)

This commit is contained in:
Jörn-Michael Miehe 2022-09-15 19:30:48 +00:00
parent 5a77231282
commit 2db0cb58f0
3 changed files with 61 additions and 10 deletions

View file

@ -14,7 +14,7 @@
:contain="image_contain"
:urls="image_urls"
/>
<div v-html="message_html" />
<Message :html="message_html" />
</template>
<template slot="calendars">
<CalendarCarousel :speed="calendar_speed" :data="calendar_data" />
@ -37,20 +37,23 @@
<script lang="ts">
import { Component, Vue } from "vue-property-decorator";
import CalendarCarousel from "./components/calendar/CalendarCarousel.vue";
import Dashboard from "./components/Dashboard.vue";
import DashboardInfo from "./components/DashboardInfo.vue";
import ImageCarousel from "./components/ImageCarousel.vue";
import TitleBar from "./components/title/TitleBar.vue";
import Dashboard from "./components/Dashboard.vue";
import ImageCarousel from "./components/ImageCarousel.vue";
import Message from "./components/Message.vue";
import CalendarCarousel from "./components/calendar/CalendarCarousel.vue";
import DashboardInfo from "./components/DashboardInfo.vue";
import TickerBar from "./components/TickerBar.vue";
@Component({
components: {
CalendarCarousel,
Dashboard,
DashboardInfo,
ImageCarousel,
TitleBar,
Dashboard,
ImageCarousel,
Message,
CalendarCarousel,
DashboardInfo,
TickerBar,
},
})
@ -63,7 +66,7 @@ export default class App extends Vue {
private image_height = 300;
private image_contain = false;
private image_speed = 10000;
private message_html = "<p>changeme</p>";
private message_html = require("@/assets/lipsum.json");
private calendar_data = require("@/assets/calendar_testdata.json");
private calendar_speed = 10000;

View file

@ -0,0 +1 @@
"<h1>Lorem ipsum dolor sit amet</h1>\n<h2>Consectetuer adipiscing elit</h2>\n<ul>\n<li>In enim justo, rhoncus ut</li>\n<li>imperdiet a, venenatis vitae, justo</li>\n<li>Nullam dictum felis eu pede mollis pretium</li>\n</ul>\n<p>Aenean commodo ligula eget dolor. Aenean massa. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus. Donec quam felis, ultricies nec, pellentesque eu, pretium quis, sem. Nulla consequat massa quis enim. Donec pede justo, fringilla vel, aliquet nec, vulputate eget, arcu. </p>\n<ol>\n<li>Integer tincidunt</li>\n<li>Cras dapibus</li>\n<li>Vivamus elementum semper nisi</li>\n</ol>"

View file

@ -0,0 +1,47 @@
<template>
<div v-html="html" />
</template>
<script lang="ts">
import { Component, Prop, Vue } from "vue-property-decorator";
@Component
export default class Message extends Vue {
@Prop({ required: true })
private readonly html!: string;
}
</script>
<style lang="scss" scoped>
div:deep() {
h1,
h2,
h3,
h4,
h5,
h6,
ul,
ol {
font-family: "Neue Praxis", sans-serif !important;
margin-bottom: 0.4rem;
}
p {
text-align: justify;
hyphens: auto;
margin-bottom: 0.4rem;
}
h1,
h2,
h3 {
font-weight: normal;
}
h4,
h5,
h6 {
font-weight: bold;
}
}
</style>