quantum-component-library 0.0.1 → 1.0.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (119) hide show
  1. package/README.md +115 -69
  2. package/dist/babel-vendor-BOM86iTb.js +221 -0
  3. package/dist/babel-vendor-cKvSpnBp.cjs +3 -0
  4. package/dist/components/activity-list/index.d.ts +19 -0
  5. package/dist/components/copy-activity-form/index.d.ts +30 -0
  6. package/dist/components/copy-activity-form/index.stories.d.ts +6 -0
  7. package/dist/components/copy-module-form/index.d.ts +30 -0
  8. package/dist/components/copy-module-form/index.stories.d.ts +6 -0
  9. package/dist/components/index.d.ts +8 -0
  10. package/dist/components/module-form/index.d.ts +15 -0
  11. package/dist/components/parameter-edit-list/index.d.ts +13 -0
  12. package/dist/components/parameter-edit-select/index.d.ts +16 -0
  13. package/dist/components/test-filter-panel/index.d.ts +7 -0
  14. package/dist/components/ui/form/index.d.ts +4 -0
  15. package/dist/components/ui/form/label/index.d.ts +4 -0
  16. package/dist/components/ui/form/list-order-input/index.d.ts +14 -0
  17. package/dist/components/ui/form/radio-buttons/index.d.ts +16 -0
  18. package/dist/components/ui/form/range-slider-input/index.d.ts +17 -0
  19. package/dist/components/ui/index.d.ts +2 -1
  20. package/dist/components/ui/tag-group/index.d.ts +7 -0
  21. package/dist/components/upsert-activity-form/index.d.ts +18 -0
  22. package/dist/components/upsert-activity-form/index.stories.d.ts +6 -0
  23. package/dist/components/upsert-module-form/index.d.ts +17 -0
  24. package/dist/components/upsert-module-form/index.stories.d.ts +6 -0
  25. package/dist/components.cjs +13 -0
  26. package/dist/components.js +2078 -0
  27. package/dist/dnd-core-vendor-bgjKfDi6.cjs +1 -0
  28. package/dist/dnd-core-vendor-q7mfiuVu.js +750 -0
  29. package/dist/generated/fragment-masking.d.ts +19 -0
  30. package/dist/generated/gql.d.ts +271 -0
  31. package/dist/generated/graphql.d.ts +2326 -0
  32. package/dist/generated/index.d.ts +2 -0
  33. package/dist/generated-ChsGaiYd.cjs +1 -0
  34. package/dist/generated-GfcSQz21.js +65 -0
  35. package/dist/graphql/fragments/actions.d.ts +1 -0
  36. package/dist/graphql/fragments/analysis.d.ts +12 -0
  37. package/dist/graphql/fragments/groups.d.ts +1 -0
  38. package/dist/graphql/fragments/index.d.ts +6 -0
  39. package/dist/graphql/fragments/modules.d.ts +3 -0
  40. package/dist/graphql/fragments/playback.d.ts +11 -0
  41. package/dist/graphql/fragments/session.d.ts +3 -0
  42. package/dist/graphql/index.d.ts +3 -0
  43. package/dist/graphql/mutations/actions.d.ts +7 -0
  44. package/dist/graphql/mutations/index.d.ts +2 -0
  45. package/dist/graphql/mutations/modules.d.ts +13 -0
  46. package/dist/graphql/queries/actions.d.ts +19 -0
  47. package/dist/graphql/queries/groups.d.ts +9 -0
  48. package/dist/graphql/queries/index.d.ts +3 -0
  49. package/dist/graphql/queries/modules.d.ts +9 -0
  50. package/dist/graphql-CqPvuCvr.cjs +679 -0
  51. package/dist/graphql-DiUes2Np.js +735 -0
  52. package/dist/graphql-vendor-JsvuUrRs.cjs +14 -0
  53. package/dist/graphql-vendor-YnA_qhJA.js +669 -0
  54. package/dist/hooks.cjs +1 -0
  55. package/dist/hooks.js +84 -0
  56. package/dist/index.cjs +1 -0
  57. package/dist/index.d.ts +6 -1
  58. package/dist/index.js +132 -3159
  59. package/dist/lib/hooks/index.d.ts +7 -0
  60. package/dist/lib/hooks/use-graphql-client.d.ts +5 -0
  61. package/dist/lib/hooks/use-joints-for-limb-ids.d.ts +2 -0
  62. package/dist/lib/hooks/use-joints-for-sensor-locations.d.ts +2 -0
  63. package/dist/lib/hooks/use-limbs-for-sensor-locations.d.ts +2 -0
  64. package/dist/lib/hooks/use-part-options-for-joints.d.ts +3 -0
  65. package/dist/lib/hooks/use-part-options-for-limbs.d.ts +3 -0
  66. package/dist/lib/hooks/use-part-options-for-sensor-locations.d.ts +3 -0
  67. package/dist/lib/services/human.d.ts +69 -0
  68. package/dist/lib/services/index.d.ts +1 -0
  69. package/dist/lib/services/rom.json.d.ts +226 -0
  70. package/dist/lib/types/activity.d.ts +19 -0
  71. package/dist/lib/types/analysis.d.ts +115 -0
  72. package/dist/lib/types/athlete.d.ts +8 -0
  73. package/dist/lib/types/catalog.d.ts +35 -0
  74. package/dist/lib/types/error.d.ts +4 -0
  75. package/dist/lib/types/human-part.d.ts +23 -0
  76. package/dist/lib/types/human.d.ts +147 -0
  77. package/dist/lib/types/index.d.ts +14 -0
  78. package/dist/lib/types/parameters.d.ts +10 -0
  79. package/dist/lib/types/playback.d.ts +20 -0
  80. package/dist/lib/types/recording.d.ts +5 -0
  81. package/dist/lib/types/sensor-info.d.ts +105 -0
  82. package/dist/lib/types/threshold.d.ts +30 -0
  83. package/dist/lib/types/tracking.d.ts +82 -0
  84. package/dist/lib/types/upload.d.ts +28 -0
  85. package/dist/lib/utils/conversion.d.ts +27 -0
  86. package/dist/lib/utils/index.d.ts +6 -0
  87. package/dist/lib/utils/memo.d.ts +7 -0
  88. package/dist/lib/utils/parameters.d.ts +6 -0
  89. package/dist/lib/utils/text.d.ts +2 -0
  90. package/dist/lodash-vendor-D5A6v3mw.cjs +1 -0
  91. package/dist/lodash-vendor-Dz4vW7Gd.js +1120 -0
  92. package/dist/other-CmpBz5tg.js +15 -0
  93. package/dist/other-TR0ap-t4.cjs +1 -0
  94. package/dist/providers/index.d.ts +1 -0
  95. package/dist/providers/quantum-library-provider.d.ts +8 -0
  96. package/dist/providers.cjs +1 -0
  97. package/dist/providers.js +11 -0
  98. package/dist/quantum-component-library.css +1 -0
  99. package/dist/react-dnd-vendor-BWqlt2EC.cjs +2 -0
  100. package/dist/react-dnd-vendor-BZs2igAJ.js +1375 -0
  101. package/dist/react-icons-vendor-D2s8zw9h.cjs +1 -0
  102. package/dist/react-icons-vendor-TETORdU9.js +119 -0
  103. package/dist/react-select-vendor-By3h6JjH.cjs +4 -0
  104. package/dist/react-select-vendor-eBH7yy3O.js +2801 -0
  105. package/dist/services.cjs +1 -0
  106. package/dist/services.js +810 -0
  107. package/dist/styled-components-vendor-Bvwhddj9.js +1154 -0
  108. package/dist/styled-components-vendor-D09ATioU.cjs +60 -0
  109. package/dist/types.cjs +1 -0
  110. package/dist/types.js +316 -0
  111. package/dist/utils.cjs +1 -0
  112. package/dist/utils.js +128 -0
  113. package/dist/vendor-BeqUcSbw.cjs +45 -0
  114. package/dist/vendor-DvX9OX-j.js +7876 -0
  115. package/package.json +118 -60
  116. package/dist/components/ui/button.d.ts +0 -10
  117. package/dist/index.css +0 -1
  118. package/dist/index.umd.cjs +0 -22
  119. package/dist/lib/utils.d.ts +0 -2
@@ -0,0 +1,147 @@
1
+ import { AnalysisPartId } from './analysis';
2
+ export interface IHumanBody {
3
+ limbs: HumanBodyLimbs;
4
+ joints: HumanBodyJoints;
5
+ points: HumanBodyPoints;
6
+ center_of_mass?: ICenterOfMass;
7
+ timestamp: bigint | number;
8
+ direction?: HeadingDirection | null;
9
+ }
10
+ export interface IBodySequenceFrame {
11
+ timestamp: bigint | number;
12
+ video_frame?: bigint | number | null;
13
+ bodies: IHumanBody[];
14
+ }
15
+ export interface IBodySequenceResponse {
16
+ frames: IBodySequenceFrame[];
17
+ estimated_duration: bigint | number;
18
+ limbs_with_sensors: HumanBodyLimbId[];
19
+ }
20
+ /**
21
+ * All of the available LimbIds. This should exactly match what is in
22
+ * `tracking/src/human/body.rs`.
23
+ */
24
+ export type HumanBodyLimbId = "Head" | "UpperBack" | "CenterBack" | "LowerBack" | "LeftThigh" | "RightThigh" | "LeftShank" | "RightShank" | "LeftFoot" | "RightFoot" | "LeftUpperArm" | "RightUpperArm" | "LeftForearm" | "RightForearm" | "LeftPelvis" | "RightPelvis" | "LeftClavicle" | "RightClavicle";
25
+ /**
26
+ * All of the available JointIds. This should exactly match what is in
27
+ * `tracking/src/human/body.rs`.
28
+ */
29
+ export type HumanBodyJointId = "LeftAnkle" | "RightAnkle" | "LeftKnee" | "RightKnee" | "LeftHip" | "RightHip" | "LeftShoulder" | "RightShoulder" | "LeftElbow" | "RightElbow" | "ChestSpine" | "NavalSpine" | "TotalSpine" | "Neck";
30
+ export type HumanBodyPointId = "Nose" | "Neck" | "LeftEye" | "RightEye" | "LeftEar" | "RightEar" | "LeftShoulder" | "RightShoulder" | "LeftElbow" | "RightElbow" | "LeftWrist" | "RightWrist" | "LeftHip" | "RightHip" | "LeftKnee" | "RightKnee" | "LeftAnkle" | "RightAnkle" | "Head" | "Pelvis" | "NavalSpine" | "ChestSpine" | "LeftClavicle" | "RightClavicle" | "LeftHand" | "RightHand" | "LeftHandTip" | "RightHandTip" | "LeftThumb" | "RightThumb" | "LeftFoot" | "RightFoot" | "LeftHeel" | "RightHeel" | "ShoulderCenter";
31
+ export type HumanBodyLimbIdNoSide = "Head" | "UpperBack" | "CenterBack" | "LowerBack" | "Thigh" | "Shank" | "Foot" | "UpperArm" | "Forearm" | "Pelvis" | "Clavicle";
32
+ export type HumanBodyJointIdNoSide = "Ankle" | "Knee" | "Hip" | "Shoulder" | "Elbow" | "Spine" | "Neck";
33
+ export type HumanBodyLimbs = {
34
+ [key in HumanBodyLimbId]: IHumanLimb;
35
+ };
36
+ export type HumanBodyJoints = {
37
+ [key in HumanBodyJointId]: IHumanJoint;
38
+ };
39
+ export type HumanBodyPoints = {
40
+ [key in HumanBodyPointId]: IHumanPoint;
41
+ };
42
+ export interface IHumanLimb {
43
+ len: number | null;
44
+ point_vector: [number, number, number] | null;
45
+ sensor_orientation: Quaternion | null;
46
+ sensor_angle: IBodyAngle | null;
47
+ pose_orientation: Quaternion | null;
48
+ pose_angle: IBodyAngle | null;
49
+ acceleration: IAcceleration | null;
50
+ }
51
+ export interface IHumanJoint {
52
+ pose_angle: IBodyAngle | null;
53
+ sensor_angle: IBodyAngle | null;
54
+ sensor_angular_velocity: IBodyAngularVelocity | null;
55
+ point: IHumanPoint | null;
56
+ }
57
+ export declare const jointAngle: (joint?: IHumanJoint | null, dataSource?: AngleDataSource | null, heading?: HeadingDirection | null) => Partial<IBodyAngle> | null;
58
+ export declare const limbAngle: (limb?: IHumanLimb | null, dataSource?: AngleDataSource | null) => IBodyAngle | null;
59
+ export interface IHumanPoint {
60
+ point: {
61
+ x: bigint;
62
+ y: bigint;
63
+ z: bigint;
64
+ };
65
+ screen_point: {
66
+ x: number;
67
+ y: number;
68
+ };
69
+ }
70
+ export type Quaternion = {
71
+ w: number;
72
+ x: number;
73
+ y: number;
74
+ z: number;
75
+ };
76
+ export interface IBodyAngle {
77
+ frontal: number;
78
+ sagittal: number;
79
+ transverse: number;
80
+ }
81
+ export interface IBodyAngularVelocity {
82
+ frontal: number;
83
+ sagittal: number;
84
+ transverse: number;
85
+ }
86
+ export interface ICenterOfMass {
87
+ x: number;
88
+ y: number;
89
+ }
90
+ export interface IAcceleration {
91
+ x: number;
92
+ y: number;
93
+ z: number;
94
+ }
95
+ export type AnglePlane = keyof IBodyAngle;
96
+ export interface IAvailableHumanLimb {
97
+ id: HumanBodyLimbId;
98
+ name: string;
99
+ }
100
+ export interface IAvailableJoint {
101
+ id: HumanBodyJointId;
102
+ name: string;
103
+ }
104
+ export declare const availablePlanes: Array<AnglePlane>;
105
+ export interface ITrackingFrame<N extends string> {
106
+ frame_number: bigint;
107
+ timestamp: bigint;
108
+ __kind__: N;
109
+ }
110
+ export interface IHumanTrackingFrame extends ITrackingFrame<"human"> {
111
+ bodies: IHumanBody[];
112
+ }
113
+ export interface ILimbTrackingFrame extends ITrackingFrame<"limb"> {
114
+ limbs: IHumanLimb[];
115
+ }
116
+ export interface IJointTrackingFrame extends ITrackingFrame<"joint"> {
117
+ joints: IHumanJoint[];
118
+ }
119
+ export declare const isLimbTrackingFrame: (frame: ITrackingFrame<string>) => frame is ILimbTrackingFrame;
120
+ export interface IExtraTrackingFrame {
121
+ center_of_mass: NonNullable<IHumanBody["center_of_mass"]>[];
122
+ timestamp: bigint;
123
+ }
124
+ export interface IPlaybackExtraInfo {
125
+ extra_frame_data: IExtraTrackingFrame[];
126
+ frame_count: number;
127
+ estimated_duration: bigint;
128
+ limbs_with_sensors: HumanBodyLimbId[];
129
+ }
130
+ export interface IPlaybackOptions {
131
+ speed: number;
132
+ }
133
+ export interface IUpdatePlaybackOptionsArgs {
134
+ options: IPlaybackOptions;
135
+ }
136
+ export declare const canBeVerticalForce: (limbId: HumanBodyLimbId, axis: "x" | "y" | "z") => boolean;
137
+ export declare const getLimbIdWithSide: (limbId: HumanBodyLimbIdNoSide, side: "left" | "right") => HumanBodyLimbId;
138
+ export declare const getPointSide: (pointId: HumanBodyPointId | HumanBodyJointId) => "left" | "right" | null;
139
+ export declare const getJointIdWithSide: (jointId: HumanBodyJointIdNoSide, side: "left" | "right") => HumanBodyJointId;
140
+ export declare const getJointIdNoSide: (jointId: HumanBodyJointId) => HumanBodyJointIdNoSide;
141
+ export declare const getLimbIdNoSide: (limbId: HumanBodyLimbId) => HumanBodyLimbIdNoSide;
142
+ export declare enum AngleDataSource {
143
+ Sensor = "sensor",
144
+ Pose = "pose"
145
+ }
146
+ export type HeadingDirection = "left" | "right" | "forward" | "backward";
147
+ export declare const getAnalysisPartIdNoSide: (partId: AnalysisPartId) => HumanBodyLimbIdNoSide | HumanBodyJointIdNoSide;
@@ -0,0 +1,14 @@
1
+ export * from './activity';
2
+ export * from './analysis';
3
+ export * from './athlete';
4
+ export * from './catalog';
5
+ export * from './error';
6
+ export * from './human';
7
+ export * from './human-part';
8
+ export * from './parameters';
9
+ export * from './playback';
10
+ export * from './recording';
11
+ export * from './sensor-info';
12
+ export * from './threshold';
13
+ export * from './tracking';
14
+ export * from './upload';
@@ -0,0 +1,10 @@
1
+ import { ThresholdKind } from '../../generated/graphql';
2
+ import { AnalysisPartId } from './analysis';
3
+ import { AnglePlane } from './human';
4
+ export type PartParameter = {
5
+ id: AnalysisPartId;
6
+ plane: AnglePlane;
7
+ min: number;
8
+ max: number;
9
+ kind: ThresholdKind;
10
+ };
@@ -0,0 +1,20 @@
1
+ import { IHumanBody } from './human';
2
+ export interface IPlaybackLoadArgs {
3
+ videoPath?: string;
4
+ packetPath?: string;
5
+ videoDataOffset: number;
6
+ }
7
+ export interface IPlaybackLoadResult {
8
+ viewVideoUrl?: string;
9
+ startUnixTime?: number;
10
+ usesSensorData?: boolean;
11
+ usesPoseData?: boolean;
12
+ }
13
+ export interface IPlaybackSeekToFrameArgs {
14
+ frame: number;
15
+ }
16
+ export interface IRequestKeypointHumans {
17
+ packetPath: string;
18
+ frameNumbers: number[];
19
+ }
20
+ export type KeypointHumansResult = Array<[number, IHumanBody[]]>;
@@ -0,0 +1,5 @@
1
+ export interface IRecordingFilePaths {
2
+ video_path: string | null;
3
+ sensor_data_path: string | null;
4
+ camera_data_path: string | null;
5
+ }
@@ -0,0 +1,105 @@
1
+ import { SensorLocation } from '../../generated/graphql';
2
+ import { HumanBodyLimbId } from './human';
3
+ export type SensorState = "AVAILABLE" | "CONNECTED" | "SYNCING" | "READY" | "MEASURING" | "RECORDING" | "EXPORTING" | "DESTRUCTING" | "FLUSHING";
4
+ export type SensorMode = "ORIENTATION" | "ACCELERATION" | "COMBINED";
5
+ export type LimbId = string;
6
+ export type ConnectedInfo = {
7
+ name: string;
8
+ rssi: number | null;
9
+ };
10
+ type ConnectedState = ConnectedInfo & {
11
+ state: "CONNECTED" | "SYNCING" | "MEASURING" | "RECORDING" | "EXPORTING" | "FLUSHING";
12
+ };
13
+ type AvailableState = {
14
+ state: "AVAILABLE";
15
+ rssi: number | null;
16
+ };
17
+ type DestructingState = {
18
+ state: "DESTRUCTING";
19
+ };
20
+ type ReadyState = ConnectedInfo & {
21
+ state: "READY";
22
+ synced_to: string;
23
+ output_rate: OutputRate;
24
+ };
25
+ export type OutputRate = "Hz1" | "Hz4" | "Hz10" | "Hz12" | "Hz15" | "Hz20" | "Hz30" | "Hz60" | "Hz120";
26
+ export type SensorInfo = (ConnectedState | AvailableState | DestructingState | ReadyState) & {
27
+ addr: string;
28
+ };
29
+ export type SensorBattery = {
30
+ address: string;
31
+ battery: {
32
+ percent: number;
33
+ is_charging: boolean;
34
+ };
35
+ };
36
+ export type StorageLevel = {
37
+ max_bytes: number;
38
+ used_bytes: number;
39
+ };
40
+ export interface IAvailableLimb {
41
+ name: string;
42
+ id: LimbId;
43
+ linked_to: string | null;
44
+ is_disconnecting?: boolean;
45
+ }
46
+ export interface ISensorSyncValidationResult {
47
+ total_frames: number;
48
+ partial_frames: number;
49
+ frames_per_sensor: {
50
+ [addr: string]: number;
51
+ };
52
+ expected_drop: number;
53
+ }
54
+ export type SyncError = "NotInitialized" | {
55
+ SyncError: SensorError;
56
+ };
57
+ export type SensorError = "NoAdapterFound" | "SensorAlreadyConnected" | "InvalidCharacteristicUUID" | "CannotSyncZeroSensors" | "InvalidChecksum" | "SensorNotFound" | "InvalidCharNotifyData" | "NoFrameReceived" | "BadOrientationChannel" | {
58
+ UnknownSyncError: unknown;
59
+ } | {
60
+ SyncFailed: unknown;
61
+ } | {
62
+ InvalidStateForOp: string;
63
+ } | {
64
+ CharacteristicNotFound: string;
65
+ } | {
66
+ BtleError: unknown;
67
+ } | {
68
+ CannotCreateNotificationTask: unknown;
69
+ } | {
70
+ SyncTimeout: string;
71
+ } | {
72
+ SyncFailedDisconnectTimeout: string;
73
+ } | {
74
+ MultiSensorError: MultiSensorError;
75
+ };
76
+ export type MultiSensorError = {
77
+ [addr: string]: SensorError;
78
+ };
79
+ export type StartSensorRecordingResult = {
80
+ [addr: string]: {
81
+ startedAt: number;
82
+ recordingAt: number;
83
+ estimatedDelay: IMessageDelay;
84
+ };
85
+ };
86
+ export interface IExportSensorRecordingArgs {
87
+ recordings: ISensorRecording[];
88
+ outputPath: string;
89
+ }
90
+ export interface ISensorRecording {
91
+ address: string;
92
+ startedAt: number;
93
+ recordingAt: number;
94
+ startDelay?: number;
95
+ recordingDelay: IMessageDelay;
96
+ segmentId: LimbId;
97
+ }
98
+ export interface IMessageDelay {
99
+ write: number;
100
+ ack: number;
101
+ roundTrip: number;
102
+ }
103
+ export declare const sensorLocationToLimbId: (location: SensorLocation | `${SensorLocation}`) => HumanBodyLimbId | null;
104
+ export declare const sensorLocationName: (location: SensorLocation) => string;
105
+ export {};
@@ -0,0 +1,30 @@
1
+ import { AnalysisThresholdFragment, TestAnalysisThresholdKind, ThresholdInput } from '../../generated/graphql';
2
+ import { AnglePlane, HumanBodyJointId, HumanBodyLimbId, IAvailableJoint, IAvailableHumanLimb as IAvailableLimb } from './human';
3
+ import { HumanPart, XYZ } from './human-part';
4
+ export type Threshold = {
5
+ kind: TestAnalysisThresholdKind;
6
+ min: number;
7
+ max: number;
8
+ };
9
+ export type PlaneThresholds<T extends string = AnglePlane> = {
10
+ [key in T]?: Threshold;
11
+ };
12
+ export type Thresholds = {
13
+ joint: {
14
+ [key in HumanBodyJointId]?: PlaneThresholds;
15
+ };
16
+ limb: {
17
+ [key in HumanBodyLimbId]?: PlaneThresholds;
18
+ };
19
+ acceleration: {
20
+ [key in HumanBodyLimbId]?: PlaneThresholds<XYZ>;
21
+ };
22
+ };
23
+ export declare const jointOrLimbHasThreshold: (thresholds: Thresholds, item: IAvailableJoint | IAvailableLimb) => boolean;
24
+ export declare const jointOrLimbThresholdCount: (thresholds: Thresholds, item: IAvailableJoint | IAvailableLimb) => number;
25
+ export declare const partAndPlaneHasThreshold: (thresholds: Thresholds, part: IAvailableJoint | IAvailableLimb, plane: AnglePlane | XYZ) => boolean;
26
+ export declare const thresholdForPart: (thresholds: Thresholds, part: HumanPart) => Threshold | undefined;
27
+ export declare const updateThreshold: (thresholds: Thresholds, part: HumanPart, threshold?: Threshold) => Thresholds;
28
+ export declare const thresholdsToInput: (thresholds: Thresholds) => Array<ThresholdInput>;
29
+ export declare const thresholdFragmentsToThresholds: (thresholds: Array<AnalysisThresholdFragment>) => Thresholds;
30
+ export declare const areThresholdsEmpty: (thresholds: Thresholds) => boolean;
@@ -0,0 +1,82 @@
1
+ import { ICameraCalibration } from './catalog';
2
+ import { IRecordingFilePaths } from './recording';
3
+ export interface ITrackingOptions {
4
+ mirrorVideo: boolean;
5
+ useSensors: boolean;
6
+ useRealtimeData: boolean;
7
+ recordingPaths?: IRecordingFilePaths;
8
+ fusionConfigPath?: string;
9
+ initialSensorData?: RawSensorData[];
10
+ cameraType: CameraType;
11
+ requestedFrameRate: CameraFrameRate;
12
+ poseModelComplexity?: PoseModelComplexity;
13
+ preserveCameraSettings?: boolean;
14
+ }
15
+ export type PoseModelComplexity = "lite" | "full" | "heavy";
16
+ export type CameraType = "Zed" | {
17
+ Webcam: number;
18
+ } | {
19
+ GoPro: string;
20
+ };
21
+ export type CameraFrameRate = "fps60" | "fps120";
22
+ export interface IStartTrackingResult {
23
+ imageSize: [number, number] | null;
24
+ focalLength: [number, number] | null;
25
+ principalPoint: [number, number] | null;
26
+ videoStartedAt: number | null;
27
+ }
28
+ export interface IMergeDataFilesArgs {
29
+ fileA: string;
30
+ fileB: string;
31
+ outputPath: string;
32
+ skipUntilMsTimestamp: number | null;
33
+ }
34
+ export interface IKinematicFittingArgs {
35
+ calibration: ICameraCalibration;
36
+ modelPath: string;
37
+ inputPath: string;
38
+ outputPath: string;
39
+ }
40
+ export interface IScaleModelArgs {
41
+ inputPath: string;
42
+ skipForMs: number;
43
+ outputPath: string;
44
+ }
45
+ export interface ZedDevice {
46
+ kind: "Zed";
47
+ state: "Available" | "NotAvailable";
48
+ id: number;
49
+ serial_number: number;
50
+ input_type: unknown;
51
+ model: string;
52
+ }
53
+ export interface UsbDevice {
54
+ kind: "Usb";
55
+ name: string;
56
+ description: string;
57
+ index: number | null;
58
+ }
59
+ export interface GoProDevice {
60
+ kind: "GoPro";
61
+ id: string;
62
+ serial_number: string;
63
+ model_name: string;
64
+ }
65
+ export declare const isDeviceEqual: (a: TrackingDevice, b: TrackingDevice) => boolean;
66
+ export type TrackingDevice = ZedDevice | UsbDevice | GoProDevice;
67
+ export type RawSensorData = {
68
+ address: number[];
69
+ timestamp: number;
70
+ acceleration?: {
71
+ x: number;
72
+ y: number;
73
+ z: number;
74
+ };
75
+ orientation?: {
76
+ w: number;
77
+ x: number;
78
+ y: number;
79
+ z: number;
80
+ };
81
+ };
82
+ export type ResetOrientationResult = Array<RawSensorData>;
@@ -0,0 +1,28 @@
1
+ export interface INativeRustApiOptions {
2
+ base_url: string;
3
+ auth_token: string;
4
+ }
5
+ export interface IUploadTrackingFileParams {
6
+ testId: string;
7
+ dataPath?: string | null;
8
+ videoPath?: string | null;
9
+ trimStartMs?: number | null;
10
+ options: INativeRustApiOptions;
11
+ }
12
+ export interface IUploadTrackingFileResult {
13
+ id: string;
14
+ dataFile: string;
15
+ videoFile: string;
16
+ videoFileFormat: string;
17
+ }
18
+ export interface IDownloadTrackingFileParams {
19
+ testId: string;
20
+ fileKind: 'data' | 'video';
21
+ destPath: string;
22
+ options: INativeRustApiOptions;
23
+ }
24
+ export interface IDownloadProgress {
25
+ key: string;
26
+ progress: number;
27
+ total: number;
28
+ }
@@ -0,0 +1,27 @@
1
+ import { ReviewParameterFragment } from '../../generated/graphql';
2
+ import { Unit, UnitKind } from '../types';
3
+ export declare const metersToInches: (meters: number) => number;
4
+ export declare const inchesToMeters: (inches: number) => number;
5
+ export declare const kgToPounds: (kg: number) => number;
6
+ export declare const poundsToKg: (pounds: number) => number;
7
+ export declare const radToDeg: (rad?: number | null | undefined, noRound?: boolean) => number | null;
8
+ export declare const degToRad: <R extends number | null | undefined>(deg?: R) => number | null;
9
+ export declare const msToDurationStr: (ms: number) => string;
10
+ export declare const msToTimestampStr: (ms: number, showMs?: boolean, padStart?: boolean) => string;
11
+ export declare const sToTimestampStr: (s: number, fractional?: boolean) => string;
12
+ export declare const msToPrettyStr: (ms: number) => string;
13
+ export declare const msToHourMinSecStr: (ms: number) => string;
14
+ export declare const secondsToTimestampStr: (s: number) => string;
15
+ export declare const hourMinSecStrToMs: (str: string, end?: boolean) => number;
16
+ export declare const getUnitValueFormatted: (unit: UnitKind, value: number) => string;
17
+ export declare const getUnitFormatted: (unit: Unit) => string;
18
+ type ExclusiveValues<U1, U2> = Exclude<U1, U2> | Exclude<U2, U1>;
19
+ type EnumValues<T> = T extends string ? `${T}` : never;
20
+ export type CompatibleUnions<U1, U2> = ExclusiveValues<U1, U2> extends never ? U1 : never;
21
+ export type CompatibleEnums<E1, E2> = CompatibleUnions<EnumValues<E1>, EnumValues<E2>> extends never ? never : E1;
22
+ /**
23
+ * Safely convert between two enums that have the same values.
24
+ */
25
+ export declare const safelyConvertEnum: <From extends string, To extends string>(fromValue: CompatibleEnums<From, To>) => To;
26
+ export declare const getFormatterForParameter: (parameter: Pick<ReviewParameterFragment, "partKind" | "partId" | "partDimension">) => (value: number) => string;
27
+ export {};
@@ -0,0 +1,6 @@
1
+ import { ClassValue } from 'clsx';
2
+ export declare function cn(...inputs: ClassValue[]): string;
3
+ export * from './conversion';
4
+ export * from './memo';
5
+ export * from './parameters';
6
+ export * from './text';
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Returns a memoized version of the given function. That is, the function will
3
+ * only be called once for a given set of arguments, and the result will be
4
+ * returned for subsequent calls with the same arguments. This is especially
5
+ * useful for us where we are doing a lot of file system reads.
6
+ */
7
+ export declare const memo: <T extends (...args: never[]) => unknown>(fn: T) => T;
@@ -0,0 +1,6 @@
1
+ import { ThresholdInput } from '../../generated/graphql';
2
+ import { PartParameter } from '../types/parameters';
3
+ export declare const parameterToThreshold: (parameter: PartParameter) => ThresholdInput;
4
+ export declare const parametersToThresholds: (parameters: PartParameter[]) => ThresholdInput[];
5
+ export declare const thresholdToParameter: (threshold: ThresholdInput) => PartParameter;
6
+ export declare const thresholdsToParameters: (thresholds: ThresholdInput[]) => PartParameter[];
@@ -0,0 +1,2 @@
1
+ export declare const capitalizeAll: (str: string) => string;
2
+ export declare const pluralize: (word: string, count: number) => string;
@@ -0,0 +1 @@
1
+ "use strict";const m=require("./other-TR0ap-t4.cjs");var K,Mr;function Fa(){if(Mr)return K;Mr=1;function e(){this.__data__=[],this.size=0}return K=e,K}var V,Gr;function D(){if(Gr)return V;Gr=1;function e(r,t){return r===t||r!==r&&t!==t}return V=e,V}var k,Dr;function L(){if(Dr)return k;Dr=1;var e=D();function r(t,a){for(var n=t.length;n--;)if(e(t[n][0],a))return n;return-1}return k=r,k}var z,Lr;function Ha(){if(Lr)return z;Lr=1;var e=L(),r=Array.prototype,t=r.splice;function a(n){var i=this.__data__,u=e(i,n);if(u<0)return!1;var s=i.length-1;return u==s?i.pop():t.call(i,u,1),--this.size,!0}return z=a,z}var $,Fr;function Ea(){if(Fr)return $;Fr=1;var e=L();function r(t){var a=this.__data__,n=e(a,t);return n<0?void 0:a[n][1]}return $=r,$}var J,Hr;function Ba(){if(Hr)return J;Hr=1;var e=L();function r(t){return e(this.__data__,t)>-1}return J=r,J}var X,Er;function Ua(){if(Er)return X;Er=1;var e=L();function r(t,a){var n=this.__data__,i=e(n,t);return i<0?(++this.size,n.push([t,a])):n[i][1]=a,this}return X=r,X}var W,Br;function F(){if(Br)return W;Br=1;var e=Fa(),r=Ha(),t=Ea(),a=Ba(),n=Ua();function i(u){var s=-1,o=u==null?0:u.length;for(this.clear();++s<o;){var c=u[s];this.set(c[0],c[1])}}return i.prototype.clear=e,i.prototype.delete=r,i.prototype.get=t,i.prototype.has=a,i.prototype.set=n,W=i,W}var Y,Ur;function Na(){if(Ur)return Y;Ur=1;var e=F();function r(){this.__data__=new e,this.size=0}return Y=r,Y}var Z,Nr;function Ka(){if(Nr)return Z;Nr=1;function e(r){var t=this.__data__,a=t.delete(r);return this.size=t.size,a}return Z=e,Z}var Q,Kr;function Va(){if(Kr)return Q;Kr=1;function e(r){return this.__data__.get(r)}return Q=e,Q}var ee,Vr;function ka(){if(Vr)return ee;Vr=1;function e(r){return this.__data__.has(r)}return ee=e,ee}var re,kr;function Ca(){if(kr)return re;kr=1;var e=typeof m.commonjsGlobal=="object"&&m.commonjsGlobal&&m.commonjsGlobal.Object===Object&&m.commonjsGlobal;return re=e,re}var te,zr;function A(){if(zr)return te;zr=1;var e=Ca(),r=typeof self=="object"&&self&&self.Object===Object&&self,t=e||r||Function("return this")();return te=t,te}var ae,$r;function Ra(){if($r)return ae;$r=1;var e=A(),r=e.Symbol;return ae=r,ae}var ne,Jr;function za(){if(Jr)return ne;Jr=1;var e=Ra(),r=Object.prototype,t=r.hasOwnProperty,a=r.toString,n=e?e.toStringTag:void 0;function i(u){var s=t.call(u,n),o=u[n];try{u[n]=void 0;var c=!0}catch{}var f=a.call(u);return c&&(s?u[n]=o:delete u[n]),f}return ne=i,ne}var ie,Xr;function $a(){if(Xr)return ie;Xr=1;var e=Object.prototype,r=e.toString;function t(a){return r.call(a)}return ie=t,ie}var ue,Wr;function H(){if(Wr)return ue;Wr=1;var e=Ra(),r=za(),t=$a(),a="[object Null]",n="[object Undefined]",i=e?e.toStringTag:void 0;function u(s){return s==null?s===void 0?n:a:i&&i in Object(s)?r(s):t(s)}return ue=u,ue}var se,Yr;function T(){if(Yr)return se;Yr=1;function e(r){var t=typeof r;return r!=null&&(t=="object"||t=="function")}return se=e,se}var oe,Zr;function Sr(){if(Zr)return oe;Zr=1;var e=H(),r=T(),t="[object AsyncFunction]",a="[object Function]",n="[object GeneratorFunction]",i="[object Proxy]";function u(s){if(!r(s))return!1;var o=e(s);return o==a||o==n||o==t||o==i}return oe=u,oe}var ce,Qr;function Ja(){if(Qr)return ce;Qr=1;var e=A(),r=e["__core-js_shared__"];return ce=r,ce}var fe,et;function Xa(){if(et)return fe;et=1;var e=Ja(),r=(function(){var a=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return a?"Symbol(src)_1."+a:""})();function t(a){return!!r&&r in a}return fe=t,fe}var ve,rt;function Wa(){if(rt)return ve;rt=1;var e=Function.prototype,r=e.toString;function t(a){if(a!=null){try{return r.call(a)}catch{}try{return a+""}catch{}}return""}return ve=t,ve}var _e,tt;function Ya(){if(tt)return _e;tt=1;var e=Sr(),r=Xa(),t=T(),a=Wa(),n=/[\\^$.*+?()[\]{}|]/g,i=/^\[object .+?Constructor\]$/,u=Function.prototype,s=Object.prototype,o=u.toString,c=s.hasOwnProperty,f=RegExp("^"+o.call(c).replace(n,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function _(h){if(!t(h)||r(h))return!1;var g=e(h)?f:i;return g.test(a(h))}return _e=_,_e}var he,at;function Za(){if(at)return he;at=1;function e(r,t){return r?.[t]}return he=e,he}var le,nt;function mr(){if(nt)return le;nt=1;var e=Ya(),r=Za();function t(a,n){var i=r(a,n);return e(i)?i:void 0}return le=t,le}var de,it;function Oa(){if(it)return de;it=1;var e=mr(),r=A(),t=e(r,"Map");return de=t,de}var pe,ut;function E(){if(ut)return pe;ut=1;var e=mr(),r=e(Object,"create");return pe=r,pe}var ge,st;function Qa(){if(st)return ge;st=1;var e=E();function r(){this.__data__=e?e(null):{},this.size=0}return ge=r,ge}var be,ot;function en(){if(ot)return be;ot=1;function e(r){var t=this.has(r)&&delete this.__data__[r];return this.size-=t?1:0,t}return be=e,be}var ye,ct;function rn(){if(ct)return ye;ct=1;var e=E(),r="__lodash_hash_undefined__",t=Object.prototype,a=t.hasOwnProperty;function n(i){var u=this.__data__;if(e){var s=u[i];return s===r?void 0:s}return a.call(u,i)?u[i]:void 0}return ye=n,ye}var qe,ft;function tn(){if(ft)return qe;ft=1;var e=E(),r=Object.prototype,t=r.hasOwnProperty;function a(n){var i=this.__data__;return e?i[n]!==void 0:t.call(i,n)}return qe=a,qe}var Ce,vt;function an(){if(vt)return Ce;vt=1;var e=E(),r="__lodash_hash_undefined__";function t(a,n){var i=this.__data__;return this.size+=this.has(a)?0:1,i[a]=e&&n===void 0?r:n,this}return Ce=t,Ce}var Re,_t;function nn(){if(_t)return Re;_t=1;var e=Qa(),r=en(),t=rn(),a=tn(),n=an();function i(u){var s=-1,o=u==null?0:u.length;for(this.clear();++s<o;){var c=u[s];this.set(c[0],c[1])}}return i.prototype.clear=e,i.prototype.delete=r,i.prototype.get=t,i.prototype.has=a,i.prototype.set=n,Re=i,Re}var Oe,ht;function un(){if(ht)return Oe;ht=1;var e=nn(),r=F(),t=Oa();function a(){this.size=0,this.__data__={hash:new e,map:new(t||r),string:new e}}return Oe=a,Oe}var Te,lt;function sn(){if(lt)return Te;lt=1;function e(r){var t=typeof r;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?r!=="__proto__":r===null}return Te=e,Te}var je,dt;function B(){if(dt)return je;dt=1;var e=sn();function r(t,a){var n=t.__data__;return e(a)?n[typeof a=="string"?"string":"hash"]:n.map}return je=r,je}var Ae,pt;function on(){if(pt)return Ae;pt=1;var e=B();function r(t){var a=e(this,t).delete(t);return this.size-=a?1:0,a}return Ae=r,Ae}var Ie,gt;function cn(){if(gt)return Ie;gt=1;var e=B();function r(t){return e(this,t).get(t)}return Ie=r,Ie}var Se,bt;function fn(){if(bt)return Se;bt=1;var e=B();function r(t){return e(this,t).has(t)}return Se=r,Se}var me,yt;function vn(){if(yt)return me;yt=1;var e=B();function r(t,a){var n=e(this,t),i=n.size;return n.set(t,a),this.size+=n.size==i?0:1,this}return me=r,me}var Pe,qt;function _n(){if(qt)return Pe;qt=1;var e=un(),r=on(),t=cn(),a=fn(),n=vn();function i(u){var s=-1,o=u==null?0:u.length;for(this.clear();++s<o;){var c=u[s];this.set(c[0],c[1])}}return i.prototype.clear=e,i.prototype.delete=r,i.prototype.get=t,i.prototype.has=a,i.prototype.set=n,Pe=i,Pe}var xe,Ct;function hn(){if(Ct)return xe;Ct=1;var e=F(),r=Oa(),t=_n(),a=200;function n(i,u){var s=this.__data__;if(s instanceof e){var o=s.__data__;if(!r||o.length<a-1)return o.push([i,u]),this.size=++s.size,this;s=this.__data__=new t(o)}return s.set(i,u),this.size=s.size,this}return xe=n,xe}var we,Rt;function ln(){if(Rt)return we;Rt=1;var e=F(),r=Na(),t=Ka(),a=Va(),n=ka(),i=hn();function u(s){var o=this.__data__=new e(s);this.size=o.size}return u.prototype.clear=r,u.prototype.delete=t,u.prototype.get=a,u.prototype.has=n,u.prototype.set=i,we=u,we}var Me,Ot;function Ta(){if(Ot)return Me;Ot=1;var e=mr(),r=(function(){try{var t=e(Object,"defineProperty");return t({},"",{}),t}catch{}})();return Me=r,Me}var Ge,Tt;function Pr(){if(Tt)return Ge;Tt=1;var e=Ta();function r(t,a,n){a=="__proto__"&&e?e(t,a,{configurable:!0,enumerable:!0,value:n,writable:!0}):t[a]=n}return Ge=r,Ge}var De,jt;function ja(){if(jt)return De;jt=1;var e=Pr(),r=D();function t(a,n,i){(i!==void 0&&!r(a[n],i)||i===void 0&&!(n in a))&&e(a,n,i)}return De=t,De}var Le,At;function dn(){if(At)return Le;At=1;function e(r){return function(t,a,n){for(var i=-1,u=Object(t),s=n(t),o=s.length;o--;){var c=s[r?o:++i];if(a(u[c],c,u)===!1)break}return t}}return Le=e,Le}var Fe,It;function pn(){if(It)return Fe;It=1;var e=dn(),r=e();return Fe=r,Fe}var P={exports:{}};P.exports;var St;function gn(){return St||(St=1,(function(e,r){var t=A(),a=r&&!r.nodeType&&r,n=a&&!0&&e&&!e.nodeType&&e,i=n&&n.exports===a,u=i?t.Buffer:void 0,s=u?u.allocUnsafe:void 0;function o(c,f){if(f)return c.slice();var _=c.length,h=s?s(_):new c.constructor(_);return c.copy(h),h}e.exports=o})(P,P.exports)),P.exports}var He,mt;function bn(){if(mt)return He;mt=1;var e=A(),r=e.Uint8Array;return He=r,He}var Ee,Pt;function yn(){if(Pt)return Ee;Pt=1;var e=bn();function r(t){var a=new t.constructor(t.byteLength);return new e(a).set(new e(t)),a}return Ee=r,Ee}var Be,xt;function qn(){if(xt)return Be;xt=1;var e=yn();function r(t,a){var n=a?e(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}return Be=r,Be}var Ue,wt;function Cn(){if(wt)return Ue;wt=1;function e(r,t){var a=-1,n=r.length;for(t||(t=Array(n));++a<n;)t[a]=r[a];return t}return Ue=e,Ue}var Ne,Mt;function Rn(){if(Mt)return Ne;Mt=1;var e=T(),r=Object.create,t=(function(){function a(){}return function(n){if(!e(n))return{};if(r)return r(n);a.prototype=n;var i=new a;return a.prototype=void 0,i}})();return Ne=t,Ne}var Ke,Gt;function On(){if(Gt)return Ke;Gt=1;function e(r,t){return function(a){return r(t(a))}}return Ke=e,Ke}var Ve,Dt;function Aa(){if(Dt)return Ve;Dt=1;var e=On(),r=e(Object.getPrototypeOf,Object);return Ve=r,Ve}var ke,Lt;function Ia(){if(Lt)return ke;Lt=1;var e=Object.prototype;function r(t){var a=t&&t.constructor,n=typeof a=="function"&&a.prototype||e;return t===n}return ke=r,ke}var ze,Ft;function Tn(){if(Ft)return ze;Ft=1;var e=Rn(),r=Aa(),t=Ia();function a(n){return typeof n.constructor=="function"&&!t(n)?e(r(n)):{}}return ze=a,ze}var $e,Ht;function M(){if(Ht)return $e;Ht=1;function e(r){return r!=null&&typeof r=="object"}return $e=e,$e}var Je,Et;function jn(){if(Et)return Je;Et=1;var e=H(),r=M(),t="[object Arguments]";function a(n){return r(n)&&e(n)==t}return Je=a,Je}var Xe,Bt;function Sa(){if(Bt)return Xe;Bt=1;var e=jn(),r=M(),t=Object.prototype,a=t.hasOwnProperty,n=t.propertyIsEnumerable,i=e((function(){return arguments})())?e:function(u){return r(u)&&a.call(u,"callee")&&!n.call(u,"callee")};return Xe=i,Xe}var We,Ut;function ma(){if(Ut)return We;Ut=1;var e=Array.isArray;return We=e,We}var Ye,Nt;function Pa(){if(Nt)return Ye;Nt=1;var e=9007199254740991;function r(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=e}return Ye=r,Ye}var Ze,Kt;function xr(){if(Kt)return Ze;Kt=1;var e=Sr(),r=Pa();function t(a){return a!=null&&r(a.length)&&!e(a)}return Ze=t,Ze}var Qe,Vt;function An(){if(Vt)return Qe;Vt=1;var e=xr(),r=M();function t(a){return r(a)&&e(a)}return Qe=t,Qe}var x={exports:{}},er,kt;function In(){if(kt)return er;kt=1;function e(){return!1}return er=e,er}x.exports;var zt;function xa(){return zt||(zt=1,(function(e,r){var t=A(),a=In(),n=r&&!r.nodeType&&r,i=n&&!0&&e&&!e.nodeType&&e,u=i&&i.exports===n,s=u?t.Buffer:void 0,o=s?s.isBuffer:void 0,c=o||a;e.exports=c})(x,x.exports)),x.exports}var rr,$t;function Sn(){if($t)return rr;$t=1;var e=H(),r=Aa(),t=M(),a="[object Object]",n=Function.prototype,i=Object.prototype,u=n.toString,s=i.hasOwnProperty,o=u.call(Object);function c(f){if(!t(f)||e(f)!=a)return!1;var _=r(f);if(_===null)return!0;var h=s.call(_,"constructor")&&_.constructor;return typeof h=="function"&&h instanceof h&&u.call(h)==o}return rr=c,rr}var tr,Jt;function mn(){if(Jt)return tr;Jt=1;var e=H(),r=Pa(),t=M(),a="[object Arguments]",n="[object Array]",i="[object Boolean]",u="[object Date]",s="[object Error]",o="[object Function]",c="[object Map]",f="[object Number]",_="[object Object]",h="[object RegExp]",g="[object Set]",y="[object String]",q="[object WeakMap]",C="[object ArrayBuffer]",j="[object DataView]",l="[object Float32Array]",U="[object Float64Array]",N="[object Int8Array]",I="[object Int16Array]",R="[object Int32Array]",b="[object Uint8Array]",d="[object Uint8ClampedArray]",G="[object Uint16Array]",p="[object Uint32Array]",v={};v[l]=v[U]=v[N]=v[I]=v[R]=v[b]=v[d]=v[G]=v[p]=!0,v[a]=v[n]=v[C]=v[i]=v[j]=v[u]=v[s]=v[o]=v[c]=v[f]=v[_]=v[h]=v[g]=v[y]=v[q]=!1;function S(O){return t(O)&&r(O.length)&&!!v[e(O)]}return tr=S,tr}var ar,Xt;function Pn(){if(Xt)return ar;Xt=1;function e(r){return function(t){return r(t)}}return ar=e,ar}var w={exports:{}};w.exports;var Wt;function xn(){return Wt||(Wt=1,(function(e,r){var t=Ca(),a=r&&!r.nodeType&&r,n=a&&!0&&e&&!e.nodeType&&e,i=n&&n.exports===a,u=i&&t.process,s=(function(){try{var o=n&&n.require&&n.require("util").types;return o||u&&u.binding&&u.binding("util")}catch{}})();e.exports=s})(w,w.exports)),w.exports}var nr,Yt;function wa(){if(Yt)return nr;Yt=1;var e=mn(),r=Pn(),t=xn(),a=t&&t.isTypedArray,n=a?r(a):e;return nr=n,nr}var ir,Zt;function Ma(){if(Zt)return ir;Zt=1;function e(r,t){if(!(t==="constructor"&&typeof r[t]=="function")&&t!="__proto__")return r[t]}return ir=e,ir}var ur,Qt;function wn(){if(Qt)return ur;Qt=1;var e=Pr(),r=D(),t=Object.prototype,a=t.hasOwnProperty;function n(i,u,s){var o=i[u];(!(a.call(i,u)&&r(o,s))||s===void 0&&!(u in i))&&e(i,u,s)}return ur=n,ur}var sr,ea;function Mn(){if(ea)return sr;ea=1;var e=wn(),r=Pr();function t(a,n,i,u){var s=!i;i||(i={});for(var o=-1,c=n.length;++o<c;){var f=n[o],_=u?u(i[f],a[f],f,i,a):void 0;_===void 0&&(_=a[f]),s?r(i,f,_):e(i,f,_)}return i}return sr=t,sr}var or,ra;function Gn(){if(ra)return or;ra=1;function e(r,t){for(var a=-1,n=Array(r);++a<r;)n[a]=t(a);return n}return or=e,or}var cr,ta;function Ga(){if(ta)return cr;ta=1;var e=9007199254740991,r=/^(?:0|[1-9]\d*)$/;function t(a,n){var i=typeof a;return n=n??e,!!n&&(i=="number"||i!="symbol"&&r.test(a))&&a>-1&&a%1==0&&a<n}return cr=t,cr}var fr,aa;function Dn(){if(aa)return fr;aa=1;var e=Gn(),r=Sa(),t=ma(),a=xa(),n=Ga(),i=wa(),u=Object.prototype,s=u.hasOwnProperty;function o(c,f){var _=t(c),h=!_&&r(c),g=!_&&!h&&a(c),y=!_&&!h&&!g&&i(c),q=_||h||g||y,C=q?e(c.length,String):[],j=C.length;for(var l in c)(f||s.call(c,l))&&!(q&&(l=="length"||g&&(l=="offset"||l=="parent")||y&&(l=="buffer"||l=="byteLength"||l=="byteOffset")||n(l,j)))&&C.push(l);return C}return fr=o,fr}var vr,na;function Ln(){if(na)return vr;na=1;function e(r){var t=[];if(r!=null)for(var a in Object(r))t.push(a);return t}return vr=e,vr}var _r,ia;function Fn(){if(ia)return _r;ia=1;var e=T(),r=Ia(),t=Ln(),a=Object.prototype,n=a.hasOwnProperty;function i(u){if(!e(u))return t(u);var s=r(u),o=[];for(var c in u)c=="constructor"&&(s||!n.call(u,c))||o.push(c);return o}return _r=i,_r}var hr,ua;function Da(){if(ua)return hr;ua=1;var e=Dn(),r=Fn(),t=xr();function a(n){return t(n)?e(n,!0):r(n)}return hr=a,hr}var lr,sa;function Hn(){if(sa)return lr;sa=1;var e=Mn(),r=Da();function t(a){return e(a,r(a))}return lr=t,lr}var dr,oa;function En(){if(oa)return dr;oa=1;var e=ja(),r=gn(),t=qn(),a=Cn(),n=Tn(),i=Sa(),u=ma(),s=An(),o=xa(),c=Sr(),f=T(),_=Sn(),h=wa(),g=Ma(),y=Hn();function q(C,j,l,U,N,I,R){var b=g(C,l),d=g(j,l),G=R.get(d);if(G){e(C,l,G);return}var p=I?I(b,d,l+"",C,j,R):void 0,v=p===void 0;if(v){var S=u(d),O=!S&&o(d),wr=!S&&!O&&h(d);p=d,S||O||wr?u(b)?p=b:s(b)?p=a(b):O?(v=!1,p=r(d,!0)):wr?(v=!1,p=t(d,!0)):p=[]:_(d)||i(d)?(p=b,i(b)?p=y(b):(!f(b)||c(b))&&(p=n(d))):v=!1}v&&(R.set(d,p),N(p,d,U,I,R),R.delete(d)),e(C,l,p)}return dr=q,dr}var pr,ca;function Bn(){if(ca)return pr;ca=1;var e=ln(),r=ja(),t=pn(),a=En(),n=T(),i=Da(),u=Ma();function s(o,c,f,_,h){o!==c&&t(c,function(g,y){if(h||(h=new e),n(g))a(o,c,y,f,s,_,h);else{var q=_?_(u(o,y),g,y+"",o,c,h):void 0;q===void 0&&(q=g),r(o,y,q)}},i)}return pr=s,pr}var gr,fa;function La(){if(fa)return gr;fa=1;function e(r){return r}return gr=e,gr}var br,va;function Un(){if(va)return br;va=1;function e(r,t,a){switch(a.length){case 0:return r.call(t);case 1:return r.call(t,a[0]);case 2:return r.call(t,a[0],a[1]);case 3:return r.call(t,a[0],a[1],a[2])}return r.apply(t,a)}return br=e,br}var yr,_a;function Nn(){if(_a)return yr;_a=1;var e=Un(),r=Math.max;function t(a,n,i){return n=r(n===void 0?a.length-1:n,0),function(){for(var u=arguments,s=-1,o=r(u.length-n,0),c=Array(o);++s<o;)c[s]=u[n+s];s=-1;for(var f=Array(n+1);++s<n;)f[s]=u[s];return f[n]=i(c),e(a,this,f)}}return yr=t,yr}var qr,ha;function Kn(){if(ha)return qr;ha=1;function e(r){return function(){return r}}return qr=e,qr}var Cr,la;function Vn(){if(la)return Cr;la=1;var e=Kn(),r=Ta(),t=La(),a=r?function(n,i){return r(n,"toString",{configurable:!0,enumerable:!1,value:e(i),writable:!0})}:t;return Cr=a,Cr}var Rr,da;function kn(){if(da)return Rr;da=1;var e=800,r=16,t=Date.now;function a(n){var i=0,u=0;return function(){var s=t(),o=r-(s-u);if(u=s,o>0){if(++i>=e)return arguments[0]}else i=0;return n.apply(void 0,arguments)}}return Rr=a,Rr}var Or,pa;function zn(){if(pa)return Or;pa=1;var e=Vn(),r=kn(),t=r(e);return Or=t,Or}var Tr,ga;function $n(){if(ga)return Tr;ga=1;var e=La(),r=Nn(),t=zn();function a(n,i){return t(r(n,i,e),n+"")}return Tr=a,Tr}var jr,ba;function Jn(){if(ba)return jr;ba=1;var e=D(),r=xr(),t=Ga(),a=T();function n(i,u,s){if(!a(s))return!1;var o=typeof u;return(o=="number"?r(s)&&t(u,s.length):o=="string"&&u in s)?e(s[u],i):!1}return jr=n,jr}var Ar,ya;function Xn(){if(ya)return Ar;ya=1;var e=$n(),r=Jn();function t(a){return e(function(n,i){var u=-1,s=i.length,o=s>1?i[s-1]:void 0,c=s>2?i[2]:void 0;for(o=a.length>3&&typeof o=="function"?(s--,o):void 0,c&&r(i[0],i[1],c)&&(o=s<3?void 0:o,s=1),n=Object(n);++u<s;){var f=i[u];f&&a(n,f,u,o)}return n})}return Ar=t,Ar}var Ir,qa;function Wn(){if(qa)return Ir;qa=1;var e=Bn(),r=Xn(),t=r(function(a,n,i){e(a,n,i)});return Ir=t,Ir}var Yn=Wn();const Zn=m.getDefaultExportFromCjs(Yn);exports.merge=Zn;