示例#1
0
        public override void Render(Context context, System.IO.TextWriter result)
        {
            if (FootnoteCore.Footnotes.Count != 0)
            {
                result.Write("<div class=\"footnotes\"><hr /><ol>");

                foreach (var footnote in FootnoteCore.Footnotes)
                {
                    result.Write($"<li id=\"fn:{footnote.Key}\">\n\n{footnote.Value}\n\n</li>");
                }

                result.Write("</ol></div>");
                FootnoteCore.Clear();
            }
        }
示例#2
0
        public override void Initialize(string tagName, string markup, List <string> tokens)
        {
            base.Initialize(tagName, markup, tokens);

            this.id = FootnoteCore.AddFootnote(markup.Trim());
        }