hexo/themes/blank/layout/partial/link.ejs

21 lines
1.1 KiB
Plaintext
Raw Normal View History

2024-05-09 10:56:56 +08:00
<% if (site.data.links){ %>
<div id="links">
<div class="links-content">
<div class="link-navigation">
<% for (var i in site.data.links) { %>
<div class="card">
<% if(theme.lazyload.enable) {%>
<img class="ava" data-src="<%= site.data.links[i].avatar %>" onerror=this.onerror=null,this.src="<%= url_for(theme.lazyload.image) %>">
<% } else { %>
<img class="ava" src="<%= site.data.links[i].avatar %>" onerror=this.onerror=null,this.src="<%= url_for(theme.lazyload.image) %>">
<% } %>
<div class="card-header">
<div><a href="<%= site.data.links[i].link %>" target="_blank" title="<%= site.data.links[i].name %>"><%= site.data.links[i].name %></a></div>
<div class="info" title="<%= site.data.links[i].info %>"><%= site.data.links[i].info %></div>
</div>
</div>
<% } %>
</div>
</div>
<% } %>
<%- page.content %>