@macrostrat/map-interface 1.5.2 → 1.5.3
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/CHANGELOG.md +10 -0
- package/dist/cjs/index.js +2 -2
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/map-interface.1faa2839.js +14 -0
- package/dist/cjs/map-interface.1faa2839.js.map +1 -0
- package/dist/cjs/map-interface.1fdaaaf6.js +135 -0
- package/dist/cjs/map-interface.1fdaaaf6.js.map +1 -0
- package/dist/cjs/{map-interface.744b121c.js → map-interface.23d5c62c.js} +3 -4
- package/dist/cjs/map-interface.23d5c62c.js.map +1 -0
- package/dist/cjs/map-interface.24a1c14e.js +46 -0
- package/dist/cjs/map-interface.24a1c14e.js.map +1 -0
- package/dist/cjs/map-interface.2a4a5470.js +34 -0
- package/dist/cjs/map-interface.2a4a5470.js.map +1 -0
- package/dist/cjs/{map-interface.71259cf9.css → map-interface.368b346c.css} +10 -10
- package/dist/{esm/map-interface.409f6268.js.map → cjs/map-interface.368b346c.css.map} +1 -1
- package/dist/cjs/map-interface.3c606eea.js +36 -0
- package/dist/cjs/map-interface.3c606eea.js.map +1 -0
- package/dist/cjs/map-interface.441d3b83.css +69 -0
- package/dist/cjs/map-interface.441d3b83.css.map +1 -0
- package/dist/cjs/map-interface.49704804.js +388 -0
- package/dist/cjs/map-interface.49704804.js.map +1 -0
- package/dist/cjs/map-interface.4c2f5ced.js +58 -0
- package/dist/cjs/map-interface.4c2f5ced.js.map +1 -0
- package/dist/cjs/map-interface.5a4f4529.js +38 -0
- package/dist/cjs/map-interface.5a4f4529.js.map +1 -0
- package/dist/cjs/{map-interface.1bfa8ff4.css → map-interface.633d24e6.css} +5 -5
- package/dist/cjs/map-interface.633d24e6.css.map +1 -0
- package/dist/cjs/{map-interface.4264e7e1.js → map-interface.71e61c74.js} +19 -19
- package/dist/cjs/map-interface.71e61c74.js.map +1 -0
- package/dist/cjs/map-interface.ad03b0c2.js +64 -0
- package/dist/cjs/map-interface.ad03b0c2.js.map +1 -0
- package/dist/cjs/{map-interface.84080d80.js → map-interface.b15c1893.js} +10 -10
- package/dist/cjs/map-interface.b15c1893.js.map +1 -0
- package/dist/cjs/map-interface.ce2c83fa.js +17 -0
- package/dist/cjs/map-interface.ce2c83fa.js.map +1 -0
- package/dist/cjs/map-interface.e109c93a.js +100 -0
- package/dist/cjs/map-interface.e109c93a.js.map +1 -0
- package/dist/cjs/map-interface.f4227aaa.js +123 -0
- package/dist/cjs/map-interface.f4227aaa.js.map +1 -0
- package/dist/cjs/map-interface.f9611285.js +32 -0
- package/dist/cjs/map-interface.f9611285.js.map +1 -0
- package/dist/esm/index.d.ts +36 -1
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.js +2 -2
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/map-interface.021cf79b.js +18 -0
- package/dist/esm/map-interface.021cf79b.js.map +1 -0
- package/dist/esm/map-interface.13e6d768.js +130 -0
- package/dist/esm/map-interface.13e6d768.js.map +1 -0
- package/dist/esm/map-interface.1f2a6325.js +54 -0
- package/dist/esm/map-interface.1f2a6325.js.map +1 -0
- package/dist/esm/map-interface.243c85c6.js +49 -0
- package/dist/esm/map-interface.243c85c6.js.map +1 -0
- package/dist/esm/{map-interface.b7a0dc07.js → map-interface.316fd76a.js} +8 -8
- package/dist/esm/map-interface.316fd76a.js.map +1 -0
- package/dist/esm/map-interface.47191f77.js +15 -0
- package/dist/esm/map-interface.47191f77.js.map +1 -0
- package/dist/esm/{map-interface.2daa72f9.js → map-interface.578a7505.js} +3 -4
- package/dist/esm/map-interface.578a7505.js.map +1 -0
- package/dist/esm/map-interface.59896194.js +37 -0
- package/dist/esm/map-interface.59896194.js.map +1 -0
- package/dist/esm/map-interface.70768c2c.js +383 -0
- package/dist/esm/map-interface.70768c2c.js.map +1 -0
- package/dist/esm/map-interface.70d6a7ff.js +16 -0
- package/dist/esm/map-interface.70d6a7ff.js.map +1 -0
- package/dist/esm/map-interface.767fdc4a.js +64 -0
- package/dist/esm/map-interface.767fdc4a.js.map +1 -0
- package/dist/esm/map-interface.7ea8a1e0.js +40 -0
- package/dist/esm/map-interface.7ea8a1e0.js.map +1 -0
- package/dist/esm/map-interface.b97aca89.js +25 -0
- package/dist/esm/map-interface.b97aca89.js.map +1 -0
- package/dist/esm/map-interface.bdef07d2.js +34 -0
- package/dist/esm/map-interface.bdef07d2.js.map +1 -0
- package/dist/esm/map-interface.c1d19ef4.js +114 -0
- package/dist/esm/map-interface.c1d19ef4.js.map +1 -0
- package/dist/esm/map-interface.fb96fb7e.js +94 -0
- package/dist/esm/map-interface.fb96fb7e.js.map +1 -0
- package/dist/node/index.js +1 -1
- package/dist/node/index.js.map +1 -1
- package/dist/node/map-interface.206d8dd9.js +2 -0
- package/dist/node/map-interface.206d8dd9.js.map +1 -0
- package/dist/node/map-interface.3dbeec12.js +2 -0
- package/dist/node/map-interface.3dbeec12.js.map +1 -0
- package/dist/node/map-interface.432dd2f9.js +2 -0
- package/dist/node/map-interface.432dd2f9.js.map +1 -0
- package/dist/node/map-interface.73dfe675.js +2 -0
- package/dist/node/map-interface.73dfe675.js.map +1 -0
- package/dist/node/map-interface.82397845.js +2 -0
- package/dist/node/map-interface.82397845.js.map +1 -0
- package/dist/node/map-interface.8881e38a.js +2 -0
- package/dist/node/map-interface.8881e38a.js.map +1 -0
- package/dist/node/map-interface.9317d050.js +2 -0
- package/dist/node/map-interface.9317d050.js.map +1 -0
- package/dist/node/map-interface.97b93dd1.js +2 -0
- package/dist/node/map-interface.97b93dd1.js.map +1 -0
- package/dist/node/map-interface.9e6751ac.js +2 -0
- package/dist/node/map-interface.9e6751ac.js.map +1 -0
- package/dist/node/map-interface.a1252092.css +2 -0
- package/dist/node/map-interface.a1252092.css.map +1 -0
- package/dist/node/map-interface.a50eb4e3.js +2 -0
- package/dist/node/map-interface.a50eb4e3.js.map +1 -0
- package/dist/node/map-interface.a8a16138.js +2 -0
- package/dist/node/map-interface.a8a16138.js.map +1 -0
- package/dist/node/{map-interface.fcb95c23.js → map-interface.a8be0cba.js} +2 -2
- package/dist/node/map-interface.a8be0cba.js.map +1 -0
- package/dist/node/map-interface.ae3d2d83.js +2 -0
- package/dist/node/map-interface.ae3d2d83.js.map +1 -0
- package/dist/node/map-interface.c5c0ad06.js +2 -0
- package/dist/node/map-interface.c5c0ad06.js.map +1 -0
- package/dist/node/map-interface.d22d91e9.css +2 -0
- package/dist/node/map-interface.d22d91e9.css.map +1 -0
- package/dist/node/map-interface.d5eba479.css +2 -0
- package/dist/node/map-interface.d5eba479.css.map +1 -0
- package/dist/node/map-interface.f413c362.js +2 -0
- package/dist/node/map-interface.f413c362.js.map +1 -0
- package/dist/node/map-interface.fdd35e74.js +2 -0
- package/dist/node/map-interface.fdd35e74.js.map +1 -0
- package/package.json +2 -2
- package/src/index.ts +1 -1
- package/src/location-details/fetch.ts +57 -0
- package/src/{map-panel/components/info-drawer → location-details}/fossil-collections/collections.tsx +1 -2
- package/src/{map-panel/components/info-drawer → location-details}/fossil-collections/index.ts +1 -1
- package/src/location-details/index.ts +5 -0
- package/src/{map-panel/components → location-details}/info-blocks.ts +7 -5
- package/src/location-details/location-details.stories.ts +104 -0
- package/src/{map-panel/components/info-drawer → location-details}/macrostrat-linked.ts +28 -20
- package/src/{map-panel/components/info-drawer → location-details}/physiography.ts +8 -7
- package/src/{map-panel/components/info-drawer → location-details}/reg-strat.ts +26 -7
- package/src/{map-panel → location-details}/utils/fossils.ts +0 -2
- package/src/{map-panel/components/info-drawer → location-details}/xdd-panel/index.ts +6 -2
- package/dist/cjs/map-interface.02835ba5.js +0 -46
- package/dist/cjs/map-interface.02835ba5.js.map +0 -1
- package/dist/cjs/map-interface.07a195a5.js +0 -14
- package/dist/cjs/map-interface.07a195a5.js.map +0 -1
- package/dist/cjs/map-interface.0f2392a0.css +0 -64
- package/dist/cjs/map-interface.0f2392a0.css.map +0 -1
- package/dist/cjs/map-interface.141c7329.js +0 -58
- package/dist/cjs/map-interface.141c7329.js.map +0 -1
- package/dist/cjs/map-interface.1be58b40.css +0 -69
- package/dist/cjs/map-interface.1be58b40.css.map +0 -1
- package/dist/cjs/map-interface.1bfa8ff4.css.map +0 -1
- package/dist/cjs/map-interface.4264e7e1.js.map +0 -1
- package/dist/cjs/map-interface.533a7323.js +0 -113
- package/dist/cjs/map-interface.533a7323.js.map +0 -1
- package/dist/cjs/map-interface.58c87b08.js +0 -29
- package/dist/cjs/map-interface.58c87b08.js.map +0 -1
- package/dist/cjs/map-interface.5c8f9bde.js +0 -24
- package/dist/cjs/map-interface.5c8f9bde.js.map +0 -1
- package/dist/cjs/map-interface.5f0bd31b.js +0 -141
- package/dist/cjs/map-interface.5f0bd31b.js.map +0 -1
- package/dist/cjs/map-interface.71259cf9.css.map +0 -1
- package/dist/cjs/map-interface.727092bc.js +0 -381
- package/dist/cjs/map-interface.727092bc.js.map +0 -1
- package/dist/cjs/map-interface.744b121c.js.map +0 -1
- package/dist/cjs/map-interface.84080d80.js.map +0 -1
- package/dist/cjs/map-interface.937c0b90.js +0 -60
- package/dist/cjs/map-interface.937c0b90.js.map +0 -1
- package/dist/cjs/map-interface.9893b047.js +0 -38
- package/dist/cjs/map-interface.9893b047.js.map +0 -1
- package/dist/cjs/map-interface.b6e70f1b.js +0 -98
- package/dist/cjs/map-interface.b6e70f1b.js.map +0 -1
- package/dist/cjs/map-interface.d8e62b02.js +0 -17
- package/dist/cjs/map-interface.d8e62b02.js.map +0 -1
- package/dist/cjs/map-interface.ee59fc6e.js +0 -32
- package/dist/cjs/map-interface.ee59fc6e.js.map +0 -1
- package/dist/cjs/map-interface.fba5cf13.js +0 -136
- package/dist/cjs/map-interface.fba5cf13.js.map +0 -1
- package/dist/cjs/map-interface.fd9ad74c.js +0 -34
- package/dist/cjs/map-interface.fd9ad74c.js.map +0 -1
- package/dist/cjs/map-interface.ff2231f5.js +0 -37
- package/dist/cjs/map-interface.ff2231f5.js.map +0 -1
- package/dist/esm/map-interface.15ee4b90.js +0 -16
- package/dist/esm/map-interface.15ee4b90.js.map +0 -1
- package/dist/esm/map-interface.17a0e9a0.js +0 -51
- package/dist/esm/map-interface.17a0e9a0.js.map +0 -1
- package/dist/esm/map-interface.20193fc6.js +0 -92
- package/dist/esm/map-interface.20193fc6.js.map +0 -1
- package/dist/esm/map-interface.2daa72f9.js.map +0 -1
- package/dist/esm/map-interface.36bab86c.js +0 -31
- package/dist/esm/map-interface.36bab86c.js.map +0 -1
- package/dist/esm/map-interface.409f6268.js +0 -34
- package/dist/esm/map-interface.6981dd47.js +0 -131
- package/dist/esm/map-interface.6981dd47.js.map +0 -1
- package/dist/esm/map-interface.69a566f3.js +0 -25
- package/dist/esm/map-interface.69a566f3.js.map +0 -1
- package/dist/esm/map-interface.6c0f5044.js +0 -376
- package/dist/esm/map-interface.6c0f5044.js.map +0 -1
- package/dist/esm/map-interface.6c44beb8.js +0 -49
- package/dist/esm/map-interface.6c44beb8.js.map +0 -1
- package/dist/esm/map-interface.70fdf48a.js +0 -64
- package/dist/esm/map-interface.70fdf48a.js.map +0 -1
- package/dist/esm/map-interface.9123f5c8.js +0 -104
- package/dist/esm/map-interface.9123f5c8.js.map +0 -1
- package/dist/esm/map-interface.a0ea0c86.js +0 -18
- package/dist/esm/map-interface.a0ea0c86.js.map +0 -1
- package/dist/esm/map-interface.b7a0dc07.js.map +0 -1
- package/dist/esm/map-interface.b965dc94.js +0 -40
- package/dist/esm/map-interface.b965dc94.js.map +0 -1
- package/dist/esm/map-interface.ba2faf2f.js +0 -7
- package/dist/esm/map-interface.ba2faf2f.js.map +0 -1
- package/dist/esm/map-interface.ce6edbfa.js +0 -37
- package/dist/esm/map-interface.ce6edbfa.js.map +0 -1
- package/dist/esm/map-interface.d86c2fc5.js +0 -32
- package/dist/esm/map-interface.d86c2fc5.js.map +0 -1
- package/dist/esm/map-interface.e5607033.js +0 -136
- package/dist/esm/map-interface.e5607033.js.map +0 -1
- package/dist/node/map-interface.01fee32b.js +0 -2
- package/dist/node/map-interface.01fee32b.js.map +0 -1
- package/dist/node/map-interface.0755d245.css +0 -2
- package/dist/node/map-interface.0755d245.css.map +0 -1
- package/dist/node/map-interface.2c94d421.js +0 -2
- package/dist/node/map-interface.2c94d421.js.map +0 -1
- package/dist/node/map-interface.2dde967a.js +0 -2
- package/dist/node/map-interface.2dde967a.js.map +0 -1
- package/dist/node/map-interface.4dfbbb99.css +0 -2
- package/dist/node/map-interface.4dfbbb99.css.map +0 -1
- package/dist/node/map-interface.4e422f5e.js +0 -2
- package/dist/node/map-interface.4e422f5e.js.map +0 -1
- package/dist/node/map-interface.5fbb81b1.js +0 -2
- package/dist/node/map-interface.5fbb81b1.js.map +0 -1
- package/dist/node/map-interface.791d22a7.css +0 -2
- package/dist/node/map-interface.791d22a7.css.map +0 -1
- package/dist/node/map-interface.7963263e.js +0 -2
- package/dist/node/map-interface.7963263e.js.map +0 -1
- package/dist/node/map-interface.995ff472.js +0 -2
- package/dist/node/map-interface.995ff472.js.map +0 -1
- package/dist/node/map-interface.bbeeb59c.js +0 -2
- package/dist/node/map-interface.bbeeb59c.js.map +0 -1
- package/dist/node/map-interface.bf061b97.js +0 -2
- package/dist/node/map-interface.bf061b97.js.map +0 -1
- package/dist/node/map-interface.c3275c05.js +0 -2
- package/dist/node/map-interface.c3275c05.js.map +0 -1
- package/dist/node/map-interface.c8139e21.js +0 -2
- package/dist/node/map-interface.c8139e21.js.map +0 -1
- package/dist/node/map-interface.ca6e8916.js +0 -2
- package/dist/node/map-interface.ca6e8916.js.map +0 -1
- package/dist/node/map-interface.d430c066.css +0 -2
- package/dist/node/map-interface.d430c066.css.map +0 -1
- package/dist/node/map-interface.d4cd446a.js +0 -2
- package/dist/node/map-interface.d4cd446a.js.map +0 -1
- package/dist/node/map-interface.ecfe462b.js +0 -2
- package/dist/node/map-interface.ecfe462b.js.map +0 -1
- package/dist/node/map-interface.ee63d11f.js +0 -2
- package/dist/node/map-interface.ee63d11f.js.map +0 -1
- package/dist/node/map-interface.f42969c3.js +0 -2
- package/dist/node/map-interface.f42969c3.js.map +0 -1
- package/dist/node/map-interface.fbe01b07.js +0 -2
- package/dist/node/map-interface.fbe01b07.js.map +0 -1
- package/dist/node/map-interface.fcb95c23.js.map +0 -1
- package/dist/node/map-interface.fecb181b.js +0 -2
- package/dist/node/map-interface.fecb181b.js.map +0 -1
- package/src/map-panel/components/buttons.module.styl +0 -5
- package/src/map-panel/components/buttons.ts +0 -56
- package/src/map-panel/components/card.module.styl +0 -43
- package/src/map-panel/components/closeable-card.ts +0 -64
- package/src/map-panel/components/docs.module.styl +0 -93
- package/src/map-panel/components/docs.ts +0 -92
- package/src/map-panel/components/info-drawer/index.ts +0 -152
- package/src/map-panel/components/transitions/index.ts +0 -24
- package/src/map-panel/components/transitions/main.module.styl +0 -55
- package/src/map-panel/index.ts +0 -1
- /package/src/{map-panel/components/info-drawer → location-details}/fossil-collections/main.module.sass +0 -0
- /package/src/{map-panel/components → location-details}/info-blocks.module.styl +0 -0
- /package/src/{map-panel/components/info-drawer → location-details}/main.module.styl +0 -0
- /package/src/{map-panel → location-details}/utils/formatting.ts +0 -0
- /package/src/{map-panel → location-details}/utils/index.ts +0 -0
- /package/src/{map-panel/components/info-drawer → location-details}/xdd-panel/Article.tsx +0 -0
- /package/src/{map-panel/components/info-drawer → location-details}/xdd-panel/Journal.tsx +0 -0
|
@@ -1,381 +0,0 @@
|
|
|
1
|
-
var $dd32e7ae54443412$exports = require("./map-interface.b6e70f1b.js");
|
|
2
|
-
require("./map-interface.1be58b40.css");
|
|
3
|
-
var $f2e0b9e87d965c31$exports = require("./map-interface.9893b047.js");
|
|
4
|
-
var $7j411$macrostrathyper = require("@macrostrat/hyper");
|
|
5
|
-
var $7j411$macrostratmapinterface = require("@macrostrat/map-interface");
|
|
6
|
-
var $7j411$visxscale = require("@visx/scale");
|
|
7
|
-
var $7j411$visxaxis = require("@visx/axis");
|
|
8
|
-
var $7j411$chromajs = require("chroma-js");
|
|
9
|
-
var $7j411$macrostratdatacomponents = require("@macrostrat/data-components");
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
function $parcel$interopDefault(a) {
|
|
13
|
-
return a && a.__esModule ? a.default : a;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
function $parcel$export(e, n, v, s) {
|
|
17
|
-
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
$parcel$export(module.exports, "MacrostratLinkedData", () => $8569970142f4fcfc$export$fa9d8c2f420ac2bd);
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
const $8569970142f4fcfc$var$h = (0, ($parcel$interopDefault($7j411$macrostrathyper))).styled((0, ($parcel$interopDefault($f2e0b9e87d965c31$exports))));
|
|
30
|
-
function $8569970142f4fcfc$export$fa9d8c2f420ac2bd(props) {
|
|
31
|
-
const { mapInfo: mapInfo, bedrockMatchExpanded: bedrockMatchExpanded, source: source } = props;
|
|
32
|
-
if (!mapInfo.mapData[0]) return $8569970142f4fcfc$var$h("div");
|
|
33
|
-
return $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpansionPanel), {
|
|
34
|
-
className: "regional-panel",
|
|
35
|
-
title: "Macrostrat-linked data",
|
|
36
|
-
helpText: "via Macrostrat",
|
|
37
|
-
expanded: bedrockMatchExpanded
|
|
38
|
-
}, [
|
|
39
|
-
$8569970142f4fcfc$var$h("div", {
|
|
40
|
-
classes: $8569970142f4fcfc$var$expansionPanelDetailClasses
|
|
41
|
-
}, [
|
|
42
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$MatchBasis, {
|
|
43
|
-
source: source
|
|
44
|
-
}),
|
|
45
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$AgeInformation, {
|
|
46
|
-
mapInfo: mapInfo,
|
|
47
|
-
source: source
|
|
48
|
-
}),
|
|
49
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$Thickness, {
|
|
50
|
-
source: source
|
|
51
|
-
}),
|
|
52
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$MinorFossilCollections, {
|
|
53
|
-
source: source
|
|
54
|
-
}),
|
|
55
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$FossilOccs, {
|
|
56
|
-
source: source
|
|
57
|
-
}),
|
|
58
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$LithsAndClasses, {
|
|
59
|
-
source: source
|
|
60
|
-
}),
|
|
61
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$Environments, {
|
|
62
|
-
source: source
|
|
63
|
-
}),
|
|
64
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$Economy, {
|
|
65
|
-
source: source
|
|
66
|
-
})
|
|
67
|
-
])
|
|
68
|
-
]);
|
|
69
|
-
}
|
|
70
|
-
const $8569970142f4fcfc$var$expansionPanelDetailClasses = {
|
|
71
|
-
root: "expansion-panel-detail"
|
|
72
|
-
};
|
|
73
|
-
function $8569970142f4fcfc$var$AgeInformation(props) {
|
|
74
|
-
const { source: source, mapInfo: mapInfo } = props;
|
|
75
|
-
const { macrostrat: macrostrat } = source;
|
|
76
|
-
if (!macrostrat?.b_age) return $8569970142f4fcfc$var$h($8569970142f4fcfc$var$MapAgeRenderer, {
|
|
77
|
-
mapInfo: mapInfo
|
|
78
|
-
});
|
|
79
|
-
return $8569970142f4fcfc$var$h($8569970142f4fcfc$var$MacrostratAgeInfo, {
|
|
80
|
-
macrostrat: macrostrat,
|
|
81
|
-
mapInfo: mapInfo
|
|
82
|
-
});
|
|
83
|
-
}
|
|
84
|
-
function $8569970142f4fcfc$var$MapAgeRenderer(props) {
|
|
85
|
-
const { mapInfo: mapInfo, ...rest } = props;
|
|
86
|
-
return $8569970142f4fcfc$var$h($8569970142f4fcfc$var$DescribedAgeInfo, {
|
|
87
|
-
ageElement: $8569970142f4fcfc$var$h((0, $dd32e7ae54443412$exports.AgeChip), {
|
|
88
|
-
b_int: mapInfo.mapData[0].b_int,
|
|
89
|
-
t_int: mapInfo.mapData[0].t_int
|
|
90
|
-
})
|
|
91
|
-
}, "Based on geologic map description.");
|
|
92
|
-
}
|
|
93
|
-
function $8569970142f4fcfc$var$DescribedAgeInfo(props) {
|
|
94
|
-
const { ageElement: ageElement, children: children, className: className } = props;
|
|
95
|
-
return $8569970142f4fcfc$var$h("div.described-age.macrostrast-detail", [
|
|
96
|
-
$8569970142f4fcfc$var$h("div.expansion-summary-title", "Age"),
|
|
97
|
-
$8569970142f4fcfc$var$h("div.age-chips", null, ageElement),
|
|
98
|
-
$8569970142f4fcfc$var$h("div.description", children)
|
|
99
|
-
]);
|
|
100
|
-
}
|
|
101
|
-
function $8569970142f4fcfc$var$AgeRefinementBar({ scale: scale, data: data, color: color, label: label = null }) {
|
|
102
|
-
const { b_int: b_int, t_int: t_int } = data;
|
|
103
|
-
const b_age = data.b_age ?? b_int.b_age;
|
|
104
|
-
const t_age = data.t_age ?? t_int.t_age;
|
|
105
|
-
const backgroundColor = color ?? b_int.color;
|
|
106
|
-
const accentColor = (0, ($parcel$interopDefault($7j411$chromajs)))(backgroundColor).darken(0.5).hex();
|
|
107
|
-
const labelColor = (0, ($parcel$interopDefault($7j411$chromajs)))(backgroundColor).darken(2).hex();
|
|
108
|
-
const left = scale(b_age);
|
|
109
|
-
const width = scale(t_age) - scale(b_age);
|
|
110
|
-
let labelTranslate = 5;
|
|
111
|
-
let textAlign = "start";
|
|
112
|
-
// Adjust label placement
|
|
113
|
-
if (width < 100) {
|
|
114
|
-
if (left < 100) labelTranslate = width + 5;
|
|
115
|
-
else {
|
|
116
|
-
labelTranslate = -305;
|
|
117
|
-
textAlign = "end";
|
|
118
|
-
}
|
|
119
|
-
}
|
|
120
|
-
return $8569970142f4fcfc$var$h("div.age-refinement-bar", {
|
|
121
|
-
style: {
|
|
122
|
-
marginLeft: `${left}px`,
|
|
123
|
-
width: `${width}px`,
|
|
124
|
-
height: "18px",
|
|
125
|
-
backgroundColor: backgroundColor,
|
|
126
|
-
border: `2px solid ${accentColor}`,
|
|
127
|
-
position: "relative"
|
|
128
|
-
}
|
|
129
|
-
}, $8569970142f4fcfc$var$h("div.age-refinement-bar-label", {
|
|
130
|
-
style: {
|
|
131
|
-
transform: `translateX(${labelTranslate}px)`,
|
|
132
|
-
color: labelColor,
|
|
133
|
-
fontSize: "10px",
|
|
134
|
-
width: 300,
|
|
135
|
-
textAlign: textAlign
|
|
136
|
-
}
|
|
137
|
-
}, label));
|
|
138
|
-
}
|
|
139
|
-
function $8569970142f4fcfc$var$AgeRefinementPlot({ macrostrat: macrostrat, mapInfo: mapInfo }) {
|
|
140
|
-
// Plot the amount by which the age was refined
|
|
141
|
-
const mapData = mapInfo.mapData[0];
|
|
142
|
-
const b_age = Math.max(mapData.b_int.b_age, macrostrat.b_age);
|
|
143
|
-
const t_age = Math.min(mapData.t_int.t_age, macrostrat.t_age);
|
|
144
|
-
const scale = (0, $7j411$visxscale.scaleLinear)({
|
|
145
|
-
domain: [
|
|
146
|
-
1.02 * b_age,
|
|
147
|
-
t_age * 0.98
|
|
148
|
-
],
|
|
149
|
-
range: [
|
|
150
|
-
20,
|
|
151
|
-
360
|
|
152
|
-
]
|
|
153
|
-
});
|
|
154
|
-
// use visx to plot the age refinement
|
|
155
|
-
return $8569970142f4fcfc$var$h("div.age-refinement-plot", [
|
|
156
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$AgeRefinementBar, {
|
|
157
|
-
scale: scale,
|
|
158
|
-
data: macrostrat,
|
|
159
|
-
label: "Macrostrat age model"
|
|
160
|
-
}),
|
|
161
|
-
$8569970142f4fcfc$var$h($8569970142f4fcfc$var$AgeRefinementBar, {
|
|
162
|
-
scale: scale,
|
|
163
|
-
data: mapData,
|
|
164
|
-
label: "Map legend"
|
|
165
|
-
}),
|
|
166
|
-
// Age axis
|
|
167
|
-
$8569970142f4fcfc$var$h("svg", {
|
|
168
|
-
width: "100%",
|
|
169
|
-
height: "40px"
|
|
170
|
-
}, [
|
|
171
|
-
$8569970142f4fcfc$var$h((0, $7j411$visxaxis.AxisBottom), {
|
|
172
|
-
scale: scale,
|
|
173
|
-
numTicks: 5,
|
|
174
|
-
top: 1,
|
|
175
|
-
left: 0,
|
|
176
|
-
label: "Age (Ma)"
|
|
177
|
-
})
|
|
178
|
-
])
|
|
179
|
-
]);
|
|
180
|
-
}
|
|
181
|
-
function $8569970142f4fcfc$var$MacrostratAgeInfoCore({ macrostrat: macrostrat }) {
|
|
182
|
-
const { b_age: b_age, t_age: t_age, b_int: b_int, t_int: t_int } = macrostrat;
|
|
183
|
-
if (!b_age) return null;
|
|
184
|
-
let age = b_int.int_name;
|
|
185
|
-
if (b_int.int_id !== t_int.int_id) age += ` - ${t_int.int_name}`;
|
|
186
|
-
return $8569970142f4fcfc$var$h($8569970142f4fcfc$var$DescribedAgeInfo, {
|
|
187
|
-
ageElement: $8569970142f4fcfc$var$h((0, $dd32e7ae54443412$exports.AgeChip), {
|
|
188
|
-
b_int: {
|
|
189
|
-
...b_int,
|
|
190
|
-
int_name: age,
|
|
191
|
-
b_age: b_age,
|
|
192
|
-
t_age: t_age
|
|
193
|
-
},
|
|
194
|
-
t_int: {
|
|
195
|
-
...b_int,
|
|
196
|
-
int_name: age,
|
|
197
|
-
b_age: b_age,
|
|
198
|
-
t_age: t_age
|
|
199
|
-
}
|
|
200
|
-
})
|
|
201
|
-
}, "Refined using the Macrostrat age model.");
|
|
202
|
-
}
|
|
203
|
-
function $8569970142f4fcfc$var$MacrostratAgeInfo(props) {
|
|
204
|
-
return $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpandableDetailsPanel), {
|
|
205
|
-
headerElement: $8569970142f4fcfc$var$h($8569970142f4fcfc$var$MacrostratAgeInfoCore, props)
|
|
206
|
-
}, $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpansionBody), {
|
|
207
|
-
title: "Age refinement"
|
|
208
|
-
}, $8569970142f4fcfc$var$h($8569970142f4fcfc$var$AgeRefinementPlot, props)));
|
|
209
|
-
}
|
|
210
|
-
function $8569970142f4fcfc$var$MatchBasis(props) {
|
|
211
|
-
const { source: source } = props;
|
|
212
|
-
if (!source.macrostrat?.strat_names) return null;
|
|
213
|
-
return $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpandableDetailsPanel), {
|
|
214
|
-
className: "macrostrat-unit",
|
|
215
|
-
headerElement: $8569970142f4fcfc$var$h([
|
|
216
|
-
$8569970142f4fcfc$var$h("h3", source.macrostrat.strat_names[0].rank_name),
|
|
217
|
-
$8569970142f4fcfc$var$h("div.description", "Matched stratigraphic unit")
|
|
218
|
-
])
|
|
219
|
-
}, $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpansionBody), {
|
|
220
|
-
title: "All matched names"
|
|
221
|
-
}, [
|
|
222
|
-
source.macrostrat.strat_names.map((name, i)=>{
|
|
223
|
-
let lastElement = i == source.macrostrat.strat_names.length - 1;
|
|
224
|
-
return $8569970142f4fcfc$var$h("span", {
|
|
225
|
-
key: i
|
|
226
|
-
}, [
|
|
227
|
-
$8569970142f4fcfc$var$h("a.externalLink", {
|
|
228
|
-
href: "/lex/strat-names/" + name.strat_name_id,
|
|
229
|
-
key: i
|
|
230
|
-
}, [
|
|
231
|
-
name.rank_name
|
|
232
|
-
]),
|
|
233
|
-
$8569970142f4fcfc$var$h.if(!lastElement)([
|
|
234
|
-
", "
|
|
235
|
-
])
|
|
236
|
-
]);
|
|
237
|
-
})
|
|
238
|
-
]));
|
|
239
|
-
}
|
|
240
|
-
function $8569970142f4fcfc$var$Thickness(props) {
|
|
241
|
-
const { source: source } = props;
|
|
242
|
-
if (!source.macrostrat.max_thick) return $8569970142f4fcfc$var$h("div");
|
|
243
|
-
return $8569970142f4fcfc$var$h.if(source.macrostrat && source.macrostrat.max_thick)("div.macrostrat-detail", [
|
|
244
|
-
$8569970142f4fcfc$var$h("div.expansion-summary-title", "Thickness"),
|
|
245
|
-
$8569970142f4fcfc$var$h("div", [
|
|
246
|
-
source.macrostrat.min_min_thick,
|
|
247
|
-
" - ",
|
|
248
|
-
source.macrostrat.max_thick,
|
|
249
|
-
"m"
|
|
250
|
-
])
|
|
251
|
-
]);
|
|
252
|
-
}
|
|
253
|
-
function $8569970142f4fcfc$var$MinorFossilCollections(props) {
|
|
254
|
-
const { source: source } = props;
|
|
255
|
-
const { macrostrat: macrostrat } = source;
|
|
256
|
-
if (!macrostrat.pbdb_collections) return $8569970142f4fcfc$var$h("div");
|
|
257
|
-
return $8569970142f4fcfc$var$h.if(macrostrat && macrostrat.pbdb_collections)("div.macrostrat-detail", [
|
|
258
|
-
$8569970142f4fcfc$var$h("div.expansion-summary-title", "Fossil collections"),
|
|
259
|
-
$8569970142f4fcfc$var$h("div", [
|
|
260
|
-
macrostrat.pbdb_collections
|
|
261
|
-
])
|
|
262
|
-
]);
|
|
263
|
-
}
|
|
264
|
-
function $8569970142f4fcfc$var$FossilOccs(props) {
|
|
265
|
-
const { source: source } = props;
|
|
266
|
-
const { macrostrat: macrostrat } = source;
|
|
267
|
-
if (!macrostrat?.pbdb_occs) return null;
|
|
268
|
-
return $8569970142f4fcfc$var$h("div.macrostrat-detail", [
|
|
269
|
-
$8569970142f4fcfc$var$h("div.expansion-summary-title", "Fossil occurrences"),
|
|
270
|
-
$8569970142f4fcfc$var$h("div", [
|
|
271
|
-
macrostrat.pbdb_occs
|
|
272
|
-
])
|
|
273
|
-
]);
|
|
274
|
-
}
|
|
275
|
-
function $8569970142f4fcfc$var$LithTypes(props) {
|
|
276
|
-
const { lith_types: lith_types } = props;
|
|
277
|
-
return $8569970142f4fcfc$var$h.if(lith_types && lith_types.length > 0)("div.lithologies.lithology-types", [
|
|
278
|
-
$8569970142f4fcfc$var$h((0, $7j411$macrostratdatacomponents.LithologyList), {
|
|
279
|
-
lithologies: lith_types
|
|
280
|
-
})
|
|
281
|
-
]);
|
|
282
|
-
}
|
|
283
|
-
function $8569970142f4fcfc$var$LithsAndClasses(props) {
|
|
284
|
-
const { source: source } = props;
|
|
285
|
-
const { macrostrat: macrostrat } = source;
|
|
286
|
-
const { liths: liths = null, lith_types: lith_types = null } = macrostrat;
|
|
287
|
-
if (!liths || liths.length == 0) return null;
|
|
288
|
-
const lithologies = liths.map((lith)=>{
|
|
289
|
-
return {
|
|
290
|
-
...lith,
|
|
291
|
-
name: lith.lith,
|
|
292
|
-
color: lith.color || "#000000"
|
|
293
|
-
};
|
|
294
|
-
});
|
|
295
|
-
return $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpandableDetailsPanel), {
|
|
296
|
-
title: "Lithology",
|
|
297
|
-
value: $8569970142f4fcfc$var$h($8569970142f4fcfc$var$LithTypes, {
|
|
298
|
-
lith_types: lith_types
|
|
299
|
-
})
|
|
300
|
-
}, $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpansionBody), {
|
|
301
|
-
title: "Matched lithologies"
|
|
302
|
-
}, [
|
|
303
|
-
$8569970142f4fcfc$var$h((0, $7j411$macrostratdatacomponents.LithologyList), {
|
|
304
|
-
lithologies: lithologies,
|
|
305
|
-
onClickItem: (e, lith)=>{
|
|
306
|
-
window.open("/lex/lithology/" + lith.lith_id, "_self");
|
|
307
|
-
}
|
|
308
|
-
})
|
|
309
|
-
]));
|
|
310
|
-
}
|
|
311
|
-
function $8569970142f4fcfc$var$EnvironTypes(props) {
|
|
312
|
-
const { environ_types: environ_types } = props;
|
|
313
|
-
return $8569970142f4fcfc$var$h.if(environ_types && environ_types.length > 0)((0, $7j411$macrostratdatacomponents.LithologyList), {
|
|
314
|
-
lithologies: environ_types?.filter((e)=>e.name != "")
|
|
315
|
-
});
|
|
316
|
-
}
|
|
317
|
-
function $8569970142f4fcfc$var$Environments(props) {
|
|
318
|
-
const { source: source } = props;
|
|
319
|
-
const { macrostrat: macrostrat } = source;
|
|
320
|
-
const { environs: environs = null, environ_types: environ_types = null } = macrostrat;
|
|
321
|
-
if (!environs || environs.length == 0) return null;
|
|
322
|
-
const lithologies = environs.map((environ)=>{
|
|
323
|
-
return {
|
|
324
|
-
...environ,
|
|
325
|
-
name: environ.environ,
|
|
326
|
-
color: environ.color || "#000000"
|
|
327
|
-
};
|
|
328
|
-
});
|
|
329
|
-
return $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpandableDetailsPanel), {
|
|
330
|
-
title: "Environment",
|
|
331
|
-
value: $8569970142f4fcfc$var$h($8569970142f4fcfc$var$EnvironTypes, {
|
|
332
|
-
environ_types: environ_types
|
|
333
|
-
})
|
|
334
|
-
}, $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpansionBody), {
|
|
335
|
-
title: "Matched environments"
|
|
336
|
-
}, [
|
|
337
|
-
$8569970142f4fcfc$var$h((0, $7j411$macrostratdatacomponents.LithologyList), {
|
|
338
|
-
lithologies: lithologies,
|
|
339
|
-
onClickItem: (e, environ)=>{
|
|
340
|
-
window.open("/lex/environments/" + environ.environ_id, "_self");
|
|
341
|
-
}
|
|
342
|
-
})
|
|
343
|
-
]));
|
|
344
|
-
}
|
|
345
|
-
function $8569970142f4fcfc$var$EconType(props) {
|
|
346
|
-
const { econ_types: econ_types } = props;
|
|
347
|
-
return $8569970142f4fcfc$var$h.if(econ_types && econ_types.length > 0)("div", [
|
|
348
|
-
econ_types.map((econClass, i)=>{
|
|
349
|
-
return $8569970142f4fcfc$var$h((0, $dd32e7ae54443412$exports.AttrChip), {
|
|
350
|
-
key: i,
|
|
351
|
-
name: econClass.name,
|
|
352
|
-
color: econClass.color
|
|
353
|
-
});
|
|
354
|
-
})
|
|
355
|
-
]);
|
|
356
|
-
}
|
|
357
|
-
function $8569970142f4fcfc$var$Economy(props) {
|
|
358
|
-
const { source: source } = props;
|
|
359
|
-
const { macrostrat: macrostrat } = source;
|
|
360
|
-
const { econs: econs = null, econ_types: econ_types = null } = macrostrat;
|
|
361
|
-
if (!econs) return $8569970142f4fcfc$var$h("div");
|
|
362
|
-
return $8569970142f4fcfc$var$h.if(econs && econs.length > 0)((0, $7j411$macrostratmapinterface.ExpandableDetailsPanel), {
|
|
363
|
-
title: "Economy ",
|
|
364
|
-
value: $8569970142f4fcfc$var$h($8569970142f4fcfc$var$EconType, {
|
|
365
|
-
econ_types: econ_types
|
|
366
|
-
})
|
|
367
|
-
}, $8569970142f4fcfc$var$h((0, $7j411$macrostratmapinterface.ExpansionBody), {
|
|
368
|
-
title: "Matched economic attributes"
|
|
369
|
-
}, [
|
|
370
|
-
econs.map((econ, i)=>{
|
|
371
|
-
return $8569970142f4fcfc$var$h((0, $dd32e7ae54443412$exports.AttrChip), {
|
|
372
|
-
key: i,
|
|
373
|
-
name: econ.econ,
|
|
374
|
-
color: econ.color
|
|
375
|
-
});
|
|
376
|
-
})
|
|
377
|
-
]));
|
|
378
|
-
}
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
//# sourceMappingURL=map-interface.727092bc.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;AAaA,MAAM,0BAAI,CAAA,GAAA,gDAAI,EAAE,MAAM,CAAC,CAAA,GAAA,mDAAK;AAE5B,SAAS,0CAAqB,KAAK;IACjC,MAAM,WAAE,OAAO,wBAAE,oBAAoB,UAAE,MAAM,EAAE,GAAG;IAElD,IAAI,CAAC,QAAQ,OAAO,CAAC,EAAE,EAAE,OAAO,wBAAE;IAElC,OAAO,wBACL,CAAA,GAAA,4CAAa,GACb;QACE,WAAW;QACX,OAAO;QACP,UAAU;QACV,UAAU;IACZ,GACA;QACE,wBAAE,OAAO;YAAE,SAAS;QAA4B,GAAG;YACjD,wBAAE,kCAAY;wBAAE;YAAO;YACvB,wBAAE,sCAAgB;yBAAE;wBAAS;YAAO;YACpC,wBAAE,iCAAW;wBAAE;YAAO;YACtB,wBAAE,8CAAwB;wBAAE;YAAO;YACnC,wBAAE,kCAAY;wBAAE;YAAO;YACv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"],"sourcesContent":["import hyper from \"@macrostrat/hyper\";\nimport { AgeChip, AttrChip } from \"../info-blocks\";\nimport {\n ExpansionPanel,\n ExpandableDetailsPanel,\n ExpansionBody,\n} from \"@macrostrat/map-interface\";\nimport styles from \"./main.module.styl\";\nimport { scaleLinear } from \"@visx/scale\";\nimport { AxisBottom } from \"@visx/axis\";\nimport chroma from \"chroma-js\";\nimport { LithologyList } from \"@macrostrat/data-components\";\n\nconst h = hyper.styled(styles);\n\nfunction MacrostratLinkedData(props) {\n const { mapInfo, bedrockMatchExpanded, source } = props;\n\n if (!mapInfo.mapData[0]) return h(\"div\");\n\n return h(\n ExpansionPanel,\n {\n className: \"regional-panel\",\n title: \"Macrostrat-linked data\",\n helpText: \"via Macrostrat\",\n expanded: bedrockMatchExpanded,\n },\n [\n h(\"div\", { classes: expansionPanelDetailClasses }, [\n h(MatchBasis, { source }),\n h(AgeInformation, { mapInfo, source }),\n h(Thickness, { source }),\n h(MinorFossilCollections, { source }),\n h(FossilOccs, { source }),\n h(LithsAndClasses, { source }),\n h(Environments, { source }),\n h(Economy, { source }),\n ]),\n ],\n );\n}\n\nconst expansionPanelDetailClasses = {\n root: \"expansion-panel-detail\",\n};\n\nfunction AgeInformation(props) {\n const { source, mapInfo } = props;\n const { macrostrat } = source;\n\n if (!macrostrat?.b_age) return h(MapAgeRenderer, { mapInfo });\n\n return h(MacrostratAgeInfo, { macrostrat, mapInfo });\n}\n\nfunction MapAgeRenderer(props) {\n const { mapInfo, ...rest } = props;\n return h(\n DescribedAgeInfo,\n {\n ageElement: h(AgeChip, {\n b_int: mapInfo.mapData[0].b_int,\n t_int: mapInfo.mapData[0].t_int,\n }),\n },\n \"Based on geologic map description.\",\n );\n}\n\nfunction DescribedAgeInfo(props) {\n const { ageElement, children, className } = props;\n\n return h(\"div.described-age.macrostrast-detail\", [\n h(\"div.expansion-summary-title\", \"Age\"),\n h(\"div.age-chips\", null, ageElement),\n h(\"div.description\", children),\n ]);\n}\n\nfunction AgeRefinementBar({ scale, data, color, label = null }) {\n const { b_int, t_int } = data;\n const b_age = data.b_age ?? b_int.b_age;\n const t_age = data.t_age ?? t_int.t_age;\n const backgroundColor = color ?? b_int.color;\n const accentColor = chroma(backgroundColor).darken(0.5).hex();\n const labelColor = chroma(backgroundColor).darken(2).hex();\n\n const left = scale(b_age);\n const width = scale(t_age) - scale(b_age);\n\n let labelTranslate = 5;\n let textAlign = \"start\";\n\n // Adjust label placement\n\n if (width < 100) {\n if (left < 100) {\n labelTranslate = width + 5;\n } else {\n labelTranslate = -305;\n textAlign = \"end\";\n }\n }\n\n return h(\n \"div.age-refinement-bar\",\n {\n style: {\n marginLeft: `${left}px`,\n width: `${width}px`,\n height: \"18px\",\n backgroundColor,\n border: `2px solid ${accentColor}`,\n position: \"relative\",\n },\n },\n h(\n \"div.age-refinement-bar-label\",\n {\n style: {\n transform: `translateX(${labelTranslate}px)`,\n color: labelColor,\n fontSize: \"10px\",\n width: 300,\n textAlign,\n },\n },\n label,\n ),\n );\n}\n\nfunction AgeRefinementPlot({ macrostrat, mapInfo }) {\n // Plot the amount by which the age was refined\n\n const mapData = mapInfo.mapData[0];\n const b_age = Math.max(mapData.b_int.b_age, macrostrat.b_age);\n const t_age = Math.min(mapData.t_int.t_age, macrostrat.t_age);\n\n const scale = scaleLinear({\n domain: [1.02 * b_age, t_age * 0.98],\n range: [20, 360],\n });\n\n // use visx to plot the age refinement\n return h(\"div.age-refinement-plot\", [\n h(AgeRefinementBar, {\n scale,\n data: macrostrat,\n label: \"Macrostrat age model\",\n }),\n h(AgeRefinementBar, {\n scale,\n data: mapData,\n label: \"Map legend\",\n }),\n // Age axis\n h(\"svg\", { width: \"100%\", height: \"40px\" }, [\n h(AxisBottom, {\n scale,\n numTicks: 5,\n top: 1,\n left: 0,\n label: \"Age (Ma)\",\n }),\n ]),\n ]);\n}\n\nfunction MacrostratAgeInfoCore({ macrostrat }) {\n const { b_age, t_age, b_int, t_int } = macrostrat;\n\n if (!b_age) return null;\n\n let age = b_int.int_name;\n if (b_int.int_id !== t_int.int_id) {\n age += ` - ${t_int.int_name}`;\n }\n return h(\n DescribedAgeInfo,\n {\n ageElement: h(AgeChip, {\n b_int: { ...b_int, int_name: age, b_age, t_age },\n t_int: { ...b_int, int_name: age, b_age, t_age },\n }),\n },\n \"Refined using the Macrostrat age model.\",\n );\n}\n\nfunction MacrostratAgeInfo(props) {\n return h(\n ExpandableDetailsPanel,\n { headerElement: h(MacrostratAgeInfoCore, props) },\n h(ExpansionBody, { title: \"Age refinement\" }, h(AgeRefinementPlot, props)),\n );\n}\n\nfunction MatchBasis(props) {\n const { source } = props;\n if (!source.macrostrat?.strat_names) return null;\n\n return h(\n ExpandableDetailsPanel,\n {\n className: \"macrostrat-unit\",\n headerElement: h([\n h(\"h3\", source.macrostrat.strat_names[0].rank_name),\n h(\"div.description\", \"Matched stratigraphic unit\"),\n ]),\n },\n h(ExpansionBody, { title: \"All matched names\" }, [\n source.macrostrat.strat_names.map((name, i) => {\n let lastElement: boolean =\n i == source.macrostrat.strat_names.length - 1;\n return h(\"span\", { key: i }, [\n h(\n \"a.externalLink\",\n {\n href: \"/lex/strat-names/\" + name.strat_name_id,\n key: i,\n },\n [name.rank_name],\n ),\n h.if(!lastElement)([\", \"]),\n ]);\n }),\n ]),\n );\n}\n\nfunction Thickness(props) {\n const { source } = props;\n if (!source.macrostrat.max_thick) return h(\"div\");\n\n return h.if(source.macrostrat && source.macrostrat.max_thick)(\n \"div.macrostrat-detail\",\n [\n h(\"div.expansion-summary-title\", \"Thickness\"),\n h(\"div\", [\n source.macrostrat.min_min_thick,\n \" - \",\n source.macrostrat.max_thick,\n \"m\",\n ]),\n ],\n );\n}\n\nfunction MinorFossilCollections(props) {\n const { source } = props;\n const { macrostrat } = source;\n if (!macrostrat.pbdb_collections) return h(\"div\");\n\n return h.if(macrostrat && macrostrat.pbdb_collections)(\n \"div.macrostrat-detail\",\n [\n h(\"div.expansion-summary-title\", \"Fossil collections\"),\n h(\"div\", [macrostrat.pbdb_collections]),\n ],\n );\n}\n\nfunction FossilOccs(props) {\n const { source } = props;\n const { macrostrat } = source;\n\n if (!macrostrat?.pbdb_occs) return null;\n\n return h(\"div.macrostrat-detail\", [\n h(\"div.expansion-summary-title\", \"Fossil occurrences\"),\n h(\"div\", [macrostrat.pbdb_occs]),\n ]);\n}\n\nfunction LithTypes(props) {\n const { lith_types } = props;\n\n return h.if(lith_types && lith_types.length > 0)(\n \"div.lithologies.lithology-types\",\n [\n h(LithologyList, {\n lithologies: lith_types,\n }),\n ],\n );\n}\n\nfunction LithsAndClasses(props) {\n const { source } = props;\n const { macrostrat } = source;\n const { liths = null, lith_types = null } = macrostrat;\n\n if (!liths || liths.length == 0) return null;\n\n const lithologies = liths.map((lith) => {\n return {\n ...lith,\n name: lith.lith,\n color: lith.color || \"#000000\",\n };\n });\n\n return h(\n ExpandableDetailsPanel,\n {\n title: \"Lithology\",\n value: h(LithTypes, { lith_types }),\n },\n h(ExpansionBody, { title: \"Matched lithologies\" }, [\n h(LithologyList, {\n lithologies,\n onClickItem: (e, lith) => {\n window.open(\"/lex/lithology/\" + lith.lith_id, \"_self\");\n },\n }),\n ]),\n );\n}\n\nfunction EnvironTypes(props) {\n const { environ_types } = props;\n return h.if(environ_types && environ_types.length > 0)(LithologyList, {\n lithologies: environ_types?.filter((e) => e.name != \"\"),\n });\n}\n\nfunction Environments(props) {\n const { source } = props;\n const { macrostrat } = source;\n const { environs = null, environ_types = null } = macrostrat;\n\n if (!environs || environs.length == 0) return null;\n\n const lithologies = environs.map((environ) => {\n return {\n ...environ,\n name: environ.environ,\n color: environ.color || \"#000000\",\n };\n });\n\n return h(\n ExpandableDetailsPanel,\n {\n title: \"Environment\",\n value: h(EnvironTypes, { environ_types }),\n },\n h(ExpansionBody, { title: \"Matched environments\" }, [\n h(LithologyList, {\n lithologies,\n onClickItem: (e, environ) => {\n window.open(\"/lex/environments/\" + environ.environ_id, \"_self\");\n },\n }),\n ]),\n );\n}\n\nfunction EconType(props) {\n const { econ_types } = props;\n\n return h.if(econ_types && econ_types.length > 0)(\"div\", [\n econ_types.map((econClass, i) => {\n return h(AttrChip, {\n key: i,\n name: econClass.name,\n color: econClass.color,\n });\n }),\n ]);\n}\n\nfunction Economy(props) {\n const { source } = props;\n const { macrostrat } = source;\n const { econs = null, econ_types = null } = macrostrat;\n if (!econs) return h(\"div\");\n\n return h.if(econs && econs.length > 0)(\n ExpandableDetailsPanel,\n {\n title: \"Economy \",\n value: h(EconType, { econ_types }),\n },\n h(ExpansionBody, { title: \"Matched economic attributes\" }, [\n econs.map((econ, i) => {\n return h(AttrChip, {\n key: i,\n name: econ.econ,\n color: econ.color,\n });\n }),\n ]),\n );\n}\n\nexport { MacrostratLinkedData };\n"],"names":[],"version":3,"file":"map-interface.727092bc.js.map"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"mappings":";;;;;;AAAO,SAAS,0CAAmB,IAAI;IACrC,IAAI,iBAAiB;QAAE,OAAO,EAAE;IAAC;IACjC,IAAI,UAAU;QACZ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,IAAI;QACJ,GAAG;QACH,GAAG;QACH,GAAG;QACH,GAAG;QACH,GAAG;QACH,GAAG;QACH,GAAG;QACH,GAAG;IACL;IAEA,SAAS,SAAS,IAAI,EAAE,IAAI,EAAE,QAAQ;QACpC,IAAK,IAAI,IAAI,GAAG,MAAM,KAAK,MAAM,EAAE,IAAI,KAAK,IAAK;YAC/C,IAAI,IAAI,CAAC,EAAE,CAAC,SAAS,KAAK,MAAM,OAAO;QACzC;QACA,OAAO;IACT;IAEA,QAAQ,GAAG,CAAC,6BAA6B;IAEzC,KAAK,OAAO,CAAC,CAAC;QACZ,qBAAqB;QACrB,EAAE,IAAI,GAAG,EAAE,GAAG,GA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AAC,MAAM,KAAK,aAAa;YACzD,eAAe,KAAK,CAAC,EAAE,CAAC,MAAM,GAAG;YACjC,eAAe,KAAK,CAAC,EAAE,CAAC,QAAQ,GAAG;QACrC;IACF;IAEA,OAAO;AACT","sources":["packages/map-interface/src/map-panel/utils/fossils.ts"],"sourcesContent":["export function makeOccurrenceTree(data) {\n let occurrenceTree = { phyla: [] };\n let rankMap = {\n 25: \"unranked\",\n 23: \"kingdom\",\n 22: \"subkingdom\",\n 21: \"superphylum\",\n 20: \"phylum\",\n 19: \"subphylum\",\n 18: \"superclass\",\n 17: \"class\",\n 16: \"subclass\",\n 15: \"infraclass\",\n 14: \"superorder\",\n 13: \"order\",\n 12: \"suborder\",\n 11: \"infraorder\",\n 10: \"superfamily\",\n 9: \"family\",\n 8: \"subfamily\",\n 7: \"tribe\",\n 6: \"subtribe\",\n 5: \"genus\",\n 4: \"subgenus\",\n 3: \"species\",\n 2: \"subspecies\",\n };\n\n function getIndex(data, term, property) {\n for (let i = 0, len = data.length; i < len; i++) {\n if (data[i][property] === term) return i;\n }\n return -1;\n }\n\n console.log(\"Processing fossil data...\", data);\n\n data.forEach((d) => {\n // Some preprocessing\n d.rank = d.rnk ? rankMap[d.rnk] : d.idr ? rankMap[d.idr] : \"Unknown\";\n d.italics = d.rnk < 6 ? \"italics\" : \"\";\n if (typeof d.tna === \"undefined\") {\n d.tna = d.idn;\n }\n d.old_name = d.tna.split(\" \")[0] != d.idg ? d.tna : \"\";\n d.url =\n d.rank === \"species\"\n ? d.idg + \" \" + d.ids\n : d.tid\n ? d.tid.split(\":\")[1] > 0\n ? d.idg\n : \"\"\n : \"\";\n\n // If it has a genus name...\n if (d.idg) {\n let genusRes = d.rsg ? d.rsg + \" \" : \"\";\n let speciesRes = d.rss ? \" \" + d.rss + \" \" : \" \";\n d.genusRes = genusRes;\n // If it's a species...\n if (d.rank === \"species\") {\n d.display_name1 = d.tna;\n d.display_name2 = d.tna != d.idg + \" \" + d.ids ? \"(\" + d.tna + \")\" : \"\";\n d.display_name3 = \"\";\n } else {\n d.display_name1 = d.idg;\n d.display_name2 = speciesRes;\n d.display_name3 = d.ids;\n }\n } else {\n d.display_name1 = d.tna;\n d.display_name2 = \"\";\n }\n\n // Find unique phyla\n let phyla = [];\n for (let i = 0; i < occurrenceTree.phyla.length; i++) {\n phyla.push(occurrenceTree.phyla[i].phylum);\n }\n\n if (phyla.indexOf(d.phl) < 0) {\n let newPhylum = { phylum: d.phl, classes: [] };\n occurrenceTree.phyla.push(newPhylum);\n }\n\n // Find unique phylum/class combinations\n let phyla_classes = [];\n for (let i = 0; i < occurrenceTree.phyla.length; i++) {\n for (let j = 0; j < occurrenceTree.phyla[i].classes.length; j++) {\n phyla_classes.push(\n occurrenceTree.phyla[i].phylum +\n \"-\" +\n occurrenceTree.phyla[i].classes[j].nameClass,\n );\n }\n }\n\n if (phyla_classes.indexOf(d.phl + \"-\" + d.cll) < 0) {\n let newClass = { nameClass: d.cll, families: [] };\n let phylumIndex = getIndex(occurrenceTree.phyla, d.phl, \"phylum\");\n occurrenceTree.phyla[phylumIndex][\"classes\"].push(newClass);\n }\n\n // Find unique phylum/class/family combinations\n let phyla_class_family = [];\n for (let i = 0; i < occurrenceTree.phyla.length; i++) {\n for (let j = 0; j < occurrenceTree.phyla[i].classes.length; j++) {\n for (\n let k = 0;\n k < occurrenceTree.phyla[i].classes[j].families.length;\n k++\n ) {\n phyla_class_family.push(\n occurrenceTree.phyla[i].phylum +\n \"-\" +\n occurrenceTree.phyla[i].classes[j].nameClass +\n \"-\" +\n occurrenceTree.phyla[i].classes[j].families[k].family,\n );\n }\n }\n }\n\n if (phyla_class_family.indexOf(d.phl + \"-\" + d.cll + \"-\" + d.fml) < 0) {\n let newFamily = { family: d.fml, genera: [] };\n let phylumIndex = getIndex(occurrenceTree.phyla, d.phl, \"phylum\");\n let classIndex = getIndex(\n occurrenceTree.phyla[phylumIndex].classes,\n d.cll,\n \"nameClass\",\n );\n occurrenceTree.phyla[phylumIndex].classes[classIndex][\"families\"].push(\n newFamily,\n );\n }\n\n // Place genera into the right phylum/class/family\n let phylumIndex = getIndex(occurrenceTree.phyla, d.phl, \"phylum\");\n let classIndex = getIndex(\n occurrenceTree.phyla[phylumIndex].classes,\n d.cll,\n \"nameClass\",\n );\n let familyIndex = getIndex(\n occurrenceTree.phyla[phylumIndex].classes[classIndex].families,\n d.fml,\n \"family\",\n );\n occurrenceTree.phyla[phylumIndex].classes[classIndex].families[\n familyIndex\n ].genera.push(d);\n });\n\n for (let i = 0; i < occurrenceTree.phyla.length; i++) {\n let undefinedClassIndex;\n for (let j = 0; j < occurrenceTree.phyla[i].classes.length; j++) {\n let undefinedFamilyIndex;\n for (\n let k = 0;\n k < occurrenceTree.phyla[i].classes[j].families.length;\n k++\n ) {\n if (\n typeof occurrenceTree.phyla[i].classes[j].families[k].family ===\n \"undefined\"\n ) {\n undefinedFamilyIndex = k;\n occurrenceTree.phyla[i].classes[j].families[k].family =\n \"Miscellaneous \" +\n (typeof occurrenceTree.phyla[i].classes[j].nameClass ===\n \"undefined\")\n ? \"Miscellaneous unranked taxa\"\n : occurrenceTree.phyla[i].classes[j].nameClass;\n occurrenceTree.phyla[i].classes[j].families[k].noFamily = true;\n }\n }\n\n if (typeof undefinedFamilyIndex != \"undefined\") {\n occurrenceTree.phyla[i].classes[j].families.push(\n occurrenceTree.phyla[i].classes[j].families.splice(\n undefinedFamilyIndex,\n 1,\n )[0],\n );\n }\n\n if (typeof occurrenceTree.phyla[i].classes[j].nameClass === \"undefined\") {\n undefinedFamilyIndex = j;\n occurrenceTree.phyla[i].classes[j].nameClass =\n \"Miscellaneous \" +\n (typeof occurrenceTree.phyla[i].phylum === \"undefined\")\n ? \"Miscellaneous unranked taxa\"\n : occurrenceTree.phyla[i].phylum;\n occurrenceTree.phyla[i].classes[j].noClass = true;\n }\n }\n\n if (typeof undefinedClassIndex != \"undefined\") {\n occurrenceTree.phyla[i].classes.push(\n occurrenceTree.phyla[i].classes.splice(undefinedClassIndex, 1)[0],\n );\n }\n\n if (typeof occurrenceTree.phyla[i].phylum === \"undefined\") {\n occurrenceTree.phyla[i].phylum = \"Unranked taxa\";\n occurrenceTree.phyla[i].unranked = true;\n }\n }\n\n return occurrenceTree;\n}\n"],"names":[],"version":3,"file":"map-interface.744b121c.js.map"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;AAAO,MAAM,4CAAY,CAAC;IACxB,IAAI,SAAS;IACb,IAAI,QAAQ,EAAE,QAAQ,GAAG,KAAK,CAAC;IAC/B,KAAK,CAAC,EAAE,GAAG,KAAK,CAAC,EAAE,CAAC,OAAO,CAAC,yBAAyB;IACrD,OAAO,MAAM,IAAI,CAAC;AACpB;AAEO,MAAM,4CAAM,CAAC,MAAM;IACxB,IAAI,CAAC,QAAQ,CAAC,KAAK,MAAM,EACvB,OAAO,EAAE;IAEX,OAAO,KACJ,GAAG,CAAC,CAAC;QACJ,OAAO,CAAC,CAAC,KAAK;IAChB,GACC,MAAM,CAAC,CAAC,GAAG;QACV,OAAO,IAAI;IACb,GAAG;AACP;AAEO,MAAM,4CAAW,CAAC,KAAK;IAC5B,IAAI,CAAC,KACH,OAAO;IAET,MAAM,IAAI,OAAO,CAAC,KAAK;IACvB,IAAI,SAAS,SAAS,KAAK;IAC3B,IAAI,IAAI,AAAC,UAAU,KAAM;IACzB,IAAI,IAAI,AAAC,UAAU,IAAK;IACxB,IAAI,IAAI,SAAS;IACjB,OAAO,CAAC,KAAK,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC,EAAE,EAAE,CAAC,EAAE,WAAW,IAAI,CAAC,CAAC;AACjD;AAUO,MAAM,4CAAiC;IAC5C;QAAE,MAAM;QAAc,QAAQ;QAAK,OAAO;QAAG,OAAO;QAAO,OAAO;IAAU;IAC5E;QACE,MAAM;QACN,QAAQ;QACR,OAAO;QACP,OAAO;QACP,OAAO;IACT;IACA;QACE,MAAM;QACN,QAAQ;QACR,OAAO;QACP,OAAO;QAC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AAU;IAC5E;QACE,MAAM;QACN,QAAQ;QACR,OAAO;QACP,OAAO;QACP,OAAO;IACT;CACD","sources":["packages/map-interface/src/map-panel/utils/index.ts"],"sourcesContent":["export const addCommas = (x) => {\n x = parseInt(x);\n var parts = x.toString().split(\".\");\n parts[0] = parts[0].replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\");\n return parts.join(\".\");\n};\n\nexport const sum = (data, prop) => {\n if (!data || !data.length) {\n return [];\n }\n return data\n .map((d) => {\n return d[prop];\n })\n .reduce((a, b) => {\n return a + b;\n }, 0);\n};\n\nexport const hexToRgb = (hex, opacity) => {\n if (!hex) {\n return \"rgba(0,0,0,0.3)\";\n }\n hex = hex.replace(\"#\", \"\");\n let bigint = parseInt(hex, 16);\n let r = (bigint >> 16) & 255;\n let g = (bigint >> 8) & 255;\n let b = bigint & 255;\n return `rgba(${r},${g},${b},${opacity || 0.8})`;\n};\n\nexport type TimescaleDivision = {\n name: string;\n abbrev: string;\n t_age: number;\n b_age: number;\n color: string;\n};\n\nexport const timescale: TimescaleDivision[] = [\n { name: \"Quaternary\", abbrev: \"Q\", t_age: 0, b_age: 2.588, color: \"#F9F97F\" },\n {\n name: \"Neogene\",\n abbrev: \"Ng\",\n t_age: 2.588,\n b_age: 23.03,\n color: \"#FFE619\",\n },\n {\n name: \"Paleogene\",\n abbrev: \"Pg\",\n t_age: 23.03,\n b_age: 66,\n color: \"#FD9A52\",\n },\n { name: \"Cretaceous\", abbrev: \"K\", t_age: 66, b_age: 145, color: \"#7FC64E\" },\n { name: \"Jurassic\", abbrev: \"J\", t_age: 145, b_age: 201.3, color: \"#34B2C9\" },\n {\n name: \"Triassic\",\n abbrev: \"Tr\",\n t_age: 201.3,\n b_age: 252.17,\n color: \"#812B92\",\n },\n {\n name: \"Permian\",\n abbrev: \"P\",\n t_age: 252.17,\n b_age: 298.9,\n color: \"#F04028\",\n },\n {\n name: \"Carboniferous\",\n abbrev: \"C\",\n t_age: 298.9,\n b_age: 358.9,\n color: \"#67A599\",\n },\n {\n name: \"Devonian\",\n abbrev: \"D\",\n t_age: 358.9,\n b_age: 419.2,\n color: \"#CB8C37\",\n },\n {\n name: \"Silurian\",\n abbrev: \"S\",\n t_age: 419.2,\n b_age: 443.8,\n color: \"#B3E1B6\",\n },\n {\n name: \"Ordovician\",\n abbrev: \"O\",\n t_age: 443.8,\n b_age: 485.4,\n color: \"#009270\",\n },\n {\n name: \"Cambrian\",\n abbrev: \"Cm\",\n t_age: 485.4,\n b_age: 541,\n color: \"#7FA056\",\n },\n { name: \"Ediacaran\", abbrev: \"E\", t_age: 541, b_age: 635, color: \"#FFC3E1\" },\n {\n name: \"Cryogenian\",\n abbrev: \"Cr\",\n t_age: 635,\n b_age: 720,\n color: \"#FFAFD7\",\n },\n { name: \"Tonian\", abbrev: \"T\", t_age: 720, b_age: 1000, color: \"#FFA5D2\" },\n { name: \"Stenian\", abbrev: \"St\", t_age: 1000, b_age: 1200, color: \"#FFA5D2\" },\n {\n name: \"Ectasian\",\n abbrev: \"Ec\",\n t_age: 1200,\n b_age: 1400,\n color: \"#FF98CC\",\n },\n {\n name: \"Calymmian\",\n abbrev: \"Ca\",\n t_age: 1400,\n b_age: 1600,\n color: \"#FF8BC5\",\n },\n {\n name: \"Statherian\",\n abbrev: \"St\",\n t_age: 1600,\n b_age: 1800,\n color: \"#EE93C1\",\n },\n {\n name: \"Orosirian\",\n abbrev: \"Or\",\n t_age: 1800,\n b_age: 2050,\n color: \"#E874AF\",\n },\n { name: \"Rhyacian\", abbrev: \"R\", t_age: 2050, b_age: 2300, color: \"#EB84B8\" },\n {\n name: \"Siderian\",\n abbrev: \"Sd\",\n t_age: 2300,\n b_age: 2500,\n color: \"#E874AF\",\n },\n];\n\nexport * from \"./fossils\";\nexport * from \"./formatting\";\n"],"names":[],"version":3,"file":"map-interface.84080d80.js.map"}
|
|
@@ -1,60 +0,0 @@
|
|
|
1
|
-
var $769456f773c604e1$exports = require("./map-interface.141c7329.js");
|
|
2
|
-
var $foqjG$blueprintjscore = require("@blueprintjs/core");
|
|
3
|
-
var $foqjG$macrostrathyper = require("@macrostrat/hyper");
|
|
4
|
-
var $foqjG$macrostratmapinterface = require("@macrostrat/map-interface");
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
function $parcel$interopDefault(a) {
|
|
8
|
-
return a && a.__esModule ? a.default : a;
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
function $parcel$export(e, n, v, s) {
|
|
12
|
-
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
$parcel$export(module.exports, "XddExpansion", () => $d3d9e7b5fce766d0$export$7bbcc612b1169c6f);
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
function $d3d9e7b5fce766d0$export$7bbcc612b1169c6f({ xddInfo: xddInfo }) {
|
|
21
|
-
return (0, ($parcel$interopDefault($foqjG$macrostrathyper)))($d3d9e7b5fce766d0$export$223bda478756d1d9, {
|
|
22
|
-
className: "regional-panel",
|
|
23
|
-
data: xddInfo,
|
|
24
|
-
isFetching: xddInfo == undefined || xddInfo.length === 0
|
|
25
|
-
});
|
|
26
|
-
}
|
|
27
|
-
function $d3d9e7b5fce766d0$export$223bda478756d1d9({ isFetching: isFetching, data: xddInfo, ...rest }) {
|
|
28
|
-
const groupedData = $d3d9e7b5fce766d0$var$groupSnippetsByJournal(xddInfo);
|
|
29
|
-
return (0, ($parcel$interopDefault($foqjG$macrostrathyper)))((0, $foqjG$macrostratmapinterface.ExpansionPanel), {
|
|
30
|
-
className: "regional-panel",
|
|
31
|
-
title: "Primary literature",
|
|
32
|
-
helpText: "via xDD",
|
|
33
|
-
...rest
|
|
34
|
-
}, [
|
|
35
|
-
(0, ($parcel$interopDefault($foqjG$macrostrathyper))).if(isFetching)((0, $foqjG$blueprintjscore.Spinner)),
|
|
36
|
-
(0, ($parcel$interopDefault($foqjG$macrostrathyper))).if(!isFetching && xddInfo.length > 0)([
|
|
37
|
-
Array.from(groupedData.entries())?.map(([journal, snippets])=>{
|
|
38
|
-
return (0, ($parcel$interopDefault($foqjG$macrostrathyper)))((0, $769456f773c604e1$exports.default), {
|
|
39
|
-
name: journal,
|
|
40
|
-
articles: snippets,
|
|
41
|
-
publisher: snippets[0].publisher,
|
|
42
|
-
key: journal
|
|
43
|
-
});
|
|
44
|
-
})
|
|
45
|
-
])
|
|
46
|
-
]);
|
|
47
|
-
}
|
|
48
|
-
function $d3d9e7b5fce766d0$var$groupSnippetsByJournal(snippets) {
|
|
49
|
-
const journals = new Map();
|
|
50
|
-
if (!snippets || snippets.length === 0) return journals;
|
|
51
|
-
for (let snippet of snippets){
|
|
52
|
-
const { pubname: journal } = snippet;
|
|
53
|
-
if (!journals.has(journal)) journals.set(journal, []);
|
|
54
|
-
journals.get(journal).push(snippet);
|
|
55
|
-
}
|
|
56
|
-
return journals;
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
//# sourceMappingURL=map-interface.937c0b90.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;;;;;AAkBO,SAAS,0CAAa,WAAE,OAAO,EAAE;IACtC,OAAO,CAAA,GAAA,gDAAA,EAAE,2CAAc;QACrB,WAAW;QACX,MAAM;QACN,YAAY,WAAW,aAAa,QAAQ,MAAM,KAAK;IACzD;AACF;AAEO,SAAS,0CAAa,cAAE,UAAU,EAAE,MAAM,OAAO,EAAE,GAAG,MAAM;IACjE,MAAM,cAAc,6CAAuB;IAE3C,OAAO,CAAA,GAAA,gDAAA,EACL,CAAA,GAAA,4CAAa,GACb;QACE,WAAW;QACX,OAAO;QACP,UAAU;QACV,GAAG,IAAI;IACT,GACA;QACE,CAAA,GAAA,gDAAA,EAAE,EAAE,CAAC,YAAY,CAAA,GAAA,8BAAM;QACvB,CAAA,GAAA,gDAAA,EAAE,EAAE,CAAC,CAAC,cAAc,QAAQ,MAAM,GAAG,GAAG;YACtC,MAAM,IAAI,CAAC,YAAY,OAAO,KAAK,IAAI,CAAC,CAAC,SAAS,SAAS;gBACzD,OAAO,CAAA,GAAA,gDAAA,EAAE,CAAA,GAAA,iCAAM,GAAG;oBAChB,MAAM;oBACN,UAAU;oBACV,WAAW,QAAQ,CAAC,EAAE,CAAC,SAAS;oBAChC,KAAK;gBACP;YACF;SACD;KACF;AAEL;AAEA,SAAS,6CACP,QAAsB;IAEtB,MAAM,WAAW,IAAI;IACrB,IAAI,CAAC,YAAY,SAAS,MAAM,KAAK,GACnC,OAAO;IAET,KAAK,IAAI,WAAW,SAAU;QAC5B,MAAM,EAAE,SAAS,OAAO,EAAE,GAAG;QAC7B,IAAI,CAAC,SAAS,GAAG,CAAC,UAChB,SAAS,GAAG,CAAC,SAAS,EAAE;QAE1B,SAAS,GAAG,CAAC,SAAS,IAAI,CAAC;IAC7B;IACA,OAAO;AACT","sources":["packages/map-interface/src/map-panel/components/info-drawer/xdd-panel/index.ts"],"sourcesContent":["import { Spinner } from \"@blueprintjs/core\";\nimport h from \"@macrostrat/hyper\";\nimport Journal from \"./Journal\";\nimport { ExpansionPanel } from \"@macrostrat/map-interface\";\n\nexport interface XDDSnippet {\n pubname: string;\n publisher: string;\n _gddid: string;\n title: string;\n doi: string;\n coverDate: string;\n URL: string;\n authors: string;\n hits: number;\n highlight: string[];\n}\n\nexport function XddExpansion({ xddInfo }) {\n return h(xDDPanelCore, {\n className: \"regional-panel\",\n data: xddInfo,\n isFetching: xddInfo == undefined || xddInfo.length === 0,\n });\n}\n\nexport function xDDPanelCore({ isFetching, data: xddInfo, ...rest }) {\n const groupedData = groupSnippetsByJournal(xddInfo);\n\n return h(\n ExpansionPanel,\n {\n className: \"regional-panel\",\n title: \"Primary literature\",\n helpText: \"via xDD\",\n ...rest,\n },\n [\n h.if(isFetching)(Spinner),\n h.if(!isFetching && xddInfo.length > 0)([\n Array.from(groupedData.entries())?.map(([journal, snippets]) => {\n return h(Journal, {\n name: journal,\n articles: snippets,\n publisher: snippets[0].publisher,\n key: journal,\n });\n }),\n ]),\n ],\n );\n}\n\nfunction groupSnippetsByJournal(\n snippets: XDDSnippet[],\n): Map<string, XDDSnippet[]> {\n const journals = new Map<string, XDDSnippet[]>();\n if (!snippets || snippets.length === 0) {\n return journals;\n }\n for (let snippet of snippets) {\n const { pubname: journal } = snippet;\n if (!journals.has(journal)) {\n journals.set(journal, []);\n }\n journals.get(journal).push(snippet);\n }\n return journals;\n}\n"],"names":[],"version":3,"file":"map-interface.937c0b90.js.map"}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
function $parcel$export(e, n, v, s) {
|
|
3
|
-
Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
|
|
4
|
-
}
|
|
5
|
-
|
|
6
|
-
$parcel$export(module.exports, "age-chips", () => $f2e0b9e87d965c31$export$e806ffd2c8080e0, (v) => $f2e0b9e87d965c31$export$e806ffd2c8080e0 = v);
|
|
7
|
-
$parcel$export(module.exports, "age-refinement-bar", () => $f2e0b9e87d965c31$export$2a430a6b6becc9ef, (v) => $f2e0b9e87d965c31$export$2a430a6b6becc9ef = v);
|
|
8
|
-
$parcel$export(module.exports, "age-refinement-plot", () => $f2e0b9e87d965c31$export$5ebe301e9a11fad8, (v) => $f2e0b9e87d965c31$export$5ebe301e9a11fad8 = v);
|
|
9
|
-
$parcel$export(module.exports, "described-age", () => $f2e0b9e87d965c31$export$234d4cd7931f3ae7, (v) => $f2e0b9e87d965c31$export$234d4cd7931f3ae7 = v);
|
|
10
|
-
$parcel$export(module.exports, "description", () => $f2e0b9e87d965c31$export$6d59db4903f20f7d, (v) => $f2e0b9e87d965c31$export$6d59db4903f20f7d = v);
|
|
11
|
-
$parcel$export(module.exports, "expansion-summary-title", () => $f2e0b9e87d965c31$export$e420ed5c68615fe8, (v) => $f2e0b9e87d965c31$export$e420ed5c68615fe8 = v);
|
|
12
|
-
$parcel$export(module.exports, "infodrawer-content", () => $f2e0b9e87d965c31$export$9c4e881ec478ba6d, (v) => $f2e0b9e87d965c31$export$9c4e881ec478ba6d = v);
|
|
13
|
-
$parcel$export(module.exports, "macrostrat-detail", () => $f2e0b9e87d965c31$export$f23733506e8895aa, (v) => $f2e0b9e87d965c31$export$f23733506e8895aa = v);
|
|
14
|
-
$parcel$export(module.exports, "macrostrat-unit", () => $f2e0b9e87d965c31$export$fcdb9e479e3129ed, (v) => $f2e0b9e87d965c31$export$fcdb9e479e3129ed = v);
|
|
15
|
-
$parcel$export(module.exports, "spacer", () => $f2e0b9e87d965c31$export$8cc075c801fd6817, (v) => $f2e0b9e87d965c31$export$8cc075c801fd6817 = v);
|
|
16
|
-
var $f2e0b9e87d965c31$export$e806ffd2c8080e0;
|
|
17
|
-
var $f2e0b9e87d965c31$export$2a430a6b6becc9ef;
|
|
18
|
-
var $f2e0b9e87d965c31$export$5ebe301e9a11fad8;
|
|
19
|
-
var $f2e0b9e87d965c31$export$234d4cd7931f3ae7;
|
|
20
|
-
var $f2e0b9e87d965c31$export$6d59db4903f20f7d;
|
|
21
|
-
var $f2e0b9e87d965c31$export$e420ed5c68615fe8;
|
|
22
|
-
var $f2e0b9e87d965c31$export$9c4e881ec478ba6d;
|
|
23
|
-
var $f2e0b9e87d965c31$export$f23733506e8895aa;
|
|
24
|
-
var $f2e0b9e87d965c31$export$fcdb9e479e3129ed;
|
|
25
|
-
var $f2e0b9e87d965c31$export$8cc075c801fd6817;
|
|
26
|
-
$f2e0b9e87d965c31$export$e806ffd2c8080e0 = `JozziG_age-chips`;
|
|
27
|
-
$f2e0b9e87d965c31$export$2a430a6b6becc9ef = `JozziG_age-refinement-bar`;
|
|
28
|
-
$f2e0b9e87d965c31$export$5ebe301e9a11fad8 = `JozziG_age-refinement-plot`;
|
|
29
|
-
$f2e0b9e87d965c31$export$234d4cd7931f3ae7 = `JozziG_described-age`;
|
|
30
|
-
$f2e0b9e87d965c31$export$6d59db4903f20f7d = `JozziG_description`;
|
|
31
|
-
$f2e0b9e87d965c31$export$e420ed5c68615fe8 = `JozziG_expansion-summary-title`;
|
|
32
|
-
$f2e0b9e87d965c31$export$9c4e881ec478ba6d = `JozziG_infodrawer-content`;
|
|
33
|
-
$f2e0b9e87d965c31$export$f23733506e8895aa = `JozziG_macrostrat-detail`;
|
|
34
|
-
$f2e0b9e87d965c31$export$fcdb9e479e3129ed = `JozziG_macrostrat-unit`;
|
|
35
|
-
$f2e0b9e87d965c31$export$8cc075c801fd6817 = `JozziG_spacer`;
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
//# sourceMappingURL=map-interface.9893b047.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"mappings":";;;;;;;;;;;;;;;AAAA,IAAA;AACA,IAAA;AACA,IAAA;AACA,IAAA;AACA,IAAA;AACA,IAAA;AACA,IAAA;AACA,IAAA;AACA,IAAA;AACA,IAAA;AATA,2CAA8B,CAAC,gBAAgB,CAAC;AAChD,4CAAuC,CAAC,yBAAyB,CAAC;AAClE,4CAAwC,CAAC,0BAA0B,CAAC;AACpE,4CAAkC,CAAC,oBAAoB,CAAC;AACxD,4CAAgC,CAAC,kBAAkB,CAAC;AACpD,4CAA4C,CAAC,8BAA8B,CAAC;AAC5E,4CAAuC,CAAC,yBAAyB,CAAC;AAClE,4CAAsC,CAAC,wBAAwB,CAAC;AAChE,4CAAoC,CAAC,sBAAsB,CAAC;AAC5D,4CAA2B,CAAC,aAAa,CAAC","sources":["packages/map-interface/src/map-panel/components/info-drawer/main.module.styl"],"sourcesContent":[".spacer\n flex-grow 1\n pointer-events none\n\n.infodrawer-content\n margin: 0;\n\n.macrostrat-detail\n display: flex;\n align-items: center;\n margin 0.2em 0 0.4em;\n\n .expansion-summary-title\n margin-right: 0.8em;\n\n &:after\n content: \":\";\n\n.described-age, .macrostrat-detail\n display: flex;\n align-items: center;\n\n .expansion-summary-title\n margin-right: 0.8em;\n\n &:after\n content: \":\";\n\n .description\n font-style italic\n font-size 0.7em\n max-width: 100px\n text-align: right\n\n .age-chips\n flex-grow 1\n\n\n// &.loading\n// max-height: 200px\n// max-height: calc(100vh - 60px)\n// transition: max-height 0.5s ease-in-out 0.25s\n\n\n.spacer\n flex-grow 1\n pointer-events none\n\n.macrostrat-unit\n h3\n margin: 0.5em 0 0.5em;\n flex-grow: 1;\n\n .description\n margin-right: 1em\n\n.description\n font-style italic\n\n.age-refinement-plot\n position relative\n\n .age-refinement-bar\n border-radius: 3px\n margin-bottom: 1px\n\n\n"],"names":[],"version":3,"file":"map-interface.9893b047.js.map"}
|