◊(Local Yarn Code "Check-in [d42e2609]")

Overview
Comment:Fix verse italic attribute to match docs
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: d42e2609d8086d9d0f78a5d3c0d4d8b3330464c553917cbff707c427e5855aac
User & Date: joel on 2019-06-23 16:40:21
Other Links: manifest | tags
Context
2019-06-23
18:42
Improve disposition marks in notes check-in: f0e18f94 user: joel tags: trunk
16:40
Fix verse italic attribute to match docs check-in: d42e2609 user: joel tags: trunk
2019-06-20
01:17
Rename smallcaps→caps, add saylines tag check-in: 374734ed user: joel tags: trunk
Changes

Modified tags-html.rkt from [38504446] to [d9318d98].

121
122
123
124
125
126
127
128
129
130
131
132
133
134
135

;; Same as ◊say, but preserve linebreaks
(define (html-saylines . elems)
  (apply html-say (decode-linebreaks elems)))

(define (html-verse attrs elems)
  (let* ([title  (maybe-attr 'title attrs "")]
         [italic? (assoc 'italic attrs)]
         [pre-attrs (cond [italic? '([class "verse"] [style "font-style: italic"])]
                          [else '([class "verse"])])]
         [pre-title (cond [(string>? title "") `(p [[class "verse-heading"]] ,title)]
                          [else ""])])
    `(div [[class "poem"]] ,pre-title (pre ,pre-attrs ,@elems))))

;; (Private) Get the dimensions of an image file







|







121
122
123
124
125
126
127
128
129
130
131
132
133
134
135

;; Same as ◊say, but preserve linebreaks
(define (html-saylines . elems)
  (apply html-say (decode-linebreaks elems)))

(define (html-verse attrs elems)
  (let* ([title  (maybe-attr 'title attrs "")]
         [italic? (assoc 'italic? attrs)]
         [pre-attrs (cond [italic? '([class "verse"] [style "font-style: italic"])]
                          [else '([class "verse"])])]
         [pre-title (cond [(string>? title "") `(p [[class "verse-heading"]] ,title)]
                          [else ""])])
    `(div [[class "poem"]] ,pre-title (pre ,pre-attrs ,@elems))))

;; (Private) Get the dimensions of an image file