quantum-component-library 1.4.53-dev.1 → 1.4.53-dev.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components.cjs +1 -1
- package/dist/components.js +965 -965
- package/dist/{dnd-core-vendor-CxLn_KVZ.js → dnd-core-vendor-Dl2_2nro.js} +2 -2
- package/dist/{dnd-core-vendor-BpIne3vw.cjs → dnd-core-vendor-JZjD_Td8.cjs} +1 -1
- package/dist/{graphql-vendor-D1Yd8wq_.cjs → graphql-vendor-B7q7Yz13.cjs} +1 -1
- package/dist/{graphql-vendor-Cx8Mc6Yz.js → graphql-vendor-e0-pkqHq.js} +1 -1
- package/dist/hooks.cjs +1 -1
- package/dist/hooks.js +3 -3
- package/dist/index.cjs +1 -1
- package/dist/index.js +3 -3
- package/dist/lib/services/reports.d.ts +5 -0
- package/dist/{lodash-vendor-3vLqZYsK.js → lodash-vendor-CNINpQjK.js} +1 -1
- package/dist/{lodash-vendor-BXoJ3fY7.cjs → lodash-vendor-DUcUuCwh.cjs} +1 -1
- package/dist/{other-V9jzzJwZ.js → other-Bc-jVnzY.js} +2 -2
- package/dist/{other-DNeraOC1.cjs → other-CIQ4hL6N.cjs} +1 -1
- package/dist/{react-dnd-vendor-GZ764FSN.cjs → react-dnd-vendor-D97_L5Fj.cjs} +1 -1
- package/dist/{react-dnd-vendor-DpRaxBS3.js → react-dnd-vendor-cqCcPDYo.js} +2 -2
- package/dist/{react-select-vendor-DAt1SKof.js → react-select-vendor-Dm7JCXQl.js} +1 -1
- package/dist/{react-select-vendor-2_u9DhYj.cjs → react-select-vendor-DpstHMZN.cjs} +1 -1
- package/dist/{services-human-CoaB5w4L.js → services-human-BFuIf4vd.js} +138 -103
- package/dist/{services-human-BelpNNkM.cjs → services-human-BTPVJl80.cjs} +1 -1
- package/dist/services.cjs +1 -1
- package/dist/services.js +61 -70
- package/dist/types.cjs +1 -1
- package/dist/types.js +3 -3
- package/dist/{utils-conversion-CuA6asju.cjs → utils-conversion-DP8LonZS.cjs} +1 -1
- package/dist/{utils-conversion-C9aq8_At.js → utils-conversion-DSzF0R3j.js} +1 -1
- package/dist/utils.cjs +1 -1
- package/dist/utils.js +1 -1
- package/dist/{vendor-Bap2-34A.js → vendor-2NwaL0dE.js} +1 -1
- package/dist/{vendor-BUPEP1f9.cjs → vendor-vQ2gqPbn.cjs} +1 -1
- package/package.json +1 -1
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { axes as x, planes as w, AngleDataSource as l, limbAngle as
|
|
1
|
+
import { axes as x, planes as w, AngleDataSource as l, limbAngle as v, jointAngle as F } from "./types.js";
|
|
2
2
|
import { SensorLocation as n } from "./generated-graphql.js";
|
|
3
|
-
import { r as
|
|
3
|
+
import { r as d } from "./services-rom-omMeC-vQ.js";
|
|
4
4
|
import "./moment-vendor-DMLRxgRE.js";
|
|
5
5
|
import { m as h } from "./utils-memo-DtXdOqCT.js";
|
|
6
|
-
import { c as
|
|
7
|
-
const
|
|
6
|
+
import { c as R } from "./utils-text-CN3zLiZ7.js";
|
|
7
|
+
const s = {
|
|
8
8
|
LeftFoot: "Left Foot",
|
|
9
9
|
RightFoot: "Right Foot",
|
|
10
10
|
LeftShank: "Left Shank",
|
|
@@ -73,25 +73,25 @@ const o = {
|
|
|
73
73
|
RightElbow: ["RightUpperArm", "RightForearm"],
|
|
74
74
|
Neck: ["Head", "UpperBack"]
|
|
75
75
|
}, S = () => [
|
|
76
|
-
{ id: "LeftFoot", name:
|
|
77
|
-
{ id: "RightFoot", name:
|
|
78
|
-
{ id: "LeftShank", name:
|
|
79
|
-
{ id: "RightShank", name:
|
|
80
|
-
{ id: "LeftThigh", name:
|
|
81
|
-
{ id: "RightThigh", name:
|
|
76
|
+
{ id: "LeftFoot", name: s.LeftFoot },
|
|
77
|
+
{ id: "RightFoot", name: s.RightFoot },
|
|
78
|
+
{ id: "LeftShank", name: s.LeftShank },
|
|
79
|
+
{ id: "RightShank", name: s.RightShank },
|
|
80
|
+
{ id: "LeftThigh", name: s.LeftThigh },
|
|
81
|
+
{ id: "RightThigh", name: s.RightThigh },
|
|
82
82
|
// { id: 'LeftPelvis', name: limbNames.LeftPelvis },
|
|
83
83
|
// { id: 'RightPelvis', name: limbNames.RightPelvis },
|
|
84
|
-
{ id: "LowerBack", name:
|
|
85
|
-
{ id: "CenterBack", name:
|
|
86
|
-
{ id: "UpperBack", name:
|
|
87
|
-
{ id: "Head", name:
|
|
84
|
+
{ id: "LowerBack", name: s.LowerBack },
|
|
85
|
+
{ id: "CenterBack", name: s.CenterBack },
|
|
86
|
+
{ id: "UpperBack", name: s.UpperBack },
|
|
87
|
+
{ id: "Head", name: s.Head },
|
|
88
88
|
// { id: 'LeftClavicle', name: limbNames.LeftClavicle },
|
|
89
89
|
// { id: 'RightClavicle', name: limbNames.RightClavicle },
|
|
90
|
-
{ id: "LeftUpperArm", name:
|
|
91
|
-
{ id: "RightUpperArm", name:
|
|
92
|
-
{ id: "LeftForearm", name:
|
|
93
|
-
{ id: "RightForearm", name:
|
|
94
|
-
], ae = (t) => S().filter((e) => t.find((a) => a == e.id)),
|
|
90
|
+
{ id: "LeftUpperArm", name: s.LeftUpperArm },
|
|
91
|
+
{ id: "RightUpperArm", name: s.RightUpperArm },
|
|
92
|
+
{ id: "LeftForearm", name: s.LeftForearm },
|
|
93
|
+
{ id: "RightForearm", name: s.RightForearm }
|
|
94
|
+
], ae = (t) => S().filter((e) => t.find((a) => a == e.id)), b = () => [
|
|
95
95
|
{ id: "LeftAnkle", name: i.LeftAnkle },
|
|
96
96
|
{ id: "RightAnkle", name: i.RightAnkle },
|
|
97
97
|
{ id: "LeftKnee", name: i.LeftKnee },
|
|
@@ -122,7 +122,7 @@ const o = {
|
|
|
122
122
|
// { id: 'LeftElbow', name: jointNames.LeftElbow },
|
|
123
123
|
// { id: 'RightElbow', name: jointNames.RightElbow },
|
|
124
124
|
{ id: "Neck", name: i.Neck }
|
|
125
|
-
],
|
|
125
|
+
], P = () => [
|
|
126
126
|
{ id: "LeftAnkle", name: i.LeftAnkle },
|
|
127
127
|
{ id: "RightAnkle", name: i.RightAnkle },
|
|
128
128
|
{ id: "LeftKnee", name: i.LeftKnee },
|
|
@@ -136,20 +136,20 @@ const o = {
|
|
|
136
136
|
{ id: "RightElbow", name: i.RightElbow },
|
|
137
137
|
{ id: "Neck", name: i.Neck }
|
|
138
138
|
], ne = () => [
|
|
139
|
-
{ id: "Head", name:
|
|
140
|
-
{ id: "LeftThigh", name:
|
|
141
|
-
{ id: "RightThigh", name:
|
|
142
|
-
{ id: "LeftShank", name:
|
|
143
|
-
{ id: "RightShank", name:
|
|
144
|
-
{ id: "LeftFoot", name:
|
|
145
|
-
{ id: "RightFoot", name:
|
|
146
|
-
{ id: "LowerBack", name:
|
|
147
|
-
{ id: "UpperBack", name:
|
|
148
|
-
{ id: "LeftUpperArm", name:
|
|
149
|
-
{ id: "RightUpperArm", name:
|
|
150
|
-
{ id: "LeftForearm", name:
|
|
151
|
-
{ id: "RightForearm", name:
|
|
152
|
-
], ie = (t) => T().filter((a) => k[a.id].every((
|
|
139
|
+
{ id: "Head", name: s.Head },
|
|
140
|
+
{ id: "LeftThigh", name: s.LeftThigh },
|
|
141
|
+
{ id: "RightThigh", name: s.RightThigh },
|
|
142
|
+
{ id: "LeftShank", name: s.LeftShank },
|
|
143
|
+
{ id: "RightShank", name: s.RightShank },
|
|
144
|
+
{ id: "LeftFoot", name: s.LeftFoot },
|
|
145
|
+
{ id: "RightFoot", name: s.RightFoot },
|
|
146
|
+
{ id: "LowerBack", name: s.LowerBack },
|
|
147
|
+
{ id: "UpperBack", name: s.UpperBack },
|
|
148
|
+
{ id: "LeftUpperArm", name: s.LeftUpperArm },
|
|
149
|
+
{ id: "RightUpperArm", name: s.RightUpperArm },
|
|
150
|
+
{ id: "LeftForearm", name: s.LeftForearm },
|
|
151
|
+
{ id: "RightForearm", name: s.RightForearm }
|
|
152
|
+
], ie = (t) => T().filter((a) => k[a.id].every((r) => t.includes(r))), se = (t) => P().filter((a) => k[a.id].every((r) => t.includes(r))), E = (t, e, a) => {
|
|
153
153
|
if (a)
|
|
154
154
|
return ["frontal", "sagittal", "transverse"];
|
|
155
155
|
switch (t) {
|
|
@@ -166,7 +166,7 @@ const o = {
|
|
|
166
166
|
return e && e == l.Pose ? ["sagittal"] : ["frontal", "sagittal", "transverse"];
|
|
167
167
|
}
|
|
168
168
|
return e && e == l.Pose ? ["frontal", "sagittal"] : ["frontal", "sagittal", "transverse"];
|
|
169
|
-
},
|
|
169
|
+
}, H = (t, e) => {
|
|
170
170
|
if (e === l.Sensor)
|
|
171
171
|
return ["frontal", "sagittal", "transverse"];
|
|
172
172
|
switch (t) {
|
|
@@ -189,7 +189,7 @@ const o = {
|
|
|
189
189
|
return ["frontal", "sagittal"];
|
|
190
190
|
}
|
|
191
191
|
return [];
|
|
192
|
-
},
|
|
192
|
+
}, U = h(
|
|
193
193
|
(t, e, a) => {
|
|
194
194
|
switch (t) {
|
|
195
195
|
case "LeftAnkle":
|
|
@@ -309,7 +309,7 @@ const o = {
|
|
|
309
309
|
}
|
|
310
310
|
return null;
|
|
311
311
|
}
|
|
312
|
-
),
|
|
312
|
+
), L = h(
|
|
313
313
|
(t, e, a) => {
|
|
314
314
|
switch (t) {
|
|
315
315
|
case "LowerBack":
|
|
@@ -594,43 +594,43 @@ const o = {
|
|
|
594
594
|
kind: "angular_velocity",
|
|
595
595
|
value: t,
|
|
596
596
|
plane: e
|
|
597
|
-
}), y = (t) => x.includes(t), le = (t) => w.includes(t), $ = (t) => typeof t == "object" && t !== null && "id" in t && "name" in t && !!S().find((e) => e.id === t.id), D = (t) => typeof t == "object" && t !== null && "id" in t && "name" in t && !!
|
|
597
|
+
}), y = (t) => x.includes(t), le = (t) => w.includes(t), $ = (t) => typeof t == "object" && t !== null && "id" in t && "name" in t && !!S().find((e) => e.id === t.id), D = (t) => typeof t == "object" && t !== null && "id" in t && "name" in t && !!b().find((e) => e.id === t.id), he = (t, e, a = !1) => y(e) ? $(t) ? j(t, e) : z(
|
|
598
598
|
`Can't make acceleration part from joint: ${t} ${e}`
|
|
599
|
-
) : D(t) ? a ? J(t, e) : C(t, e) : K(t, e),
|
|
599
|
+
) : D(t) ? a ? J(t, e) : C(t, e) : K(t, e), me = (t) => t.kind === "acceleration" ? t.axis : t.plane, ge = (t) => t?.kind === "acceleration" ? t.axis : null, fe = (t) => t?.kind === "acceleration" ? null : t?.plane ?? null, z = (t) => {
|
|
600
600
|
throw new Error(t);
|
|
601
|
-
},
|
|
601
|
+
}, u = (t) => t in i ? i[t] : t in s ? s[t] : "Unknown", ue = (t) => u(t).replace(/Left|Right/g, ""), _ = (t) => t in d, M = (t, e) => {
|
|
602
602
|
if (!_(t))
|
|
603
603
|
return null;
|
|
604
|
-
const a =
|
|
604
|
+
const a = d[t];
|
|
605
605
|
if (e in a) {
|
|
606
|
-
const { min:
|
|
606
|
+
const { min: o, max: r } = a[e];
|
|
607
607
|
return {
|
|
608
|
-
min:
|
|
609
|
-
max:
|
|
608
|
+
min: o ?? 0,
|
|
609
|
+
max: r ?? 0
|
|
610
610
|
};
|
|
611
611
|
}
|
|
612
612
|
return null;
|
|
613
|
-
},
|
|
614
|
-
const e =
|
|
613
|
+
}, Le = (...t) => {
|
|
614
|
+
const e = M(...t);
|
|
615
615
|
return e ? Math.abs(e.max - e.min) : 0;
|
|
616
|
-
},
|
|
617
|
-
const a = Object.keys(
|
|
618
|
-
return !a && !
|
|
619
|
-
}, Le = (t, e, a) => {
|
|
620
|
-
const r = Object.keys(i).find((c) => c === e), s = I(t, e);
|
|
621
|
-
return s ? r ? U(e, s).includes(a) : P(e, s).includes(a) : !1;
|
|
616
|
+
}, W = (t, e) => {
|
|
617
|
+
const a = Object.keys(s).find((r) => r === e), o = Object.keys(i).find((r) => r === e);
|
|
618
|
+
return !a && !o ? null : a ? t.limbs[e].sensor_angle ? l.Sensor : l.Pose : t.joints[e].sensor_angle ? l.Sensor : l.Pose;
|
|
622
619
|
}, Re = (t, e, a) => {
|
|
623
|
-
const
|
|
624
|
-
|
|
620
|
+
const o = Object.keys(i).find((c) => c === e), r = W(t, e);
|
|
621
|
+
return r ? o ? E(e, r).includes(a) : H(e, r).includes(a) : !1;
|
|
622
|
+
}, pe = (t, e, a) => {
|
|
623
|
+
const o = Object.keys(s).find((c) => c === e), r = Object.keys(i).find((c) => c === e);
|
|
624
|
+
if (!o && !r)
|
|
625
625
|
throw new Error(
|
|
626
626
|
`Unknown partId: ${e} - this invariant should've been enforced by typescript`
|
|
627
627
|
);
|
|
628
|
-
return
|
|
628
|
+
return o ? v(t.limbs[e])?.[a] ?? null : F(
|
|
629
629
|
t.joints[e],
|
|
630
630
|
void 0,
|
|
631
631
|
t.direction
|
|
632
632
|
)?.[a] ?? null;
|
|
633
|
-
},
|
|
633
|
+
}, f = (t = !1) => t ? "Internal/External Rotation" : "External/Internal Rotation", I = (t, e, a = !1) => {
|
|
634
634
|
switch (t) {
|
|
635
635
|
case "LeftAnkle":
|
|
636
636
|
case "RightAnkle":
|
|
@@ -640,7 +640,7 @@ const o = {
|
|
|
640
640
|
case "sagittal":
|
|
641
641
|
return a ? "Plantar/Dorsi Flexion" : "Dorsi/Plantar Flexion";
|
|
642
642
|
case "transverse":
|
|
643
|
-
return
|
|
643
|
+
return f(a);
|
|
644
644
|
}
|
|
645
645
|
case "LeftKnee":
|
|
646
646
|
case "RightKnee":
|
|
@@ -650,7 +650,7 @@ const o = {
|
|
|
650
650
|
case "sagittal":
|
|
651
651
|
return a ? "Extension/Flexion" : "Flexion/Extension";
|
|
652
652
|
case "transverse":
|
|
653
|
-
return
|
|
653
|
+
return f(a);
|
|
654
654
|
}
|
|
655
655
|
case "LeftHip":
|
|
656
656
|
case "RightHip":
|
|
@@ -660,7 +660,7 @@ const o = {
|
|
|
660
660
|
case "sagittal":
|
|
661
661
|
return a ? "Extension/Flexion" : "Flexion/Extension";
|
|
662
662
|
case "transverse":
|
|
663
|
-
return
|
|
663
|
+
return f(a);
|
|
664
664
|
}
|
|
665
665
|
case "NavalSpine":
|
|
666
666
|
case "ChestSpine":
|
|
@@ -682,7 +682,7 @@ const o = {
|
|
|
682
682
|
case "sagittal":
|
|
683
683
|
return a ? "Extension/Flexion" : "Flexion/Extension";
|
|
684
684
|
case "transverse":
|
|
685
|
-
return
|
|
685
|
+
return f(a);
|
|
686
686
|
}
|
|
687
687
|
case "LeftElbow":
|
|
688
688
|
case "RightElbow":
|
|
@@ -696,13 +696,13 @@ const o = {
|
|
|
696
696
|
}
|
|
697
697
|
}
|
|
698
698
|
}, O = (t, e, a = !1) => {
|
|
699
|
-
const
|
|
700
|
-
if (
|
|
701
|
-
const
|
|
702
|
-
return `${
|
|
699
|
+
const o = u(t), r = L(t, e, 1), c = L(t, e, -1);
|
|
700
|
+
if (r && c) {
|
|
701
|
+
const m = R(r), g = R(c), A = a ? `${g}/${m}` : `${m}/${g}`;
|
|
702
|
+
return `${o} (${A})`;
|
|
703
703
|
}
|
|
704
|
-
return `${
|
|
705
|
-
},
|
|
704
|
+
return `${o} (${e})`;
|
|
705
|
+
}, de = (t, e) => {
|
|
706
706
|
let a;
|
|
707
707
|
switch (e) {
|
|
708
708
|
case "x":
|
|
@@ -714,43 +714,78 @@ const o = {
|
|
|
714
714
|
case "z":
|
|
715
715
|
a = "Ant./Post.";
|
|
716
716
|
}
|
|
717
|
-
return `${
|
|
717
|
+
return `${u(t)} ${a}`;
|
|
718
718
|
}, V = (t, e, a = !1) => {
|
|
719
|
-
const
|
|
720
|
-
return
|
|
721
|
-
}, ke = (t, e) => V(t, e) || O(t, e),
|
|
722
|
-
const
|
|
723
|
-
|
|
724
|
-
|
|
719
|
+
const o = u(t), r = I(t, e, a);
|
|
720
|
+
return r ? `${o} (${r})` : null;
|
|
721
|
+
}, ke = (t, e) => V(t, e) || O(t, e), p = (t, e, a, o = !1) => {
|
|
722
|
+
const r = o ? B : U, c = o ? N : L, [m, g] = t === "joint" ? [
|
|
723
|
+
r(e, a, 1),
|
|
724
|
+
r(e, a, -1)
|
|
725
725
|
] : [
|
|
726
726
|
c(e, a, 1),
|
|
727
727
|
c(e, a, -1)
|
|
728
728
|
];
|
|
729
729
|
return {
|
|
730
|
-
positive:
|
|
731
|
-
negative:
|
|
730
|
+
positive: m,
|
|
731
|
+
negative: g
|
|
732
732
|
};
|
|
733
|
-
}, q = (t, e = !1) => t.partKind === "joint" ?
|
|
733
|
+
}, q = (t, e = !1) => t.partKind === "joint" ? p(
|
|
734
734
|
"joint",
|
|
735
735
|
t.partId,
|
|
736
736
|
t.partDimension,
|
|
737
737
|
e
|
|
738
|
-
) :
|
|
738
|
+
) : p(
|
|
739
739
|
"segment",
|
|
740
740
|
t.partId,
|
|
741
741
|
t.partDimension,
|
|
742
742
|
e
|
|
743
743
|
), Se = (t, e, a = !1) => {
|
|
744
|
-
const { positive:
|
|
744
|
+
const { positive: o, negative: r } = q(
|
|
745
745
|
e,
|
|
746
746
|
a
|
|
747
747
|
);
|
|
748
|
-
return t >= 0 ?
|
|
748
|
+
return t >= 0 ? o : r;
|
|
749
749
|
}, Ae = (t) => {
|
|
750
|
-
const e = /* @__PURE__ */ new Set()
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
750
|
+
const e = /* @__PURE__ */ new Set(), a = {
|
|
751
|
+
// Joints
|
|
752
|
+
LeftAnkle: [n.LeftShank, n.LeftFoot],
|
|
753
|
+
RightAnkle: [n.RightShank, n.RightFoot],
|
|
754
|
+
LeftKnee: [n.LeftThigh, n.LeftShank],
|
|
755
|
+
RightKnee: [n.RightThigh, n.RightShank],
|
|
756
|
+
LeftHip: [n.Pelvis, n.LeftThigh],
|
|
757
|
+
RightHip: [n.Pelvis, n.RightThigh],
|
|
758
|
+
LeftShoulder: [n.Thorax, n.LeftUpperArm],
|
|
759
|
+
RightShoulder: [n.Thorax, n.RightUpperArm],
|
|
760
|
+
LeftElbow: [n.LeftUpperArm, n.LeftForearm],
|
|
761
|
+
RightElbow: [n.RightUpperArm, n.RightForearm],
|
|
762
|
+
ChestSpine: [n.Thorax, n.Pelvis],
|
|
763
|
+
NavalSpine: [n.Thorax, n.Pelvis],
|
|
764
|
+
TotalSpine: [n.Thorax, n.Pelvis],
|
|
765
|
+
Neck: [n.Head],
|
|
766
|
+
// Limbs
|
|
767
|
+
Head: [n.Head],
|
|
768
|
+
UpperBack: [n.CenterBack, n.Pelvis],
|
|
769
|
+
CenterBack: [n.CenterBack, n.Pelvis],
|
|
770
|
+
LowerBack: [n.Pelvis],
|
|
771
|
+
LeftThigh: [n.LeftThigh],
|
|
772
|
+
RightThigh: [n.RightThigh],
|
|
773
|
+
LeftShank: [n.LeftShank],
|
|
774
|
+
RightShank: [n.RightShank],
|
|
775
|
+
LeftFoot: [n.LeftFoot],
|
|
776
|
+
RightFoot: [n.RightFoot],
|
|
777
|
+
LeftUpperArm: [n.LeftUpperArm],
|
|
778
|
+
RightUpperArm: [n.RightUpperArm],
|
|
779
|
+
LeftForearm: [n.LeftForearm],
|
|
780
|
+
RightForearm: [n.RightForearm],
|
|
781
|
+
LeftPelvis: [n.Pelvis],
|
|
782
|
+
RightPelvis: [n.Pelvis],
|
|
783
|
+
LeftClavicle: [n.Thorax],
|
|
784
|
+
RightClavicle: [n.Thorax]
|
|
785
|
+
};
|
|
786
|
+
return t.forEach((o) => {
|
|
787
|
+
const r = a[o];
|
|
788
|
+
r && r.forEach((c) => e.add(c));
|
|
754
789
|
}), Array.from(e);
|
|
755
790
|
};
|
|
756
791
|
export {
|
|
@@ -762,37 +797,37 @@ export {
|
|
|
762
797
|
$ as F,
|
|
763
798
|
D as G,
|
|
764
799
|
he as H,
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
800
|
+
me as I,
|
|
801
|
+
ge as J,
|
|
802
|
+
fe as K,
|
|
803
|
+
ue as L,
|
|
804
|
+
M,
|
|
805
|
+
Le as N,
|
|
806
|
+
W as O,
|
|
807
|
+
Re as P,
|
|
808
|
+
pe as Q,
|
|
809
|
+
I as R,
|
|
810
|
+
de as S,
|
|
776
811
|
ke as T,
|
|
777
|
-
|
|
812
|
+
p as U,
|
|
778
813
|
q as V,
|
|
779
814
|
Se as W,
|
|
780
815
|
V as a,
|
|
781
|
-
|
|
782
|
-
|
|
816
|
+
U as b,
|
|
817
|
+
L as c,
|
|
783
818
|
ce as d,
|
|
784
|
-
|
|
819
|
+
u as e,
|
|
785
820
|
Ae as f,
|
|
786
821
|
O as g,
|
|
787
|
-
|
|
822
|
+
E as h,
|
|
788
823
|
re as i,
|
|
789
824
|
S as j,
|
|
790
|
-
|
|
825
|
+
H as k,
|
|
791
826
|
oe as l,
|
|
792
|
-
|
|
793
|
-
|
|
827
|
+
P as m,
|
|
828
|
+
b as n,
|
|
794
829
|
k as o,
|
|
795
|
-
|
|
830
|
+
s as p,
|
|
796
831
|
i as q,
|
|
797
832
|
te as r,
|
|
798
833
|
ae as s,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const l=require("./types.cjs"),a=require("./generated-graphql.cjs"),A=require("./services-rom-DmV5X8yu.cjs");require("./moment-vendor-1cRqq0AH.cjs");const h=require("./utils-memo-BJJP2KfI.cjs"),p=require("./utils-text-lORqO4uI.cjs"),s={LeftFoot:"Left Foot",RightFoot:"Right Foot",LeftShank:"Left Shank",RightShank:"Right Shank",LeftThigh:"Left Thigh",RightThigh:"Right Thigh",LeftPelvis:"Left Pelvis",RightPelvis:"Right Pelvis",LowerBack:"Pelvis",CenterBack:"Center Back",UpperBack:"Thorax",Head:"Head",LeftClavicle:"Left Clavicle",RightClavicle:"Right Clavicle",LeftUpperArm:"Left Upper Arm",RightUpperArm:"Right Upper Arm",LeftForearm:"Left Forearm",RightForearm:"Right Forearm"},i={LeftAnkle:"Left Ankle",RightAnkle:"Right Ankle",LeftKnee:"Left Knee",RightKnee:"Right Knee",LeftHip:"Left Hip",RightHip:"Right Hip",NavalSpine:"Lower Back",ChestSpine:"Upper Back",TotalSpine:"Total Spine",LeftShoulder:"Left Shoulder",RightShoulder:"Right Shoulder",LeftElbow:"Left Elbow",RightElbow:"Right Elbow",Neck:"Neck"},I={LeftFoot:["LeftAnkle"],RightFoot:["RightAnkle"],LeftShank:["LeftKnee","LeftAnkle"],RightShank:["RightKnee","RightAnkle"],LeftThigh:["LeftHip","LeftKnee"],RightThigh:["RightHip","RightKnee"],LeftPelvis:["LeftHip"],RightPelvis:["RightHip"],LowerBack:["LeftHip","RightHip","NavalSpine","TotalSpine"],CenterBack:["NavalSpine","ChestSpine"],UpperBack:["ChestSpine","TotalSpine"],Head:["Neck"],LeftClavicle:["LeftShoulder"],RightClavicle:["RightShoulder"],LeftUpperArm:["LeftShoulder","LeftElbow"],RightUpperArm:["RightShoulder","RightElbow"],LeftForearm:["LeftElbow"],RightForearm:["RightElbow"]},R={LeftAnkle:["LeftFoot","LeftShank"],RightAnkle:["RightFoot","RightShank"],LeftKnee:["LeftShank","LeftThigh"],RightKnee:["RightShank","RightThigh"],LeftHip:["LeftThigh","LowerBack"],RightHip:["RightThigh","LowerBack"],NavalSpine:["LowerBack","CenterBack"],ChestSpine:["CenterBack","UpperBack"],TotalSpine:["UpperBack","LowerBack"],LeftShoulder:["LeftClavicle","LeftUpperArm"],RightShoulder:["RightClavicle","RightUpperArm"],LeftElbow:["LeftUpperArm","LeftForearm"],RightElbow:["RightUpperArm","RightForearm"],Neck:["Head","UpperBack"]},S=()=>[{id:"LeftFoot",name:s.LeftFoot},{id:"RightFoot",name:s.RightFoot},{id:"LeftShank",name:s.LeftShank},{id:"RightShank",name:s.RightShank},{id:"LeftThigh",name:s.LeftThigh},{id:"RightThigh",name:s.RightThigh},{id:"LowerBack",name:s.LowerBack},{id:"CenterBack",name:s.CenterBack},{id:"UpperBack",name:s.UpperBack},{id:"Head",name:s.Head},{id:"LeftUpperArm",name:s.LeftUpperArm},{id:"RightUpperArm",name:s.RightUpperArm},{id:"LeftForearm",name:s.LeftForearm},{id:"RightForearm",name:s.RightForearm}],W=t=>S().filter(e=>t.find(n=>n==e.id)),k=()=>[{id:"LeftAnkle",name:i.LeftAnkle},{id:"RightAnkle",name:i.RightAnkle},{id:"LeftKnee",name:i.LeftKnee},{id:"RightKnee",name:i.RightKnee},{id:"LeftHip",name:i.LeftHip},{id:"RightHip",name:i.RightHip},{id:"NavalSpine",name:i.NavalSpine},{id:"ChestSpine",name:i.ChestSpine},{id:"TotalSpine",name:i.TotalSpine},{id:"LeftShoulder",name:i.LeftShoulder},{id:"RightShoulder",name:i.RightShoulder},{id:"LeftElbow",name:i.LeftElbow},{id:"RightElbow",name:i.RightElbow},{id:"Neck",name:i.Neck}],x=()=>[{id:"LeftAnkle",name:i.LeftAnkle},{id:"RightAnkle",name:i.RightAnkle},{id:"LeftKnee",name:i.LeftKnee},{id:"RightKnee",name:i.RightKnee},{id:"LeftHip",name:i.LeftHip},{id:"RightHip",name:i.RightHip},{id:"NavalSpine",name:i.NavalSpine},{id:"ChestSpine",name:i.ChestSpine},{id:"TotalSpine",name:i.TotalSpine},{id:"LeftShoulder",name:i.LeftShoulder},{id:"RightShoulder",name:i.RightShoulder},{id:"Neck",name:i.Neck}],b=()=>[{id:"LeftAnkle",name:i.LeftAnkle},{id:"RightAnkle",name:i.RightAnkle},{id:"LeftKnee",name:i.LeftKnee},{id:"RightKnee",name:i.RightKnee},{id:"LeftHip",name:i.LeftHip},{id:"RightHip",name:i.RightHip},{id:"TotalSpine",name:i.TotalSpine},{id:"LeftShoulder",name:i.LeftShoulder},{id:"RightShoulder",name:i.RightShoulder},{id:"LeftElbow",name:i.LeftElbow},{id:"RightElbow",name:i.RightElbow},{id:"Neck",name:i.Neck}],_=()=>[{id:"Head",name:s.Head},{id:"LeftThigh",name:s.LeftThigh},{id:"RightThigh",name:s.RightThigh},{id:"LeftShank",name:s.LeftShank},{id:"RightShank",name:s.RightShank},{id:"LeftFoot",name:s.LeftFoot},{id:"RightFoot",name:s.RightFoot},{id:"LowerBack",name:s.LowerBack},{id:"UpperBack",name:s.UpperBack},{id:"LeftUpperArm",name:s.LeftUpperArm},{id:"RightUpperArm",name:s.RightUpperArm},{id:"LeftForearm",name:s.LeftForearm},{id:"RightForearm",name:s.RightForearm}],O=t=>x().filter(n=>R[n.id].every(r=>t.includes(r))),M=t=>b().filter(n=>R[n.id].every(r=>t.includes(r))),w=(t,e,n)=>{if(n)return["frontal","sagittal","transverse"];switch(t){case"LeftKnee":case"RightKnee":return["sagittal"];case"LeftAnkle":case"RightAnkle":return e&&e==l.AngleDataSource.Pose?["sagittal"]:["frontal","sagittal"];case"TotalSpine":return e&&e==l.AngleDataSource.Pose?["frontal"]:["frontal","sagittal","transverse"];case"LeftElbow":case"RightElbow":return e&&e==l.AngleDataSource.Pose?["sagittal"]:["frontal","sagittal","transverse"]}return e&&e==l.AngleDataSource.Pose?["frontal","sagittal"]:["frontal","sagittal","transverse"]},F=(t,e)=>{if(e===l.AngleDataSource.Sensor)return["frontal","sagittal","transverse"];switch(t){case"Head":case"LeftThigh":case"RightThigh":case"LeftShank":case"RightShank":case"LeftUpperArm":case"RightUpperArm":case"LeftForearm":case"RightForearm":return["frontal","sagittal"];case"LeftFoot":case"RightFoot":return["sagittal"];case"LowerBack":return["frontal"];case"UpperBack":return["frontal","sagittal"]}return[]},v=h.memo((t,e,n)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return n<0?"inversion":"eversion";case"sagittal":return n<0?"plantar flexion":"dorsi flexion";case"transverse":return n<0?"internal rotation":"external rotation"}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return n<0?"adduction":"abduction";case"sagittal":return n<0?"extension":"flexion";case"transverse":return n<0?"internal rotation":"external rotation"}case"LeftHip":case"RightHip":case"LeftShoulder":case"RightShoulder":switch(e){case"frontal":return n<0?"adduction":"abduction";case"sagittal":return n<0?"extension":"flexion";case"transverse":return n<0?"internal rotation":"external rotation"}case"NavalSpine":case"ChestSpine":case"TotalSpine":case"Neck":switch(e){case"frontal":return n<0?"right lateral flexion":"left lateral flexion";case"sagittal":return n<0?"extension":"flexion";case"transverse":return n<0?"right rotation":"left rotation"}case"LeftElbow":case"RightElbow":switch(e){case"frontal":return null;case"sagittal":return n<0?"extension":"flexion";case"transverse":return n<0?"pronation":"supination"}}return null}),P=h.memo((t,e,n)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return n<0?"Inv.":"Ev.";case"sagittal":return n<0?"PF.":"DF.";case"transverse":return n<0?"IR.":"ER."}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return n<0?"Add.":"Abd.";case"sagittal":return n<0?"Ext.":"Flex.";case"transverse":return n<0?"IR.":"ER."}case"LeftHip":case"RightHip":case"LeftShoulder":case"RightShoulder":switch(e){case"frontal":return n<0?"Add.":"Abd.";case"sagittal":return n<0?"Ext.":"Flex.";case"transverse":return n<0?"IR.":"ER."}case"NavalSpine":case"ChestSpine":case"TotalSpine":case"Neck":switch(e){case"frontal":return n<0?"R. Bend":"L. Bend";case"sagittal":return n<0?"Ext.":"Flex.";case"transverse":return n<0?"R. Rot.":"L. Rot."}case"LeftElbow":case"RightElbow":switch(e){case"frontal":return null;case"sagittal":return n<0?"Ext.":"Flex.";case"transverse":return n<0?"Pro.":"Sup."}}return null}),d=h.memo((t,e,n)=>{switch(t){case"LowerBack":case"LeftPelvis":case"RightPelvis":switch(e){case"frontal":return n<0?"right drop":"left drop";case"sagittal":return n<0?"anterior tilt":"posterior tilt";case"transverse":return n<0?"right rotation":"left rotation"}case"Head":case"UpperBack":case"CenterBack":case"LeftShank":case"RightShank":case"LeftThigh":case"RightThigh":case"LeftFoot":case"RightFoot":case"LeftUpperArm":case"RightUpperArm":case"LeftForearm":case"RightForearm":switch(e){case"frontal":return n<0?"right tilt":"left tilt";case"sagittal":return n<0?"anterior tilt":"posterior tilt";case"transverse":return n<0?"right rotation":"left rotation"}default:return null}}),T=h.memo((t,e,n)=>{switch(t){case"LowerBack":case"LeftPelvis":case"RightPelvis":switch(e){case"frontal":return n<0?"R. Drop":"L. Drop";case"sagittal":return n<0?"Ant. Tilt":"Pos. Tilt";case"transverse":return n<0?"R. Rot.":"L. Rot."}case"Head":case"UpperBack":case"CenterBack":case"LeftShank":case"RightShank":case"LeftThigh":case"RightThigh":case"LeftFoot":case"RightFoot":case"LeftUpperArm":case"RightUpperArm":case"LeftForearm":case"RightForearm":switch(e){case"frontal":return n<0?"R. Tilt":"L. Tilt";case"sagittal":return n<0?"Ant. Tilt":"Pos. Tilt";case"transverse":return n<0?"R. Rot.":"L. Rot."}default:return null}}),V=h.memo((t,e)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return{min:-20,max:20};case"sagittal":return{min:-30,max:30};case"transverse":return{min:-5,max:5}}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return{min:-5,max:5};case"sagittal":return{min:-5,max:90};case"transverse":return{min:-5,max:5}}case"LeftHip":case"RightHip":return{min:-30,max:30};case"LeftShoulder":case"RightShoulder":return{min:-50,max:50};case"NavalSpine":case"ChestSpine":case"TotalSpine":case"Neck":switch(e){case"frontal":return{min:-5,max:5};case"sagittal":return{min:-5,max:5};case"transverse":return{min:-5,max:5}}case"LeftElbow":case"RightElbow":switch(e){case"frontal":return{min:-5,max:5};case"sagittal":return{min:-5,max:50};case"transverse":return{min:-5,max:5}}}return{min:-10,max:10}}),X=h.memo((t,e)=>{switch(t){case"LeftFoot":case"RightFoot":switch(e){case"frontal":return{min:-20,max:20};case"sagittal":return{min:-30,max:30};case"transverse":return{min:-5,max:5}}case"LeftShank":case"RightShank":switch(e){case"frontal":return{min:-35,max:35};case"sagittal":return{min:-35,max:35};case"transverse":return{min:-5,max:5}}case"LeftThigh":case"RightThigh":switch(e){case"frontal":return{min:-35,max:35};case"sagittal":return{min:-35,max:35};case"transverse":return{min:-10,max:5}}case"LeftPelvis":case"RightPelvis":switch(e){case"frontal":return{min:-15,max:15};case"sagittal":return{min:-10,max:10};case"transverse":return{min:-10,max:10}}case"LowerBack":case"CenterBack":case"UpperBack":case"Head":return{min:-5,max:5};case"LeftClavicle":case"RightClavicle":switch(e){case"frontal":return{min:-15,max:15};case"sagittal":return{min:-10,max:10};case"transverse":return{min:-10,max:10}}case"LeftUpperArm":case"RightUpperArm":case"LeftForearm":case"RightForearm":switch(e){case"frontal":return{min:-45,max:45};case"sagittal":return{min:-45,max:45};case"transverse":return{min:-20,max:20}}}return{min:-10,max:10}}),G=h.memo((t,e)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return{min:-40,max:30};case"sagittal":return{min:-80,max:50};case"transverse":return{min:-90,max:90}}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return{min:-15,max:5};case"sagittal":return{min:-10,max:160};case"transverse":return{min:-35,max:45}}case"LeftHip":case"RightHip":switch(e){case"frontal":return{min:-50,max:60};case"sagittal":return{min:-50,max:150};case"transverse":return{min:-60,max:70}}case"TotalSpine":switch(e){case"frontal":return{min:-60,max:60};case"sagittal":return{min:-50,max:150};case"transverse":return{min:-50,max:50}}case"ChestSpine":switch(e){case"frontal":return{min:-25,max:25};case"sagittal":return{min:-25,max:40};case"transverse":return{min:-35,max:35}}case"NavalSpine":switch(e){case"frontal":return{min:-25,max:25};case"sagittal":return{min:-35,max:60};case"transverse":return{min:-15,max:15}}default:return{min:-180,max:180}}}),N=(t,e)=>({kind:"joint",value:t,plane:e}),E=(t,e)=>({kind:"limb",value:t,plane:e}),U=(t,e)=>({kind:"acceleration",value:t,axis:e}),H=(t,e)=>({kind:"angular_velocity",value:t,plane:e}),B=t=>l.axes.includes(t),Q=t=>l.planes.includes(t),C=t=>typeof t=="object"&&t!==null&&"id"in t&&"name"in t&&!!S().find(e=>e.id===t.id),J=t=>typeof t=="object"&&t!==null&&"id"in t&&"name"in t&&!!k().find(e=>e.id===t.id),Y=(t,e,n=!1)=>B(e)?C(t)?U(t,e):ne(`Can't make acceleration part from joint: ${t} ${e}`):J(t)?n?H(t,e):N(t,e):E(t,e),Z=t=>t.kind==="acceleration"?t.axis:t.plane,ee=t=>t?.kind==="acceleration"?t.axis:null,te=t=>t?.kind==="acceleration"?null:t?.plane??null,ne=t=>{throw new Error(t)},g=t=>t in i?i[t]:t in s?s[t]:"Unknown",ae=t=>g(t).replace(/Left|Right/g,""),ie=t=>t in A.romJson,K=(t,e)=>{if(!ie(t))return null;const n=A.romJson[t];if(e in n){const{min:o,max:r}=n[e];return{min:o??0,max:r??0}}return null},re=(...t)=>{const e=K(...t);return e?Math.abs(e.max-e.min):0},D=(t,e)=>{const n=Object.keys(s).find(r=>r===e),o=Object.keys(i).find(r=>r===e);return!n&&!o?null:n?t.limbs[e].sensor_angle?l.AngleDataSource.Sensor:l.AngleDataSource.Pose:t.joints[e].sensor_angle?l.AngleDataSource.Sensor:l.AngleDataSource.Pose},se=(t,e,n)=>{const o=Object.keys(i).find(c=>c===e),r=D(t,e);return r?o?w(e,r).includes(n):F(e,r).includes(n):!1},oe=(t,e,n)=>{const o=Object.keys(s).find(c=>c===e),r=Object.keys(i).find(c=>c===e);if(!o&&!r)throw new Error(`Unknown partId: ${e} - this invariant should've been enforced by typescript`);return o?l.limbAngle(t.limbs[e])?.[n]??null:l.jointAngle(t.joints[e],void 0,t.direction)?.[n]??null},L=(t=!1)=>t?"Internal/External Rotation":"External/Internal Rotation",j=(t,e,n=!1)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return n?"Inversion/Eversion":"Eversion/Inversion";case"sagittal":return n?"Plantar/Dorsi Flexion":"Dorsi/Plantar Flexion";case"transverse":return L(n)}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return n?"Adduction/Abduction":"Abduction/Adduction";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return L(n)}case"LeftHip":case"RightHip":switch(e){case"frontal":return n?"Adduction/Abduction":"Abduction/Adduction";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return L(n)}case"NavalSpine":case"ChestSpine":case"TotalSpine":case"Neck":switch(e){case"frontal":return"Lateral Bend";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return"Rotation"}case"LeftShoulder":case"RightShoulder":switch(e){case"frontal":return n?"Adduction/Abduction":"Abduction/Adduction";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return L(n)}case"LeftElbow":case"RightElbow":switch(e){case"frontal":return n?"Adduction/Abduction":"Abduction/Adduction";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return n?"Pronation/Supination":"Supination/Pronation"}}},y=(t,e,n=!1)=>{const o=g(t),r=d(t,e,1),c=d(t,e,-1);if(r&&c){const m=p.capitalizeAll(r),f=p.capitalizeAll(c),z=n?`${f}/${m}`:`${m}/${f}`;return`${o} (${z})`}return`${o} (${e})`},ce=(t,e)=>{let n;switch(e){case"x":n="Med./Lat.";break;case"y":n="Vertical";break;case"z":n="Ant./Post."}return`${g(t)} ${n}`},$=(t,e,n=!1)=>{const o=g(t),r=j(t,e,n);return r?`${o} (${r})`:null},le=(t,e)=>$(t,e)||y(t,e),u=(t,e,n,o=!1)=>{const r=o?P:v,c=o?T:d,[m,f]=t==="joint"?[r(e,n,1),r(e,n,-1)]:[c(e,n,1),c(e,n,-1)];return{positive:m,negative:f}},q=(t,e=!1)=>t.partKind==="joint"?u("joint",t.partId,t.partDimension,e):u("segment",t.partId,t.partDimension,e),he=(t,e,n=!1)=>{const{positive:o,negative:r}=q(e,n);return t>=0?o:r},ge=t=>{const e=new Set;return t.forEach(n=>{const o=n.includes("Left"),r=n.includes("Right");n.includes("Knee")?o?(e.add(a.SensorLocation.LeftThigh),e.add(a.SensorLocation.LeftShank)):r?(e.add(a.SensorLocation.RightThigh),e.add(a.SensorLocation.RightShank)):(e.add(a.SensorLocation.LeftThigh),e.add(a.SensorLocation.RightThigh),e.add(a.SensorLocation.LeftShank),e.add(a.SensorLocation.RightShank)):n.includes("Hip")?(e.add(a.SensorLocation.Pelvis),o?e.add(a.SensorLocation.LeftThigh):(r||e.add(a.SensorLocation.LeftThigh),e.add(a.SensorLocation.RightThigh))):n.includes("Ankle")?o?(e.add(a.SensorLocation.LeftShank),e.add(a.SensorLocation.LeftFoot)):r?(e.add(a.SensorLocation.RightShank),e.add(a.SensorLocation.RightFoot)):(e.add(a.SensorLocation.LeftShank),e.add(a.SensorLocation.RightShank),e.add(a.SensorLocation.LeftFoot),e.add(a.SensorLocation.RightFoot)):n.includes("Shoulder")?(e.add(a.SensorLocation.Thorax),o?e.add(a.SensorLocation.LeftUpperArm):(r||e.add(a.SensorLocation.LeftUpperArm),e.add(a.SensorLocation.RightUpperArm))):n.includes("Elbow")?o?(e.add(a.SensorLocation.LeftUpperArm),e.add(a.SensorLocation.LeftForearm)):r?(e.add(a.SensorLocation.RightUpperArm),e.add(a.SensorLocation.RightForearm)):(e.add(a.SensorLocation.LeftUpperArm),e.add(a.SensorLocation.RightUpperArm),e.add(a.SensorLocation.LeftForearm),e.add(a.SensorLocation.RightForearm)):(n.includes("Neck")||n.includes("Head"))&&e.add(a.SensorLocation.Head),n.includes("Thigh")?o?e.add(a.SensorLocation.LeftThigh):(r||e.add(a.SensorLocation.LeftThigh),e.add(a.SensorLocation.RightThigh)):n.includes("Shank")?o?e.add(a.SensorLocation.LeftShank):(r||e.add(a.SensorLocation.LeftShank),e.add(a.SensorLocation.RightShank)):n.includes("Foot")?o?e.add(a.SensorLocation.LeftFoot):(r||e.add(a.SensorLocation.LeftFoot),e.add(a.SensorLocation.RightFoot)):n.includes("UpperArm")?o?e.add(a.SensorLocation.LeftUpperArm):(r||e.add(a.SensorLocation.LeftUpperArm),e.add(a.SensorLocation.RightUpperArm)):n.includes("Forearm")?o?e.add(a.SensorLocation.LeftForearm):(r||e.add(a.SensorLocation.LeftForearm),e.add(a.SensorLocation.RightForearm)):n.includes("Spine")?(e.add(a.SensorLocation.Thorax),e.add(a.SensorLocation.Pelvis)):n.includes("UpperBack")||n.includes("CenterBack")?(e.add(a.SensorLocation.CenterBack),e.add(a.SensorLocation.Pelvis)):n.includes("LowerBack")&&e.add(a.SensorLocation.Pelvis)}),Array.from(e)};exports.getAllAvailableJoints=k;exports.getAllAvailableLimbs=S;exports.getAllAvailablePoseJoints=b;exports.getAllAvailablePoseLimbs=_;exports.getAllAvailableSensorJoints=x;exports.getAngleDirectionNames=u;exports.getAvailableLimbsForLimbIds=W;exports.getAvailablePoseJointsForLimbIds=M;exports.getAvailableSensorJointsForLimbIds=O;exports.getAxis=ee;exports.getDefaultAngleSource=D;exports.getDefaultJointRange=V;exports.getDefaultLimbRange=X;exports.getEnabledJointPlanes=w;exports.getEnabledSegmentPlanes=F;exports.getHumanBodyAngle=oe;exports.getIsDefaultAngleAllowed=se;exports.getJointAngleDirectionAbbr=P;exports.getJointAngleDirectionName=v;exports.getJointNameWithPlane=$;exports.getJointOrSegmentNameWithPlane=le;exports.getJointPlaneName=j;exports.getNormativeJointRange=G;exports.getParameterAngleDirectionName=he;exports.getParameterDirectionNames=q;exports.getPartName=g;exports.getPartNameNoSide=ae;exports.getPlane=te;exports.getSegmentAngleDirectionAbbr=T;exports.getSegmentAngleDirectionName=d;exports.getSegmentNameWithPlane=y;exports.getSegmentXyzName=ce;exports.getSuggestedSensorLocations=ge;exports.getTypicalRom=K;exports.getTypicalRomSize=re;exports.isAxis=B;exports.isJoint=J;exports.isLimb=C;exports.isPlane=Q;exports.jointNames=i;exports.jointsUsedByLimbs=I;exports.limbNames=s;exports.limbsRequiredForJoints=R;exports.mkAccelerationPart=U;exports.mkAngularVelocityPart=H;exports.mkHumanPart=Y;exports.mkJointPart=N;exports.mkLimbPart=E;exports.planeOrAxis=Z;
|
|
1
|
+
"use strict";const l=require("./types.cjs"),a=require("./generated-graphql.cjs"),A=require("./services-rom-DmV5X8yu.cjs");require("./moment-vendor-1cRqq0AH.cjs");const h=require("./utils-memo-BJJP2KfI.cjs"),d=require("./utils-text-lORqO4uI.cjs"),r={LeftFoot:"Left Foot",RightFoot:"Right Foot",LeftShank:"Left Shank",RightShank:"Right Shank",LeftThigh:"Left Thigh",RightThigh:"Right Thigh",LeftPelvis:"Left Pelvis",RightPelvis:"Right Pelvis",LowerBack:"Pelvis",CenterBack:"Center Back",UpperBack:"Thorax",Head:"Head",LeftClavicle:"Left Clavicle",RightClavicle:"Right Clavicle",LeftUpperArm:"Left Upper Arm",RightUpperArm:"Right Upper Arm",LeftForearm:"Left Forearm",RightForearm:"Right Forearm"},i={LeftAnkle:"Left Ankle",RightAnkle:"Right Ankle",LeftKnee:"Left Knee",RightKnee:"Right Knee",LeftHip:"Left Hip",RightHip:"Right Hip",NavalSpine:"Lower Back",ChestSpine:"Upper Back",TotalSpine:"Total Spine",LeftShoulder:"Left Shoulder",RightShoulder:"Right Shoulder",LeftElbow:"Left Elbow",RightElbow:"Right Elbow",Neck:"Neck"},I={LeftFoot:["LeftAnkle"],RightFoot:["RightAnkle"],LeftShank:["LeftKnee","LeftAnkle"],RightShank:["RightKnee","RightAnkle"],LeftThigh:["LeftHip","LeftKnee"],RightThigh:["RightHip","RightKnee"],LeftPelvis:["LeftHip"],RightPelvis:["RightHip"],LowerBack:["LeftHip","RightHip","NavalSpine","TotalSpine"],CenterBack:["NavalSpine","ChestSpine"],UpperBack:["ChestSpine","TotalSpine"],Head:["Neck"],LeftClavicle:["LeftShoulder"],RightClavicle:["RightShoulder"],LeftUpperArm:["LeftShoulder","LeftElbow"],RightUpperArm:["RightShoulder","RightElbow"],LeftForearm:["LeftElbow"],RightForearm:["RightElbow"]},S={LeftAnkle:["LeftFoot","LeftShank"],RightAnkle:["RightFoot","RightShank"],LeftKnee:["LeftShank","LeftThigh"],RightKnee:["RightShank","RightThigh"],LeftHip:["LeftThigh","LowerBack"],RightHip:["RightThigh","LowerBack"],NavalSpine:["LowerBack","CenterBack"],ChestSpine:["CenterBack","UpperBack"],TotalSpine:["UpperBack","LowerBack"],LeftShoulder:["LeftClavicle","LeftUpperArm"],RightShoulder:["RightClavicle","RightUpperArm"],LeftElbow:["LeftUpperArm","LeftForearm"],RightElbow:["RightUpperArm","RightForearm"],Neck:["Head","UpperBack"]},p=()=>[{id:"LeftFoot",name:r.LeftFoot},{id:"RightFoot",name:r.RightFoot},{id:"LeftShank",name:r.LeftShank},{id:"RightShank",name:r.RightShank},{id:"LeftThigh",name:r.LeftThigh},{id:"RightThigh",name:r.RightThigh},{id:"LowerBack",name:r.LowerBack},{id:"CenterBack",name:r.CenterBack},{id:"UpperBack",name:r.UpperBack},{id:"Head",name:r.Head},{id:"LeftUpperArm",name:r.LeftUpperArm},{id:"RightUpperArm",name:r.RightUpperArm},{id:"LeftForearm",name:r.LeftForearm},{id:"RightForearm",name:r.RightForearm}],W=t=>p().filter(e=>t.find(n=>n==e.id)),k=()=>[{id:"LeftAnkle",name:i.LeftAnkle},{id:"RightAnkle",name:i.RightAnkle},{id:"LeftKnee",name:i.LeftKnee},{id:"RightKnee",name:i.RightKnee},{id:"LeftHip",name:i.LeftHip},{id:"RightHip",name:i.RightHip},{id:"NavalSpine",name:i.NavalSpine},{id:"ChestSpine",name:i.ChestSpine},{id:"TotalSpine",name:i.TotalSpine},{id:"LeftShoulder",name:i.LeftShoulder},{id:"RightShoulder",name:i.RightShoulder},{id:"LeftElbow",name:i.LeftElbow},{id:"RightElbow",name:i.RightElbow},{id:"Neck",name:i.Neck}],x=()=>[{id:"LeftAnkle",name:i.LeftAnkle},{id:"RightAnkle",name:i.RightAnkle},{id:"LeftKnee",name:i.LeftKnee},{id:"RightKnee",name:i.RightKnee},{id:"LeftHip",name:i.LeftHip},{id:"RightHip",name:i.RightHip},{id:"NavalSpine",name:i.NavalSpine},{id:"ChestSpine",name:i.ChestSpine},{id:"TotalSpine",name:i.TotalSpine},{id:"LeftShoulder",name:i.LeftShoulder},{id:"RightShoulder",name:i.RightShoulder},{id:"Neck",name:i.Neck}],b=()=>[{id:"LeftAnkle",name:i.LeftAnkle},{id:"RightAnkle",name:i.RightAnkle},{id:"LeftKnee",name:i.LeftKnee},{id:"RightKnee",name:i.RightKnee},{id:"LeftHip",name:i.LeftHip},{id:"RightHip",name:i.RightHip},{id:"TotalSpine",name:i.TotalSpine},{id:"LeftShoulder",name:i.LeftShoulder},{id:"RightShoulder",name:i.RightShoulder},{id:"LeftElbow",name:i.LeftElbow},{id:"RightElbow",name:i.RightElbow},{id:"Neck",name:i.Neck}],_=()=>[{id:"Head",name:r.Head},{id:"LeftThigh",name:r.LeftThigh},{id:"RightThigh",name:r.RightThigh},{id:"LeftShank",name:r.LeftShank},{id:"RightShank",name:r.RightShank},{id:"LeftFoot",name:r.LeftFoot},{id:"RightFoot",name:r.RightFoot},{id:"LowerBack",name:r.LowerBack},{id:"UpperBack",name:r.UpperBack},{id:"LeftUpperArm",name:r.LeftUpperArm},{id:"RightUpperArm",name:r.RightUpperArm},{id:"LeftForearm",name:r.LeftForearm},{id:"RightForearm",name:r.RightForearm}],M=t=>x().filter(n=>S[n.id].every(s=>t.includes(s))),O=t=>b().filter(n=>S[n.id].every(s=>t.includes(s))),w=(t,e,n)=>{if(n)return["frontal","sagittal","transverse"];switch(t){case"LeftKnee":case"RightKnee":return["sagittal"];case"LeftAnkle":case"RightAnkle":return e&&e==l.AngleDataSource.Pose?["sagittal"]:["frontal","sagittal"];case"TotalSpine":return e&&e==l.AngleDataSource.Pose?["frontal"]:["frontal","sagittal","transverse"];case"LeftElbow":case"RightElbow":return e&&e==l.AngleDataSource.Pose?["sagittal"]:["frontal","sagittal","transverse"]}return e&&e==l.AngleDataSource.Pose?["frontal","sagittal"]:["frontal","sagittal","transverse"]},v=(t,e)=>{if(e===l.AngleDataSource.Sensor)return["frontal","sagittal","transverse"];switch(t){case"Head":case"LeftThigh":case"RightThigh":case"LeftShank":case"RightShank":case"LeftUpperArm":case"RightUpperArm":case"LeftForearm":case"RightForearm":return["frontal","sagittal"];case"LeftFoot":case"RightFoot":return["sagittal"];case"LowerBack":return["frontal"];case"UpperBack":return["frontal","sagittal"]}return[]},F=h.memo((t,e,n)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return n<0?"inversion":"eversion";case"sagittal":return n<0?"plantar flexion":"dorsi flexion";case"transverse":return n<0?"internal rotation":"external rotation"}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return n<0?"adduction":"abduction";case"sagittal":return n<0?"extension":"flexion";case"transverse":return n<0?"internal rotation":"external rotation"}case"LeftHip":case"RightHip":case"LeftShoulder":case"RightShoulder":switch(e){case"frontal":return n<0?"adduction":"abduction";case"sagittal":return n<0?"extension":"flexion";case"transverse":return n<0?"internal rotation":"external rotation"}case"NavalSpine":case"ChestSpine":case"TotalSpine":case"Neck":switch(e){case"frontal":return n<0?"right lateral flexion":"left lateral flexion";case"sagittal":return n<0?"extension":"flexion";case"transverse":return n<0?"right rotation":"left rotation"}case"LeftElbow":case"RightElbow":switch(e){case"frontal":return null;case"sagittal":return n<0?"extension":"flexion";case"transverse":return n<0?"pronation":"supination"}}return null}),P=h.memo((t,e,n)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return n<0?"Inv.":"Ev.";case"sagittal":return n<0?"PF.":"DF.";case"transverse":return n<0?"IR.":"ER."}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return n<0?"Add.":"Abd.";case"sagittal":return n<0?"Ext.":"Flex.";case"transverse":return n<0?"IR.":"ER."}case"LeftHip":case"RightHip":case"LeftShoulder":case"RightShoulder":switch(e){case"frontal":return n<0?"Add.":"Abd.";case"sagittal":return n<0?"Ext.":"Flex.";case"transverse":return n<0?"IR.":"ER."}case"NavalSpine":case"ChestSpine":case"TotalSpine":case"Neck":switch(e){case"frontal":return n<0?"R. Bend":"L. Bend";case"sagittal":return n<0?"Ext.":"Flex.";case"transverse":return n<0?"R. Rot.":"L. Rot."}case"LeftElbow":case"RightElbow":switch(e){case"frontal":return null;case"sagittal":return n<0?"Ext.":"Flex.";case"transverse":return n<0?"Pro.":"Sup."}}return null}),u=h.memo((t,e,n)=>{switch(t){case"LowerBack":case"LeftPelvis":case"RightPelvis":switch(e){case"frontal":return n<0?"right drop":"left drop";case"sagittal":return n<0?"anterior tilt":"posterior tilt";case"transverse":return n<0?"right rotation":"left rotation"}case"Head":case"UpperBack":case"CenterBack":case"LeftShank":case"RightShank":case"LeftThigh":case"RightThigh":case"LeftFoot":case"RightFoot":case"LeftUpperArm":case"RightUpperArm":case"LeftForearm":case"RightForearm":switch(e){case"frontal":return n<0?"right tilt":"left tilt";case"sagittal":return n<0?"anterior tilt":"posterior tilt";case"transverse":return n<0?"right rotation":"left rotation"}default:return null}}),T=h.memo((t,e,n)=>{switch(t){case"LowerBack":case"LeftPelvis":case"RightPelvis":switch(e){case"frontal":return n<0?"R. Drop":"L. Drop";case"sagittal":return n<0?"Ant. Tilt":"Pos. Tilt";case"transverse":return n<0?"R. Rot.":"L. Rot."}case"Head":case"UpperBack":case"CenterBack":case"LeftShank":case"RightShank":case"LeftThigh":case"RightThigh":case"LeftFoot":case"RightFoot":case"LeftUpperArm":case"RightUpperArm":case"LeftForearm":case"RightForearm":switch(e){case"frontal":return n<0?"R. Tilt":"L. Tilt";case"sagittal":return n<0?"Ant. Tilt":"Pos. Tilt";case"transverse":return n<0?"R. Rot.":"L. Rot."}default:return null}}),V=h.memo((t,e)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return{min:-20,max:20};case"sagittal":return{min:-30,max:30};case"transverse":return{min:-5,max:5}}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return{min:-5,max:5};case"sagittal":return{min:-5,max:90};case"transverse":return{min:-5,max:5}}case"LeftHip":case"RightHip":return{min:-30,max:30};case"LeftShoulder":case"RightShoulder":return{min:-50,max:50};case"NavalSpine":case"ChestSpine":case"TotalSpine":case"Neck":switch(e){case"frontal":return{min:-5,max:5};case"sagittal":return{min:-5,max:5};case"transverse":return{min:-5,max:5}}case"LeftElbow":case"RightElbow":switch(e){case"frontal":return{min:-5,max:5};case"sagittal":return{min:-5,max:50};case"transverse":return{min:-5,max:5}}}return{min:-10,max:10}}),X=h.memo((t,e)=>{switch(t){case"LeftFoot":case"RightFoot":switch(e){case"frontal":return{min:-20,max:20};case"sagittal":return{min:-30,max:30};case"transverse":return{min:-5,max:5}}case"LeftShank":case"RightShank":switch(e){case"frontal":return{min:-35,max:35};case"sagittal":return{min:-35,max:35};case"transverse":return{min:-5,max:5}}case"LeftThigh":case"RightThigh":switch(e){case"frontal":return{min:-35,max:35};case"sagittal":return{min:-35,max:35};case"transverse":return{min:-10,max:5}}case"LeftPelvis":case"RightPelvis":switch(e){case"frontal":return{min:-15,max:15};case"sagittal":return{min:-10,max:10};case"transverse":return{min:-10,max:10}}case"LowerBack":case"CenterBack":case"UpperBack":case"Head":return{min:-5,max:5};case"LeftClavicle":case"RightClavicle":switch(e){case"frontal":return{min:-15,max:15};case"sagittal":return{min:-10,max:10};case"transverse":return{min:-10,max:10}}case"LeftUpperArm":case"RightUpperArm":case"LeftForearm":case"RightForearm":switch(e){case"frontal":return{min:-45,max:45};case"sagittal":return{min:-45,max:45};case"transverse":return{min:-20,max:20}}}return{min:-10,max:10}}),G=h.memo((t,e)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return{min:-40,max:30};case"sagittal":return{min:-80,max:50};case"transverse":return{min:-90,max:90}}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return{min:-15,max:5};case"sagittal":return{min:-10,max:160};case"transverse":return{min:-35,max:45}}case"LeftHip":case"RightHip":switch(e){case"frontal":return{min:-50,max:60};case"sagittal":return{min:-50,max:150};case"transverse":return{min:-60,max:70}}case"TotalSpine":switch(e){case"frontal":return{min:-60,max:60};case"sagittal":return{min:-50,max:150};case"transverse":return{min:-50,max:50}}case"ChestSpine":switch(e){case"frontal":return{min:-25,max:25};case"sagittal":return{min:-25,max:40};case"transverse":return{min:-35,max:35}}case"NavalSpine":switch(e){case"frontal":return{min:-25,max:25};case"sagittal":return{min:-35,max:60};case"transverse":return{min:-15,max:15}}default:return{min:-180,max:180}}}),N=(t,e)=>({kind:"joint",value:t,plane:e}),E=(t,e)=>({kind:"limb",value:t,plane:e}),H=(t,e)=>({kind:"acceleration",value:t,axis:e}),U=(t,e)=>({kind:"angular_velocity",value:t,plane:e}),B=t=>l.axes.includes(t),Q=t=>l.planes.includes(t),C=t=>typeof t=="object"&&t!==null&&"id"in t&&"name"in t&&!!p().find(e=>e.id===t.id),J=t=>typeof t=="object"&&t!==null&&"id"in t&&"name"in t&&!!k().find(e=>e.id===t.id),Y=(t,e,n=!1)=>B(e)?C(t)?H(t,e):ne(`Can't make acceleration part from joint: ${t} ${e}`):J(t)?n?U(t,e):N(t,e):E(t,e),Z=t=>t.kind==="acceleration"?t.axis:t.plane,ee=t=>t?.kind==="acceleration"?t.axis:null,te=t=>t?.kind==="acceleration"?null:t?.plane??null,ne=t=>{throw new Error(t)},g=t=>t in i?i[t]:t in r?r[t]:"Unknown",ae=t=>g(t).replace(/Left|Right/g,""),ie=t=>t in A.romJson,K=(t,e)=>{if(!ie(t))return null;const n=A.romJson[t];if(e in n){const{min:o,max:s}=n[e];return{min:o??0,max:s??0}}return null},re=(...t)=>{const e=K(...t);return e?Math.abs(e.max-e.min):0},D=(t,e)=>{const n=Object.keys(r).find(s=>s===e),o=Object.keys(i).find(s=>s===e);return!n&&!o?null:n?t.limbs[e].sensor_angle?l.AngleDataSource.Sensor:l.AngleDataSource.Pose:t.joints[e].sensor_angle?l.AngleDataSource.Sensor:l.AngleDataSource.Pose},se=(t,e,n)=>{const o=Object.keys(i).find(c=>c===e),s=D(t,e);return s?o?w(e,s).includes(n):v(e,s).includes(n):!1},oe=(t,e,n)=>{const o=Object.keys(r).find(c=>c===e),s=Object.keys(i).find(c=>c===e);if(!o&&!s)throw new Error(`Unknown partId: ${e} - this invariant should've been enforced by typescript`);return o?l.limbAngle(t.limbs[e])?.[n]??null:l.jointAngle(t.joints[e],void 0,t.direction)?.[n]??null},L=(t=!1)=>t?"Internal/External Rotation":"External/Internal Rotation",j=(t,e,n=!1)=>{switch(t){case"LeftAnkle":case"RightAnkle":switch(e){case"frontal":return n?"Inversion/Eversion":"Eversion/Inversion";case"sagittal":return n?"Plantar/Dorsi Flexion":"Dorsi/Plantar Flexion";case"transverse":return L(n)}case"LeftKnee":case"RightKnee":switch(e){case"frontal":return n?"Adduction/Abduction":"Abduction/Adduction";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return L(n)}case"LeftHip":case"RightHip":switch(e){case"frontal":return n?"Adduction/Abduction":"Abduction/Adduction";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return L(n)}case"NavalSpine":case"ChestSpine":case"TotalSpine":case"Neck":switch(e){case"frontal":return"Lateral Bend";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return"Rotation"}case"LeftShoulder":case"RightShoulder":switch(e){case"frontal":return n?"Adduction/Abduction":"Abduction/Adduction";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return L(n)}case"LeftElbow":case"RightElbow":switch(e){case"frontal":return n?"Adduction/Abduction":"Abduction/Adduction";case"sagittal":return n?"Extension/Flexion":"Flexion/Extension";case"transverse":return n?"Pronation/Supination":"Supination/Pronation"}}},y=(t,e,n=!1)=>{const o=g(t),s=u(t,e,1),c=u(t,e,-1);if(s&&c){const m=d.capitalizeAll(s),f=d.capitalizeAll(c),z=n?`${f}/${m}`:`${m}/${f}`;return`${o} (${z})`}return`${o} (${e})`},ce=(t,e)=>{let n;switch(e){case"x":n="Med./Lat.";break;case"y":n="Vertical";break;case"z":n="Ant./Post."}return`${g(t)} ${n}`},$=(t,e,n=!1)=>{const o=g(t),s=j(t,e,n);return s?`${o} (${s})`:null},le=(t,e)=>$(t,e)||y(t,e),R=(t,e,n,o=!1)=>{const s=o?P:F,c=o?T:u,[m,f]=t==="joint"?[s(e,n,1),s(e,n,-1)]:[c(e,n,1),c(e,n,-1)];return{positive:m,negative:f}},q=(t,e=!1)=>t.partKind==="joint"?R("joint",t.partId,t.partDimension,e):R("segment",t.partId,t.partDimension,e),he=(t,e,n=!1)=>{const{positive:o,negative:s}=q(e,n);return t>=0?o:s},ge=t=>{const e=new Set,n={LeftAnkle:[a.SensorLocation.LeftShank,a.SensorLocation.LeftFoot],RightAnkle:[a.SensorLocation.RightShank,a.SensorLocation.RightFoot],LeftKnee:[a.SensorLocation.LeftThigh,a.SensorLocation.LeftShank],RightKnee:[a.SensorLocation.RightThigh,a.SensorLocation.RightShank],LeftHip:[a.SensorLocation.Pelvis,a.SensorLocation.LeftThigh],RightHip:[a.SensorLocation.Pelvis,a.SensorLocation.RightThigh],LeftShoulder:[a.SensorLocation.Thorax,a.SensorLocation.LeftUpperArm],RightShoulder:[a.SensorLocation.Thorax,a.SensorLocation.RightUpperArm],LeftElbow:[a.SensorLocation.LeftUpperArm,a.SensorLocation.LeftForearm],RightElbow:[a.SensorLocation.RightUpperArm,a.SensorLocation.RightForearm],ChestSpine:[a.SensorLocation.Thorax,a.SensorLocation.Pelvis],NavalSpine:[a.SensorLocation.Thorax,a.SensorLocation.Pelvis],TotalSpine:[a.SensorLocation.Thorax,a.SensorLocation.Pelvis],Neck:[a.SensorLocation.Head],Head:[a.SensorLocation.Head],UpperBack:[a.SensorLocation.CenterBack,a.SensorLocation.Pelvis],CenterBack:[a.SensorLocation.CenterBack,a.SensorLocation.Pelvis],LowerBack:[a.SensorLocation.Pelvis],LeftThigh:[a.SensorLocation.LeftThigh],RightThigh:[a.SensorLocation.RightThigh],LeftShank:[a.SensorLocation.LeftShank],RightShank:[a.SensorLocation.RightShank],LeftFoot:[a.SensorLocation.LeftFoot],RightFoot:[a.SensorLocation.RightFoot],LeftUpperArm:[a.SensorLocation.LeftUpperArm],RightUpperArm:[a.SensorLocation.RightUpperArm],LeftForearm:[a.SensorLocation.LeftForearm],RightForearm:[a.SensorLocation.RightForearm],LeftPelvis:[a.SensorLocation.Pelvis],RightPelvis:[a.SensorLocation.Pelvis],LeftClavicle:[a.SensorLocation.Thorax],RightClavicle:[a.SensorLocation.Thorax]};return t.forEach(o=>{const s=n[o];s&&s.forEach(c=>e.add(c))}),Array.from(e)};exports.getAllAvailableJoints=k;exports.getAllAvailableLimbs=p;exports.getAllAvailablePoseJoints=b;exports.getAllAvailablePoseLimbs=_;exports.getAllAvailableSensorJoints=x;exports.getAngleDirectionNames=R;exports.getAvailableLimbsForLimbIds=W;exports.getAvailablePoseJointsForLimbIds=O;exports.getAvailableSensorJointsForLimbIds=M;exports.getAxis=ee;exports.getDefaultAngleSource=D;exports.getDefaultJointRange=V;exports.getDefaultLimbRange=X;exports.getEnabledJointPlanes=w;exports.getEnabledSegmentPlanes=v;exports.getHumanBodyAngle=oe;exports.getIsDefaultAngleAllowed=se;exports.getJointAngleDirectionAbbr=P;exports.getJointAngleDirectionName=F;exports.getJointNameWithPlane=$;exports.getJointOrSegmentNameWithPlane=le;exports.getJointPlaneName=j;exports.getNormativeJointRange=G;exports.getParameterAngleDirectionName=he;exports.getParameterDirectionNames=q;exports.getPartName=g;exports.getPartNameNoSide=ae;exports.getPlane=te;exports.getSegmentAngleDirectionAbbr=T;exports.getSegmentAngleDirectionName=u;exports.getSegmentNameWithPlane=y;exports.getSegmentXyzName=ce;exports.getSuggestedSensorLocations=ge;exports.getTypicalRom=K;exports.getTypicalRomSize=re;exports.isAxis=B;exports.isJoint=J;exports.isLimb=C;exports.isPlane=Q;exports.jointNames=i;exports.jointsUsedByLimbs=I;exports.limbNames=r;exports.limbsRequiredForJoints=S;exports.mkAccelerationPart=H;exports.mkAngularVelocityPart=U;exports.mkHumanPart=Y;exports.mkJointPart=N;exports.mkLimbPart=E;exports.planeOrAxis=Z;
|
package/dist/services.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./services-action-DBOzfgMl.cjs"),e=require("./services-human-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("./services-action-DBOzfgMl.cjs"),e=require("./services-human-BTPVJl80.cjs"),t=require("./generated-graphql.cjs"),a=n=>({[t.ReportKind.GeneralActivity]:"General Activity Report",[t.ReportKind.MovementCoordination]:"Movement Decoupling Report",[t.ReportKind.PointOfInterest]:"Point of Interest Report",[t.ReportKind.Range]:"Movement Range Report",[t.ReportKind.StabilityBalance]:"Movement Stability & Balance Report"})[n];exports.getActivityKindFromActivityType=i.getActivityKindFromActivityType;exports.mapActivityTypeEnumToLabel=i.mapActivityTypeEnumToLabel;exports.mapSessionTypeEnumToLabel=i.mapSessionTypeEnumToLabel;exports.getAllAvailableJoints=e.getAllAvailableJoints;exports.getAllAvailableLimbs=e.getAllAvailableLimbs;exports.getAllAvailablePoseJoints=e.getAllAvailablePoseJoints;exports.getAllAvailablePoseLimbs=e.getAllAvailablePoseLimbs;exports.getAllAvailableSensorJoints=e.getAllAvailableSensorJoints;exports.getAngleDirectionNames=e.getAngleDirectionNames;exports.getAvailableLimbsForLimbIds=e.getAvailableLimbsForLimbIds;exports.getAvailablePoseJointsForLimbIds=e.getAvailablePoseJointsForLimbIds;exports.getAvailableSensorJointsForLimbIds=e.getAvailableSensorJointsForLimbIds;exports.getAxis=e.getAxis;exports.getDefaultAngleSource=e.getDefaultAngleSource;exports.getDefaultJointRange=e.getDefaultJointRange;exports.getDefaultLimbRange=e.getDefaultLimbRange;exports.getEnabledJointPlanes=e.getEnabledJointPlanes;exports.getEnabledSegmentPlanes=e.getEnabledSegmentPlanes;exports.getHumanBodyAngle=e.getHumanBodyAngle;exports.getIsDefaultAngleAllowed=e.getIsDefaultAngleAllowed;exports.getJointAngleDirectionAbbr=e.getJointAngleDirectionAbbr;exports.getJointAngleDirectionName=e.getJointAngleDirectionName;exports.getJointNameWithPlane=e.getJointNameWithPlane;exports.getJointOrSegmentNameWithPlane=e.getJointOrSegmentNameWithPlane;exports.getJointPlaneName=e.getJointPlaneName;exports.getNormativeJointRange=e.getNormativeJointRange;exports.getParameterAngleDirectionName=e.getParameterAngleDirectionName;exports.getParameterDirectionNames=e.getParameterDirectionNames;exports.getPartName=e.getPartName;exports.getPartNameNoSide=e.getPartNameNoSide;exports.getPlane=e.getPlane;exports.getSegmentAngleDirectionAbbr=e.getSegmentAngleDirectionAbbr;exports.getSegmentAngleDirectionName=e.getSegmentAngleDirectionName;exports.getSegmentNameWithPlane=e.getSegmentNameWithPlane;exports.getSegmentXyzName=e.getSegmentXyzName;exports.getSuggestedSensorLocations=e.getSuggestedSensorLocations;exports.getTypicalRom=e.getTypicalRom;exports.getTypicalRomSize=e.getTypicalRomSize;exports.isAxis=e.isAxis;exports.isJoint=e.isJoint;exports.isLimb=e.isLimb;exports.isPlane=e.isPlane;exports.jointNames=e.jointNames;exports.jointsUsedByLimbs=e.jointsUsedByLimbs;exports.limbNames=e.limbNames;exports.limbsRequiredForJoints=e.limbsRequiredForJoints;exports.mkAccelerationPart=e.mkAccelerationPart;exports.mkAngularVelocityPart=e.mkAngularVelocityPart;exports.mkHumanPart=e.mkHumanPart;exports.mkJointPart=e.mkJointPart;exports.mkLimbPart=e.mkLimbPart;exports.planeOrAxis=e.planeOrAxis;exports.reportKindName=a;
|