FIX: Resolve Schema.org validation issues

This commit is contained in:
Dan Ungureanu 2020-05-05 16:56:04 +03:00
parent 8010e1ab2e
commit 1019789d1a
No known key found for this signature in database
GPG Key ID: 0AA2A00D6ACC8B84
3 changed files with 28 additions and 7 deletions

View File

@ -1,4 +1,5 @@
<div itemscope itemtype='http://schema.org/ItemList'>
<meta itemprop='itemListOrder' content='http://schema.org/ItemListOrderDescending'>
<table class='category-list'>
<thead>
<tr>
@ -7,7 +8,6 @@
</tr>
</thead>
<tbody>
<meta itemprop='itemListOrder' content='http://schema.org/ItemListOrderDescending'>
<% @category_list.categories.each_with_index do |c, index| %>
<tr>
<td class='category' style='border-color: #<%= c.color %>;'>

View File

@ -36,11 +36,31 @@
<footer class="container wrap">
<nav class='crawler-nav'>
<ul>
<li itemscope itemtype='http://schema.org/SiteNavigationElement' itemprop="name"><a href='<%= path "/" %>' itemprop="url"><%= t 'home_title' %> </a></li>
<li itemscope itemtype='http://schema.org/SiteNavigationElement' itemprop="name"><a href='<%= path "/categories" %>' itemprop="url"><%= t 'js.filters.categories.title' %> </a></li>
<li itemscope itemtype='http://schema.org/SiteNavigationElement' itemprop="name"><a href='<%= path "/guidelines" %>' itemprop="url"><%= t 'guidelines_topic.title' %> </a></li>
<li itemscope itemtype='http://schema.org/SiteNavigationElement' itemprop="name"><a href='<%= path "/tos" %>' itemprop="url"><%= t 'tos_topic.title' %> </a></li>
<li itemscope itemtype='http://schema.org/SiteNavigationElement' itemprop="name"><a href='<%= path "/privacy" %>' itemprop="url"><%= t 'privacy_topic.title' %> </a></li>
<li itemscope itemtype='http://schema.org/SiteNavigationElement'>
<span itemprop='name'>
<a href='<%= path "/" %>' itemprop="url"><%= t 'home_title' %> </a>
</span>
</li>
<li itemscope itemtype='http://schema.org/SiteNavigationElement'>
<span itemprop='name'>
<a href='<%= path "/categories" %>' itemprop="url"><%= t 'js.filters.categories.title' %> </a>
</span>
</li>
<li itemscope itemtype='http://schema.org/SiteNavigationElement'>
<span itemprop='name'>
<a href='<%= path "/guidelines" %>' itemprop="url"><%= t 'guidelines_topic.title' %> </a>
</span>
</li>
<li itemscope itemtype='http://schema.org/SiteNavigationElement'>
<span itemprop='name'>
<a href='<%= path "/tos" %>' itemprop="url"><%= t 'tos_topic.title' %> </a>
</span>
</li>
<li itemscope itemtype='http://schema.org/SiteNavigationElement'>
<span itemprop='name'>
<a href='<%= path "/privacy" %>' itemprop="url"><%= t 'privacy_topic.title' %> </a>
</span>
</li>
</ul>
</nav>
<p class='powered-by-link'><%= t 'powered_by_html' %></p>

View File

@ -39,6 +39,8 @@
<% end %>
<div itemscope itemtype='http://schema.org/ItemList'>
<meta itemprop='itemListOrder' content='http://schema.org/ItemListOrderDescending'>
<table class='topic-list'>
<thead>
@ -52,7 +54,6 @@
</thead>
<tbody>
<meta itemprop='itemListOrder' content='http://schema.org/ItemListOrderDescending'>
<% @list.topics.each_with_index do |t,i| %>
<tr class="topic-list-item">
<td class="main-link" itemprop='itemListElement' itemscope itemtype='http://schema.org/ListItem'>