ComicScrapy/Comics/spiders/rm_comic.yml
2024-10-28 00:03:20 +08:00

48 lines
1.5 KiB
YAML

books:
names: '//div[@class="truncate"]/text()'
urls: '//div[@class="grid grid-cols-1 sm:grid-cols-4 md:grid-cols-6 gap-2 sm:gap-4"]//a/@href'
data:
name: '//div[@class="basis-3/5 text-sm sm:text-base"]//div[@class="text-xl text-gray-900"]/text()'
icon: '//div[@class="flex flex-row gap-3 sm:gap-4"]//div[@class="basis-2/5"]/img[@class="rounded"]/@src'
author:
xpath: '//div[@class="flex flex-row gap-3 sm:gap-4"]//span[@class="text-gray-800"]/text()'
index: 0
tags:
xpath: '//div[@class="flex flex-row gap-3 sm:gap-4"]//span[@class="text-gray-800"]/text()'
index: 3
dep:
xpath: '//div[@class="my-2 text-gray-800 text-sm sm:text-base"]/p/text()'
index: 1
date:
xpath: '//div[@class="text-gray-500 text-sm mt-2"]/div/text()'
index: 1
genre:
value: "韩漫"
age_rating:
value: "R18+"
chapter_href: '//div[@class="grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 gap-2 px-2 py-4"]//a/@href'
chapters: '//div[@class="grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 gap-2 px-2 py-4"]//div[@class="text truncate bg-slate-300 p-2 hover:bg-rose-100"]/text()'
parse_chapter:
name:
sexec: props.pageProps.bookName
dep:
sexec: props.pageProps.description
chapter:
sexec: props.pageProps.chapterName
image_urls:
sexec: props.pageProps.images
images:
sexec: props.pageProps.images
chapter_api:
sexec: props.pageProps.chapterAPIPath
parse_chapter_api:
chapter:
sexec: chapter.name
image_urls:
sexec: chapter.images
images:
sexec: chapter.images