Fix layout section attribute tags (#401)

* Fix attribute tags

* Update test date to expect attribute with ac: prefix
This commit is contained in:
Stephen Paulger 2023-12-19 12:57:52 +00:00 committed by GitHub
parent 21d76ec25a
commit aaae918478
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 12 additions and 12 deletions

View File

@ -45,22 +45,22 @@ func (r *ConfluenceHTMLBlockRenderer) renderHTMLBlock(w util.BufWriter, source [
_, _ = w.WriteString("</ac:layout>\n")
return ast.WalkContinue, nil
case "<!-- ac:layout-section type:single -->":
_, _ = w.WriteString("<ac:layout-section type=\"single\">\n")
_, _ = w.WriteString("<ac:layout-section ac:type=\"single\">\n")
return ast.WalkContinue, nil
case "<!-- ac:layout-section type:two_equal -->":
_, _ = w.WriteString("<ac:layout-section type=\"two_equal\">\n")
_, _ = w.WriteString("<ac:layout-section ac:type=\"two_equal\">\n")
return ast.WalkContinue, nil
case "<!-- ac:layout-section type:two_left_sidebar -->":
_, _ = w.WriteString("<ac:layout-section type=\"two_left_sidebar\">\n")
_, _ = w.WriteString("<ac:layout-section ac:type=\"two_left_sidebar\">\n")
return ast.WalkContinue, nil
case "<!-- ac:layout-section type:two_right_sidebar -->":
_, _ = w.WriteString("<ac:layout-section type=\"two_right_sidebar\">\n")
_, _ = w.WriteString("<ac:layout-section ac:type=\"two_right_sidebar\">\n")
return ast.WalkContinue, nil
case "<!-- ac:layout-section type:three -->":
_, _ = w.WriteString("<ac:layout-section type=\"three\">\n")
_, _ = w.WriteString("<ac:layout-section ac:type=\"three\">\n")
return ast.WalkContinue, nil
case "<!-- ac:layout-section type:three_with_sidebars -->":
_, _ = w.WriteString("<ac:layout-section type=\"three_with_sidebars\">\n")
_, _ = w.WriteString("<ac:layout-section ac:type=\"three_with_sidebars\">\n")
return ast.WalkContinue, nil
case "<!-- ac:layout-section end -->":
_, _ = w.WriteString("</ac:layout-section>\n")

View File

@ -1,5 +1,5 @@
<ac:layout>
<ac:layout-section type="three_with_sidebars">
<ac:layout-section ac:type="three_with_sidebars">
<ac:layout-cell>
<p>More Content</p>
</ac:layout-cell>
@ -10,7 +10,7 @@
<p>Even More Content</p>
</ac:layout-cell>
</ac:layout-section>
<ac:layout-section type="single">
<ac:layout-section ac:type="single">
<ac:layout-cell>
<p>Still More Content</p>
</ac:layout-cell>

View File

@ -1,5 +1,5 @@
<ac:layout>
<ac:layout-section type="three_with_sidebars">
<ac:layout-section ac:type="three_with_sidebars">
<ac:layout-cell>
<p>More Content</p>
</ac:layout-cell>
@ -10,7 +10,7 @@
<p>Even More Content</p>
</ac:layout-cell>
</ac:layout-section>
<ac:layout-section type="single">
<ac:layout-section ac:type="single">
<ac:layout-cell>
<p>Still More Content</p>
</ac:layout-cell>

View File

@ -1,5 +1,5 @@
<ac:layout>
<ac:layout-section type="three_with_sidebars">
<ac:layout-section ac:type="three_with_sidebars">
<ac:layout-cell>
<p>More Content</p>
</ac:layout-cell>
@ -10,7 +10,7 @@
<p>Even More Content</p>
</ac:layout-cell>
</ac:layout-section>
<ac:layout-section type="single">
<ac:layout-section ac:type="single">
<ac:layout-cell>
<p>Still More Content</p>
</ac:layout-cell>