gatsby-core-theme 2.0.13 → 2.0.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +10 -0
- package/package.json +1 -1
- package/src/hooks/lazy-image/index.js +27 -15
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,13 @@
|
|
|
1
|
+
## [2.0.14](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/compare/v2.0.13...v2.0.14) (2022-01-05)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* lazy image no script tag ([3b47ad0](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/3b47ad093423a1ef58cd0b9dfedee22f83367552))
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
* Merge branch 'master' of git.ilcd.rocks:team-floyd/themes/gatsby-themes ([a60dbce](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/commit/a60dbce4848d3446f115001b5fea0c4269c1a233))
|
|
10
|
+
|
|
1
11
|
## [2.0.13](https://git.ilcd.rocks/team-floyd/themes/gatsby-themes/compare/v2.0.12...v2.0.13) (2022-01-05)
|
|
2
12
|
|
|
3
13
|
|
package/package.json
CHANGED
|
@@ -23,21 +23,33 @@ export default function LazyImage({
|
|
|
23
23
|
if (!isNativeImageLazyLoadingSupported()) {
|
|
24
24
|
const LazyLoad = loadable(() => import(`react-lazyload`));
|
|
25
25
|
return (
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
26
|
+
<>
|
|
27
|
+
<LazyLoad
|
|
28
|
+
height={height ? `${height}px` : null}
|
|
29
|
+
width={width ? `${width}px` : null}
|
|
30
|
+
placeholder={<span className="lazyload-placeholder" />}
|
|
31
|
+
debounce={0}
|
|
32
|
+
>
|
|
33
|
+
<img
|
|
34
|
+
src={src}
|
|
35
|
+
className={className}
|
|
36
|
+
height={height}
|
|
37
|
+
width={width}
|
|
38
|
+
alt={alt}
|
|
39
|
+
style={style}
|
|
40
|
+
/>
|
|
41
|
+
</LazyLoad>
|
|
42
|
+
<noscript>
|
|
43
|
+
<img
|
|
44
|
+
src={src}
|
|
45
|
+
className={className}
|
|
46
|
+
height={height}
|
|
47
|
+
width={width}
|
|
48
|
+
alt={alt}
|
|
49
|
+
style={style}
|
|
50
|
+
/>
|
|
51
|
+
</noscript>
|
|
52
|
+
</>
|
|
41
53
|
);
|
|
42
54
|
}
|
|
43
55
|
|