col-browser 2.3.0 → 2.3.2
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.
- package/es/chunks/{Distributions-BWucAjsL.js → Distributions-BzwnK_GR.js} +2 -2
- package/es/chunks/{Distributions-BWucAjsL.js.map → Distributions-BzwnK_GR.js.map} +1 -1
- package/es/chunks/MergedDataBadge-CdQ7RzDt.js +82 -0
- package/es/chunks/MergedDataBadge-CdQ7RzDt.js.map +1 -0
- package/es/chunks/XrGutter-CG0gAVhH.js +23 -0
- package/es/chunks/XrGutter-CG0gAVhH.js.map +1 -0
- package/es/search.js +153 -154
- package/es/search.js.map +1 -1
- package/es/sourceDatasetList.js +17 -21
- package/es/sourceDatasetList.js.map +1 -1
- package/es/taxon.js +637 -625
- package/es/taxon.js.map +1 -1
- package/es/taxonDistribution.js +1 -1
- package/es/tree.js +1 -1
- package/package.json +1 -1
- package/umd/col-browser.js +206 -235
- package/umd/col-browser.js.map +1 -1
- package/umd/col-browser.min.js +4 -4
- package/umd/col-browser.min.js.map +1 -1
- package/es/chunks/MergedDataBadge-DsTsn5Xu.js +0 -134
- package/es/chunks/MergedDataBadge-DsTsn5Xu.js.map +0 -1
package/es/taxonDistribution.js
CHANGED
|
@@ -3,7 +3,7 @@ import { j as i } from "./chunks/jsx-runtime-BzflLqGi.js";
|
|
|
3
3
|
import { useState as s, useEffect as $ } from "react";
|
|
4
4
|
import { s as D, c as l, R as T, b as g } from "./chunks/router-CssZk5qZ.js";
|
|
5
5
|
import { Row as k, Col as v, Spin as w } from "antd";
|
|
6
|
-
import { D as A } from "./chunks/Distributions-
|
|
6
|
+
import { D as A } from "./chunks/Distributions-BzwnK_GR.js";
|
|
7
7
|
const C = ({
|
|
8
8
|
taxonId: o,
|
|
9
9
|
datasetKey: n,
|
package/es/tree.js
CHANGED
|
@@ -10,7 +10,7 @@ import { sortBy as N, get as m, isUndefined as I, flatten as le, isArray as A }
|
|
|
10
10
|
import { L, c as D, R as U, s as de, b as he } from "./chunks/router-CssZk5qZ.js";
|
|
11
11
|
import T from "dataloader";
|
|
12
12
|
import { c as W, b as H, g as ce } from "./chunks/dataset-DvQG4NjA.js";
|
|
13
|
-
import { M as pe } from "./chunks/MergedDataBadge-
|
|
13
|
+
import { M as pe } from "./chunks/MergedDataBadge-CdQ7RzDt.js";
|
|
14
14
|
import { E as ue } from "./chunks/ErrorMsg-K8k5PPTp.js";
|
|
15
15
|
import { g as fe } from "./chunks/sector-BnVzMnMO.js";
|
|
16
16
|
import { C as F, N as xe } from "./chunks/DatasetCitation-bkPmDDYB.js";
|
package/package.json
CHANGED
package/umd/col-browser.js
CHANGED
|
@@ -68330,38 +68330,24 @@ html body {
|
|
|
68330
68330
|
}) => {
|
|
68331
68331
|
const [sourceDataset, setSourceDataset] = reactExports.useState(null);
|
|
68332
68332
|
const [sourceDatasetLoading, setSourceDatasetLoading] = reactExports.useState(false);
|
|
68333
|
-
const [sourceTaxon, setSourceTaxon] = reactExports.useState(null);
|
|
68334
|
-
const [sourceTaxonLoading, setSourceTaxonLoading] = reactExports.useState(null);
|
|
68335
68333
|
const [verbatimRecord, setVerbatimRecord] = reactExports.useState(null);
|
|
68336
68334
|
const [verbatimRecordLoading, setVerbatimRecordLoading] = reactExports.useState(false);
|
|
68337
68335
|
const [open2, setOpen] = reactExports.useState(false);
|
|
68336
|
+
const effectiveSourceDatasetKey = sourceDatasetKey || (verbatimRecord == null ? void 0 : verbatimRecord.sourceDatasetKey);
|
|
68337
|
+
const effectiveSourceId = sourceId || (verbatimRecord == null ? void 0 : verbatimRecord.sourceId);
|
|
68338
68338
|
reactExports.useEffect(() => {
|
|
68339
|
-
if (open2 && sourceDatasetKey && sourceId) {
|
|
68340
|
-
getSourceTaxon();
|
|
68341
|
-
}
|
|
68342
|
-
if (open2 && sourceDatasetKey) {
|
|
68343
|
-
getSourceDataset();
|
|
68344
|
-
}
|
|
68345
68339
|
if (open2 && verbatimSourceKey && !createdByAlgorithm[createdBy]) {
|
|
68346
68340
|
getVerbatimRecord();
|
|
68347
68341
|
}
|
|
68348
|
-
}, [
|
|
68349
|
-
|
|
68350
|
-
|
|
68351
|
-
|
|
68352
|
-
|
|
68353
|
-
|
|
68354
|
-
|
|
68355
|
-
}).catch((err) => {
|
|
68356
|
-
console.error("Error fetching source taxon:", err);
|
|
68357
|
-
setSourceTaxonLoading(false);
|
|
68358
|
-
setSourceTaxon(null);
|
|
68359
|
-
});
|
|
68360
|
-
};
|
|
68361
|
-
const getSourceDataset = () => {
|
|
68342
|
+
}, [verbatimSourceKey, open2]);
|
|
68343
|
+
reactExports.useEffect(() => {
|
|
68344
|
+
if (open2 && effectiveSourceDatasetKey) {
|
|
68345
|
+
getSourceDataset(effectiveSourceDatasetKey);
|
|
68346
|
+
}
|
|
68347
|
+
}, [open2, effectiveSourceDatasetKey]);
|
|
68348
|
+
const getSourceDataset = (key2) => {
|
|
68362
68349
|
setSourceDatasetLoading(true);
|
|
68363
|
-
|
|
68364
|
-
client(`${config.dataApi}dataset/${sourceDatasetKey}`).then((res) => {
|
|
68350
|
+
client(`${config.dataApi}dataset/${key2}`).then((res) => {
|
|
68365
68351
|
setSourceDatasetLoading(false);
|
|
68366
68352
|
setSourceDataset(res.data);
|
|
68367
68353
|
}).catch((err) => {
|
|
@@ -68373,7 +68359,9 @@ html body {
|
|
|
68373
68359
|
const getVerbatimRecord = () => {
|
|
68374
68360
|
setVerbatimRecordLoading(true);
|
|
68375
68361
|
setVerbatimRecord(null);
|
|
68376
|
-
client(
|
|
68362
|
+
client(
|
|
68363
|
+
`${config.dataApi}dataset/${datasetKey}/verbatimsource/${verbatimSourceKey}`
|
|
68364
|
+
).then((res) => {
|
|
68377
68365
|
setVerbatimRecordLoading(false);
|
|
68378
68366
|
setVerbatimRecord(res.data);
|
|
68379
68367
|
}).catch((err) => {
|
|
@@ -68383,95 +68371,51 @@ html body {
|
|
|
68383
68371
|
});
|
|
68384
68372
|
};
|
|
68385
68373
|
const idRef = reactExports.useRef(Math.random().toString(36).substring(2, 15));
|
|
68374
|
+
const clbEntity = ((verbatimRecord == null ? void 0 : verbatimRecord.sourceEntity) || "").toLowerCase().replace(/\s+/g, "");
|
|
68375
|
+
const clbPath = clbEntity === "reference" ? "reference" : "taxon";
|
|
68376
|
+
const sourceRecordHref = effectiveSourceId && effectiveSourceDatasetKey ? `https://www.checklistbank.org/dataset/${effectiveSourceDatasetKey}/${clbPath}/${encodeURIComponent(
|
|
68377
|
+
effectiveSourceId
|
|
68378
|
+
)}` : null;
|
|
68379
|
+
const loadingSource = sourceDatasetLoading || !!verbatimSourceKey && verbatimRecordLoading;
|
|
68380
|
+
const content = /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { style: { minWidth: "300px" }, children: [
|
|
68381
|
+
!!createdByAlgorithm[createdBy] && /* @__PURE__ */ jsxRuntimeExports.jsx("div", { children: createdByAlgorithm[createdBy] }),
|
|
68382
|
+
/* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
|
|
68383
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("strong", { children: "Source:" }),
|
|
68384
|
+
" ",
|
|
68385
|
+
sourceDataset ? /* @__PURE__ */ jsxRuntimeExports.jsx(LinkTo, { to: "source", args: sourceDataset.key, children: sourceDataset.title }) : loadingSource ? "Loading..." : "—"
|
|
68386
|
+
] }),
|
|
68387
|
+
sourceRecordHref && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
|
|
68388
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("strong", { children: "ID:" }),
|
|
68389
|
+
" ",
|
|
68390
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("a", { href: sourceRecordHref, target: "_blank", rel: "noreferrer", children: effectiveSourceId })
|
|
68391
|
+
] }),
|
|
68392
|
+
(verbatimRecord == null ? void 0 : verbatimRecord.issues) && verbatimRecord.issues.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
|
|
68393
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: "Issues: " }),
|
|
68394
|
+
verbatimRecord.issues.map((issue, index2) => /* @__PURE__ */ jsxRuntimeExports.jsx(Tag, { style: { margin: "2px" }, children: issue }, index2))
|
|
68395
|
+
] })
|
|
68396
|
+
] });
|
|
68397
|
+
const tagStyle = {
|
|
68398
|
+
cursor: "pointer",
|
|
68399
|
+
fontFamily: "monospace",
|
|
68400
|
+
fontSize: "8px",
|
|
68401
|
+
fontWeight: 900,
|
|
68402
|
+
padding: "2px",
|
|
68403
|
+
lineHeight: "8px",
|
|
68404
|
+
verticalAlign: "middle",
|
|
68405
|
+
marginRight: "2px",
|
|
68406
|
+
...style2
|
|
68407
|
+
};
|
|
68386
68408
|
return !!sourceDatasetKey || !!verbatimSourceKey ? /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style: { display: "inline" }, id: idRef.current, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
68387
68409
|
Popover,
|
|
68388
68410
|
{
|
|
68389
68411
|
getPopupContainer: () => document.getElementById(idRef.current),
|
|
68390
|
-
content
|
|
68391
|
-
!verbatimSourceKey && !sourceId && sourceDatasetKey && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
|
|
68392
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("strong", { children: "Source:" }),
|
|
68393
|
-
" ",
|
|
68394
|
-
sourceDatasetLoading ? "Loading..." : /* @__PURE__ */ jsxRuntimeExports.jsx(LinkTo, { to: "source", args: sourceDataset == null ? void 0 : sourceDataset.key, children: sourceDataset == null ? void 0 : sourceDataset.title })
|
|
68395
|
-
] }),
|
|
68396
|
-
sourceDatasetKey && sourceId && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
|
|
68397
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("strong", { children: "Source:" }),
|
|
68398
|
-
" ",
|
|
68399
|
-
sourceTaxonLoading ? "Loading..." : /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
68400
|
-
"a",
|
|
68401
|
-
{
|
|
68402
|
-
href: `https://www.checklistbank.org/dataset/${sourceDatasetKey}/taxon/${sourceId}`,
|
|
68403
|
-
dangerouslySetInnerHTML: { __html: sourceTaxon == null ? void 0 : sourceTaxon.labelHtml },
|
|
68404
|
-
onClick: () => {
|
|
68405
|
-
window.location.href = `https://www.checklistbank.org/dataset/${sourceDatasetKey}/taxon/${sourceId}`;
|
|
68406
|
-
}
|
|
68407
|
-
}
|
|
68408
|
-
)
|
|
68409
|
-
] }),
|
|
68410
|
-
!sourceId && verbatimSourceKey && /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
|
|
68411
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("strong", { children: "Source:" }),
|
|
68412
|
-
" ",
|
|
68413
|
-
!!createdByAlgorithm[createdBy] && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: createdByAlgorithm[createdBy] }),
|
|
68414
|
-
verbatimRecordLoading ? "Loading..." : !!verbatimRecord ? /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
68415
|
-
" ",
|
|
68416
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
68417
|
-
"a",
|
|
68418
|
-
{
|
|
68419
|
-
href: `https://www.checklistbank.org/dataset/${verbatimRecord.sourceDatasetKey}/${(verbatimRecord.sourceEntity || "").replace(/\s/g, "")}/${encodeURIComponent(verbatimRecord.sourceId)}`,
|
|
68420
|
-
dangerouslySetInnerHTML: { __html: (sourceDataset == null ? void 0 : sourceDataset.title) || (verbatimRecord == null ? void 0 : verbatimRecord.sourceEntity) },
|
|
68421
|
-
onClick: () => {
|
|
68422
|
-
window.location.href = `https://www.checklistbank.org/dataset/${verbatimRecord.sourceDatasetKey}/${(verbatimRecord.sourceEntity || "").replace(/\s/g, "")}/${encodeURIComponent(verbatimRecord.sourceId)}`;
|
|
68423
|
-
}
|
|
68424
|
-
}
|
|
68425
|
-
),
|
|
68426
|
-
(verbatimRecord == null ? void 0 : verbatimRecord.issues) && (verbatimRecord == null ? void 0 : verbatimRecord.issues.length) > 0 ? /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { children: [
|
|
68427
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: "Issues: " }),
|
|
68428
|
-
verbatimRecord.issues.map((issue, index2) => /* @__PURE__ */ jsxRuntimeExports.jsx(Tag, { style: { margin: "2px" }, children: issue }, index2))
|
|
68429
|
-
] }) : ""
|
|
68430
|
-
] }) : ""
|
|
68431
|
-
] })
|
|
68432
|
-
] }),
|
|
68412
|
+
content,
|
|
68433
68413
|
trigger: "click",
|
|
68434
68414
|
placement: popoverPlacement || "right",
|
|
68435
68415
|
onOpenChange: setOpen,
|
|
68436
|
-
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
68437
|
-
Tag,
|
|
68438
|
-
{
|
|
68439
|
-
color: "purple",
|
|
68440
|
-
style: {
|
|
68441
|
-
cursor: "pointer",
|
|
68442
|
-
fontFamily: "monospace",
|
|
68443
|
-
fontSize: "8px",
|
|
68444
|
-
fontWeight: 900,
|
|
68445
|
-
padding: "2px",
|
|
68446
|
-
lineHeight: "8px",
|
|
68447
|
-
verticalAlign: "middle",
|
|
68448
|
-
marginRight: "2px",
|
|
68449
|
-
...style2
|
|
68450
|
-
},
|
|
68451
|
-
children: "XR"
|
|
68452
|
-
}
|
|
68453
|
-
)
|
|
68416
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(Tag, { color: "purple", style: tagStyle, children: "XR" })
|
|
68454
68417
|
}
|
|
68455
|
-
) }) : /* @__PURE__ */ jsxRuntimeExports.
|
|
68456
|
-
" ",
|
|
68457
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
68458
|
-
Tag,
|
|
68459
|
-
{
|
|
68460
|
-
color: "purple",
|
|
68461
|
-
style: {
|
|
68462
|
-
fontFamily: "monospace",
|
|
68463
|
-
fontSize: "8px",
|
|
68464
|
-
fontWeight: 900,
|
|
68465
|
-
padding: "2px",
|
|
68466
|
-
lineHeight: "8px",
|
|
68467
|
-
verticalAlign: "middle",
|
|
68468
|
-
marginRight: "2px",
|
|
68469
|
-
...style2
|
|
68470
|
-
},
|
|
68471
|
-
children: "XR"
|
|
68472
|
-
}
|
|
68473
|
-
)
|
|
68474
|
-
] });
|
|
68418
|
+
) }) : /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style: { display: "inline" }, children: /* @__PURE__ */ jsxRuntimeExports.jsx(Tag, { color: "purple", style: { ...tagStyle, cursor: "default" }, children: "XR" }) });
|
|
68475
68419
|
};
|
|
68476
68420
|
const ColTreeContext = React.createContext();
|
|
68477
68421
|
class ColTreeNode extends React.Component {
|
|
@@ -70672,6 +70616,22 @@ html body {
|
|
|
70672
70616
|
this.getDatasets.cancel();
|
|
70673
70617
|
}
|
|
70674
70618
|
}
|
|
70619
|
+
const XrGutter = ({ merged, style: style2, children, ...badgeProps }) => merged ? /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { style: { position: "relative", display: "inline-block", ...style2 }, children: [
|
|
70620
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
70621
|
+
MergedDataBadge,
|
|
70622
|
+
{
|
|
70623
|
+
...badgeProps,
|
|
70624
|
+
style: {
|
|
70625
|
+
position: "absolute",
|
|
70626
|
+
right: "100%",
|
|
70627
|
+
top: "50%",
|
|
70628
|
+
transform: "translateY(-50%)",
|
|
70629
|
+
marginRight: "4px"
|
|
70630
|
+
}
|
|
70631
|
+
}
|
|
70632
|
+
),
|
|
70633
|
+
children
|
|
70634
|
+
] }) : /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children });
|
|
70675
70635
|
const CONTENT_TYPE_KEY = "search-content-type";
|
|
70676
70636
|
const FormItem = Form.Item;
|
|
70677
70637
|
const RadioGroup = Radio.Group;
|
|
@@ -70699,23 +70659,22 @@ html body {
|
|
|
70699
70659
|
sortBy: "relevance"
|
|
70700
70660
|
};
|
|
70701
70661
|
const getColumns$1 = () => [
|
|
70702
|
-
{
|
|
70703
|
-
title: "",
|
|
70704
|
-
dataIndex: ["usage", "merged"],
|
|
70705
|
-
key: "merged",
|
|
70706
|
-
width: 12,
|
|
70707
|
-
render: (text2, record) => {
|
|
70708
|
-
var _a2, _b2, _c;
|
|
70709
|
-
return ((_a2 = record == null ? void 0 : record.usage) == null ? void 0 : _a2.merged) ? /* @__PURE__ */ jsxRuntimeExports.jsx(MergedDataBadge, { datasetKey: (_b2 = record == null ? void 0 : record.usage) == null ? void 0 : _b2.datasetKey, verbatimSourceKey: (_c = record == null ? void 0 : record.usage) == null ? void 0 : _c.verbatimSourceKey }) : "";
|
|
70710
|
-
}
|
|
70711
|
-
},
|
|
70712
70662
|
{
|
|
70713
70663
|
title: "Scientific Name",
|
|
70714
70664
|
dataIndex: ["usage", "labelHtml"],
|
|
70715
70665
|
key: "scientificName",
|
|
70716
70666
|
render: (text2, record) => {
|
|
70667
|
+
var _a2, _b2, _c;
|
|
70717
70668
|
const id = get(record, "usage.accepted.id") || get(record, "usage.id");
|
|
70718
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
70669
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
70670
|
+
XrGutter,
|
|
70671
|
+
{
|
|
70672
|
+
merged: (_a2 = record == null ? void 0 : record.usage) == null ? void 0 : _a2.merged,
|
|
70673
|
+
datasetKey: (_b2 = record == null ? void 0 : record.usage) == null ? void 0 : _b2.datasetKey,
|
|
70674
|
+
verbatimSourceKey: (_c = record == null ? void 0 : record.usage) == null ? void 0 : _c.verbatimSourceKey,
|
|
70675
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(LinkTo, { to: "taxon", args: id, children: /* @__PURE__ */ jsxRuntimeExports.jsx("span", { dangerouslySetInnerHTML: { __html: text2 } }) })
|
|
70676
|
+
}
|
|
70677
|
+
);
|
|
70719
70678
|
},
|
|
70720
70679
|
width: 200,
|
|
70721
70680
|
sorter: true
|
|
@@ -77439,27 +77398,28 @@ html body {
|
|
|
77439
77398
|
] }) });
|
|
77440
77399
|
};
|
|
77441
77400
|
const TypeMaterial = ({ dataset, data, nameID, style: style2 }) => {
|
|
77442
|
-
return data[nameID] ? /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style: style2, children: data[nameID].map((s) => /* @__PURE__ */ jsxRuntimeExports.
|
|
77443
|
-
|
|
77444
|
-
|
|
77445
|
-
|
|
77446
|
-
|
|
77447
|
-
|
|
77448
|
-
|
|
77449
|
-
|
|
77450
|
-
|
|
77451
|
-
|
|
77452
|
-
|
|
77453
|
-
|
|
77454
|
-
|
|
77455
|
-
|
|
77456
|
-
|
|
77457
|
-
|
|
77458
|
-
|
|
77459
|
-
|
|
77460
|
-
|
|
77461
|
-
|
|
77462
|
-
|
|
77401
|
+
return data[nameID] ? /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style: style2, children: data[nameID].map((s) => /* @__PURE__ */ jsxRuntimeExports.jsx(BorderedListItem$1, { children: /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
77402
|
+
XrGutter,
|
|
77403
|
+
{
|
|
77404
|
+
merged: s.merged,
|
|
77405
|
+
createdBy: s == null ? void 0 : s.createdBy,
|
|
77406
|
+
datasetKey: s == null ? void 0 : s.datasetKey,
|
|
77407
|
+
verbatimSourceKey: s == null ? void 0 : s.verbatimSourceKey,
|
|
77408
|
+
sourceDatasetKey: s == null ? void 0 : s.sourceDatasetKey,
|
|
77409
|
+
children: [
|
|
77410
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Tag, { color: getTypeColor(s == null ? void 0 : s.status), children: s == null ? void 0 : s.status }),
|
|
77411
|
+
" ",
|
|
77412
|
+
getLinks(dataset, s),
|
|
77413
|
+
" ",
|
|
77414
|
+
(s == null ? void 0 : s.citation) && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
77415
|
+
"span",
|
|
77416
|
+
{
|
|
77417
|
+
dangerouslySetInnerHTML: { __html: linkifyHtml((s == null ? void 0 : s.citation) || "") }
|
|
77418
|
+
}
|
|
77419
|
+
)
|
|
77420
|
+
]
|
|
77421
|
+
}
|
|
77422
|
+
) }, s.id)) }) : null;
|
|
77463
77423
|
};
|
|
77464
77424
|
class TypeMaterialPopover extends React.Component {
|
|
77465
77425
|
constructor(props) {
|
|
@@ -77483,12 +77443,9 @@ html body {
|
|
|
77483
77443
|
const { typeMaterial, nameId } = this.props;
|
|
77484
77444
|
const data = (typeMaterial == null ? void 0 : typeMaterial[nameId]) || [];
|
|
77485
77445
|
if (data.length > 0) {
|
|
77486
|
-
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { children: data.map((s) => /* @__PURE__ */ jsxRuntimeExports.
|
|
77446
|
+
return /* @__PURE__ */ jsxRuntimeExports.jsx("div", { children: data.map((s) => /* @__PURE__ */ jsxRuntimeExports.jsx("div", { style: { marginBottom: "8px", paddingLeft: "18px" }, children: /* @__PURE__ */ jsxRuntimeExports.jsxs(XrGutter, { merged: s.merged, children: [
|
|
77487
77447
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Tag, { color: getTypeColor(s == null ? void 0 : s.status), children: s == null ? void 0 : s.status }),
|
|
77488
|
-
|
|
77489
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(MergedDataBadge, {}),
|
|
77490
|
-
" "
|
|
77491
|
-
] }),
|
|
77448
|
+
" ",
|
|
77492
77449
|
(s == null ? void 0 : s.citation) && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
77493
77450
|
"span",
|
|
77494
77451
|
{
|
|
@@ -77497,7 +77454,7 @@ html body {
|
|
|
77497
77454
|
}
|
|
77498
77455
|
}
|
|
77499
77456
|
)
|
|
77500
|
-
] }, s.id)) });
|
|
77457
|
+
] }) }, s.id)) });
|
|
77501
77458
|
}
|
|
77502
77459
|
});
|
|
77503
77460
|
__publicField(this, "render", () => {
|
|
@@ -77539,7 +77496,8 @@ html body {
|
|
|
77539
77496
|
decisions,
|
|
77540
77497
|
typeMaterial,
|
|
77541
77498
|
referenceIndexMap,
|
|
77542
|
-
primarySource
|
|
77499
|
+
primarySource,
|
|
77500
|
+
misapplied
|
|
77543
77501
|
}) => {
|
|
77544
77502
|
const [showAll, setShowAll] = reactExports.useState(false);
|
|
77545
77503
|
const getNomStatus = (taxon) => !nomStatus ? get(taxon, "name.nomStatus") : nomStatus[get(taxon, "name.nomStatus")][get(taxon, "name.code"), "zoological"];
|
|
@@ -77555,49 +77513,57 @@ html body {
|
|
|
77555
77513
|
}
|
|
77556
77514
|
};
|
|
77557
77515
|
const items = [];
|
|
77558
|
-
if (
|
|
77559
|
-
|
|
77560
|
-
|
|
77561
|
-
|
|
77562
|
-
}
|
|
77563
|
-
if (data.heterotypicGroups) {
|
|
77564
|
-
[...data.heterotypicGroups].sort((a, b2) => sorter(a[0], b2[0])).forEach((group) => {
|
|
77565
|
-
group.forEach((s, i) => {
|
|
77566
|
-
items.push({ syn: s, homotypic: i > 0, indent: i > 0 });
|
|
77516
|
+
if (misapplied) {
|
|
77517
|
+
if (data.misapplied) {
|
|
77518
|
+
[...data.misapplied].sort(sorter).forEach((s) => {
|
|
77519
|
+
items.push({ syn: s, homotypic: false, indent: false });
|
|
77567
77520
|
});
|
|
77568
|
-
}
|
|
77521
|
+
}
|
|
77522
|
+
} else {
|
|
77523
|
+
if (data.homotypic) {
|
|
77524
|
+
[...data.homotypic].sort(sorter).forEach((s) => {
|
|
77525
|
+
items.push({ syn: s, homotypic: true, indent: false });
|
|
77526
|
+
});
|
|
77527
|
+
}
|
|
77528
|
+
if (data.heterotypicGroups) {
|
|
77529
|
+
[...data.heterotypicGroups].sort((a, b2) => sorter(a[0], b2[0])).forEach((group) => {
|
|
77530
|
+
group.forEach((s, i) => {
|
|
77531
|
+
items.push({ syn: s, homotypic: i > 0, indent: i > 0 });
|
|
77532
|
+
});
|
|
77533
|
+
});
|
|
77534
|
+
}
|
|
77569
77535
|
}
|
|
77570
77536
|
const total = items.length;
|
|
77571
77537
|
const visibleItems = showAll ? items : items.slice(0, TOP_N);
|
|
77572
77538
|
const renderItem = ({ syn: s, homotypic, indent }) => /* @__PURE__ */ jsxRuntimeExports.jsxs(BorderedListItem$1, { children: [
|
|
77573
|
-
/* @__PURE__ */ jsxRuntimeExports.
|
|
77574
|
-
|
|
77575
|
-
" ",
|
|
77576
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(LinkTo, { to: "taxon", args: get(s, "id"), children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
77577
|
-
"span",
|
|
77578
|
-
{
|
|
77579
|
-
dangerouslySetInnerHTML: {
|
|
77580
|
-
__html: get(
|
|
77581
|
-
s,
|
|
77582
|
-
"labelHtml",
|
|
77583
|
-
`${get(s, "name.scientificName")} ${get(
|
|
77584
|
-
s,
|
|
77585
|
-
"name.authorship",
|
|
77586
|
-
""
|
|
77587
|
-
)}`
|
|
77588
|
-
)
|
|
77589
|
-
}
|
|
77590
|
-
}
|
|
77591
|
-
) })
|
|
77592
|
-
] }),
|
|
77593
|
-
" ",
|
|
77594
|
-
(s == null ? void 0 : s.sourceDatasetKey) && get(primarySource, "key") !== (s == null ? void 0 : s.sourceDatasetKey) && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
77595
|
-
MergedDataBadge,
|
|
77539
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
77540
|
+
XrGutter,
|
|
77596
77541
|
{
|
|
77542
|
+
merged: !!(s == null ? void 0 : s.sourceDatasetKey) && get(primarySource, "key") !== (s == null ? void 0 : s.sourceDatasetKey),
|
|
77597
77543
|
createdBy: s == null ? void 0 : s.createdBy,
|
|
77598
77544
|
datasetKey: s.datasetKey,
|
|
77599
77545
|
sourceDatasetKey: s == null ? void 0 : s.sourceDatasetKey,
|
|
77600
|
-
verbatimSourceKey: s.verbatimSourceKey
|
|
77546
|
+
verbatimSourceKey: s.verbatimSourceKey,
|
|
77547
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsxs("span", { style: indent ? { marginLeft: "10px" } : null, children: [
|
|
77548
|
+
misapplied ? "" : homotypic === true ? "≡ " : "= ",
|
|
77549
|
+
" ",
|
|
77550
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(LinkTo, { to: "taxon", args: get(s, "id"), children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
77551
|
+
"span",
|
|
77552
|
+
{
|
|
77553
|
+
dangerouslySetInnerHTML: {
|
|
77554
|
+
__html: get(
|
|
77555
|
+
s,
|
|
77556
|
+
"labelHtml",
|
|
77557
|
+
`${get(s, "name.scientificName")} ${get(
|
|
77558
|
+
s,
|
|
77559
|
+
"name.authorship",
|
|
77560
|
+
""
|
|
77561
|
+
)}`
|
|
77562
|
+
)
|
|
77563
|
+
}
|
|
77564
|
+
}
|
|
77565
|
+
) })
|
|
77566
|
+
] })
|
|
77601
77567
|
}
|
|
77602
77568
|
),
|
|
77603
77569
|
" ",
|
|
@@ -77692,17 +77658,21 @@ html body {
|
|
|
77692
77658
|
countryAlpha3: {},
|
|
77693
77659
|
countryAlpha2: {},
|
|
77694
77660
|
columns: [
|
|
77695
|
-
{
|
|
77696
|
-
title: "",
|
|
77697
|
-
dataIndex: "merged",
|
|
77698
|
-
key: "merged",
|
|
77699
|
-
width: 12,
|
|
77700
|
-
render: (text2, record) => (record == null ? void 0 : record.merged) ? /* @__PURE__ */ jsxRuntimeExports.jsx(MergedDataBadge, { createdBy: record == null ? void 0 : record.createdBy, datasetKey: record == null ? void 0 : record.datasetKey, verbatimSourceKey: record == null ? void 0 : record.verbatimSourceKey, sourceDatasetKey: record == null ? void 0 : record.sourceDatasetKey }) : ""
|
|
77701
|
-
},
|
|
77702
77661
|
{
|
|
77703
77662
|
title: "Original name",
|
|
77704
77663
|
dataIndex: "name",
|
|
77705
|
-
key: "name"
|
|
77664
|
+
key: "name",
|
|
77665
|
+
render: (text2, record) => /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
77666
|
+
XrGutter,
|
|
77667
|
+
{
|
|
77668
|
+
merged: record == null ? void 0 : record.merged,
|
|
77669
|
+
createdBy: record == null ? void 0 : record.createdBy,
|
|
77670
|
+
datasetKey: record == null ? void 0 : record.datasetKey,
|
|
77671
|
+
verbatimSourceKey: record == null ? void 0 : record.verbatimSourceKey,
|
|
77672
|
+
sourceDatasetKey: record == null ? void 0 : record.sourceDatasetKey,
|
|
77673
|
+
children: text2
|
|
77674
|
+
}
|
|
77675
|
+
)
|
|
77706
77676
|
},
|
|
77707
77677
|
{
|
|
77708
77678
|
title: "Transliterated name",
|
|
@@ -80419,26 +80389,25 @@ html body {
|
|
|
80419
80389
|
var _a2, _b2;
|
|
80420
80390
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(Row, { children: [
|
|
80421
80391
|
/* @__PURE__ */ jsxRuntimeExports.jsx(Col, { style: { paddingRight: "5px" }, children: get(referenceIndexMap, s.id) && /* @__PURE__ */ jsxRuntimeExports.jsx("span", { children: `[${get(referenceIndexMap, s.id)}]` }) }),
|
|
80422
|
-
/* @__PURE__ */ jsxRuntimeExports.
|
|
80423
|
-
|
|
80424
|
-
|
|
80425
|
-
|
|
80426
|
-
|
|
80427
|
-
|
|
80428
|
-
|
|
80429
|
-
|
|
80430
|
-
|
|
80431
|
-
|
|
80432
|
-
|
|
80433
|
-
|
|
80434
|
-
|
|
80435
|
-
|
|
80436
|
-
|
|
80437
|
-
__html: linkifyHtml(purify.sanitize(s.citation))
|
|
80392
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(Col, { span: 20, style: { paddingLeft: "18px" }, children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
80393
|
+
XrGutter,
|
|
80394
|
+
{
|
|
80395
|
+
merged: ((_a2 = s == null ? void 0 : s.sourceDataset) == null ? void 0 : _a2.key) !== primarySourceDatasetKey,
|
|
80396
|
+
createdBy: s == null ? void 0 : s.createdBy,
|
|
80397
|
+
datasetKey: s.datasetKey,
|
|
80398
|
+
verbatimSourceKey: s == null ? void 0 : s.verbatimSourceKey,
|
|
80399
|
+
sourceDatasetKey: (_b2 = s == null ? void 0 : s.sourceDataset) == null ? void 0 : _b2.key,
|
|
80400
|
+
children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
80401
|
+
"span",
|
|
80402
|
+
{
|
|
80403
|
+
id: `col-reference-${s.id}`,
|
|
80404
|
+
dangerouslySetInnerHTML: {
|
|
80405
|
+
__html: linkifyHtml(purify.sanitize(s.citation))
|
|
80406
|
+
}
|
|
80438
80407
|
}
|
|
80439
|
-
|
|
80440
|
-
|
|
80441
|
-
|
|
80408
|
+
)
|
|
80409
|
+
}
|
|
80410
|
+
) })
|
|
80442
80411
|
] }, s.id);
|
|
80443
80412
|
}) });
|
|
80444
80413
|
};
|
|
@@ -87266,7 +87235,7 @@ html body {
|
|
|
87266
87235
|
}
|
|
87267
87236
|
}
|
|
87268
87237
|
render() {
|
|
87269
|
-
var _a2, _b2, _c, _d, _e2, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B
|
|
87238
|
+
var _a2, _b2, _c, _d, _e2, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B;
|
|
87270
87239
|
const {
|
|
87271
87240
|
datasetKey,
|
|
87272
87241
|
showDistributionMap,
|
|
@@ -87294,7 +87263,7 @@ html body {
|
|
|
87294
87263
|
);
|
|
87295
87264
|
const homotypic = get(info, "synonyms.homotypic", []);
|
|
87296
87265
|
const heterotypic = get(info, "synonyms.heterotypic", []);
|
|
87297
|
-
get(info, "synonyms.misapplied", []);
|
|
87266
|
+
const misapplied = get(info, "synonyms.misapplied", []);
|
|
87298
87267
|
[
|
|
87299
87268
|
...homotypic.map((h) => ({ ...h, __homotypic: true })),
|
|
87300
87269
|
...heterotypic
|
|
@@ -87424,7 +87393,7 @@ html body {
|
|
|
87424
87393
|
]
|
|
87425
87394
|
}
|
|
87426
87395
|
),
|
|
87427
|
-
Array.isArray(get(taxon, "identifier")) && get(taxon, "identifier").length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsx(PresentationItem$1, { md, label: "
|
|
87396
|
+
Array.isArray(get(taxon, "identifier")) && get(taxon, "identifier").length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsx(PresentationItem$1, { md, label: "Other identifiers", children: get(taxon, "identifier").map((id, i) => /* @__PURE__ */ jsxRuntimeExports.jsxs(React.Fragment, { children: [
|
|
87428
87397
|
i > 0 && ", ",
|
|
87429
87398
|
String(id)
|
|
87430
87399
|
] }, i)) }),
|
|
@@ -87478,6 +87447,20 @@ html body {
|
|
|
87478
87447
|
datasetKey
|
|
87479
87448
|
}
|
|
87480
87449
|
) }),
|
|
87450
|
+
!isSynonym && misapplied.length > 0 && /* @__PURE__ */ jsxRuntimeExports.jsx(PresentationItem$1, { md, label: "Misapplied names", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
87451
|
+
SynonymsTable,
|
|
87452
|
+
{
|
|
87453
|
+
misapplied: true,
|
|
87454
|
+
primarySource: sourceDataset,
|
|
87455
|
+
data: get(info, "synonyms"),
|
|
87456
|
+
decisions: get(info, "decisions"),
|
|
87457
|
+
references: get(info, "references"),
|
|
87458
|
+
typeMaterial: get(info, "typeMaterial"),
|
|
87459
|
+
referenceIndexMap,
|
|
87460
|
+
style: { marginTop: "-3px" },
|
|
87461
|
+
datasetKey
|
|
87462
|
+
}
|
|
87463
|
+
) }),
|
|
87481
87464
|
get(info, "typeMaterial") && info.typeMaterial[(_m = (_l = info == null ? void 0 : info.usage) == null ? void 0 : _l.name) == null ? void 0 : _m.id] && /* @__PURE__ */ jsxRuntimeExports.jsx(PresentationItem$1, { md, label: "Type material", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
87482
87465
|
TypeMaterial,
|
|
87483
87466
|
{
|
|
@@ -87586,22 +87569,15 @@ html body {
|
|
|
87586
87569
|
}
|
|
87587
87570
|
),
|
|
87588
87571
|
" ",
|
|
87589
|
-
(
|
|
87590
|
-
|
|
87591
|
-
|
|
87592
|
-
{
|
|
87593
|
-
|
|
87594
|
-
|
|
87595
|
-
|
|
87596
|
-
|
|
87597
|
-
|
|
87598
|
-
"in",
|
|
87599
|
-
" "
|
|
87600
|
-
] }),
|
|
87601
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(LinkTo, { to: "source", args: get(sourceDataset, "key"), children: `${get(sourceDataset, "alias")}: ${get(
|
|
87602
|
-
sourceDataset,
|
|
87603
|
-
"title"
|
|
87604
|
-
)}` }),
|
|
87572
|
+
((_t = info == null ? void 0 : info.source) == null ? void 0 : _t.sourceId) ? /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
87573
|
+
"a",
|
|
87574
|
+
{
|
|
87575
|
+
href: `https://www.checklistbank.org/dataset/${(_u = info == null ? void 0 : info.source) == null ? void 0 : _u.sourceDatasetKey}/taxon/${(_v = info == null ? void 0 : info.source) == null ? void 0 : _v.sourceId}`,
|
|
87576
|
+
children: get(sourceDataset, "alias")
|
|
87577
|
+
}
|
|
87578
|
+
) : get(sourceDataset, "alias"),
|
|
87579
|
+
": ",
|
|
87580
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(LinkTo, { to: "source", args: get(sourceDataset, "key"), children: get(sourceDataset, "title") }),
|
|
87605
87581
|
/* @__PURE__ */ jsxRuntimeExports.jsx("span", { style: { marginLeft: "10px" }, children: get(sourceDataset, "completeness") && get(sourceDataset, "completeness") + "%" }),
|
|
87606
87582
|
get(sourceDataset, "confidence") && /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
87607
87583
|
Rate,
|
|
@@ -87613,17 +87589,17 @@ html body {
|
|
|
87613
87589
|
)
|
|
87614
87590
|
] }) }),
|
|
87615
87591
|
get(taxon, "link") && /* @__PURE__ */ jsxRuntimeExports.jsx(PresentationItem$1, { md, label: "Original record", children: /* @__PURE__ */ jsxRuntimeExports.jsx("a", { href: get(taxon, "link"), children: get(taxon, "link") }) }),
|
|
87616
|
-
((
|
|
87592
|
+
((_w = info == null ? void 0 : info.source) == null ? void 0 : _w.secondarySources) && /* @__PURE__ */ jsxRuntimeExports.jsx(PresentationItem$1, { md, label: "Secondary Sources", children: /* @__PURE__ */ jsxRuntimeExports.jsx(SecondarySources, { info, datasetKey }) }),
|
|
87617
87593
|
get(info, "references") && /* @__PURE__ */ jsxRuntimeExports.jsx(PresentationItem$1, { md, label: "References", children: /* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
87618
87594
|
ReferencesTable,
|
|
87619
87595
|
{
|
|
87620
87596
|
referenceIndexMap,
|
|
87621
|
-
primarySourceDatasetKey: (
|
|
87597
|
+
primarySourceDatasetKey: (_x = info == null ? void 0 : info.source) == null ? void 0 : _x.sourceDatasetKey,
|
|
87622
87598
|
data: get(info, "references"),
|
|
87623
87599
|
style: { marginTop: "-3px" }
|
|
87624
87600
|
}
|
|
87625
87601
|
) }),
|
|
87626
|
-
((
|
|
87602
|
+
((_z = (_y = window == null ? void 0 : window.location) == null ? void 0 : _y.hostname) == null ? void 0 : _z.endsWith("catalogueoflife.org")) && /* @__PURE__ */ jsxRuntimeExports.jsx(PresentationItem$1, { md, label: "", children: /* @__PURE__ */ jsxRuntimeExports.jsx(Feedback, { taxonKey: (_B = (_A = this == null ? void 0 : this.state) == null ? void 0 : _A.taxon) == null ? void 0 : _B.id, datasetKey: this.props.datasetKey }) })
|
|
87627
87603
|
]
|
|
87628
87604
|
}
|
|
87629
87605
|
) });
|
|
@@ -89367,9 +89343,7 @@ Please report this to https://github.com/markedjs/marked.`, e2) {
|
|
|
89367
89343
|
ellipsis: true,
|
|
89368
89344
|
render: (text2, record) => {
|
|
89369
89345
|
return /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
89370
|
-
record.id ? /* @__PURE__ */ jsxRuntimeExports.jsxs(
|
|
89371
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(MergedDataBadge, { style: { marginLeft: "0px" } }),
|
|
89372
|
-
" ",
|
|
89346
|
+
record.id ? /* @__PURE__ */ jsxRuntimeExports.jsxs(XrGutter, { merged: true, children: [
|
|
89373
89347
|
"Publisher: ",
|
|
89374
89348
|
" ",
|
|
89375
89349
|
/* @__PURE__ */ jsxRuntimeExports.jsx(
|
|
@@ -89383,10 +89357,7 @@ Please report this to https://github.com/markedjs/marked.`, e2) {
|
|
|
89383
89357
|
),
|
|
89384
89358
|
" "
|
|
89385
89359
|
] }) : /* @__PURE__ */ jsxRuntimeExports.jsxs(jsxRuntimeExports.Fragment, { children: [
|
|
89386
|
-
|
|
89387
|
-
!!(record == null ? void 0 : record.merged) && /* @__PURE__ */ jsxRuntimeExports.jsx(MergedDataBadge, { style: { marginLeft: "0px" } }),
|
|
89388
|
-
" ",
|
|
89389
|
-
/* @__PURE__ */ jsxRuntimeExports.jsx(LinkTo, { to: "source", args: record.key, children: record.alias || record.title }),
|
|
89360
|
+
/* @__PURE__ */ jsxRuntimeExports.jsx(XrGutter, { merged: !!(record == null ? void 0 : record.merged), children: /* @__PURE__ */ jsxRuntimeExports.jsx(LinkTo, { to: "source", args: record.key, children: record.alias || record.title }) }),
|
|
89390
89361
|
!!(record == null ? void 0 : record.taxonomicScope) && /* @__PURE__ */ jsxRuntimeExports.jsx("br", {})
|
|
89391
89362
|
] }),
|
|
89392
89363
|
!!(record == null ? void 0 : record.taxonomicScope) && (record == null ? void 0 : record.taxonomicScope)
|