Skip to content

Commit

Permalink
fix clipboard on futaba
Browse files Browse the repository at this point in the history
  • Loading branch information
MikeZeDev committed Nov 22, 2024
1 parent 4aef846 commit 226ad8e
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 27 deletions.
6 changes: 3 additions & 3 deletions web/src/engine/websites/Futabanet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import * as SpeedBinb from './decorators/SpeedBinb';
import { FetchCSS } from '../platform/FetchProvider';
import type { Priority } from '../taskpool/DeferredTask';

@Common.MangaCSS(/^https:\/\/gaugau\.futabane(t|x)\.jp\/list\/work\/[^/]+$/, 'div.works__grid div.list__text div.mbOff h1')
@Common.MangaCSS(/^https:\/\/gaugau\.futabane(t|x)\.jp\/list\/work\/[^/]+$/, 'ol.breadcrumb li:last-of-type')
@Common.MangasMultiPageCSS('/list/works?page={page}', 'div.works__grid div.list__box h4 a')

export default class extends DecoratableMangaScraper {
Expand All @@ -29,13 +29,13 @@ export default class extends DecoratableMangaScraper {
});
}

public override async FetchPages(chapter: Chapter): Promise<Page[]> {
public override async FetchPages(chapter: Chapter): Promise<Page[]> { //Not sure if needed anymore
let pages: Page[] = await Common.FetchPagesSinglePageCSS.call(this, chapter, 'div.works_tateyomi__img img');
pages = pages?.map(page => new Page(this, chapter, page.Link, { useCommon: true }));
return pages?.length > 0 ? pages : await SpeedBinb.FetchPagesSinglePageAjaxv016130.call(this, chapter);
}

public override async FetchImage(page: Page, priority: Priority, signal: AbortSignal): Promise<Blob> {
public override async FetchImage(page: Page, priority: Priority, signal: AbortSignal): Promise<Blob> { //Not sure if needed anymore
return page.Parameters?.useCommon ? Common.FetchImageAjax.call(this, page, priority, signal) : SpeedBinb.FetchImageAjax.call(this, page, priority, signal);
}
}
25 changes: 1 addition & 24 deletions web/src/engine/websites/Futabanet_e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,27 +22,4 @@ const config: Config = {
}
};

new TestFixture(config).AssertWebsite();

const NoSpeedBinbConfig: Config = {
plugin: {
id: 'futabanet',
title: 'がうがうモンスター (Futabanet Monster)'
},
container: {
url: 'https://gaugau.futabanet.jp/list/work/oCMElLZtSKn7e5PVKDuV2josm',
id: '/list/work/oCMElLZtSKn7e5PVKDuV2josm',
title: 'ルーン魔術だけが取り柄の不憫令嬢、天才王子に溺愛される ~婚約者、仕事、成果もすべて姉に横取りされた地味な妹ですが、ある日突然立場が逆転しちゃいました~'
},
child: {
id: '/list/work/oCMElLZtSKn7e5PVKDuV2josm/episodes/7',
title: '第3話(3)',
},
entry: {
index: 0,
size: 204_914,
type: 'image/jpeg'
}
};

new TestFixture(NoSpeedBinbConfig).AssertWebsite();
new TestFixture(config).AssertWebsite();

0 comments on commit 226ad8e

Please sign in to comment.