mirror of
https://github.com/Tyrrrz/DiscordChatExporter.git
synced 2025-06-07 09:54:50 -04:00
[HTML] Cleanup templates slightly
This commit is contained in:
parent
fd9d367bad
commit
2b0fa4213b
4 changed files with 17 additions and 13 deletions
|
@ -1,8 +1,9 @@
|
||||||
@using System
|
@using System
|
||||||
@using System.Linq
|
@using System.Linq
|
||||||
@using System.Threading.Tasks
|
@using System.Threading.Tasks
|
||||||
|
|
||||||
@namespace DiscordChatExporter.Core.Exporting.Writers.Html
|
@namespace DiscordChatExporter.Core.Exporting.Writers.Html
|
||||||
@inherits MiniRazor.TemplateBase<DiscordChatExporter.Core.Exporting.Writers.Html.MessageGroupTemplateContext>
|
@inherits MiniRazor.TemplateBase<MessageGroupTemplateContext>
|
||||||
|
|
||||||
@{
|
@{
|
||||||
string FormatDate(DateTimeOffset date) => Model.ExportContext.FormatDate(date);
|
string FormatDate(DateTimeOffset date) => Model.ExportContext.FormatDate(date);
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
@namespace DiscordChatExporter.Core.Exporting.Writers.Html
|
@namespace DiscordChatExporter.Core.Exporting.Writers.Html
|
||||||
@inherits MiniRazor.TemplateBase<DiscordChatExporter.Core.Exporting.Writers.Html.PostambleTemplateContext>
|
@inherits MiniRazor.TemplateBase<PostambleTemplateContext>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
@using System
|
@using System
|
||||||
@using System.Threading.Tasks
|
@using System.Threading.Tasks
|
||||||
|
|
||||||
@namespace DiscordChatExporter.Core.Exporting.Writers.Html
|
@namespace DiscordChatExporter.Core.Exporting.Writers.Html
|
||||||
@inherits MiniRazor.TemplateBase<DiscordChatExporter.Core.Exporting.Writers.Html.PreambleTemplateContext>
|
@inherits MiniRazor.TemplateBase<PreambleTemplateContext>
|
||||||
|
|
||||||
@{
|
@{
|
||||||
string FormatDate(DateTimeOffset date) => Model.ExportContext.FormatDate(date);
|
string FormatDate(DateTimeOffset date) => Model.ExportContext.FormatDate(date);
|
||||||
|
|
|
@ -1,11 +1,13 @@
|
||||||
@using System
|
@using System
|
||||||
|
|
||||||
@namespace DiscordChatExporter.Core.Exporting.Writers.Html
|
@namespace DiscordChatExporter.Core.Exporting.Writers.Html
|
||||||
@inherits MiniRazor.TemplateBase<DiscordChatExporter.Core.Exporting.Writers.Html.PreambleTemplateContext>
|
@inherits MiniRazor.TemplateBase<PreambleTemplateContext>
|
||||||
|
|
||||||
@{
|
@{
|
||||||
var isDarkTheme = string.Equals(Model.ThemeName, "Dark", StringComparison.OrdinalIgnoreCase);
|
string Themed(string darkVariant, string lightVariant) =>
|
||||||
|
string.Equals(Model.ThemeName, "Dark", StringComparison.OrdinalIgnoreCase)
|
||||||
string Themed(string darkVariant, string lightVariant) => isDarkTheme ? darkVariant : lightVariant;
|
? darkVariant
|
||||||
|
: lightVariant;
|
||||||
}
|
}
|
||||||
|
|
||||||
<style>
|
<style>
|
||||||
|
@ -268,12 +270,12 @@
|
||||||
color: @Themed("#ffffff", "#2f3136");
|
color: @Themed("#ffffff", "#2f3136");
|
||||||
}
|
}
|
||||||
|
|
||||||
.chatlog__reference-content > * {
|
.chatlog__reference-content>* {
|
||||||
display: inline;
|
display: inline;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
.chatlog__reference-content > a:hover {
|
.chatlog__reference-content>a:hover {
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -365,22 +367,22 @@
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.chatlog__attachment-icon > .a {
|
.chatlog__attachment-icon>.a {
|
||||||
fill: #f4f5fb;
|
fill: #f4f5fb;
|
||||||
d: path("M50,935a25,25,0,0,1-25-25V50A25,25,0,0,1,50,25H519.6L695,201.32V910a25,25,0,0,1-25,25Z");
|
d: path("M50,935a25,25,0,0,1-25-25V50A25,25,0,0,1,50,25H519.6L695,201.32V910a25,25,0,0,1-25,25Z");
|
||||||
}
|
}
|
||||||
|
|
||||||
.chatlog__attachment-icon > .b {
|
.chatlog__attachment-icon>.b {
|
||||||
fill: #7789c4;
|
fill: #7789c4;
|
||||||
d: path("M509.21,50,670,211.63V910H50V50H509.21M530,0H50A50,50,0,0,0,0,50V910a50,50,0,0,0,50,50H670a50,50,0,0,0,50-50h0V191Z");
|
d: path("M509.21,50,670,211.63V910H50V50H509.21M530,0H50A50,50,0,0,0,0,50V910a50,50,0,0,0,50,50H670a50,50,0,0,0,50-50h0V191Z");
|
||||||
}
|
}
|
||||||
|
|
||||||
.chatlog__attachment-icon > .c {
|
.chatlog__attachment-icon>.c {
|
||||||
fill: #f4f5fb;
|
fill: #f4f5fb;
|
||||||
d: path("M530,215a25,25,0,0,1-25-25V50a25,25,0,0,1,16.23-23.41L693.41,198.77A25,25,0,0,1,670,215Z");
|
d: path("M530,215a25,25,0,0,1-25-25V50a25,25,0,0,1,16.23-23.41L693.41,198.77A25,25,0,0,1,670,215Z");
|
||||||
}
|
}
|
||||||
|
|
||||||
.chatlog__attachment-icon > .d {
|
.chatlog__attachment-icon>.d {
|
||||||
fill: #7789c4;
|
fill: #7789c4;
|
||||||
d: path("M530,70.71,649.29,190H530V70.71M530,0a50,50,0,0,0-50,50V190a50,50,0,0,0,50,50H670a50,50,0,0,0,50-50Z");
|
d: path("M530,70.71,649.29,190H530V70.71M530,0a50,50,0,0,0-50,50V190a50,50,0,0,0,50,50H670a50,50,0,0,0,50-50Z");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue