Commit ff28b6eb authored by Chris Lamb's avatar Chris Lamb 💬

Revert "Correction to HTML markup warnings/errors: fix empty value for...

Revert "Correction to HTML markup warnings/errors: fix empty value for attributte name on 'a' tags and add an id to the nearest div containers."

This reverts commit a6fd6b33; not sure how this
ended up on master (?) given it's on an MR..?

Gbp-Dch: ignore
parent a6fd6b33
Pipeline #40031 passed with stage
in 15 minutes and 52 seconds
......@@ -157,14 +157,11 @@ def output_visual(visual, path, indentstr, indentnum):
logger.debug('including image for %s', visual.source)
indent = tuple(indentstr * (indentnum + x) for x in range(3))
anchor = output_anchor(path)
id = ""
if anchor:
id = u"""id=\"{0}\"""".format(anchor)
return u"""{0[0]}<div class="difference">
{0[1]}<div class="diffheader">
{0[1]}<div class="diffcontrol">⊟</div>
{0[1]}<div {5}><span class="source">{1}</span>
{0[2]}<a class="anchor" href="#{2}">\xb6</a>
{0[1]}<div><span class="source">{1}</span>
{0[2]}<a class="anchor" href="#{2}" name="{2}">\xb6</a>
{0[1]}</div>
{0[1]}</div>
{0[1]}<div class="difference"><img src=\"data:{3},{4}\" alt=\"compared images\" /></div>
......@@ -174,16 +171,12 @@ def output_visual(visual, path, indentstr, indentnum):
anchor,
visual.data_type,
visual.content,
id,
)
def output_node_frame(difference, path, indentstr, indentnum, body):
indent = tuple(indentstr * (indentnum + x) for x in range(3))
anchor = output_anchor(path)
id = ""
if anchor:
id = u"""id=\"{0}\"""".format(anchor)
dctrl_class, dctrl = (
("diffcontrol", u'⊟')
if difference.has_visible_children()
......@@ -192,8 +185,8 @@ def output_node_frame(difference, path, indentstr, indentnum, body):
if difference.source1 == difference.source2:
header = u"""{0[1]}<div class="{1}">{2}</div>
{0[1]}<div><span class="diffsize">{3}</span></div>
{0[1]}<div {6}><span class="source">{5}</span>
{0[2]}<a class="anchor" href="#{4}">\xb6</a>
{0[1]}<div><span class="source">{5}</span>
{0[2]}<a class="anchor" href="#{4}" name="{4}">\xb6</a>
{0[1]}</div>
""".format(
indent,
......@@ -202,14 +195,13 @@ def output_node_frame(difference, path, indentstr, indentnum, body):
sizeof_fmt(difference.size()),
anchor,
html.escape(difference.source1),
id,
)
else:
header = u"""{0[1]}<div class="{1} diffcontrol-double">{2}</div>
{0[1]}<div><span class="diffsize">{3}</span></div>
{0[1]}<div><span class="source">{5}</span> vs.</div>
{0[1]}<div {7}><span class="source">{6}</span>
{0[2]}<a class="anchor" href="#{4}">\xb6</a>
{0[1]}<div><span class="source">{6}</span>
{0[2]}<a class="anchor" href="#{4}" name="{4}">\xb6</a>
{0[1]}</div>
""".format(
indent,
......@@ -219,7 +211,6 @@ def output_node_frame(difference, path, indentstr, indentnum, body):
anchor,
html.escape(difference.source1),
html.escape(difference.source2),
id,
)
return PartialString.numl(
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment