mirror of
https://github.com/danbulant/api_docs
synced 2026-06-18 22:01:13 +00:00
Fix data-title attribute for H2 elements in TOC (#884)
I believe the data-title attribute for H2 elements was mistakenly using the parent H1 content as its value, rather than its own content.
This commit is contained in:
parent
bdf8548cc7
commit
adf815e35f
1 changed files with 1 additions and 1 deletions
|
|
@ -77,7 +77,7 @@ under the License.
|
||||||
<ul class="toc-list-h2">
|
<ul class="toc-list-h2">
|
||||||
<% h1[:children].each do |h2| %>
|
<% h1[:children].each do |h2| %>
|
||||||
<li>
|
<li>
|
||||||
<a href="#<%= h2[:id] %>" class="toc-h2 toc-link" data-title="<%= h1[:content] %>"><%= h2[:content] %></a>
|
<a href="#<%= h2[:id] %>" class="toc-h2 toc-link" data-title="<%= h2[:content] %>"><%= h2[:content] %></a>
|
||||||
</li>
|
</li>
|
||||||
<% end %>
|
<% end %>
|
||||||
</ul>
|
</ul>
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue