mirror of
https://github.com/gohugoio/hugo.git
synced 2026-08-25 07:48:52 +00:00
Fix featherlight to avoid icon images
This commit is contained in:
Vendored
+2
-2
File diff suppressed because one or more lines are too long
@@ -9,7 +9,7 @@
|
||||
<a href="{{ $values.url }}">
|
||||
<section>
|
||||
<div class="homepage-card-image-wrapper">
|
||||
<img src="/images/hugo-icons/{{ $values.url }}.svg" alt="">
|
||||
<img class="hugo-icon" src="/images/hugo-icons/{{ $values.url }}.svg" alt="">
|
||||
</div>
|
||||
<div class="homepage-card-copy">
|
||||
<header>
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
<div class="list-icon-wrapper">
|
||||
<img src="{{$.Site.BaseURL}}images/hugo-icons/{{.Section}}.svg" alt="">
|
||||
<img class="hugo-icon" src="{{$.Site.BaseURL}}images/hugo-icons/{{.Section}}.svg" alt="">
|
||||
</div>
|
||||
@@ -5,9 +5,9 @@
|
||||
* Copyright 2016, Noël Raoul Bossart (http://www.noelboss.com)
|
||||
* MIT Licensed.
|
||||
**/
|
||||
// Modification IIFE for digital.cap.org to wrap all images in feather anchor first
|
||||
// Modification IIFE for gohugo.il to wrap all images in feather anchor first; this only applies to img within body copy
|
||||
(function() {
|
||||
$('.body-copy img').each(function() {
|
||||
$('.body-copy img:not(.hugo-icon)').each(function() {
|
||||
$(this).wrap('<a class=\"image-link\" data-featherlight=\"image\" href=\"' + $(this).attr('src') + '\"></a>');
|
||||
});
|
||||
})();
|
||||
|
||||
Reference in New Issue
Block a user