yande.re hotlink protection workaround
parent
17c84b16db
commit
593c4cef0d
15
README.md
15
README.md
|
|
@ -22,4 +22,17 @@ Scrape a booru-like post object from the DOM.
|
|||
| shuushuu | e-shuushuu.net | content, rating, resolution, tags, tag_category | Rating is assumed to be safe. |
|
||||
| twitter | twitter.com, mobile.twitter.com | content | |
|
||||
| zerochan | www.zerochan.net | content, resolution, tags, tag_category | Rating is assumed to be safe. |
|
||||
| fallback | | content | Tries to find the largest image or video on the current page. |
|
||||
| fallback | | content | Tries to find the largest image or video on the current page. |
|
||||
|
||||
## Development
|
||||
|
||||
Build SzuruChrome with your local version of neo-scraper.
|
||||
|
||||
```sh
|
||||
cd neo-scraper
|
||||
pnpm install
|
||||
pnpm build # or pnpm watch in another terminal
|
||||
pnpm link --global
|
||||
cd ../SzuruChrome
|
||||
pnpm dev
|
||||
```
|
||||
|
|
|
|||
|
|
@ -1,6 +1,6 @@
|
|||
{
|
||||
"name": "neo-scraper",
|
||||
"version": "0.9.0",
|
||||
"version": "0.9.1",
|
||||
"description": "Scrape a booru-like post object from the DOM.",
|
||||
"type": "module",
|
||||
"main": "dist/index.js",
|
||||
|
|
|
|||
|
|
@ -13,6 +13,10 @@ export default class Moebooru extends ScrapeEngineBase {
|
|||
const post = new ScrapedPost();
|
||||
post.pageUrl = document.location.href;
|
||||
|
||||
if (document.location.host == "yande.re") {
|
||||
post.uploadMode = "content";
|
||||
}
|
||||
|
||||
// Set image url
|
||||
const originalImageElement = document.querySelector("#highres") as HTMLAnchorElement;
|
||||
if (originalImageElement) {
|
||||
|
|
|
|||
Loading…
Reference in New Issue