@@ -27,10 +27,10 @@ export class CatMangaParser {
2727return mangaTiles ;
2828}
2929
30- parseFeatured ( $ :CheerioStatic ) {
30+ parseFeatured ( $ :CheerioStatic , base : string ) {
3131const seen :string [ ] = [ ] ;
3232const mangaTiles :MangaTile [ ] = [ ] ;
33- $ ( "ul.slider" ) . map ( ( index , element ) => {
33+ $ ( "ul.slider li.slide " ) . map ( ( index , element ) => {
3434const link = $ ( "a" , element ) ;
3535const linkId = link . attr ( "href" )
3636if ( linkId ) {
@@ -42,7 +42,7 @@ export class CatMangaParser {
4242title :createIconText ( {
4343text :$ ( "h1" , element ) . first ( ) . text ( ) . trim ( )
4444} ) ,
45- image :$ ( "img" , element ) . attr ( "src" ) || "" ,
45+ image :base + $ ( "img" , element ) . attr ( "src" ) || "" ,
4646primaryText :createIconText ( {
4747text :$ ( "div p" , $ ( "a" , element ) . parent ( ) ) . first ( ) . text ( ) . trim ( )
4848} )
@@ -61,13 +61,18 @@ export class CatMangaParser {
6161parseChapterList ( $ :CheerioStatic , mangaId :string ) {
6262const chapters :Chapter [ ] = [ ] ;
6363$ ( 'a[class^="chaptertile_element"]' ) . map ( ( index , element ) => {
64- const chapNum = Number ( $ ( "p" , element ) . first ( ) . text ( ) . replace ( "Chapter " , "" ) ) ;
64+ const chapNumString = $ ( "p" , element ) . first ( ) . text ( ) . replace ( "Chapter " , "" )
65+ const chapNum = Number ( chapNumString ) || 0 ;
66+ let title :string | null = null ;
67+ if ( chapNum === 0 ) {
68+ title = chapNumString
69+ }
6570const data :Chapter = {
6671chapNum :chapNum ,
6772id :String ( chapNum ) ,
6873langCode :LanguageCode . ENGLISH ,
6974mangaId :mangaId ,
70- name :$ ( "p" , element ) . last ( ) . text ( ) . trim ( )
75+ name :title || $ ( "p" , element ) . last ( ) . text ( ) . trim ( )
7176} ;
7277chapters . push ( createChapter ( data ) ) ;
7378} )