Module: MMMD::Renderers::HTMLConstants

Defined in:
lib/mmmd/renderers/html.rb

Defined Under Namespace

Classes: MapManager

Constant Summary collapse

ELEMENT_MAP =
{
  "PointBlank::DOM::InlinePre" => {
    tag: "code",
    style: "white-space: pre;"
  },
  "PointBlank::DOM::InlineBreak" => {
    tag: "br"
  },
  "PointBlank::DOM::InlineStrong" => {
    tag: "strong"
  },
  "PointBlank::DOM::InlineEmphasis" => {
    tag: "em"
  },
  "PointBlank::DOM::InlineUnder" => {
    tag: "span",
    style: "text-decoration: underline;"
  },
  "PointBlank::DOM::InlineStrike" => {
    tag: "s"
  },
  "PointBlank::DOM::InlineLink" => {
    tag: "a",
    href: true,
    title: true
  },
  "PointBlank::DOM::InlineImage" => {
    tag: "img",
    src: true,
    inline: true,
    alt: true,
    title: true
  },
  "PointBlank::DOM::ULBlock" => {
    tag: "ul"
  },
  "PointBlank::DOM::OLBlock" => {
    tag: "ol"
  },
  "PointBlank::DOM::IndentBlock" => {
    tag: "pre"
  },
  "PointBlank::DOM::ULListElement" => {
    tag: "li"
  },
  "PointBlank::DOM::OLListElement" => {
    tag: "li"
  },
  "PointBlank::DOM::Paragraph" => {
    tag: "p"
  },
  "PointBlank::DOM::SetextHeading1" => {
    tag: "h1"
  },
  "PointBlank::DOM::SetextHeading2" => {
    tag: "h2"
  },
  "PointBlank::DOM::ATXHeading1" => {
    tag: "h1"
  },
  "PointBlank::DOM::ATXHeading2" => {
    tag: "h2"
  },
  "PointBlank::DOM::ATXHeading3" => {
    tag: "h3"
  },
  "PointBlank::DOM::ATXHeading4" => {
    tag: "h4"
  },
  "PointBlank::DOM::ATXHeading5" => {
    tag: "h5"
  },
  "PointBlank::DOM::ATXHeading6" => {
    tag: "h6"
  },
  "PointBlank::DOM::Document" => {
    tag: "main"
  },
  "PointBlank::DOM::CodeBlock" => {
    tag: "pre",
    outer: {
      tag: "code"
    }
  },
  "PointBlank::DOM::QuoteBlock" => {
    tag: "blockquote"
  },
  "PointBlank::DOM::HorizontalRule" => {
    tag: "hr",
    inline: true
  },
  "PointBlank::DOM::Text" => {
    sanitize: true
  },
  "PointBlank::DOM::InlineAutolink" => {
    tag: "a",
    href: true
  }
}.freeze