aboutsummaryrefslogtreecommitdiffstats
path: root/src/Pages/Read.cshtml
blob: cbbd69a2bb404d1476a8c88a955bf6117b322ade (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
@page "/les/{site}"
@model ReadModel
@{
    ViewData["Title"] = Model.Source.Title;
}

<div id="art-header" style="display: flex; justify-content: space-between">
    <div>
        <h1>@Model.Source.Title</h1>
        <p>@Model.Source.Subtitle</p>
    </div>
    <div style="display: flex; flex-direction: column; flex-wrap: nowrap">
        <div style="flex-direction:column">
            @if (Model.Source.PublishedAt != default) {
                <small style="white-space: nowrap">Publisert: @Model.Source.PublishedAt.ToString("dd-MM-yyyy hh:mm:ss")</small>
            }
            @if (Model.Source.UpdatedAt != default) {
                <br/>
                <small style="white-space: nowrap">Oppdatert: @Model.Source.UpdatedAt.ToString("dd-MM-yyyy hh:mm:ss")</small>
            }
        </div>
        <div style="margin: 0 5px; border: 0.5px solid black"></div>
        <div style="flex-direction:column">
            @foreach (var author in Model.Source.Authors) {
                <small style="white-space: nowrap"><b>@author.Name</b>: @author.Title</small>
                <br/>
            }
        </div>
    </div>
</div>

<div id="art-body">
    @Html.Raw(Model.Source.Content)
</div>