Hi, The idea there, is to be able to convert both html (generated by a rich text editor) and markdown (or other similar markup language) file through a similar pipeline to a pdf with similar style. Using a different templating engine somewhere in the pipeline mean more complexity, so i'm considering the idea of using pandoc templating if the html result is okay. Thanks. Le lundi 27 juin 2022 à 11:55:12 UTC+2, suki...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org a écrit : > Hi, > > What are you trying to do? Pandoc's markdown (and so Pandoc itself) > supports codeblocks (pre or code, I don't remember), divs and spans with > attributes (and I believe headers too). I think paragraphs can't have > attributes. > > Cheers, > > Sukil > > > El 27/06/2022 a las 11:42, 'guenael Muller' via pandoc-discuss escribió: > > Hello all, > > Up from the future (10 years !) > > I have a similar issue now with playing with pandoc and weasyprint using > pandoc for the templating. > What seems to be a bit curious, is that some html attribute are stripped > off and some are not. > > Example: > >
Just some > text
>Just some text
>Just some text
>Just some text
>with different classes.) >> >> Not focusing specifically on HTML, I think that pandoc should allow to >> uniquely identify, add to a class and set the language to any element, >> desired text span or division. >> >> I know that this is related to a couple of messages I sent yesterday. >> Sorry for repeating myself, but these are basic features to write >> documents. >> >> From the documentation perspective, it would be to apply the type Attr >> to any constructor from data Block and Inline. And to data TableCell. >> >> Although language could be defined as a key-value pair in type Attr, I >> think is clearer to define a new specific language attribute. >> >> Is there anything wrong with this approach? >> >> Many thanks for your help, >> >> >> >> Pablo >> >> On 11/11/12 23:36, John MacFarlane wrote: >> > You've got to remember that pandoc converts the input format to an >> > internal representation of the document (the 'Pandoc' structure), and >> > then converts that to the output format. >> > >> > This internal representation (see >> > >> http://hackage.haskell.org/packages/archive/pandoc-types/1.9.1/doc/html/Text-Pandoc-Definition.html) >> >> > is much less expressive than HTML, and doesn't have a place for the >> > attributes you want. That's why they are lost on HTML -> HTML >> > translation. >> > >> > +++ Pablo Rodríguez [Nov 11 12 12:19 ]: >> >> Hi John, >> >> >> >> I'm using pandoc mainly to generate ePub files. >> >> >> >> I used textile first as source language, but it isn't fully >> implemented >> >> by pandoc and textile itself has issues with multiparagraph elements. >> >> >> >> It seems HTML is probably a much better option for pandoc as source >> >> language, although I have to forget footnotes. There is no way to have >> >> it all. >> >> >> >> But pandoc strips almost all attributes from HTML elements. >> >> >> >> A minimal sample: >> >> >> >>
Well there is no other way to tag lingua >> >> latina.
>> >>Or even classes or ids.
.