~ryanford/git-blog-tup

e7039b1d7f546cf390f99ce2141c62aa607d4163 — Ryan Ford 3 years ago 1a04d26
add capture in pre
1 files changed, 3 insertions(+), 3 deletions(-)

M plugins/minify_html
M plugins/minify_html => plugins/minify_html +3 -3
@@ 30,9 30,9 @@ local document = P{
   "document",
   document = Ct((V"doctype" * V"html" ^ 0) + (V"html" ^ 1)) / table.concat,
   html = V"comment" + V"void_element" + V"self_closing" + V"pre" + V"start_tag" + V"close_tag" + V"whitespace" + V"text_node",
   pre = C(V"start_pre" * (1 - V"close_pre") ^ 0 * V"close_pre"),
   start_pre = P"<" * any_case"pre" * (V"whitespace" * V"modifiers") ^ -1 * V"optional_space" * P">",
   close_pre = P"</" * any_case"pre" * V"optional_space" * P">",
   pre = Ct(V"start_pre" * C(1 - V"close_pre") ^ 0 * V"close_pre") / unpack,
   start_pre = Ct(C(P"<") * C(any_case"pre") * (V"whitespace" * V"modifiers") ^ -1 * V"optional_space" * C(P">")) / unpack,
   close_pre = Ct(C(P"</") * C(any_case"pre") * V"optional_space" * C(P">")) / unpack,
   text_node = C(P(1 - (space ^ 2 + V"comment" + V"start_tag" + V"close_tag" + V"void_element")) ^ 1),
   start_tag = Ct(C(P"<") * V"optional_space" *  C(V"tag_name") * (V"whitespace" * V"modifiers") ^ -1 * V"optional_space" * C(P">")) / unpack,
   close_tag = Ct(C(P"</") * V"optional_space" * C(V"tag_name") * V"optional_space" * C(P">")) / unpack,