mirror of
https://github.com/Theodor-Springmann-Stiftung/hamann-ausgabe-core.git
synced 2025-10-30 01:35:32 +00:00
Fast fertig für v 2.0
This commit is contained in:
23243
HaLive/Hamann.xml
23243
HaLive/Hamann.xml
File diff suppressed because it is too large
Load Diff
@@ -3,7 +3,7 @@
|
||||
@using System.Threading.Tasks;
|
||||
@using System.Collections.Generic;
|
||||
@using System.Threading;
|
||||
@using System.Linq:
|
||||
@using System.Linq;
|
||||
@using System.Xml.Linq;
|
||||
@using System.IO;
|
||||
|
||||
@@ -32,9 +32,10 @@
|
||||
var currpage = "";
|
||||
var oldpage = "";
|
||||
var commid = 1;
|
||||
var firstedit = true;
|
||||
var active_firstedit = true;
|
||||
var active_trad = false;
|
||||
var skipwhitespace = true;
|
||||
var active_skipwhitespace = true;
|
||||
var active_del = false;
|
||||
List<string> handstrings = new List<string>();
|
||||
|
||||
// Parsing-Combinations
|
||||
@@ -81,7 +82,10 @@
|
||||
( x => x.Name == "sal", (sb, tag) => sb.Append(HTMLHelpers.CreateElement("div", "sal")) ),
|
||||
( x => x.Name == "aq", (sb, tag) => sb.Append(HTMLHelpers.CreateElement("span", "aq")) ),
|
||||
( x => x.Name == "super", (sb, tag) => sb.Append(HTMLHelpers.CreateElement("span", "super")) ),
|
||||
( x => x.Name == "del", (sb, tag) => sb.Append(HTMLHelpers.CreateElement("span", "del")) ),
|
||||
( x => x.Name == "del", (sb, tag) => {
|
||||
sb.Append(HTMLHelpers.CreateElement("span", "del"));
|
||||
active_del = true;
|
||||
} ),
|
||||
( x => x.Name == "nr", (sb, tag) => sb.Append(HTMLHelpers.CreateElement("span", "nr")) ),
|
||||
( x => x.Name == "note", (sb, tag) => sb.Append(HTMLHelpers.CreateElement("span", "note")) ),
|
||||
( x => x.Name == "ul", (sb, tag) => sb.Append(HTMLHelpers.CreateElement("span", "ul")) ),
|
||||
@@ -107,7 +111,7 @@
|
||||
( x => x.Name == "letterTradition", (sb, tag) => sb.Append(HTMLHelpers.CreateElement("div", "tradition")) ),
|
||||
( x => x.Name == "marginal", (sb, tag) => {
|
||||
sb.Append(HTMLHelpers.CreateElement("div", "marginal"));
|
||||
skipwhitespace = !skipwhitespace;
|
||||
active_skipwhitespace = !active_skipwhitespace;
|
||||
}),
|
||||
( x => x.Name == "hand", (sb, tag) => {
|
||||
sb.Append(HTMLHelpers.CreateElement("span", "hand"));
|
||||
@@ -124,7 +128,10 @@
|
||||
( x => x.Name == "sal", (sb, tag) => sb.Append(HTMLHelpers.CreateEndElement("div")) ),
|
||||
( x => x.Name == "aq", (sb, tag) => sb.Append(HTMLHelpers.CreateEndElement("span")) ),
|
||||
( x => x.Name == "super", (sb, tag) => sb.Append(HTMLHelpers.CreateEndElement("span")) ),
|
||||
( x => x.Name == "del", (sb, tag) => sb.Append(HTMLHelpers.CreateEndElement("span")) ),
|
||||
( x => x.Name == "del", (sb, tag) => {
|
||||
sb.Append(HTMLHelpers.CreateEndElement("span"));
|
||||
active_del = false;
|
||||
} ),
|
||||
( x => x.Name == "nr", (sb, tag) => sb.Append(HTMLHelpers.CreateEndElement("span")) ),
|
||||
( x => x.Name == "note", (sb, tag) => sb.Append(HTMLHelpers.CreateEndElement("span")) ),
|
||||
( x => x.Name == "ul", (sb, tag) => sb.Append(HTMLHelpers.CreateEndElement("span")) ),
|
||||
@@ -156,7 +163,12 @@
|
||||
} )
|
||||
};
|
||||
List<(Func<Text, bool>, Action<StringBuilder, Text>)> Text_Funcs = new List<(Func<Text, bool>, Action<StringBuilder, Text>)>() {
|
||||
( x => true, ( sb, txt ) => sb.Append(txt.Value) )
|
||||
( x => true, ( sb, txt ) => {
|
||||
if (active_del)
|
||||
sb.Append(txt.Value.Replace("–", "<span class=\"diagdel\">–</span>"));
|
||||
else
|
||||
sb.Append(txt.Value);
|
||||
} )
|
||||
};
|
||||
List<(Func<Text, bool>, Action<StringBuilder, Text>)> Text_Funcs_Tagging = new List<(Func<Text, bool>, Action<StringBuilder, Text>)>() {
|
||||
( x => true, ( sb, txt ) => {
|
||||
@@ -177,10 +189,10 @@
|
||||
};
|
||||
List<(Func<Whitespace, bool>, Action<StringBuilder, Whitespace>)> Whitespace_Funcs = new List<(Func<Whitespace, bool>, Action<StringBuilder, Whitespace>)>() {
|
||||
( x => true, ( sb, txt ) => {
|
||||
if (skipwhitespace)
|
||||
if (active_skipwhitespace)
|
||||
sb.Append(txt.Value);
|
||||
else
|
||||
skipwhitespace = !skipwhitespace;
|
||||
active_skipwhitespace = !active_skipwhitespace;
|
||||
})
|
||||
};
|
||||
|
||||
@@ -253,7 +265,7 @@
|
||||
|
||||
// Rules for traditions
|
||||
List<(Func<Tag, bool>, Action<StringBuilder, Tag>)> OTag_Funcs_Trad = new List<(Func<Tag, bool>, Action<StringBuilder, Tag>)>() {
|
||||
( x => x.Name == "app", (sb, tag) => { if (!firstedit) { sb.Append(HTMLHelpers.CreateElement("br")); } else { firstedit = false; } } ),
|
||||
( x => x.Name == "app", (sb, tag) => { if (!active_firstedit) { sb.Append(HTMLHelpers.CreateElement("br")); } else { active_firstedit = false; } } ),
|
||||
( x => x.Name == "ZHText", (sb, tag) => {
|
||||
sb_tradition.Append(HTMLHelpers.CreateElement("div", "row zhtext"));
|
||||
sb_tradition.Append(HTMLHelpers.CreateElement("div", "trad-text col order-2 letterbox"));
|
||||
|
||||
@@ -2,15 +2,17 @@
|
||||
-------------------------------------------------- */
|
||||
|
||||
:root {
|
||||
--hamannDunkelGrau: #6e6e6e; /** Dunkelgraue Schriftfarbe zur klaren Abhebung **/
|
||||
--hamannHellGrau: #dddddd; /** Zur Linienführung; Ähnlich dem Hintergrund **/
|
||||
--hamannHellHellGrau: #eeeeee;
|
||||
--hamannLink: #707070; /** Dunkelgraue Schriftfarbe zur leichten Abhebung von Links **/
|
||||
--hamannSehrSchwarz: #414141;
|
||||
--hamannHighlight: #d80000;
|
||||
--hamannLightHighlight: #cc7878;
|
||||
--hamannWeiss: white;
|
||||
--hamannLeichtWeiss: #f2f2f2;
|
||||
--hamannHellHellGrau: #eeeeee;
|
||||
--hamannHellGrau: #dddddd; /** Zur Linienführung; Ähnlich dem Hintergrund **/
|
||||
--hamannGrau: #b1b1b1;
|
||||
--hamannDunkelGrau: #6e6e6e; /** Dunkelgraue Schriftfarbe zur klaren Abhebung **/
|
||||
--hamannLink: #707070; /** Dunkelgraue Schriftfarbe zur leichten Abhebung von Links **/
|
||||
--hamannSehrSchwarz: #414141;
|
||||
--hamannSehrSehrSchwarz: #2e2e2e;
|
||||
--hamannHighlight: #d80000;
|
||||
--hamannLightHighlight: #cc7878;
|
||||
}
|
||||
|
||||
/* Klassen für das Shading von HamannHighlight */
|
||||
@@ -390,6 +392,14 @@ a:hover {
|
||||
line-height: 1rem;
|
||||
}
|
||||
|
||||
.hand .ul,
|
||||
.hand .ul *,
|
||||
.ul .hand,
|
||||
.ul .hand * {
|
||||
/* color: var(--hamannDunkelGrau); */
|
||||
text-decoration-thickness: 1px;
|
||||
}
|
||||
|
||||
.hand .aq {
|
||||
font-size: 1.05rem;
|
||||
}
|
||||
@@ -1032,6 +1042,7 @@ a:hover {
|
||||
.ul * {
|
||||
display: inline;
|
||||
text-decoration: underline;
|
||||
text-decoration-thickness: 1px;
|
||||
text-decoration-skip-ink: auto;
|
||||
-webkit-text-decoration-skip-ink: auto;
|
||||
}
|
||||
@@ -1050,6 +1061,7 @@ a:hover {
|
||||
.dul,
|
||||
.dul * {
|
||||
text-decoration: underline;
|
||||
text-decoration-thickness: 1px;
|
||||
text-decoration-style: double;
|
||||
text-decoration-skip-ink: auto;
|
||||
-webkit-text-decoration-skip-ink: auto;
|
||||
@@ -1058,6 +1070,7 @@ a:hover {
|
||||
.tul,
|
||||
.tul * {
|
||||
text-decoration: underline;
|
||||
text-decoration-thickness: 1px;
|
||||
display: inline;
|
||||
border-bottom: 3px double;
|
||||
}
|
||||
@@ -1075,10 +1088,33 @@ a:hover {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
.diagdel {
|
||||
text-decoration: none;
|
||||
position: relative;
|
||||
display: inline-block;
|
||||
}
|
||||
|
||||
.diagdel::before, .diagdel::after {
|
||||
content: '';
|
||||
width: 100%;
|
||||
height: 0%;
|
||||
position: absolute;
|
||||
right: 0;
|
||||
bottom: 1.5ex;
|
||||
}
|
||||
|
||||
.diagdel::before {
|
||||
border-bottom: 1px solid black;
|
||||
-webkit-transform: skewY(-36deg);
|
||||
transform: skewY(-36deg);
|
||||
}
|
||||
|
||||
|
||||
.del .del,
|
||||
.del .del * {
|
||||
-moz-text-decoration-style: double;
|
||||
-webkit-text-decoration-style: double !important;
|
||||
text-decoration-thickness: 1px;
|
||||
text-decoration-style: double;
|
||||
}
|
||||
|
||||
@@ -1088,12 +1124,14 @@ a:hover {
|
||||
text-decoration: line-through underline;
|
||||
-moz-text-decoration-style: double;
|
||||
-webkit-text-decoration-style: double !important;
|
||||
text-decoration-thickness: 1px;
|
||||
text-decoration-style: double;
|
||||
}
|
||||
|
||||
.del .ul,
|
||||
.ul .del {
|
||||
text-decoration: line-through underline;
|
||||
text-decoration-thickness: 1px;
|
||||
text-decoration-skip-ink: auto;
|
||||
-webkit-text-decoration-skip-ink: auto;
|
||||
}
|
||||
@@ -1794,6 +1832,19 @@ a:hover {
|
||||
font-weight: bolder;
|
||||
}
|
||||
|
||||
.additions .additionbox .edits .edit .reference .added,
|
||||
.additions .additionbox .edits .edit .reference .added * {
|
||||
background-color: var(--hamannGrau);
|
||||
}
|
||||
|
||||
.additions .additionbox .edits .edit .reference .aq,
|
||||
.additions .additionbox .edits .edit .reference .aq * {
|
||||
font-family: Biolinum;
|
||||
font-size: 0.7rem !important;
|
||||
font-weight: bolder;
|
||||
}
|
||||
|
||||
|
||||
.additions .additionbox .edits .edit .zh {
|
||||
font-family: Libertine;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user