baselode 0.1.19 → 0.1.20
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/dist/baselode.js
CHANGED
|
@@ -1,33 +1,33 @@
|
|
|
1
|
-
import { _ as gt, w as k, H as _, P as de, F as
|
|
2
|
-
import { p as
|
|
1
|
+
import { _ as gt, w as k, H as _, P as de, F as C, T as M, c as bt, L as se, a as re, D as G, A as j, b as Y, E as pe, N as ye, d as ve, M as Ee, G as le, e as ce, B as _t, f as Qe, g as $e, h as Pe, i as Be, j as Nt, k as et, l as Et, m as Ge, n as At, o as vt } from "./baselode3dScene-qMfVRKxK.js";
|
|
2
|
+
import { p as us, q as ds, r as ms, s as fs, t as hs, u as ps, v as ys, x as gs, y as bs, z as _s, C as Ns, I as Es, J as As, K as vs, O as Is, Q as Ss, R as Ls, S as Cs, U as Ts, V as Ms, W as Os, X as Ps, Y as Ds, Z as xs, $ as Rs, a0 as zs, a1 as Fs, a2 as $s, a3 as ks, a4 as ws, a5 as Hs, a6 as Us, a7 as Bs, a8 as Gs, a9 as Vs, aa as js, ab as Ys, ac as Ws, ad as qs, ae as Ks, af as Xs, ag as Zs, ah as Js, ai as Qs, aj as er, ak as tr, al as nr, am as sr, an as rr, ao as or, ap as ir, aq as ar, ar as lr, as as cr, at as ur, au as dr, av as mr, aw as fr, ax as hr, ay as pr, az as yr, aA as gr, aB as br, aC as _r, aD as Nr, aE as Er, aF as Ar, aG as vr, aH as Ir, aI as Sr, aJ as Lr, aK as Cr, aL as Tr, aM as Mr, aN as Or, aO as Pr, aP as Dr, aQ as xr, aR as Rr, aS as zr, aT as Fr, aU as $r, aV as kr, aW as wr, aX as Hr, aY as Ur, aZ as Br, a_ as Gr, a$ as Vr, b0 as jr, b1 as Yr, b2 as Wr, b3 as qr, b4 as Kr, b5 as Xr, b6 as Zr, b7 as Jr, b8 as Qr, b9 as eo, ba as to, bb as no, bc as so, bd as ro, be as oo, bf as io, bg as ao } from "./baselode3dScene-qMfVRKxK.js";
|
|
3
3
|
import J from "papaparse";
|
|
4
|
-
import { jsx as
|
|
5
|
-
import { useRef as _e, useState as X, useEffect as ne, useMemo as ee, useCallback as
|
|
6
|
-
import
|
|
4
|
+
import { jsx as S, jsxs as W } from "react/jsx-runtime";
|
|
5
|
+
import { useRef as _e, useState as X, useEffect as ne, useMemo as ee, useCallback as De } from "react";
|
|
6
|
+
import Ae from "plotly.js-dist-min";
|
|
7
7
|
import * as Q from "three";
|
|
8
|
-
function
|
|
8
|
+
function Ie(e) {
|
|
9
9
|
return (e || "").toString().trim().toLowerCase().replace(/\s+/g, "_");
|
|
10
10
|
}
|
|
11
11
|
function ie(e, n = null, t = null) {
|
|
12
|
-
const
|
|
12
|
+
const s = { ...gt };
|
|
13
13
|
if (t) {
|
|
14
14
|
for (const [i, o] of Object.entries(t))
|
|
15
15
|
if (i != null && o != null) {
|
|
16
|
-
const a =
|
|
17
|
-
|
|
16
|
+
const a = Ie(i), l = Ie(o);
|
|
17
|
+
s[a] = l;
|
|
18
18
|
}
|
|
19
19
|
}
|
|
20
|
-
const
|
|
20
|
+
const r = {};
|
|
21
21
|
for (const [i, o] of Object.entries(e)) {
|
|
22
|
-
const a =
|
|
23
|
-
|
|
22
|
+
const a = Ie(i), l = s[a] || a;
|
|
23
|
+
r[l] = o;
|
|
24
24
|
}
|
|
25
|
-
return
|
|
25
|
+
return r;
|
|
26
26
|
}
|
|
27
27
|
function _n(e, n = null, t = null) {
|
|
28
|
-
return e.map((
|
|
28
|
+
return e.map((s) => ie(s, n, t));
|
|
29
29
|
}
|
|
30
|
-
const
|
|
30
|
+
const It = /* @__PURE__ */ new Set([
|
|
31
31
|
"hole_id",
|
|
32
32
|
"holeid",
|
|
33
33
|
"id",
|
|
@@ -59,25 +59,25 @@ const At = /* @__PURE__ */ new Set([
|
|
|
59
59
|
"todepth",
|
|
60
60
|
"comment",
|
|
61
61
|
"z"
|
|
62
|
-
]),
|
|
63
|
-
function
|
|
62
|
+
]), Te = (e, n = null) => ie(e, null, n);
|
|
63
|
+
function St(e) {
|
|
64
64
|
return { holeId: e[_] };
|
|
65
65
|
}
|
|
66
66
|
function tt(e, n = null) {
|
|
67
|
-
const t = e[_],
|
|
68
|
-
if (!
|
|
69
|
-
const
|
|
67
|
+
const t = e[_], s = t !== void 0 ? `${t}`.trim() : "";
|
|
68
|
+
if (!s) return null;
|
|
69
|
+
const r = e[de] || e.project || e.project_code, i = Number(e[C]), o = Number(e[M]);
|
|
70
70
|
return !Number.isFinite(i) || !Number.isFinite(o) || o <= i ? null : {
|
|
71
|
-
holeId:
|
|
72
|
-
project:
|
|
71
|
+
holeId: s,
|
|
72
|
+
project: r,
|
|
73
73
|
from: i,
|
|
74
74
|
to: o,
|
|
75
75
|
...e
|
|
76
76
|
};
|
|
77
77
|
}
|
|
78
78
|
function nt(e, n) {
|
|
79
|
-
var
|
|
80
|
-
const t = n.sort((i, o) => i.from - o.from),
|
|
79
|
+
var r;
|
|
80
|
+
const t = n.sort((i, o) => i.from - o.from), s = [];
|
|
81
81
|
return t.forEach((i) => {
|
|
82
82
|
const { from: o, to: a, project: l, ...u } = i, c = {
|
|
83
83
|
z: o,
|
|
@@ -87,53 +87,53 @@ function nt(e, n) {
|
|
|
87
87
|
[de]: l,
|
|
88
88
|
...u
|
|
89
89
|
};
|
|
90
|
-
|
|
91
|
-
}), { id: e, project: (
|
|
90
|
+
s.push(c), s.push({ ...c, z: a });
|
|
91
|
+
}), { id: e, project: (r = t[0]) == null ? void 0 : r.project, points: s };
|
|
92
92
|
}
|
|
93
93
|
function Nn(e, n = null) {
|
|
94
|
-
return new Promise((t,
|
|
95
|
-
const
|
|
94
|
+
return new Promise((t, s) => {
|
|
95
|
+
const r = /* @__PURE__ */ new Set();
|
|
96
96
|
J.parse(e, {
|
|
97
97
|
header: !0,
|
|
98
98
|
dynamicTyping: !0,
|
|
99
99
|
skipEmptyLines: !0,
|
|
100
100
|
step: (i) => {
|
|
101
|
-
const a =
|
|
102
|
-
a !== void 0 && `${a}`.trim() !== "" &&
|
|
101
|
+
const a = Te(i.data, n)[_];
|
|
102
|
+
a !== void 0 && `${a}`.trim() !== "" && r.add(`${a}`.trim());
|
|
103
103
|
},
|
|
104
|
-
complete: () => t(Array.from(
|
|
105
|
-
error: (i) =>
|
|
104
|
+
complete: () => t(Array.from(r)),
|
|
105
|
+
error: (i) => s(k("parseAssayHoleIds", i))
|
|
106
106
|
});
|
|
107
107
|
});
|
|
108
108
|
}
|
|
109
109
|
function Lt(e) {
|
|
110
|
-
return Object.entries(e || {}).some(([n, t]) => !(
|
|
110
|
+
return Object.entries(e || {}).some(([n, t]) => !(It.has(n) || t == null || typeof t == "string" && t.trim() === ""));
|
|
111
111
|
}
|
|
112
|
-
function
|
|
113
|
-
return new Promise((t,
|
|
114
|
-
const
|
|
112
|
+
function Ct(e, n = null) {
|
|
113
|
+
return new Promise((t, s) => {
|
|
114
|
+
const r = /* @__PURE__ */ new Map();
|
|
115
115
|
J.parse(e, {
|
|
116
116
|
header: !0,
|
|
117
117
|
dynamicTyping: !0,
|
|
118
118
|
skipEmptyLines: !0,
|
|
119
119
|
step: (i) => {
|
|
120
|
-
const o =
|
|
120
|
+
const o = Te(i.data, n);
|
|
121
121
|
if (!Lt(o)) return;
|
|
122
|
-
const l =
|
|
122
|
+
const l = St(o).holeId;
|
|
123
123
|
if (l !== void 0 && `${l}`.trim() !== "") {
|
|
124
124
|
const u = `${l}`.trim();
|
|
125
|
-
|
|
125
|
+
r.has(u) || r.set(u, {
|
|
126
126
|
holeId: u
|
|
127
127
|
});
|
|
128
128
|
}
|
|
129
129
|
},
|
|
130
|
-
complete: () => t(Array.from(
|
|
131
|
-
error: (i) =>
|
|
130
|
+
complete: () => t(Array.from(r.values())),
|
|
131
|
+
error: (i) => s(k("parseAssayHoleIdsWithAssays", i))
|
|
132
132
|
});
|
|
133
133
|
});
|
|
134
134
|
}
|
|
135
|
-
function
|
|
136
|
-
return new Promise((
|
|
135
|
+
function Tt(e, n, t = null, s = null) {
|
|
136
|
+
return new Promise((r, i) => {
|
|
137
137
|
const o = `${n}`.trim();
|
|
138
138
|
if (!o) {
|
|
139
139
|
i(k("parseAssayHole", new Error("Missing hole id")));
|
|
@@ -145,23 +145,23 @@ function Mt(e, n, t = null, r = null) {
|
|
|
145
145
|
dynamicTyping: !0,
|
|
146
146
|
skipEmptyLines: !0,
|
|
147
147
|
step: (l) => {
|
|
148
|
-
const u =
|
|
148
|
+
const u = Te(l.data, s), c = tt(u, s);
|
|
149
149
|
c && `${c.holeId}`.trim() === o && a.push(c);
|
|
150
150
|
},
|
|
151
151
|
complete: () => {
|
|
152
152
|
if (!a.length) {
|
|
153
|
-
|
|
153
|
+
r(null);
|
|
154
154
|
return;
|
|
155
155
|
}
|
|
156
156
|
const l = nt(o, a);
|
|
157
|
-
|
|
157
|
+
r(l);
|
|
158
158
|
},
|
|
159
159
|
error: (l) => i(k("parseAssayHole", l))
|
|
160
160
|
});
|
|
161
161
|
});
|
|
162
162
|
}
|
|
163
|
-
function
|
|
164
|
-
return new Promise((
|
|
163
|
+
function Mt(e, n = null, t = null) {
|
|
164
|
+
return new Promise((s, r) => {
|
|
165
165
|
J.parse(e, {
|
|
166
166
|
header: !0,
|
|
167
167
|
dynamicTyping: !0,
|
|
@@ -169,143 +169,143 @@ function Tt(e, n = null, t = null) {
|
|
|
169
169
|
complete: (i) => {
|
|
170
170
|
const o = /* @__PURE__ */ new Map();
|
|
171
171
|
i.data.forEach((l) => {
|
|
172
|
-
const u =
|
|
172
|
+
const u = Te(l, t), c = tt(u, t);
|
|
173
173
|
c && (o.has(c.holeId) || o.set(c.holeId, []), o.get(c.holeId).push(c));
|
|
174
174
|
});
|
|
175
175
|
const a = Array.from(o.entries()).map(([l, u]) => nt(l, u));
|
|
176
|
-
|
|
176
|
+
s({ holes: a });
|
|
177
177
|
},
|
|
178
|
-
error: (i) =>
|
|
178
|
+
error: (i) => r(k("parseAssaysCSV", i))
|
|
179
179
|
});
|
|
180
180
|
});
|
|
181
181
|
}
|
|
182
|
-
function
|
|
182
|
+
function En(e = {}) {
|
|
183
183
|
const n = {};
|
|
184
|
-
return Object.entries(e || {}).forEach(([t,
|
|
185
|
-
t && (n[
|
|
184
|
+
return Object.entries(e || {}).forEach(([t, s]) => {
|
|
185
|
+
t && (n[Ie(t)] = s);
|
|
186
186
|
}), n;
|
|
187
187
|
}
|
|
188
|
-
function
|
|
189
|
-
for (const
|
|
190
|
-
const
|
|
191
|
-
if (
|
|
192
|
-
return
|
|
188
|
+
function An(e = {}, n = [], t) {
|
|
189
|
+
for (const s of n) {
|
|
190
|
+
const r = e[s];
|
|
191
|
+
if (r != null && `${r}`.trim() !== "")
|
|
192
|
+
return r;
|
|
193
193
|
}
|
|
194
194
|
return t;
|
|
195
195
|
}
|
|
196
196
|
const Ot = 4;
|
|
197
|
-
function
|
|
197
|
+
function st(e = [], n = "") {
|
|
198
198
|
if (!e.length) return [];
|
|
199
199
|
if (!n) return e;
|
|
200
200
|
const t = e.findIndex((i) => i === n);
|
|
201
201
|
if (t === -1) return e;
|
|
202
|
-
const
|
|
203
|
-
return [
|
|
202
|
+
const s = e[t], r = e.filter((i, o) => o !== t);
|
|
203
|
+
return [s, ...r];
|
|
204
204
|
}
|
|
205
|
-
function
|
|
205
|
+
function Se({
|
|
206
206
|
property: e = "",
|
|
207
207
|
chartType: n = "",
|
|
208
208
|
categoricalProps: t = [],
|
|
209
|
-
commentProps:
|
|
210
|
-
numericDefaultChartType:
|
|
209
|
+
commentProps: s = [],
|
|
210
|
+
numericDefaultChartType: r = "markers+line"
|
|
211
211
|
} = {}) {
|
|
212
|
-
return e ?
|
|
212
|
+
return e ? s.includes(e) ? "comment" : t.includes(e) ? "categorical" : e === "dip" ? "tadpole" : !n || n === "categorical" || n === "comment" || n === "tadpole" ? r : n : n || r;
|
|
213
213
|
}
|
|
214
|
-
function
|
|
214
|
+
function rt({
|
|
215
215
|
holeIds: e = [],
|
|
216
216
|
focusedHoleId: n = "",
|
|
217
217
|
plotCount: t = Ot,
|
|
218
|
-
defaultProp:
|
|
219
|
-
categoricalProps:
|
|
218
|
+
defaultProp: s = "",
|
|
219
|
+
categoricalProps: r = [],
|
|
220
220
|
commentProps: i = [],
|
|
221
221
|
numericDefaultChartType: o = "markers+line"
|
|
222
222
|
} = {}) {
|
|
223
|
-
const a =
|
|
223
|
+
const a = st(e, n);
|
|
224
224
|
return Array.from({ length: t }).map((l, u) => {
|
|
225
|
-
const c = a[u] || e[u] || "", m =
|
|
226
|
-
property:
|
|
225
|
+
const c = a[u] || e[u] || "", m = Se({
|
|
226
|
+
property: s,
|
|
227
227
|
chartType: "",
|
|
228
|
-
categoricalProps:
|
|
228
|
+
categoricalProps: r,
|
|
229
229
|
commentProps: i,
|
|
230
230
|
numericDefaultChartType: o
|
|
231
231
|
});
|
|
232
232
|
return {
|
|
233
233
|
holeId: c,
|
|
234
|
-
property:
|
|
234
|
+
property: s,
|
|
235
235
|
chartType: m
|
|
236
236
|
};
|
|
237
237
|
});
|
|
238
238
|
}
|
|
239
239
|
function Le(e = []) {
|
|
240
|
-
const n = e.flatMap((a) => a.points || []), { numericCols: t, categoricalCols:
|
|
240
|
+
const n = e.flatMap((a) => a.points || []), { numericCols: t, categoricalCols: s, commentCols: r, byType: i } = bt(n), o = t[0] || s[0] || "";
|
|
241
241
|
return {
|
|
242
242
|
numericProps: t,
|
|
243
|
-
categoricalProps:
|
|
244
|
-
commentProps:
|
|
243
|
+
categoricalProps: s,
|
|
244
|
+
commentProps: r,
|
|
245
245
|
columnMeta: i,
|
|
246
246
|
defaultProp: o
|
|
247
247
|
};
|
|
248
248
|
}
|
|
249
249
|
async function Pt(e, n = null) {
|
|
250
|
-
return await
|
|
250
|
+
return await Ct(e);
|
|
251
251
|
}
|
|
252
|
-
async function
|
|
253
|
-
return await
|
|
252
|
+
async function Dt(e, n, t = null) {
|
|
253
|
+
return await Tt(e, n);
|
|
254
254
|
}
|
|
255
|
-
function
|
|
255
|
+
function xt(e = [], n = "") {
|
|
256
256
|
if (!e.length) return null;
|
|
257
|
-
const { numericProps: t, categoricalProps:
|
|
257
|
+
const { numericProps: t, categoricalProps: s, commentProps: r, columnMeta: i, defaultProp: o } = Le(e), a = e.map((u) => u.id || u.holeId).filter(Boolean), l = rt({
|
|
258
258
|
holeIds: a,
|
|
259
259
|
focusedHoleId: n,
|
|
260
260
|
plotCount: 4,
|
|
261
261
|
defaultProp: o,
|
|
262
|
-
categoricalProps:
|
|
263
|
-
commentProps:
|
|
262
|
+
categoricalProps: s,
|
|
263
|
+
commentProps: r,
|
|
264
264
|
numericDefaultChartType: "line"
|
|
265
265
|
});
|
|
266
266
|
return {
|
|
267
267
|
holes: e,
|
|
268
268
|
numericProps: t,
|
|
269
|
-
categoricalProps:
|
|
270
|
-
commentProps:
|
|
269
|
+
categoricalProps: s,
|
|
270
|
+
commentProps: r,
|
|
271
271
|
columnMeta: i,
|
|
272
272
|
defaultProp: o,
|
|
273
273
|
traceConfigs: l
|
|
274
274
|
};
|
|
275
275
|
}
|
|
276
|
-
async function
|
|
277
|
-
const { holes:
|
|
278
|
-
if (!
|
|
279
|
-
return
|
|
276
|
+
async function vn(e, n = "", t = null) {
|
|
277
|
+
const { holes: s } = await Mt(e, t), r = xt(s, n);
|
|
278
|
+
if (!r) throw new Error("No valid assay intervals found.");
|
|
279
|
+
return r;
|
|
280
280
|
}
|
|
281
|
-
function
|
|
282
|
-
return new Promise((t,
|
|
281
|
+
function In(e, n = null) {
|
|
282
|
+
return new Promise((t, s) => {
|
|
283
283
|
J.parse(e, {
|
|
284
284
|
header: !0,
|
|
285
285
|
dynamicTyping: !0,
|
|
286
286
|
skipEmptyLines: !0,
|
|
287
|
-
complete: (
|
|
288
|
-
const i =
|
|
287
|
+
complete: (r) => {
|
|
288
|
+
const i = r.data.map((o) => Rt(o, n)).filter((o) => o[_] && Number.isFinite(o[G]) && Number.isFinite(o[Y]) && Number.isFinite(o[j]));
|
|
289
289
|
t(i);
|
|
290
290
|
},
|
|
291
|
-
error: (
|
|
291
|
+
error: (r) => s(k("parseSurveyCSV", r))
|
|
292
292
|
});
|
|
293
293
|
});
|
|
294
294
|
}
|
|
295
|
-
function
|
|
296
|
-
const t = ie(e, null, n),
|
|
295
|
+
function Rt(e, n = null) {
|
|
296
|
+
const t = ie(e, null, n), s = t[_], r = t[de] || t.project || t.project_code, i = he(t[se]), o = he(t[re]), a = he(t[G]), l = he(t[Y]), u = he(t[j]), c = he(t.maxdepth);
|
|
297
297
|
return {
|
|
298
298
|
raw: t,
|
|
299
|
-
[_]:
|
|
300
|
-
[de]:
|
|
301
|
-
[
|
|
302
|
-
[
|
|
303
|
-
[
|
|
299
|
+
[_]: s,
|
|
300
|
+
[de]: r,
|
|
301
|
+
[se]: i,
|
|
302
|
+
[re]: o,
|
|
303
|
+
[G]: a,
|
|
304
304
|
[Y]: l,
|
|
305
305
|
[j]: u,
|
|
306
306
|
maxdepth: c,
|
|
307
307
|
// Legacy field names for backwards compatibility
|
|
308
|
-
project_code:
|
|
308
|
+
project_code: r,
|
|
309
309
|
latitude: i,
|
|
310
310
|
longitude: o,
|
|
311
311
|
surveydepth: a
|
|
@@ -315,7 +315,7 @@ const he = (e) => {
|
|
|
315
315
|
const n = Number(e);
|
|
316
316
|
return Number.isFinite(n) ? n : void 0;
|
|
317
317
|
};
|
|
318
|
-
function
|
|
318
|
+
function Sn(e, n) {
|
|
319
319
|
var u, c, m, d;
|
|
320
320
|
const t = /* @__PURE__ */ new Map();
|
|
321
321
|
e.forEach((f) => {
|
|
@@ -324,7 +324,7 @@ function Cn(e, n) {
|
|
|
324
324
|
const y = g.toLowerCase();
|
|
325
325
|
t.has(y) || t.set(y, f);
|
|
326
326
|
});
|
|
327
|
-
const
|
|
327
|
+
const s = ((u = e[0]) == null ? void 0 : u.lat) ?? ((c = e[0]) == null ? void 0 : c[se]) ?? 0, r = ((m = e[0]) == null ? void 0 : m.lng) ?? ((d = e[0]) == null ? void 0 : d[re]) ?? 0, i = 111132, o = 111320 * Math.cos(s * Math.PI / 180), a = /* @__PURE__ */ new Map();
|
|
328
328
|
n.forEach((f) => {
|
|
329
329
|
const g = (f[_] || "").toString().trim();
|
|
330
330
|
if (!g) return;
|
|
@@ -335,54 +335,54 @@ function Cn(e, n) {
|
|
|
335
335
|
return a.forEach((f, g) => {
|
|
336
336
|
const y = t.get(g);
|
|
337
337
|
if (!y) return;
|
|
338
|
-
const b = f.filter((
|
|
338
|
+
const b = f.filter((I) => Number.isFinite(I[G] ?? I.surveydepth)).sort((I, z) => (I[G] ?? I.surveydepth) - (z[G] ?? z.surveydepth));
|
|
339
339
|
if (!b.length) return;
|
|
340
|
-
const h = y.lat ?? y[
|
|
341
|
-
let
|
|
342
|
-
for (let
|
|
343
|
-
const
|
|
340
|
+
const h = y.lat ?? y[se], E = y.lng ?? y[re], A = 111132, x = 111320 * Math.cos(h * Math.PI / 180), H = (E - r) * o, O = (h - s) * i, P = [];
|
|
341
|
+
let R = 0, V = 0, p = 0;
|
|
342
|
+
for (let I = 0; I < b.length; I += 1) {
|
|
343
|
+
const z = b[I], w = b[I - 1], v = z[G] ?? z.surveydepth, N = z[j] ?? z.azimuth, D = z[Y] ?? z.dip;
|
|
344
344
|
if (!w) {
|
|
345
345
|
P.push({
|
|
346
|
-
x:
|
|
347
|
-
y: O +
|
|
346
|
+
x: H + R,
|
|
347
|
+
y: O + V,
|
|
348
348
|
z: 0,
|
|
349
|
-
md:
|
|
349
|
+
md: v,
|
|
350
350
|
azimuth: N,
|
|
351
|
-
dip:
|
|
351
|
+
dip: D
|
|
352
352
|
});
|
|
353
353
|
continue;
|
|
354
354
|
}
|
|
355
|
-
const
|
|
356
|
-
if (
|
|
357
|
-
const
|
|
358
|
-
Math.sin(
|
|
359
|
-
), me = be > 1e-6 ? 2 / be * Math.tan(be / 2) : 1, Oe = 0.5 *
|
|
360
|
-
|
|
361
|
-
x:
|
|
362
|
-
y: O +
|
|
355
|
+
const F = w[G] ?? w.surveydepth, L = w[j] ?? w.azimuth, U = w[Y] ?? w.dip, B = v - F;
|
|
356
|
+
if (B <= 0) continue;
|
|
357
|
+
const $ = Ve(U), q = Ve(D), K = Fe(L), ae = Fe(N), be = Math.acos(
|
|
358
|
+
Math.sin($) * Math.sin(q) * Math.cos(K - ae) + Math.cos($) * Math.cos(q)
|
|
359
|
+
), me = be > 1e-6 ? 2 / be * Math.tan(be / 2) : 1, Oe = 0.5 * B * (Math.sin($) * Math.cos(K) + Math.sin(q) * Math.cos(ae)) * me, fe = 0.5 * B * (Math.sin($) * Math.sin(K) + Math.sin(q) * Math.sin(ae)) * me, yt = 0.5 * B * (Math.cos($) + Math.cos(q)) * me;
|
|
360
|
+
R += Oe, V += fe, p += yt, P.push({
|
|
361
|
+
x: H + R,
|
|
362
|
+
y: O + V,
|
|
363
363
|
z: -p,
|
|
364
364
|
// render with z up; depth down
|
|
365
|
-
md:
|
|
365
|
+
md: v,
|
|
366
366
|
azimuth: N,
|
|
367
|
-
dip:
|
|
367
|
+
dip: D
|
|
368
368
|
});
|
|
369
369
|
}
|
|
370
|
-
const
|
|
371
|
-
...
|
|
372
|
-
lat: h +
|
|
373
|
-
lng:
|
|
370
|
+
const T = P.map((I) => ({
|
|
371
|
+
...I,
|
|
372
|
+
lat: h + I.y / A,
|
|
373
|
+
lng: E + I.x / x
|
|
374
374
|
}));
|
|
375
375
|
l.push({
|
|
376
376
|
id: y[_] || y.holeId || g,
|
|
377
377
|
project: y[de] || y.project_id || y.project || "",
|
|
378
|
-
points:
|
|
378
|
+
points: T,
|
|
379
379
|
collar: y
|
|
380
380
|
});
|
|
381
381
|
}), l;
|
|
382
382
|
}
|
|
383
|
-
const
|
|
384
|
-
const n = Number(e), t = 90 + (Number.isFinite(n) ? n : 0),
|
|
385
|
-
return
|
|
383
|
+
const Fe = (e) => e * Math.PI / 180, Ve = (e) => {
|
|
384
|
+
const n = Number(e), t = 90 + (Number.isFinite(n) ? n : 0), s = Math.min(180, Math.max(0, t));
|
|
385
|
+
return Fe(s);
|
|
386
386
|
};
|
|
387
387
|
function te(e, n = void 0) {
|
|
388
388
|
const t = Number(e);
|
|
@@ -391,27 +391,27 @@ function te(e, n = void 0) {
|
|
|
391
391
|
function je(e) {
|
|
392
392
|
return e == null ? "" : `${e}`.trim();
|
|
393
393
|
}
|
|
394
|
-
function
|
|
395
|
-
const t = n || "hole_id",
|
|
396
|
-
if (!
|
|
394
|
+
function Ce(e = [], n = null) {
|
|
395
|
+
const t = n || "hole_id", r = [t, "hole_id", "holeId", "id"].find((i) => e.some((o) => je(o == null ? void 0 : o[i])));
|
|
396
|
+
if (!r)
|
|
397
397
|
throw k("canonicalizeHoleIdRows", new Error(`hole id column '${t}' not found`));
|
|
398
398
|
return {
|
|
399
|
-
aliasCol:
|
|
399
|
+
aliasCol: r,
|
|
400
400
|
rows: e.map((i) => ({
|
|
401
401
|
...i,
|
|
402
|
-
hole_id: je(i == null ? void 0 : i[
|
|
402
|
+
hole_id: je(i == null ? void 0 : i[r])
|
|
403
403
|
}))
|
|
404
404
|
};
|
|
405
405
|
}
|
|
406
406
|
function Ye(e) {
|
|
407
407
|
return Number(e) * Math.PI / 180;
|
|
408
408
|
}
|
|
409
|
-
function
|
|
410
|
-
const t = Ye(e),
|
|
411
|
-
return { ca:
|
|
409
|
+
function xe(e, n) {
|
|
410
|
+
const t = Ye(e), s = Ye(n), r = Math.cos(s) * Math.sin(t), i = Math.cos(s) * Math.cos(t), o = Math.sin(s) * -1;
|
|
411
|
+
return { ca: r, cb: i, cc: o };
|
|
412
412
|
}
|
|
413
|
-
function
|
|
414
|
-
const o =
|
|
413
|
+
function zt(e, n, t, s, r, i = "minimum_curvature") {
|
|
414
|
+
const o = xe(n, t), a = xe(s, r);
|
|
415
415
|
if (i === "tangential")
|
|
416
416
|
return {
|
|
417
417
|
dx: e * o.ca,
|
|
@@ -421,7 +421,7 @@ function Rt(e, n, t, r, s, i = "minimum_curvature") {
|
|
|
421
421
|
dip: t
|
|
422
422
|
};
|
|
423
423
|
if (i === "balanced_tangential") {
|
|
424
|
-
const m = 0.5 * (n +
|
|
424
|
+
const m = 0.5 * (n + s), d = 0.5 * (t + r), f = xe(m, d);
|
|
425
425
|
return {
|
|
426
426
|
dx: e * f.ca,
|
|
427
427
|
dy: e * f.cb,
|
|
@@ -435,16 +435,16 @@ function Rt(e, n, t, r, s, i = "minimum_curvature") {
|
|
|
435
435
|
dx: 0.5 * e * (o.ca + a.ca) * c,
|
|
436
436
|
dy: 0.5 * e * (o.cb + a.cb) * c,
|
|
437
437
|
dz: 0.5 * e * (o.cc + a.cc) * c,
|
|
438
|
-
azimuth:
|
|
439
|
-
dip:
|
|
438
|
+
azimuth: s,
|
|
439
|
+
dip: r
|
|
440
440
|
};
|
|
441
441
|
}
|
|
442
442
|
function ke(e = [], n = [], t = {}) {
|
|
443
443
|
const {
|
|
444
|
-
step:
|
|
445
|
-
holeIdCol:
|
|
444
|
+
step: s = 1,
|
|
445
|
+
holeIdCol: r = null,
|
|
446
446
|
method: i = "minimum_curvature"
|
|
447
|
-
} = t, o = Number.isFinite(Number(
|
|
447
|
+
} = t, o = Number.isFinite(Number(s)) && Number(s) > 0 ? Number(s) : 1, a = Ce(e, r), l = Ce(n, r || a.aliasCol);
|
|
448
448
|
if (!a.rows.length || !l.rows.length) return [];
|
|
449
449
|
const u = /* @__PURE__ */ new Map();
|
|
450
450
|
a.rows.forEach((d) => {
|
|
@@ -463,76 +463,76 @@ function ke(e = [], n = [], t = {}) {
|
|
|
463
463
|
from: te(P.from),
|
|
464
464
|
azimuth: te(P.azimuth),
|
|
465
465
|
dip: te(P.dip)
|
|
466
|
-
})).filter((P) => Number.isFinite(P.from) && Number.isFinite(P.azimuth) && Number.isFinite(P.dip)).sort((P,
|
|
466
|
+
})).filter((P) => Number.isFinite(P.from) && Number.isFinite(P.azimuth) && Number.isFinite(P.dip)).sort((P, R) => P.from - R.from);
|
|
467
467
|
if (!y.length) return;
|
|
468
|
-
let b = te(g.x, 0), h = te(g.y, 0),
|
|
469
|
-
const
|
|
468
|
+
let b = te(g.x, 0), h = te(g.y, 0), E = te(g.z, 0), A = y[0].from;
|
|
469
|
+
const x = y[0].azimuth, H = y[0].dip, O = {
|
|
470
470
|
hole_id: f,
|
|
471
|
-
md:
|
|
471
|
+
md: A,
|
|
472
472
|
x: b,
|
|
473
473
|
y: h,
|
|
474
|
-
z:
|
|
475
|
-
azimuth:
|
|
476
|
-
dip:
|
|
474
|
+
z: E,
|
|
475
|
+
azimuth: x,
|
|
476
|
+
dip: H
|
|
477
477
|
};
|
|
478
478
|
a.aliasCol !== "hole_id" && g[a.aliasCol] !== void 0 && (O[a.aliasCol] = g[a.aliasCol]), m.push(O);
|
|
479
479
|
for (let P = 0; P < y.length - 1; P += 1) {
|
|
480
|
-
const
|
|
481
|
-
if (
|
|
482
|
-
const
|
|
483
|
-
for (let
|
|
484
|
-
|
|
485
|
-
const N = (
|
|
486
|
-
b += L.dx, h += L.dy,
|
|
487
|
-
const
|
|
480
|
+
const R = y[P], V = y[P + 1], p = R.from, I = V.from - p;
|
|
481
|
+
if (I <= 0) continue;
|
|
482
|
+
const z = Math.max(1, Math.ceil(I / o)), w = I / z;
|
|
483
|
+
for (let v = 0; v < z; v += 1) {
|
|
484
|
+
A += w;
|
|
485
|
+
const N = (A - p) / I, D = R.azimuth + N * (V.azimuth - R.azimuth), F = R.dip + N * (V.dip - R.dip), L = zt(w, R.azimuth, R.dip, V.azimuth, V.dip, i);
|
|
486
|
+
b += L.dx, h += L.dy, E += L.dz;
|
|
487
|
+
const U = {
|
|
488
488
|
hole_id: f,
|
|
489
|
-
md:
|
|
489
|
+
md: A,
|
|
490
490
|
x: b,
|
|
491
491
|
y: h,
|
|
492
|
-
z:
|
|
493
|
-
azimuth: i === "minimum_curvature" ?
|
|
494
|
-
dip: i === "minimum_curvature" ?
|
|
492
|
+
z: E,
|
|
493
|
+
azimuth: i === "minimum_curvature" ? D : L.azimuth,
|
|
494
|
+
dip: i === "minimum_curvature" ? F : L.dip
|
|
495
495
|
};
|
|
496
|
-
a.aliasCol !== "hole_id" && g[a.aliasCol] !== void 0 && (
|
|
496
|
+
a.aliasCol !== "hole_id" && g[a.aliasCol] !== void 0 && (U[a.aliasCol] = g[a.aliasCol]), m.push(U);
|
|
497
497
|
}
|
|
498
498
|
}
|
|
499
499
|
}), m;
|
|
500
500
|
}
|
|
501
|
-
function
|
|
501
|
+
function Ft(e, n, t = {}) {
|
|
502
502
|
return ke(e, n, { ...t, method: "minimum_curvature" });
|
|
503
503
|
}
|
|
504
504
|
function Ln(e, n, t = {}) {
|
|
505
505
|
return ke(e, n, { ...t, method: "tangential" });
|
|
506
506
|
}
|
|
507
|
-
function
|
|
507
|
+
function Cn(e, n, t = {}) {
|
|
508
508
|
return ke(e, n, { ...t, method: "balanced_tangential" });
|
|
509
509
|
}
|
|
510
|
-
function
|
|
511
|
-
return
|
|
510
|
+
function Tn(e, n, t = {}) {
|
|
511
|
+
return Ft(e, n, t);
|
|
512
512
|
}
|
|
513
|
-
function
|
|
513
|
+
function $t(e, n) {
|
|
514
514
|
if (!e.length || !Number.isFinite(n)) return null;
|
|
515
|
-
let t = null,
|
|
516
|
-
for (let
|
|
517
|
-
const i = e[
|
|
515
|
+
let t = null, s = 1 / 0;
|
|
516
|
+
for (let r = 0; r < e.length; r += 1) {
|
|
517
|
+
const i = e[r], o = te(i.md);
|
|
518
518
|
if (!Number.isFinite(o)) continue;
|
|
519
519
|
const a = Math.abs(o - n);
|
|
520
|
-
a <
|
|
520
|
+
a < s && (s = a, t = i);
|
|
521
521
|
}
|
|
522
522
|
return t;
|
|
523
523
|
}
|
|
524
|
-
function
|
|
525
|
-
const
|
|
526
|
-
if (!
|
|
524
|
+
function Mn(e = [], n = [], t = {}) {
|
|
525
|
+
const s = t.holeIdCol || "hole_id", r = Ce(e, s), i = Ce(n, s);
|
|
526
|
+
if (!r.rows.length || !i.rows.length) return [...r.rows];
|
|
527
527
|
const o = /* @__PURE__ */ new Map();
|
|
528
528
|
return i.rows.forEach((a) => {
|
|
529
529
|
a.hole_id && (o.has(a.hole_id) || o.set(a.hole_id, []), o.get(a.hole_id).push(a));
|
|
530
530
|
}), o.forEach((a, l) => {
|
|
531
531
|
o.set(l, [...a].sort((u, c) => te(u.md, 0) - te(c.md, 0)));
|
|
532
|
-
}),
|
|
532
|
+
}), r.rows.map((a) => {
|
|
533
533
|
const l = te(a.from), u = te(a.to), c = Number.isFinite(l) && Number.isFinite(u) ? 0.5 * (l + u) : void 0;
|
|
534
534
|
if (!a.hole_id || !Number.isFinite(c)) return { ...a };
|
|
535
|
-
const m =
|
|
535
|
+
const m = $t(o.get(a.hole_id) || [], c);
|
|
536
536
|
if (!m) return { ...a };
|
|
537
537
|
const d = { ...a };
|
|
538
538
|
return ["md", "x", "y", "z", "azimuth", "dip"].forEach((f) => {
|
|
@@ -541,15 +541,15 @@ function Tn(e = [], n = [], t = {}) {
|
|
|
541
541
|
});
|
|
542
542
|
}
|
|
543
543
|
function On(e, n = null) {
|
|
544
|
-
return new Promise((t,
|
|
544
|
+
return new Promise((t, s) => {
|
|
545
545
|
J.parse(e, {
|
|
546
546
|
header: !0,
|
|
547
547
|
dynamicTyping: !0,
|
|
548
548
|
skipEmptyLines: !0,
|
|
549
|
-
complete: (
|
|
549
|
+
complete: (r) => {
|
|
550
550
|
const i = /* @__PURE__ */ new Map();
|
|
551
|
-
|
|
552
|
-
const u = ie(a, null, n), c = u[_], m = c !== void 0 ? `${c}`.trim() : "", d = u[pe] ?? u.x, f = u[ye] ?? u.y, g = u[
|
|
551
|
+
r.data.forEach((a, l) => {
|
|
552
|
+
const u = ie(a, null, n), c = u[_], m = c !== void 0 ? `${c}`.trim() : "", d = u[pe] ?? u.x, f = u[ye] ?? u.y, g = u[ve] ?? u.z, y = u.order ?? l;
|
|
553
553
|
!m || d === null || d === void 0 || f === null || f === void 0 || g === null || g === void 0 || (i.has(m) || i.set(m, []), i.get(m).push({
|
|
554
554
|
...u,
|
|
555
555
|
holeId: m,
|
|
@@ -570,7 +570,7 @@ function On(e, n = null) {
|
|
|
570
570
|
}));
|
|
571
571
|
t({ holes: o });
|
|
572
572
|
},
|
|
573
|
-
error: (
|
|
573
|
+
error: (r) => s(k("parseDrillholesCSV", r))
|
|
574
574
|
});
|
|
575
575
|
});
|
|
576
576
|
}
|
|
@@ -583,9 +583,9 @@ function Z(e) {
|
|
|
583
583
|
}
|
|
584
584
|
function Ne(e = [], n = []) {
|
|
585
585
|
const t = [...e];
|
|
586
|
-
return t.sort((
|
|
586
|
+
return t.sort((s, r) => {
|
|
587
587
|
for (let i = 0; i < n.length; i += 1) {
|
|
588
|
-
const o = n[i], a =
|
|
588
|
+
const o = n[i], a = s == null ? void 0 : s[o], l = r == null ? void 0 : r[o];
|
|
589
589
|
if (a !== l)
|
|
590
590
|
return a == null ? 1 : l == null ? -1 : typeof a == "number" && typeof l == "number" ? a - l : `${a}`.localeCompare(`${l}`);
|
|
591
591
|
}
|
|
@@ -594,39 +594,39 @@ function Ne(e = [], n = []) {
|
|
|
594
594
|
}
|
|
595
595
|
function kt(e = [], n = "Intervals") {
|
|
596
596
|
if (!e.length) return;
|
|
597
|
-
const t = Ne(e, [_,
|
|
598
|
-
t.forEach((
|
|
599
|
-
const i = `${(
|
|
597
|
+
const t = Ne(e, [_, C, M]), s = /* @__PURE__ */ new Map();
|
|
598
|
+
t.forEach((r) => {
|
|
599
|
+
const i = `${(r == null ? void 0 : r[_]) ?? ""}`.trim(), o = Number(r == null ? void 0 : r[C]), a = Number(r == null ? void 0 : r[M]);
|
|
600
600
|
if (!i || !Number.isFinite(o) || !Number.isFinite(a)) return;
|
|
601
|
-
const l =
|
|
601
|
+
const l = s.get(i);
|
|
602
602
|
if (Number.isFinite(l) && o < l)
|
|
603
603
|
throw k(
|
|
604
604
|
"validateNoOverlappingIntervals",
|
|
605
605
|
new Error(`${n} intervals overlap for hole '${i}': from=${o} is less than previous to=${l}`)
|
|
606
606
|
);
|
|
607
|
-
|
|
607
|
+
s.set(i, a);
|
|
608
608
|
});
|
|
609
609
|
}
|
|
610
610
|
function wt(e, n = {}) {
|
|
611
|
-
return new Promise((t,
|
|
611
|
+
return new Promise((t, s) => {
|
|
612
612
|
J.parse(e, {
|
|
613
613
|
header: !0,
|
|
614
614
|
dynamicTyping: !0,
|
|
615
615
|
skipEmptyLines: !0,
|
|
616
616
|
...n,
|
|
617
|
-
complete: (
|
|
618
|
-
error: (
|
|
617
|
+
complete: (r) => t(Array.isArray(r == null ? void 0 : r.data) ? r.data : []),
|
|
618
|
+
error: (r) => s(k("loadTable(csv)", r))
|
|
619
619
|
});
|
|
620
620
|
});
|
|
621
621
|
}
|
|
622
|
-
function
|
|
623
|
-
return e.map((
|
|
622
|
+
function Ht(e = [], n = null, t = null) {
|
|
623
|
+
return e.map((s) => ie(s, n, t));
|
|
624
624
|
}
|
|
625
|
-
async function
|
|
625
|
+
async function Me(e, n = {}) {
|
|
626
626
|
const {
|
|
627
627
|
kind: t = "csv",
|
|
628
|
-
columnMap:
|
|
629
|
-
sourceColumnMap:
|
|
628
|
+
columnMap: s = null,
|
|
629
|
+
sourceColumnMap: r = null,
|
|
630
630
|
papaParseConfig: i = {}
|
|
631
631
|
} = n;
|
|
632
632
|
let o;
|
|
@@ -635,18 +635,18 @@ async function Te(e, n = {}) {
|
|
|
635
635
|
else if (t === "csv")
|
|
636
636
|
o = await wt(e, i);
|
|
637
637
|
else throw t === "parquet" || t === "sql" ? k("loadTable", new Error(`Unsupported kind in JS runtime: ${t}`)) : k("loadTable", new Error(`Unsupported kind: ${t}`));
|
|
638
|
-
return
|
|
638
|
+
return Ht(o, s, r);
|
|
639
639
|
}
|
|
640
640
|
async function Pn(e, n = {}) {
|
|
641
641
|
const {
|
|
642
642
|
crs: t = null,
|
|
643
|
-
sourceColumnMap:
|
|
644
|
-
keepAll:
|
|
643
|
+
sourceColumnMap: s = null,
|
|
644
|
+
keepAll: r = !0,
|
|
645
645
|
...i
|
|
646
|
-
} = n, o = await
|
|
646
|
+
} = n, o = await Me(e, { ...i, sourceColumnMap: s });
|
|
647
647
|
if (!o.some((d) => _ in d))
|
|
648
648
|
throw k("loadCollars", new Error(`Collar table missing column: ${_}`));
|
|
649
|
-
const l = o.some((d) => pe in d && ye in d), u = o.some((d) =>
|
|
649
|
+
const l = o.some((d) => pe in d && ye in d), u = o.some((d) => se in d && re in d);
|
|
650
650
|
if (!l && !u)
|
|
651
651
|
throw k("loadCollars", new Error("Collar table missing coordinate columns (need easting/northing or latitude/longitude)"));
|
|
652
652
|
const c = o.map((d) => {
|
|
@@ -655,18 +655,18 @@ async function Pn(e, n = {}) {
|
|
|
655
655
|
const g = f[_];
|
|
656
656
|
f[_] = g == null ? "" : `${g}`.trim();
|
|
657
657
|
}
|
|
658
|
-
return
|
|
658
|
+
return se in f && (f[se] = Z(f[se])), re in f && (f[re] = Z(f[re])), ve in f && (f[ve] = Z(f[ve])), pe in f && (f[pe] = Z(f[pe])), ye in f && (f[ye] = Z(f[ye])), !("datasource_hole_id" in f) && _ in f && (f.datasource_hole_id = f[_]), f;
|
|
659
659
|
});
|
|
660
|
-
if (!c.every((d) => !(!d[_] || u && (!Number.isFinite(d[
|
|
660
|
+
if (!c.every((d) => !(!d[_] || u && (!Number.isFinite(d[se]) || !Number.isFinite(d[re])) || l && !u && (!Number.isFinite(d[pe]) || !Number.isFinite(d[ye])))))
|
|
661
661
|
throw k("loadCollars", new Error("Collar table has missing required values"));
|
|
662
662
|
return c;
|
|
663
663
|
}
|
|
664
|
-
async function
|
|
664
|
+
async function Dn(e, n = {}) {
|
|
665
665
|
const {
|
|
666
666
|
sourceColumnMap: t = null,
|
|
667
|
-
keepAll:
|
|
668
|
-
...
|
|
669
|
-
} = n, i = await
|
|
667
|
+
keepAll: s = !0,
|
|
668
|
+
...r
|
|
669
|
+
} = n, i = await Me(e, { ...r, sourceColumnMap: t }), o = [_, G, j, Y];
|
|
670
670
|
for (const u of o)
|
|
671
671
|
if (!i.some((m) => u in m))
|
|
672
672
|
throw k("loadSurveys", new Error(`Survey table missing column: ${u}`));
|
|
@@ -676,18 +676,18 @@ async function xn(e, n = {}) {
|
|
|
676
676
|
const m = c[_];
|
|
677
677
|
c[_] = m == null ? "" : `${m}`.trim();
|
|
678
678
|
}
|
|
679
|
-
return
|
|
679
|
+
return G in c && (c[G] = Z(c[G])), M in c && (c[M] = Z(c[M])), j in c && (c[j] = Z(c[j])), Y in c && (c[Y] = Z(c[Y])), c;
|
|
680
680
|
});
|
|
681
|
-
if (!a.every((u) => !(!u[_] || !Number.isFinite(u[
|
|
681
|
+
if (!a.every((u) => !(!u[_] || !Number.isFinite(u[G]) || !Number.isFinite(u[j]) || !Number.isFinite(u[Y]))))
|
|
682
682
|
throw k("loadSurveys", new Error("Survey table has missing required values"));
|
|
683
|
-
return Ne(a, [_,
|
|
683
|
+
return Ne(a, [_, G]);
|
|
684
684
|
}
|
|
685
|
-
async function
|
|
685
|
+
async function xn(e, n = {}) {
|
|
686
686
|
const {
|
|
687
687
|
sourceColumnMap: t = null,
|
|
688
|
-
keepAll:
|
|
689
|
-
...
|
|
690
|
-
} = n, i = await
|
|
688
|
+
keepAll: s = !0,
|
|
689
|
+
...r
|
|
690
|
+
} = n, i = await Me(e, { ...r, sourceColumnMap: t }), o = [_, C, M];
|
|
691
691
|
for (const u of o)
|
|
692
692
|
if (!i.some((m) => u in m))
|
|
693
693
|
throw k("loadAssays", new Error(`Assay table missing column: ${u}`));
|
|
@@ -697,18 +697,18 @@ async function Dn(e, n = {}) {
|
|
|
697
697
|
const m = c[_];
|
|
698
698
|
c[_] = m == null ? "" : `${m}`.trim();
|
|
699
699
|
}
|
|
700
|
-
return
|
|
700
|
+
return C in c && (c[C] = Z(c[C])), M in c && (c[M] = Z(c[M])), C in c && M in c && Number.isFinite(c[C]) && Number.isFinite(c[M]) && (c[Ee] = 0.5 * (c[C] + c[M])), c;
|
|
701
701
|
});
|
|
702
|
-
if (!a.every((u) => !(!u[_] || !Number.isFinite(u[
|
|
702
|
+
if (!a.every((u) => !(!u[_] || !Number.isFinite(u[C]) || !Number.isFinite(u[M]) || !(u[M] > u[C]))))
|
|
703
703
|
throw k("loadAssays", new Error("Assay table has missing required values"));
|
|
704
|
-
return Ne(a, [_,
|
|
704
|
+
return Ne(a, [_, C, M]);
|
|
705
705
|
}
|
|
706
|
-
async function
|
|
706
|
+
async function Rn(e, n = {}) {
|
|
707
707
|
const {
|
|
708
708
|
sourceColumnMap: t = null,
|
|
709
|
-
keepAll:
|
|
710
|
-
...
|
|
711
|
-
} = n, i = await
|
|
709
|
+
keepAll: s = !0,
|
|
710
|
+
...r
|
|
711
|
+
} = n, i = await Me(e, { ...r, sourceColumnMap: t }), o = [_, C, M];
|
|
712
712
|
for (const c of o)
|
|
713
713
|
if (!i.some((d) => c in d))
|
|
714
714
|
throw k("loadGeology", new Error(`Geology table missing column: ${c}`));
|
|
@@ -718,76 +718,76 @@ async function zn(e, n = {}) {
|
|
|
718
718
|
const g = m[_];
|
|
719
719
|
m[_] = g == null ? "" : `${g}`.trim();
|
|
720
720
|
}
|
|
721
|
-
|
|
721
|
+
C in m && (m[C] = Z(m[C])), M in m && (m[M] = Z(m[M])), C in m && M in m && Number.isFinite(m[C]) && Number.isFinite(m[M]) && (m[M] === m[C] && (m[C] = Math.round(m[C] * 1e3) / 1e3, m[M] = m[C] + 1e-3), m[Ee] = 0.5 * (m[C] + m[M]));
|
|
722
722
|
const d = m[le] !== void 0 && m[le] !== null && `${m[le]}`.trim() !== "", f = m[ce] !== void 0 && m[ce] !== null && `${m[ce]}`.trim() !== "";
|
|
723
723
|
return !d && f && (m[le] = m[ce]), d && !f && (m[ce] = m[le]), m;
|
|
724
724
|
});
|
|
725
|
-
if (!a.every((c) => !(!c[_] || !Number.isFinite(c[
|
|
725
|
+
if (!a.every((c) => !(!c[_] || !Number.isFinite(c[C]) || !Number.isFinite(c[M]) || !(c[M] > c[C]))))
|
|
726
726
|
throw k("loadGeology", new Error("Geology table has missing or invalid interval values"));
|
|
727
727
|
if (!a.some((c) => {
|
|
728
728
|
const m = c[le], d = c[ce];
|
|
729
729
|
return m != null && `${m}`.trim() !== "" || d != null && `${d}`.trim() !== "";
|
|
730
730
|
}))
|
|
731
731
|
throw k("loadGeology", new Error(`Geology table missing categorical columns: ${le} or ${ce}`));
|
|
732
|
-
if (kt(a, "Geology"), !
|
|
732
|
+
if (kt(a, "Geology"), !s) {
|
|
733
733
|
const c = new Set(Object.keys(_t));
|
|
734
734
|
return Ne(
|
|
735
735
|
a.map((m) => Object.fromEntries(Object.entries(m).filter(([d]) => c.has(d)))),
|
|
736
|
-
[_,
|
|
736
|
+
[_, C, M]
|
|
737
737
|
);
|
|
738
738
|
}
|
|
739
|
-
return Ne(a, [_,
|
|
739
|
+
return Ne(a, [_, C, M]);
|
|
740
740
|
}
|
|
741
|
-
function
|
|
742
|
-
const
|
|
741
|
+
function zn(e = [], n = [], t = {}) {
|
|
742
|
+
const s = Array.isArray(t.onCols) && t.onCols.length ? t.onCols : [_];
|
|
743
743
|
if (!n.length) return [...e];
|
|
744
|
-
const
|
|
744
|
+
const r = (o) => s.map((a) => `${(o == null ? void 0 : o[a]) ?? ""}`).join("|"), i = /* @__PURE__ */ new Map();
|
|
745
745
|
return n.forEach((o) => {
|
|
746
|
-
i.set(
|
|
746
|
+
i.set(r(o), o);
|
|
747
747
|
}), e.map((o) => {
|
|
748
|
-
const a = i.get(
|
|
748
|
+
const a = i.get(r(o));
|
|
749
749
|
if (!a) return { ...o };
|
|
750
750
|
const l = { ...o };
|
|
751
751
|
return Object.entries(a).forEach(([u, c]) => {
|
|
752
|
-
|
|
752
|
+
s.includes(u) || (Object.prototype.hasOwnProperty.call(l, u) ? l[`${u}_trace`] = c : l[u] = c);
|
|
753
753
|
}), l;
|
|
754
754
|
});
|
|
755
755
|
}
|
|
756
|
-
function
|
|
757
|
-
return n == null ? [...e] : e.length ? e.some((
|
|
756
|
+
function Fn(e = [], n = null) {
|
|
757
|
+
return n == null ? [...e] : e.length ? e.some((s) => de in s) ? e.filter((s) => (s == null ? void 0 : s[de]) === n) : [...e] : [];
|
|
758
758
|
}
|
|
759
|
-
function
|
|
759
|
+
function $n(e = [], n = []) {
|
|
760
760
|
return e.map((t) => {
|
|
761
|
-
const
|
|
762
|
-
return n.forEach((
|
|
763
|
-
if (!(
|
|
764
|
-
const i = Z(r
|
|
765
|
-
r
|
|
766
|
-
}),
|
|
761
|
+
const s = { ...t };
|
|
762
|
+
return n.forEach((r) => {
|
|
763
|
+
if (!(r in s)) return;
|
|
764
|
+
const i = Z(s[r]);
|
|
765
|
+
s[r] = i;
|
|
766
|
+
}), s;
|
|
767
767
|
});
|
|
768
768
|
}
|
|
769
769
|
function kn({
|
|
770
770
|
collars: e = [],
|
|
771
771
|
surveys: n = [],
|
|
772
772
|
assays: t = [],
|
|
773
|
-
geology:
|
|
774
|
-
structures:
|
|
773
|
+
geology: s = [],
|
|
774
|
+
structures: r = [],
|
|
775
775
|
metadata: i = {}
|
|
776
776
|
} = {}) {
|
|
777
777
|
return {
|
|
778
778
|
collars: ge(e),
|
|
779
779
|
surveys: ge(n),
|
|
780
780
|
assays: ge(t),
|
|
781
|
-
geology: ge(
|
|
782
|
-
structures: ge(
|
|
781
|
+
geology: ge(s),
|
|
782
|
+
structures: ge(r),
|
|
783
783
|
metadata: i || {}
|
|
784
784
|
};
|
|
785
785
|
}
|
|
786
786
|
const we = (e, n = null) => ie(e, null, n);
|
|
787
|
-
function
|
|
787
|
+
function Ut(e) {
|
|
788
788
|
if (!e.length) return null;
|
|
789
|
-
const n = e[0], t =
|
|
790
|
-
return t ? "interval" :
|
|
789
|
+
const n = e[0], t = C in n && M in n, s = G in n && !t;
|
|
790
|
+
return t ? "interval" : s ? "point" : null;
|
|
791
791
|
}
|
|
792
792
|
function oe(e) {
|
|
793
793
|
const n = Number(e);
|
|
@@ -796,10 +796,10 @@ function oe(e) {
|
|
|
796
796
|
function ot(e) {
|
|
797
797
|
const n = e[_] !== void 0 ? `${e[_]}`.trim() : "";
|
|
798
798
|
if (!n) return null;
|
|
799
|
-
const t = oe(e[
|
|
799
|
+
const t = oe(e[G]);
|
|
800
800
|
return t === null ? null : {
|
|
801
801
|
[_]: n,
|
|
802
|
-
[
|
|
802
|
+
[G]: t,
|
|
803
803
|
[Y]: oe(e[Y]),
|
|
804
804
|
[j]: oe(e[j]),
|
|
805
805
|
comments: e.comments != null ? `${e.comments}` : null,
|
|
@@ -809,14 +809,14 @@ function ot(e) {
|
|
|
809
809
|
function it(e) {
|
|
810
810
|
const n = e[_] !== void 0 ? `${e[_]}`.trim() : "";
|
|
811
811
|
if (!n) return null;
|
|
812
|
-
const t = oe(e[
|
|
813
|
-
if (t === null ||
|
|
814
|
-
const
|
|
812
|
+
const t = oe(e[C]), s = oe(e[M]);
|
|
813
|
+
if (t === null || s === null || s <= t) return null;
|
|
814
|
+
const r = 0.5 * (t + s);
|
|
815
815
|
return {
|
|
816
816
|
[_]: n,
|
|
817
|
-
[
|
|
818
|
-
[
|
|
819
|
-
mid:
|
|
817
|
+
[C]: t,
|
|
818
|
+
[M]: s,
|
|
819
|
+
mid: r,
|
|
820
820
|
[Y]: oe(e[Y]),
|
|
821
821
|
[j]: oe(e[j]),
|
|
822
822
|
classification: e.classification != null ? `${e.classification}` : null,
|
|
@@ -826,15 +826,15 @@ function it(e) {
|
|
|
826
826
|
}
|
|
827
827
|
function wn(e) {
|
|
828
828
|
const n = [], t = [];
|
|
829
|
-
for (const
|
|
830
|
-
const
|
|
831
|
-
i !== null && (i < 0 || i > 90) &&
|
|
829
|
+
for (const s of e) {
|
|
830
|
+
const r = [], i = oe(s[Y]), o = oe(s[j]);
|
|
831
|
+
i !== null && (i < 0 || i > 90) && r.push(`dip ${i} out of range [0, 90]`), o !== null && (o < 0 || o >= 360) && r.push(`azimuth ${o} out of range [0, 360)`), r.length ? t.push({ row: s, message: r.join("; ") }) : n.push(s);
|
|
832
832
|
}
|
|
833
833
|
return { valid: n, errors: t };
|
|
834
834
|
}
|
|
835
|
-
function
|
|
836
|
-
return new Promise((t,
|
|
837
|
-
const
|
|
835
|
+
function Hn(e, n = null) {
|
|
836
|
+
return new Promise((t, s) => {
|
|
837
|
+
const r = {
|
|
838
838
|
header: !0,
|
|
839
839
|
dynamicTyping: !0,
|
|
840
840
|
skipEmptyLines: !0,
|
|
@@ -846,48 +846,48 @@ function Bn(e, n = null) {
|
|
|
846
846
|
}
|
|
847
847
|
t(o);
|
|
848
848
|
},
|
|
849
|
-
error: (i) =>
|
|
849
|
+
error: (i) => s(k("parseStructuralPointsCSV", i))
|
|
850
850
|
};
|
|
851
851
|
typeof e == "string" && !e.startsWith("data:") && e.includes(`
|
|
852
|
-
`) ? J.parse(e,
|
|
852
|
+
`) ? J.parse(e, r) : J.parse(e, r);
|
|
853
853
|
});
|
|
854
854
|
}
|
|
855
|
-
function
|
|
856
|
-
return new Promise((t,
|
|
855
|
+
function Un(e, n = null) {
|
|
856
|
+
return new Promise((t, s) => {
|
|
857
857
|
J.parse(e, {
|
|
858
858
|
header: !0,
|
|
859
859
|
dynamicTyping: !0,
|
|
860
860
|
skipEmptyLines: !0,
|
|
861
|
-
complete: (
|
|
861
|
+
complete: (r) => {
|
|
862
862
|
const i = [];
|
|
863
|
-
for (const o of
|
|
863
|
+
for (const o of r.data) {
|
|
864
864
|
const a = we(o, n), l = it(a);
|
|
865
865
|
l && i.push(l);
|
|
866
866
|
}
|
|
867
867
|
t(i);
|
|
868
868
|
},
|
|
869
|
-
error: (
|
|
869
|
+
error: (r) => s(k("parseStructuralIntervalsCSV", r))
|
|
870
870
|
});
|
|
871
871
|
});
|
|
872
872
|
}
|
|
873
|
-
function
|
|
873
|
+
function Bt(e, n = _) {
|
|
874
874
|
const t = /* @__PURE__ */ new Map();
|
|
875
|
-
for (const
|
|
876
|
-
const
|
|
877
|
-
|
|
875
|
+
for (const s of e) {
|
|
876
|
+
const r = s[n] != null ? String(s[n]).trim() : "";
|
|
877
|
+
r && (t.has(r) || t.set(r, { holeId: r, points: [] }), t.get(r).points.push(s));
|
|
878
878
|
}
|
|
879
879
|
return Array.from(t.values());
|
|
880
880
|
}
|
|
881
|
-
function
|
|
882
|
-
return new Promise((t,
|
|
881
|
+
function Gt(e, n = null) {
|
|
882
|
+
return new Promise((t, s) => {
|
|
883
883
|
J.parse(e, {
|
|
884
884
|
header: !0,
|
|
885
885
|
dynamicTyping: !0,
|
|
886
886
|
skipEmptyLines: !0,
|
|
887
|
-
complete: (
|
|
888
|
-
const i =
|
|
887
|
+
complete: (r) => {
|
|
888
|
+
const i = r.data.map((l) => we(l, n)), o = Ut(i);
|
|
889
889
|
if (!o) {
|
|
890
|
-
|
|
890
|
+
s(k(
|
|
891
891
|
"parseStructuralCSV",
|
|
892
892
|
new Error("Structural CSV requires either 'depth' (point) or 'from'/'to' (interval) columns")
|
|
893
893
|
));
|
|
@@ -900,40 +900,40 @@ function Vt(e, n = null) {
|
|
|
900
900
|
}
|
|
901
901
|
t({ schema: o, rows: a });
|
|
902
902
|
},
|
|
903
|
-
error: (
|
|
903
|
+
error: (r) => s(k("parseStructuralCSV", r))
|
|
904
904
|
});
|
|
905
905
|
});
|
|
906
906
|
}
|
|
907
|
-
function
|
|
907
|
+
function Vt(e) {
|
|
908
908
|
return new Promise((n) => {
|
|
909
909
|
J.parse(e, {
|
|
910
910
|
header: !0,
|
|
911
911
|
dynamicTyping: !0,
|
|
912
912
|
skipEmptyLines: !0,
|
|
913
913
|
complete: (t) => {
|
|
914
|
-
const
|
|
914
|
+
const s = /* @__PURE__ */ new Map();
|
|
915
915
|
for (const i of t.data) {
|
|
916
916
|
const o = ie(i), a = o[_] != null ? `${o[_]}`.trim() : "";
|
|
917
917
|
if (!a) continue;
|
|
918
|
-
const l = Number(o[
|
|
918
|
+
const l = Number(o[C]), u = Number(o[M]);
|
|
919
919
|
if (!Number.isFinite(l) || !Number.isFinite(u) || u <= l) continue;
|
|
920
920
|
const c = (l + u) / 2, { [Y]: m, [j]: d, ...f } = o, g = {
|
|
921
921
|
...f,
|
|
922
922
|
[_]: a,
|
|
923
|
-
[
|
|
924
|
-
[
|
|
925
|
-
[
|
|
926
|
-
[
|
|
923
|
+
[C]: l,
|
|
924
|
+
[M]: u,
|
|
925
|
+
[Ee]: c,
|
|
926
|
+
[G]: c,
|
|
927
927
|
// unified depth field for y-axis rendering
|
|
928
928
|
_source: "assay"
|
|
929
929
|
};
|
|
930
|
-
|
|
930
|
+
s.has(a) || s.set(a, []), s.get(a).push(g);
|
|
931
931
|
}
|
|
932
|
-
const
|
|
932
|
+
const r = Array.from(s.entries()).map(([i, o]) => ({
|
|
933
933
|
holeId: i,
|
|
934
|
-
points: o.sort((a, l) => a[
|
|
934
|
+
points: o.sort((a, l) => a[C] - l[C])
|
|
935
935
|
}));
|
|
936
|
-
n(
|
|
936
|
+
n(r);
|
|
937
937
|
}
|
|
938
938
|
});
|
|
939
939
|
});
|
|
@@ -945,42 +945,42 @@ function jt(e) {
|
|
|
945
945
|
dynamicTyping: !0,
|
|
946
946
|
skipEmptyLines: !0,
|
|
947
947
|
complete: (t) => {
|
|
948
|
-
const
|
|
949
|
-
for (const
|
|
950
|
-
const i = ie(
|
|
948
|
+
const s = /* @__PURE__ */ new Map();
|
|
949
|
+
for (const r of t.data) {
|
|
950
|
+
const i = ie(r), o = (i[_] ?? "").toString().trim();
|
|
951
951
|
if (!o) continue;
|
|
952
|
-
const a = Number(i[
|
|
952
|
+
const a = Number(i[C]), l = Number(i[M]);
|
|
953
953
|
if (!Number.isFinite(a) || !Number.isFinite(l) || l <= a) continue;
|
|
954
954
|
const u = (a + l) / 2, { [Y]: c, [j]: m, ...d } = i, f = {
|
|
955
955
|
...d,
|
|
956
956
|
[_]: o,
|
|
957
|
-
[
|
|
958
|
-
[
|
|
959
|
-
[
|
|
960
|
-
[
|
|
957
|
+
[C]: a,
|
|
958
|
+
[M]: l,
|
|
959
|
+
[Ee]: u,
|
|
960
|
+
[G]: u,
|
|
961
961
|
_source: "geology"
|
|
962
962
|
};
|
|
963
|
-
|
|
963
|
+
s.has(o) || s.set(o, []), s.get(o).push(f);
|
|
964
964
|
}
|
|
965
965
|
n({
|
|
966
|
-
holes: Array.from(
|
|
967
|
-
holeId:
|
|
968
|
-
points: i.sort((o, a) => o[
|
|
966
|
+
holes: Array.from(s.entries()).map(([r, i]) => ({
|
|
967
|
+
holeId: r,
|
|
968
|
+
points: i.sort((o, a) => o[C] - a[C])
|
|
969
969
|
}))
|
|
970
970
|
});
|
|
971
971
|
}
|
|
972
972
|
});
|
|
973
973
|
});
|
|
974
974
|
}
|
|
975
|
-
async function
|
|
976
|
-
const [
|
|
977
|
-
e ?
|
|
978
|
-
n ?
|
|
979
|
-
({ rows: a }) =>
|
|
975
|
+
async function Bn({ assayCsv: e, structuralCsv: n, geologyCsv: t } = {}) {
|
|
976
|
+
const [s, r, i] = await Promise.all([
|
|
977
|
+
e ? Vt(e) : Promise.resolve([]),
|
|
978
|
+
n ? Gt(n).then(
|
|
979
|
+
({ rows: a }) => Bt(a.map((l) => ({ ...l, _source: "structural" })))
|
|
980
980
|
) : Promise.resolve([]),
|
|
981
981
|
t ? jt(t).then(({ holes: a }) => a) : Promise.resolve([])
|
|
982
|
-
]), o = new Map(
|
|
983
|
-
for (const a of [...
|
|
982
|
+
]), o = new Map(s.map((a) => [a.holeId, { ...a, points: [...a.points] }]));
|
|
983
|
+
for (const a of [...r, ...i]) {
|
|
984
984
|
const l = a.holeId;
|
|
985
985
|
if (l)
|
|
986
986
|
if (o.has(l)) {
|
|
@@ -991,8 +991,8 @@ async function Gn({ assayCsv: e, structuralCsv: n, geologyCsv: t } = {}) {
|
|
|
991
991
|
}
|
|
992
992
|
return { holes: Array.from(o.values()) };
|
|
993
993
|
}
|
|
994
|
-
function
|
|
995
|
-
const i =
|
|
994
|
+
function Gn(e, n, t, s, r = {}) {
|
|
995
|
+
const i = r.fromCol || "from", o = r.toCol || "to", a = r.holeCol || "hole_id";
|
|
996
996
|
if (!e || !e.length) return [];
|
|
997
997
|
const l = {};
|
|
998
998
|
for (const c of e) {
|
|
@@ -1001,36 +1001,36 @@ function Vn(e, n, t, r, s = {}) {
|
|
|
1001
1001
|
}
|
|
1002
1002
|
const u = [];
|
|
1003
1003
|
for (const [c, m] of Object.entries(l)) {
|
|
1004
|
-
const f = [...m].sort((h,
|
|
1005
|
-
const
|
|
1006
|
-
return Number.isFinite(
|
|
1004
|
+
const f = [...m].sort((h, E) => Number(h[i]) - Number(E[i])).filter((h) => {
|
|
1005
|
+
const E = Number(h[n]);
|
|
1006
|
+
return Number.isFinite(E) && E >= t;
|
|
1007
1007
|
});
|
|
1008
1008
|
if (!f.length) continue;
|
|
1009
1009
|
const g = [];
|
|
1010
1010
|
let y = [], b = null;
|
|
1011
1011
|
for (const h of f) {
|
|
1012
|
-
const
|
|
1013
|
-
b === null || Math.abs(
|
|
1012
|
+
const E = Number(h[i]), A = Number(h[o]);
|
|
1013
|
+
b === null || Math.abs(E - b) > 1e-6 ? (y.length && g.push(y), y = [h]) : y.push(h), b = A;
|
|
1014
1014
|
}
|
|
1015
1015
|
y.length && g.push(y);
|
|
1016
1016
|
for (const h of g) {
|
|
1017
|
-
const
|
|
1018
|
-
if (
|
|
1019
|
-
let
|
|
1017
|
+
const E = Number(h[0][i]), A = Number(h[h.length - 1][o]), x = A - E;
|
|
1018
|
+
if (x < s) continue;
|
|
1019
|
+
let H = 0, O = 0;
|
|
1020
1020
|
for (const p of h) {
|
|
1021
|
-
const
|
|
1022
|
-
|
|
1021
|
+
const T = Number(p[n]), I = Number(p[o]) - Number(p[i]);
|
|
1022
|
+
H += T * I, O += I;
|
|
1023
1023
|
}
|
|
1024
|
-
const P =
|
|
1024
|
+
const P = H / O, R = h.length, V = `${x.toFixed(1)} m @ ${P.toFixed(2)} ${n}`;
|
|
1025
1025
|
u.push({
|
|
1026
1026
|
[a]: c,
|
|
1027
1027
|
assay_field: n,
|
|
1028
|
-
[i]:
|
|
1029
|
-
[o]:
|
|
1030
|
-
length:
|
|
1028
|
+
[i]: E,
|
|
1029
|
+
[o]: A,
|
|
1030
|
+
length: x,
|
|
1031
1031
|
avg_grade: P,
|
|
1032
|
-
n_samples:
|
|
1033
|
-
label:
|
|
1032
|
+
n_samples: R,
|
|
1033
|
+
label: V
|
|
1034
1034
|
});
|
|
1035
1035
|
}
|
|
1036
1036
|
}
|
|
@@ -1038,39 +1038,39 @@ function Vn(e, n, t, r, s = {}) {
|
|
|
1038
1038
|
}
|
|
1039
1039
|
const at = ["depth", "md", "measured_depth", "dept", "z"];
|
|
1040
1040
|
function Yt(e) {
|
|
1041
|
-
if (e[
|
|
1042
|
-
const
|
|
1043
|
-
if (Number.isFinite(
|
|
1041
|
+
if (e[G] !== void 0) {
|
|
1042
|
+
const s = Number(e[G]);
|
|
1043
|
+
if (Number.isFinite(s)) return s;
|
|
1044
1044
|
}
|
|
1045
|
-
for (const
|
|
1046
|
-
if (e[
|
|
1047
|
-
const
|
|
1048
|
-
if (Number.isFinite(
|
|
1045
|
+
for (const s of at)
|
|
1046
|
+
if (e[s] !== void 0) {
|
|
1047
|
+
const r = Number(e[s]);
|
|
1048
|
+
if (Number.isFinite(r)) return r;
|
|
1049
1049
|
}
|
|
1050
|
-
const n = Number(e[
|
|
1050
|
+
const n = Number(e[C]), t = Number(e[M]);
|
|
1051
1051
|
return Number.isFinite(n) && Number.isFinite(t) && t >= n ? (n + t) / 2 : null;
|
|
1052
1052
|
}
|
|
1053
1053
|
function Wt(e) {
|
|
1054
1054
|
if (e.length === 0) return [];
|
|
1055
|
-
const n = /* @__PURE__ */ new Set([_,
|
|
1056
|
-
return Object.keys(e[0]).filter((
|
|
1057
|
-
let
|
|
1055
|
+
const n = /* @__PURE__ */ new Set([_, G, C, M, Ee, ...at]);
|
|
1056
|
+
return Object.keys(e[0]).filter((s) => !n.has(s)).filter((s) => {
|
|
1057
|
+
let r = 0;
|
|
1058
1058
|
for (const i of e) {
|
|
1059
|
-
const o = Number(i[
|
|
1060
|
-
Number.isFinite(o) &&
|
|
1059
|
+
const o = Number(i[s]);
|
|
1060
|
+
Number.isFinite(o) && r++;
|
|
1061
1061
|
}
|
|
1062
|
-
return
|
|
1062
|
+
return r / e.length > 0.5;
|
|
1063
1063
|
});
|
|
1064
1064
|
}
|
|
1065
|
-
function
|
|
1066
|
-
const
|
|
1065
|
+
function Vn(e, n = null) {
|
|
1066
|
+
const s = J.parse(e, {
|
|
1067
1067
|
header: !0,
|
|
1068
1068
|
skipEmptyLines: !0,
|
|
1069
1069
|
dynamicTyping: !1
|
|
1070
1070
|
}).data || [];
|
|
1071
|
-
if (
|
|
1072
|
-
const
|
|
1073
|
-
for (const l of
|
|
1071
|
+
if (s.length === 0) return [];
|
|
1072
|
+
const r = s.map((l) => ie(l, null, n)), i = Wt(r), o = /* @__PURE__ */ new Map();
|
|
1073
|
+
for (const l of r) {
|
|
1074
1074
|
const u = l[_] != null ? `${l[_]}`.trim() : "";
|
|
1075
1075
|
if (!u) continue;
|
|
1076
1076
|
const c = Yt(l);
|
|
@@ -1093,82 +1093,82 @@ function Un(e, n = null) {
|
|
|
1093
1093
|
return a;
|
|
1094
1094
|
}
|
|
1095
1095
|
function jn(e, n = null, t = {}) {
|
|
1096
|
-
const
|
|
1097
|
-
for (const { holeId:
|
|
1096
|
+
const s = [];
|
|
1097
|
+
for (const { holeId: r, channels: i } of e) {
|
|
1098
1098
|
const o = n && i[n] ? n : Object.keys(i)[0];
|
|
1099
1099
|
if (!o) continue;
|
|
1100
1100
|
const { depths: a, values: l } = i[o];
|
|
1101
|
-
|
|
1101
|
+
s.push({ holeId: r, depths: a, values: l, options: t });
|
|
1102
1102
|
}
|
|
1103
|
-
return
|
|
1103
|
+
return s;
|
|
1104
1104
|
}
|
|
1105
1105
|
function lt(e) {
|
|
1106
1106
|
const n = e.indexOf(".");
|
|
1107
1107
|
if (n < 0) return null;
|
|
1108
|
-
const t = e.slice(0, n).trim().toUpperCase(),
|
|
1108
|
+
const t = e.slice(0, n).trim().toUpperCase(), s = e.slice(n + 1), r = s.match(/^(\S*)\s*(.*)/s), i = r ? r[1] : "", o = r ? r[2] : s, a = o.lastIndexOf(":"), l = a >= 0 ? o.slice(0, a).trim() : o.trim(), u = a >= 0 ? o.slice(a + 1).trim() : "";
|
|
1109
1109
|
return { mnem: t, unit: i, value: l, description: u };
|
|
1110
1110
|
}
|
|
1111
1111
|
function qt(e) {
|
|
1112
1112
|
const n = [];
|
|
1113
1113
|
let t = null;
|
|
1114
|
-
for (const
|
|
1115
|
-
const
|
|
1116
|
-
|
|
1114
|
+
for (const s of e.split(/\r?\n/)) {
|
|
1115
|
+
const r = s.trimEnd();
|
|
1116
|
+
r.startsWith("~") ? (t = { type: r.slice(1, 2).toUpperCase(), lines: [] }, n.push(t)) : t && t.lines.push(r);
|
|
1117
1117
|
}
|
|
1118
1118
|
return n;
|
|
1119
1119
|
}
|
|
1120
1120
|
function We(e = []) {
|
|
1121
1121
|
const n = {};
|
|
1122
1122
|
for (const t of e) {
|
|
1123
|
-
const
|
|
1124
|
-
if (!
|
|
1125
|
-
const
|
|
1126
|
-
|
|
1123
|
+
const s = t.trimStart();
|
|
1124
|
+
if (!s || s.startsWith("#")) continue;
|
|
1125
|
+
const r = lt(t);
|
|
1126
|
+
r && (n[r.mnem] = r);
|
|
1127
1127
|
}
|
|
1128
1128
|
return n;
|
|
1129
1129
|
}
|
|
1130
1130
|
function Yn(e, n = {}) {
|
|
1131
|
-
var h,
|
|
1132
|
-
const t = qt(e),
|
|
1131
|
+
var h, E, A, x, H, O, P, R, V;
|
|
1132
|
+
const t = qt(e), s = t.find((p) => p.type === "V"), r = t.find((p) => p.type === "W"), i = t.find((p) => p.type === "C"), o = t.find((p) => p.type === "A");
|
|
1133
1133
|
if (!o) return [];
|
|
1134
|
-
const a = We(
|
|
1134
|
+
const a = We(s == null ? void 0 : s.lines), l = We(r == null ? void 0 : r.lines), u = [];
|
|
1135
1135
|
for (const p of (i == null ? void 0 : i.lines) ?? []) {
|
|
1136
|
-
const
|
|
1137
|
-
if (!
|
|
1138
|
-
const
|
|
1139
|
-
|
|
1136
|
+
const T = p.trimStart();
|
|
1137
|
+
if (!T || T.startsWith("#")) continue;
|
|
1138
|
+
const I = lt(p);
|
|
1139
|
+
I && u.push(I);
|
|
1140
1140
|
}
|
|
1141
|
-
(((
|
|
1141
|
+
(((E = (h = a.WRAP) == null ? void 0 : h.value) == null ? void 0 : E.trim().toUpperCase()) ?? "NO") === "YES" && console.warn(
|
|
1142
1142
|
"parseLasFile: WRAP YES is not supported. Data rows may be read incorrectly."
|
|
1143
1143
|
);
|
|
1144
|
-
const m = n.holeId ?? (((
|
|
1144
|
+
const m = n.holeId ?? (((x = (A = l.WELL) == null ? void 0 : A.value) == null ? void 0 : x.trim()) || null) ?? (((O = (H = l.UWI) == null ? void 0 : H.value) == null ? void 0 : O.trim()) || null) ?? (((R = (P = l.API) == null ? void 0 : P.value) == null ? void 0 : R.trim()) || null) ?? "unknown";
|
|
1145
1145
|
let d = Qe;
|
|
1146
|
-
if ((
|
|
1146
|
+
if ((V = l.NULL) != null && V.value) {
|
|
1147
1147
|
const p = Number(l.NULL.value);
|
|
1148
1148
|
Number.isFinite(p) && (d = p);
|
|
1149
1149
|
}
|
|
1150
1150
|
if (n.nullSentinel !== void 0 && (d = n.nullSentinel), u.length === 0) return [];
|
|
1151
1151
|
const f = u.slice(1), g = {};
|
|
1152
|
-
for (const { mnem: p, unit:
|
|
1153
|
-
g[p.toLowerCase()] =
|
|
1152
|
+
for (const { mnem: p, unit: T } of f)
|
|
1153
|
+
g[p.toLowerCase()] = T;
|
|
1154
1154
|
const y = {};
|
|
1155
1155
|
for (const { mnem: p } of f)
|
|
1156
1156
|
y[p.toLowerCase()] = { depths: [], values: [] };
|
|
1157
1157
|
for (const p of o.lines) {
|
|
1158
|
-
const
|
|
1159
|
-
if (!
|
|
1160
|
-
const
|
|
1161
|
-
if (
|
|
1162
|
-
const
|
|
1163
|
-
if (!(!Number.isFinite(
|
|
1158
|
+
const T = p.trimStart();
|
|
1159
|
+
if (!T || T.startsWith("#")) continue;
|
|
1160
|
+
const I = T.split(/\s+/);
|
|
1161
|
+
if (I.length < 2) continue;
|
|
1162
|
+
const z = Number(I[0]);
|
|
1163
|
+
if (!(!Number.isFinite(z) || z === d))
|
|
1164
1164
|
for (let w = 0; w < f.length; w++) {
|
|
1165
|
-
const
|
|
1166
|
-
Number.isFinite(N) && N !== d && (y[
|
|
1165
|
+
const v = f[w].mnem.toLowerCase(), N = Number(I[w + 1]);
|
|
1166
|
+
Number.isFinite(N) && N !== d && (y[v].depths.push(z), y[v].values.push(N));
|
|
1167
1167
|
}
|
|
1168
1168
|
}
|
|
1169
1169
|
const b = {};
|
|
1170
|
-
for (const [p,
|
|
1171
|
-
|
|
1170
|
+
for (const [p, T] of Object.entries(y))
|
|
1171
|
+
T.depths.length >= 2 && (b[p] = T);
|
|
1172
1172
|
return Object.keys(b).length === 0 ? [] : [{ holeId: m, units: g, channels: b }];
|
|
1173
1173
|
}
|
|
1174
1174
|
const ct = [
|
|
@@ -1223,35 +1223,35 @@ function ut(e = {}) {
|
|
|
1223
1223
|
function Xt(e, {
|
|
1224
1224
|
tailScale: n = 5,
|
|
1225
1225
|
colorBy: t = null,
|
|
1226
|
-
palette:
|
|
1227
|
-
depthCol:
|
|
1226
|
+
palette: s = ct,
|
|
1227
|
+
depthCol: r = G,
|
|
1228
1228
|
dipCol: i = Y,
|
|
1229
1229
|
azCol: o = j,
|
|
1230
1230
|
template: a = void 0
|
|
1231
1231
|
} = {}) {
|
|
1232
1232
|
const l = e.filter(
|
|
1233
|
-
(y) => y[
|
|
1233
|
+
(y) => y[r] != null && y[i] != null && y[o] != null
|
|
1234
1234
|
);
|
|
1235
1235
|
if (!l.length)
|
|
1236
1236
|
return { data: [], layout: {} };
|
|
1237
1237
|
const u = {};
|
|
1238
1238
|
t && [...new Set(l.map((b) => b[t]).filter((b) => b != null))].sort().forEach((b, h) => {
|
|
1239
|
-
u[b] =
|
|
1239
|
+
u[b] = s[h % s.length];
|
|
1240
1240
|
});
|
|
1241
1241
|
const c = /* @__PURE__ */ new Map(), m = [];
|
|
1242
1242
|
for (const y of l) {
|
|
1243
|
-
const b = Number(y[
|
|
1244
|
-
c.has(
|
|
1245
|
-
const
|
|
1246
|
-
|
|
1247
|
-
const O =
|
|
1243
|
+
const b = Number(y[r]), h = Number(y[i]), E = Number(y[o]), A = t ? y[t] ?? "_default" : "_default", x = t ? u[A] ?? "#0f172a" : "#0f172a";
|
|
1244
|
+
c.has(A) || c.set(A, { xs: [], ys: [], dips: [], azs: [], color: x });
|
|
1245
|
+
const H = c.get(A);
|
|
1246
|
+
H.xs.push(h), H.ys.push(b), H.dips.push(h), H.azs.push(E);
|
|
1247
|
+
const O = E * Math.PI / 180, P = n * (Math.abs(h) / 90), R = Math.sin(O) * P, V = Math.cos(O) * P;
|
|
1248
1248
|
m.push({
|
|
1249
1249
|
type: "line",
|
|
1250
1250
|
x0: h,
|
|
1251
1251
|
y0: b,
|
|
1252
|
-
x1: h +
|
|
1253
|
-
y1: b +
|
|
1254
|
-
line: { color:
|
|
1252
|
+
x1: h + R,
|
|
1253
|
+
y1: b + V,
|
|
1254
|
+
line: { color: x, width: 2 }
|
|
1255
1255
|
});
|
|
1256
1256
|
}
|
|
1257
1257
|
const d = [], f = t && c.size > 1;
|
|
@@ -1264,7 +1264,7 @@ function Xt(e, {
|
|
|
1264
1264
|
name: y !== "_default" ? String(y) : void 0,
|
|
1265
1265
|
marker: { size: 8, color: b.color },
|
|
1266
1266
|
showlegend: f && y !== "_default",
|
|
1267
|
-
customdata: b.dips.map((h,
|
|
1267
|
+
customdata: b.dips.map((h, E) => [h, b.azs[E]]),
|
|
1268
1268
|
hovertemplate: "Depth: %{y}<br>Dip: %{customdata[0]}<br>Az: %{customdata[1]}<extra></extra>"
|
|
1269
1269
|
});
|
|
1270
1270
|
return { data: d, layout: {
|
|
@@ -1280,22 +1280,22 @@ function Xt(e, {
|
|
|
1280
1280
|
},
|
|
1281
1281
|
yaxis: { title: "Depth (m)", autorange: "reversed" },
|
|
1282
1282
|
showlegend: !!f,
|
|
1283
|
-
template: a !== void 0 ? a :
|
|
1283
|
+
template: a !== void 0 ? a : $e
|
|
1284
1284
|
} };
|
|
1285
1285
|
}
|
|
1286
1286
|
function Wn(e, {
|
|
1287
1287
|
labelCol: n = "structure_type",
|
|
1288
1288
|
palette: t = ct,
|
|
1289
|
-
fromCol:
|
|
1290
|
-
toCol:
|
|
1289
|
+
fromCol: s = C,
|
|
1290
|
+
toCol: r = M,
|
|
1291
1291
|
template: i = void 0
|
|
1292
1292
|
} = {}) {
|
|
1293
|
-
const o = e.filter((d) => d[
|
|
1293
|
+
const o = e.filter((d) => d[s] != null && d[r] != null && Number(d[r]) > Number(d[s])).filter((d) => {
|
|
1294
1294
|
const f = d[n];
|
|
1295
1295
|
if (f == null) return !1;
|
|
1296
1296
|
const g = String(f).trim();
|
|
1297
1297
|
return g !== "" && !/^(nan|null|none)$/i.test(g);
|
|
1298
|
-
}).map((d) => ({ from: Number(d[
|
|
1298
|
+
}).map((d) => ({ from: Number(d[s]), to: Number(d[r]), label: String(d[n]).trim() })).sort((d, f) => d.from - f.from);
|
|
1299
1299
|
if (!o.length)
|
|
1300
1300
|
return { data: [], layout: {} };
|
|
1301
1301
|
const a = [], l = [], u = [];
|
|
@@ -1327,36 +1327,36 @@ function Wn(e, {
|
|
|
1327
1327
|
xaxis: { range: [0, 1], visible: !1, fixedrange: !0 },
|
|
1328
1328
|
yaxis: { title: "Depth (m)", autorange: "reversed" },
|
|
1329
1329
|
showlegend: !1,
|
|
1330
|
-
template: i !== void 0 ? i :
|
|
1330
|
+
template: i !== void 0 ? i : $e
|
|
1331
1331
|
}) };
|
|
1332
1332
|
}
|
|
1333
1333
|
function Xe(e, n) {
|
|
1334
1334
|
if (!e) return "";
|
|
1335
|
-
const t = String(e).trim().split(/\s+/),
|
|
1336
|
-
let
|
|
1335
|
+
const t = String(e).trim().split(/\s+/), s = [];
|
|
1336
|
+
let r = "";
|
|
1337
1337
|
for (const i of t)
|
|
1338
|
-
|
|
1339
|
-
return
|
|
1338
|
+
r && r.length + 1 + i.length > n ? (s.push(r), r = i) : r = r ? `${r} ${i}` : i;
|
|
1339
|
+
return r && s.push(r), s.join("<br>");
|
|
1340
1340
|
}
|
|
1341
1341
|
function Zt(e, {
|
|
1342
1342
|
commentCol: n = "comments",
|
|
1343
|
-
fromCol: t =
|
|
1344
|
-
toCol:
|
|
1345
|
-
bgColor:
|
|
1343
|
+
fromCol: t = C,
|
|
1344
|
+
toCol: s = M,
|
|
1345
|
+
bgColor: r = "#f1f5f9",
|
|
1346
1346
|
borderColor: i = "#cbd5e1",
|
|
1347
1347
|
textColor: o = "#1e293b",
|
|
1348
1348
|
charsPerLine: a = 18,
|
|
1349
1349
|
template: l = void 0
|
|
1350
1350
|
} = {}) {
|
|
1351
|
-
const u = e.filter((h) => h[t] != null && h[
|
|
1352
|
-
const
|
|
1353
|
-
return { from: Number(h[t]), to: Number(h[
|
|
1354
|
-
}).sort((h,
|
|
1351
|
+
const u = e.filter((h) => h[t] != null && h[s] != null && Number(h[s]) > Number(h[t])).map((h) => {
|
|
1352
|
+
const E = h[n], A = E != null && String(E).trim() !== "" && String(E) !== "null" ? String(E).trim() : "";
|
|
1353
|
+
return { from: Number(h[t]), to: Number(h[s]), comment: A };
|
|
1354
|
+
}).sort((h, E) => h.from - E.from);
|
|
1355
1355
|
if (!u.length)
|
|
1356
1356
|
return { data: [], layout: {} };
|
|
1357
1357
|
const c = [], m = [], d = [], f = [], g = [];
|
|
1358
1358
|
for (const h of u) {
|
|
1359
|
-
const
|
|
1359
|
+
const E = 0.5 * (h.from + h.to), A = !!h.comment;
|
|
1360
1360
|
c.push({
|
|
1361
1361
|
type: "rect",
|
|
1362
1362
|
xref: "x",
|
|
@@ -1365,10 +1365,10 @@ function Zt(e, {
|
|
|
1365
1365
|
x1: 1,
|
|
1366
1366
|
y0: h.from,
|
|
1367
1367
|
y1: h.to,
|
|
1368
|
-
fillcolor:
|
|
1368
|
+
fillcolor: A ? r : "rgba(0,0,0,0)",
|
|
1369
1369
|
line: { color: i, width: 1 },
|
|
1370
1370
|
layer: "below"
|
|
1371
|
-
}),
|
|
1371
|
+
}), A && (m.push(0.5), d.push(E), f.push(Xe(h.comment, a)), g.push(`${h.from.toFixed(3)}–${h.to.toFixed(3)} m<br>${Xe(h.comment, 40)}`));
|
|
1372
1372
|
}
|
|
1373
1373
|
return { data: m.length ? [{
|
|
1374
1374
|
type: "scatter",
|
|
@@ -1387,48 +1387,48 @@ function Zt(e, {
|
|
|
1387
1387
|
xaxis: { range: [0, 1], visible: !1, fixedrange: !0 },
|
|
1388
1388
|
yaxis: { title: "Depth (m)", autorange: "reversed" },
|
|
1389
1389
|
showlegend: !1,
|
|
1390
|
-
template: l !== void 0 ? l :
|
|
1390
|
+
template: l !== void 0 ? l : $e
|
|
1391
1391
|
}) };
|
|
1392
1392
|
}
|
|
1393
1393
|
function qn(e, {
|
|
1394
1394
|
symbolSize: n = 10,
|
|
1395
1395
|
xCol: t = "easting",
|
|
1396
|
-
yCol:
|
|
1396
|
+
yCol: s = "northing"
|
|
1397
1397
|
} = {}) {
|
|
1398
|
-
const
|
|
1399
|
-
if (
|
|
1398
|
+
const r = e[t] != null ? Number(e[t]) : null, i = e[s] != null ? Number(e[s]) : null, o = e[Y] != null ? Number(e[Y]) : null, a = e[j] != null ? Number(e[j]) : null;
|
|
1399
|
+
if (r === null || i === null || o === null || a === null) return null;
|
|
1400
1400
|
const l = (a - 90 + 360) % 360, u = l * Math.PI / 180, c = a * Math.PI / 180, m = n * Math.sin(u), d = n * Math.cos(u), f = n * 0.4 * (o / 90), g = f * Math.sin(c), y = f * Math.cos(c);
|
|
1401
1401
|
return {
|
|
1402
1402
|
strike: l,
|
|
1403
1403
|
dipValue: o,
|
|
1404
|
-
x:
|
|
1404
|
+
x: r,
|
|
1405
1405
|
y: i,
|
|
1406
|
-
strikeX0:
|
|
1406
|
+
strikeX0: r - m,
|
|
1407
1407
|
strikeY0: i - d,
|
|
1408
|
-
strikeX1:
|
|
1408
|
+
strikeX1: r + m,
|
|
1409
1409
|
strikeY1: i + d,
|
|
1410
|
-
tickX1:
|
|
1410
|
+
tickX1: r + g,
|
|
1411
1411
|
tickY1: i + y
|
|
1412
1412
|
};
|
|
1413
1413
|
}
|
|
1414
1414
|
const dt = "markers+line";
|
|
1415
1415
|
function Jt(e, n) {
|
|
1416
|
-
var
|
|
1416
|
+
var s;
|
|
1417
1417
|
const t = et(e);
|
|
1418
|
-
return t.some((
|
|
1418
|
+
return t.some((r) => r.value === n) ? n : ((s = t[0]) == null ? void 0 : s.value) || dt;
|
|
1419
1419
|
}
|
|
1420
|
-
function Kn({ config: e, graph: n, holeOptions: t = [], propertyOptions:
|
|
1421
|
-
const o = _e(null), a = n == null ? void 0 : n.hole, l = (n == null ? void 0 : n.points) || [], u = (e == null ? void 0 : e.property) || "", c = (e == null ? void 0 : e.chartType) || dt, m = (e == null ? void 0 : e.holeId) || "", d = (n == null ? void 0 : n.displayType) || (n != null && n.isComment ? Pe : n != null && n.isCategorical ?
|
|
1420
|
+
function Kn({ config: e, graph: n, holeOptions: t = [], propertyOptions: s = [], onConfigChange: r, template: i }) {
|
|
1421
|
+
const o = _e(null), a = n == null ? void 0 : n.hole, l = (n == null ? void 0 : n.points) || [], u = (e == null ? void 0 : e.property) || "", c = (e == null ? void 0 : e.chartType) || dt, m = (e == null ? void 0 : e.holeId) || "", d = (n == null ? void 0 : n.displayType) || (n != null && n.isComment ? Pe : n != null && n.isCategorical ? Be : Nt), f = et(d), g = Jt(d, c), [y, b] = X("");
|
|
1422
1422
|
return ne(() => {
|
|
1423
|
-
const h = d === Pe,
|
|
1424
|
-
if (!a || !u || !h && !
|
|
1425
|
-
const
|
|
1426
|
-
if (!
|
|
1427
|
-
let
|
|
1423
|
+
const h = d === Pe, E = d === Ge;
|
|
1424
|
+
if (!a || !u || !h && !E && l.length === 0) return;
|
|
1425
|
+
const A = o.current;
|
|
1426
|
+
if (!A) return;
|
|
1427
|
+
let x;
|
|
1428
1428
|
try {
|
|
1429
|
-
h ?
|
|
1429
|
+
h ? x = Zt(l, { commentCol: u, fromCol: "from", toCol: "to" }) : E ? x = Xt(l) : x = Et({
|
|
1430
1430
|
points: l,
|
|
1431
|
-
isCategorical: d ===
|
|
1431
|
+
isCategorical: d === Be,
|
|
1432
1432
|
property: u,
|
|
1433
1433
|
chartType: g,
|
|
1434
1434
|
template: i
|
|
@@ -1437,25 +1437,25 @@ function Kn({ config: e, graph: n, holeOptions: t = [], propertyOptions: r = [],
|
|
|
1437
1437
|
console.error("Plot build error", O), b((O == null ? void 0 : O.message) || "Plot build error");
|
|
1438
1438
|
return;
|
|
1439
1439
|
}
|
|
1440
|
-
if ((!(
|
|
1440
|
+
if ((!(x != null && x.data) || x.data.length === 0) && !h)
|
|
1441
1441
|
return;
|
|
1442
|
-
const
|
|
1442
|
+
const H = {
|
|
1443
1443
|
displayModeBar: !0,
|
|
1444
1444
|
responsive: !0,
|
|
1445
1445
|
useResizeHandler: !0,
|
|
1446
1446
|
modeBarButtonsToRemove: ["select2d", "lasso2d", "autoScale2d"]
|
|
1447
1447
|
};
|
|
1448
1448
|
try {
|
|
1449
|
-
b(""),
|
|
1450
|
-
|
|
1449
|
+
b(""), Ae.react(A, x.data, x.layout, H), requestAnimationFrame(() => {
|
|
1450
|
+
A && A.parentElement && Ae.Plots.resize(A);
|
|
1451
1451
|
});
|
|
1452
1452
|
} catch (O) {
|
|
1453
1453
|
console.error("Plot render error", O), b((O == null ? void 0 : O.message) || "Plot render error");
|
|
1454
1454
|
}
|
|
1455
1455
|
return () => {
|
|
1456
|
-
if (
|
|
1456
|
+
if (A)
|
|
1457
1457
|
try {
|
|
1458
|
-
|
|
1458
|
+
Ae.purge(A);
|
|
1459
1459
|
} catch (O) {
|
|
1460
1460
|
console.warn("Plot purge error", O);
|
|
1461
1461
|
}
|
|
@@ -1463,237 +1463,237 @@ function Kn({ config: e, graph: n, holeOptions: t = [], propertyOptions: r = [],
|
|
|
1463
1463
|
}, [a, u, g, d, l, i]), ne(() => {
|
|
1464
1464
|
const h = o.current;
|
|
1465
1465
|
if (!h || typeof ResizeObserver > "u") return;
|
|
1466
|
-
const
|
|
1466
|
+
const E = new ResizeObserver(() => {
|
|
1467
1467
|
try {
|
|
1468
|
-
h && h.data &&
|
|
1469
|
-
} catch (
|
|
1470
|
-
console.warn("Plot resize error",
|
|
1468
|
+
h && h.data && Ae.Plots.resize(h);
|
|
1469
|
+
} catch (A) {
|
|
1470
|
+
console.warn("Plot resize error", A);
|
|
1471
1471
|
}
|
|
1472
1472
|
});
|
|
1473
|
-
return
|
|
1474
|
-
}, []), !a || !u ? /* @__PURE__ */
|
|
1473
|
+
return E.observe(h), () => E.disconnect();
|
|
1474
|
+
}, []), !a || !u ? /* @__PURE__ */ S("div", { className: "plot-card empty", children: /* @__PURE__ */ S("div", { className: "placeholder", children: e != null && e.holeId ? n != null && n.loading ? `Loading ${e.holeId}...` : "Select a property" : "Loading demo data..." }) }) : d !== Pe && d !== Ge && l.length === 0 ? /* @__PURE__ */ S("div", { className: "plot-card empty", children: /* @__PURE__ */ S("div", { className: "placeholder", children: "No data" }) }) : y ? /* @__PURE__ */ S("div", { className: "plot-card empty", children: /* @__PURE__ */ W("div", { className: "placeholder", children: [
|
|
1475
1475
|
"Plot error: ",
|
|
1476
1476
|
y
|
|
1477
1477
|
] }) }) : /* @__PURE__ */ W("div", { className: "plot-card", children: [
|
|
1478
|
-
/* @__PURE__ */
|
|
1478
|
+
/* @__PURE__ */ S("div", { className: "plot-title", children: /* @__PURE__ */ S(
|
|
1479
1479
|
"select",
|
|
1480
1480
|
{
|
|
1481
1481
|
className: "plot-select",
|
|
1482
1482
|
value: m,
|
|
1483
|
-
onChange: (h) =>
|
|
1483
|
+
onChange: (h) => r && r({ holeId: h.target.value }),
|
|
1484
1484
|
children: t.map((h) => {
|
|
1485
|
-
const
|
|
1486
|
-
return /* @__PURE__ */
|
|
1485
|
+
const E = typeof h == "string" ? h : h.holeId, A = typeof h == "string" ? h : h.label || h.holeId;
|
|
1486
|
+
return /* @__PURE__ */ S("option", { value: E, children: A }, E);
|
|
1487
1487
|
})
|
|
1488
1488
|
}
|
|
1489
1489
|
) }),
|
|
1490
1490
|
/* @__PURE__ */ W("div", { className: "plot-controls column", children: [
|
|
1491
|
-
|
|
1491
|
+
s.length > 0 && /* @__PURE__ */ S(
|
|
1492
1492
|
"select",
|
|
1493
1493
|
{
|
|
1494
1494
|
className: "plot-select",
|
|
1495
1495
|
value: u,
|
|
1496
|
-
onChange: (h) =>
|
|
1497
|
-
children:
|
|
1496
|
+
onChange: (h) => r && r({ property: h.target.value }),
|
|
1497
|
+
children: s.map((h) => /* @__PURE__ */ S("option", { value: h, children: h }, h))
|
|
1498
1498
|
}
|
|
1499
1499
|
),
|
|
1500
|
-
f.length > 1 && /* @__PURE__ */
|
|
1500
|
+
f.length > 1 && /* @__PURE__ */ S(
|
|
1501
1501
|
"select",
|
|
1502
1502
|
{
|
|
1503
1503
|
className: "plot-select",
|
|
1504
1504
|
value: g,
|
|
1505
|
-
onChange: (h) =>
|
|
1506
|
-
children: f.map((h) => /* @__PURE__ */
|
|
1505
|
+
onChange: (h) => r && r({ chartType: h.target.value }),
|
|
1506
|
+
children: f.map((h) => /* @__PURE__ */ S("option", { value: h.value, children: h.label }, h.value))
|
|
1507
1507
|
}
|
|
1508
1508
|
)
|
|
1509
1509
|
] }),
|
|
1510
|
-
/* @__PURE__ */
|
|
1510
|
+
/* @__PURE__ */ S("div", { className: "plotly-chart", ref: o })
|
|
1511
1511
|
] });
|
|
1512
1512
|
}
|
|
1513
1513
|
function Ze(e, n) {
|
|
1514
1514
|
if (!(n != null && n.length)) return e;
|
|
1515
|
-
const t = new Map(e.map((
|
|
1516
|
-
for (const
|
|
1517
|
-
const
|
|
1518
|
-
if (
|
|
1519
|
-
if (t.has(
|
|
1520
|
-
const i = t.get(
|
|
1521
|
-
t.set(
|
|
1515
|
+
const t = new Map(e.map((s) => [s.id || s.holeId, { ...s }]));
|
|
1516
|
+
for (const s of n) {
|
|
1517
|
+
const r = s.id || s.holeId;
|
|
1518
|
+
if (r)
|
|
1519
|
+
if (t.has(r)) {
|
|
1520
|
+
const i = t.get(r);
|
|
1521
|
+
t.set(r, { ...i, points: [...i.points || [], ...s.points || []] });
|
|
1522
1522
|
} else
|
|
1523
|
-
t.set(
|
|
1523
|
+
t.set(r, s);
|
|
1524
1524
|
}
|
|
1525
1525
|
return Array.from(t.values());
|
|
1526
1526
|
}
|
|
1527
1527
|
function Qt(e, n) {
|
|
1528
1528
|
if (!e || !n) return [];
|
|
1529
|
-
const t = /* @__PURE__ */ new Set(),
|
|
1530
|
-
for (const
|
|
1531
|
-
const i = Number(
|
|
1529
|
+
const t = /* @__PURE__ */ new Set(), s = [];
|
|
1530
|
+
for (const r of e.points || []) {
|
|
1531
|
+
const i = Number(r.from ?? r.samp_from ?? r.depth_from ?? r.from_depth), o = Number(r.to ?? r.samp_to ?? r.depth_to ?? r.to_depth);
|
|
1532
1532
|
if (!Number.isFinite(i) || !Number.isFinite(o) || o <= i) continue;
|
|
1533
1533
|
const a = `${i}-${o}`;
|
|
1534
|
-
t.has(a) || (t.add(a),
|
|
1534
|
+
t.has(a) || (t.add(a), s.push({ from: i, to: o, [n]: r[n] ?? "" }));
|
|
1535
1535
|
}
|
|
1536
|
-
return
|
|
1536
|
+
return s;
|
|
1537
1537
|
}
|
|
1538
1538
|
function Xn({
|
|
1539
1539
|
initialFocusedHoleId: e = "",
|
|
1540
1540
|
sourceFile: n = null,
|
|
1541
1541
|
extraHoles: t = [],
|
|
1542
|
-
plotCount:
|
|
1542
|
+
plotCount: s = 4
|
|
1543
1543
|
} = {}) {
|
|
1544
|
-
const [
|
|
1544
|
+
const [r, i] = X([]), [o, a] = X([]), [l, u] = X([]), [c, m] = X([]), [d, f] = X([]), [g, y] = X({}), [b, h] = X(""), [E, A] = X([]), [x, H] = X(""), [O, P] = X(e || ""), [R, V] = X([]), p = _e(null);
|
|
1545
1545
|
ne(() => {
|
|
1546
|
-
!n || p.current === n || (p.current = n, Pt(n).then((
|
|
1547
|
-
if (!
|
|
1548
|
-
const N = Array.from(new Map(
|
|
1549
|
-
a(N),
|
|
1550
|
-
holeIds: N.map((
|
|
1546
|
+
!n || p.current === n || (p.current = n, Pt(n).then((v) => {
|
|
1547
|
+
if (!v) return;
|
|
1548
|
+
const N = Array.from(new Map(v.map((D) => [D.holeId, D])).values());
|
|
1549
|
+
a(N), A(rt({
|
|
1550
|
+
holeIds: N.map((D) => D.holeId),
|
|
1551
1551
|
focusedHoleId: O,
|
|
1552
|
-
plotCount:
|
|
1552
|
+
plotCount: s,
|
|
1553
1553
|
defaultProp: "",
|
|
1554
1554
|
categoricalProps: c,
|
|
1555
1555
|
commentProps: d,
|
|
1556
1556
|
numericDefaultChartType: "markers+line"
|
|
1557
1557
|
}));
|
|
1558
|
-
}).catch((
|
|
1559
|
-
console.info("Assay metadata load skipped:",
|
|
1558
|
+
}).catch((v) => {
|
|
1559
|
+
console.info("Assay metadata load skipped:", v.message);
|
|
1560
1560
|
}));
|
|
1561
|
-
}, [n, O,
|
|
1561
|
+
}, [n, O, s, c, d]), ne(() => {
|
|
1562
1562
|
if (!(t != null && t.length)) return;
|
|
1563
|
-
const
|
|
1563
|
+
const v = t.map((N) => ({ holeId: N.id || N.holeId })).filter((N) => N.holeId);
|
|
1564
1564
|
a((N) => {
|
|
1565
|
-
const
|
|
1566
|
-
return
|
|
1565
|
+
const D = new Set(N.map((L) => L.holeId)), F = v.filter((L) => !D.has(L.holeId));
|
|
1566
|
+
return F.length ? [...N, ...F] : N;
|
|
1567
1567
|
});
|
|
1568
1568
|
}, [t]), ne(() => {
|
|
1569
|
-
|
|
1570
|
-
}, [
|
|
1569
|
+
H((v) => v && v.startsWith("Loading ") && v.includes(" for hole ") ? v : "");
|
|
1570
|
+
}, [E]), ne(() => {
|
|
1571
1571
|
if (!o.length) {
|
|
1572
|
-
|
|
1572
|
+
A([]);
|
|
1573
1573
|
return;
|
|
1574
1574
|
}
|
|
1575
|
-
const
|
|
1576
|
-
|
|
1575
|
+
const v = st(o.map((N) => N.holeId), O);
|
|
1576
|
+
A((N) => Array.from({ length: s }).map((F, L) => {
|
|
1577
1577
|
var K;
|
|
1578
|
-
const
|
|
1579
|
-
property:
|
|
1580
|
-
chartType:
|
|
1578
|
+
const U = N[L] || {}, B = o.some((ae) => ae.holeId === U.holeId) ? U.holeId : v[L] || ((K = o[L]) == null ? void 0 : K.holeId) || "", $ = U.property || b, q = Se({
|
|
1579
|
+
property: $,
|
|
1580
|
+
chartType: U.chartType,
|
|
1581
1581
|
categoricalProps: c,
|
|
1582
1582
|
commentProps: d,
|
|
1583
1583
|
numericDefaultChartType: "markers+line"
|
|
1584
1584
|
});
|
|
1585
|
-
return { holeId:
|
|
1585
|
+
return { holeId: B, property: $, chartType: q };
|
|
1586
1586
|
}));
|
|
1587
|
-
}, [o, O, b, c, d,
|
|
1587
|
+
}, [o, O, b, c, d, s]), ne(() => {
|
|
1588
1588
|
if (!n) return;
|
|
1589
|
-
|
|
1590
|
-
const
|
|
1591
|
-
|
|
1592
|
-
|
|
1593
|
-
const
|
|
1594
|
-
[...
|
|
1589
|
+
E.map((N) => N.holeId).filter(Boolean).forEach((N) => {
|
|
1590
|
+
const D = r.some((L) => (L.id || L.holeId) === N), F = R.includes(N);
|
|
1591
|
+
D || F || (V((L) => [...L, N]), Dt(n, N).then((L) => {
|
|
1592
|
+
V((U) => U.filter((B) => B !== N)), L && i((U) => {
|
|
1593
|
+
const B = Ze(
|
|
1594
|
+
[...U.filter((q) => (q.id || q.holeId) !== N), L],
|
|
1595
1595
|
t
|
|
1596
|
-
),
|
|
1597
|
-
return u(
|
|
1596
|
+
), $ = Le(B);
|
|
1597
|
+
return u($.numericProps), m($.categoricalProps), f($.commentProps), y($.columnMeta), !b && $.defaultProp && (h($.defaultProp), A((q) => q.map((K) => ({
|
|
1598
1598
|
...K,
|
|
1599
|
-
property: K.property ||
|
|
1600
|
-
chartType:
|
|
1601
|
-
property: K.property ||
|
|
1599
|
+
property: K.property || $.defaultProp,
|
|
1600
|
+
chartType: Se({
|
|
1601
|
+
property: K.property || $.defaultProp,
|
|
1602
1602
|
chartType: K.chartType,
|
|
1603
|
-
categoricalProps:
|
|
1604
|
-
commentProps:
|
|
1603
|
+
categoricalProps: $.categoricalProps,
|
|
1604
|
+
commentProps: $.commentProps,
|
|
1605
1605
|
numericDefaultChartType: "markers+line"
|
|
1606
1606
|
})
|
|
1607
|
-
})))),
|
|
1607
|
+
})))), B;
|
|
1608
1608
|
});
|
|
1609
1609
|
}).catch((L) => {
|
|
1610
|
-
console.error(L),
|
|
1610
|
+
console.error(L), V((U) => U.filter((B) => B !== N)), H(L.message || `Error loading hole ${N}`);
|
|
1611
1611
|
}));
|
|
1612
1612
|
});
|
|
1613
|
-
}, [
|
|
1614
|
-
t != null && t.length && i((
|
|
1615
|
-
if (!
|
|
1616
|
-
const
|
|
1617
|
-
return u(
|
|
1613
|
+
}, [E, n, r, R, b, t]), ne(() => {
|
|
1614
|
+
t != null && t.length && i((v) => {
|
|
1615
|
+
if (!v.length) {
|
|
1616
|
+
const F = Le(t);
|
|
1617
|
+
return u(F.numericProps), m(F.categoricalProps), f(F.commentProps), y(F.columnMeta), !b && F.defaultProp && h(F.defaultProp), t;
|
|
1618
1618
|
}
|
|
1619
|
-
const N = Ze(
|
|
1620
|
-
return u(
|
|
1619
|
+
const N = Ze(v, t), D = Le(N);
|
|
1620
|
+
return u(D.numericProps), m(D.categoricalProps), f(D.commentProps), y(D.columnMeta), !b && D.defaultProp && h(D.defaultProp), N;
|
|
1621
1621
|
});
|
|
1622
1622
|
}, [t]);
|
|
1623
|
-
const
|
|
1623
|
+
const T = ee(
|
|
1624
1624
|
() => [...l, ...c, ...d],
|
|
1625
1625
|
[l, c, d]
|
|
1626
|
-
),
|
|
1627
|
-
() => o.map((
|
|
1626
|
+
), I = ee(
|
|
1627
|
+
() => o.map((v) => ({ holeId: v.holeId, label: v.holeId })).sort((v, N) => v.label.localeCompare(N.label)),
|
|
1628
1628
|
[o]
|
|
1629
|
-
),
|
|
1630
|
-
const
|
|
1631
|
-
return Array.from({ length:
|
|
1632
|
-
const
|
|
1633
|
-
let
|
|
1634
|
-
L && !
|
|
1635
|
-
const
|
|
1629
|
+
), z = ee(() => {
|
|
1630
|
+
const v = [...l, ...c, ...d];
|
|
1631
|
+
return Array.from({ length: s }).map((N, D) => {
|
|
1632
|
+
const F = E[D] || {}, L = r.find((fe) => (fe.id || fe.holeId) === F.holeId) || null, U = L ? v.filter((fe) => At(L, fe)) : v;
|
|
1633
|
+
let B = F.property || b;
|
|
1634
|
+
L && !U.includes(B) && (B = U[0] || B);
|
|
1635
|
+
const $ = d.includes(B), q = !$ && c.includes(B), K = !$ && !q && B === "dip", ae = $ ? "comment" : K ? "tadpole" : q ? "categorical" : "numeric", be = K ? "tadpole" : F.chartType || ($ ? "comment" : q ? "categorical" : "markers+line"), me = F.holeId || (L == null ? void 0 : L.id) || (L == null ? void 0 : L.holeId) || "", Oe = K ? (L == null ? void 0 : L.points) || [] : $ ? Qt(L, B) : vt(L, B, q);
|
|
1636
1636
|
return {
|
|
1637
|
-
config: { holeId: me, property:
|
|
1637
|
+
config: { holeId: me, property: B, chartType: be },
|
|
1638
1638
|
hole: L,
|
|
1639
|
-
loading:
|
|
1639
|
+
loading: R.includes(F.holeId),
|
|
1640
1640
|
isCategorical: q,
|
|
1641
|
-
isComment:
|
|
1641
|
+
isComment: $,
|
|
1642
1642
|
isTadpole: K,
|
|
1643
1643
|
displayType: ae,
|
|
1644
1644
|
points: Oe,
|
|
1645
|
-
propertyOptions:
|
|
1645
|
+
propertyOptions: U,
|
|
1646
1646
|
label: me
|
|
1647
1647
|
};
|
|
1648
1648
|
});
|
|
1649
|
-
}, [
|
|
1650
|
-
|
|
1651
|
-
const
|
|
1652
|
-
return N.property && (
|
|
1649
|
+
}, [E, r, b, c, d, R, s, l]), w = (v, N) => {
|
|
1650
|
+
A((D) => {
|
|
1651
|
+
const F = [...D], U = { ...F[v] || {}, ...N };
|
|
1652
|
+
return N.property && (U.chartType = Se({
|
|
1653
1653
|
property: N.property,
|
|
1654
|
-
chartType:
|
|
1654
|
+
chartType: U.chartType,
|
|
1655
1655
|
categoricalProps: c,
|
|
1656
1656
|
commentProps: d,
|
|
1657
1657
|
numericDefaultChartType: "markers+line"
|
|
1658
|
-
})),
|
|
1658
|
+
})), F[v] = U, F;
|
|
1659
1659
|
});
|
|
1660
1660
|
};
|
|
1661
1661
|
return {
|
|
1662
|
-
error:
|
|
1662
|
+
error: x,
|
|
1663
1663
|
focusedHoleId: O,
|
|
1664
1664
|
setFocusedHoleId: P,
|
|
1665
|
-
setError:
|
|
1665
|
+
setError: H,
|
|
1666
1666
|
holeCount: o.length,
|
|
1667
1667
|
numericProps: l,
|
|
1668
1668
|
categoricalProps: c,
|
|
1669
1669
|
commentProps: d,
|
|
1670
1670
|
columnMeta: g,
|
|
1671
|
-
propertyOptions:
|
|
1672
|
-
labeledHoleOptions:
|
|
1673
|
-
traceGraphs:
|
|
1671
|
+
propertyOptions: T,
|
|
1672
|
+
labeledHoleOptions: I,
|
|
1673
|
+
traceGraphs: z,
|
|
1674
1674
|
handleConfigChange: w
|
|
1675
1675
|
};
|
|
1676
1676
|
}
|
|
1677
1677
|
function mt(e) {
|
|
1678
1678
|
return Array.isArray(e) ? e : [];
|
|
1679
1679
|
}
|
|
1680
|
-
function
|
|
1680
|
+
function Re(e) {
|
|
1681
1681
|
const n = Number(e);
|
|
1682
1682
|
return Number.isFinite(n) ? n : void 0;
|
|
1683
1683
|
}
|
|
1684
1684
|
function ft(e = {}) {
|
|
1685
1685
|
return {
|
|
1686
1686
|
...e,
|
|
1687
|
-
x:
|
|
1688
|
-
y:
|
|
1689
|
-
z:
|
|
1687
|
+
x: Re(e.x),
|
|
1688
|
+
y: Re(e.y),
|
|
1689
|
+
z: Re(e.z)
|
|
1690
1690
|
};
|
|
1691
1691
|
}
|
|
1692
1692
|
function en(e = [], n = [0, 0], t = 0) {
|
|
1693
|
-
const [
|
|
1693
|
+
const [s, r] = n, i = Number(t) * Math.PI / 180, o = Math.cos(i), a = Math.sin(i);
|
|
1694
1694
|
return mt(e).map(ft).map((l) => {
|
|
1695
1695
|
if (!Number.isFinite(l.x) || !Number.isFinite(l.y)) return { ...l };
|
|
1696
|
-
const u = l.x -
|
|
1696
|
+
const u = l.x - s, c = l.y - r;
|
|
1697
1697
|
return {
|
|
1698
1698
|
...l,
|
|
1699
1699
|
along: u * a + c * o,
|
|
@@ -1701,32 +1701,32 @@ function en(e = [], n = [0, 0], t = 0) {
|
|
|
1701
1701
|
};
|
|
1702
1702
|
});
|
|
1703
1703
|
}
|
|
1704
|
-
function tn(e = [], n = [0, 0], t = 0,
|
|
1705
|
-
const
|
|
1706
|
-
return !Number.isFinite(i) || i <= 0 ?
|
|
1704
|
+
function tn(e = [], n = [0, 0], t = 0, s = 50) {
|
|
1705
|
+
const r = en(e, n, t), i = 0.5 * Number(s || 0);
|
|
1706
|
+
return !Number.isFinite(i) || i <= 0 ? r : r.filter((o) => Number.isFinite(o.across) && Math.abs(o.across) <= i);
|
|
1707
1707
|
}
|
|
1708
1708
|
function Zn(e = [], n = null, t = null) {
|
|
1709
|
-
let
|
|
1709
|
+
let s = mt(e).map(ft);
|
|
1710
1710
|
if (Array.isArray(n) && n.length === 2) {
|
|
1711
|
-
const [
|
|
1712
|
-
|
|
1711
|
+
const [r, i] = n;
|
|
1712
|
+
s = s.filter((o) => Number.isFinite(o.z) && o.z <= Number(r) && o.z >= Number(i));
|
|
1713
1713
|
}
|
|
1714
|
-
return t && (
|
|
1715
|
-
...
|
|
1716
|
-
color_value:
|
|
1717
|
-
}))),
|
|
1718
|
-
}
|
|
1719
|
-
function Jn(e = [], n = [0, 0], t = 0,
|
|
1720
|
-
let i = tn(e, n, t,
|
|
1721
|
-
return
|
|
1714
|
+
return t && (s = s.map((r) => ({
|
|
1715
|
+
...r,
|
|
1716
|
+
color_value: r == null ? void 0 : r[t]
|
|
1717
|
+
}))), s;
|
|
1718
|
+
}
|
|
1719
|
+
function Jn(e = [], n = [0, 0], t = 0, s = 50, r = null) {
|
|
1720
|
+
let i = tn(e, n, t, s);
|
|
1721
|
+
return r && (i = i.map((o) => ({
|
|
1722
1722
|
...o,
|
|
1723
|
-
color_value: o == null ? void 0 : o[
|
|
1723
|
+
color_value: o == null ? void 0 : o[r]
|
|
1724
1724
|
}))), i;
|
|
1725
1725
|
}
|
|
1726
|
-
function
|
|
1726
|
+
function He(e) {
|
|
1727
1727
|
return Array.isArray(e) ? e : [];
|
|
1728
1728
|
}
|
|
1729
|
-
function
|
|
1729
|
+
function Ue(e = {}) {
|
|
1730
1730
|
return e.hole_id ?? e.holeId ?? e.id;
|
|
1731
1731
|
}
|
|
1732
1732
|
function ue(e, n = void 0) {
|
|
@@ -1735,62 +1735,62 @@ function ue(e, n = void 0) {
|
|
|
1735
1735
|
}
|
|
1736
1736
|
function Qn(e = [], n = null) {
|
|
1737
1737
|
const t = /* @__PURE__ */ new Map();
|
|
1738
|
-
|
|
1739
|
-
const i =
|
|
1738
|
+
He(e).forEach((r) => {
|
|
1739
|
+
const i = Ue(r);
|
|
1740
1740
|
if (i == null || `${i}`.trim() === "") return;
|
|
1741
1741
|
const o = `${i}`;
|
|
1742
|
-
t.has(o) || t.set(o, []), t.get(o).push(
|
|
1742
|
+
t.has(o) || t.set(o, []), t.get(o).push(r);
|
|
1743
1743
|
});
|
|
1744
|
-
const
|
|
1745
|
-
return t.forEach((
|
|
1746
|
-
const o = [...
|
|
1744
|
+
const s = [];
|
|
1745
|
+
return t.forEach((r, i) => {
|
|
1746
|
+
const o = [...r].sort((l, u) => ue(l.md, 0) - ue(u.md, 0)), a = {
|
|
1747
1747
|
hole_id: i,
|
|
1748
1748
|
x: o.map((l) => ue(l.x, 0)),
|
|
1749
1749
|
y: o.map((l) => ue(l.y, 0)),
|
|
1750
1750
|
z: o.map((l) => ue(l.z, 0)),
|
|
1751
1751
|
color: null
|
|
1752
1752
|
};
|
|
1753
|
-
n && (a.color = o.map((l) => l == null ? void 0 : l[n])),
|
|
1754
|
-
}),
|
|
1755
|
-
}
|
|
1756
|
-
function
|
|
1757
|
-
return
|
|
1758
|
-
hole_id:
|
|
1759
|
-
from:
|
|
1760
|
-
to:
|
|
1753
|
+
n && (a.color = o.map((l) => l == null ? void 0 : l[n])), s.push(a);
|
|
1754
|
+
}), s;
|
|
1755
|
+
}
|
|
1756
|
+
function es(e = [], n = 1, t = null) {
|
|
1757
|
+
return He(e).map((s) => ({
|
|
1758
|
+
hole_id: Ue(s),
|
|
1759
|
+
from: s == null ? void 0 : s.from,
|
|
1760
|
+
to: s == null ? void 0 : s.to,
|
|
1761
1761
|
radius: n,
|
|
1762
|
-
color: t ?
|
|
1763
|
-
value: t ?
|
|
1762
|
+
color: t ? s == null ? void 0 : s[t] : null,
|
|
1763
|
+
value: t ? s == null ? void 0 : s[t] : null
|
|
1764
1764
|
}));
|
|
1765
1765
|
}
|
|
1766
|
-
function
|
|
1767
|
-
return n ?
|
|
1768
|
-
hole_id:
|
|
1766
|
+
function ts(e = [], n = null) {
|
|
1767
|
+
return n ? He(e).filter((t) => Object.prototype.hasOwnProperty.call(t || {}, n)).map((t) => ({
|
|
1768
|
+
hole_id: Ue(t),
|
|
1769
1769
|
label: t == null ? void 0 : t[n],
|
|
1770
1770
|
depth: 0.5 * (ue(t == null ? void 0 : t.from, 0) + ue(t == null ? void 0 : t.to, 0))
|
|
1771
1771
|
})) : [];
|
|
1772
1772
|
}
|
|
1773
|
-
function
|
|
1773
|
+
function ns({
|
|
1774
1774
|
controlMode: e = "orbit",
|
|
1775
1775
|
onToggleFly: n = () => {
|
|
1776
1776
|
},
|
|
1777
1777
|
onRecenter: t = () => {
|
|
1778
1778
|
},
|
|
1779
|
-
onLookDown:
|
|
1779
|
+
onLookDown: s = () => {
|
|
1780
1780
|
},
|
|
1781
|
-
onFit:
|
|
1781
|
+
onFit: r = () => {
|
|
1782
1782
|
},
|
|
1783
1783
|
darkBackground: i = !1,
|
|
1784
1784
|
onToggleDarkBackground: o = () => {
|
|
1785
1785
|
}
|
|
1786
1786
|
}) {
|
|
1787
1787
|
return /* @__PURE__ */ W("div", { className: "baselode-3d-controls", children: [
|
|
1788
|
-
/* @__PURE__ */
|
|
1789
|
-
/* @__PURE__ */
|
|
1790
|
-
/* @__PURE__ */
|
|
1791
|
-
/* @__PURE__ */
|
|
1788
|
+
/* @__PURE__ */ S("button", { type: "button", className: "ghost-button", onClick: t, children: "Recenter to (0,0,0)" }),
|
|
1789
|
+
/* @__PURE__ */ S("button", { type: "button", className: "ghost-button", onClick: s, children: "Look down" }),
|
|
1790
|
+
/* @__PURE__ */ S("button", { type: "button", className: "ghost-button", onClick: r, children: "Fit to scene" }),
|
|
1791
|
+
/* @__PURE__ */ S("button", { type: "button", className: "ghost-button", onClick: n, children: e === "orbit" ? "Enable fly controls" : "Disable fly controls" }),
|
|
1792
1792
|
/* @__PURE__ */ W("label", { className: "baselode-3d-controls-checkbox", children: [
|
|
1793
|
-
/* @__PURE__ */
|
|
1793
|
+
/* @__PURE__ */ S(
|
|
1794
1794
|
"input",
|
|
1795
1795
|
{
|
|
1796
1796
|
type: "checkbox",
|
|
@@ -1802,13 +1802,13 @@ function nr({
|
|
|
1802
1802
|
] })
|
|
1803
1803
|
] });
|
|
1804
1804
|
}
|
|
1805
|
-
function
|
|
1805
|
+
function ss({
|
|
1806
1806
|
properties: e = [],
|
|
1807
1807
|
selectedProperty: n = "",
|
|
1808
1808
|
onPropertyChange: t = () => {
|
|
1809
1809
|
},
|
|
1810
|
-
opacity:
|
|
1811
|
-
onOpacityChange:
|
|
1810
|
+
opacity: s = 0.85,
|
|
1811
|
+
onOpacityChange: r = () => {
|
|
1812
1812
|
},
|
|
1813
1813
|
propertyStats: i = null,
|
|
1814
1814
|
clickedBlock: o = null,
|
|
@@ -1817,7 +1817,7 @@ function rr({
|
|
|
1817
1817
|
}) {
|
|
1818
1818
|
var l, u;
|
|
1819
1819
|
return /* @__PURE__ */ W("div", { className: "bm-widget", children: [
|
|
1820
|
-
/* @__PURE__ */
|
|
1820
|
+
/* @__PURE__ */ S("label", { className: "bm-widget__label", htmlFor: "bm-property-select", children: "Color by" }),
|
|
1821
1821
|
/* @__PURE__ */ W(
|
|
1822
1822
|
"select",
|
|
1823
1823
|
{
|
|
@@ -1826,19 +1826,19 @@ function rr({
|
|
|
1826
1826
|
value: n,
|
|
1827
1827
|
onChange: (c) => t(c.target.value),
|
|
1828
1828
|
children: [
|
|
1829
|
-
e.length === 0 && /* @__PURE__ */
|
|
1830
|
-
e.map((c) => /* @__PURE__ */
|
|
1829
|
+
e.length === 0 && /* @__PURE__ */ S("option", { value: "", children: "— no attributes —" }),
|
|
1830
|
+
e.map((c) => /* @__PURE__ */ S("option", { value: c, children: c }, c))
|
|
1831
1831
|
]
|
|
1832
1832
|
}
|
|
1833
1833
|
),
|
|
1834
1834
|
i && i.type === "numeric" && /* @__PURE__ */ W("div", { className: "bm-widget__scale", children: [
|
|
1835
|
-
/* @__PURE__ */
|
|
1836
|
-
/* @__PURE__ */
|
|
1837
|
-
/* @__PURE__ */
|
|
1835
|
+
/* @__PURE__ */ S("span", { className: "bm-widget__scale-label bm-widget__scale-label--min", children: ((l = i.min) == null ? void 0 : l.toFixed(2)) ?? "—" }),
|
|
1836
|
+
/* @__PURE__ */ S("div", { className: "bm-widget__scale-bar" }),
|
|
1837
|
+
/* @__PURE__ */ S("span", { className: "bm-widget__scale-label bm-widget__scale-label--max", children: ((u = i.max) == null ? void 0 : u.toFixed(2)) ?? "—" })
|
|
1838
1838
|
] }),
|
|
1839
|
-
i && i.type === "categorical" && /* @__PURE__ */
|
|
1839
|
+
i && i.type === "categorical" && /* @__PURE__ */ S("div", { className: "bm-widget__categories", children: (i.categories || []).map((c, m) => {
|
|
1840
1840
|
const d = Math.round(m / Math.max(i.categories.length, 1) * 360);
|
|
1841
|
-
return /* @__PURE__ */
|
|
1841
|
+
return /* @__PURE__ */ S(
|
|
1842
1842
|
"span",
|
|
1843
1843
|
{
|
|
1844
1844
|
className: "bm-widget__category-chip",
|
|
@@ -1850,10 +1850,10 @@ function rr({
|
|
|
1850
1850
|
}) }),
|
|
1851
1851
|
/* @__PURE__ */ W("label", { className: "bm-widget__label", htmlFor: "bm-opacity-slider", children: [
|
|
1852
1852
|
"Opacity (",
|
|
1853
|
-
Math.round(
|
|
1853
|
+
Math.round(s * 100),
|
|
1854
1854
|
"%)"
|
|
1855
1855
|
] }),
|
|
1856
|
-
/* @__PURE__ */
|
|
1856
|
+
/* @__PURE__ */ S(
|
|
1857
1857
|
"input",
|
|
1858
1858
|
{
|
|
1859
1859
|
id: "bm-opacity-slider",
|
|
@@ -1862,14 +1862,14 @@ function rr({
|
|
|
1862
1862
|
min: "0",
|
|
1863
1863
|
max: "1",
|
|
1864
1864
|
step: "0.01",
|
|
1865
|
-
value:
|
|
1866
|
-
onChange: (c) =>
|
|
1865
|
+
value: s,
|
|
1866
|
+
onChange: (c) => r(parseFloat(c.target.value))
|
|
1867
1867
|
}
|
|
1868
1868
|
),
|
|
1869
1869
|
o && /* @__PURE__ */ W("div", { className: "bm-widget__popup", children: [
|
|
1870
1870
|
/* @__PURE__ */ W("div", { className: "bm-widget__popup-header", children: [
|
|
1871
|
-
/* @__PURE__ */
|
|
1872
|
-
/* @__PURE__ */
|
|
1871
|
+
/* @__PURE__ */ S("span", { children: "Block attributes" }),
|
|
1872
|
+
/* @__PURE__ */ S(
|
|
1873
1873
|
"button",
|
|
1874
1874
|
{
|
|
1875
1875
|
type: "button",
|
|
@@ -1880,9 +1880,9 @@ function rr({
|
|
|
1880
1880
|
}
|
|
1881
1881
|
)
|
|
1882
1882
|
] }),
|
|
1883
|
-
/* @__PURE__ */
|
|
1884
|
-
/* @__PURE__ */
|
|
1885
|
-
/* @__PURE__ */
|
|
1883
|
+
/* @__PURE__ */ S("table", { className: "bm-widget__popup-table", children: /* @__PURE__ */ S("tbody", { children: Object.entries(o).map(([c, m]) => /* @__PURE__ */ W("tr", { children: [
|
|
1884
|
+
/* @__PURE__ */ S("th", { children: c }),
|
|
1885
|
+
/* @__PURE__ */ S("td", { children: m == null ? "—" : String(m) })
|
|
1886
1886
|
] }, c)) }) })
|
|
1887
1887
|
] })
|
|
1888
1888
|
] });
|
|
@@ -1892,36 +1892,36 @@ const nn = [
|
|
|
1892
1892
|
{ minZoom: 4, lodKey: "medium" },
|
|
1893
1893
|
{ minZoom: 7, lodKey: "full" }
|
|
1894
1894
|
], ht = 50;
|
|
1895
|
-
function
|
|
1895
|
+
function sn(e, n, t = nn) {
|
|
1896
1896
|
var i;
|
|
1897
|
-
const
|
|
1898
|
-
if (!
|
|
1897
|
+
const s = e.lod_urls;
|
|
1898
|
+
if (!s || typeof s != "object" || Array.isArray(s))
|
|
1899
1899
|
return e.image_url || "";
|
|
1900
|
-
let
|
|
1900
|
+
let r = ((i = t[0]) == null ? void 0 : i.lodKey) ?? "thumb";
|
|
1901
1901
|
for (const o of t)
|
|
1902
|
-
n >= o.minZoom && (
|
|
1903
|
-
return r
|
|
1902
|
+
n >= o.minZoom && (r = o.lodKey);
|
|
1903
|
+
return s[r] || e.image_url || "";
|
|
1904
1904
|
}
|
|
1905
|
-
function
|
|
1905
|
+
function rn(e) {
|
|
1906
1906
|
return [...e].sort((n, t) => (n.from_depth ?? 0) - (t.from_depth ?? 0));
|
|
1907
1907
|
}
|
|
1908
1908
|
function on(e) {
|
|
1909
1909
|
const n = {};
|
|
1910
1910
|
for (const t of e) {
|
|
1911
|
-
const
|
|
1912
|
-
n[
|
|
1911
|
+
const s = t.photo_set != null && t.photo_set !== "" ? String(t.photo_set) : "default";
|
|
1912
|
+
n[s] || (n[s] = []), n[s].push(t);
|
|
1913
1913
|
}
|
|
1914
1914
|
return n;
|
|
1915
1915
|
}
|
|
1916
1916
|
function an(e, n, t = 10) {
|
|
1917
|
-
const
|
|
1918
|
-
if (e >= n || t <= 0) return
|
|
1919
|
-
const
|
|
1920
|
-
for (let o =
|
|
1917
|
+
const s = [];
|
|
1918
|
+
if (e >= n || t <= 0) return s;
|
|
1919
|
+
const r = Math.ceil(e / t) * t, i = t * 1e-9;
|
|
1920
|
+
for (let o = r; o <= n + i; o += t) {
|
|
1921
1921
|
const a = Math.round(o * 1e6) / 1e6;
|
|
1922
|
-
|
|
1922
|
+
s.push({ depth: a, label: `${a} m` });
|
|
1923
1923
|
}
|
|
1924
|
-
return
|
|
1924
|
+
return s;
|
|
1925
1925
|
}
|
|
1926
1926
|
function ln(e) {
|
|
1927
1927
|
return e >= 9 ? 1 : e >= 7 ? 2 : e >= 5 ? 5 : e >= 3 ? 10 : 20;
|
|
@@ -1929,10 +1929,10 @@ function ln(e) {
|
|
|
1929
1929
|
function pt(e) {
|
|
1930
1930
|
return `tray_${String(e).padStart(3, "0")}.jpg`;
|
|
1931
1931
|
}
|
|
1932
|
-
function cn(e, n, t,
|
|
1933
|
-
const o = (t ?? "").replace(/\/$/, ""), a = (
|
|
1932
|
+
function cn(e, n, t, s, r = "Tray Images", i = pt) {
|
|
1933
|
+
const o = (t ?? "").replace(/\/$/, ""), a = (s ?? "").replace(/\/$/, "");
|
|
1934
1934
|
return n.map((l, u) => {
|
|
1935
|
-
const c = l.filename ?? i(u), m = l.photoSet ??
|
|
1935
|
+
const c = l.filename ?? i(u), m = l.photoSet ?? r;
|
|
1936
1936
|
return {
|
|
1937
1937
|
hole_id: e,
|
|
1938
1938
|
from_depth: l.fromDepth,
|
|
@@ -1946,67 +1946,67 @@ function cn(e, n, t, r, s = "Tray Images", i = pt) {
|
|
|
1946
1946
|
};
|
|
1947
1947
|
});
|
|
1948
1948
|
}
|
|
1949
|
-
function
|
|
1950
|
-
const
|
|
1951
|
-
return Math.max(1, Math.round(e * t *
|
|
1949
|
+
function rs(e, n, t = ht) {
|
|
1950
|
+
const s = n / 5;
|
|
1951
|
+
return Math.max(1, Math.round(e * t * s));
|
|
1952
1952
|
}
|
|
1953
|
-
const
|
|
1953
|
+
const ze = 5, Je = 1.12, un = 0.05, dn = 40;
|
|
1954
1954
|
function mn({
|
|
1955
1955
|
photos: e = [],
|
|
1956
1956
|
holeId: n = "",
|
|
1957
1957
|
initialZoom: t = 5,
|
|
1958
|
-
transform:
|
|
1959
|
-
onTransformChange:
|
|
1958
|
+
transform: s,
|
|
1959
|
+
onTransformChange: r
|
|
1960
1960
|
}) {
|
|
1961
|
-
const [i, o] = X({ scale: 1, tx: 0, ty: 0 }), a =
|
|
1961
|
+
const [i, o] = X({ scale: 1, tx: 0, ty: 0 }), a = s ?? i, l = _e(a);
|
|
1962
1962
|
l.current = a;
|
|
1963
|
-
const u =
|
|
1963
|
+
const u = De(
|
|
1964
1964
|
(p) => {
|
|
1965
|
-
const
|
|
1966
|
-
|
|
1965
|
+
const T = typeof p == "function" ? p(l.current) : p;
|
|
1966
|
+
r ? r(T) : o(T);
|
|
1967
1967
|
},
|
|
1968
|
-
[
|
|
1969
|
-
), [c, m] = X(!1), d = _e(null), f = _e(null), g = ee(() =>
|
|
1968
|
+
[r]
|
|
1969
|
+
), [c, m] = X(!1), d = _e(null), f = _e(null), g = ee(() => rn(e), [e]), y = ee(() => on(g), [g]), b = ee(() => {
|
|
1970
1970
|
const p = /* @__PURE__ */ new Set();
|
|
1971
|
-
for (const
|
|
1972
|
-
const
|
|
1973
|
-
p.add(
|
|
1971
|
+
for (const T of e) {
|
|
1972
|
+
const I = T.photo_set != null && T.photo_set !== "" ? String(T.photo_set) : "default";
|
|
1973
|
+
p.add(I);
|
|
1974
1974
|
}
|
|
1975
1975
|
return [...p];
|
|
1976
|
-
}, [e]), { minDepth: h, maxDepth:
|
|
1976
|
+
}, [e]), { minDepth: h, maxDepth: E } = ee(() => {
|
|
1977
1977
|
if (!g.length) return { minDepth: 0, maxDepth: 0 };
|
|
1978
|
-
const p = g.map((
|
|
1978
|
+
const p = g.map((T) => T.to_depth ?? T.from_depth ?? 0);
|
|
1979
1979
|
return {
|
|
1980
1980
|
minDepth: g[0].from_depth ?? 0,
|
|
1981
1981
|
maxDepth: Math.max(...p)
|
|
1982
1982
|
};
|
|
1983
|
-
}, [g]),
|
|
1984
|
-
() => Math.max(1, Math.round((
|
|
1985
|
-
[h,
|
|
1986
|
-
),
|
|
1987
|
-
const p = ln(
|
|
1988
|
-
return an(h,
|
|
1989
|
-
}, [h,
|
|
1983
|
+
}, [g]), A = ht * ze / 5, x = ee(
|
|
1984
|
+
() => Math.max(1, Math.round((E - h) * A)),
|
|
1985
|
+
[h, E, A]
|
|
1986
|
+
), H = ee(() => {
|
|
1987
|
+
const p = ln(ze);
|
|
1988
|
+
return an(h, E, p);
|
|
1989
|
+
}, [h, E]), O = 540 * ze / 5, P = ee(
|
|
1990
1990
|
() => Math.max(1, Math.min(10, Math.round(t * a.scale))),
|
|
1991
1991
|
[t, a.scale]
|
|
1992
|
-
),
|
|
1992
|
+
), R = De((p) => {
|
|
1993
1993
|
p.preventDefault();
|
|
1994
|
-
const
|
|
1995
|
-
u((
|
|
1996
|
-
const N = Math.max(un, Math.min(dn,
|
|
1994
|
+
const T = p.deltaY < 0 ? Je : 1 / Je, I = f.current.getBoundingClientRect(), z = p.clientX - I.left, w = p.clientY - I.top;
|
|
1995
|
+
u((v) => {
|
|
1996
|
+
const N = Math.max(un, Math.min(dn, v.scale * T)), D = N / v.scale;
|
|
1997
1997
|
return {
|
|
1998
1998
|
scale: N,
|
|
1999
|
-
tx:
|
|
2000
|
-
ty: w - (w -
|
|
1999
|
+
tx: z - (z - v.tx) * D,
|
|
2000
|
+
ty: w - (w - v.ty) * D
|
|
2001
2001
|
};
|
|
2002
2002
|
});
|
|
2003
2003
|
}, [u]);
|
|
2004
2004
|
ne(() => {
|
|
2005
2005
|
const p = f.current;
|
|
2006
2006
|
if (p)
|
|
2007
|
-
return p.addEventListener("wheel",
|
|
2008
|
-
}, [
|
|
2009
|
-
const
|
|
2007
|
+
return p.addEventListener("wheel", R, { passive: !1 }), () => p.removeEventListener("wheel", R);
|
|
2008
|
+
}, [R]);
|
|
2009
|
+
const V = De((p) => {
|
|
2010
2010
|
p.button === 0 && (p.preventDefault(), d.current = {
|
|
2011
2011
|
x: p.clientX,
|
|
2012
2012
|
y: p.clientY,
|
|
@@ -2015,28 +2015,28 @@ function mn({
|
|
|
2015
2015
|
}, m(!0));
|
|
2016
2016
|
}, []);
|
|
2017
2017
|
return ne(() => {
|
|
2018
|
-
const p = (
|
|
2018
|
+
const p = (I) => {
|
|
2019
2019
|
if (!d.current) return;
|
|
2020
|
-
const { tx:
|
|
2021
|
-
u((
|
|
2022
|
-
...
|
|
2023
|
-
tx:
|
|
2024
|
-
ty: w + (
|
|
2020
|
+
const { tx: z, ty: w, x: v, y: N } = d.current;
|
|
2021
|
+
u((D) => ({
|
|
2022
|
+
...D,
|
|
2023
|
+
tx: z + (I.clientX - v),
|
|
2024
|
+
ty: w + (I.clientY - N)
|
|
2025
2025
|
}));
|
|
2026
|
-
},
|
|
2026
|
+
}, T = () => {
|
|
2027
2027
|
d.current = null, m(!1);
|
|
2028
2028
|
};
|
|
2029
|
-
return window.addEventListener("mousemove", p), window.addEventListener("mouseup",
|
|
2030
|
-
window.removeEventListener("mousemove", p), window.removeEventListener("mouseup",
|
|
2029
|
+
return window.addEventListener("mousemove", p), window.addEventListener("mouseup", T), () => {
|
|
2030
|
+
window.removeEventListener("mousemove", p), window.removeEventListener("mouseup", T);
|
|
2031
2031
|
};
|
|
2032
2032
|
}, [u]), /* @__PURE__ */ W("div", { className: "core-photo-table", children: [
|
|
2033
2033
|
/* @__PURE__ */ W("div", { className: "core-photo-controls", children: [
|
|
2034
|
-
n && /* @__PURE__ */
|
|
2034
|
+
n && /* @__PURE__ */ S("span", { className: "core-photo-hole-id", children: n }),
|
|
2035
2035
|
/* @__PURE__ */ W("span", { className: "core-photo-zoom-label", children: [
|
|
2036
2036
|
Math.round(a.scale * 100),
|
|
2037
2037
|
"%"
|
|
2038
2038
|
] }),
|
|
2039
|
-
/* @__PURE__ */
|
|
2039
|
+
/* @__PURE__ */ S(
|
|
2040
2040
|
"button",
|
|
2041
2041
|
{
|
|
2042
2042
|
className: "core-photo-zoom-btn",
|
|
@@ -2048,8 +2048,8 @@ function mn({
|
|
|
2048
2048
|
)
|
|
2049
2049
|
] }),
|
|
2050
2050
|
e.length > 0 && /* @__PURE__ */ W("div", { className: "core-photo-col-headers", children: [
|
|
2051
|
-
/* @__PURE__ */
|
|
2052
|
-
b.map((p) => /* @__PURE__ */
|
|
2051
|
+
/* @__PURE__ */ S("div", { className: "core-photo-ruler-spacer" }),
|
|
2052
|
+
b.map((p) => /* @__PURE__ */ S(
|
|
2053
2053
|
"div",
|
|
2054
2054
|
{
|
|
2055
2055
|
className: "core-photo-set-header",
|
|
@@ -2059,76 +2059,76 @@ function mn({
|
|
|
2059
2059
|
p
|
|
2060
2060
|
))
|
|
2061
2061
|
] }),
|
|
2062
|
-
e.length === 0 ? /* @__PURE__ */
|
|
2062
|
+
e.length === 0 ? /* @__PURE__ */ S("div", { className: "core-photo-empty", children: "No photos to display." }) : /* @__PURE__ */ S(
|
|
2063
2063
|
"div",
|
|
2064
2064
|
{
|
|
2065
2065
|
className: `core-photo-scroll${c ? " is-dragging" : ""}`,
|
|
2066
2066
|
ref: f,
|
|
2067
|
-
onMouseDown:
|
|
2067
|
+
onMouseDown: V,
|
|
2068
2068
|
children: /* @__PURE__ */ W(
|
|
2069
2069
|
"div",
|
|
2070
2070
|
{
|
|
2071
2071
|
className: "core-photo-inner",
|
|
2072
2072
|
style: {
|
|
2073
|
-
height:
|
|
2073
|
+
height: x,
|
|
2074
2074
|
transform: `translate(${a.tx}px, ${a.ty}px) scale(${a.scale})`,
|
|
2075
2075
|
transformOrigin: "0 0"
|
|
2076
2076
|
},
|
|
2077
2077
|
children: [
|
|
2078
|
-
/* @__PURE__ */
|
|
2078
|
+
/* @__PURE__ */ S(
|
|
2079
2079
|
"div",
|
|
2080
2080
|
{
|
|
2081
2081
|
className: "core-photo-depth-ruler",
|
|
2082
|
-
style: { height:
|
|
2083
|
-
children:
|
|
2082
|
+
style: { height: x },
|
|
2083
|
+
children: H.map(({ depth: p, label: T }) => /* @__PURE__ */ S(
|
|
2084
2084
|
"div",
|
|
2085
2085
|
{
|
|
2086
2086
|
className: "core-photo-depth-marker",
|
|
2087
2087
|
style: {
|
|
2088
|
-
top: Math.round((p - h) *
|
|
2088
|
+
top: Math.round((p - h) * A)
|
|
2089
2089
|
},
|
|
2090
|
-
children:
|
|
2090
|
+
children: T
|
|
2091
2091
|
},
|
|
2092
2092
|
p
|
|
2093
2093
|
))
|
|
2094
2094
|
}
|
|
2095
2095
|
),
|
|
2096
|
-
b.map((p) => /* @__PURE__ */
|
|
2096
|
+
b.map((p) => /* @__PURE__ */ S(
|
|
2097
2097
|
"div",
|
|
2098
2098
|
{
|
|
2099
2099
|
className: "core-photo-col-body",
|
|
2100
|
-
style: { height:
|
|
2101
|
-
children: y[p].map((
|
|
2102
|
-
const
|
|
2103
|
-
(
|
|
2104
|
-
),
|
|
2100
|
+
style: { height: x, width: O },
|
|
2101
|
+
children: y[p].map((T) => {
|
|
2102
|
+
const I = T.from_depth ?? 0, z = T.to_depth ?? I, w = Math.round(
|
|
2103
|
+
(I - h) * A
|
|
2104
|
+
), v = Math.max(
|
|
2105
2105
|
2,
|
|
2106
|
-
Math.round((
|
|
2107
|
-
), N =
|
|
2106
|
+
Math.round((z - I) * A)
|
|
2107
|
+
), N = sn(T, P);
|
|
2108
2108
|
return /* @__PURE__ */ W(
|
|
2109
2109
|
"div",
|
|
2110
2110
|
{
|
|
2111
2111
|
className: "core-photo-item",
|
|
2112
|
-
style: { top: w, height:
|
|
2113
|
-
title: `${
|
|
2112
|
+
style: { top: w, height: v, width: O },
|
|
2113
|
+
title: `${I}–${z} m`,
|
|
2114
2114
|
children: [
|
|
2115
|
-
N ? /* @__PURE__ */
|
|
2115
|
+
N ? /* @__PURE__ */ S(
|
|
2116
2116
|
"img",
|
|
2117
2117
|
{
|
|
2118
2118
|
src: N,
|
|
2119
|
-
alt: `Core ${
|
|
2119
|
+
alt: `Core ${I}–${z} m`,
|
|
2120
2120
|
loading: "lazy"
|
|
2121
2121
|
}
|
|
2122
|
-
) : /* @__PURE__ */
|
|
2123
|
-
|
|
2124
|
-
|
|
2122
|
+
) : /* @__PURE__ */ S("div", { className: "core-photo-no-image" }),
|
|
2123
|
+
v >= 18 && /* @__PURE__ */ W("span", { className: "core-photo-item-label", children: [
|
|
2124
|
+
I,
|
|
2125
2125
|
"–",
|
|
2126
|
-
|
|
2126
|
+
z,
|
|
2127
2127
|
" m"
|
|
2128
2128
|
] })
|
|
2129
2129
|
]
|
|
2130
2130
|
},
|
|
2131
|
-
`${
|
|
2131
|
+
`${T.hole_id ?? ""}-${I}-${z}-${p}`
|
|
2132
2132
|
);
|
|
2133
2133
|
})
|
|
2134
2134
|
},
|
|
@@ -2141,22 +2141,22 @@ function mn({
|
|
|
2141
2141
|
)
|
|
2142
2142
|
] });
|
|
2143
2143
|
}
|
|
2144
|
-
function
|
|
2144
|
+
function os({
|
|
2145
2145
|
holeId: e = "",
|
|
2146
2146
|
trays: n = [],
|
|
2147
2147
|
thumbBaseUrl: t = "",
|
|
2148
|
-
fullBaseUrl:
|
|
2149
|
-
photoSet:
|
|
2148
|
+
fullBaseUrl: s = "",
|
|
2149
|
+
photoSet: r = "Tray Images",
|
|
2150
2150
|
getFilename: i = pt,
|
|
2151
2151
|
initialZoom: o = 5,
|
|
2152
2152
|
transform: a,
|
|
2153
2153
|
onTransformChange: l
|
|
2154
2154
|
}) {
|
|
2155
2155
|
const u = ee(
|
|
2156
|
-
() => cn(e, n, t,
|
|
2157
|
-
[e, n, t,
|
|
2156
|
+
() => cn(e, n, t, s, r, i),
|
|
2157
|
+
[e, n, t, s, r, i]
|
|
2158
2158
|
);
|
|
2159
|
-
return /* @__PURE__ */
|
|
2159
|
+
return /* @__PURE__ */ S(
|
|
2160
2160
|
mn,
|
|
2161
2161
|
{
|
|
2162
2162
|
photos: u,
|
|
@@ -2167,7 +2167,7 @@ function or({
|
|
|
2167
2167
|
}
|
|
2168
2168
|
);
|
|
2169
2169
|
}
|
|
2170
|
-
function
|
|
2170
|
+
function is(e) {
|
|
2171
2171
|
const n = typeof e == "string" ? JSON.parse(e) : e;
|
|
2172
2172
|
if (n.schema_version !== "1.0")
|
|
2173
2173
|
throw new Error(
|
|
@@ -2175,18 +2175,18 @@ function ir(e) {
|
|
|
2175
2175
|
);
|
|
2176
2176
|
if (!Array.isArray(n.blocks))
|
|
2177
2177
|
throw new Error('"blocks" must be a JSON array.');
|
|
2178
|
-
const t = n.blocks.map((
|
|
2179
|
-
if (
|
|
2180
|
-
if (
|
|
2181
|
-
if (!Array.isArray(
|
|
2182
|
-
if (!Array.isArray(
|
|
2178
|
+
const t = n.blocks.map((s, r) => {
|
|
2179
|
+
if (s.id == null) throw new Error(`Block at index ${r} is missing required field "id".`);
|
|
2180
|
+
if (s.name == null) throw new Error(`Block "${s.id}" is missing required field "name".`);
|
|
2181
|
+
if (!Array.isArray(s.vertices)) throw new Error(`Block "${s.id}" is missing required field "vertices".`);
|
|
2182
|
+
if (!Array.isArray(s.triangles)) throw new Error(`Block "${s.id}" is missing required field "triangles".`);
|
|
2183
2183
|
return {
|
|
2184
|
-
id:
|
|
2185
|
-
name:
|
|
2186
|
-
vertices:
|
|
2187
|
-
triangles:
|
|
2188
|
-
attributes:
|
|
2189
|
-
material:
|
|
2184
|
+
id: s.id,
|
|
2185
|
+
name: s.name,
|
|
2186
|
+
vertices: s.vertices,
|
|
2187
|
+
triangles: s.triangles,
|
|
2188
|
+
attributes: s.attributes ?? {},
|
|
2189
|
+
material: s.material ?? {}
|
|
2190
2190
|
};
|
|
2191
2191
|
});
|
|
2192
2192
|
return {
|
|
@@ -2197,19 +2197,19 @@ function ir(e) {
|
|
|
2197
2197
|
}
|
|
2198
2198
|
function fn(e) {
|
|
2199
2199
|
const n = new Q.BufferGeometry(), t = new Float32Array(e.vertices.length * 3);
|
|
2200
|
-
e.vertices.forEach(([
|
|
2201
|
-
t[a * 3] =
|
|
2200
|
+
e.vertices.forEach(([r, i, o], a) => {
|
|
2201
|
+
t[a * 3] = r, t[a * 3 + 1] = i, t[a * 3 + 2] = o;
|
|
2202
2202
|
}), n.setAttribute("position", new Q.BufferAttribute(t, 3));
|
|
2203
|
-
const
|
|
2204
|
-
return e.triangles.forEach(([
|
|
2205
|
-
|
|
2206
|
-
}), n.setIndex(new Q.BufferAttribute(
|
|
2203
|
+
const s = new Uint32Array(e.triangles.length * 3);
|
|
2204
|
+
return e.triangles.forEach(([r, i, o], a) => {
|
|
2205
|
+
s[a * 3] = r, s[a * 3 + 1] = i, s[a * 3 + 2] = o;
|
|
2206
|
+
}), n.setIndex(new Q.BufferAttribute(s, 1)), n;
|
|
2207
2207
|
}
|
|
2208
|
-
function
|
|
2209
|
-
const { defaultOpacity:
|
|
2208
|
+
function as(e, n, t = {}) {
|
|
2209
|
+
const { defaultOpacity: s = 1 } = t, r = new Q.Group();
|
|
2210
2210
|
return n.blocks.forEach((i) => {
|
|
2211
2211
|
var y, b;
|
|
2212
|
-
const o = fn(i), a = ((y = i.material) == null ? void 0 : y.color) ?? "#888888", l = ((b = i.material) == null ? void 0 : b.opacity) ??
|
|
2212
|
+
const o = fn(i), a = ((y = i.material) == null ? void 0 : y.color) ?? "#888888", l = ((b = i.material) == null ? void 0 : b.opacity) ?? s, u = l < 1, c = new Q.MeshStandardMaterial({
|
|
2213
2213
|
color: new Q.Color(a),
|
|
2214
2214
|
opacity: l,
|
|
2215
2215
|
transparent: u,
|
|
@@ -2221,195 +2221,215 @@ function ar(e, n, t = {}) {
|
|
|
2221
2221
|
attributes: i.attributes
|
|
2222
2222
|
};
|
|
2223
2223
|
const d = new Q.EdgesGeometry(o, 15), f = new Q.LineBasicMaterial({ color: "#ffffbb", linewidth: 1 }), g = new Q.LineSegments(d, f);
|
|
2224
|
-
g.visible = !1, m.add(g),
|
|
2225
|
-
}), e.add(
|
|
2224
|
+
g.visible = !1, m.add(g), r.add(m);
|
|
2225
|
+
}), e.add(r), r;
|
|
2226
2226
|
}
|
|
2227
2227
|
export {
|
|
2228
|
-
|
|
2229
|
-
|
|
2228
|
+
us as ALPHA,
|
|
2229
|
+
ds as ASSAY_COLOR_PALETTE_10,
|
|
2230
|
+
It as ASSAY_NON_VALUE_FIELDS,
|
|
2230
2231
|
j as AZIMUTH,
|
|
2231
|
-
|
|
2232
|
-
|
|
2233
|
-
|
|
2234
|
-
|
|
2235
|
-
|
|
2236
|
-
|
|
2232
|
+
ms as BASELODE_COLORWAY,
|
|
2233
|
+
fs as BASELODE_DARK,
|
|
2234
|
+
hs as BASELODE_DARK_TEMPLATE,
|
|
2235
|
+
ps as BASELODE_DARK_TEMPLATE_NAME,
|
|
2236
|
+
ys as BASELODE_DATA_MODEL_DRILL_ASSAY,
|
|
2237
|
+
gs as BASELODE_DATA_MODEL_DRILL_COLLAR,
|
|
2237
2238
|
_t as BASELODE_DATA_MODEL_DRILL_GEOLOGY,
|
|
2238
|
-
|
|
2239
|
-
|
|
2240
|
-
|
|
2241
|
-
|
|
2242
|
-
|
|
2243
|
-
|
|
2244
|
-
|
|
2245
|
-
|
|
2239
|
+
bs as BASELODE_DATA_MODEL_DRILL_SURVEY,
|
|
2240
|
+
_s as BASELODE_DATA_MODEL_GEOPHYSICS,
|
|
2241
|
+
Ns as BASELODE_DATA_MODEL_STRUCTURAL_POINT,
|
|
2242
|
+
Es as BASELODE_DATA_MODEL_SURFACE_SAMPLE,
|
|
2243
|
+
As as BASELODE_LIGHT,
|
|
2244
|
+
vs as BASELODE_LIGHT_TEMPLATE,
|
|
2245
|
+
Is as BASELODE_LIGHT_TEMPLATE_NAME,
|
|
2246
|
+
$e as BASELODE_TEMPLATE,
|
|
2247
|
+
Ss as BASELODE_TEMPLATE_NAME,
|
|
2246
2248
|
ht as BASE_PIXELS_PER_METRE,
|
|
2247
|
-
|
|
2248
|
-
|
|
2249
|
-
|
|
2250
|
-
|
|
2251
|
-
|
|
2252
|
-
|
|
2253
|
-
|
|
2254
|
-
|
|
2249
|
+
Ls as BETA,
|
|
2250
|
+
Cs as BUILTIN_COLOUR_MAPS,
|
|
2251
|
+
ns as Baselode3DControls,
|
|
2252
|
+
Ts as Baselode3DScene,
|
|
2253
|
+
ss as BlockModelWidget,
|
|
2254
|
+
Ms as CHART_OPTIONS,
|
|
2255
|
+
Os as COLLAR_ID,
|
|
2256
|
+
Ps as COMMENTS,
|
|
2257
|
+
Ds as COMMENT_COLUMN_NAMES,
|
|
2258
|
+
xs as COMMODITY_COLOURS,
|
|
2259
|
+
Rs as CRS,
|
|
2255
2260
|
mn as CorePhotoTable,
|
|
2256
|
-
|
|
2257
|
-
|
|
2261
|
+
os as CorePhotoViewer,
|
|
2262
|
+
zs as DATASOURCE,
|
|
2263
|
+
Fs as DATASOURCE_HOLE_ID,
|
|
2264
|
+
$s as DATASOURCE_SAMPLE_ID,
|
|
2265
|
+
ks as DATASOURCE_SURFACE_SAMPLE_ID,
|
|
2266
|
+
ws as DATE_END,
|
|
2267
|
+
Hs as DATE_START,
|
|
2268
|
+
Us as DEFAULT_COLUMN_MAP,
|
|
2258
2269
|
nn as DEFAULT_LOD_BREAKPOINTS,
|
|
2259
|
-
|
|
2270
|
+
G as DEPTH,
|
|
2260
2271
|
Y as DIP,
|
|
2261
|
-
|
|
2272
|
+
Be as DISPLAY_CATEGORICAL,
|
|
2262
2273
|
Pe as DISPLAY_COMMENT,
|
|
2263
|
-
|
|
2274
|
+
Bs as DISPLAY_HIDDEN,
|
|
2264
2275
|
Nt as DISPLAY_NUMERIC,
|
|
2265
|
-
|
|
2276
|
+
Ge as DISPLAY_TADPOLE,
|
|
2266
2277
|
pe as EASTING,
|
|
2267
|
-
|
|
2268
|
-
|
|
2269
|
-
|
|
2270
|
-
|
|
2271
|
-
|
|
2272
|
-
|
|
2278
|
+
ve as ELEVATION,
|
|
2279
|
+
Gs as ERROR_COLOR,
|
|
2280
|
+
Vs as EXTRA,
|
|
2281
|
+
js as FALLBACK_COLOUR,
|
|
2282
|
+
Ys as FOV_MAX_DEG,
|
|
2283
|
+
Ws as FOV_MIN_DEG,
|
|
2284
|
+
C as FROM,
|
|
2273
2285
|
le as GEOLOGY_CODE,
|
|
2274
2286
|
ce as GEOLOGY_DESCRIPTION,
|
|
2287
|
+
qs as GEOPHYSICS_NULL,
|
|
2275
2288
|
Qe as GEOPHYSICS_NULL_SENTINEL,
|
|
2276
|
-
|
|
2289
|
+
Ks as HIDDEN_COLUMNS,
|
|
2277
2290
|
_ as HOLE_ID,
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
|
|
2281
|
-
|
|
2291
|
+
Xs as HOLE_TYPE,
|
|
2292
|
+
se as LATITUDE,
|
|
2293
|
+
Zs as LITHOLOGY_COLOURS,
|
|
2294
|
+
re as LONGITUDE,
|
|
2295
|
+
Js as MAX_DEPTH,
|
|
2296
|
+
Ee as MID,
|
|
2282
2297
|
ye as NORTHING,
|
|
2283
|
-
|
|
2284
|
-
|
|
2298
|
+
Qs as NUMERIC_LINE_COLOR,
|
|
2299
|
+
er as NUMERIC_MARKER_COLOR,
|
|
2285
2300
|
de as PROJECT_ID,
|
|
2286
|
-
|
|
2287
|
-
|
|
2288
|
-
|
|
2289
|
-
|
|
2290
|
-
|
|
2301
|
+
tr as REPORT_NUMBER,
|
|
2302
|
+
nr as SAMPLE_ID,
|
|
2303
|
+
sr as STRIKE,
|
|
2304
|
+
rr as STRIP_LOG_DEFAULT_COLOR,
|
|
2305
|
+
or as STRIP_LOG_DEFAULT_LATERAL_OFFSET,
|
|
2306
|
+
ir as STRIP_LOG_DEFAULT_PANEL_WIDTH,
|
|
2307
|
+
ar as SURFACE_SAMPLE_ID,
|
|
2308
|
+
lr as SURFACE_SAMPLE_TYPE,
|
|
2309
|
+
cr as SURVEY_TYPE,
|
|
2310
|
+
M as TO,
|
|
2291
2311
|
Kn as TracePlot,
|
|
2292
|
-
|
|
2293
|
-
|
|
2294
|
-
|
|
2295
|
-
|
|
2312
|
+
as as addGradeBlocksToScene,
|
|
2313
|
+
ur as addRasterOverlay,
|
|
2314
|
+
dr as alphaBetaToNormal,
|
|
2315
|
+
ts as annotationsFromIntervals,
|
|
2296
2316
|
kn as assembleDataset,
|
|
2297
|
-
|
|
2298
|
-
|
|
2299
|
-
|
|
2300
|
-
|
|
2317
|
+
Mn as attachAssayPositions,
|
|
2318
|
+
Cn as balancedTangentialDesurvey,
|
|
2319
|
+
xt as buildAssayState,
|
|
2320
|
+
mr as buildCategoricalStripLogConfig,
|
|
2301
2321
|
Zt as buildCommentsConfig,
|
|
2302
2322
|
an as buildDepthMarkers,
|
|
2303
|
-
|
|
2304
|
-
|
|
2305
|
-
|
|
2323
|
+
fr as buildEqualRangeColorScale,
|
|
2324
|
+
vt as buildIntervalPoints,
|
|
2325
|
+
Et as buildPlotConfig,
|
|
2306
2326
|
qn as buildStrikeDipSymbol,
|
|
2307
|
-
|
|
2308
|
-
|
|
2309
|
-
|
|
2327
|
+
hr as buildStripLogGroup,
|
|
2328
|
+
pr as buildStripLogLinePoints,
|
|
2329
|
+
yr as buildStructuralDiscs,
|
|
2310
2330
|
Wn as buildStructuralStripConfig,
|
|
2311
2331
|
Xt as buildTadpoleConfig,
|
|
2312
|
-
|
|
2332
|
+
Tn as buildTraces,
|
|
2313
2333
|
cn as buildTrayPhotos,
|
|
2314
|
-
|
|
2315
|
-
|
|
2316
|
-
|
|
2334
|
+
gr as buildViewSignature,
|
|
2335
|
+
br as calculateBlockVolume,
|
|
2336
|
+
_r as calculatePropertyStats,
|
|
2317
2337
|
bt as classifyColumns,
|
|
2318
|
-
|
|
2319
|
-
|
|
2320
|
-
|
|
2321
|
-
|
|
2322
|
-
|
|
2323
|
-
|
|
2338
|
+
Nr as clearRasterOverlays,
|
|
2339
|
+
Er as clearStripLogs,
|
|
2340
|
+
$n as coerceNumeric,
|
|
2341
|
+
Ar as computeStructuralPositions,
|
|
2342
|
+
vr as createRasterOverlay,
|
|
2343
|
+
Ir as defaultChartType,
|
|
2324
2344
|
pt as defaultTrayFilename,
|
|
2325
|
-
|
|
2345
|
+
rs as depthIntervalToPixels,
|
|
2326
2346
|
ln as depthMarkerInterval,
|
|
2327
2347
|
Le as deriveAssayProps,
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
|
|
2332
|
-
|
|
2333
|
-
|
|
2334
|
-
|
|
2335
|
-
|
|
2348
|
+
Sn as desurveyTraces,
|
|
2349
|
+
Sr as dipAzimuthToNormal,
|
|
2350
|
+
Lr as dolly,
|
|
2351
|
+
Cr as emitViewChangeIfNeeded,
|
|
2352
|
+
Tr as filterBlocks,
|
|
2353
|
+
Fn as filterByProject,
|
|
2354
|
+
Mr as fitCameraToBounds,
|
|
2355
|
+
Or as focusOnLastBounds,
|
|
2336
2356
|
jn as geophysicsToStripLogs,
|
|
2337
|
-
|
|
2338
|
-
|
|
2357
|
+
Pr as getBlockStats,
|
|
2358
|
+
Dr as getCategoryHexColor,
|
|
2339
2359
|
et as getChartOptions,
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2345
|
-
|
|
2346
|
-
|
|
2360
|
+
xr as getColorForValue,
|
|
2361
|
+
Rr as getColour,
|
|
2362
|
+
zr as getEqualRangeBinIndex,
|
|
2363
|
+
Fr as getEqualRangeColor,
|
|
2364
|
+
$r as getHoleVerticalExtent,
|
|
2365
|
+
kr as getRasterOverlay,
|
|
2366
|
+
wr as getViewState,
|
|
2347
2367
|
fn as gradeBlockToThreeGeometry,
|
|
2348
2368
|
on as groupPhotosBySet,
|
|
2349
|
-
|
|
2350
|
-
|
|
2351
|
-
|
|
2352
|
-
|
|
2353
|
-
|
|
2354
|
-
|
|
2355
|
-
|
|
2356
|
-
|
|
2369
|
+
Bt as groupRowsByHole,
|
|
2370
|
+
At as holeHasData,
|
|
2371
|
+
Hr as interpolateTrace,
|
|
2372
|
+
es as intervalsAsTubes,
|
|
2373
|
+
zn as joinAssaysToTraces,
|
|
2374
|
+
Ur as listRasterOverlays,
|
|
2375
|
+
vn as loadAssayFile,
|
|
2376
|
+
Dt as loadAssayHole,
|
|
2357
2377
|
Pt as loadAssayMetadata,
|
|
2358
|
-
|
|
2359
|
-
|
|
2378
|
+
xn as loadAssays,
|
|
2379
|
+
Br as loadBlockModelMetadata,
|
|
2360
2380
|
Pn as loadCollars,
|
|
2361
|
-
|
|
2362
|
-
|
|
2363
|
-
|
|
2364
|
-
|
|
2365
|
-
|
|
2366
|
-
|
|
2367
|
-
|
|
2368
|
-
|
|
2369
|
-
|
|
2370
|
-
|
|
2371
|
-
|
|
2372
|
-
|
|
2373
|
-
|
|
2374
|
-
|
|
2375
|
-
|
|
2376
|
-
|
|
2381
|
+
Rn as loadGeology,
|
|
2382
|
+
is as loadGradeBlocksFromJson,
|
|
2383
|
+
Dn as loadSurveys,
|
|
2384
|
+
Me as loadTable,
|
|
2385
|
+
Gr as logDataInfo,
|
|
2386
|
+
Vr as logDataWarning,
|
|
2387
|
+
jr as lookDown,
|
|
2388
|
+
Ft as minimumCurvatureDesurvey,
|
|
2389
|
+
Yr as normalizeBlockRow,
|
|
2390
|
+
Wr as normalizeBounds,
|
|
2391
|
+
En as normalizeCsvRow,
|
|
2392
|
+
Ie as normalizeFieldName,
|
|
2393
|
+
qr as normalizeStripLogOptions,
|
|
2394
|
+
Kr as pan,
|
|
2395
|
+
Vt as parseAssayCsvTextToHoles,
|
|
2396
|
+
Tt as parseAssayHole,
|
|
2377
2397
|
Nn as parseAssayHoleIds,
|
|
2378
|
-
|
|
2379
|
-
|
|
2380
|
-
|
|
2398
|
+
Ct as parseAssayHoleIdsWithAssays,
|
|
2399
|
+
Mt as parseAssaysCSV,
|
|
2400
|
+
Xr as parseBlockModelCSV,
|
|
2381
2401
|
On as parseDrillholesCSV,
|
|
2382
2402
|
jt as parseGeologyCsvText,
|
|
2383
|
-
|
|
2403
|
+
Vn as parseGeophysicsCSV,
|
|
2384
2404
|
Yn as parseLasFile,
|
|
2385
|
-
|
|
2386
|
-
|
|
2387
|
-
|
|
2388
|
-
|
|
2389
|
-
|
|
2390
|
-
|
|
2405
|
+
Gt as parseStructuralCSV,
|
|
2406
|
+
Un as parseStructuralIntervalsCSV,
|
|
2407
|
+
Hn as parseStructuralPointsCSV,
|
|
2408
|
+
In as parseSurveyCSV,
|
|
2409
|
+
Bn as parseUnifiedDataset,
|
|
2410
|
+
An as pickFirstPresent,
|
|
2391
2411
|
Zn as planView,
|
|
2392
2412
|
en as projectTraceToSection,
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2413
|
+
Zr as recenterCameraToOrigin,
|
|
2414
|
+
Jr as removeRasterOverlay,
|
|
2415
|
+
st as reorderHoleIds,
|
|
2416
|
+
Qr as resolveColourMap,
|
|
2397
2417
|
Jn as sectionView,
|
|
2398
2418
|
tn as sectionWindow,
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
|
-
|
|
2402
|
-
|
|
2403
|
-
|
|
2404
|
-
|
|
2405
|
-
|
|
2406
|
-
|
|
2407
|
-
|
|
2408
|
-
|
|
2419
|
+
sn as selectPhotoLodUrl,
|
|
2420
|
+
eo as setControlMode,
|
|
2421
|
+
to as setFov,
|
|
2422
|
+
no as setRasterOverlayElevation,
|
|
2423
|
+
so as setRasterOverlayOpacity,
|
|
2424
|
+
ro as setRasterOverlayVisibility,
|
|
2425
|
+
oo as setStripLogs,
|
|
2426
|
+
io as setViewState,
|
|
2427
|
+
Gn as significantIntercepts,
|
|
2428
|
+
rn as sortPhotosByDepth,
|
|
2409
2429
|
ie as standardizeColumns,
|
|
2410
2430
|
_n as standardizeRowArray,
|
|
2411
2431
|
Ln as tangentialDesurvey,
|
|
2412
|
-
|
|
2432
|
+
ao as toError,
|
|
2413
2433
|
Qn as tracesAsSegments,
|
|
2414
2434
|
Xn as useDrillholeTraceGrid,
|
|
2415
2435
|
wn as validateStructuralPoints,
|