fix(route/ps): monthly-games (#17211)

* fix(route/ps): monthly-games list target element updated to #monthly-games

* fix(route/ps): link tag

---------

Co-authored-by: wanghao9 <wanghao9@sugon.com>
This commit is contained in:
Leo
2024-10-20 21:07:33 -07:00
committed by GitHub
co-authored by wanghao9
parent 8d76a0055d
commit 71e1fce88a
+4 -4
View File
@@ -38,17 +38,17 @@ async function handler() {
const { data: response } = await got(baseUrl);
const $ = load(response);
const list = $('.cmp-experiencefragment--your-latest-monthly-games .box')
const list = $('#monthly-games .box--light ')
.toArray()
.map((item) => {
item = $(item);
.map((e) => {
const item = $(e);
return {
title: item.find('h3').text(),
description: art(path.join(__dirname, 'templates/monthly-games.art'), {
img: item.find('.media-block__img source').attr('srcset'),
text: item.find('h3 + p').text(),
}),
link: item.find('.button a').attr('href'),
link: item.find('.btn--cta').attr('href'),
};
});