This repository was archived by the owner on Aug 14, 2024. It is now read-only.
File tree 3 files changed +322
-333
lines changed
3 files changed +322
-333
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " nyanga-read" ,
3
- "version" : " 3.0.4 " ,
3
+ "version" : " 3.0.8 " ,
4
4
"author" : {
5
5
"email" : " idnatte@gmail.com" ,
6
6
"name" : " IDNatte" ,
21
21
},
22
22
"devDependencies" : {
23
23
"@sveltejs/adapter-static" : " ^2.0.2" ,
24
- "@sveltejs/kit" : " ^1.22.3 " ,
24
+ "@sveltejs/kit" : " ^2.5.10 " ,
25
25
"@tailwindcss/typography" : " ^0.5.9" ,
26
26
"@types/cookie" : " ^0.5.1" ,
27
27
"@types/lodash" : " ^4.14.195" ,
28
28
"@types/showdown" : " ^2.0.1" ,
29
29
"@typescript-eslint/eslint-plugin" : " ^6.1.0" ,
30
- "@typescript-eslint/parser" : " ^6.1 .0" ,
30
+ "@typescript-eslint/parser" : " ^7.10 .0" ,
31
31
"autoprefixer" : " ^10.4.14" ,
32
32
"eslint" : " ^8.45.0" ,
33
33
"eslint-config-prettier" : " ^8.8.0" ,
34
34
"eslint-plugin-svelte3" : " ^4.0.0" ,
35
- "lodash" : " ^4.17.21 " ,
35
+ "lodash" : " ^4.17.4 " ,
36
36
"postcss" : " ^8.4.27" ,
37
37
"prettier" : " ^2.8.8" ,
38
38
"prettier-plugin-svelte" : " ^2.10.1" ,
39
39
"showdown" : " ^2.1.0" ,
40
40
"svelte" : " ^3.59.2" ,
41
- "svelte-check" : " ^3.4.6 " ,
41
+ "svelte-check" : " ^3.7.1 " ,
42
42
"svelte-french-toast" : " ^1.2.0" ,
43
43
"svelte-i18n" : " ^4.0.0" ,
44
44
"tailwindcss" : " ^3.3.3" ,
45
45
"tslib" : " ^2.6.0" ,
46
46
"typescript" : " ^5.1.6" ,
47
- "vite" : " ^5.2.8 "
47
+ "vite" : " ^5.2.11 "
48
48
},
49
49
"type" : " module"
50
50
}
Original file line number Diff line number Diff line change 1
1
<script lang =" ts" >
2
- import { onMount , createEventDispatcher } from ' svelte' ;
3
2
import loaderStore from ' $lib/store/loader/loader.store' ;
3
+ import { createEventDispatcher , onMount } from ' svelte' ;
4
4
5
5
export let alt: string | null | undefined ;
6
6
export let src: string | null | undefined ;
9
9
const dispatch: any = createEventDispatcher ();
10
10
let loaded: boolean = false ;
11
11
let thisImage: HTMLImageElement ;
12
+ let error: boolean = false
12
13
13
14
loaderStore .set (' loading' );
14
15
onMount (() => {
24
25
thisImage .onerror = () => {
25
26
dispatch (' imageloaderror' );
26
27
loaded = false ;
28
+ error = true
27
29
};
28
30
});
29
31
</script >
30
32
33
+ {#if ! loaded }
34
+ <div class =" animate-pulse bg-slate-200 w-full min-h-[580px] rounded" >
35
+ </div >
36
+ {/if }
37
+
31
38
<img {src } {alt } class:loaded class ={className } bind:this ={thisImage } loading =" lazy" />
32
39
33
40
<style >
You can’t perform that action at this time.
0 commit comments