Makers: Improve hyphenation
[ccbib.git] / pandocTools / extractRaw.hs
blob48d1b52196477088953d78a63a422e6bfd705978
1 -- extractRaw.hs
2 import Text.Pandoc
4 class RawContainer a where
5 extractRaw :: a -> [String]
7 instance RawContainer Inline where
8 extractRaw (HtmlInline s) = [s]
9 extractRaw _ = []
11 instance RawContainer Block where
12 extractRaw (RawHtml s) = [s]
13 extractRaw _ = []
15 readDoc = readHtml defaultParserState{
16 stateParseRaw=True
19 main = interact (unlines . queryWith extractRaw . readDoc)