feat(aklive2d): updated the struct of offical_update.json
This commit is contained in:
@@ -10,7 +10,9 @@ export default async function () {
|
|||||||
const dom = new jsdom.JSDOM(html_text);
|
const dom = new jsdom.JSDOM(html_text);
|
||||||
const rows = dom.window.document.body.querySelector(".dynList").querySelectorAll(".row")
|
const rows = dom.window.document.body.querySelector(".dynList").querySelectorAll(".row")
|
||||||
|
|
||||||
const dict = {}
|
const dict = {
|
||||||
|
length: 0
|
||||||
|
}
|
||||||
|
|
||||||
for (const row of rows) {
|
for (const row of rows) {
|
||||||
const date = row.querySelector(".date").textContent.trim()
|
const date = row.querySelector(".date").textContent.trim()
|
||||||
@@ -18,6 +20,10 @@ export default async function () {
|
|||||||
|
|
||||||
const charCards = row.querySelectorAll(".charCard")
|
const charCards = row.querySelectorAll(".charCard")
|
||||||
|
|
||||||
|
if (dict.length === 0) {
|
||||||
|
dict.latest = date
|
||||||
|
}
|
||||||
|
|
||||||
for (const charCard of charCards) {
|
for (const charCard of charCards) {
|
||||||
const color = charCard.style.color
|
const color = charCard.style.color
|
||||||
const codename = {
|
const codename = {
|
||||||
@@ -40,6 +46,7 @@ export default async function () {
|
|||||||
codename,
|
codename,
|
||||||
type
|
type
|
||||||
})
|
})
|
||||||
|
dict.length++
|
||||||
}
|
}
|
||||||
dict[date] = operators
|
dict[date] = operators
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
{
|
{
|
||||||
|
"length": 33,
|
||||||
|
"latest": "2023/08",
|
||||||
"2023/08": [
|
"2023/08": [
|
||||||
{
|
{
|
||||||
"color": "rgb(183, 227, 243)",
|
"color": "rgb(183, 227, 243)",
|
||||||
|
|||||||
Reference in New Issue
Block a user