From f9c3b3d5056031fa5f0fbced5b630541a38597c6 Mon Sep 17 00:00:00 2001 From: Oliverpool Date: Thu, 22 Oct 2015 08:52:48 +0200 Subject: [PATCH] Improve html template --- .../songs/chordpro/data/html/content_verse | 8 ++- test/test_chordpro/newline.html | 53 ++++++++----------- 2 files changed, 30 insertions(+), 31 deletions(-) diff --git a/patacrep/songs/chordpro/data/html/content_verse b/patacrep/songs/chordpro/data/html/content_verse index 6fe21f6b..2b3e6fe3 100644 --- a/patacrep/songs/chordpro/data/html/content_verse +++ b/patacrep/songs/chordpro/data/html/content_verse @@ -1,5 +1,11 @@ +(* if content.directive() *) +

+(*- elif content.nolyrics -*) +

+(*- else *)

- (* for line in content.lines *) +(*- endif *) + (* for line in content.lines -*) (( render(line) )) (*- if not loop.last *)
(* endif *) diff --git a/test/test_chordpro/newline.html b/test/test_chordpro/newline.html index aca33fa6..5540af64 100644 --- a/test/test_chordpro/newline.html +++ b/test/test_chordpro/newline.html @@ -1,50 +1,43 @@ + Lang: en

-

- This is a verse
- With a new line
-
- The second part of the verse
- Is this line +

This is a verse
+With a new line
+
+The second part of the verse
+Is this line

-

- Here is a new line at the end
- +

Here is a new line at the end
+

-

- Foo bar +

Foo bar

-

-
- And a new line
- At the beginning +


+And a new line
+At the beginning

-

- New lines can also
-
- Be in chorus +

New lines can also
+
+Be in chorus

-

- New lines can also
-
- Be in bridges +

New lines can also
+
+Be in bridges

-

- New lines can also
-
- Be surrounded by spaces +

New lines can also
+
+Be surrounded by spaces

-

- New lines cannot +

New lines cannot

-
+ \ No newline at end of file