Support ATTR_HTML above quote blocks

master
Kaushal Modi 8 years ago
parent ebfca1eed5
commit a2d43f3beb
  1. 15
      ox-blackfriday.el
  2. 13
      test/site/content-org/all-posts.org
  3. 17
      test/site/content/posts/quote-blocks-with-attr-html.md

@ -563,13 +563,16 @@ communication channel."
(let* ((next (org-export-get-next-element quote-block info))
(next-type (org-element-type next))
(next-is-quote (eq 'quote-block next-type))
(contents (org-md-quote-block quote-block contents info)))
(contents (org-md-quote-block quote-block contents info))
ret)
;; (message "[ox-bf quote-block DBG]")
(concat contents
;; Two consecutive blockquotes in Markdown can be
;; separated by a comment.
(when next-is-quote
"\n\n<!--quoteend-->"))))
(setq ret (org-blackfriday--div-wrap-maybe quote-block contents))
(setq ret (concat ret
;; Two consecutive blockquotes in Markdown can be
;; separated by a comment.
(when next-is-quote
"\n\n<!--quoteend-->")))
ret))
;;;; Special Block
(defun org-blackfriday-special-block (special-block contents _info)

@ -2583,6 +2583,19 @@ Some quoted text.
#+END_EXAMPLE
#+END_QUOTE
Some other text.
** Quote blocks with ATTR_HTML :attr___html:attr___css:
:PROPERTIES:
:EXPORT_FILE_NAME: quote-blocks-with-attr-html
:END:
Some text.
#+ATTR_HTML: :class red-text
#+ATTR_CSS: :color red
#+BEGIN_QUOTE
This is a red quote.
#+END_QUOTE
Some more text.
* Verse :verse:
** One verse
:PROPERTIES:

@ -0,0 +1,17 @@
+++
title = "Quote blocks with ATTR_HTML"
tags = ["quotes", "attr_html", "attr_css"]
draft = false
+++
Some text.
<style>.red-text { color: red; }</style>
<div class="red-text">
<div></div>
> This is a red quote.
</div>
Some more text.
Loading…
Cancel
Save