@talisdev/bibliographic-resource-parsers-lib 5.45.0 → 5.46.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -3334,13 +3334,16 @@ var ts = (e) => {
|
|
|
3334
3334
|
spage: a,
|
|
3335
3335
|
epage: o
|
|
3336
3336
|
}));
|
|
3337
|
-
}, Ls = /^[0-9X]$/, Rs = (e) => {
|
|
3337
|
+
}, Ls = /^[0-9X]$/, Rs = ",", zs = (e) => {
|
|
3338
3338
|
if (!e) return;
|
|
3339
3339
|
let t = "";
|
|
3340
3340
|
for (let n of e) Ls.test(n) && (t += n);
|
|
3341
3341
|
if (t) return t;
|
|
3342
|
-
},
|
|
3343
|
-
let
|
|
3342
|
+
}, Bs = (e) => {
|
|
3343
|
+
let t = new Set(e.flatMap((e) => e?.split(Rs) ?? []).map((e) => zs(e)).filter((e) => !!e));
|
|
3344
|
+
return t.size > 0 ? [...t].join(Rs) : void 0;
|
|
3345
|
+
}, Vs = (e, t) => {
|
|
3346
|
+
let n = e.querySelector(".c-cksc-content-header__title")?.textContent.trim(), r = e.querySelector(".c-cksc-content-nice__button")?.textContent.trim(), i = e.querySelector(".c-cksc-content-nice__date")?.textContent.trim(), a = zs(e.evaluate("//p[contains(text(), \"ISBN\")]", e, null, XPathResult.ANY_TYPE).iterateNext()?.textContent);
|
|
3344
3347
|
return B({
|
|
3345
3348
|
genre: F.Document,
|
|
3346
3349
|
title: n,
|
|
@@ -3349,8 +3352,8 @@ var ts = (e) => {
|
|
|
3349
3352
|
uri: t,
|
|
3350
3353
|
isbn: a
|
|
3351
3354
|
});
|
|
3352
|
-
},
|
|
3353
|
-
let t =
|
|
3355
|
+
}, Hs = (e) => e.querySelector(".browse-toc") ?? e.querySelector(".browse__journal"), Us = (e) => (Hs(e)?.querySelector("h1")?.firstElementChild)?.textContent.trim(), Ws = (e) => {
|
|
3356
|
+
let t = Hs(e), n = t?.querySelector("figure figcaption.source");
|
|
3354
3357
|
if (n) {
|
|
3355
3358
|
let [e, t, r] = n.textContent.split(",").map((e) => e.trim());
|
|
3356
3359
|
return {
|
|
@@ -3365,41 +3368,41 @@ var ts = (e) => {
|
|
|
3365
3368
|
volume: Os(r),
|
|
3366
3369
|
issue: Os(i)
|
|
3367
3370
|
};
|
|
3368
|
-
},
|
|
3369
|
-
let { date: t, volume: n, issue: r } =
|
|
3371
|
+
}, Gs = (e) => {
|
|
3372
|
+
let { date: t, volume: n, issue: r } = Ws(e);
|
|
3370
3373
|
return B(L(F.Journal, {
|
|
3371
|
-
jtitle:
|
|
3374
|
+
jtitle: Us(e),
|
|
3372
3375
|
date: t,
|
|
3373
3376
|
volume: n,
|
|
3374
3377
|
issue: r
|
|
3375
3378
|
}));
|
|
3376
|
-
},
|
|
3379
|
+
}, Ks = /* @__PURE__ */ function(e) {
|
|
3377
3380
|
return e.Book = "Book", e.Chapter = "Book Chapter", e.Article = "Full Text Article", e.Journal = "Journal", e.Guideline = "Guideline", e;
|
|
3378
|
-
}(
|
|
3381
|
+
}(Ks || {}), qs = (e) => Object.values(Ks).includes(e), Js = (e, t) => {
|
|
3379
3382
|
let n = e.querySelector(".content-type") ?? e.querySelector(".c-cksc-content-header__content-type");
|
|
3380
|
-
if (!n) return t.includes("journal") ?
|
|
3383
|
+
if (!n) return t.includes("journal") ? Ks.Journal : void 0;
|
|
3381
3384
|
let r = n.textContent;
|
|
3382
|
-
if (r &&
|
|
3383
|
-
},
|
|
3384
|
-
switch (
|
|
3385
|
-
case
|
|
3386
|
-
case
|
|
3387
|
-
case
|
|
3388
|
-
case
|
|
3389
|
-
case
|
|
3385
|
+
if (r && qs(r)) return r;
|
|
3386
|
+
}, Ys = ({ url: e, document: t }) => {
|
|
3387
|
+
switch (Js(t, e)) {
|
|
3388
|
+
case Ks.Book: return Ps(t);
|
|
3389
|
+
case Ks.Chapter: return Is(t);
|
|
3390
|
+
case Ks.Article: return Ns(t);
|
|
3391
|
+
case Ks.Journal: return Gs(t);
|
|
3392
|
+
case Ks.Guideline: return Vs(t, e);
|
|
3390
3393
|
case void 0: return z();
|
|
3391
3394
|
}
|
|
3392
|
-
}, W = j({ "@context": O() }),
|
|
3395
|
+
}, W = j({ "@context": O() }), Xs = (e) => W.safeParse(e).success, Zs = "script[type=\"application/ld+json\"]", Qs = (e) => Array.from(e.querySelectorAll(Zs)), $s = (e) => e.querySelector(Zs), ec = (e) => {
|
|
3393
3396
|
let t = e.textContent;
|
|
3394
3397
|
if (!t) return null;
|
|
3395
3398
|
try {
|
|
3396
3399
|
let e = JSON.parse(t);
|
|
3397
|
-
if (
|
|
3400
|
+
if (Xs(e)) return e;
|
|
3398
3401
|
} catch {
|
|
3399
3402
|
return null;
|
|
3400
3403
|
}
|
|
3401
3404
|
return null;
|
|
3402
|
-
},
|
|
3405
|
+
}, tc = j({
|
|
3403
3406
|
"@id": O(),
|
|
3404
3407
|
"@type": O(),
|
|
3405
3408
|
author: j({ "@id": O() }).optional(),
|
|
@@ -3410,33 +3413,33 @@ var ts = (e) => {
|
|
|
3410
3413
|
isPartOf: j({ "@id": O() }).optional(),
|
|
3411
3414
|
name: O().optional(),
|
|
3412
3415
|
url: O().optional()
|
|
3413
|
-
}),
|
|
3414
|
-
let t =
|
|
3416
|
+
}), nc = W.extend({ "@graph": A(tc) }), rc = (e) => nc.safeParse(e).success, ic = (e) => {
|
|
3417
|
+
let t = Qs(e);
|
|
3415
3418
|
if (t.length === 0) return null;
|
|
3416
|
-
let n = t.map(
|
|
3419
|
+
let n = t.map(ec).filter(rc).map((e) => e["@graph"]);
|
|
3417
3420
|
return n.length === 1 ? n[0] : null;
|
|
3418
|
-
},
|
|
3419
|
-
let t =
|
|
3421
|
+
}, ac = (e, t) => e.find((e) => e["@type"] === t) ?? null, oc = (e, t) => e.find((e) => e["@id"] === t) ?? null, sc = (e) => {
|
|
3422
|
+
let t = ac(e, "WebPage");
|
|
3420
3423
|
if (!t) return null;
|
|
3421
|
-
let n = t.author ?
|
|
3424
|
+
let n = t.author ? oc(e, t.author["@id"]) : void 0;
|
|
3422
3425
|
return _o({
|
|
3423
3426
|
au: n?.name ? [n.name] : void 0,
|
|
3424
3427
|
date: t.datePublished,
|
|
3425
3428
|
title: t.name
|
|
3426
3429
|
});
|
|
3427
|
-
},
|
|
3428
|
-
let t =
|
|
3430
|
+
}, cc = ({ document: e }) => {
|
|
3431
|
+
let t = ic(e);
|
|
3429
3432
|
return t ? {
|
|
3430
3433
|
bookmarkingWorkflowUrl: null,
|
|
3431
|
-
resource:
|
|
3434
|
+
resource: sc(t)
|
|
3432
3435
|
} : z();
|
|
3433
|
-
},
|
|
3436
|
+
}, lc = () => z(), uc = /* @__PURE__ */ function(e) {
|
|
3434
3437
|
return e.Journal = "journal", e.Article = "article", e;
|
|
3435
|
-
}(
|
|
3438
|
+
}(uc || {}), dc = (e) => {
|
|
3436
3439
|
let { pathname: t } = new URL(e);
|
|
3437
|
-
if (t.startsWith("/toc/")) return
|
|
3438
|
-
if (t.startsWith("/article/")) return
|
|
3439
|
-
},
|
|
3440
|
+
if (t.startsWith("/toc/")) return uc.Journal;
|
|
3441
|
+
if (t.startsWith("/article/")) return uc.Article;
|
|
3442
|
+
}, fc = (e) => {
|
|
3440
3443
|
let t = e.querySelector("header h1 span")?.firstChild?.textContent?.trim(), n = (e.querySelector("header p span")?.textContent.trim())?.match(/\d{4}-\d{3}[\dX]/g) ?? [], [r, i] = [n[0], n[1]], a = e.evaluate("//dt[contains(text(), \"Publisher\")]/following-sibling::dd/a", e, null, XPathResult.STRING_TYPE).stringValue.trim();
|
|
3441
3444
|
return B(L(F.Journal, {
|
|
3442
3445
|
pub: a,
|
|
@@ -3444,14 +3447,14 @@ var ts = (e) => {
|
|
|
3444
3447
|
issn: r,
|
|
3445
3448
|
eissn: i
|
|
3446
3449
|
}));
|
|
3447
|
-
},
|
|
3450
|
+
}, pc = (e) => {
|
|
3448
3451
|
let t, n, r = H(e, "name", "citation_issn");
|
|
3449
3452
|
return r.length === 2 ? (t = r[1], n = r[0]) : t = r[0], {
|
|
3450
3453
|
eissn: t,
|
|
3451
3454
|
issn: n
|
|
3452
3455
|
};
|
|
3453
|
-
},
|
|
3454
|
-
let t = V(e, "name", "citation_journal_title"), n = V(e, "name", "citation_title"), r = H(e, "name", "citation_author"), i = V(e, "name", "citation_doi"), { eissn: a, issn: o } =
|
|
3456
|
+
}, mc = (e) => {
|
|
3457
|
+
let t = V(e, "name", "citation_journal_title"), n = V(e, "name", "citation_title"), r = H(e, "name", "citation_author"), i = V(e, "name", "citation_doi"), { eissn: a, issn: o } = pc(e), s = V(e, "name", "citation_publisher"), c = V(e, "name", "citation_publication_date"), l = V(e, "name", "citation_volume"), u = V(e, "name", "citation_issue"), d = V(e, "name", "citation_firstpage"), f = V(e, "name", "citation_lastpage");
|
|
3455
3458
|
return B(L(F.Article, {
|
|
3456
3459
|
jtitle: t,
|
|
3457
3460
|
atitle: n,
|
|
@@ -3466,13 +3469,13 @@ var ts = (e) => {
|
|
|
3466
3469
|
spage: d,
|
|
3467
3470
|
epage: f
|
|
3468
3471
|
}));
|
|
3469
|
-
},
|
|
3470
|
-
switch (
|
|
3471
|
-
case
|
|
3472
|
-
case
|
|
3472
|
+
}, hc = ({ document: e, url: t }) => {
|
|
3473
|
+
switch (dc(t)) {
|
|
3474
|
+
case uc.Journal: return fc(e);
|
|
3475
|
+
case uc.Article: return mc(e);
|
|
3473
3476
|
case void 0: return z();
|
|
3474
3477
|
}
|
|
3475
|
-
},
|
|
3478
|
+
}, gc = (e) => {
|
|
3476
3479
|
let t = V(e, "name", "pbContext");
|
|
3477
3480
|
if (!t) return U.None;
|
|
3478
3481
|
let n = ds(t);
|
|
@@ -3481,23 +3484,23 @@ var ts = (e) => {
|
|
|
3481
3484
|
case "Table of Contents": return U.Journal;
|
|
3482
3485
|
default: return U.None;
|
|
3483
3486
|
}
|
|
3484
|
-
},
|
|
3487
|
+
}, _c = (e) => {
|
|
3485
3488
|
let t = e.querySelector("meta[property=\"article:author\"]")?.getAttribute("content")?.split(",").map((e) => e.trim());
|
|
3486
3489
|
return t && t.length > 0 ? t : void 0;
|
|
3487
|
-
},
|
|
3490
|
+
}, vc = (e) => {
|
|
3488
3491
|
let t = /* @__PURE__ */ new Map(), n = Array.from(e.querySelectorAll(".rlist>li>span")).map((e) => e.textContent.trim()).join(""), r = /^ISSN:\s(\d{4}-\d{3}(?:\d|X))/.exec(n);
|
|
3489
3492
|
r && t.set("issn", r[1]);
|
|
3490
3493
|
let i = /Online ISSN:\s(\d{4}-\d{3}(?:\d|X))/.exec(n);
|
|
3491
3494
|
return i && t.set("eissn", i[1]), t;
|
|
3492
|
-
},
|
|
3495
|
+
}, yc = (e) => e.querySelector("span[property=\"isPartOf\"][typeof=\"PublicationVolume\"] > span[property=\"volumeNumber\"]")?.textContent ?? void 0, bc = (e) => e.querySelector("span[property=\"isPartOf\"][typeof=\"PublicationIssue\"] > span[property=\"issueNumber\"]")?.textContent ?? void 0, xc = (e) => e.querySelector("meta[name=\"dc.Identifier\"][scheme=\"doi\"]")?.getAttribute("content") ?? void 0, Sc = (e) => e.querySelector("h1")?.textContent ?? void 0, Cc = (e) => {
|
|
3493
3496
|
let t = /* @__PURE__ */ new Map(), n = e.querySelector("h2.heading-m")?.textContent, r = n?.match(/Issue\s+(\d+(?:-\d+)?)/);
|
|
3494
3497
|
r && t.set("issue", r[1]);
|
|
3495
3498
|
let i = n?.match(/Volume\s+(\d+)/);
|
|
3496
3499
|
i && t.set("volume", i[1]);
|
|
3497
3500
|
let a = n?.match(/(\d{4})$/);
|
|
3498
3501
|
return a && t.set("date", a[1]), t;
|
|
3499
|
-
},
|
|
3500
|
-
let t =
|
|
3502
|
+
}, wc = (e) => {
|
|
3503
|
+
let t = _c(e.document), n = V(e.document, "name", "dc.Date"), r = xc(e.document), i = vc(e.document), a = i.get("issn"), o = i.get("eissn"), s = bc(e.document), c = V(e.document, "name", "citation_journal_title"), l = V(e.document, "name", "dc.Publisher"), u = V(e.document, "name", "dc.Title"), d = yc(e.document);
|
|
3501
3504
|
return L(F.Article, {
|
|
3502
3505
|
au: t,
|
|
3503
3506
|
date: n,
|
|
@@ -3510,8 +3513,8 @@ var ts = (e) => {
|
|
|
3510
3513
|
volume: d,
|
|
3511
3514
|
doi: r
|
|
3512
3515
|
});
|
|
3513
|
-
},
|
|
3514
|
-
let t =
|
|
3516
|
+
}, Tc = (e) => {
|
|
3517
|
+
let t = vc(e.document), n = t.get("issn"), r = t.get("eissn"), i = Sc(e.document), a = Cc(e.document), o = a.get("issue"), s = a.get("volume"), c = a.get("date");
|
|
3515
3518
|
return L(F.Journal, {
|
|
3516
3519
|
eissn: r,
|
|
3517
3520
|
issn: n,
|
|
@@ -3521,33 +3524,33 @@ var ts = (e) => {
|
|
|
3521
3524
|
volume: s,
|
|
3522
3525
|
date: c
|
|
3523
3526
|
});
|
|
3524
|
-
},
|
|
3525
|
-
switch (
|
|
3526
|
-
case U.Article: return B(
|
|
3527
|
-
case U.Journal: return B(
|
|
3527
|
+
}, Ec = (e) => {
|
|
3528
|
+
switch (gc(e.document)) {
|
|
3529
|
+
case U.Article: return B(wc(e));
|
|
3530
|
+
case U.Journal: return B(Tc(e));
|
|
3528
3531
|
default: return z();
|
|
3529
3532
|
}
|
|
3530
|
-
},
|
|
3533
|
+
}, Dc = (e) => {
|
|
3531
3534
|
let t = V(e, "name", "citation_type"), n = V(e, "name", "citation_article_type");
|
|
3532
3535
|
return t === "JOUR" && n ? U.Article : t === "CHP" ? U.Chapter : e.querySelector(".book-edition-year")?.textContent.includes("Book") ? U.Book : e.getElementById("journal-title") ? U.Journal : U.None;
|
|
3533
|
-
},
|
|
3536
|
+
}, Oc = (e) => V(e, "name", "citation_doi") ?? V(e, "name", "dc.identifier") ?? e.querySelector(".doi .anchor-text")?.textContent ?? void 0, kc = (e) => {
|
|
3534
3537
|
let t = Array.from(e.querySelectorAll(".kf-details .kf-detail-item:has(h3)")), n = /* @__PURE__ */ new Map();
|
|
3535
3538
|
for (let e of t) {
|
|
3536
3539
|
let t = e.querySelector("h3")?.textContent, r = e.querySelector("p")?.textContent;
|
|
3537
3540
|
t && r && n.set(t, r);
|
|
3538
3541
|
}
|
|
3539
3542
|
return n;
|
|
3540
|
-
},
|
|
3543
|
+
}, Ac = (e, t) => {
|
|
3541
3544
|
let n = Array.from(e.querySelectorAll(t)).map((e) => e.textContent).filter((e) => !!e);
|
|
3542
3545
|
return n.length > 0 ? n : void 0;
|
|
3543
|
-
},
|
|
3546
|
+
}, jc = (e) => {
|
|
3544
3547
|
let t = e.querySelector(".js-issn")?.textContent;
|
|
3545
3548
|
if (t) return t.replace("Online ISSN: ", "");
|
|
3546
|
-
},
|
|
3549
|
+
}, Mc = (e) => {
|
|
3547
3550
|
let t = e.get("DOI");
|
|
3548
3551
|
if (t) return URL.canParse(t) ? new URL(t).pathname.substring(1) : t;
|
|
3549
|
-
},
|
|
3550
|
-
let t =
|
|
3552
|
+
}, Nc = (e) => {
|
|
3553
|
+
let t = kc(e), n = V(e, "property", "og:title"), r = V(e, "property", "og:book:isbn"), i = t.get("Published"), a = Ac(e, ".authors-container .author-detail h3"), o = Oc(e) ?? Mc(t);
|
|
3551
3554
|
return I(F.Book, {
|
|
3552
3555
|
au: a,
|
|
3553
3556
|
date: i,
|
|
@@ -3555,8 +3558,8 @@ var ts = (e) => {
|
|
|
3555
3558
|
isbn: r,
|
|
3556
3559
|
title: n
|
|
3557
3560
|
});
|
|
3558
|
-
},
|
|
3559
|
-
let t = V(e, "property", "og:title"), n = V(e, "property", "og:book:isbn"), r = V(e, "name", "citation_publication_date"), i =
|
|
3561
|
+
}, Pc = (e) => {
|
|
3562
|
+
let t = V(e, "property", "og:title"), n = V(e, "property", "og:book:isbn"), r = V(e, "name", "citation_publication_date"), i = Ac(e, ".author-group .button-link-text"), a = V(e, "name", "citation_firstpage"), o = V(e, "name", "citation_lastpage"), s = V(e, "name", "citation_publisher"), c = Oc(e), l = V(e, "name", "citation_inbook_title") ?? e.querySelector(".publication-title")?.textContent ?? void 0;
|
|
3560
3563
|
return I(F.Bookitem, {
|
|
3561
3564
|
au: i,
|
|
3562
3565
|
btitle: l,
|
|
@@ -3568,8 +3571,8 @@ var ts = (e) => {
|
|
|
3568
3571
|
spage: a,
|
|
3569
3572
|
title: t
|
|
3570
3573
|
});
|
|
3571
|
-
},
|
|
3572
|
-
let t = V(e, "property", "og:title"), n = V(e, "name", "citation_issn"), r = V(e, "name", "citation_publication_date"), i =
|
|
3574
|
+
}, Fc = (e) => {
|
|
3575
|
+
let t = V(e, "property", "og:title"), n = V(e, "name", "citation_issn"), r = V(e, "name", "citation_publication_date"), i = Ac(e, ".author-group .button-link-text"), a = V(e, "name", "citation_publisher"), o = V(e, "name", "citation_firstpage"), s = V(e, "name", "citation_issue"), c = V(e, "name", "citation_volume"), l = Oc(e), u = V(e, "name", "citation_journal_title") ?? e.querySelector(".publication-title")?.textContent ?? void 0;
|
|
3573
3576
|
return L(F.Article, {
|
|
3574
3577
|
au: i,
|
|
3575
3578
|
jtitle: u,
|
|
@@ -3582,36 +3585,36 @@ var ts = (e) => {
|
|
|
3582
3585
|
title: t,
|
|
3583
3586
|
volume: c
|
|
3584
3587
|
});
|
|
3585
|
-
},
|
|
3586
|
-
let t = e.getElementById("journal-title")?.textContent ?? void 0, n =
|
|
3588
|
+
}, Ic = (e) => {
|
|
3589
|
+
let t = e.getElementById("journal-title")?.textContent ?? void 0, n = jc(e);
|
|
3587
3590
|
return L(F.Journal, {
|
|
3588
3591
|
issn: n,
|
|
3589
3592
|
title: t
|
|
3590
3593
|
});
|
|
3591
|
-
},
|
|
3592
|
-
switch (
|
|
3593
|
-
case U.Book: return B(
|
|
3594
|
-
case U.Chapter: return B(
|
|
3595
|
-
case U.Article: return B(
|
|
3596
|
-
case U.Journal: return B(
|
|
3594
|
+
}, Lc = ({ document: e }) => {
|
|
3595
|
+
switch (Dc(e)) {
|
|
3596
|
+
case U.Book: return B(Nc(e));
|
|
3597
|
+
case U.Chapter: return B(Pc(e));
|
|
3598
|
+
case U.Article: return B(Fc(e));
|
|
3599
|
+
case U.Journal: return B(Ic(e));
|
|
3597
3600
|
default: return z();
|
|
3598
3601
|
}
|
|
3599
|
-
},
|
|
3602
|
+
}, Rc = (e) => {
|
|
3600
3603
|
let t = V(e, "name", "pbContext");
|
|
3601
3604
|
return t && ds(t).has("article") ? U.Article : U.Journal;
|
|
3602
|
-
},
|
|
3605
|
+
}, zc = (e) => {
|
|
3603
3606
|
let t = e.querySelector(".itemPageRangeHistory");
|
|
3604
3607
|
if (!t) return;
|
|
3605
3608
|
let n = Array.from(t.childNodes).find((e) => e.textContent?.trim().startsWith("Page"));
|
|
3606
3609
|
if (n) return n.textContent?.replace(/Pages?/, "").trim() ?? void 0;
|
|
3607
|
-
},
|
|
3610
|
+
}, Bc = (e) => {
|
|
3608
3611
|
let t = e.querySelector(".issue-heading")?.textContent;
|
|
3609
3612
|
if (t) return t.split(",")[0]?.replace("Volume", "").trim();
|
|
3610
|
-
},
|
|
3613
|
+
}, Vc = (e) => {
|
|
3611
3614
|
let t = e.querySelector(".issue-heading .nav-toc-list")?.textContent;
|
|
3612
3615
|
if (t) return t.replace("Issue", "").trim();
|
|
3613
|
-
},
|
|
3614
|
-
let t = V(e, "property", "og:title"), n = V(e, "name", "dc.Publisher"), r = V(e, "name", "dc.Date"), i = V(e, "name", "publication_doi"), a = V(e, "name", "citation_journal_title"), o = H(e, "name", "dc.Creator"), s =
|
|
3616
|
+
}, Hc = (e) => {
|
|
3617
|
+
let t = V(e, "property", "og:title"), n = V(e, "name", "dc.Publisher"), r = V(e, "name", "dc.Date"), i = V(e, "name", "publication_doi"), a = V(e, "name", "citation_journal_title"), o = H(e, "name", "dc.Creator"), s = Bc(e), c = Vc(e), l = zc(e), u = l?.includes("-") ? l.split("-")[0] : l, d = l?.includes("-") ? l.split("-")[1] : l;
|
|
3615
3618
|
return L(F.Article, {
|
|
3616
3619
|
au: o,
|
|
3617
3620
|
jtitle: a,
|
|
@@ -3624,45 +3627,45 @@ var ts = (e) => {
|
|
|
3624
3627
|
title: t,
|
|
3625
3628
|
volume: s
|
|
3626
3629
|
});
|
|
3627
|
-
},
|
|
3630
|
+
}, Uc = (e) => {
|
|
3628
3631
|
let t = V(e, "property", "og:title"), n = V(e, "name", "publication_doi");
|
|
3629
3632
|
return L(F.Journal, {
|
|
3630
3633
|
doi: n,
|
|
3631
3634
|
title: t
|
|
3632
3635
|
});
|
|
3633
|
-
},
|
|
3634
|
-
switch (
|
|
3635
|
-
case U.Article: return B(
|
|
3636
|
-
case U.Journal: return B(
|
|
3636
|
+
}, Wc = ({ document: e }) => {
|
|
3637
|
+
switch (Rc(e)) {
|
|
3638
|
+
case U.Article: return B(Hc(e));
|
|
3639
|
+
case U.Journal: return B(Uc(e));
|
|
3637
3640
|
default: return z();
|
|
3638
3641
|
}
|
|
3639
|
-
},
|
|
3640
|
-
function
|
|
3642
|
+
}, Gc = (e) => Xo.safeParse(e).success, Kc = (e) => Zo.safeParse(e).success, qc = (e) => Wo.safeParse(e).success;
|
|
3643
|
+
function Jc(e) {
|
|
3641
3644
|
return Ko.safeParse(e).success;
|
|
3642
3645
|
}
|
|
3643
|
-
function
|
|
3646
|
+
function Yc(e) {
|
|
3644
3647
|
return qo.safeParse(e).success;
|
|
3645
3648
|
}
|
|
3646
|
-
function
|
|
3649
|
+
function Xc(e) {
|
|
3647
3650
|
return Jo.safeParse(e).success;
|
|
3648
3651
|
}
|
|
3649
|
-
function
|
|
3652
|
+
function Zc(e) {
|
|
3650
3653
|
return Yo.safeParse(e).success;
|
|
3651
3654
|
}
|
|
3652
|
-
function
|
|
3655
|
+
function Qc(e) {
|
|
3653
3656
|
return Go.safeParse(e).success;
|
|
3654
3657
|
}
|
|
3655
3658
|
//#endregion
|
|
3656
3659
|
//#region src/parsers/site/vu-find-parser.ts
|
|
3657
|
-
var
|
|
3660
|
+
var $c = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textContent.trim() === "DOI:")?.nextElementSibling?.querySelector("span[property=\"identifier\"]")?.textContent ?? void 0, el = (e) => {
|
|
3658
3661
|
let t = /Record\/(\d+)/.exec(e);
|
|
3659
3662
|
if (t && t.length > 1) return t[1];
|
|
3660
|
-
},
|
|
3663
|
+
}, tl = (e) => {
|
|
3661
3664
|
let { url: t, document: n } = e, r = ns(e);
|
|
3662
|
-
if (!
|
|
3663
|
-
let i =
|
|
3664
|
-
return i && (r.resource.rft_id = [`info:doi/${i}`]), r.resource.bibid =
|
|
3665
|
-
},
|
|
3665
|
+
if (!Yc(r)) return r;
|
|
3666
|
+
let i = $c(n);
|
|
3667
|
+
return i && (r.resource.rft_id = [`info:doi/${i}`]), r.resource.bibid = el(t), r;
|
|
3668
|
+
}, nl = W.extend({
|
|
3666
3669
|
"@type": N("VideoObject"),
|
|
3667
3670
|
name: O(),
|
|
3668
3671
|
author: O(),
|
|
@@ -3671,13 +3674,13 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3671
3674
|
uploadDate: O(),
|
|
3672
3675
|
duration: O(),
|
|
3673
3676
|
thumbnailUrl: A(O())
|
|
3674
|
-
}),
|
|
3675
|
-
let t =
|
|
3677
|
+
}), rl = (e) => nl.safeParse(e).success, il = (e) => {
|
|
3678
|
+
let t = Qs(e);
|
|
3676
3679
|
if (t.length === 0) return null;
|
|
3677
|
-
let n = t.map(
|
|
3680
|
+
let n = t.map(ec).filter(rl);
|
|
3678
3681
|
return n.length === 1 ? n[0] : null;
|
|
3679
|
-
},
|
|
3680
|
-
let n =
|
|
3682
|
+
}, al = ({ url: e, document: t }) => {
|
|
3683
|
+
let n = il(t);
|
|
3681
3684
|
return n ? {
|
|
3682
3685
|
bookmarkingWorkflowUrl: null,
|
|
3683
3686
|
resource: R({
|
|
@@ -3687,17 +3690,17 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3687
3690
|
uri: e
|
|
3688
3691
|
})
|
|
3689
3692
|
} : z();
|
|
3690
|
-
},
|
|
3693
|
+
}, ol = (e) => V(e, "name", "doi") ?? V(e, "name", "DOI") ?? V(e, "name", "citation_doi") ?? V(e, "name", "dc.identifier") ?? V(e, "name", "prism.doi") ?? void 0, sl = (e) => {
|
|
3691
3694
|
let t = e.editor?.map((e) => e.name) ?? [], n = [...e.author?.map((e) => e.name) ?? [], ...t];
|
|
3692
3695
|
if (n.length !== 0) return n;
|
|
3693
|
-
},
|
|
3696
|
+
}, cl = /* @__PURE__ */ function(e) {
|
|
3694
3697
|
return e.Book = "Book", e.Journal = "Journal", e.Periodical = "Periodical", e.PublicationVolume = "PublicationVolume", e.ScholarlyArticle = "ScholarlyArticle", e.VideoObject = "VideoObject", e.WebPage = "WebPage", e;
|
|
3695
|
-
}({}),
|
|
3698
|
+
}({}), ll = /* @__PURE__ */ function(e) {
|
|
3696
3699
|
return e.Article = "article", e.Book = "book", e.Paper = "Paper", e.Video = "video.other", e.Website = "website", e;
|
|
3697
|
-
}({}),
|
|
3700
|
+
}({}), ul = /* @__PURE__ */ function(e) {
|
|
3698
3701
|
return e.Article = "/article/", e.Book = "/book/", e.Chapter = "/chapter/", e.Video = "/video/", e.ReferenceWorkEntry = "/referenceworkentry/", e.ReferenceWork = "/referencework/", e.Protocol = "/protocol/", e.Collections = "/collections/", e.Journal = "/journal/", e.JournalIssue = "/volumes-and-issues/", e;
|
|
3699
|
-
}({}),
|
|
3700
|
-
"@type": N(
|
|
3702
|
+
}({}), dl = j({
|
|
3703
|
+
"@type": N(cl.ScholarlyArticle),
|
|
3701
3704
|
author: A(j({
|
|
3702
3705
|
"@type": O(),
|
|
3703
3706
|
name: O()
|
|
@@ -3722,16 +3725,16 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3722
3725
|
"@type": O(),
|
|
3723
3726
|
name: O()
|
|
3724
3727
|
}).optional()
|
|
3725
|
-
}),
|
|
3726
|
-
"@type": N(
|
|
3727
|
-
mainEntity:
|
|
3728
|
-
}),
|
|
3728
|
+
}), fl = (e) => dl.safeParse(e).success, pl = W.extend({
|
|
3729
|
+
"@type": N(cl.WebPage),
|
|
3730
|
+
mainEntity: dl
|
|
3731
|
+
}), ml = (e) => pl.safeParse(e).success, hl = j({
|
|
3729
3732
|
"@type": A(O()),
|
|
3730
3733
|
name: O().optional(),
|
|
3731
3734
|
issn: A(O()),
|
|
3732
3735
|
volumeNumber: O().optional()
|
|
3733
|
-
}),
|
|
3734
|
-
let n =
|
|
3736
|
+
}), gl = (e) => hl.safeParse(e).success, _l = (e, t) => V(e, "name", "citation_issn") ?? V(e, "name", "prism.issn") ?? (fl(t.isPartOf) ? t.isPartOf.issn?.[0] : void 0), vl = (e, t) => {
|
|
3737
|
+
let n = sl(t), r = V(e, "name", "citation_online_date"), i = ol(e), a = V(e, "name", "citation_issue"), o = _l(e, t), s = gl(t.isPartOf) && t.isPartOf.issn.length > 0 ? t.isPartOf.issn[1] : void 0, c = t.pageStart, l = t.pageEnd, u = t.headline, d = t.isPartOf.name, f = gl(t.isPartOf) ? t.isPartOf.volumeNumber : void 0;
|
|
3735
3738
|
return L(F.Article, {
|
|
3736
3739
|
au: n,
|
|
3737
3740
|
date: r,
|
|
@@ -3745,8 +3748,8 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3745
3748
|
jtitle: d,
|
|
3746
3749
|
volume: f
|
|
3747
3750
|
});
|
|
3748
|
-
},
|
|
3749
|
-
"@type": N(
|
|
3751
|
+
}, yl = W.extend({
|
|
3752
|
+
"@type": N(cl.Book),
|
|
3750
3753
|
copyrightYear: O().optional(),
|
|
3751
3754
|
author: A(j({
|
|
3752
3755
|
"@type": O(),
|
|
@@ -3763,16 +3766,16 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3763
3766
|
"@type": O(),
|
|
3764
3767
|
name: O()
|
|
3765
3768
|
}).optional()
|
|
3766
|
-
}),
|
|
3769
|
+
}), bl = (e) => yl.safeParse(e).success, xl = /* @__PURE__ */ function(e) {
|
|
3767
3770
|
return e.BOOK_TITLE = "Book Title", e.AUTHORS = "Authors", e.SERIES_TITLE = "Series Title", e.DOI = "DOI", e.PUBLISHER = "Publisher", e.SOFTCOVER_ISBN = "Softcover ISBN", e.EBOOK_ISBN = "eBook ISBN", e.SERIES_ISSN = "Series ISSN", e.SERIES_EISSN = "Series E-ISSN", e.EDITION_NUMBER = "Edition Number", e.NUMBER_OF_PAGES = "Number of Pages", e;
|
|
3768
|
-
}(
|
|
3771
|
+
}(xl || {}), Sl = (e) => {
|
|
3769
3772
|
let t = e.querySelectorAll(".c-bibliographic-information__list-item"), n = /* @__PURE__ */ new Map();
|
|
3770
3773
|
return t.forEach((e) => {
|
|
3771
3774
|
let t = e.querySelector(".u-text-bold")?.textContent.trim(), r = e.querySelector(".c-bibliographic-information__value")?.textContent.trim();
|
|
3772
3775
|
t && r && n.set(t, r);
|
|
3773
3776
|
}), n;
|
|
3774
|
-
},
|
|
3775
|
-
let n =
|
|
3777
|
+
}, Cl = (e, t) => {
|
|
3778
|
+
let n = Sl(e), r = sl(t), i = t.copyrightYear?.toString(), a = ol(e) ?? n.get(xl.DOI), o = t.name ?? n.get(xl.BOOK_TITLE), s = t.isbn ?? n.get(xl.SOFTCOVER_ISBN), c = t.numberOfPages?.toString() ?? n.get(xl.NUMBER_OF_PAGES), l = t.publisher?.name ?? n.get(xl.PUBLISHER);
|
|
3776
3779
|
return I(F.Book, {
|
|
3777
3780
|
au: r,
|
|
3778
3781
|
date: i,
|
|
@@ -3782,7 +3785,7 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3782
3785
|
tpages: c,
|
|
3783
3786
|
pub: l
|
|
3784
3787
|
});
|
|
3785
|
-
},
|
|
3788
|
+
}, wl = j({
|
|
3786
3789
|
"@type": N("Periodical"),
|
|
3787
3790
|
name: O(),
|
|
3788
3791
|
url: O(),
|
|
@@ -3793,7 +3796,7 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3793
3796
|
})),
|
|
3794
3797
|
publisher: j({ name: O() }),
|
|
3795
3798
|
description: O()
|
|
3796
|
-
}),
|
|
3799
|
+
}), Tl = (e) => wl.safeParse(e).success, El = (e) => {
|
|
3797
3800
|
let t = e.editor.map(({ givenName: e, familyName: t }) => `${e} ${t}`), n = e.name, [r, i] = e.issn, a = e.publisher.name;
|
|
3798
3801
|
return L(F.Journal, {
|
|
3799
3802
|
au: t,
|
|
@@ -3802,15 +3805,15 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3802
3805
|
issn: i,
|
|
3803
3806
|
pub: a
|
|
3804
3807
|
});
|
|
3805
|
-
},
|
|
3806
|
-
"@type": N(
|
|
3808
|
+
}, Dl = j({
|
|
3809
|
+
"@type": N(cl.VideoObject),
|
|
3807
3810
|
name: O().optional(),
|
|
3808
3811
|
description: O().optional(),
|
|
3809
3812
|
thumbnailUrl: O().optional(),
|
|
3810
3813
|
uploadDate: O().optional(),
|
|
3811
3814
|
contentUrl: O().optional(),
|
|
3812
3815
|
duration: O().optional()
|
|
3813
|
-
}),
|
|
3816
|
+
}), Ol = (e) => Dl.safeParse(e).success, kl = (e, t) => {
|
|
3814
3817
|
let n = Array.from(e.querySelectorAll("dd[data-test=\"video-segment-author\"]")).map((e) => e.textContent.trim()).filter((e) => !!e), r = t?.uploadDate ? new Date(t.uploadDate).getFullYear().toString() : void 0, i = t?.name ?? V(e, "property", "og:title") ?? void 0, a = e.querySelector("video-about-doi")?.textContent ?? void 0;
|
|
3815
3818
|
return R({
|
|
3816
3819
|
au: n.length > 0 ? n : void 0,
|
|
@@ -3818,26 +3821,26 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3818
3821
|
doi: a,
|
|
3819
3822
|
title: i
|
|
3820
3823
|
});
|
|
3821
|
-
},
|
|
3824
|
+
}, Al = (e) => _o({ title: V(e, "property", "og:title") }), jl = (e, t) => {
|
|
3822
3825
|
let n = V(t, "property", "og:type");
|
|
3823
|
-
return n ===
|
|
3824
|
-
},
|
|
3825
|
-
let n =
|
|
3826
|
-
if (n === U.Webpage) return B(
|
|
3827
|
-
let r =
|
|
3826
|
+
return n === ll.Article && e.includes(ul.Article) ? U.Article : n === ll.Book && (e.includes(ul.Book) || e.includes(ul.ReferenceWork)) ? U.Book : n === ll.Paper && e.includes(ul.Chapter) ? U.Chapter : n === ll.Paper && (e.includes(ul.ReferenceWorkEntry) || e.includes(ul.Protocol)) ? U.Article : n === ll.Video && e.includes(ul.Video) ? U.AudioVisual : n === ll.Website && (e.includes(ul.Collections) || e.includes(ul.JournalIssue)) ? U.Webpage : n === ll.Website && e.includes(ul.Journal) ? U.Journal : U.None;
|
|
3827
|
+
}, Ml = (e, t, n) => e === U.AudioVisual && Ol(n) ? B(kl(t, n)) : e === U.Book && bl(n) ? B(Cl(t, n)) : (e === U.Chapter || e === U.Article) && fl(n) ? B(vl(t, n)) : e === U.Article && ml(n) ? B(vl(t, n.mainEntity)) : e === U.Journal && Tl(n) ? B(El(n)) : z(), Nl = ({ url: e, document: t }) => {
|
|
3828
|
+
let n = jl(e, t);
|
|
3829
|
+
if (n === U.Webpage) return B(Al(t));
|
|
3830
|
+
let r = $s(t);
|
|
3828
3831
|
if (!r) return z();
|
|
3829
|
-
let i =
|
|
3830
|
-
return i ?
|
|
3832
|
+
let i = ec(r);
|
|
3833
|
+
return i ? Ml(n, t, i) : z();
|
|
3831
3834
|
}, G = /* @__PURE__ */ function(e) {
|
|
3832
3835
|
return e.PrintIsbn = "Print ISBN", e.OnlineIsbn = "Online ISBN", e.Doi = "DOI", e.FirstPublished = "First published", e.OnlineIssn = "Online ISSN", e.PrintIssn = "Print ISSN", e;
|
|
3833
|
-
}(G || {}),
|
|
3836
|
+
}(G || {}), Pl = new Set([
|
|
3834
3837
|
G.PrintIsbn,
|
|
3835
3838
|
G.OnlineIsbn,
|
|
3836
3839
|
G.Doi,
|
|
3837
3840
|
G.FirstPublished,
|
|
3838
3841
|
G.OnlineIssn,
|
|
3839
3842
|
G.PrintIssn
|
|
3840
|
-
]),
|
|
3843
|
+
]), Fl = j({ content: j({
|
|
3841
3844
|
item: j({
|
|
3842
3845
|
title: O(),
|
|
3843
3846
|
"published-date": O()
|
|
@@ -3851,66 +3854,66 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3851
3854
|
type: O(),
|
|
3852
3855
|
eissn: O()
|
|
3853
3856
|
})
|
|
3854
|
-
}).optional() }),
|
|
3857
|
+
}).optional() }), Il = (e, t) => {
|
|
3855
3858
|
if (!e) return;
|
|
3856
3859
|
let n = e.indexOf(t);
|
|
3857
3860
|
return n > -1 ? e.substring(0, n) : e;
|
|
3858
|
-
},
|
|
3861
|
+
}, Ll = (e) => {
|
|
3859
3862
|
let t = /\d+/.exec(e);
|
|
3860
3863
|
if (t?.[0]) return t[0];
|
|
3861
|
-
},
|
|
3864
|
+
}, Rl = (e) => {
|
|
3862
3865
|
let t = e.querySelectorAll("script"), n = Array.from(t).find((e) => e.textContent.includes("adobeDataLayerJson"))?.textContent.match(/var adobeDataLayerJson = (\{.*?});/s);
|
|
3863
3866
|
if (n?.length === 2) try {
|
|
3864
3867
|
let e = JSON.parse(n[1]);
|
|
3865
|
-
return
|
|
3868
|
+
return Fl.parse(e);
|
|
3866
3869
|
} catch {
|
|
3867
3870
|
return;
|
|
3868
3871
|
}
|
|
3869
|
-
},
|
|
3872
|
+
}, zl = (e, t) => {
|
|
3870
3873
|
let n = V(e, "property", "og:type"), r = t.includes("epdf");
|
|
3871
3874
|
return n === "Book" || n === "books.book" ? U.Book : n === "Chapter" ? U.Chapter : n === "Journal" ? U.Journal : n === "Article" || r ? U.Article : U.None;
|
|
3872
|
-
},
|
|
3875
|
+
}, Bl = (e) => {
|
|
3873
3876
|
let t = H(e, "name", "citation_author"), n = Array.from(e.querySelectorAll("#product-details-content .product-authors")).map((e) => e.textContent).filter((e) => !!e), r = new Set([...t, ...n]);
|
|
3874
3877
|
return r.size > 0 ? [...r] : void 0;
|
|
3875
|
-
},
|
|
3878
|
+
}, Vl = (e) => {
|
|
3876
3879
|
let t = Array.from(e.querySelectorAll("#product-details-content .text-piped p")).map((e) => e.textContent).find((e) => e.endsWith(" pages"));
|
|
3877
|
-
if (t) return
|
|
3878
|
-
},
|
|
3880
|
+
if (t) return Ll(t);
|
|
3881
|
+
}, Hl = (e) => {
|
|
3879
3882
|
let t = /* @__PURE__ */ new Map(), n = Array.from(e.querySelectorAll(".journal-info-container .info-block")).flatMap((e) => Array.from(e.querySelectorAll(".info_label")));
|
|
3880
3883
|
for (let e of n) {
|
|
3881
3884
|
let n = e.nextElementSibling;
|
|
3882
3885
|
if (!n?.classList.contains("info_value")) continue;
|
|
3883
|
-
let r =
|
|
3884
|
-
!r || !i ||
|
|
3886
|
+
let r = Il(e.textContent, ":"), i = Il(n.textContent, ":");
|
|
3887
|
+
!r || !i || Pl.has(r) && t.set(r, i);
|
|
3885
3888
|
}
|
|
3886
3889
|
return t;
|
|
3887
|
-
},
|
|
3890
|
+
}, Ul = (e, t) => V(e, "property", "books:release_date") ?? V(e, "name", "citation_online_date") ?? t.get(G.FirstPublished) ?? void 0, Wl = (e, t) => V(e, "name", "dc.identifier") ?? V(e, "name", "citation_doi") ?? V(e, "name", "publication_doi") ?? t.get(G.Doi) ?? void 0, Gl = (e, t) => {
|
|
3888
3891
|
let n = new Set([
|
|
3889
3892
|
V(e, "property", "books:isbn"),
|
|
3890
3893
|
t.get(G.PrintIsbn),
|
|
3891
3894
|
t.get(G.OnlineIsbn)
|
|
3892
3895
|
].filter((e) => !!e));
|
|
3893
3896
|
return n.size > 0 ? [...n].join(",") : void 0;
|
|
3894
|
-
},
|
|
3897
|
+
}, Kl = (e) => {
|
|
3895
3898
|
let t, n, r = e.querySelector(".cover-image__details div:first-of-type");
|
|
3896
3899
|
if (r?.childNodes.length === 2) {
|
|
3897
3900
|
let [e, i] = r.childNodes;
|
|
3898
|
-
e.textContent && (t =
|
|
3901
|
+
e.textContent && (t = Ll(e.textContent)), i.textContent && (n = Ll(i.textContent));
|
|
3899
3902
|
}
|
|
3900
3903
|
return {
|
|
3901
3904
|
volume: t,
|
|
3902
3905
|
issue: n
|
|
3903
3906
|
};
|
|
3904
|
-
},
|
|
3907
|
+
}, ql = (e) => {
|
|
3905
3908
|
let t = Array.from(e.querySelectorAll(".authors .author")).map((e) => e.textContent.trim().replace(",", "")).filter((e) => !!e);
|
|
3906
3909
|
return t.length > 0 ? t : void 0;
|
|
3907
|
-
},
|
|
3910
|
+
}, Jl = (e) => {
|
|
3908
3911
|
let t = Array.from(e.querySelectorAll(".details-section .details-entry")), n = t.find((e) => e.querySelector(".details-label")?.textContent.trim() === "ISSN"), r = t.find((e) => e.querySelector(".details-label")?.textContent.trim() === "eISSN"), i, a;
|
|
3909
3912
|
return n && (i = n.querySelector(".details-value")?.textContent.trim()), r && (a = r.querySelector(".details-value")?.textContent.trim()), {
|
|
3910
3913
|
issn: i,
|
|
3911
3914
|
eissn: a
|
|
3912
3915
|
};
|
|
3913
|
-
},
|
|
3916
|
+
}, Yl = (e) => {
|
|
3914
3917
|
if (!e?.content?.group) return {
|
|
3915
3918
|
volume: void 0,
|
|
3916
3919
|
issue: void 0
|
|
@@ -3923,7 +3926,7 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3923
3926
|
volume: t,
|
|
3924
3927
|
issue: n
|
|
3925
3928
|
};
|
|
3926
|
-
},
|
|
3929
|
+
}, Xl = (e) => {
|
|
3927
3930
|
let [t, n] = ((Array.from(e.querySelectorAll(".details-section .details-entry")).find((e) => e.querySelector(".details-label")?.textContent.trim() === "Pages")?.querySelector(".details-value")?.textContent.trim())?.split("-") ?? [void 0, void 0]).map((e) => e?.trim());
|
|
3928
3931
|
return t?.toLowerCase() === "n/a" && n?.toLowerCase() === "n/a" ? {
|
|
3929
3932
|
spage: void 0,
|
|
@@ -3932,8 +3935,8 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3932
3935
|
spage: t,
|
|
3933
3936
|
epage: n
|
|
3934
3937
|
};
|
|
3935
|
-
},
|
|
3936
|
-
let t =
|
|
3938
|
+
}, Zl = (e) => {
|
|
3939
|
+
let t = Hl(e), n = Bl(e), r = V(e, "property", "og:title"), i = Ul(e, t), a = Wl(e, t), o = Gl(e, t), s = Vl(e);
|
|
3937
3940
|
return I(F.Book, {
|
|
3938
3941
|
au: n,
|
|
3939
3942
|
date: i,
|
|
@@ -3942,8 +3945,8 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3942
3945
|
pages: s,
|
|
3943
3946
|
title: r
|
|
3944
3947
|
});
|
|
3945
|
-
},
|
|
3946
|
-
let t =
|
|
3948
|
+
}, Ql = (e) => {
|
|
3949
|
+
let t = Hl(e), n = Bl(e), r = V(e, "name", "citation_book_title"), i = Ul(e, t), a = Wl(e, t), o = Gl(e, t), s = V(e, "name", "citation_publisher"), c = V(e, "property", "og:title");
|
|
3947
3950
|
return I(F.Bookitem, {
|
|
3948
3951
|
au: n,
|
|
3949
3952
|
btitle: r,
|
|
@@ -3953,8 +3956,8 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3953
3956
|
pub: s,
|
|
3954
3957
|
title: c
|
|
3955
3958
|
});
|
|
3956
|
-
},
|
|
3957
|
-
let t =
|
|
3959
|
+
}, $l = (e) => {
|
|
3960
|
+
let t = Hl(e), n = Bl(e), r = Ul(e, t), i = t.get(G.OnlineIssn), a = t.get(G.PrintIssn), o = V(e, "property", "og:title"), { volume: s, issue: c } = Kl(e);
|
|
3958
3961
|
return L(F.Journal, {
|
|
3959
3962
|
au: n,
|
|
3960
3963
|
date: r,
|
|
@@ -3964,8 +3967,8 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3964
3967
|
title: o,
|
|
3965
3968
|
volume: s
|
|
3966
3969
|
});
|
|
3967
|
-
},
|
|
3968
|
-
let t =
|
|
3970
|
+
}, eu = (e) => {
|
|
3971
|
+
let t = Hl(e), n = Rl(e), r = Bl(e) ?? ql(e), i = Ul(e, t) ?? n?.content?.item["published-date"], a = Wl(e, t), { issn: o, eissn: s } = Jl(e), { volume: c, issue: l } = Yl(n), u = V(e, "property", "og:title") ?? n?.content?.item.title, d = V(e, "name", "citation_journal_title") ?? n?.content?.series.title, { spage: f, epage: p } = Xl(e);
|
|
3969
3972
|
return L(F.Article, {
|
|
3970
3973
|
au: r,
|
|
3971
3974
|
date: i,
|
|
@@ -3979,71 +3982,71 @@ var Zc = (e) => Array.from(e.querySelectorAll("tr th")).find((e) => e.textConten
|
|
|
3979
3982
|
spage: f,
|
|
3980
3983
|
epage: p
|
|
3981
3984
|
});
|
|
3982
|
-
},
|
|
3983
|
-
switch (
|
|
3984
|
-
case U.Book: return B(
|
|
3985
|
-
case U.Chapter: return B(
|
|
3986
|
-
case U.Journal: return B(
|
|
3987
|
-
case U.Article: return B(
|
|
3985
|
+
}, tu = ({ document: e, url: t }) => {
|
|
3986
|
+
switch (zl(e, t)) {
|
|
3987
|
+
case U.Book: return B(Zl(e));
|
|
3988
|
+
case U.Chapter: return B(Ql(e));
|
|
3989
|
+
case U.Journal: return B($l(e));
|
|
3990
|
+
case U.Article: return B(eu(e));
|
|
3988
3991
|
default: return z();
|
|
3989
3992
|
}
|
|
3990
|
-
},
|
|
3993
|
+
}, nu = (e) => {
|
|
3991
3994
|
let t = H(e, "name", "citation_author");
|
|
3992
3995
|
return t.length > 0 ? t : void 0;
|
|
3993
|
-
},
|
|
3994
|
-
au:
|
|
3996
|
+
}, ru = ({ document: e }) => B(R({
|
|
3997
|
+
au: nu(e),
|
|
3995
3998
|
date: V(e, "name", "citation_publication_date"),
|
|
3996
3999
|
doi: V(e, "name", "citation_doi"),
|
|
3997
4000
|
isbn: V(e, "name", "citation_isbn"),
|
|
3998
4001
|
pub: V(e, "name", "citation_publisher"),
|
|
3999
4002
|
title: V(e, "name", "citation_title") ?? e.title
|
|
4000
|
-
})),
|
|
4003
|
+
})), iu = ({ document: e }) => Array.from(e.querySelectorAll(".Z3988")).length <= 1 ? z() : $o(), au = (e) => {
|
|
4001
4004
|
if (!(!e || e.length === 0)) return e[0];
|
|
4002
4005
|
};
|
|
4003
4006
|
//#endregion
|
|
4004
4007
|
//#region src/parsers/shared/parsing-utils.ts
|
|
4005
|
-
function
|
|
4006
|
-
return
|
|
4008
|
+
function ou(e, t) {
|
|
4009
|
+
return au(t.map((t) => {
|
|
4007
4010
|
let n = e.querySelector(t)?.textContent ?? null;
|
|
4008
4011
|
if (n && n.trim() !== "") return n;
|
|
4009
4012
|
}).filter((e) => e)) ?? null;
|
|
4010
4013
|
}
|
|
4011
|
-
function
|
|
4014
|
+
function su(e, t) {
|
|
4012
4015
|
let n = t.flatMap((t) => Array.from(e.querySelectorAll(t)).flatMap((e) => {
|
|
4013
4016
|
let t = e.textContent;
|
|
4014
4017
|
return t && t.trim() !== "" ? t.split(";").map((e) => e.trim()).filter((e) => e.length > 0) : [];
|
|
4015
4018
|
}));
|
|
4016
4019
|
return n.length > 0 ? n : null;
|
|
4017
4020
|
}
|
|
4018
|
-
var
|
|
4021
|
+
var cu = (e, t) => ou(e, [t])?.trim(), lu = (e) => {
|
|
4019
4022
|
let t = e.querySelector(".content-meta-data__authors")?.textContent;
|
|
4020
4023
|
if (t) return t.split(/,\s+|\s+and\s+/).filter((e) => !!e);
|
|
4021
|
-
},
|
|
4024
|
+
}, uu = (e) => {
|
|
4022
4025
|
let t = Array.from(e.querySelectorAll(".tombstone-metadata [data-qa=\"item-authors\"]")).map((e) => e.textContent).filter((e) => !!e);
|
|
4023
4026
|
return t.length ? t : void 0;
|
|
4024
|
-
},
|
|
4027
|
+
}, du = (e) => {
|
|
4025
4028
|
let t = Array.from(e.querySelectorAll(".item-authors [data-qa=\"item-contributors\"], .item-authors [data-qa=\"item-creators\"]")).map((e) => e.textContent).filter((e) => !!e);
|
|
4026
4029
|
return t.length ? t : void 0;
|
|
4027
|
-
},
|
|
4030
|
+
}, fu = (e) => {
|
|
4028
4031
|
let t = Array.from(e.querySelectorAll(".contrib-type-author .name")).map((e) => e.textContent).filter((e) => !!e);
|
|
4029
4032
|
return t.length ? t : void 0;
|
|
4030
|
-
},
|
|
4033
|
+
}, pu = (e) => {
|
|
4031
4034
|
let t = new Set([
|
|
4035
|
+
...du(e) ?? [],
|
|
4032
4036
|
...lu(e) ?? [],
|
|
4033
|
-
...
|
|
4034
|
-
...uu(e) ?? []
|
|
4035
|
-
...cu(e) ?? []
|
|
4037
|
+
...fu(e) ?? [],
|
|
4038
|
+
...uu(e) ?? []
|
|
4036
4039
|
]);
|
|
4037
4040
|
return t.size ? [...t] : void 0;
|
|
4038
|
-
},
|
|
4041
|
+
}, mu = (e, t) => e.querySelector("[data-qa=\"published-date\"]")?.textContent ?? e.querySelector(".summary-image")?.textContent ?? vu(t?.get("date")) ?? vu(t?.get("copyright date")) ?? vu(t?.get("published date")), hu = (e) => {
|
|
4039
4042
|
let t = e.find((e) => e.startsWith("https://doi.org/"));
|
|
4040
4043
|
if (t) return t.replace("https://doi.org/", "");
|
|
4041
|
-
},
|
|
4044
|
+
}, gu = (e) => {
|
|
4042
4045
|
let t = e.get("local identifier");
|
|
4043
|
-
if (t?.length) return
|
|
4044
|
-
},
|
|
4046
|
+
if (t?.length) return hu(t);
|
|
4047
|
+
}, _u = (e) => e.querySelector(".doi")?.getAttribute("href") ?? void 0, vu = (e) => {
|
|
4045
4048
|
if (e?.length) return e[0];
|
|
4046
|
-
},
|
|
4049
|
+
}, yu = (e) => {
|
|
4047
4050
|
let t = /* @__PURE__ */ new Map();
|
|
4048
4051
|
return Array.from(e.querySelectorAll(".metadata-element, .metadata")).map((e) => ({
|
|
4049
4052
|
name: e.querySelector(".metadata-label")?.textContent.trim().toLowerCase(),
|
|
@@ -4051,24 +4054,24 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4051
4054
|
})).forEach(({ name: e, values: n }) => {
|
|
4052
4055
|
!e || !n.length || t.set(e, n);
|
|
4053
4056
|
}), t;
|
|
4054
|
-
},
|
|
4055
|
-
let t =
|
|
4057
|
+
}, bu = (e) => {
|
|
4058
|
+
let t = yu(e), n = e.querySelector(".summary-journal"), r = Array.from(n?.childNodes ?? []), i = r[0]?.textContent ?? e.querySelector(".journal-link")?.textContent ?? void 0, a = r[2]?.textContent?.replace(/Published By:\s+?/i, "") ?? vu(t.get("publisher")) ?? e.querySelector(".publisher-link")?.textContent ?? void 0;
|
|
4056
4059
|
return {
|
|
4057
4060
|
pub: a && a.trim() !== "" ? a : void 0,
|
|
4058
4061
|
jtitle: i && i.trim() !== "" ? i : void 0
|
|
4059
4062
|
};
|
|
4060
|
-
},
|
|
4061
|
-
let t =
|
|
4063
|
+
}, xu = (e) => {
|
|
4064
|
+
let t = ou(e, [
|
|
4062
4065
|
"[data-qa=\"journal\"]:first-child cite",
|
|
4063
4066
|
"[data-qa=\"copyright-statement\"] > cite",
|
|
4064
4067
|
"[data-qa=\"collection-links\"] mfe-content-details-pharos-link"
|
|
4065
4068
|
]);
|
|
4066
4069
|
return t && t.trim() !== "" ? t : void 0;
|
|
4067
|
-
},
|
|
4070
|
+
}, Su = (e) => Os(e.querySelector("[data-qa=\"page-count\"]")?.textContent), Cu = (e, t) => e.querySelector(".publisher-link")?.textContent ?? vu(t?.get("publisher")), wu = (e) => e.querySelector("[data-qa=\"item-title\"]")?.textContent.trim() ?? e.querySelector("mfe-turnaway-pharos-heading")?.textContent.trim() ?? e.querySelector(".metadata mfe-toc-pharos-heading")?.textContent.trim() ?? e.querySelector(".journal_header-title")?.textContent.trim() ?? void 0, Tu = (e) => {
|
|
4068
4071
|
if (!URL.canParse(e)) return;
|
|
4069
4072
|
let t = new URL(e);
|
|
4070
4073
|
return t.origin + t.pathname;
|
|
4071
|
-
},
|
|
4074
|
+
}, Eu = (e) => {
|
|
4072
4075
|
let t = e.querySelector(".ccda-container > :first-child"), n, r;
|
|
4073
4076
|
if (t?.textContent.includes("Volume") || t?.textContent.includes("Issue")) {
|
|
4074
4077
|
let e = t.textContent.trim().split(/,\s+/);
|
|
@@ -4078,7 +4081,7 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4078
4081
|
issue: n,
|
|
4079
4082
|
volume: r
|
|
4080
4083
|
};
|
|
4081
|
-
},
|
|
4084
|
+
}, Du = (e) => {
|
|
4082
4085
|
let t = e.querySelector("[data-qa=\"item-src-info\"]")?.textContent ?? V(e, "property", "og:description") ?? V(e, "name", "description");
|
|
4083
4086
|
if (!t) return {};
|
|
4084
4087
|
let n = /Vol\.\s*(\d+)/.exec(t), r = n ? n[1] : void 0, i = /No\.\s*(\d+)/.exec(t), a = i ? i[1] : void 0, o = /pp\.\s*(\d+)-(\d+)/.exec(t), s = o ? o[1] : void 0, c = o ? o[2] : void 0, l = /pp\.\s*\d+-\d+\s*\((\d+)\s*pages\)/.exec(t);
|
|
@@ -4089,16 +4092,16 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4089
4092
|
epage: c,
|
|
4090
4093
|
pages: l ? l[1] : void 0
|
|
4091
4094
|
};
|
|
4092
|
-
},
|
|
4093
|
-
let t =
|
|
4095
|
+
}, Ou = (e) => {
|
|
4096
|
+
let t = ou(e, ["mfe-turnaway-pharos-link", "[data-qa=\"item-src-info\"]"]);
|
|
4094
4097
|
if (!t) return;
|
|
4095
4098
|
let n = /\(.+\)/.exec(t)?.map((e) => {
|
|
4096
4099
|
let t = /\d{4}/.exec(e);
|
|
4097
4100
|
return t ? t[0] : void 0;
|
|
4098
4101
|
});
|
|
4099
|
-
return
|
|
4100
|
-
},
|
|
4101
|
-
let n =
|
|
4102
|
+
return au(n);
|
|
4103
|
+
}, ku = (e, t) => {
|
|
4104
|
+
let n = wu(e), r = pu(e), i = mu(e) ?? Ou(e), a = bu(e), o = a.jtitle ?? xu(e) ?? void 0, s = a.pub, c = Eu(e), l = Du(e), u = c.issue ?? l.issue, d = c.volume ?? l.volume, f = Su(e) ?? l.pages, p = l.spage, m = l.epage, h = Tu(t), g = hu(Array.from(e.querySelector(".content-meta-data-stables")?.childNodes ?? []).map((e) => e.textContent ?? "")) ?? _u(e);
|
|
4102
4105
|
return L(F.Article, {
|
|
4103
4106
|
atitle: n,
|
|
4104
4107
|
au: r,
|
|
@@ -4113,17 +4116,17 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4113
4116
|
uri: h,
|
|
4114
4117
|
volume: d
|
|
4115
4118
|
});
|
|
4116
|
-
},
|
|
4117
|
-
let n =
|
|
4119
|
+
}, Au = (e, t) => {
|
|
4120
|
+
let n = yu(e), r = pu(e), i = mu(e, n), a = wu(e);
|
|
4118
4121
|
return R({
|
|
4119
4122
|
au: r,
|
|
4120
4123
|
date: i,
|
|
4121
|
-
pub:
|
|
4124
|
+
pub: Cu(e, n),
|
|
4122
4125
|
title: a,
|
|
4123
|
-
uri:
|
|
4126
|
+
uri: Tu(t)
|
|
4124
4127
|
});
|
|
4125
|
-
},
|
|
4126
|
-
let n =
|
|
4128
|
+
}, ju = (e, t) => {
|
|
4129
|
+
let n = yu(e), r = pu(e), i = wu(e), a = mu(e), o = Su(e), s = Cu(e, n), c = Tu(t), l = gu(n);
|
|
4127
4130
|
return I(F.Book, {
|
|
4128
4131
|
au: r,
|
|
4129
4132
|
date: a,
|
|
@@ -4133,8 +4136,8 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4133
4136
|
title: i,
|
|
4134
4137
|
uri: c
|
|
4135
4138
|
});
|
|
4136
|
-
},
|
|
4137
|
-
let n =
|
|
4139
|
+
}, Mu = (e, t) => {
|
|
4140
|
+
let n = yu(e), r = pu(e), i = wu(e), a = e.querySelector(".book-title-link")?.textContent ?? void 0, o = mu(e, n), s = Array.from(e.querySelectorAll("[data-qa=\"book\"] > span")).map((e) => e.textContent), c = Su(e), l = s.find((e) => e.includes("pp."))?.match(/(\d+)-(\d+)/) ?? void 0, u = Cu(e, n), d = Tu(t);
|
|
4138
4141
|
return I(F.Bookitem, {
|
|
4139
4142
|
atitle: i,
|
|
4140
4143
|
au: r,
|
|
@@ -4146,8 +4149,8 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4146
4149
|
spage: l?.[1],
|
|
4147
4150
|
uri: d
|
|
4148
4151
|
});
|
|
4149
|
-
},
|
|
4150
|
-
let n =
|
|
4152
|
+
}, Nu = (e, t) => {
|
|
4153
|
+
let n = yu(e), r = pu(e), i = wu(e), a = mu(e), o = Su(e), s = Cu(e, n), c = Tu(t), l = gu(n);
|
|
4151
4154
|
return I(F.Document, {
|
|
4152
4155
|
au: r,
|
|
4153
4156
|
date: a,
|
|
@@ -4157,16 +4160,16 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4157
4160
|
title: i,
|
|
4158
4161
|
uri: c
|
|
4159
4162
|
});
|
|
4160
|
-
},
|
|
4161
|
-
let n =
|
|
4163
|
+
}, Pu = (e, t) => {
|
|
4164
|
+
let n = yu(e);
|
|
4162
4165
|
return ho({
|
|
4163
|
-
au:
|
|
4164
|
-
date:
|
|
4165
|
-
title:
|
|
4166
|
-
uri:
|
|
4166
|
+
au: pu(e),
|
|
4167
|
+
date: mu(e, n),
|
|
4168
|
+
title: wu(e),
|
|
4169
|
+
uri: Tu(t)
|
|
4167
4170
|
});
|
|
4168
|
-
},
|
|
4169
|
-
let { pub: n } =
|
|
4171
|
+
}, Fu = (e, t) => {
|
|
4172
|
+
let { pub: n } = bu(e), r = wu(e), i = e.querySelector(".eissn")?.textContent.replace(/EISSN\s+/, "").trim() ?? void 0, a = e.querySelector(".issn")?.textContent.replace(/ISSN\s+/, "").trim() ?? void 0, o = Tu(t);
|
|
4170
4173
|
return L(F.Journal, {
|
|
4171
4174
|
eissn: i,
|
|
4172
4175
|
issn: a,
|
|
@@ -4176,66 +4179,66 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4176
4179
|
});
|
|
4177
4180
|
}, K = /* @__PURE__ */ function(e) {
|
|
4178
4181
|
return e.Article = "journal article", e.Audio = "audio", e.Book = "book", e.Chapter = "book chapter", e.Document = "document", e.Image = "image", e.Journal = "journal", e.ResearchReport = "research report", e.Serial = "serial", e.Video = "video", e;
|
|
4179
|
-
}({}),
|
|
4180
|
-
let n =
|
|
4182
|
+
}({}), Iu = (e, t) => {
|
|
4183
|
+
let n = yu(e), r = pu(e), i = mu(e, n), a = wu(e);
|
|
4181
4184
|
return R({
|
|
4182
4185
|
au: r,
|
|
4183
4186
|
date: i,
|
|
4184
|
-
pub:
|
|
4187
|
+
pub: Cu(e, n),
|
|
4185
4188
|
title: a,
|
|
4186
|
-
uri:
|
|
4189
|
+
uri: Tu(t)
|
|
4187
4190
|
});
|
|
4188
|
-
},
|
|
4191
|
+
}, Lu = (e) => Object.values(K).includes(e), Ru = (e) => {
|
|
4189
4192
|
if (e.querySelector(".journal_header-title")) return K.Journal;
|
|
4190
4193
|
if (e.querySelector(".journal-link")) return K.Article;
|
|
4191
4194
|
let t = e.querySelector(".content-type > span")?.textContent.toLowerCase().trim() ?? e.querySelector(".content-meta-data-label")?.textContent.toLowerCase().trim();
|
|
4192
|
-
return
|
|
4193
|
-
},
|
|
4194
|
-
switch (
|
|
4195
|
+
return Lu(t) ? t : null;
|
|
4196
|
+
}, zu = (e, t) => {
|
|
4197
|
+
switch (Ru(e)) {
|
|
4195
4198
|
case K.Article:
|
|
4196
|
-
case K.Serial: return
|
|
4197
|
-
case K.Audio: return
|
|
4198
|
-
case K.Book: return
|
|
4199
|
+
case K.Serial: return ku(e, t);
|
|
4200
|
+
case K.Audio: return Au(e, t);
|
|
4201
|
+
case K.Book: return ju(e, t);
|
|
4199
4202
|
case K.Chapter:
|
|
4200
|
-
case K.ResearchReport: return
|
|
4201
|
-
case K.Document: return
|
|
4202
|
-
case K.Image: return
|
|
4203
|
-
case K.Journal: return
|
|
4204
|
-
case K.Video: return
|
|
4203
|
+
case K.ResearchReport: return Mu(e, t);
|
|
4204
|
+
case K.Document: return Nu(e, t);
|
|
4205
|
+
case K.Image: return Pu(e, t);
|
|
4206
|
+
case K.Journal: return Fu(e, t);
|
|
4207
|
+
case K.Video: return Iu(e, t);
|
|
4205
4208
|
default: return null;
|
|
4206
4209
|
}
|
|
4207
|
-
},
|
|
4208
|
-
let n =
|
|
4210
|
+
}, Bu = ({ document: e, url: t }) => {
|
|
4211
|
+
let n = zu(e, t);
|
|
4209
4212
|
return n ? B(n) : z();
|
|
4210
|
-
},
|
|
4213
|
+
}, Vu = /([0-9]{4}-[0-9]{1,2}-[0-9]{1,2}|[0-9]{4}-[0-9]{1,2}|[0-9]{4})/, Hu = /(E?ISBN|E?ISSN|DOI)\s*:\s*/gi, Uu = (e) => {
|
|
4211
4214
|
if (!e) return;
|
|
4212
|
-
let t =
|
|
4215
|
+
let t = Vu.exec(e);
|
|
4213
4216
|
if (t) return t.length > 1 ? t[1] : void 0;
|
|
4214
|
-
},
|
|
4217
|
+
}, Wu = (e) => {
|
|
4215
4218
|
let t = {};
|
|
4216
4219
|
return e.forEach((e) => {
|
|
4217
4220
|
let n = [], r;
|
|
4218
|
-
for (
|
|
4221
|
+
for (Hu.lastIndex = 0; (r = Hu.exec(e)) !== null;) n.push({
|
|
4219
4222
|
id: r[1].toLowerCase(),
|
|
4220
4223
|
index: r.index,
|
|
4221
|
-
start:
|
|
4224
|
+
start: Hu.lastIndex
|
|
4222
4225
|
});
|
|
4223
4226
|
n.forEach(({ id: r, start: i }, a) => {
|
|
4224
4227
|
t[r] ??= [], t[r].push(e.substring(i, n[a + 1]?.index).trim());
|
|
4225
4228
|
});
|
|
4226
4229
|
}), t;
|
|
4227
|
-
},
|
|
4230
|
+
}, Gu = (e) => [...e.isbn ?? [], ...e.eisbn ?? []].map((e) => zs(e)).filter((e) => !!e), Ku = (e) => {
|
|
4228
4231
|
if (e) {
|
|
4229
4232
|
if (typeof e == "string") return e;
|
|
4230
4233
|
if (e.length > 0) return e[0];
|
|
4231
4234
|
}
|
|
4232
|
-
},
|
|
4233
|
-
if (e) return typeof e == "string" ? e : Array.isArray(e) ? e.length === 0 ? void 0 :
|
|
4234
|
-
},
|
|
4235
|
+
}, qu = (e) => {
|
|
4236
|
+
if (e) return typeof e == "string" ? e : Array.isArray(e) ? e.length === 0 ? void 0 : Ku(e[0].name) : Ku(e.name);
|
|
4237
|
+
}, Ju = (...e) => {
|
|
4235
4238
|
let t = new Set(e.filter((e) => !!e));
|
|
4236
4239
|
if (t.size !== 0) return [...t];
|
|
4237
|
-
},
|
|
4238
|
-
let t =
|
|
4240
|
+
}, Yu = (e) => {
|
|
4241
|
+
let t = Wu(e.identifierValues), [n] = e.isPartOf?.split(",") ?? [], r = Uu(e.publicationDate ?? e.creationDate), i = Gu(t);
|
|
4239
4242
|
return {
|
|
4240
4243
|
authors: e.authors,
|
|
4241
4244
|
date: r,
|
|
@@ -4249,58 +4252,62 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4249
4252
|
publisher: e.publisher,
|
|
4250
4253
|
title: e.title
|
|
4251
4254
|
};
|
|
4252
|
-
},
|
|
4255
|
+
}, Xu = ({ lcn: e, title: t }) => ({
|
|
4253
4256
|
bibid: e,
|
|
4254
4257
|
title: t
|
|
4255
|
-
}),
|
|
4258
|
+
}), Zu = /_ALMA(_|$)/, Qu = (e) => {
|
|
4256
4259
|
let t = e.mainEntity.creator;
|
|
4257
|
-
if (t) return typeof t == "string" ? [t] : Array.isArray(t) ? t.map((e) =>
|
|
4258
|
-
},
|
|
4260
|
+
if (t) return typeof t == "string" ? [t] : Array.isArray(t) ? t.map((e) => Ku(e.name)).filter((e) => !!e) : [Ku(t.name)].filter((e) => !!e);
|
|
4261
|
+
}, $u = (e) => {
|
|
4259
4262
|
let t = e.mainEntity.issn;
|
|
4260
4263
|
return t ? typeof t == "string" ? [t] : t : [];
|
|
4261
|
-
},
|
|
4264
|
+
}, ed = (e) => {
|
|
4262
4265
|
let t = e.mainEntity.datePublished;
|
|
4263
4266
|
if (t) return t.replace(/-$/, "") || void 0;
|
|
4264
|
-
},
|
|
4265
|
-
let n =
|
|
4267
|
+
}, td = (e) => e.replace(/[.,;]+$/, "").trim(), nd = (e, t) => {
|
|
4268
|
+
let n = td(e), r = td(t);
|
|
4266
4269
|
return n.startsWith(r) || r.startsWith(n);
|
|
4267
|
-
},
|
|
4270
|
+
}, rd = (e) => {
|
|
4268
4271
|
let t = [];
|
|
4269
|
-
for (let n of e) n && (t.some((e) =>
|
|
4272
|
+
for (let n of e) n && (t.some((e) => nd(e, n)) || t.push(n));
|
|
4270
4273
|
return t.length > 0 ? t : void 0;
|
|
4271
|
-
}
|
|
4272
|
-
|
|
4274
|
+
};
|
|
4275
|
+
function id(e) {
|
|
4276
|
+
if (e) return Zu.test(e) ? e.replace(Zu, "") : e.startsWith("alma") ? e.replace("alma", "") : e;
|
|
4277
|
+
}
|
|
4278
|
+
var ad = (e, t) => {
|
|
4279
|
+
let n = rd([...(e && Qu(e)) ?? [], ...t.authors ?? []]), r = Ju(...t.eissns ?? []), i = Ju(e?.mainEntity.isbn ? zs(e.mainEntity.isbn) : void 0, ...t.isbns ?? []), a = Ju(...e ? $u(e) : [], ...t.issns ?? []), [o, s] = e?.mainEntity.pagination?.split("-") ?? [];
|
|
4273
4280
|
return {
|
|
4274
4281
|
authors: n,
|
|
4275
4282
|
btitle: e?.mainEntity.isPartOf?.name ?? t.jtitle,
|
|
4276
|
-
date: t.date ?? (e ?
|
|
4277
|
-
doi:
|
|
4283
|
+
date: t.date ?? (e ? ed(e) : void 0),
|
|
4284
|
+
doi: Ku(t.dois),
|
|
4278
4285
|
edition: e?.mainEntity.edition ?? t.edition,
|
|
4279
|
-
eissn:
|
|
4286
|
+
eissn: Ku(r),
|
|
4280
4287
|
epage: s,
|
|
4281
4288
|
isbn: i?.join(","),
|
|
4282
|
-
issn:
|
|
4289
|
+
issn: Ku(a),
|
|
4283
4290
|
issue: e?.mainEntity.issueNumber,
|
|
4284
4291
|
jtitle: t.jtitle,
|
|
4285
|
-
lcn: t.lcn ?? e?.identifier.value,
|
|
4286
|
-
publisher: t.publisher ??
|
|
4292
|
+
lcn: id(t.lcn ?? e?.identifier.value),
|
|
4293
|
+
publisher: t.publisher ?? qu(e?.mainEntity.publisher),
|
|
4287
4294
|
spage: o,
|
|
4288
4295
|
title: e?.name ?? t.title,
|
|
4289
4296
|
volume: e?.mainEntity.volumeNumber
|
|
4290
4297
|
};
|
|
4291
|
-
},
|
|
4298
|
+
}, od = j({
|
|
4292
4299
|
"@type": N("Organization"),
|
|
4293
4300
|
name: M([O(), A(O())])
|
|
4294
|
-
}),
|
|
4301
|
+
}), sd = j({
|
|
4295
4302
|
"@type": N("Person"),
|
|
4296
4303
|
name: M([O(), A(O())])
|
|
4297
|
-
}),
|
|
4304
|
+
}), cd = j({
|
|
4298
4305
|
"@type": M([O(), A(O())]),
|
|
4299
4306
|
"@id": O().optional(),
|
|
4300
4307
|
issn: O().optional(),
|
|
4301
4308
|
name: O().optional(),
|
|
4302
4309
|
volume: O().optional()
|
|
4303
|
-
}),
|
|
4310
|
+
}), ld = W.extend({
|
|
4304
4311
|
identifier: j({
|
|
4305
4312
|
"@type": O(),
|
|
4306
4313
|
propertyID: O(),
|
|
@@ -4312,8 +4319,8 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4312
4319
|
bookFormat: P(O()),
|
|
4313
4320
|
creator: P(M([
|
|
4314
4321
|
O(),
|
|
4315
|
-
|
|
4316
|
-
A(
|
|
4322
|
+
sd,
|
|
4323
|
+
A(sd)
|
|
4317
4324
|
])),
|
|
4318
4325
|
datePublished: P(O()),
|
|
4319
4326
|
description: P(M([O(), A(O())])),
|
|
@@ -4321,24 +4328,24 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4321
4328
|
inLanguage: P(O()),
|
|
4322
4329
|
isbn: P(O()),
|
|
4323
4330
|
issn: P(M([O(), A(O())])),
|
|
4324
|
-
isPartOf: P(
|
|
4331
|
+
isPartOf: P(cd),
|
|
4325
4332
|
issueNumber: P(O()),
|
|
4326
4333
|
pagination: P(O()),
|
|
4327
4334
|
publisher: P(M([
|
|
4328
4335
|
O(),
|
|
4329
|
-
|
|
4330
|
-
A(
|
|
4336
|
+
od,
|
|
4337
|
+
A(od)
|
|
4331
4338
|
])),
|
|
4332
4339
|
volumeNumber: P(O())
|
|
4333
4340
|
}),
|
|
4334
4341
|
name: O()
|
|
4335
|
-
}),
|
|
4336
|
-
let t =
|
|
4342
|
+
}), ud = (e) => {
|
|
4343
|
+
let t = $s(e);
|
|
4337
4344
|
if (!t) return null;
|
|
4338
|
-
let n =
|
|
4345
|
+
let n = ec(t), r = ld.safeParse(n);
|
|
4339
4346
|
return r.success ? r.data : null;
|
|
4340
|
-
},
|
|
4341
|
-
...
|
|
4347
|
+
}, dd = (e) => L(F.Article, {
|
|
4348
|
+
...Xu(e),
|
|
4342
4349
|
au: e.authors,
|
|
4343
4350
|
doi: e.doi,
|
|
4344
4351
|
eissn: e.eissn,
|
|
@@ -4349,8 +4356,8 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4349
4356
|
pub: e.publisher,
|
|
4350
4357
|
spage: e.spage,
|
|
4351
4358
|
volume: e.volume
|
|
4352
|
-
}),
|
|
4353
|
-
...
|
|
4359
|
+
}), fd = (e) => I(F.Book, {
|
|
4360
|
+
...Xu(e),
|
|
4354
4361
|
au: e.authors,
|
|
4355
4362
|
date: e.date,
|
|
4356
4363
|
doi: e.doi,
|
|
@@ -4359,7 +4366,7 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4359
4366
|
isbn: e.isbn,
|
|
4360
4367
|
pub: e.publisher,
|
|
4361
4368
|
spage: e.spage
|
|
4362
|
-
}),
|
|
4369
|
+
}), pd = (e) => I(F.Bookitem, {
|
|
4363
4370
|
bibid: e.lcn,
|
|
4364
4371
|
atitle: e.title,
|
|
4365
4372
|
btitle: e.btitle,
|
|
@@ -4370,69 +4377,69 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4370
4377
|
isbn: e.isbn,
|
|
4371
4378
|
pub: e.publisher,
|
|
4372
4379
|
spage: e.spage
|
|
4373
|
-
}),
|
|
4374
|
-
...
|
|
4380
|
+
}), md = (e) => I(F.Conference, {
|
|
4381
|
+
...Xu(e),
|
|
4375
4382
|
au: e.authors,
|
|
4376
4383
|
date: e.date,
|
|
4377
4384
|
doi: e.doi,
|
|
4378
4385
|
isbn: e.isbn,
|
|
4379
4386
|
pub: e.publisher
|
|
4380
|
-
}),
|
|
4381
|
-
...
|
|
4387
|
+
}), hd = (e) => go({
|
|
4388
|
+
...Xu(e),
|
|
4382
4389
|
au: e.authors,
|
|
4383
4390
|
date: e.date,
|
|
4384
4391
|
pub: e.publisher
|
|
4385
|
-
}),
|
|
4386
|
-
...
|
|
4392
|
+
}), gd = (e) => L(F.Journal, {
|
|
4393
|
+
...Xu(e),
|
|
4387
4394
|
date: e.date,
|
|
4388
4395
|
doi: e.doi,
|
|
4389
4396
|
eissn: e.eissn,
|
|
4390
4397
|
issn: e.issn,
|
|
4391
4398
|
pub: e.publisher
|
|
4392
|
-
}),
|
|
4393
|
-
...
|
|
4399
|
+
}), _d = (e) => R({
|
|
4400
|
+
...Xu(e),
|
|
4394
4401
|
au: e.authors,
|
|
4395
4402
|
date: e.date,
|
|
4396
4403
|
pub: e.publisher
|
|
4397
|
-
}),
|
|
4398
|
-
...
|
|
4404
|
+
}), vd = (e) => R({
|
|
4405
|
+
...Xu(e),
|
|
4399
4406
|
au: e.authors,
|
|
4400
4407
|
date: e.date,
|
|
4401
4408
|
pub: e.publisher
|
|
4402
4409
|
}), q = /* @__PURE__ */ function(e) {
|
|
4403
4410
|
return e.Article = "Article", e.Audio = "Audio", e.Book = "Book", e.BookChapter = "BookChapter", e.Conference = "Conference", e.Dissertation = "Dissertation", e.Journal = "Journal", e.Video = "Video", e;
|
|
4404
|
-
}({}),
|
|
4405
|
-
let r =
|
|
4411
|
+
}({}), yd = (e, t) => ({ document: n }) => {
|
|
4412
|
+
let r = ud(n), i = ad(r, e(n));
|
|
4406
4413
|
switch (t(n, r)) {
|
|
4407
|
-
case q.Article: return B(
|
|
4408
|
-
case q.Book: return B(
|
|
4409
|
-
case q.BookChapter: return B(
|
|
4410
|
-
case q.Conference: return B(
|
|
4411
|
-
case q.Dissertation: return B(
|
|
4412
|
-
case q.Journal: return B(
|
|
4413
|
-
case q.Audio: return B(
|
|
4414
|
-
case q.Video: return B(
|
|
4414
|
+
case q.Article: return B(dd(i));
|
|
4415
|
+
case q.Book: return B(fd(i));
|
|
4416
|
+
case q.BookChapter: return B(pd(i));
|
|
4417
|
+
case q.Conference: return B(md(i));
|
|
4418
|
+
case q.Dissertation: return B(hd(i));
|
|
4419
|
+
case q.Journal: return B(gd(i));
|
|
4420
|
+
case q.Audio: return B(vd(i));
|
|
4421
|
+
case q.Video: return B(_d(i));
|
|
4415
4422
|
default: return z();
|
|
4416
4423
|
}
|
|
4417
|
-
},
|
|
4424
|
+
}, bd = (e) => `*:has([data-details-label="${e}"]) + .item-details-element-container prm-highlight`, xd = (e, t) => {
|
|
4418
4425
|
for (let n of t) {
|
|
4419
4426
|
let t = e.querySelector(n)?.textContent.trim();
|
|
4420
4427
|
if (t) return t;
|
|
4421
4428
|
}
|
|
4422
|
-
},
|
|
4423
|
-
|
|
4424
|
-
|
|
4425
|
-
|
|
4426
|
-
]),
|
|
4427
|
-
authors:
|
|
4428
|
-
title:
|
|
4429
|
-
publisher:
|
|
4430
|
-
creationDate:
|
|
4431
|
-
edition:
|
|
4432
|
-
isPartOf:
|
|
4433
|
-
identifierValues:
|
|
4434
|
-
lcn:
|
|
4435
|
-
}),
|
|
4429
|
+
}, Sd = (e) => `*:has([title*="${e}" i]) + .item-details-element-container prm-highlight`, Cd = (e) => Array.from(e.querySelectorAll(bd("identifier"))).map((e) => e.textContent).filter((e) => !!e), wd = (e) => Array.from(e.querySelectorAll(bd("creator"))).filter((e) => !!e.textContent && e.parentElement !== null && e.parentElement.getAttribute("aria-hidden") !== "true").map((e) => e.textContent.trim()), Td = (e, t) => e.querySelector(bd(t))?.textContent.trim(), Ed = (e) => Td(e, "mms") ?? xd(e, [
|
|
4430
|
+
Sd("MMS ID"),
|
|
4431
|
+
Sd("ID MMS"),
|
|
4432
|
+
Sd("Record ID")
|
|
4433
|
+
]), Dd = (e) => Yu({
|
|
4434
|
+
authors: wd(e),
|
|
4435
|
+
title: Td(e, "title"),
|
|
4436
|
+
publisher: Td(e, "publisher"),
|
|
4437
|
+
creationDate: Td(e, "creationdate"),
|
|
4438
|
+
edition: Td(e, "edition"),
|
|
4439
|
+
isPartOf: Td(e, "ispartof"),
|
|
4440
|
+
identifierValues: Cd(e),
|
|
4441
|
+
lcn: Ed(e)
|
|
4442
|
+
}), Od = {
|
|
4436
4443
|
Article: q.Article,
|
|
4437
4444
|
Book: q.Book,
|
|
4438
4445
|
"Book Chapter": q.BookChapter,
|
|
@@ -4443,14 +4450,14 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4443
4450
|
CreativeWork: q.Audio,
|
|
4444
4451
|
Movie: q.Video,
|
|
4445
4452
|
Video: q.Video
|
|
4446
|
-
},
|
|
4453
|
+
}, kd = yd(Dd, (e, t) => {
|
|
4447
4454
|
let n = t?.mainEntity["@type"] ?? e.querySelector(".media-content-type")?.textContent ?? void 0;
|
|
4448
|
-
return n ?
|
|
4449
|
-
}),
|
|
4455
|
+
return n ? Od[n] : void 0;
|
|
4456
|
+
}), Ad = (e) => {
|
|
4450
4457
|
let t = e.querySelectorAll("[id=\"Info\"] > p"), n = Array.from(t).find((e) => e.textContent.includes("Document Type"))?.textContent, r = V(e, "name", "DC.identifier");
|
|
4451
4458
|
if (r?.startsWith("info:doi/") || n?.includes("Article")) return U.Article;
|
|
4452
4459
|
if (r?.startsWith("urn:issn:")) return U.Journal;
|
|
4453
|
-
},
|
|
4460
|
+
}, jd = (e) => {
|
|
4454
4461
|
let [t, n, r, i] = V(e, "name", "DCTERMS.bibliographicCitation")?.split(",") ?? [];
|
|
4455
4462
|
return {
|
|
4456
4463
|
journalTitle: t,
|
|
@@ -4458,22 +4465,22 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4458
4465
|
issue: r,
|
|
4459
4466
|
pages: i
|
|
4460
4467
|
};
|
|
4461
|
-
},
|
|
4468
|
+
}, Md = (e) => {
|
|
4462
4469
|
let t = V(e, "name", "DC.identifier");
|
|
4463
4470
|
return (t ? t.split("info:doi/") : null)?.[1] ?? void 0;
|
|
4464
|
-
},
|
|
4471
|
+
}, Nd = (e) => e.evaluate("//*[@id=\"altLayoutPublisherLogo\"]/p/a[1]", e, null, XPathResult.STRING_TYPE, null).stringValue, Pd = (e) => {
|
|
4465
4472
|
let [t, n] = e ? e.trim().split("-") : [void 0, void 0];
|
|
4466
4473
|
return {
|
|
4467
4474
|
spage: t,
|
|
4468
4475
|
epage: n?.replace(/\(\d+\)/, "").trim()
|
|
4469
4476
|
};
|
|
4470
|
-
},
|
|
4477
|
+
}, Fd = (e) => {
|
|
4471
4478
|
let t = V(e, "name", "DCTERMS.issued");
|
|
4472
4479
|
if (!t) return;
|
|
4473
4480
|
let n = /\d{4}/.exec(t);
|
|
4474
4481
|
return n ? n[0] : void 0;
|
|
4475
|
-
},
|
|
4476
|
-
let t = V(e, "name", "DC.title"), n = V(e, "name", "DC.publisher"), r =
|
|
4482
|
+
}, Id = (e) => {
|
|
4483
|
+
let t = V(e, "name", "DC.title"), n = V(e, "name", "DC.publisher"), r = Fd(e), i = jd(e), a = i.journalTitle?.trim(), o = i.volume?.trim(), s = i.issue?.trim(), c = i.pages ? Pd(i.pages) : void 0, l = c?.spage, u = c?.epage, d = H(e, "name", "DC.creator"), f = Md(e);
|
|
4477
4484
|
return L(F.Article, {
|
|
4478
4485
|
au: d,
|
|
4479
4486
|
jtitle: a,
|
|
@@ -4486,72 +4493,72 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4486
4493
|
atitle: t,
|
|
4487
4494
|
volume: o
|
|
4488
4495
|
});
|
|
4489
|
-
},
|
|
4490
|
-
let t = V(e, "name", "DC.title"), n = V(e, "name", "DC.publisher"), r =
|
|
4496
|
+
}, Ld = (e) => {
|
|
4497
|
+
let t = V(e, "name", "DC.title"), n = V(e, "name", "DC.publisher"), r = Nd(e);
|
|
4491
4498
|
return L(F.Journal, {
|
|
4492
4499
|
issn: r,
|
|
4493
4500
|
title: t,
|
|
4494
4501
|
pub: n
|
|
4495
4502
|
});
|
|
4496
|
-
},
|
|
4497
|
-
switch (
|
|
4498
|
-
case U.Article: return B(
|
|
4499
|
-
case U.Journal: return B(
|
|
4503
|
+
}, Rd = ({ document: e }) => {
|
|
4504
|
+
switch (Ad(e)) {
|
|
4505
|
+
case U.Article: return B(Id(e));
|
|
4506
|
+
case U.Journal: return B(Ld(e));
|
|
4500
4507
|
default: return z();
|
|
4501
4508
|
}
|
|
4502
|
-
},
|
|
4503
|
-
let t = e.filter(
|
|
4509
|
+
}, zd = /^\d{4}-\d{3}[\dX]$/i, Bd = (e) => zd.test(e), Vd = (e) => {
|
|
4510
|
+
let t = e.filter(Bd);
|
|
4504
4511
|
return t.length ? t : void 0;
|
|
4505
|
-
},
|
|
4512
|
+
}, Hd = (e) => {
|
|
4506
4513
|
let t = H(e, "name", "citation_author");
|
|
4507
4514
|
return t.length ? t : void 0;
|
|
4508
|
-
},
|
|
4515
|
+
}, Ud = (e) => V(e, "name", "citation_publication_date")?.match(/^\d{4}/)?.[0], Wd = (e) => V(e, "name", "citation_doi"), Gd = (e) => {
|
|
4509
4516
|
let t = H(e, "name", "citation_isbn");
|
|
4510
4517
|
return t.length ? t.join(",") : void 0;
|
|
4511
|
-
},
|
|
4512
|
-
atitle:
|
|
4513
|
-
au:
|
|
4514
|
-
date:
|
|
4515
|
-
doi:
|
|
4516
|
-
issn:
|
|
4517
|
-
issue:
|
|
4518
|
-
jtitle:
|
|
4519
|
-
pub:
|
|
4520
|
-
volume:
|
|
4521
|
-
spage:
|
|
4522
|
-
epage:
|
|
4523
|
-
}),
|
|
4524
|
-
atitle:
|
|
4525
|
-
au:
|
|
4526
|
-
btitle:
|
|
4527
|
-
date:
|
|
4528
|
-
isbn:
|
|
4529
|
-
pub:
|
|
4530
|
-
spage:
|
|
4531
|
-
epage:
|
|
4532
|
-
}),
|
|
4533
|
-
title:
|
|
4534
|
-
au:
|
|
4535
|
-
date:
|
|
4536
|
-
pub:
|
|
4537
|
-
spage:
|
|
4538
|
-
epage:
|
|
4539
|
-
}),
|
|
4518
|
+
}, Kd = (e) => Vd(H(e, "name", "citation_issn")), qd = (e) => V(e, "name", "citation_journal_title"), Jd = (e) => V(e, "name", "citation_publisher"), Yd = (e) => V(e, "name", "citation_title"), Xd = (e) => V(e, "name", "citation_doi"), Zd = (e) => V(e, "name", "citation_firstpage"), Qd = (e) => V(e, "name", "citation_lastpage"), $d = (e) => V(e, "name", "citation_issue"), ef = (e) => V(e, "name", "citation_volume"), tf = (e) => L(F.Article, {
|
|
4519
|
+
atitle: Yd(e),
|
|
4520
|
+
au: Hd(e),
|
|
4521
|
+
date: Ud(e),
|
|
4522
|
+
doi: Wd(e),
|
|
4523
|
+
issn: Kd(e)?.[0],
|
|
4524
|
+
issue: $d(e),
|
|
4525
|
+
jtitle: qd(e),
|
|
4526
|
+
pub: Jd(e),
|
|
4527
|
+
volume: ef(e),
|
|
4528
|
+
spage: Zd(e),
|
|
4529
|
+
epage: Qd(e)
|
|
4530
|
+
}), nf = (e) => I(F.Bookitem, {
|
|
4531
|
+
atitle: Yd(e),
|
|
4532
|
+
au: Hd(e),
|
|
4533
|
+
btitle: qd(e),
|
|
4534
|
+
date: Ud(e),
|
|
4535
|
+
isbn: Gd(e),
|
|
4536
|
+
pub: Jd(e),
|
|
4537
|
+
spage: Zd(e),
|
|
4538
|
+
epage: Qd(e)
|
|
4539
|
+
}), rf = (e) => go({
|
|
4540
|
+
title: Yd(e),
|
|
4541
|
+
au: Hd(e),
|
|
4542
|
+
date: Ud(e),
|
|
4543
|
+
pub: Jd(e),
|
|
4544
|
+
spage: Zd(e),
|
|
4545
|
+
epage: Qd(e)
|
|
4546
|
+
}), af = (e) => !!e.isbn, of = (e) => !!e.issn || e.type === "Article" && !!e.journalTitle || !af(e) && !!e.journalTitle, sf = (e) => !!e.title, cf = (e) => {
|
|
4540
4547
|
let t = {
|
|
4541
|
-
type:
|
|
4542
|
-
isbn:
|
|
4543
|
-
issn:
|
|
4544
|
-
journalTitle:
|
|
4545
|
-
title:
|
|
4548
|
+
type: Xd(e),
|
|
4549
|
+
isbn: Gd(e),
|
|
4550
|
+
issn: Kd(e),
|
|
4551
|
+
journalTitle: qd(e),
|
|
4552
|
+
title: Yd(e)
|
|
4546
4553
|
};
|
|
4547
|
-
return
|
|
4548
|
-
},
|
|
4549
|
-
let n =
|
|
4554
|
+
return af(t) ? nf(e) : of(t) ? tf(e) : sf(t) ? rf(e) : null;
|
|
4555
|
+
}, lf = ({ url: e, document: t }) => {
|
|
4556
|
+
let n = cf(t);
|
|
4550
4557
|
return n ? B({
|
|
4551
4558
|
...n,
|
|
4552
4559
|
uri: e
|
|
4553
4560
|
}) : z();
|
|
4554
|
-
},
|
|
4561
|
+
}, uf = j({
|
|
4555
4562
|
"@content": O(),
|
|
4556
4563
|
datePublished: O().optional(),
|
|
4557
4564
|
mainEntity: j({
|
|
@@ -4564,20 +4571,20 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4564
4571
|
}).optional(),
|
|
4565
4572
|
isbn: O().optional()
|
|
4566
4573
|
})
|
|
4567
|
-
}),
|
|
4574
|
+
}), df = (e) => uf.safeParse(e).success, ff = (e) => {
|
|
4568
4575
|
let t = e.textContent;
|
|
4569
4576
|
if (!t) return null;
|
|
4570
4577
|
try {
|
|
4571
4578
|
let e = JSON.parse(t);
|
|
4572
|
-
if (
|
|
4579
|
+
if (df(e)) return e;
|
|
4573
4580
|
} catch {
|
|
4574
4581
|
return null;
|
|
4575
4582
|
}
|
|
4576
4583
|
return null;
|
|
4577
|
-
},
|
|
4578
|
-
let t =
|
|
4584
|
+
}, pf = ({ document: e }) => {
|
|
4585
|
+
let t = $s(e);
|
|
4579
4586
|
if (!t) return z();
|
|
4580
|
-
let n =
|
|
4587
|
+
let n = ff(t);
|
|
4581
4588
|
if (!n) return z();
|
|
4582
4589
|
let r = n.mainEntity.type, i = n.mainEntity.author?.map((e) => e.name), a = n.datePublished?.substring(0, 4), o = n.mainEntity.name, s = n.mainEntity.isbn, c = n.mainEntity.publisher?.name;
|
|
4583
4590
|
switch (r) {
|
|
@@ -4590,18 +4597,18 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4590
4597
|
}));
|
|
4591
4598
|
default: return z();
|
|
4592
4599
|
}
|
|
4593
|
-
},
|
|
4600
|
+
}, mf = W.extend({
|
|
4594
4601
|
"@type": O().optional(),
|
|
4595
4602
|
name: O().optional(),
|
|
4596
4603
|
copyrightYear: ha().optional(),
|
|
4597
4604
|
author: A(j({ name: O() })).optional(),
|
|
4598
4605
|
publisher: A(j({ name: O() })).optional()
|
|
4599
|
-
}),
|
|
4600
|
-
let n =
|
|
4606
|
+
}), hf = (e) => mf.safeParse(e).success, gf = ({ document: e, url: t }) => {
|
|
4607
|
+
let n = $s(e);
|
|
4601
4608
|
if (!n) return z();
|
|
4602
|
-
let r =
|
|
4603
|
-
if (!r || !
|
|
4604
|
-
let i = r["@type"], a = r.author?.map((e) => e.name), o = r.copyrightYear?.toString() ?? V(e, "property", "og:book:release_date"), s = r.name, c =
|
|
4609
|
+
let r = ec(n);
|
|
4610
|
+
if (!r || !hf(r)) return z();
|
|
4611
|
+
let i = r["@type"], a = r.author?.map((e) => e.name), o = r.copyrightYear?.toString() ?? V(e, "property", "og:book:release_date"), s = r.name, c = au(r.publisher?.map((e) => e.name)), l = V(e, "property", "og:book:isbn");
|
|
4605
4612
|
switch (i) {
|
|
4606
4613
|
case "Book": return B(I(F.Book, {
|
|
4607
4614
|
au: a,
|
|
@@ -4613,14 +4620,14 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4613
4620
|
}));
|
|
4614
4621
|
default: return z();
|
|
4615
4622
|
}
|
|
4616
|
-
},
|
|
4623
|
+
}, _f = (e) => {
|
|
4617
4624
|
let t = Array.from(e.querySelectorAll("a[rel=author]")).map((e) => e.textContent.trim()).filter(Boolean);
|
|
4618
4625
|
return t.length ? t : void 0;
|
|
4619
|
-
},
|
|
4626
|
+
}, vf = (e) => {
|
|
4620
4627
|
let t = Array.from(e.querySelectorAll("strong")).filter((e) => e.textContent.startsWith("ISBN")).map((e) => e.nextElementSibling?.textContent.trim());
|
|
4621
4628
|
if (t.length !== 0) return t[0]?.replace(/\s+/, ",");
|
|
4622
|
-
},
|
|
4623
|
-
let n = t.querySelector("h3.page-title")?.textContent.trim() ?? void 0, r =
|
|
4629
|
+
}, yf = ({ url: e, document: t }) => {
|
|
4630
|
+
let n = t.querySelector("h3.page-title")?.textContent.trim() ?? void 0, r = _f(t), i = V(t, "property", "article:published_time"), a = vf(t);
|
|
4624
4631
|
return B(I(F.Book, {
|
|
4625
4632
|
au: r,
|
|
4626
4633
|
date: i?.substring(0, 4),
|
|
@@ -4629,21 +4636,21 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4629
4636
|
title: n,
|
|
4630
4637
|
uri: e
|
|
4631
4638
|
}));
|
|
4632
|
-
},
|
|
4633
|
-
switch (
|
|
4634
|
-
case U.Chapter: return B(
|
|
4635
|
-
case U.Book: return B(
|
|
4636
|
-
case U.Article: return B(
|
|
4637
|
-
case U.Journal: return B(
|
|
4639
|
+
}, bf = ({ document: e, url: t }) => {
|
|
4640
|
+
switch (Sf(t)) {
|
|
4641
|
+
case U.Chapter: return B(Df(e));
|
|
4642
|
+
case U.Book: return B(Of(e));
|
|
4643
|
+
case U.Article: return B(Cf(e));
|
|
4644
|
+
case U.Journal: return B(wf(e));
|
|
4638
4645
|
default: return z();
|
|
4639
4646
|
}
|
|
4640
|
-
},
|
|
4647
|
+
}, xf = /* @__PURE__ */ function(e) {
|
|
4641
4648
|
return e.Print = "Print", e.Online = "Online", e;
|
|
4642
|
-
}(
|
|
4649
|
+
}(xf || {}), Sf = (e) => {
|
|
4643
4650
|
let { pathname: t } = new URL(e);
|
|
4644
4651
|
return t.includes("/books/abs/") ? U.Chapter : t.includes("/books/") ? U.Book : /\/journals\/.+\/article\//.exec(t) == null ? t.includes("/journals/") ? U.Journal : U.None : U.Article;
|
|
4645
|
-
},
|
|
4646
|
-
let t = V(e, "name", "citation_title"), n = V(e, "name", "citation_journal_title"), r = V(e, "name", "citation_doi"), i = V(e, "name", "citation_volume"), a = V(e, "name", "citation_issue"), o = V(e, "name", "citation_firstpage"), s = V(e, "name", "citation_lastpage"), c = V(e, "name", "citation_publication_date")?.substring(0, 4), l = V(e, "name", "citation_publisher"), u =
|
|
4652
|
+
}, Cf = (e) => {
|
|
4653
|
+
let t = V(e, "name", "citation_title"), n = V(e, "name", "citation_journal_title"), r = V(e, "name", "citation_doi"), i = V(e, "name", "citation_volume"), a = V(e, "name", "citation_issue"), o = V(e, "name", "citation_firstpage"), s = V(e, "name", "citation_lastpage"), c = V(e, "name", "citation_publication_date")?.substring(0, 4), l = V(e, "name", "citation_publisher"), u = kf(e), d = Vd(H(e, "name", "citation_issn"));
|
|
4647
4654
|
return L(F.Article, {
|
|
4648
4655
|
atitle: t,
|
|
4649
4656
|
au: u,
|
|
@@ -4657,14 +4664,14 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4657
4664
|
date: c,
|
|
4658
4665
|
pub: l
|
|
4659
4666
|
});
|
|
4660
|
-
},
|
|
4661
|
-
let t =
|
|
4667
|
+
}, wf = (e) => {
|
|
4668
|
+
let t = Tf(e), n = Ef(e), r = n.find((e) => e.type === xf.Print), i = n.find((e) => e.type === xf.Online), a = r ? r.value : void 0, o = i ? i.value : void 0;
|
|
4662
4669
|
return L(F.Journal, {
|
|
4663
4670
|
title: t,
|
|
4664
4671
|
issn: a,
|
|
4665
4672
|
eissn: o
|
|
4666
4673
|
});
|
|
4667
|
-
},
|
|
4674
|
+
}, Tf = (e) => e.querySelector("h1.title")?.textContent.trim() ?? void 0, Ef = (e) => {
|
|
4668
4675
|
let t = Array.from(e.querySelectorAll("span.bold")).find((e) => e.textContent.trim() === "ISSN:"), n = /^([0-9]{4}-[0-9]{3}[0-9X]) \((Print|Online)\)/, r = [];
|
|
4669
4676
|
return t && (t.parentElement?.querySelectorAll("span.value"))?.forEach((e) => {
|
|
4670
4677
|
let t = e.textContent.trim(), i = n.exec(t);
|
|
@@ -4673,7 +4680,7 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4673
4680
|
type: i[2]
|
|
4674
4681
|
});
|
|
4675
4682
|
}), r;
|
|
4676
|
-
},
|
|
4683
|
+
}, Df = (e) => {
|
|
4677
4684
|
let t = V(e, "name", "citation_title"), n = V(e, "name", "citation_inbook_title"), r = V(e, "name", "citation_doi"), i = V(e, "name", "citation_publication_date")?.substring(0, 4), a = V(e, "name", "citation_publisher");
|
|
4678
4685
|
return I(F.Bookitem, {
|
|
4679
4686
|
atitle: t,
|
|
@@ -4682,8 +4689,8 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4682
4689
|
date: i,
|
|
4683
4690
|
pub: a
|
|
4684
4691
|
});
|
|
4685
|
-
},
|
|
4686
|
-
let t = V(e, "name", "citation_title"), n = V(e, "name", "citation_doi"), r = V(e, "name", "citation_isbn"), i = V(e, "name", "citation_publication_date")?.substring(0, 4), a = V(e, "name", "citation_publisher"), o =
|
|
4692
|
+
}, Of = (e) => {
|
|
4693
|
+
let t = V(e, "name", "citation_title"), n = V(e, "name", "citation_doi"), r = V(e, "name", "citation_isbn"), i = V(e, "name", "citation_publication_date")?.substring(0, 4), a = V(e, "name", "citation_publisher"), o = kf(e);
|
|
4687
4694
|
return I(F.Book, {
|
|
4688
4695
|
title: t,
|
|
4689
4696
|
au: o,
|
|
@@ -4692,19 +4699,19 @@ var ou = (e, t) => iu(e, [t])?.trim(), su = (e) => {
|
|
|
4692
4699
|
date: i,
|
|
4693
4700
|
pub: a
|
|
4694
4701
|
});
|
|
4695
|
-
},
|
|
4702
|
+
}, kf = (e) => {
|
|
4696
4703
|
let t = H(e, "name", "citation_author");
|
|
4697
4704
|
return t.length ? t : void 0;
|
|
4698
|
-
},
|
|
4705
|
+
}, Af = /* @__PURE__ */ function(e) {
|
|
4699
4706
|
return e.Journal = "Journal", e.Article = "Article", e;
|
|
4700
|
-
}(
|
|
4707
|
+
}(Af || {}), jf = (e) => {
|
|
4701
4708
|
switch (V(e, "property", "og:type")) {
|
|
4702
|
-
case "Article": return
|
|
4703
|
-
case "Journal": return
|
|
4709
|
+
case "Article": return Af.Article;
|
|
4710
|
+
case "Journal": return Af.Journal;
|
|
4704
4711
|
default: return;
|
|
4705
4712
|
}
|
|
4706
4713
|
};
|
|
4707
|
-
function
|
|
4714
|
+
function Mf(e) {
|
|
4708
4715
|
let t = V(e, "property", "og:title"), n = V(e, "name", "dc.Publisher"), r = V(e, "name", "publication_doi");
|
|
4709
4716
|
return B(L(F.Journal, {
|
|
4710
4717
|
jtitle: t,
|
|
@@ -4712,7 +4719,7 @@ function Of(e) {
|
|
|
4712
4719
|
doi: r
|
|
4713
4720
|
}));
|
|
4714
4721
|
}
|
|
4715
|
-
function
|
|
4722
|
+
function Nf(e) {
|
|
4716
4723
|
let t = V(e, "name", "dc.Title"), n = H(e, "name", "dc.Creator"), r = V(e, "name", "dc.Date")?.substring(0, 4), i = V(e, "name", "publication_doi"), a = V(e, "name", "citation_journal_title"), o = V(e, "name", "dc.Publisher");
|
|
4717
4724
|
return B(L(F.Article, {
|
|
4718
4725
|
atitle: t,
|
|
@@ -4723,24 +4730,24 @@ function kf(e) {
|
|
|
4723
4730
|
pub: o
|
|
4724
4731
|
}));
|
|
4725
4732
|
}
|
|
4726
|
-
var
|
|
4727
|
-
switch (
|
|
4728
|
-
case
|
|
4729
|
-
case
|
|
4733
|
+
var Pf = ({ document: e }) => {
|
|
4734
|
+
switch (jf(e)) {
|
|
4735
|
+
case Af.Journal: return Mf(e);
|
|
4736
|
+
case Af.Article: return Nf(e);
|
|
4730
4737
|
default: return z();
|
|
4731
4738
|
}
|
|
4732
|
-
},
|
|
4739
|
+
}, Ff = (e) => {
|
|
4733
4740
|
if (!e) return;
|
|
4734
4741
|
let [t, n] = e.trim().split("-");
|
|
4735
4742
|
return {
|
|
4736
4743
|
spage: t,
|
|
4737
4744
|
epage: n
|
|
4738
4745
|
};
|
|
4739
|
-
},
|
|
4746
|
+
}, If = (e) => {
|
|
4740
4747
|
let { pathname: t } = new URL(e);
|
|
4741
4748
|
if (t.includes("/article/")) return U.Article;
|
|
4742
|
-
},
|
|
4743
|
-
let t = V(e, "name", "DC.Source"), n = V(e, "name", "DC.Title"), r = H(e, "name", "DC.Creator.PersonalName"), i = V(e, "name", "DC.Source.ISSN"), a = V(e, "name", "citation_date")?.substring(0, 4), o = V(e, "name", "DC.Source.Volume"), s = V(e, "name", "DC.Source.Issue"), c = V(e, "name", "DC.Identifier.URI"), l = V(e, "name", "DC.Identifier.pageNumber"), u = l ?
|
|
4749
|
+
}, Lf = (e) => {
|
|
4750
|
+
let t = V(e, "name", "DC.Source"), n = V(e, "name", "DC.Title"), r = H(e, "name", "DC.Creator.PersonalName"), i = V(e, "name", "DC.Source.ISSN"), a = V(e, "name", "citation_date")?.substring(0, 4), o = V(e, "name", "DC.Source.Volume"), s = V(e, "name", "DC.Source.Issue"), c = V(e, "name", "DC.Identifier.URI"), l = V(e, "name", "DC.Identifier.pageNumber"), u = l ? Ff(l) : void 0, d = u?.spage, f = u?.epage;
|
|
4744
4751
|
return L(F.Article, {
|
|
4745
4752
|
jtitle: t,
|
|
4746
4753
|
atitle: n,
|
|
@@ -4753,22 +4760,22 @@ var Af = ({ document: e }) => {
|
|
|
4753
4760
|
issue: s,
|
|
4754
4761
|
uri: c
|
|
4755
4762
|
});
|
|
4756
|
-
},
|
|
4757
|
-
switch (
|
|
4758
|
-
case U.Article: return B(
|
|
4763
|
+
}, Rf = ({ document: e, url: t }) => {
|
|
4764
|
+
switch (If(t)) {
|
|
4765
|
+
case U.Article: return B(Lf(e));
|
|
4759
4766
|
default: return z();
|
|
4760
4767
|
}
|
|
4761
|
-
},
|
|
4768
|
+
}, zf = /* @__PURE__ */ function(e) {
|
|
4762
4769
|
return e.Book = "Book", e.Chapter = "Chapter", e;
|
|
4763
|
-
}(
|
|
4764
|
-
switch (
|
|
4765
|
-
case "eBook": return
|
|
4766
|
-
case "Reference": return
|
|
4770
|
+
}(zf || {}), Bf = (e) => {
|
|
4771
|
+
switch (Vf(e)) {
|
|
4772
|
+
case "eBook": return zf.Book;
|
|
4773
|
+
case "Reference": return zf.Chapter;
|
|
4767
4774
|
default: return;
|
|
4768
4775
|
}
|
|
4769
|
-
},
|
|
4770
|
-
function
|
|
4771
|
-
let n =
|
|
4776
|
+
}, Vf = (e) => e.querySelector("#vol-contentType a")?.textContent ?? void 0;
|
|
4777
|
+
function Hf(e, t) {
|
|
4778
|
+
let n = Wf(e), r = qf(e), i = Yf(e), a = Xf(e), o = Zf(e), s = Qf(e), c = qf(e), l = t, { startPage: u, endPage: d } = $f(e) ?? {};
|
|
4772
4779
|
return B(I(F.Book, {
|
|
4773
4780
|
au: n,
|
|
4774
4781
|
btitle: r,
|
|
@@ -4782,8 +4789,8 @@ function Rf(e, t) {
|
|
|
4782
4789
|
uri: l
|
|
4783
4790
|
}));
|
|
4784
4791
|
}
|
|
4785
|
-
function
|
|
4786
|
-
let n =
|
|
4792
|
+
function Uf(e, t) {
|
|
4793
|
+
let n = Wf(e), r = Jf(e), i = qf(e), a = Yf(e), o = Xf(e), s = Zf(e), c = Qf(e), l = Jf(e), u = t, { startPage: d, endPage: f } = $f(e) ?? {};
|
|
4787
4794
|
return B(I(F.Book, {
|
|
4788
4795
|
au: n,
|
|
4789
4796
|
atitle: r,
|
|
@@ -4798,10 +4805,10 @@ function zf(e, t) {
|
|
|
4798
4805
|
uri: u
|
|
4799
4806
|
}));
|
|
4800
4807
|
}
|
|
4801
|
-
var
|
|
4808
|
+
var Wf = (e) => {
|
|
4802
4809
|
let t = e.querySelectorAll("div#article_author p.author-bio b"), n = Array.from(t).map((e) => e.textContent).filter((e) => !!e).map((e) => e.trim());
|
|
4803
4810
|
return n.length > 0 ? n : void 0;
|
|
4804
|
-
},
|
|
4811
|
+
}, Gf = (e, t) => e.querySelector(`input#${t}`)?.getAttribute("value") ?? void 0, Kf = (e) => V(e, "property", "og:title"), qf = (e) => Gf(e, "titlevalue") ?? Kf(e), Jf = (e) => Gf(e, "chapter-title-squid"), Yf = (e) => Gf(e, "pubdate-squid"), Xf = (e) => Gf(e, "doi-squid"), Zf = (e) => Gf(e, "isbn-squid"), Qf = (e) => Gf(e, "pubname-squid"), $f = (e) => {
|
|
4805
4812
|
let t = e.querySelector("#pageRange")?.textContent ?? void 0;
|
|
4806
4813
|
if (!t) return;
|
|
4807
4814
|
let n = /(\d+)–(\d+)/.exec(t);
|
|
@@ -4809,34 +4816,34 @@ var Bf = (e) => {
|
|
|
4809
4816
|
startPage: n[1],
|
|
4810
4817
|
endPage: n[2]
|
|
4811
4818
|
};
|
|
4812
|
-
},
|
|
4813
|
-
switch (
|
|
4814
|
-
case
|
|
4815
|
-
case
|
|
4819
|
+
}, ep = ({ document: e, url: t }) => {
|
|
4820
|
+
switch (Bf(e)) {
|
|
4821
|
+
case zf.Book: return Hf(e, t);
|
|
4822
|
+
case zf.Chapter: return Uf(e, t);
|
|
4816
4823
|
default: return z();
|
|
4817
4824
|
}
|
|
4818
|
-
},
|
|
4819
|
-
switch (
|
|
4825
|
+
}, tp = (e, t) => e.evaluate(`//*[@class="singleRecord_view_label"][contains(text(), "${t}")]/following-sibling::*[@class="singleRecord_view_data"]`, e, null, XPathResult.STRING_TYPE).stringValue.toLowerCase().trim(), np = (e) => {
|
|
4826
|
+
switch (tp(e, "Medium")) {
|
|
4820
4827
|
case "book":
|
|
4821
4828
|
case "e-book": return F.Book;
|
|
4822
4829
|
case "e-journal": return F.Journal;
|
|
4823
4830
|
default: return F.Unknown;
|
|
4824
4831
|
}
|
|
4825
|
-
},
|
|
4832
|
+
}, rp = (e) => {
|
|
4826
4833
|
delete e.rft_id;
|
|
4827
|
-
},
|
|
4834
|
+
}, ip = (e) => {
|
|
4828
4835
|
let t = ns(e);
|
|
4829
|
-
if (
|
|
4830
|
-
let n =
|
|
4831
|
-
t.resource.genre = n,
|
|
4836
|
+
if (Yc(t)) {
|
|
4837
|
+
let n = np(e.document);
|
|
4838
|
+
t.resource.genre = n, rp(t.resource);
|
|
4832
4839
|
}
|
|
4833
4840
|
return t;
|
|
4834
|
-
},
|
|
4841
|
+
}, ap = (e) => {
|
|
4835
4842
|
let t = V(e, "name", "type")?.toLowerCase(), n = V(e, "name", "og:type")?.toLowerCase(), r = V(e, "name", "citation_article_type")?.toLowerCase();
|
|
4836
4843
|
if (t === "article" || r === "article" || n === "article") return U.Article;
|
|
4837
4844
|
let i = V(e, "name", "twitter:title")?.trim(), a = V(e, "name", "description")?.trim();
|
|
4838
4845
|
if (i || a) return U.Webpage;
|
|
4839
|
-
},
|
|
4846
|
+
}, op = (e) => {
|
|
4840
4847
|
let t = V(e, "name", "DC.Title"), n = V(e, "name", "DC.Publisher"), r = V(e, "name", "DC.Date"), i = V(e, "name", "DC.Identifier"), a = V(e, "name", "citation_journal_title"), o = V(e, "name", "citation_volume"), s = V(e, "name", "citation_issn"), c = H(e, "name", "citation_author");
|
|
4841
4848
|
return L(F.Article, {
|
|
4842
4849
|
au: c,
|
|
@@ -4848,41 +4855,41 @@ var Bf = (e) => {
|
|
|
4848
4855
|
title: t,
|
|
4849
4856
|
volume: o
|
|
4850
4857
|
});
|
|
4851
|
-
},
|
|
4858
|
+
}, sp = (e, t) => _o({
|
|
4852
4859
|
uri: e,
|
|
4853
4860
|
title: V(t, "name", "twitter:title")
|
|
4854
|
-
}),
|
|
4855
|
-
switch (
|
|
4856
|
-
case U.Article: return B(
|
|
4857
|
-
case U.Webpage: return B(
|
|
4861
|
+
}), cp = ({ url: e, document: t }) => {
|
|
4862
|
+
switch (ap(t)) {
|
|
4863
|
+
case U.Article: return B(op(t));
|
|
4864
|
+
case U.Webpage: return B(sp(e, t));
|
|
4858
4865
|
}
|
|
4859
4866
|
return z();
|
|
4860
|
-
},
|
|
4861
|
-
function
|
|
4867
|
+
}, lp = ({ document: e }) => Array.from(e.querySelectorAll(".availability.documentSummaryAvailability.availabilityContent")).length === 0 ? z() : es(), up = /([0-9]{4})\s+at/;
|
|
4868
|
+
function dp(e) {
|
|
4862
4869
|
if (!e) return;
|
|
4863
|
-
let t =
|
|
4870
|
+
let t = up.exec(e);
|
|
4864
4871
|
if (t && t.length > 1) return t[1];
|
|
4865
4872
|
}
|
|
4866
|
-
function
|
|
4873
|
+
function fp(e, t) {
|
|
4867
4874
|
let n = e.getElementsByClassName(t);
|
|
4868
4875
|
if (n.length !== 0) return n[0].textContent;
|
|
4869
4876
|
}
|
|
4870
|
-
function
|
|
4877
|
+
function pp(e) {
|
|
4871
4878
|
return Array.from(e.getElementsByTagName("li")).reduce((e, t) => {
|
|
4872
|
-
let n =
|
|
4879
|
+
let n = fp(t, "title"), r = fp(t, "content");
|
|
4873
4880
|
return n && r && (e[n] = r), e;
|
|
4874
4881
|
}, {});
|
|
4875
4882
|
}
|
|
4876
|
-
function
|
|
4883
|
+
function mp(e) {
|
|
4877
4884
|
let t = e.getElementsByClassName("information");
|
|
4878
4885
|
if (t.length === 0) return {};
|
|
4879
|
-
let n =
|
|
4886
|
+
let n = pp(t[0]);
|
|
4880
4887
|
return {
|
|
4881
|
-
date:
|
|
4888
|
+
date: dp(n.Published),
|
|
4882
4889
|
series: n.Show
|
|
4883
4890
|
};
|
|
4884
4891
|
}
|
|
4885
|
-
var
|
|
4892
|
+
var hp = ({ url: e, document: t }) => {
|
|
4886
4893
|
if (!new URL(e).searchParams.has("i")) return z();
|
|
4887
4894
|
let n = F.AudioDocument;
|
|
4888
4895
|
return B({
|
|
@@ -4890,16 +4897,16 @@ var dp = ({ url: e, document: t }) => {
|
|
|
4890
4897
|
pub: V(t, "property", "og:site_name"),
|
|
4891
4898
|
title: V(t, "property", "og:title"),
|
|
4892
4899
|
uri: e,
|
|
4893
|
-
...
|
|
4900
|
+
...mp(t)
|
|
4894
4901
|
});
|
|
4895
|
-
},
|
|
4902
|
+
}, gp = (e) => {
|
|
4896
4903
|
let t = V(e, "name", "citation_date");
|
|
4897
4904
|
if (t) return t.split("/").find((e) => /^\d{4}/.test(e)) ?? void 0;
|
|
4898
|
-
},
|
|
4905
|
+
}, _p = (e) => {
|
|
4899
4906
|
let t = e.querySelector("#arxiv-doi-link")?.textContent;
|
|
4900
4907
|
if (t) return t.replace("https://doi.org/", "").trim();
|
|
4901
|
-
},
|
|
4902
|
-
let t = V(e, "name", "citation_title"), n = V(e, "name", "citation_pdf_url"), r = H(e, "name", "citation_author"), i =
|
|
4908
|
+
}, vp = ({ document: e }) => {
|
|
4909
|
+
let t = V(e, "name", "citation_title"), n = V(e, "name", "citation_pdf_url"), r = H(e, "name", "citation_author"), i = gp(e), a = _p(e);
|
|
4903
4910
|
return !t && r.length === 0 && !i && !a ? z() : B(L(F.Article, {
|
|
4904
4911
|
au: r,
|
|
4905
4912
|
date: i,
|
|
@@ -4907,12 +4914,12 @@ var dp = ({ url: e, document: t }) => {
|
|
|
4907
4914
|
title: t,
|
|
4908
4915
|
uri: n
|
|
4909
4916
|
}));
|
|
4910
|
-
},
|
|
4911
|
-
let t =
|
|
4917
|
+
}, yp = (e) => {
|
|
4918
|
+
let t = cu(e, "div.director-section div.term-info-section-items");
|
|
4912
4919
|
if (!t) return;
|
|
4913
4920
|
let n = t.split(",").map((e) => e.replace(/\s+/g, " ").trim()).filter((e) => e.length > 0);
|
|
4914
4921
|
return n.length > 0 ? n : void 0;
|
|
4915
|
-
},
|
|
4922
|
+
}, bp = (e) => {
|
|
4916
4923
|
let t = /* @__PURE__ */ new Map();
|
|
4917
4924
|
return Array.from(e.querySelectorAll(".info-section-container")).forEach((e) => {
|
|
4918
4925
|
let n = e.querySelector(".info-section-header .info-section-title")?.textContent.trim().toLowerCase();
|
|
@@ -4920,34 +4927,34 @@ var dp = ({ url: e, document: t }) => {
|
|
|
4920
4927
|
let r = Array.from(e.querySelectorAll(".term-info-section-item")).map((e) => e.textContent.replace(",", "").trim()).filter((e) => !!e);
|
|
4921
4928
|
r.length && t.set(n, r);
|
|
4922
4929
|
}), t;
|
|
4923
|
-
},
|
|
4924
|
-
let n =
|
|
4930
|
+
}, xp = ({ url: e, document: t }) => {
|
|
4931
|
+
let n = bp(t);
|
|
4925
4932
|
return B(R({
|
|
4926
|
-
au:
|
|
4927
|
-
date:
|
|
4928
|
-
pub:
|
|
4929
|
-
title:
|
|
4933
|
+
au: yp(t) ?? n.get("director"),
|
|
4934
|
+
date: cu(t, "div.product-release-year"),
|
|
4935
|
+
pub: cu(t, "div.studio-section div.term-info-section-item") ?? vu(n.get("supplier")),
|
|
4936
|
+
title: cu(t, ".product-title") ?? cu(t, ".movie-title"),
|
|
4930
4937
|
uri: e
|
|
4931
4938
|
}));
|
|
4932
|
-
},
|
|
4939
|
+
}, Sp = (e) => {
|
|
4933
4940
|
if (V(e, "property", "og:type") === "article") return U.Article;
|
|
4934
4941
|
};
|
|
4935
|
-
function
|
|
4942
|
+
function Cp(e) {
|
|
4936
4943
|
let t = {}, n = e.querySelector("[data-id=layout-form]");
|
|
4937
4944
|
return n && Array.from(n.getElementsByTagName("h2")).forEach((e) => {
|
|
4938
4945
|
let n = e.textContent.toLowerCase(), r = Array.from(e.parentElement?.getElementsByTagName("span") ?? []).map((e) => e.textContent || "");
|
|
4939
4946
|
n && (t[n] = r[0]);
|
|
4940
4947
|
}), t;
|
|
4941
4948
|
}
|
|
4942
|
-
function
|
|
4949
|
+
function wp(e, t, n) {
|
|
4943
4950
|
return n.includes("publisher") ? t.publisher : n.includes("place of publication, exhibition, or creation") ? t["place of publication, exhibition, or creation"] : V(e, "name", "DC.publisher");
|
|
4944
4951
|
}
|
|
4945
|
-
function
|
|
4952
|
+
function Tp(e) {
|
|
4946
4953
|
let t = V(e, "name", "citation_publication_date");
|
|
4947
4954
|
return t ? t.substring(0, 4) : V(e, "name", "citation_online_date")?.substring(0, 4);
|
|
4948
4955
|
}
|
|
4949
|
-
var
|
|
4950
|
-
let t =
|
|
4956
|
+
var Ep = (e) => {
|
|
4957
|
+
let t = Cp(e), n = V(e, "name", "DataCite.title"), r = H(e, "name", "DataCite.contributor"), i = Tp(e), a = V(e, "name", "DC.identifier.DOI"), o = Object.keys(t), s = wp(e, t, o), c = o.includes("journal") ? t.journal : void 0, l = o.includes("volume") ? t.volume : void 0, u = o.includes("issue") ? t.issue : void 0, d = o.includes("issn") ? t.issn : void 0, f = o.includes("electronic location (url)") ? t["electronic location (url)"] : void 0;
|
|
4951
4958
|
return L(F.Article, {
|
|
4952
4959
|
jtitle: c,
|
|
4953
4960
|
atitle: n,
|
|
@@ -4960,43 +4967,43 @@ var Sp = (e) => {
|
|
|
4960
4967
|
issn: d,
|
|
4961
4968
|
uri: f
|
|
4962
4969
|
});
|
|
4963
|
-
},
|
|
4964
|
-
switch (
|
|
4965
|
-
case U.Article: return B(
|
|
4970
|
+
}, Dp = ({ document: e }) => {
|
|
4971
|
+
switch (Sp(e)) {
|
|
4972
|
+
case U.Article: return B(Ep(e));
|
|
4966
4973
|
default: return z();
|
|
4967
4974
|
}
|
|
4968
4975
|
}, J = /* @__PURE__ */ function(e) {
|
|
4969
4976
|
return e.ISSN = "issn (print)", e.EISSN = "issn (electronic)", e.ISBN = "isbn (print)", e.VOLUME = "volume", e.ISSUE = "issue", e.PUBLISHER = "publisher", e.DATE_OF_PUBLICATION = "date of publication", e.RESOURCE_TYPE = "resource type", e.JOURNAL_TITLE = "journal", e.BOOK_TITLE = "book title", e.PAGE_RANGE = "page range", e;
|
|
4970
|
-
}(J || {}),
|
|
4977
|
+
}(J || {}), Op = (e) => {
|
|
4971
4978
|
let t = Y(e, J.RESOURCE_TYPE);
|
|
4972
4979
|
return t ? t === "Other Journal Article" || t === "Journal Article" || t === "Journal Item" || t === "Book Review" ? U.Article : t === "Book Chapter" || t === "Book Part" || t === "Conference Abstract" || t === "Book ChapterConference Paper" || t === "Conference Paper" || t === "Other Book Part" ? U.Document : U.None : U.None;
|
|
4973
|
-
},
|
|
4980
|
+
}, kp = (e) => e.replace(":", "").replace(" | ", "").trim().toLowerCase(), Ap = (e) => {
|
|
4974
4981
|
let t = /* @__PURE__ */ new Map(), n = e.querySelector("ul.rlist.publication-details__list");
|
|
4975
4982
|
return n && Array.from(n.querySelectorAll("li")).forEach((e) => {
|
|
4976
4983
|
let n = Array.from(e.querySelectorAll("span.label")), r = Array.from(e.querySelectorAll("span.info"));
|
|
4977
4984
|
n.forEach((e, n) => {
|
|
4978
|
-
let i =
|
|
4985
|
+
let i = kp(e.textContent), a = r[n]?.textContent?.trim();
|
|
4979
4986
|
i && a && (t.has(i) || t.set(i, []), t.get(i)?.push(a));
|
|
4980
4987
|
});
|
|
4981
4988
|
}), t;
|
|
4982
4989
|
}, Y = (e, t) => {
|
|
4983
4990
|
let n = e.get(t);
|
|
4984
|
-
if (n) return
|
|
4985
|
-
},
|
|
4986
|
-
let t =
|
|
4991
|
+
if (n) return au(n);
|
|
4992
|
+
}, jp = (e) => H(e, "name", "dc.Creator").map((e) => e.trim()), Mp = (e) => {
|
|
4993
|
+
let t = su(e, [".loa-accordion a.author-name"]);
|
|
4987
4994
|
if (t) return t.map((e) => e.replace("Authors:", "").trim());
|
|
4988
|
-
},
|
|
4989
|
-
let t =
|
|
4990
|
-
return t.length > 0 ? t :
|
|
4991
|
-
},
|
|
4995
|
+
}, Np = (e) => {
|
|
4996
|
+
let t = jp(e);
|
|
4997
|
+
return t.length > 0 ? t : Mp(e);
|
|
4998
|
+
}, Pp = (e) => V(e, "name", "dc.Title") ?? V(e, "property", "og:title"), Fp = (e) => V(e, "name", "publication_doi"), Ip = (e, t) => Y(t, J.DATE_OF_PUBLICATION) ?? V(e, "name", "dc.Date"), Lp = (e) => {
|
|
4992
4999
|
let t = Y(e, J.PAGE_RANGE), n, r;
|
|
4993
5000
|
return t?.includes("-") && (n = t ? t.split("-")[0].trim() : void 0, r = t ? t.split("-")[1].trim() : void 0), {
|
|
4994
5001
|
pages: t,
|
|
4995
5002
|
spage: n,
|
|
4996
5003
|
epage: r
|
|
4997
5004
|
};
|
|
4998
|
-
},
|
|
4999
|
-
let r =
|
|
5005
|
+
}, Rp = (e, t, n) => {
|
|
5006
|
+
let r = Pp(e), i = Y(t, J.JOURNAL_TITLE), a = V(e, "name", "citation_journal_title"), o = i ?? a, s = Fp(e), c = Ip(e, t), l = Y(t, J.PUBLISHER), u = Np(e), d = Y(t, J.VOLUME), f = Y(t, J.ISSUE), p = Lp(t), m = Y(t, J.ISSN), h = Y(t, J.EISSN);
|
|
5000
5007
|
return L(F.Article, {
|
|
5001
5008
|
title: r,
|
|
5002
5009
|
jtitle: o,
|
|
@@ -5013,8 +5020,8 @@ var Sp = (e) => {
|
|
|
5013
5020
|
eissn: h,
|
|
5014
5021
|
uri: n
|
|
5015
5022
|
});
|
|
5016
|
-
},
|
|
5017
|
-
let r =
|
|
5023
|
+
}, zp = (e, t, n) => {
|
|
5024
|
+
let r = Pp(e), i = Y(t, J.BOOK_TITLE), a = Fp(e), o = Ip(e, t), s = Y(t, J.PUBLISHER), c = Np(e), l = Lp(t), u = Y(t, J.ISBN);
|
|
5018
5025
|
return I(F.Conference, {
|
|
5019
5026
|
title: r,
|
|
5020
5027
|
btitle: i,
|
|
@@ -5028,8 +5035,8 @@ var Sp = (e) => {
|
|
|
5028
5035
|
isbn: u,
|
|
5029
5036
|
uri: n
|
|
5030
5037
|
});
|
|
5031
|
-
},
|
|
5032
|
-
let r =
|
|
5038
|
+
}, Bp = (e, t, n) => {
|
|
5039
|
+
let r = Pp(e), i = Fp(e), a = Ip(e, t), o = Y(t, J.PUBLISHER), s = Np(e), c = Y(t, J.ISBN);
|
|
5033
5040
|
return I(F.Document, {
|
|
5034
5041
|
title: r,
|
|
5035
5042
|
doi: i,
|
|
@@ -5039,16 +5046,16 @@ var Sp = (e) => {
|
|
|
5039
5046
|
uri: n,
|
|
5040
5047
|
isbn: c
|
|
5041
5048
|
});
|
|
5042
|
-
},
|
|
5043
|
-
let n =
|
|
5044
|
-
switch (
|
|
5045
|
-
case U.Article: return B(
|
|
5046
|
-
case U.Document: return B(
|
|
5047
|
-
case U.None: return B(
|
|
5049
|
+
}, Vp = ({ url: e, document: t }) => {
|
|
5050
|
+
let n = Ap(t);
|
|
5051
|
+
switch (Op(n)) {
|
|
5052
|
+
case U.Article: return B(Rp(t, n, e));
|
|
5053
|
+
case U.Document: return B(zp(t, n, e));
|
|
5054
|
+
case U.None: return B(Bp(t, n, e));
|
|
5048
5055
|
default: return z();
|
|
5049
5056
|
}
|
|
5050
|
-
},
|
|
5051
|
-
let t =
|
|
5057
|
+
}, Hp = (e) => V(e, "property", "og:title")?.trim() ?? void 0, Up = (e) => V(e, "name", "dc.identifier") ?? V(e, "name", "citation_doi"), Wp = (e) => {
|
|
5058
|
+
let t = Hp(e), n = t, r = Xp(e), i = Yp(e), a = qp(e), o = Jp(e), { issn: s, eissn: c } = Kp(e);
|
|
5052
5059
|
return B(L(F.Journal, {
|
|
5053
5060
|
date: r,
|
|
5054
5061
|
eissn: c,
|
|
@@ -5059,11 +5066,11 @@ var Sp = (e) => {
|
|
|
5059
5066
|
title: t,
|
|
5060
5067
|
volume: o
|
|
5061
5068
|
}));
|
|
5062
|
-
},
|
|
5069
|
+
}, Gp = (e) => e.includes("/journals/") && e.includes("issue"), Kp = (e) => ({
|
|
5063
5070
|
issn: e.querySelector("dd.printissn.text-metadata-value > span")?.textContent.trim(),
|
|
5064
5071
|
eissn: e.querySelector("dd.onlineissn.text-metadata-value > span")?.textContent.trim()
|
|
5065
|
-
}),
|
|
5066
|
-
let t =
|
|
5072
|
+
}), qp = (e) => e.querySelector("dd.publisher.text-metadata-value span")?.textContent.trim() ?? void 0, Jp = (e) => Hp(e)?.match(/Volume\s+(\d+)/i)?.[1], Yp = (e) => Hp(e)?.match(/Issue\s+(\d+)/i)?.[1], Xp = (e) => Hp(e)?.match(/\((\d{4})\)/)?.[1], Zp = (e) => {
|
|
5073
|
+
let t = Hp(e), n = V(e, "name", "citation_title") ?? t, r = H(e, "property", "article:author"), i = Qp(e), a = Up(e), o = V(e, "name", "citation_lastpage"), s = V(e, "name", "citation_issn"), c = V(e, "name", "citation_issue"), l = V(e, "name", "citation_journal_title"), u = V(e, "name", "citation_publisher"), d = V(e, "name", "citation_firstpage"), f = V(e, "name", "citation_volume");
|
|
5067
5074
|
return B(L(F.Article, {
|
|
5068
5075
|
atitle: n,
|
|
5069
5076
|
au: r,
|
|
@@ -5078,8 +5085,8 @@ var Sp = (e) => {
|
|
|
5078
5085
|
title: t,
|
|
5079
5086
|
volume: f
|
|
5080
5087
|
}));
|
|
5081
|
-
},
|
|
5082
|
-
let t =
|
|
5088
|
+
}, Qp = (e) => V(e, "property", "article:published_time") ?? V(e, "name", "citation_publication_date"), $p = (e) => {
|
|
5089
|
+
let t = Hp(e), n = V(e, "name", "citation_title") ?? t, r = em(e), i = nm(e), a = Up(e), o = rm(e), s = V(e, "name", "citation_publisher");
|
|
5083
5090
|
return B(I(F.Book, {
|
|
5084
5091
|
au: r,
|
|
5085
5092
|
btitle: n,
|
|
@@ -5089,59 +5096,59 @@ var Sp = (e) => {
|
|
|
5089
5096
|
pub: s,
|
|
5090
5097
|
title: t
|
|
5091
5098
|
}));
|
|
5092
|
-
},
|
|
5099
|
+
}, em = (e) => {
|
|
5093
5100
|
let t = H(e, "property", "book:author");
|
|
5094
5101
|
if (t.length > 0) return t;
|
|
5095
5102
|
let n = H(e, "name", "citation_author");
|
|
5096
|
-
return n.length > 0 ? n :
|
|
5097
|
-
},
|
|
5103
|
+
return n.length > 0 ? n : tm(e);
|
|
5104
|
+
}, tm = (e) => Array.from(e.querySelectorAll(".contributor-details span[data-testid=\"author-name\"]")).map((e) => (e.textContent || "").trim()).filter((e) => e.length > 0), nm = (e) => V(e, "property", "book:release_date") ?? V(e, "name", "citation_publication_date"), rm = (e) => V(e, "property", "book:isbn") ?? V(e, "name", "citation_isbn"), im = (e, t) => {
|
|
5098
5105
|
switch (V(e, "property", "og:type")) {
|
|
5099
5106
|
case "article": return U.Article;
|
|
5100
5107
|
case "book": return U.Book;
|
|
5101
5108
|
default: break;
|
|
5102
5109
|
}
|
|
5103
|
-
return
|
|
5104
|
-
},
|
|
5105
|
-
switch (
|
|
5106
|
-
case U.Article: return
|
|
5107
|
-
case U.Journal: return
|
|
5108
|
-
case U.Book: return
|
|
5110
|
+
return Gp(t) ? U.Journal : U.None;
|
|
5111
|
+
}, am = ({ document: e, url: t }) => {
|
|
5112
|
+
switch (im(e, t)) {
|
|
5113
|
+
case U.Article: return Zp(e);
|
|
5114
|
+
case U.Journal: return Wp(e);
|
|
5115
|
+
case U.Book: return $p(e);
|
|
5109
5116
|
default: return z();
|
|
5110
5117
|
}
|
|
5111
|
-
},
|
|
5118
|
+
}, om = (e) => {
|
|
5112
5119
|
let t = e.getAttribute("title");
|
|
5113
5120
|
return t ? Do(t) : null;
|
|
5114
|
-
},
|
|
5121
|
+
}, sm = ({ url: e, document: t }) => {
|
|
5115
5122
|
let n = t.querySelector(".Z3988");
|
|
5116
5123
|
if (!n) return z();
|
|
5117
|
-
let r =
|
|
5124
|
+
let r = om(n);
|
|
5118
5125
|
return r ? (r.genre === F.Article && !r.jtitle && r.title && (r.jtitle = r.title), B({
|
|
5119
5126
|
...r,
|
|
5120
5127
|
uri: e
|
|
5121
5128
|
})) : z();
|
|
5122
|
-
},
|
|
5123
|
-
let n = e.querySelector(
|
|
5129
|
+
}, cm = (e) => `[data-qa="detail_${e}"]`, lm = (e, t) => {
|
|
5130
|
+
let n = e.querySelector(cm(t));
|
|
5124
5131
|
return n ? Array.from(n.querySelectorAll("nde-highlight")).map((e) => e.textContent.trim()).filter((e) => !!e) : [];
|
|
5125
|
-
},
|
|
5126
|
-
let n =
|
|
5132
|
+
}, um = (e, t) => {
|
|
5133
|
+
let n = lm(e, t);
|
|
5127
5134
|
return n.length > 0 ? n[0] : void 0;
|
|
5128
|
-
},
|
|
5129
|
-
let t = e.querySelector(
|
|
5135
|
+
}, dm = (e) => {
|
|
5136
|
+
let t = e.querySelector(cm("creator"));
|
|
5130
5137
|
if (!t) return [];
|
|
5131
5138
|
let n = Array.from(t.querySelectorAll("nde-highlight")).map((e) => e.textContent.trim()).filter((e) => !!e).map((e) => e.replace(/,?\s*author\s*$/i, "").trim());
|
|
5132
5139
|
return n.length > 0 ? n : [];
|
|
5133
|
-
},
|
|
5134
|
-
let t =
|
|
5135
|
-
return
|
|
5136
|
-
authors:
|
|
5137
|
-
title:
|
|
5138
|
-
publisher:
|
|
5139
|
-
creationDate:
|
|
5140
|
+
}, fm = (e) => {
|
|
5141
|
+
let t = lm(e, "identifier"), n = lm(e, "ispartof"), r = t.find((e) => e.startsWith("LC:"));
|
|
5142
|
+
return Yu({
|
|
5143
|
+
authors: dm(e),
|
|
5144
|
+
title: um(e, "title"),
|
|
5145
|
+
publisher: um(e, "publisher"),
|
|
5146
|
+
creationDate: um(e, "creationdate"),
|
|
5140
5147
|
isPartOf: n.length > 0 ? n[0] : void 0,
|
|
5141
5148
|
identifierValues: t,
|
|
5142
5149
|
lcn: r?.replace("LC:", "").trim()
|
|
5143
5150
|
});
|
|
5144
|
-
},
|
|
5151
|
+
}, pm = {
|
|
5145
5152
|
Article: q.Article,
|
|
5146
5153
|
Audio: q.Audio,
|
|
5147
5154
|
Book: q.Book,
|
|
@@ -5152,28 +5159,28 @@ var Sp = (e) => {
|
|
|
5152
5159
|
"Magazine Article": q.Article,
|
|
5153
5160
|
Newspaper: q.Journal,
|
|
5154
5161
|
Video: q.Video
|
|
5155
|
-
},
|
|
5162
|
+
}, mm = {
|
|
5156
5163
|
CreativeWork: q.Audio,
|
|
5157
5164
|
Movie: q.Video,
|
|
5158
5165
|
Periodical: q.Journal,
|
|
5159
5166
|
Thesis: q.Dissertation
|
|
5160
|
-
},
|
|
5161
|
-
...
|
|
5162
|
-
...
|
|
5163
|
-
},
|
|
5167
|
+
}, hm = {
|
|
5168
|
+
...pm,
|
|
5169
|
+
...mm
|
|
5170
|
+
}, gm = (e) => {
|
|
5164
5171
|
if (e) return e.mainEntity["@type"];
|
|
5165
|
-
},
|
|
5166
|
-
let n =
|
|
5167
|
-
return n ?
|
|
5168
|
-
}),
|
|
5172
|
+
}, _m = (e) => e.querySelector(".record-type")?.textContent.trim() ?? void 0, vm = yd(fm, (e, t) => {
|
|
5173
|
+
let n = _m(e) ?? gm(t);
|
|
5174
|
+
return n ? hm[n] : void 0;
|
|
5175
|
+
}), ym = (e) => {
|
|
5169
5176
|
let t = V(e, "name", "bepress_citation_doi");
|
|
5170
5177
|
if (t) return t.replace("https://doi.org/", "").trim();
|
|
5171
|
-
},
|
|
5178
|
+
}, bm = (e) => {
|
|
5172
5179
|
let { document: t } = e, n = ns(e);
|
|
5173
|
-
if (!
|
|
5174
|
-
let r = V(t, "name", "bepress_citation_date"), i = V(t, "name", "bepress_citation_pdf_url"), a =
|
|
5180
|
+
if (!Yc(n)) return n;
|
|
5181
|
+
let r = V(t, "name", "bepress_citation_date"), i = V(t, "name", "bepress_citation_pdf_url"), a = ym(t);
|
|
5175
5182
|
return r && (n.resource.date = r), i && (n.resource.uri = i), a && (n.resource.rft_id = [a]), n;
|
|
5176
|
-
},
|
|
5183
|
+
}, xm = (e) => {
|
|
5177
5184
|
let t = {}, n = Array.from(e.querySelectorAll("#bibliographic-data .bib-label"));
|
|
5178
5185
|
for (let e of n) {
|
|
5179
5186
|
let n = e.querySelector("h6")?.textContent.trim().toLowerCase(), r = e.nextElementSibling?.classList.contains("bib-field") ? e.nextElementSibling.textContent.trim() : void 0;
|
|
@@ -5184,16 +5191,16 @@ var Sp = (e) => {
|
|
|
5184
5191
|
n && (t.title = n.textContent.trim());
|
|
5185
5192
|
}
|
|
5186
5193
|
return t;
|
|
5187
|
-
},
|
|
5194
|
+
}, Sm = (e) => {
|
|
5188
5195
|
if (e.title) return e.subtitle ? `${e.title}: ${e.subtitle}` : e.title;
|
|
5189
|
-
},
|
|
5196
|
+
}, Cm = (e) => {
|
|
5190
5197
|
let t = e["print pub date"];
|
|
5191
5198
|
if (t) return t.split("-")[0];
|
|
5192
|
-
},
|
|
5199
|
+
}, wm = (e) => e.author ? [e.author] : e.authors ? Tm(e.authors) : void 0, Tm = (e) => {
|
|
5193
5200
|
let t = e.split(",").map((e) => e.trim()).filter(Boolean), n = t[t.length - 1];
|
|
5194
5201
|
return n.startsWith("and ") && (t[t.length - 1] = n.replace(/^and\s/, "").trim()), t;
|
|
5195
|
-
},
|
|
5196
|
-
let n =
|
|
5202
|
+
}, Em = (e, t) => e.querySelector("a.ga_detail_bt_readonline")?.getAttribute("href") ?? t, Dm = ({ document: e, url: t }) => {
|
|
5203
|
+
let n = xm(e), r = Sm(n), i = n.edition, a = n["ebook isbn"], o = wm(n), s = n.publisher, c = n.series, l = Cm(n), u = Em(e, t);
|
|
5197
5204
|
return B(I(F.Book, {
|
|
5198
5205
|
atitle: r,
|
|
5199
5206
|
edition: i,
|
|
@@ -5204,7 +5211,7 @@ var Sp = (e) => {
|
|
|
5204
5211
|
date: l,
|
|
5205
5212
|
uri: u
|
|
5206
5213
|
}));
|
|
5207
|
-
},
|
|
5214
|
+
}, Om = W.extend({
|
|
5208
5215
|
"@type": N("VideoObject"),
|
|
5209
5216
|
name: O(),
|
|
5210
5217
|
url: O(),
|
|
@@ -5216,56 +5223,56 @@ var Sp = (e) => {
|
|
|
5216
5223
|
"@type": N("Person"),
|
|
5217
5224
|
name: O()
|
|
5218
5225
|
}))]))
|
|
5219
|
-
}),
|
|
5220
|
-
let t =
|
|
5226
|
+
}), km = (e) => {
|
|
5227
|
+
let t = $s(e);
|
|
5221
5228
|
if (!t) return null;
|
|
5222
|
-
let n =
|
|
5229
|
+
let n = ec(t), r = Om.safeParse(n);
|
|
5223
5230
|
return r.success ? r.data : null;
|
|
5224
|
-
},
|
|
5231
|
+
}, Am = (e) => {
|
|
5225
5232
|
if (e.creator) return Array.isArray(e.creator) ? e.creator.map((e) => e.name) : [e.creator.name];
|
|
5226
|
-
},
|
|
5227
|
-
let t =
|
|
5233
|
+
}, jm = ({ document: e }) => {
|
|
5234
|
+
let t = km(e);
|
|
5228
5235
|
if (!t) return z();
|
|
5229
|
-
let n =
|
|
5236
|
+
let n = Am(t);
|
|
5230
5237
|
return B(R({
|
|
5231
5238
|
title: t.name,
|
|
5232
5239
|
date: t.datePublished,
|
|
5233
5240
|
au: n,
|
|
5234
5241
|
uri: t.url
|
|
5235
5242
|
}));
|
|
5236
|
-
},
|
|
5243
|
+
}, Mm = W.extend({ publisher: j({
|
|
5237
5244
|
"@type": N("Organization"),
|
|
5238
5245
|
name: O()
|
|
5239
|
-
}) }),
|
|
5246
|
+
}) }), Nm = W.extend({
|
|
5240
5247
|
"@type": N("WebSite"),
|
|
5241
5248
|
issn: O(),
|
|
5242
5249
|
name: O()
|
|
5243
|
-
}),
|
|
5244
|
-
let t =
|
|
5250
|
+
}), Pm = (e) => {
|
|
5251
|
+
let t = Im(e), n = e.querySelector(".article-issue-info a")?.getAttribute("href") ?? "", r = /\/v(\d+)/i.exec(n), i = /\/n(\d+)/i.exec(n);
|
|
5245
5252
|
return {
|
|
5246
5253
|
jtitle: t?.name ?? void 0,
|
|
5247
5254
|
issn: t?.issn ?? void 0,
|
|
5248
5255
|
volume: r ? r[1] : void 0,
|
|
5249
5256
|
issue: i ? i[1] : void 0
|
|
5250
5257
|
};
|
|
5251
|
-
},
|
|
5252
|
-
let t =
|
|
5253
|
-
return t.length === 0 ? null : t.map((e) =>
|
|
5254
|
-
},
|
|
5255
|
-
let t =
|
|
5258
|
+
}, Fm = (e) => {
|
|
5259
|
+
let t = Qs(e);
|
|
5260
|
+
return t.length === 0 ? null : t.map((e) => ec(e)).filter((e) => e !== null);
|
|
5261
|
+
}, Im = (e) => {
|
|
5262
|
+
let t = Fm(e);
|
|
5256
5263
|
if (!t) return;
|
|
5257
|
-
let n = t.map((e) =>
|
|
5264
|
+
let n = t.map((e) => Nm.safeParse(e)).find((e) => e.success);
|
|
5258
5265
|
return n ? n.data : void 0;
|
|
5259
|
-
},
|
|
5260
|
-
let t =
|
|
5266
|
+
}, Lm = (e) => {
|
|
5267
|
+
let t = Fm(e);
|
|
5261
5268
|
if (!t) return;
|
|
5262
|
-
let n = t.map((e) =>
|
|
5269
|
+
let n = t.map((e) => Mm.safeParse(e)).find((e) => e.success);
|
|
5263
5270
|
return n ? n.data.publisher.name : void 0;
|
|
5264
|
-
},
|
|
5271
|
+
}, Rm = (e) => V(e, "property", "article:author"), zm = (e) => V(e, "property", "og:title"), Bm = (e) => {
|
|
5265
5272
|
let t = V(e, "property", "article:published_time");
|
|
5266
5273
|
return t ? t.split("T")[0] : void 0;
|
|
5267
|
-
},
|
|
5268
|
-
let t =
|
|
5274
|
+
}, Vm = (e) => V(e, "property", "og:url"), Hm = (e) => {
|
|
5275
|
+
let t = Rm(e), n = zm(e), r = Vm(e), i = Bm(e), a = Lm(e), { volume: o, issue: s, issn: c, jtitle: l } = Pm(e);
|
|
5269
5276
|
return L(F.Article, {
|
|
5270
5277
|
au: t ? [t] : void 0,
|
|
5271
5278
|
pub: a,
|
|
@@ -5277,8 +5284,8 @@ var Sp = (e) => {
|
|
|
5277
5284
|
volume: o,
|
|
5278
5285
|
issue: s
|
|
5279
5286
|
});
|
|
5280
|
-
},
|
|
5281
|
-
let t =
|
|
5287
|
+
}, Um = (e) => {
|
|
5288
|
+
let t = Rm(e), n = zm(e), r = Vm(e), i = Bm(e), a = Lm(e);
|
|
5282
5289
|
return R({
|
|
5283
5290
|
au: t ? [t] : void 0,
|
|
5284
5291
|
pub: a,
|
|
@@ -5286,42 +5293,42 @@ var Sp = (e) => {
|
|
|
5286
5293
|
title: n,
|
|
5287
5294
|
date: i
|
|
5288
5295
|
});
|
|
5289
|
-
},
|
|
5296
|
+
}, Wm = (e) => {
|
|
5290
5297
|
switch (V(e, "property", "og:type")) {
|
|
5291
5298
|
case "article": return U.Article;
|
|
5292
5299
|
case "podcast":
|
|
5293
5300
|
case "film": return U.AudioVisual;
|
|
5294
5301
|
default: return null;
|
|
5295
5302
|
}
|
|
5296
|
-
},
|
|
5297
|
-
switch (
|
|
5298
|
-
case U.Article: return
|
|
5299
|
-
case U.AudioVisual: return
|
|
5303
|
+
}, Gm = (e) => {
|
|
5304
|
+
switch (Wm(e)) {
|
|
5305
|
+
case U.Article: return Hm(e);
|
|
5306
|
+
case U.AudioVisual: return Um(e);
|
|
5300
5307
|
default: return null;
|
|
5301
5308
|
}
|
|
5302
|
-
},
|
|
5303
|
-
let t =
|
|
5309
|
+
}, Km = ({ document: e }) => {
|
|
5310
|
+
let t = Gm(e);
|
|
5304
5311
|
return t ? B(t) : z();
|
|
5305
|
-
},
|
|
5312
|
+
}, qm = (e) => {
|
|
5306
5313
|
let t = /\/books\/([^/]+)/.exec(e);
|
|
5307
5314
|
return t ? t[1] : void 0;
|
|
5308
|
-
},
|
|
5315
|
+
}, Jm = (e) => {
|
|
5309
5316
|
let t = e.querySelector(".sc-epFoly")?.textContent.trim();
|
|
5310
5317
|
if (t) return t.split(";").map((e) => e.trim());
|
|
5311
|
-
},
|
|
5318
|
+
}, Ym = (e) => {
|
|
5312
5319
|
let t = e.querySelector("h3.sc-eEvSnX")?.textContent.trim();
|
|
5313
5320
|
if (t) return t;
|
|
5314
5321
|
let n = e.title.split("Ref:").pop();
|
|
5315
5322
|
return n ? n.trim() : void 0;
|
|
5316
|
-
},
|
|
5317
|
-
let n =
|
|
5323
|
+
}, Xm = ({ document: e, url: t }) => {
|
|
5324
|
+
let n = Ym(e), r = qm(t), i = Jm(e);
|
|
5318
5325
|
return !n && !i && !r ? z() : B(I(F.Book, {
|
|
5319
5326
|
title: n,
|
|
5320
5327
|
au: i,
|
|
5321
5328
|
isbn: r,
|
|
5322
5329
|
uri: t
|
|
5323
5330
|
}));
|
|
5324
|
-
},
|
|
5331
|
+
}, Zm = (e) => {
|
|
5325
5332
|
let t = V(e, "name", "citation_title");
|
|
5326
5333
|
if (!t) return null;
|
|
5327
5334
|
let n = H(e, "name", "citation_author"), r = V(e, "name", "citation_journal_title"), i = V(e, "name", "citation_issn"), a = fs(V(e, "name", "citation_date")), o = V(e, "name", "citation_volume"), s = V(e, "name", "citation_issue"), c = V(e, "name", "citation_firstpage"), l = V(e, "name", "citation_lastpage"), u = V(e, "name", "citation_doi"), d = V(e, "name", "citation_fulltext_html_url") ?? V(e, "name", "citation_pdf_url");
|
|
@@ -5338,57 +5345,183 @@ var Sp = (e) => {
|
|
|
5338
5345
|
doi: u,
|
|
5339
5346
|
uri: d
|
|
5340
5347
|
});
|
|
5341
|
-
},
|
|
5342
|
-
let t =
|
|
5348
|
+
}, Qm = (e) => {
|
|
5349
|
+
let t = Zm(e.document);
|
|
5343
5350
|
return t ? B(t) : ns(e);
|
|
5351
|
+
}, $m = "[data-auto=\"record-staff-view-title\"]", eh = 3, th = /\$([a-z0-9])\s*([^$]*)/g, nh = /[\s,:;/=]+$/, rh = "001", ih = "007", ah = ["020"], oh = ["100", "700"], sh = ["245"], ch = ["250"], lh = ["260", "264"], uh = [
|
|
5352
|
+
"440",
|
|
5353
|
+
"490",
|
|
5354
|
+
"830"
|
|
5355
|
+
], dh = ["856"], fh = "LEA", ph = 6, mh = new Set(["m", "v"]), hh = new Set(["i", "j"]), gh = (e) => e.trim().replace(nh, ""), _h = (e) => {
|
|
5356
|
+
let t = /* @__PURE__ */ new Map();
|
|
5357
|
+
for (let [, n, r] of e.matchAll(th)) {
|
|
5358
|
+
let e = gh(r);
|
|
5359
|
+
e && !t.has(n) && t.set(n, e);
|
|
5360
|
+
}
|
|
5361
|
+
return t;
|
|
5362
|
+
}, vh = (e) => {
|
|
5363
|
+
let t = e.querySelector($m);
|
|
5364
|
+
if (!t) return;
|
|
5365
|
+
let n = /* @__PURE__ */ new Map();
|
|
5366
|
+
for (let e of t.querySelectorAll("tr")) {
|
|
5367
|
+
let t = e.querySelectorAll("td");
|
|
5368
|
+
if (t.length < 2) continue;
|
|
5369
|
+
let r = t[0].textContent.trim().slice(0, eh), i = t[1].textContent.trim();
|
|
5370
|
+
if (!r || !i) continue;
|
|
5371
|
+
let a = n.get(r) ?? [];
|
|
5372
|
+
a.push(i), n.set(r, a);
|
|
5373
|
+
}
|
|
5374
|
+
return n.size > 0 ? n : void 0;
|
|
5375
|
+
}, yh = (e, t) => au(e.get(t)), bh = (e, t, n) => t.flatMap((t) => e.get(t) ?? []).map((e) => _h(e).get(n)).filter((e) => !!e), xh = (e, t, n) => au(bh(e, t, n)), Sh = (e) => {
|
|
5376
|
+
let t = xh(e, sh, "a");
|
|
5377
|
+
if (!t) return;
|
|
5378
|
+
let n = xh(e, sh, "b");
|
|
5379
|
+
return n ? `${t} : ${n}` : t;
|
|
5380
|
+
}, Ch = (e) => {
|
|
5381
|
+
let t = bh(e, oh, "a");
|
|
5382
|
+
return t.length > 0 ? t : void 0;
|
|
5383
|
+
}, wh = (e) => {
|
|
5384
|
+
let t = yh(e, fh)?.charAt(ph);
|
|
5385
|
+
if (hh.has(t ?? "")) return F.AudioDocument;
|
|
5386
|
+
let n = yh(e, ih)?.charAt(0);
|
|
5387
|
+
if (mh.has(n ?? "")) return F.AudioVisualDocument;
|
|
5388
|
+
}, Th = (e) => {
|
|
5389
|
+
let t = vh(e);
|
|
5390
|
+
return t ? {
|
|
5391
|
+
genre: wh(t),
|
|
5392
|
+
title: Sh(t),
|
|
5393
|
+
au: Ch(t),
|
|
5394
|
+
pub: xh(t, lh, "b"),
|
|
5395
|
+
place: xh(t, lh, "a"),
|
|
5396
|
+
isbn: Bs(bh(t, ah, "a")),
|
|
5397
|
+
date: fs(xh(t, lh, "c")),
|
|
5398
|
+
edition: xh(t, ch, "a"),
|
|
5399
|
+
series: xh(t, uh, "a"),
|
|
5400
|
+
bibid: yh(t, rh),
|
|
5401
|
+
uri: xh(t, dh, "u")
|
|
5402
|
+
} : {};
|
|
5403
|
+
}, Eh = "[data-auto=\"record-summary\"]", Dh = "[data-auto=\"record-summary-title\"]", Oh = "[data-auto=\"record-publisher-content\"]", kh = "[data-auto=\"record-isbn-content\"] li", Ah = "[data-auto=\"record-document-type-content\"]", jh = ".instanceDetailsPage__externalLink [data-auto=\"eb-hyperlink\"]", Mh = ["By", "Contributors"], Nh = "Published", Ph = new Map([
|
|
5404
|
+
["paperback", F.Book],
|
|
5405
|
+
["hardback", F.Book],
|
|
5406
|
+
["re-bound", F.Book],
|
|
5407
|
+
["spiral", F.Book],
|
|
5408
|
+
["boxed", F.Book],
|
|
5409
|
+
["pack", F.Book],
|
|
5410
|
+
["ebook", F.Book],
|
|
5411
|
+
["dvd", F.AudioVisualDocument],
|
|
5412
|
+
["compact disc", F.AudioDocument],
|
|
5413
|
+
["sound disc", F.AudioDocument],
|
|
5414
|
+
["audio cassette", F.AudioDocument],
|
|
5415
|
+
["e-audio", F.AudioDocument],
|
|
5416
|
+
["other -- unknown", F.Unknown]
|
|
5417
|
+
]), Fh = (e, t) => {
|
|
5418
|
+
let n = e.querySelector(Eh);
|
|
5419
|
+
return Array.from(n?.querySelectorAll("span") ?? []).find((e) => e.textContent.trim() === `${t}:`);
|
|
5420
|
+
}, Ih = (e) => e.split("/")[0].trim(), Lh = (e) => {
|
|
5421
|
+
let t = cu(e, Dh);
|
|
5422
|
+
return t ? Ih(t) : void 0;
|
|
5423
|
+
}, Rh = (e) => {
|
|
5424
|
+
let t = Mh.flatMap((t) => Array.from(Fh(e, t)?.parentElement?.querySelectorAll("a") ?? [])).map((e) => e.textContent.trim()).filter((e) => e.length > 0);
|
|
5425
|
+
return t.length > 0 ? t : void 0;
|
|
5426
|
+
}, zh = (e) => Fh(e, Nh)?.nextElementSibling?.textContent.trim(), Bh = (e) => {
|
|
5427
|
+
let t = cu(e, Oh);
|
|
5428
|
+
if (!t) return {};
|
|
5429
|
+
let n = t.lastIndexOf(",");
|
|
5430
|
+
return n === -1 ? { publisher: t } : {
|
|
5431
|
+
publisher: t.slice(0, n).trim() || void 0,
|
|
5432
|
+
place: t.slice(n + 1).trim() || void 0
|
|
5433
|
+
};
|
|
5434
|
+
}, Vh = (e) => Array.from(e.querySelectorAll(kh)).map((e) => e.textContent.trim()).filter((e) => e.length > 0), Hh = (e) => {
|
|
5435
|
+
let t = e.querySelector(jh)?.getAttribute("href")?.trim() ?? "";
|
|
5436
|
+
return t.length > 0 ? t : void 0;
|
|
5437
|
+
}, Uh = (e) => {
|
|
5438
|
+
let t = cu(e, Ah)?.toLowerCase();
|
|
5439
|
+
return t ? Ph.get(t) ?? F.Unknown : F.Book;
|
|
5440
|
+
}, Wh = (e) => {
|
|
5441
|
+
let { publisher: t, place: n } = Bh(e);
|
|
5442
|
+
return {
|
|
5443
|
+
genre: Uh(e),
|
|
5444
|
+
title: Lh(e),
|
|
5445
|
+
au: Rh(e),
|
|
5446
|
+
pub: t,
|
|
5447
|
+
place: n,
|
|
5448
|
+
isbn: Bs(Vh(e)),
|
|
5449
|
+
date: fs(zh(e)),
|
|
5450
|
+
uri: Hh(e)
|
|
5451
|
+
};
|
|
5452
|
+
}, Gh = /(^|[\s.])\p{Lu}\.$/u, Kh = /,\s*\d{4}[^,]*$/, qh = /\s*\([^)]*\)$/, Jh = (e) => Gh.test(e) ? e : e.replace(/\.$/, ""), Yh = (e) => e.replace(Kh, ""), Xh = (e) => e.replace(qh, ""), Zh = (e) => e?.map((e) => Jh(Yh(Xh(e)))), Qh = (e) => ({
|
|
5453
|
+
...R(e),
|
|
5454
|
+
genre: F.AudioDocument
|
|
5455
|
+
}), $h = (e) => ro.safeParse(e).success, eg = (e) => $h(e) ? e : F.Unknown, tg = (e) => {
|
|
5456
|
+
let t = Wh(e), n = Th(e), r = n.title ?? t.title;
|
|
5457
|
+
if (!r) return null;
|
|
5458
|
+
let i = {
|
|
5459
|
+
title: r,
|
|
5460
|
+
au: Zh(n.au ?? t.au),
|
|
5461
|
+
pub: n.pub ?? t.pub,
|
|
5462
|
+
isbn: Bs([t.isbn, n.isbn]),
|
|
5463
|
+
date: n.date ?? t.date,
|
|
5464
|
+
bibid: n.bibid ?? t.bibid,
|
|
5465
|
+
uri: n.uri ?? t.uri
|
|
5466
|
+
}, a = n.genre ?? t.genre ?? F.Book;
|
|
5467
|
+
return a === F.AudioDocument ? Qh(i) : a === F.AudioVisualDocument ? R(i) : I(eg(a), {
|
|
5468
|
+
...i,
|
|
5469
|
+
place: n.place ?? t.place,
|
|
5470
|
+
edition: n.edition ?? t.edition,
|
|
5471
|
+
series: n.series ?? t.series
|
|
5472
|
+
});
|
|
5473
|
+
}, ng = (e) => {
|
|
5474
|
+
let t = tg(e.document);
|
|
5475
|
+
return t ? B(t) : z();
|
|
5344
5476
|
}, X = /* @__PURE__ */ function(e) {
|
|
5345
|
-
return e.NoResourceFound = "NoResourceFound", e.Z3988 = "Z3988", e.Z3988SearchResult = "Z3988SearchResult", e.Amazon = "Amazon", e.CupOfJo = "CupOfJo", e.IngentaConnect = "IngentaConnect", e.Jstor = "Jstor", e.Milne = "Milne", e.Primo = "Primo", e.SagePub = "SagePub", e.SageVideo = "SageVideo", e.ScienceDirect = "ScienceDirect", e.Springer = "Springer", e.Youtube = "Youtube", e.TaylorFrancis = "TaylorFrancis", e.Wiley = "Wiley", e.VuFind = "VuFind", e.ClinicalKey = "ClinicalKey", e.DOAJ = "DOAJ", e.Ebscohost = "Ebscohost", e.OpenStax = "OpenStax", e.CambridgeJournalsOnline = "CambridgeJournalsOnline", e.OpenTextbook = "OpenTextbook", e.AhaJournals = "AhaJournals", e.Ijees = "Ijees", e.BloomsburyCollections = "BloomsburyCollections", e.HeritageCirqa = "HeritageCirqa", e.BritishMedicalJournal = "BritishMedicalJournal", e.SummonSearchResult = "SummonSearchResult", e.ApplePodcasts = "ApplePodcasts", e.Arxiv = "Arxiv", e.KanopyVideo = "KanopyVideo", e.LaTrobeOpal = "LaTrobeOpal", e.BYUScholarsArchive = "BYUScholarsArchive", e.Informit = "Informit", e.Brill = "Brill", e.HeinOnline = "HeinOnline", e.PrimoNde = "PrimoNde", e.MichiganLaw = "MichiganLaw", e.EbookCentral = "EbookCentral", e.AlexanderStreetPress = "AlexanderStreetPress", e.LondonReviewOfBooks = "LondonReviewOfBooks", e.VitalSource = "VitalSource", e.Icono14 = "Icono14", e;
|
|
5346
|
-
}({}),
|
|
5347
|
-
[X.NoResourceFound]:
|
|
5477
|
+
return e.NoResourceFound = "NoResourceFound", e.Z3988 = "Z3988", e.Z3988SearchResult = "Z3988SearchResult", e.Amazon = "Amazon", e.CupOfJo = "CupOfJo", e.IngentaConnect = "IngentaConnect", e.Jstor = "Jstor", e.Milne = "Milne", e.Primo = "Primo", e.SagePub = "SagePub", e.SageVideo = "SageVideo", e.ScienceDirect = "ScienceDirect", e.Springer = "Springer", e.Youtube = "Youtube", e.TaylorFrancis = "TaylorFrancis", e.Wiley = "Wiley", e.VuFind = "VuFind", e.ClinicalKey = "ClinicalKey", e.DOAJ = "DOAJ", e.Ebscohost = "Ebscohost", e.OpenStax = "OpenStax", e.CambridgeJournalsOnline = "CambridgeJournalsOnline", e.OpenTextbook = "OpenTextbook", e.AhaJournals = "AhaJournals", e.Ijees = "Ijees", e.BloomsburyCollections = "BloomsburyCollections", e.HeritageCirqa = "HeritageCirqa", e.BritishMedicalJournal = "BritishMedicalJournal", e.SummonSearchResult = "SummonSearchResult", e.ApplePodcasts = "ApplePodcasts", e.Arxiv = "Arxiv", e.KanopyVideo = "KanopyVideo", e.LaTrobeOpal = "LaTrobeOpal", e.BYUScholarsArchive = "BYUScholarsArchive", e.Informit = "Informit", e.Brill = "Brill", e.HeinOnline = "HeinOnline", e.PrimoNde = "PrimoNde", e.MichiganLaw = "MichiganLaw", e.EbookCentral = "EbookCentral", e.AlexanderStreetPress = "AlexanderStreetPress", e.LondonReviewOfBooks = "LondonReviewOfBooks", e.VitalSource = "VitalSource", e.Icono14 = "Icono14", e.EbscoLocate = "EbscoLocate", e;
|
|
5478
|
+
}({}), rg = {
|
|
5479
|
+
[X.NoResourceFound]: lc,
|
|
5348
5480
|
[X.Z3988]: ns,
|
|
5349
|
-
[X.Z3988SearchResult]:
|
|
5481
|
+
[X.Z3988SearchResult]: iu,
|
|
5350
5482
|
[X.Amazon]: us,
|
|
5351
|
-
[X.CupOfJo]:
|
|
5352
|
-
[X.Jstor]:
|
|
5353
|
-
[X.Youtube]:
|
|
5354
|
-
[X.SagePub]:
|
|
5355
|
-
[X.SageVideo]:
|
|
5356
|
-
[X.ScienceDirect]:
|
|
5357
|
-
[X.Springer]:
|
|
5358
|
-
[X.TaylorFrancis]:
|
|
5359
|
-
[X.Wiley]:
|
|
5360
|
-
[X.VuFind]:
|
|
5361
|
-
[X.ClinicalKey]:
|
|
5362
|
-
[X.DOAJ]:
|
|
5363
|
-
[X.Primo]:
|
|
5364
|
-
[X.IngentaConnect]:
|
|
5365
|
-
[X.Ebscohost]:
|
|
5366
|
-
[X.OpenStax]:
|
|
5367
|
-
[X.OpenTextbook]:
|
|
5368
|
-
[X.Milne]:
|
|
5369
|
-
[X.CambridgeJournalsOnline]:
|
|
5370
|
-
[X.AhaJournals]:
|
|
5371
|
-
[X.Ijees]:
|
|
5372
|
-
[X.BloomsburyCollections]:
|
|
5373
|
-
[X.HeritageCirqa]:
|
|
5374
|
-
[X.BritishMedicalJournal]:
|
|
5375
|
-
[X.SummonSearchResult]:
|
|
5376
|
-
[X.ApplePodcasts]:
|
|
5377
|
-
[X.Arxiv]:
|
|
5378
|
-
[X.KanopyVideo]:
|
|
5379
|
-
[X.LaTrobeOpal]:
|
|
5483
|
+
[X.CupOfJo]: cc,
|
|
5484
|
+
[X.Jstor]: Bu,
|
|
5485
|
+
[X.Youtube]: al,
|
|
5486
|
+
[X.SagePub]: Ec,
|
|
5487
|
+
[X.SageVideo]: ru,
|
|
5488
|
+
[X.ScienceDirect]: Lc,
|
|
5489
|
+
[X.Springer]: Nl,
|
|
5490
|
+
[X.TaylorFrancis]: Wc,
|
|
5491
|
+
[X.Wiley]: tu,
|
|
5492
|
+
[X.VuFind]: tl,
|
|
5493
|
+
[X.ClinicalKey]: Ys,
|
|
5494
|
+
[X.DOAJ]: hc,
|
|
5495
|
+
[X.Primo]: kd,
|
|
5496
|
+
[X.IngentaConnect]: Rd,
|
|
5497
|
+
[X.Ebscohost]: lf,
|
|
5498
|
+
[X.OpenStax]: pf,
|
|
5499
|
+
[X.OpenTextbook]: gf,
|
|
5500
|
+
[X.Milne]: yf,
|
|
5501
|
+
[X.CambridgeJournalsOnline]: bf,
|
|
5502
|
+
[X.AhaJournals]: Pf,
|
|
5503
|
+
[X.Ijees]: Rf,
|
|
5504
|
+
[X.BloomsburyCollections]: ep,
|
|
5505
|
+
[X.HeritageCirqa]: ip,
|
|
5506
|
+
[X.BritishMedicalJournal]: cp,
|
|
5507
|
+
[X.SummonSearchResult]: lp,
|
|
5508
|
+
[X.ApplePodcasts]: hp,
|
|
5509
|
+
[X.Arxiv]: vp,
|
|
5510
|
+
[X.KanopyVideo]: xp,
|
|
5511
|
+
[X.LaTrobeOpal]: Dp,
|
|
5380
5512
|
[X.BYUScholarsArchive]: Ds,
|
|
5381
|
-
[X.Informit]:
|
|
5382
|
-
[X.Brill]:
|
|
5383
|
-
[X.HeinOnline]:
|
|
5384
|
-
[X.PrimoNde]:
|
|
5385
|
-
[X.MichiganLaw]:
|
|
5386
|
-
[X.EbookCentral]:
|
|
5387
|
-
[X.AlexanderStreetPress]:
|
|
5388
|
-
[X.LondonReviewOfBooks]:
|
|
5389
|
-
[X.VitalSource]:
|
|
5390
|
-
[X.Icono14]:
|
|
5391
|
-
|
|
5513
|
+
[X.Informit]: Vp,
|
|
5514
|
+
[X.Brill]: am,
|
|
5515
|
+
[X.HeinOnline]: sm,
|
|
5516
|
+
[X.PrimoNde]: vm,
|
|
5517
|
+
[X.MichiganLaw]: bm,
|
|
5518
|
+
[X.EbookCentral]: Dm,
|
|
5519
|
+
[X.AlexanderStreetPress]: jm,
|
|
5520
|
+
[X.LondonReviewOfBooks]: Km,
|
|
5521
|
+
[X.VitalSource]: Xm,
|
|
5522
|
+
[X.Icono14]: Qm,
|
|
5523
|
+
[X.EbscoLocate]: ng
|
|
5524
|
+
}, ig = "5.46.0", ag = () => ig, og = [
|
|
5392
5525
|
"com.au",
|
|
5393
5526
|
"com",
|
|
5394
5527
|
"ca",
|
|
@@ -5396,8 +5529,8 @@ var Sp = (e) => {
|
|
|
5396
5529
|
"de",
|
|
5397
5530
|
"fr",
|
|
5398
5531
|
"nl"
|
|
5399
|
-
].flatMap((e) => [`amazon.${e}`, `www.amazon.${e}`]),
|
|
5400
|
-
version:
|
|
5532
|
+
].flatMap((e) => [`amazon.${e}`, `www.amazon.${e}`]), sg = {
|
|
5533
|
+
version: ag(),
|
|
5401
5534
|
siteRegistrations: [
|
|
5402
5535
|
{
|
|
5403
5536
|
matcher: { regexp: "^https://[a-z0-9\\-]+\\.on\\.worldcat\\.org/search" },
|
|
@@ -5425,7 +5558,7 @@ var Sp = (e) => {
|
|
|
5425
5558
|
parsers: [X.ScienceDirect]
|
|
5426
5559
|
},
|
|
5427
5560
|
{
|
|
5428
|
-
matcher: { hostnames:
|
|
5561
|
+
matcher: { hostnames: og },
|
|
5429
5562
|
name: "Amazon",
|
|
5430
5563
|
parsers: [X.Amazon]
|
|
5431
5564
|
},
|
|
@@ -5628,20 +5761,25 @@ var Sp = (e) => {
|
|
|
5628
5761
|
matcher: { regexp: "^https://bookshelf-ref[.-]vitalsource[.-]com/reader/books" },
|
|
5629
5762
|
name: "Vital Source Bookshelf",
|
|
5630
5763
|
parsers: [X.VitalSource]
|
|
5764
|
+
},
|
|
5765
|
+
{
|
|
5766
|
+
matcher: { regexp: "locate[.-]ebsco[.-]com/instances/" },
|
|
5767
|
+
name: "EBSCO Locate",
|
|
5768
|
+
parsers: [X.EbscoLocate]
|
|
5631
5769
|
}
|
|
5632
5770
|
]
|
|
5633
|
-
},
|
|
5634
|
-
matcher:
|
|
5771
|
+
}, cg = j({ hostnames: A(O()).min(1) }), lg = j({ regexp: O() }), ug = M([cg, lg]), dg = j({
|
|
5772
|
+
matcher: ug,
|
|
5635
5773
|
name: O(),
|
|
5636
5774
|
parsers: A(O()),
|
|
5637
5775
|
libraryVersionRange: O().optional()
|
|
5638
|
-
}),
|
|
5639
|
-
siteRegistrations: A(
|
|
5776
|
+
}), fg = j({
|
|
5777
|
+
siteRegistrations: A(dg),
|
|
5640
5778
|
version: O()
|
|
5641
|
-
}),
|
|
5779
|
+
}), pg = (e) => fg.safeParse(e).success, mg = (e) => dg.safeParse(e).success, hg = (e) => ug.safeParse(e).success, gg = (e) => Object.values(X).includes(e), _g = j({
|
|
5642
5780
|
url: O(),
|
|
5643
5781
|
document: eo((e) => typeof e == "object" && !!e)
|
|
5644
|
-
}),
|
|
5782
|
+
}), vg = (e) => _g.safeParse(e).success, yg = /* @__PURE__ */ e(((e, t) => {
|
|
5645
5783
|
var n = "2.0.0", r = 256;
|
|
5646
5784
|
t.exports = {
|
|
5647
5785
|
MAX_LENGTH: r,
|
|
@@ -5661,10 +5799,10 @@ var Sp = (e) => {
|
|
|
5661
5799
|
FLAG_INCLUDE_PRERELEASE: 1,
|
|
5662
5800
|
FLAG_LOOSE: 2
|
|
5663
5801
|
};
|
|
5664
|
-
})),
|
|
5802
|
+
})), bg = /* @__PURE__ */ e(((e, t) => {
|
|
5665
5803
|
t.exports = typeof process == "object" && process.env && process.env.NODE_DEBUG && /\bsemver\b/i.test(process.env.NODE_DEBUG) ? (...e) => console.error("SEMVER", ...e) : () => {};
|
|
5666
|
-
})),
|
|
5667
|
-
var { MAX_SAFE_COMPONENT_LENGTH: n, MAX_SAFE_BUILD_LENGTH: r, MAX_LENGTH: i } =
|
|
5804
|
+
})), xg = /* @__PURE__ */ e(((e, t) => {
|
|
5805
|
+
var { MAX_SAFE_COMPONENT_LENGTH: n, MAX_SAFE_BUILD_LENGTH: r, MAX_LENGTH: i } = yg(), a = bg();
|
|
5668
5806
|
e = t.exports = {};
|
|
5669
5807
|
var o = e.re = [], s = e.safeRe = [], c = e.src = [], l = e.safeSrc = [], u = e.t = {}, d = 0, f = "[a-zA-Z0-9-]", p = [
|
|
5670
5808
|
["\\s", 1],
|
|
@@ -5678,10 +5816,10 @@ var Sp = (e) => {
|
|
|
5678
5816
|
a(e, i, t), u[e] = i, c[i] = t, l[i] = r, o[i] = new RegExp(t, n ? "g" : void 0), s[i] = new RegExp(r, n ? "g" : void 0);
|
|
5679
5817
|
};
|
|
5680
5818
|
h("NUMERICIDENTIFIER", "0|[1-9]\\d*"), h("NUMERICIDENTIFIERLOOSE", "\\d+"), h("NONNUMERICIDENTIFIER", `\\d*[a-zA-Z-]${f}*`), h("MAINVERSION", `(${c[u.NUMERICIDENTIFIER]})\\.(${c[u.NUMERICIDENTIFIER]})\\.(${c[u.NUMERICIDENTIFIER]})`), h("MAINVERSIONLOOSE", `(${c[u.NUMERICIDENTIFIERLOOSE]})\\.(${c[u.NUMERICIDENTIFIERLOOSE]})\\.(${c[u.NUMERICIDENTIFIERLOOSE]})`), h("PRERELEASEIDENTIFIER", `(?:${c[u.NONNUMERICIDENTIFIER]}|${c[u.NUMERICIDENTIFIER]})`), h("PRERELEASEIDENTIFIERLOOSE", `(?:${c[u.NONNUMERICIDENTIFIER]}|${c[u.NUMERICIDENTIFIERLOOSE]})`), h("PRERELEASE", `(?:-(${c[u.PRERELEASEIDENTIFIER]}(?:\\.${c[u.PRERELEASEIDENTIFIER]})*))`), h("PRERELEASELOOSE", `(?:-?(${c[u.PRERELEASEIDENTIFIERLOOSE]}(?:\\.${c[u.PRERELEASEIDENTIFIERLOOSE]})*))`), h("BUILDIDENTIFIER", `${f}+`), h("BUILD", `(?:\\+(${c[u.BUILDIDENTIFIER]}(?:\\.${c[u.BUILDIDENTIFIER]})*))`), h("FULLPLAIN", `v?${c[u.MAINVERSION]}${c[u.PRERELEASE]}?${c[u.BUILD]}?`), h("FULL", `^${c[u.FULLPLAIN]}$`), h("LOOSEPLAIN", `[v=\\s]*${c[u.MAINVERSIONLOOSE]}${c[u.PRERELEASELOOSE]}?${c[u.BUILD]}?`), h("LOOSE", `^${c[u.LOOSEPLAIN]}$`), h("GTLT", "((?:<|>)?=?)"), h("XRANGEIDENTIFIERLOOSE", `${c[u.NUMERICIDENTIFIERLOOSE]}|x|X|\\*`), h("XRANGEIDENTIFIER", `${c[u.NUMERICIDENTIFIER]}|x|X|\\*`), h("XRANGEPLAIN", `[v=\\s]*(${c[u.XRANGEIDENTIFIER]})(?:\\.(${c[u.XRANGEIDENTIFIER]})(?:\\.(${c[u.XRANGEIDENTIFIER]})(?:${c[u.PRERELEASE]})?${c[u.BUILD]}?)?)?`), h("XRANGEPLAINLOOSE", `[v=\\s]*(${c[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[u.XRANGEIDENTIFIERLOOSE]})(?:\\.(${c[u.XRANGEIDENTIFIERLOOSE]})(?:${c[u.PRERELEASELOOSE]})?${c[u.BUILD]}?)?)?`), h("XRANGE", `^${c[u.GTLT]}\\s*${c[u.XRANGEPLAIN]}$`), h("XRANGELOOSE", `^${c[u.GTLT]}\\s*${c[u.XRANGEPLAINLOOSE]}$`), h("COERCEPLAIN", `(^|[^\\d])(\\d{1,${n}})(?:\\.(\\d{1,${n}}))?(?:\\.(\\d{1,${n}}))?`), h("COERCE", `${c[u.COERCEPLAIN]}(?:$|[^\\d])`), h("COERCEFULL", c[u.COERCEPLAIN] + `(?:${c[u.PRERELEASE]})?(?:${c[u.BUILD]})?(?:$|[^\\d])`), h("COERCERTL", c[u.COERCE], !0), h("COERCERTLFULL", c[u.COERCEFULL], !0), h("LONETILDE", "(?:~>?)"), h("TILDETRIM", `(\\s*)${c[u.LONETILDE]}\\s+`, !0), e.tildeTrimReplace = "$1~", h("TILDE", `^${c[u.LONETILDE]}${c[u.XRANGEPLAIN]}$`), h("TILDELOOSE", `^${c[u.LONETILDE]}${c[u.XRANGEPLAINLOOSE]}$`), h("LONECARET", "(?:\\^)"), h("CARETTRIM", `(\\s*)${c[u.LONECARET]}\\s+`, !0), e.caretTrimReplace = "$1^", h("CARET", `^${c[u.LONECARET]}${c[u.XRANGEPLAIN]}$`), h("CARETLOOSE", `^${c[u.LONECARET]}${c[u.XRANGEPLAINLOOSE]}$`), h("COMPARATORLOOSE", `^${c[u.GTLT]}\\s*(${c[u.LOOSEPLAIN]})$|^$`), h("COMPARATOR", `^${c[u.GTLT]}\\s*(${c[u.FULLPLAIN]})$|^$`), h("COMPARATORTRIM", `(\\s*)${c[u.GTLT]}\\s*(${c[u.LOOSEPLAIN]}|${c[u.XRANGEPLAIN]})`, !0), e.comparatorTrimReplace = "$1$2$3", h("HYPHENRANGE", `^\\s*(${c[u.XRANGEPLAIN]})\\s+-\\s+(${c[u.XRANGEPLAIN]})\\s*$`), h("HYPHENRANGELOOSE", `^\\s*(${c[u.XRANGEPLAINLOOSE]})\\s+-\\s+(${c[u.XRANGEPLAINLOOSE]})\\s*$`), h("STAR", "(<|>)?=?\\s*\\*"), h("GTE0", "^\\s*>=\\s*0\\.0\\.0\\s*$"), h("GTE0PRE", "^\\s*>=\\s*0\\.0\\.0-0\\s*$");
|
|
5681
|
-
})),
|
|
5819
|
+
})), Sg = /* @__PURE__ */ e(((e, t) => {
|
|
5682
5820
|
var n = Object.freeze({ loose: !0 }), r = Object.freeze({});
|
|
5683
5821
|
t.exports = (e) => e ? typeof e == "object" ? e : n : r;
|
|
5684
|
-
})),
|
|
5822
|
+
})), Cg = /* @__PURE__ */ e(((e, t) => {
|
|
5685
5823
|
var n = /^[0-9]+$/, r = (e, t) => {
|
|
5686
5824
|
if (typeof e == "number" && typeof t == "number") return e === t ? 0 : e < t ? -1 : 1;
|
|
5687
5825
|
let r = n.test(e), i = n.test(t);
|
|
@@ -5692,7 +5830,7 @@ var Sp = (e) => {
|
|
|
5692
5830
|
rcompareIdentifiers: (e, t) => r(t, e)
|
|
5693
5831
|
};
|
|
5694
5832
|
})), Z = /* @__PURE__ */ e(((e, t) => {
|
|
5695
|
-
var n =
|
|
5833
|
+
var n = bg(), { MAX_LENGTH: r, MAX_SAFE_INTEGER: i } = yg(), { safeRe: a, t: o } = xg(), s = Sg(), { compareIdentifiers: c } = Cg();
|
|
5696
5834
|
t.exports = class e {
|
|
5697
5835
|
constructor(t, c) {
|
|
5698
5836
|
if (c = s(c), t instanceof e) {
|
|
@@ -5812,7 +5950,7 @@ var Sp = (e) => {
|
|
|
5812
5950
|
return this.raw = this.format(), this.build.length && (this.raw += `+${this.build.join(".")}`), this;
|
|
5813
5951
|
}
|
|
5814
5952
|
};
|
|
5815
|
-
})),
|
|
5953
|
+
})), wg = /* @__PURE__ */ e(((e, t) => {
|
|
5816
5954
|
var n = Z();
|
|
5817
5955
|
t.exports = (e, t, r = !1) => {
|
|
5818
5956
|
if (e instanceof n) return e;
|
|
@@ -5823,19 +5961,19 @@ var Sp = (e) => {
|
|
|
5823
5961
|
throw e;
|
|
5824
5962
|
}
|
|
5825
5963
|
};
|
|
5826
|
-
})),
|
|
5827
|
-
var n =
|
|
5964
|
+
})), Tg = /* @__PURE__ */ e(((e, t) => {
|
|
5965
|
+
var n = wg();
|
|
5828
5966
|
t.exports = (e, t) => {
|
|
5829
5967
|
let r = n(e, t);
|
|
5830
5968
|
return r ? r.version : null;
|
|
5831
5969
|
};
|
|
5832
|
-
})),
|
|
5833
|
-
var n =
|
|
5970
|
+
})), Eg = /* @__PURE__ */ e(((e, t) => {
|
|
5971
|
+
var n = wg();
|
|
5834
5972
|
t.exports = (e, t) => {
|
|
5835
5973
|
let r = n(e.trim().replace(/^[=v]+/, ""), t);
|
|
5836
5974
|
return r ? r.version : null;
|
|
5837
5975
|
};
|
|
5838
|
-
})),
|
|
5976
|
+
})), Dg = /* @__PURE__ */ e(((e, t) => {
|
|
5839
5977
|
var n = Z();
|
|
5840
5978
|
t.exports = (e, t, r, i, a) => {
|
|
5841
5979
|
typeof r == "string" && (a = i, i = r, r = void 0);
|
|
@@ -5845,8 +5983,8 @@ var Sp = (e) => {
|
|
|
5845
5983
|
return null;
|
|
5846
5984
|
}
|
|
5847
5985
|
};
|
|
5848
|
-
})),
|
|
5849
|
-
var n =
|
|
5986
|
+
})), Og = /* @__PURE__ */ e(((e, t) => {
|
|
5987
|
+
var n = wg();
|
|
5850
5988
|
t.exports = (e, t) => {
|
|
5851
5989
|
let r = n(e, null, !0), i = n(t, null, !0), a = r.compare(i);
|
|
5852
5990
|
if (a === 0) return null;
|
|
@@ -5858,17 +5996,17 @@ var Sp = (e) => {
|
|
|
5858
5996
|
let u = l ? "pre" : "";
|
|
5859
5997
|
return r.major === i.major ? r.minor === i.minor ? r.patch === i.patch ? "prerelease" : u + "patch" : u + "minor" : u + "major";
|
|
5860
5998
|
};
|
|
5861
|
-
})),
|
|
5999
|
+
})), kg = /* @__PURE__ */ e(((e, t) => {
|
|
5862
6000
|
var n = Z();
|
|
5863
6001
|
t.exports = (e, t) => new n(e, t).major;
|
|
5864
|
-
})),
|
|
6002
|
+
})), Ag = /* @__PURE__ */ e(((e, t) => {
|
|
5865
6003
|
var n = Z();
|
|
5866
6004
|
t.exports = (e, t) => new n(e, t).minor;
|
|
5867
|
-
})),
|
|
6005
|
+
})), jg = /* @__PURE__ */ e(((e, t) => {
|
|
5868
6006
|
var n = Z();
|
|
5869
6007
|
t.exports = (e, t) => new n(e, t).patch;
|
|
5870
|
-
})),
|
|
5871
|
-
var n =
|
|
6008
|
+
})), Mg = /* @__PURE__ */ e(((e, t) => {
|
|
6009
|
+
var n = wg();
|
|
5872
6010
|
t.exports = (e, t) => {
|
|
5873
6011
|
let r = n(e, t);
|
|
5874
6012
|
return r && r.prerelease.length ? r.prerelease : null;
|
|
@@ -5876,44 +6014,44 @@ var Sp = (e) => {
|
|
|
5876
6014
|
})), Q = /* @__PURE__ */ e(((e, t) => {
|
|
5877
6015
|
var n = Z();
|
|
5878
6016
|
t.exports = (e, t, r) => new n(e, r).compare(new n(t, r));
|
|
5879
|
-
})),
|
|
6017
|
+
})), Ng = /* @__PURE__ */ e(((e, t) => {
|
|
5880
6018
|
var n = Q();
|
|
5881
6019
|
t.exports = (e, t, r) => n(t, e, r);
|
|
5882
|
-
})),
|
|
6020
|
+
})), Pg = /* @__PURE__ */ e(((e, t) => {
|
|
5883
6021
|
var n = Q();
|
|
5884
6022
|
t.exports = (e, t) => n(e, t, !0);
|
|
5885
|
-
})),
|
|
6023
|
+
})), Fg = /* @__PURE__ */ e(((e, t) => {
|
|
5886
6024
|
var n = Z();
|
|
5887
6025
|
t.exports = (e, t, r) => {
|
|
5888
6026
|
let i = new n(e, r), a = new n(t, r);
|
|
5889
6027
|
return i.compare(a) || i.compareBuild(a);
|
|
5890
6028
|
};
|
|
5891
|
-
})),
|
|
5892
|
-
var n =
|
|
6029
|
+
})), Ig = /* @__PURE__ */ e(((e, t) => {
|
|
6030
|
+
var n = Fg();
|
|
5893
6031
|
t.exports = (e, t) => e.sort((e, r) => n(e, r, t));
|
|
5894
|
-
})),
|
|
5895
|
-
var n =
|
|
6032
|
+
})), Lg = /* @__PURE__ */ e(((e, t) => {
|
|
6033
|
+
var n = Fg();
|
|
5896
6034
|
t.exports = (e, t) => e.sort((e, r) => n(r, e, t));
|
|
5897
|
-
})),
|
|
6035
|
+
})), Rg = /* @__PURE__ */ e(((e, t) => {
|
|
5898
6036
|
var n = Q();
|
|
5899
6037
|
t.exports = (e, t, r) => n(e, t, r) > 0;
|
|
5900
|
-
})),
|
|
6038
|
+
})), zg = /* @__PURE__ */ e(((e, t) => {
|
|
5901
6039
|
var n = Q();
|
|
5902
6040
|
t.exports = (e, t, r) => n(e, t, r) < 0;
|
|
5903
|
-
})),
|
|
6041
|
+
})), Bg = /* @__PURE__ */ e(((e, t) => {
|
|
5904
6042
|
var n = Q();
|
|
5905
6043
|
t.exports = (e, t, r) => n(e, t, r) === 0;
|
|
5906
|
-
})),
|
|
6044
|
+
})), Vg = /* @__PURE__ */ e(((e, t) => {
|
|
5907
6045
|
var n = Q();
|
|
5908
6046
|
t.exports = (e, t, r) => n(e, t, r) !== 0;
|
|
5909
|
-
})),
|
|
6047
|
+
})), Hg = /* @__PURE__ */ e(((e, t) => {
|
|
5910
6048
|
var n = Q();
|
|
5911
6049
|
t.exports = (e, t, r) => n(e, t, r) >= 0;
|
|
5912
|
-
})),
|
|
6050
|
+
})), Ug = /* @__PURE__ */ e(((e, t) => {
|
|
5913
6051
|
var n = Q();
|
|
5914
6052
|
t.exports = (e, t, r) => n(e, t, r) <= 0;
|
|
5915
|
-
})),
|
|
5916
|
-
var n =
|
|
6053
|
+
})), Wg = /* @__PURE__ */ e(((e, t) => {
|
|
6054
|
+
var n = Bg(), r = Vg(), i = Rg(), a = Hg(), o = zg(), s = Ug();
|
|
5917
6055
|
t.exports = (e, t, c, l) => {
|
|
5918
6056
|
switch (t) {
|
|
5919
6057
|
case "===": return typeof e == "object" && (e = e.version), typeof c == "object" && (c = c.version), e === c;
|
|
@@ -5929,8 +6067,8 @@ var Sp = (e) => {
|
|
|
5929
6067
|
default: throw TypeError(`Invalid operator: ${t}`);
|
|
5930
6068
|
}
|
|
5931
6069
|
};
|
|
5932
|
-
})),
|
|
5933
|
-
var n = Z(), r =
|
|
6070
|
+
})), Gg = /* @__PURE__ */ e(((e, t) => {
|
|
6071
|
+
var n = Z(), r = wg(), { safeRe: i, t: a } = xg();
|
|
5934
6072
|
t.exports = (e, t) => {
|
|
5935
6073
|
if (e instanceof n) return e;
|
|
5936
6074
|
if (typeof e == "number" && (e = String(e)), typeof e != "string") return null;
|
|
@@ -5946,7 +6084,7 @@ var Sp = (e) => {
|
|
|
5946
6084
|
let s = o[2];
|
|
5947
6085
|
return r(`${s}.${o[3] || "0"}.${o[4] || "0"}${t.includePrerelease && o[5] ? `-${o[5]}` : ""}${t.includePrerelease && o[6] ? `+${o[6]}` : ""}`, t);
|
|
5948
6086
|
};
|
|
5949
|
-
})),
|
|
6087
|
+
})), Kg = /* @__PURE__ */ e(((e, t) => {
|
|
5950
6088
|
t.exports = class {
|
|
5951
6089
|
constructor() {
|
|
5952
6090
|
this.max = 1e3, this.map = /* @__PURE__ */ new Map();
|
|
@@ -6036,7 +6174,7 @@ var Sp = (e) => {
|
|
|
6036
6174
|
return !1;
|
|
6037
6175
|
}
|
|
6038
6176
|
};
|
|
6039
|
-
var r = new (
|
|
6177
|
+
var r = new (Kg())(), i = Sg(), a = qg(), o = bg(), s = Z(), { safeRe: c, t: l, comparatorTrimReplace: u, tildeTrimReplace: d, caretTrimReplace: f } = xg(), { FLAG_INCLUDE_PRERELEASE: p, FLAG_LOOSE: m } = yg(), h = (e) => e.value === "<0.0.0-0", g = (e) => e.value === "", _ = (e, t) => {
|
|
6040
6178
|
let n = !0, r = e.slice(), i = r.pop();
|
|
6041
6179
|
for (; n && r.length;) n = r.every((e) => i.intersects(e, t)), i = r.pop();
|
|
6042
6180
|
return n;
|
|
@@ -6074,7 +6212,7 @@ var Sp = (e) => {
|
|
|
6074
6212
|
}
|
|
6075
6213
|
return !0;
|
|
6076
6214
|
};
|
|
6077
|
-
})),
|
|
6215
|
+
})), qg = /* @__PURE__ */ e(((e, t) => {
|
|
6078
6216
|
var n = Symbol("SemVer ANY");
|
|
6079
6217
|
t.exports = class e {
|
|
6080
6218
|
static get ANY() {
|
|
@@ -6109,8 +6247,8 @@ var Sp = (e) => {
|
|
|
6109
6247
|
return this.operator === "" ? this.value === "" ? !0 : new l(t.value, n).test(this.value) : t.operator === "" ? t.value === "" ? !0 : new l(this.value, n).test(t.semver) : (n = r(n), n.includePrerelease && (this.value === "<0.0.0-0" || t.value === "<0.0.0-0") || !n.includePrerelease && (this.value.startsWith("<0.0.0") || t.value.startsWith("<0.0.0")) ? !1 : !!(this.operator.startsWith(">") && t.operator.startsWith(">") || this.operator.startsWith("<") && t.operator.startsWith("<") || this.semver.version === t.semver.version && this.operator.includes("=") && t.operator.includes("=") || o(this.semver, "<", t.semver, n) && this.operator.startsWith(">") && t.operator.startsWith("<") || o(this.semver, ">", t.semver, n) && this.operator.startsWith("<") && t.operator.startsWith(">")));
|
|
6110
6248
|
}
|
|
6111
6249
|
};
|
|
6112
|
-
var r =
|
|
6113
|
-
})),
|
|
6250
|
+
var r = Sg(), { safeRe: i, t: a } = xg(), o = Wg(), s = bg(), c = Z(), l = $();
|
|
6251
|
+
})), Jg = /* @__PURE__ */ e(((e, t) => {
|
|
6114
6252
|
var n = $();
|
|
6115
6253
|
t.exports = (e, t, r) => {
|
|
6116
6254
|
try {
|
|
@@ -6120,10 +6258,10 @@ var Sp = (e) => {
|
|
|
6120
6258
|
}
|
|
6121
6259
|
return t.test(e);
|
|
6122
6260
|
};
|
|
6123
|
-
})),
|
|
6261
|
+
})), Yg = /* @__PURE__ */ e(((e, t) => {
|
|
6124
6262
|
var n = $();
|
|
6125
6263
|
t.exports = (e, t) => new n(e, t).set.map((e) => e.map((e) => e.value).join(" ").trim().split(" "));
|
|
6126
|
-
})),
|
|
6264
|
+
})), Xg = /* @__PURE__ */ e(((e, t) => {
|
|
6127
6265
|
var n = Z(), r = $();
|
|
6128
6266
|
t.exports = (e, t, i) => {
|
|
6129
6267
|
let a = null, o = null, s = null;
|
|
@@ -6136,7 +6274,7 @@ var Sp = (e) => {
|
|
|
6136
6274
|
s.test(e) && (!a || o.compare(e) === -1) && (a = e, o = new n(a, i));
|
|
6137
6275
|
}), a;
|
|
6138
6276
|
};
|
|
6139
|
-
})),
|
|
6277
|
+
})), Zg = /* @__PURE__ */ e(((e, t) => {
|
|
6140
6278
|
var n = Z(), r = $();
|
|
6141
6279
|
t.exports = (e, t, i) => {
|
|
6142
6280
|
let a = null, o = null, s = null;
|
|
@@ -6149,8 +6287,8 @@ var Sp = (e) => {
|
|
|
6149
6287
|
s.test(e) && (!a || o.compare(e) === 1) && (a = e, o = new n(a, i));
|
|
6150
6288
|
}), a;
|
|
6151
6289
|
};
|
|
6152
|
-
})),
|
|
6153
|
-
var n = Z(), r = $(), i =
|
|
6290
|
+
})), Qg = /* @__PURE__ */ e(((e, t) => {
|
|
6291
|
+
var n = Z(), r = $(), i = Rg();
|
|
6154
6292
|
t.exports = (e, t) => {
|
|
6155
6293
|
e = new r(e, t);
|
|
6156
6294
|
let a = new n("0.0.0");
|
|
@@ -6174,7 +6312,7 @@ var Sp = (e) => {
|
|
|
6174
6312
|
}
|
|
6175
6313
|
return a && e.test(a) ? a : null;
|
|
6176
6314
|
};
|
|
6177
|
-
})),
|
|
6315
|
+
})), $g = /* @__PURE__ */ e(((e, t) => {
|
|
6178
6316
|
var n = $();
|
|
6179
6317
|
t.exports = (e, t) => {
|
|
6180
6318
|
try {
|
|
@@ -6183,8 +6321,8 @@ var Sp = (e) => {
|
|
|
6183
6321
|
return null;
|
|
6184
6322
|
}
|
|
6185
6323
|
};
|
|
6186
|
-
})),
|
|
6187
|
-
var n = Z(), r =
|
|
6324
|
+
})), e_ = /* @__PURE__ */ e(((e, t) => {
|
|
6325
|
+
var n = Z(), r = qg(), { ANY: i } = r, a = $(), o = Jg(), s = Rg(), c = zg(), l = Ug(), u = Hg();
|
|
6188
6326
|
t.exports = (e, t, d, f) => {
|
|
6189
6327
|
e = new n(e, f), t = new a(t, f);
|
|
6190
6328
|
let p, m, h, g, _;
|
|
@@ -6206,17 +6344,17 @@ var Sp = (e) => {
|
|
|
6206
6344
|
}
|
|
6207
6345
|
return !0;
|
|
6208
6346
|
};
|
|
6209
|
-
})),
|
|
6210
|
-
var n =
|
|
6347
|
+
})), t_ = /* @__PURE__ */ e(((e, t) => {
|
|
6348
|
+
var n = e_();
|
|
6211
6349
|
t.exports = (e, t, r) => n(e, t, ">", r);
|
|
6212
|
-
})),
|
|
6213
|
-
var n =
|
|
6350
|
+
})), n_ = /* @__PURE__ */ e(((e, t) => {
|
|
6351
|
+
var n = e_();
|
|
6214
6352
|
t.exports = (e, t, r) => n(e, t, "<", r);
|
|
6215
|
-
})),
|
|
6353
|
+
})), r_ = /* @__PURE__ */ e(((e, t) => {
|
|
6216
6354
|
var n = $();
|
|
6217
6355
|
t.exports = (e, t, r) => (e = new n(e, r), t = new n(t, r), e.intersects(t, r));
|
|
6218
|
-
})),
|
|
6219
|
-
var n =
|
|
6356
|
+
})), i_ = /* @__PURE__ */ e(((e, t) => {
|
|
6357
|
+
var n = Jg(), r = Q();
|
|
6220
6358
|
t.exports = (e, t, i) => {
|
|
6221
6359
|
let a = [], o = null, s = null, c = e.sort((e, t) => r(e, t, i));
|
|
6222
6360
|
for (let e of c) n(e, t, i) ? (s = e, o ||= e) : (s && a.push([o, s]), s = null, o = null);
|
|
@@ -6226,8 +6364,8 @@ var Sp = (e) => {
|
|
|
6226
6364
|
let u = l.join(" || "), d = typeof t.raw == "string" ? t.raw : String(t);
|
|
6227
6365
|
return u.length < d.length ? u : t;
|
|
6228
6366
|
};
|
|
6229
|
-
})),
|
|
6230
|
-
var n = $(), r =
|
|
6367
|
+
})), a_ = /* @__PURE__ */ e(((e, t) => {
|
|
6368
|
+
var n = $(), r = qg(), { ANY: i } = r, a = Jg(), o = Q(), s = (e, t, r = {}) => {
|
|
6231
6369
|
if (e === t) return !0;
|
|
6232
6370
|
e = new n(e, r), t = new n(t, r);
|
|
6233
6371
|
let i = !1;
|
|
@@ -6285,46 +6423,46 @@ var Sp = (e) => {
|
|
|
6285
6423
|
return r < 0 ? e : r > 0 || t.operator === "<" && e.operator === "<=" ? t : e;
|
|
6286
6424
|
};
|
|
6287
6425
|
t.exports = s;
|
|
6288
|
-
})),
|
|
6289
|
-
var n =
|
|
6426
|
+
})), o_ = (/* @__PURE__ */ e(((e, t) => {
|
|
6427
|
+
var n = xg(), r = yg(), i = Z(), a = Cg();
|
|
6290
6428
|
t.exports = {
|
|
6291
|
-
parse:
|
|
6292
|
-
valid:
|
|
6293
|
-
clean:
|
|
6294
|
-
inc:
|
|
6295
|
-
diff:
|
|
6296
|
-
major:
|
|
6297
|
-
minor:
|
|
6298
|
-
patch:
|
|
6299
|
-
prerelease:
|
|
6429
|
+
parse: wg(),
|
|
6430
|
+
valid: Tg(),
|
|
6431
|
+
clean: Eg(),
|
|
6432
|
+
inc: Dg(),
|
|
6433
|
+
diff: Og(),
|
|
6434
|
+
major: kg(),
|
|
6435
|
+
minor: Ag(),
|
|
6436
|
+
patch: jg(),
|
|
6437
|
+
prerelease: Mg(),
|
|
6300
6438
|
compare: Q(),
|
|
6301
|
-
rcompare:
|
|
6302
|
-
compareLoose:
|
|
6303
|
-
compareBuild:
|
|
6304
|
-
sort:
|
|
6305
|
-
rsort:
|
|
6306
|
-
gt:
|
|
6307
|
-
lt:
|
|
6308
|
-
eq:
|
|
6309
|
-
neq:
|
|
6310
|
-
gte:
|
|
6311
|
-
lte:
|
|
6312
|
-
cmp:
|
|
6313
|
-
coerce:
|
|
6314
|
-
Comparator:
|
|
6439
|
+
rcompare: Ng(),
|
|
6440
|
+
compareLoose: Pg(),
|
|
6441
|
+
compareBuild: Fg(),
|
|
6442
|
+
sort: Ig(),
|
|
6443
|
+
rsort: Lg(),
|
|
6444
|
+
gt: Rg(),
|
|
6445
|
+
lt: zg(),
|
|
6446
|
+
eq: Bg(),
|
|
6447
|
+
neq: Vg(),
|
|
6448
|
+
gte: Hg(),
|
|
6449
|
+
lte: Ug(),
|
|
6450
|
+
cmp: Wg(),
|
|
6451
|
+
coerce: Gg(),
|
|
6452
|
+
Comparator: qg(),
|
|
6315
6453
|
Range: $(),
|
|
6316
|
-
satisfies:
|
|
6317
|
-
toComparators:
|
|
6318
|
-
maxSatisfying:
|
|
6319
|
-
minSatisfying:
|
|
6320
|
-
minVersion:
|
|
6321
|
-
validRange:
|
|
6322
|
-
outside:
|
|
6323
|
-
gtr:
|
|
6324
|
-
ltr:
|
|
6325
|
-
intersects:
|
|
6326
|
-
simplifyRange:
|
|
6327
|
-
subset:
|
|
6454
|
+
satisfies: Jg(),
|
|
6455
|
+
toComparators: Yg(),
|
|
6456
|
+
maxSatisfying: Xg(),
|
|
6457
|
+
minSatisfying: Zg(),
|
|
6458
|
+
minVersion: Qg(),
|
|
6459
|
+
validRange: $g(),
|
|
6460
|
+
outside: e_(),
|
|
6461
|
+
gtr: t_(),
|
|
6462
|
+
ltr: n_(),
|
|
6463
|
+
intersects: r_(),
|
|
6464
|
+
simplifyRange: i_(),
|
|
6465
|
+
subset: a_(),
|
|
6328
6466
|
SemVer: i,
|
|
6329
6467
|
re: n.re,
|
|
6330
6468
|
src: n.src,
|
|
@@ -6334,15 +6472,15 @@ var Sp = (e) => {
|
|
|
6334
6472
|
compareIdentifiers: a.compareIdentifiers,
|
|
6335
6473
|
rcompareIdentifiers: a.rcompareIdentifiers
|
|
6336
6474
|
};
|
|
6337
|
-
})))(),
|
|
6338
|
-
parser:
|
|
6475
|
+
})))(), s_ = (e, t) => c_(t) ? t.hostnames.includes(new URL(e).hostname) : l_(t) ? !!e.match(t.regexp) : !1, c_ = (e) => cg.safeParse(e).success, l_ = (e) => lg.safeParse(e).success, u_ = (e, t) => t ? (0, o_.satisfies)(e, t) : !0, d_ = (e, t, n) => u_(t, n.libraryVersionRange) && s_(e, n.matcher), f_ = (e, t) => e.siteRegistrations.filter((e) => d_(t, ag(), e)), p_ = (e, t) => f_(e, t).flatMap(({ parsers: e, name: t }) => e.filter((e) => gg(e) && e in rg).map((e) => ({
|
|
6476
|
+
parser: rg[e],
|
|
6339
6477
|
parserType: e,
|
|
6340
6478
|
name: t
|
|
6341
|
-
}))),
|
|
6342
|
-
let n =
|
|
6479
|
+
}))), m_ = (e, t) => {
|
|
6480
|
+
let n = p_(e, t.url);
|
|
6343
6481
|
for (let { parser: e, parserType: r, name: i } of n) {
|
|
6344
6482
|
let n = e(t);
|
|
6345
|
-
if (
|
|
6483
|
+
if (Yc(n) || Xc(n) || Zc(n)) return {
|
|
6346
6484
|
...n,
|
|
6347
6485
|
meta: {
|
|
6348
6486
|
parserName: i,
|
|
@@ -6352,26 +6490,26 @@ var Sp = (e) => {
|
|
|
6352
6490
|
};
|
|
6353
6491
|
}
|
|
6354
6492
|
return {
|
|
6355
|
-
...
|
|
6493
|
+
...lc(t),
|
|
6356
6494
|
meta: {
|
|
6357
6495
|
parserName: null,
|
|
6358
6496
|
parserType: X.NoResourceFound,
|
|
6359
6497
|
referrer: t.url
|
|
6360
6498
|
}
|
|
6361
6499
|
};
|
|
6362
|
-
},
|
|
6500
|
+
}, h_ = (e, t) => {
|
|
6363
6501
|
switch (t) {
|
|
6364
6502
|
case Ao.CA: return new URL(`https://${e}.rl.ca.talis.com`);
|
|
6365
6503
|
default: return new URL(`https://${e}.rl.talis.com`);
|
|
6366
6504
|
}
|
|
6367
|
-
},
|
|
6368
|
-
let n =
|
|
6505
|
+
}, g_ = (e, t) => {
|
|
6506
|
+
let n = h_(e, t);
|
|
6369
6507
|
return new URL("/ui/forms/bookmarklet.html", n);
|
|
6370
|
-
},
|
|
6508
|
+
}, __ = (e, t, n) => {
|
|
6371
6509
|
let r = To(t);
|
|
6372
6510
|
r.append("fast", "true"), r.append("breakout", "true"), n && (n.parserName && r.append("targetTitle", n.parserName), r.append("referrer", n.referrer));
|
|
6373
6511
|
let i = new URL(e.toString());
|
|
6374
6512
|
return i.search = r.toString(), i;
|
|
6375
6513
|
};
|
|
6376
6514
|
//#endregion
|
|
6377
|
-
export { ro as BookGenresSchema, Lo as CustomerListSchema, Io as CustomerSchema, Ko as DirectLinkOnlyResultSchema, F as Genre,
|
|
6515
|
+
export { ro as BookGenresSchema, Lo as CustomerListSchema, Io as CustomerSchema, Ko as DirectLinkOnlyResultSchema, F as Genre, cg as HostnamesMatcherSchema, io as JournalGenresSchema, bo as NON_OPENURL_PROPERTIES, oo as NonOpenUrlPropertiesSchema, Go as NothingParsedResultSchema, yo as OPENURL_KEYS, lo as OpenUrlAudioVisualResourceSchema, so as OpenUrlBookResourceSchema, fo as OpenUrlDocumentResourceSchema, uo as OpenUrlImageResourceSchema, co as OpenUrlJournalResourceSchema, ao as OpenUrlResourceSchema, qo as OpenUrlResultSchema, po as OpenUrlWebpageResourceSchema, rg as PARSERS, fg as ParserRegistrySchema, X as ParserType, Wo as ParsingMetadataSchema, Po as ParsingRequestSchema, Zo as ParsingResponseSchema, Xo as ParsingResultSchema, sg as REGISTRY, lg as RegExpMatcherSchema, _g as ResourceDataSchema, mo as ResourceSchema, dg as SiteRegistrationSchema, Yo as SummonSearchResultSchema, Ao as TenantRegion, Mo as TenantRegistrySchema, jo as TenantSchema, ug as UrlMatcherSchema, Jo as Z3988SearchResultSchema, Ho as convertCustomerListToTenantRegistry, R as createAudioVisual, I as createBook, go as createDocument, ho as createImage, L as createJournal, _o as createWebpage, Qo as directLinkOnly, Do as fromOpenUrl, g_ as getBaseBookmarkingUrl, ag as getLibraryVersion, Ro as isCustomer, zo as isCustomerList, Jc as isDirectLinkOnlyResult, ko as isGenre, Qc as isNothingParsedResult, Yc as isOpenUrlResult, pg as isParserRegistry, gg as isParserType, qc as isParsingMetadata, Fo as isParsingRequest, Kc as isParsingResponse, Gc as isParsingResult, vg as isResourceData, mg as isSiteRegistration, Zc as isSummonSearchResult, Bo as isTenant, Vo as isTenantRegion, hg as isUrlMatcher, Xc as isZ3988SearchResult, z as nothingParsed, B as openUrlResource, m_ as parseResource, es as summonSearchResult, __ as toBookmarkingWorkflowUrl, To as toOpenUrl, $o as z3988SearchResult };
|