diff options
| Commit | a1c2d8fe71cb1585a917424bacd4aed35d389cc2 (patch) | |
|---|---|---|
| Author | 2024-02-28 10:38:40 +0200 | |
| Committer | 2024-02-28 10:38:40 +0200 | |
| Files | 254214cadfe4ea97486beb6854ee09aa5bc248f0 | |
| syndamia.com-a1c2d8fe71cb1585a917424bacd4aed35d389cc2.tar syndamia.com-a1c2d8fe71cb1585a917424bacd4aed35d389cc2.tar.gz syndamia.com-a1c2d8fe71cb1585a917424bacd4aed35d389cc2.zip | ||
| Parent | 65761da843606786bbd2f38f4e22a7ea117a6644 (diff) | |
[awk-edits/MEL-Teaching] Added special styles and single line tag for teaching articles
2 files changed, 22 insertions, 0 deletions
| -rw-r--r-- | awk-edits/MEL-Teaching.awk | 8 | ||||
| -rw-r--r-- | src/styles.csma | 14 |
diff --git a/awk-edits/MEL-Teaching.awk b/awk-edits/MEL-Teaching.awk new file mode 100644 index 0000000..245d6fa --- /dev/null +++ b/awk-edits/MEL-Teaching.awk @@ -0,0 +1,8 @@ +# .*teaching/.*html + +BEGIN { + usesMEL() + + MEL["solution-link", MELLINEOPEN] = "<div class=\"exercise-solution\"><" + MEL["solution-link", MELLINECLOSE] = " ></div>" +} diff --git a/src/styles.csma b/src/styles.csma index 2b8f9d3..764e2ec 100644 --- a/src/styles.csma +++ b/src/styles.csma @@ -257,6 +257,7 @@ <Contents in page> {} <Pagenav> {} <Paragraphs with icons> {} + <Teaching> {} <Page specific> {} <Headers> @@ -345,6 +346,19 @@ } <Article> { +<Teaching> { + .exercise-solution { + float: right; + font-weight: bold; + } + + /* Slightly smaller than browser defaults https://stackoverflow.com/a/70720104/12036073 https://stackoverflow.com/a/47560151/12036073 */ + h2 ~ .exercise-solution { font-size: 1.4em; margin-top: 0.6em; } + h3 ~ .exercise-solution { font-size: 1.1em; margin-top: 0.8em; } +} +} + +<Article> { <Page specific> { <About page> { |