@equinor/videx-3d 5.1.0-beta
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/LICENSE.md +21 -0
- package/README.md +120 -0
- package/dist/chunk-BX-cez1_.js +23 -0
- package/dist/chunk-CnY6Tmof.js +358 -0
- package/dist/chunk-MFzFdEWm.js +591 -0
- package/dist/chunk-iY0wQ9Z6.js +887 -0
- package/dist/generators.js +711 -0
- package/dist/main.js +8405 -0
- package/dist/sdk.js +610 -0
- package/dist/shaderLib/color-conversion.glsl +33 -0
- package/dist/shaderLib/colors.glsl +8 -0
- package/dist/shaderLib/glyphs.glsl +78 -0
- package/dist/shaderLib/random.glsl +3 -0
- package/dist/shaderLib/remap.glsl +13 -0
- package/dist/shaderLib/render-number.glsl +74 -0
- package/dist/shaderLib/render-text.glsl +66 -0
- package/dist/shaderLib/rotation.glsl +19 -0
- package/dist/shaderLib/sdf-functions.glsl +18 -0
- package/dist/textures/normal_map.jpg +0 -0
- package/dist/types/common/color-ramps.d.ts +5 -0
- package/dist/types/common/types.d.ts +25 -0
- package/dist/types/components/Annotations/Annotations.d.ts +42 -0
- package/dist/types/components/Annotations/AnnotationsHMTL.d.ts +1 -0
- package/dist/types/components/Annotations/AnnotationsLayer.d.ts +46 -0
- package/dist/types/components/Annotations/AutoUpdate.d.ts +3 -0
- package/dist/types/components/Annotations/DefaultLabelComponent.d.ts +11 -0
- package/dist/types/components/Annotations/TestAnnotations.d.ts +12 -0
- package/dist/types/components/Annotations/annotations-renderer.d.ts +26 -0
- package/dist/types/components/Annotations/annotations-state.d.ts +88 -0
- package/dist/types/components/Annotations/helpers.d.ts +11 -0
- package/dist/types/components/Annotations/index.d.ts +8 -0
- package/dist/types/components/Annotations/types.d.ts +80 -0
- package/dist/types/components/Annotations/update-annotations.d.ts +12 -0
- package/dist/types/components/CameraTargetMarker/CameraTargetMarker.d.ts +29 -0
- package/dist/types/components/Distance/Distance.d.ts +35 -0
- package/dist/types/components/Distance/DistanceContext.d.ts +12 -0
- package/dist/types/components/Distance/index.d.ts +2 -0
- package/dist/types/components/EventEmitter/EventEmitter.d.ts +20 -0
- package/dist/types/components/EventEmitter/EventEmitterContext.d.ts +90 -0
- package/dist/types/components/EventEmitter/index.d.ts +3 -0
- package/dist/types/components/EventEmitter/picking-helper.d.ts +32 -0
- package/dist/types/components/EventEmitter/picking-material.d.ts +11 -0
- package/dist/types/components/Grids/BoxGrid/BoxGrid.d.ts +52 -0
- package/dist/types/components/Grids/Grid/Grid.d.ts +62 -0
- package/dist/types/components/Grids/Grid/GridAxesLabels.d.ts +24 -0
- package/dist/types/components/Grids/Grid/UtmGrid.d.ts +30 -0
- package/dist/types/components/Grids/Grid/grid-helpers.d.ts +2 -0
- package/dist/types/components/Grids/index.d.ts +5 -0
- package/dist/types/components/Highlighter/Highlighter.d.ts +23 -0
- package/dist/types/components/Highlighter/highlight-state.d.ts +43 -0
- package/dist/types/components/Highlighter/index.d.ts +2 -0
- package/dist/types/components/Html/DepthSelector.d.ts +1 -0
- package/dist/types/components/Html/OutputPanel/OutputPanel.d.ts +10 -0
- package/dist/types/components/Html/OutputPanel/index.d.ts +2 -0
- package/dist/types/components/Html/OutputPanel/output-panel-state.d.ts +38 -0
- package/dist/types/components/Html/Panel/Panel.d.ts +20 -0
- package/dist/types/components/Html/WellMap/ActiveTrack.d.ts +9 -0
- package/dist/types/components/Html/WellMap/DepthCursor.d.ts +8 -0
- package/dist/types/components/Html/WellMap/DepthReadout.d.ts +6 -0
- package/dist/types/components/Html/WellMap/Schematic.d.ts +15 -0
- package/dist/types/components/Html/WellMap/Track.d.ts +13 -0
- package/dist/types/components/Html/WellMap/WellMap.d.ts +47 -0
- package/dist/types/components/Html/WellMap/addons/WellMapCasingShoes.d.ts +14 -0
- package/dist/types/components/Html/WellMap/addons/WellMapCompletionIntervals.d.ts +15 -0
- package/dist/types/components/Html/WellMap/addons/WellMapFormations.d.ts +14 -0
- package/dist/types/components/Html/WellMap/addons/WellMapTvd.d.ts +14 -0
- package/dist/types/components/Html/WellMap/addons/index.d.ts +4 -0
- package/dist/types/components/Html/WellMap/index.d.ts +4 -0
- package/dist/types/components/Html/WellMap/themes.d.ts +13 -0
- package/dist/types/components/Html/WellMap/well-map-context.d.ts +34 -0
- package/dist/types/components/Html/WellMap/well-map-state.d.ts +38 -0
- package/dist/types/components/Html/index.d.ts +5 -0
- package/dist/types/components/ObservableGroup/ObservableGroup.d.ts +38 -0
- package/dist/types/components/SDFTest/SDFTest.d.ts +12 -0
- package/dist/types/components/Surfaces/Surface.d.ts +46 -0
- package/dist/types/components/Surfaces/SurfaceMaterial.d.ts +53 -0
- package/dist/types/components/Surfaces/index.d.ts +4 -0
- package/dist/types/components/Surfaces/surface-defs.d.ts +7 -0
- package/dist/types/components/Symbol/Symbol.d.ts +45 -0
- package/dist/types/components/Symbol/index.d.ts +1 -0
- package/dist/types/components/UtmArea/UtmArea.d.ts +37 -0
- package/dist/types/components/UtmArea/UtmAreaContext.d.ts +32 -0
- package/dist/types/components/UtmArea/UtmPosition.d.ts +26 -0
- package/dist/types/components/UtmArea/Wgs84Position.d.ts +26 -0
- package/dist/types/components/UtmArea/index.d.ts +4 -0
- package/dist/types/components/Wellbores/BasicTrajectory/BasicTrajectory.d.ts +27 -0
- package/dist/types/components/Wellbores/BasicTrajectory/basic-trajectory-defs.d.ts +3 -0
- package/dist/types/components/Wellbores/BasicTrajectory/index.d.ts +2 -0
- package/dist/types/components/Wellbores/Casings/CasingAnnotations/CasingAnnotations.d.ts +9 -0
- package/dist/types/components/Wellbores/Casings/CasingAnnotations/CasingLabel.d.ts +9 -0
- package/dist/types/components/Wellbores/Casings/CasingAnnotations/casing-annotations-defs.d.ts +1 -0
- package/dist/types/components/Wellbores/Casings/Casings.d.ts +42 -0
- package/dist/types/components/Wellbores/Casings/casings-defs.d.ts +6 -0
- package/dist/types/components/Wellbores/Casings/index.d.ts +5 -0
- package/dist/types/components/Wellbores/CompletionTools/CompletionAnnotations/CompletionAnnotations.d.ts +9 -0
- package/dist/types/components/Wellbores/CompletionTools/CompletionAnnotations/completion-annotations-defs.d.ts +1 -0
- package/dist/types/components/Wellbores/CompletionTools/CompletionTools.d.ts +31 -0
- package/dist/types/components/Wellbores/CompletionTools/Screen/screen-material.d.ts +8 -0
- package/dist/types/components/Wellbores/CompletionTools/completion-tools-defs.d.ts +4 -0
- package/dist/types/components/Wellbores/CompletionTools/index.d.ts +5 -0
- package/dist/types/components/Wellbores/DepthMarkers/DepthMarkerLabel.d.ts +11 -0
- package/dist/types/components/Wellbores/DepthMarkers/DepthMarkers.d.ts +27 -0
- package/dist/types/components/Wellbores/DepthMarkers/depth-markers-defs.d.ts +1 -0
- package/dist/types/components/Wellbores/DepthMarkers/index.d.ts +3 -0
- package/dist/types/components/Wellbores/FormationMarkers/FormationMarkerLabel.d.ts +10 -0
- package/dist/types/components/Wellbores/FormationMarkers/FormationMarkers.d.ts +33 -0
- package/dist/types/components/Wellbores/FormationMarkers/formation-markers-defs.d.ts +3 -0
- package/dist/types/components/Wellbores/FormationMarkers/index.d.ts +3 -0
- package/dist/types/components/Wellbores/Perforations/Perforations.d.ts +32 -0
- package/dist/types/components/Wellbores/Perforations/index.d.ts +2 -0
- package/dist/types/components/Wellbores/Perforations/perforations-defs.d.ts +3 -0
- package/dist/types/components/Wellbores/Perimeter/Perimeter.d.ts +29 -0
- package/dist/types/components/Wellbores/Perimeter/index.d.ts +2 -0
- package/dist/types/components/Wellbores/Perimeter/perimeter-defs.d.ts +3 -0
- package/dist/types/components/Wellbores/PositionMarkers/PositionMarkers.d.ts +12 -0
- package/dist/types/components/Wellbores/PositionMarkers/position-markers-defs.d.ts +3 -0
- package/dist/types/components/Wellbores/Shoes/Shoes.d.ts +34 -0
- package/dist/types/components/Wellbores/Shoes/index.d.ts +2 -0
- package/dist/types/components/Wellbores/Shoes/shoes-defs.d.ts +3 -0
- package/dist/types/components/Wellbores/TubeTrajectory/TubeTrajectory.d.ts +25 -0
- package/dist/types/components/Wellbores/TubeTrajectory/index.d.ts +2 -0
- package/dist/types/components/Wellbores/TubeTrajectory/tube-geometry-defs.d.ts +3 -0
- package/dist/types/components/Wellbores/Wellbore/Wellbore.d.ts +45 -0
- package/dist/types/components/Wellbores/Wellbore/WellboreContext.d.ts +19 -0
- package/dist/types/components/Wellbores/Wellbore/index.d.ts +2 -0
- package/dist/types/components/Wellbores/WellboreBounds/WellboreBounds.d.ts +47 -0
- package/dist/types/components/Wellbores/WellboreBounds/index.d.ts +2 -0
- package/dist/types/components/Wellbores/WellboreBounds/wellbore-bounds-defs.d.ts +1 -0
- package/dist/types/components/Wellbores/WellboreFormationColumn/WellboreFormationColumn.d.ts +30 -0
- package/dist/types/components/Wellbores/WellboreFormationColumn/index.d.ts +2 -0
- package/dist/types/components/Wellbores/WellboreFormationColumn/wellbore-formation-column-defs.d.ts +3 -0
- package/dist/types/components/Wellbores/WellboreLabel/WellboreAnnotationLabel.d.ts +10 -0
- package/dist/types/components/Wellbores/WellboreLabel/WellboreLabel.d.ts +25 -0
- package/dist/types/components/Wellbores/WellboreLabel/index.d.ts +3 -0
- package/dist/types/components/Wellbores/WellboreLabel/wellbore-label-defs.d.ts +1 -0
- package/dist/types/components/Wellbores/WellboreRibbon/WellboreRibbon.d.ts +22 -0
- package/dist/types/components/Wellbores/WellboreRibbon/WellboreRibbonContext.d.ts +16 -0
- package/dist/types/components/Wellbores/WellboreRibbon/index.d.ts +4 -0
- package/dist/types/components/Wellbores/WellboreRibbon/stripes/FormationsStripe.d.ts +30 -0
- package/dist/types/components/Wellbores/WellboreRibbon/stripes/MeasuredDepthStripe.d.ts +28 -0
- package/dist/types/components/Wellbores/WellboreSeismicSection/WellboreSeismicSection.d.ts +34 -0
- package/dist/types/components/Wellbores/WellboreSeismicSection/index.d.ts +2 -0
- package/dist/types/components/Wellbores/WellboreSeismicSection/wellbore-seismic-section-defs.d.ts +12 -0
- package/dist/types/components/Wellbores/Wells/Wells.d.ts +43 -0
- package/dist/types/components/Wellbores/Wells/index.d.ts +1 -0
- package/dist/types/contexts/DataContext.d.ts +15 -0
- package/dist/types/contexts/DataContextProvider.d.ts +33 -0
- package/dist/types/contexts/GeneratorsContext.d.ts +13 -0
- package/dist/types/contexts/GeneratorsContextProvider.d.ts +34 -0
- package/dist/types/contexts/GlyphsContext.d.ts +19 -0
- package/dist/types/contexts/GlyphsContextProvider.d.ts +29 -0
- package/dist/types/events/camera-events.d.ts +34 -0
- package/dist/types/events/depth-events.d.ts +22 -0
- package/dist/types/events/interaction-events.d.ts +7 -0
- package/dist/types/events/wellbore-events.d.ts +46 -0
- package/dist/types/generators/basic-trajectory-generator.d.ts +2 -0
- package/dist/types/generators/casing-annotations-generator.d.ts +8 -0
- package/dist/types/generators/casings-generator.d.ts +4 -0
- package/dist/types/generators/completion-annotations-generator.d.ts +7 -0
- package/dist/types/generators/completion-tools-generator.d.ts +2 -0
- package/dist/types/generators/depth-markers-generator.d.ts +3 -0
- package/dist/types/generators/formation-markers-generator.d.ts +2 -0
- package/dist/types/generators/index.d.ts +20 -0
- package/dist/types/generators/perforations-generator.d.ts +2 -0
- package/dist/types/generators/perimieter-generator.d.ts +2 -0
- package/dist/types/generators/position-markers-generator.d.ts +2 -0
- package/dist/types/generators/shoes-generator.d.ts +2 -0
- package/dist/types/generators/surface-generator.d.ts +4 -0
- package/dist/types/generators/tube-trajectory-generator.d.ts +2 -0
- package/dist/types/generators/wellbore-bounds-generator.d.ts +2 -0
- package/dist/types/generators/wellbore-formation-column-generator.d.ts +2 -0
- package/dist/types/generators/wellbore-label-generator.d.ts +7 -0
- package/dist/types/generators/wellbore-seismic-section-generator.d.ts +3 -0
- package/dist/types/hooks/useData.d.ts +25 -0
- package/dist/types/hooks/useGenerator.d.ts +43 -0
- package/dist/types/hooks/useWellboreContext.d.ts +13 -0
- package/dist/types/layers/layers.d.ts +6 -0
- package/dist/types/main.d.ts +48 -0
- package/dist/types/rendering/fullscreen-renderer.d.ts +9 -0
- package/dist/types/rendering/index.d.ts +2 -0
- package/dist/types/rendering/render-passes.d.ts +16 -0
- package/dist/types/sdk/data/DataLoader.d.ts +54 -0
- package/dist/types/sdk/data/GeneratorRegistry.d.ts +15 -0
- package/dist/types/sdk/data/Store.d.ts +29 -0
- package/dist/types/sdk/data/helpers/formations-helpers.d.ts +24 -0
- package/dist/types/sdk/data/helpers/well-helpers.d.ts +9 -0
- package/dist/types/sdk/data/types/Casing.d.ts +8 -0
- package/dist/types/sdk/data/types/CompletionTool.d.ts +11 -0
- package/dist/types/sdk/data/types/DepthReferencePoint.d.ts +1 -0
- package/dist/types/sdk/data/types/Formation.d.ts +32 -0
- package/dist/types/sdk/data/types/PerforationInterval.d.ts +9 -0
- package/dist/types/sdk/data/types/Pick.d.ts +8 -0
- package/dist/types/sdk/data/types/PositionLog.d.ts +17 -0
- package/dist/types/sdk/data/types/StratColumn.d.ts +18 -0
- package/dist/types/sdk/data/types/SurfaceMeta.d.ts +23 -0
- package/dist/types/sdk/data/types/SurfaceValues.d.ts +1 -0
- package/dist/types/sdk/data/types/Symbol.d.ts +6 -0
- package/dist/types/sdk/data/types/VerticalSlice.d.ts +9 -0
- package/dist/types/sdk/data/types/WellboreHeader.d.ts +15 -0
- package/dist/types/sdk/data/types/index.d.ts +11 -0
- package/dist/types/sdk/geometries/curve/curve-3d.d.ts +46 -0
- package/dist/types/sdk/geometries/curve/tube-geometry.d.ts +34 -0
- package/dist/types/sdk/geometries/delatin.d.ts +44 -0
- package/dist/types/sdk/geometries/fence.d.ts +3 -0
- package/dist/types/sdk/geometries/packing.d.ts +46 -0
- package/dist/types/sdk/geometries/triangulate-grid-delaunay.d.ts +8 -0
- package/dist/types/sdk/geometries/triangulate-grid.d.ts +28 -0
- package/dist/types/sdk/index.d.ts +39 -0
- package/dist/types/sdk/managers/CameraManager.d.ts +11 -0
- package/dist/types/sdk/managers/WellboreManager.d.ts +18 -0
- package/dist/types/sdk/materials/depth-material.d.ts +4 -0
- package/dist/types/sdk/materials/ribbon-material.d.ts +24 -0
- package/dist/types/sdk/materials/tube-material.d.ts +7 -0
- package/dist/types/sdk/materials/uv-material.d.ts +2 -0
- package/dist/types/sdk/projection/crs.d.ts +37 -0
- package/dist/types/sdk/types/common.d.ts +4 -0
- package/dist/types/sdk/utils/array.d.ts +0 -0
- package/dist/types/sdk/utils/colors.d.ts +2 -0
- package/dist/types/sdk/utils/conversions.d.ts +5 -0
- package/dist/types/sdk/utils/depth-reader.d.ts +5 -0
- package/dist/types/sdk/utils/elevation-map.d.ts +15 -0
- package/dist/types/sdk/utils/glyphs.d.ts +50 -0
- package/dist/types/sdk/utils/irapbin-parser.d.ts +17 -0
- package/dist/types/sdk/utils/num-array.d.ts +2 -0
- package/dist/types/sdk/utils/numbers.d.ts +5 -0
- package/dist/types/sdk/utils/packing.d.ts +1 -0
- package/dist/types/sdk/utils/scene.d.ts +2 -0
- package/dist/types/sdk/utils/segments.d.ts +4 -0
- package/dist/types/sdk/utils/strings.d.ts +2 -0
- package/dist/types/sdk/utils/trajectory.d.ts +59 -0
- package/dist/types/sdk/utils/trigonometry.d.ts +12 -0
- package/dist/types/sdk/utils/typed-2d-array.d.ts +52 -0
- package/dist/types/sdk/utils/typed-array.d.ts +2 -0
- package/dist/types/sdk/utils/vector-operations.d.ts +29 -0
- package/package.json +127 -0
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { PropsWithChildren } from 'react';
|
|
2
|
+
import { Color } from 'three';
|
|
3
|
+
/**
|
|
4
|
+
* Props for CameraTargetMarker
|
|
5
|
+
* @expand
|
|
6
|
+
*/
|
|
7
|
+
export type CameraTargetMarkerProps = {
|
|
8
|
+
radius?: number;
|
|
9
|
+
opacity?: number;
|
|
10
|
+
color?: number | string | Color;
|
|
11
|
+
fixedX?: number;
|
|
12
|
+
fixedY?: number;
|
|
13
|
+
fixedZ?: number;
|
|
14
|
+
renderOrder?: number;
|
|
15
|
+
depthTest?: boolean;
|
|
16
|
+
depthWrite?: boolean;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* A simple component for indicating the current camera target.
|
|
20
|
+
*
|
|
21
|
+
* NOTE: You may pass a child node to this component if you want to use a custom object representing the camera target. If you do, you'll have to
|
|
22
|
+
* manage the material settings yourself, as depthTest and depthWrite only have an effect on the default object's material.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* <CameraTargetMarker />
|
|
26
|
+
*
|
|
27
|
+
* @group Components
|
|
28
|
+
*/
|
|
29
|
+
export declare const CameraTargetMarker: ({ radius, opacity, color, fixedX, fixedY, fixedZ, renderOrder, depthTest, depthWrite, children, }: PropsWithChildren<CameraTargetMarkerProps>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Distance props
|
|
4
|
+
* @expand
|
|
5
|
+
*/
|
|
6
|
+
export type DistanceProps = {
|
|
7
|
+
min?: number;
|
|
8
|
+
max: number;
|
|
9
|
+
onDemand?: boolean;
|
|
10
|
+
children: ReactNode;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* The Distance component can be used to conditionally render other components.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* <Wellbore id={wellboreId}>
|
|
17
|
+
* { // DistanceContext provider }
|
|
18
|
+
* <WellboreBounds id={wellboreId}>
|
|
19
|
+
* <BasicTrajectory />
|
|
20
|
+
* <Distance min={0} max={2000}>
|
|
21
|
+
* <TubeTrajectory />
|
|
22
|
+
* </Distance>
|
|
23
|
+
* </WellboreBounds>
|
|
24
|
+
* </Wellbore>
|
|
25
|
+
*
|
|
26
|
+
* @remarks
|
|
27
|
+
* This component depends on a `DistanceContext` being provided by a parent component.
|
|
28
|
+
*
|
|
29
|
+
* @see [Storybook](/videx-3d/?path=/docs/components-misc-distance--docs)
|
|
30
|
+
* @see {@link DistanceContext}
|
|
31
|
+
* @see {@link WellboreBounds}
|
|
32
|
+
*
|
|
33
|
+
* @group Components
|
|
34
|
+
*/
|
|
35
|
+
export declare const Distance: ({ min, max, onDemand, children, }: DistanceProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export type DistanceContextProps = {
|
|
2
|
+
current: number;
|
|
3
|
+
};
|
|
4
|
+
/**
|
|
5
|
+
* A context for providing an object's distance to the camera. This will allow child
|
|
6
|
+
* components to use the `Distance` component.
|
|
7
|
+
*
|
|
8
|
+
* @see {@link Distance}
|
|
9
|
+
*
|
|
10
|
+
* @group Contexts
|
|
11
|
+
*/
|
|
12
|
+
export declare const DistanceContext: import('react').Context<DistanceContextProps>;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import { ReactNode } from 'react';
|
|
2
|
+
import { BufferGeometry, Material, Object3D } from 'three';
|
|
3
|
+
import { PickResult } from './picking-helper';
|
|
4
|
+
export type EmitterCallback = (e: PickResult) => void;
|
|
5
|
+
/**
|
|
6
|
+
* EventEmitter props
|
|
7
|
+
* @expand
|
|
8
|
+
*/
|
|
9
|
+
export type EventEmitterProps = {
|
|
10
|
+
autoUpdate?: boolean;
|
|
11
|
+
autoUpdateRenderPriority?: number;
|
|
12
|
+
threshold?: 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 | 10;
|
|
13
|
+
onResult?: EmitterCallback;
|
|
14
|
+
children?: ReactNode;
|
|
15
|
+
};
|
|
16
|
+
export type RenderableObject = Object3D & {
|
|
17
|
+
material: Material;
|
|
18
|
+
geometry: BufferGeometry;
|
|
19
|
+
};
|
|
20
|
+
export declare const EventEmitter: ({ autoUpdate, autoUpdateRenderPriority, threshold, onResult, children, }: EventEmitterProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
import { Camera, Object3D } from 'three';
|
|
2
|
+
import { Vec2, Vec3 } from '../../sdk';
|
|
3
|
+
export type KeysPressed = {
|
|
4
|
+
altKey: boolean;
|
|
5
|
+
ctrlKey: boolean;
|
|
6
|
+
shiftKey: boolean;
|
|
7
|
+
};
|
|
8
|
+
export type EventEmitterCallbackEvent = {
|
|
9
|
+
target: Object3D;
|
|
10
|
+
source: Object3D;
|
|
11
|
+
instanceIndex?: number;
|
|
12
|
+
position?: Vec3;
|
|
13
|
+
pointer: Vec2;
|
|
14
|
+
camera: Camera;
|
|
15
|
+
domElement: HTMLElement;
|
|
16
|
+
keys: KeysPressed;
|
|
17
|
+
ref: any;
|
|
18
|
+
};
|
|
19
|
+
export type EventEmitterCallback = (event: EventEmitterCallbackEvent) => void;
|
|
20
|
+
export type Listener = {
|
|
21
|
+
object: Object3D;
|
|
22
|
+
ref?: any;
|
|
23
|
+
threshold?: number;
|
|
24
|
+
handlers: Record<string, EventEmitterCallback>;
|
|
25
|
+
};
|
|
26
|
+
export type Emitter = {
|
|
27
|
+
source: Object3D;
|
|
28
|
+
depth: number;
|
|
29
|
+
listener: number;
|
|
30
|
+
instanced: boolean;
|
|
31
|
+
instanceCount: number;
|
|
32
|
+
threshold: number;
|
|
33
|
+
};
|
|
34
|
+
export type ObjectMapEntry = {
|
|
35
|
+
emitter: number;
|
|
36
|
+
index: number;
|
|
37
|
+
};
|
|
38
|
+
export type EventEmitterContextProps = {
|
|
39
|
+
register: (listener: Listener) => () => void;
|
|
40
|
+
update: () => void;
|
|
41
|
+
};
|
|
42
|
+
/**
|
|
43
|
+
* Context for registering event handlers to the `EventEmitter`
|
|
44
|
+
*
|
|
45
|
+
* @see {@link EventEmitter}
|
|
46
|
+
*
|
|
47
|
+
* @group Contexts
|
|
48
|
+
*/
|
|
49
|
+
export declare const EventEmitterContext: import('react').Context<EventEmitterContextProps>;
|
|
50
|
+
/**
|
|
51
|
+
* Used to register event handlers for renderable components.
|
|
52
|
+
*
|
|
53
|
+
* @example
|
|
54
|
+
* const eventHandler = useEventEmitter()
|
|
55
|
+
*
|
|
56
|
+
* @remarks
|
|
57
|
+
* The generator is an async function that process and returns data required
|
|
58
|
+
* by your components, such as geometry for a mesh.
|
|
59
|
+
*
|
|
60
|
+
* An optional threshold value may be provided in the register method. This is used
|
|
61
|
+
* to weight the distance when performing GPU picking, making objects with a
|
|
62
|
+
* higher threshold more likely to be hit. This is usually used for thin/small objects,
|
|
63
|
+
* which may otherwise be hard to hit.
|
|
64
|
+
* @example
|
|
65
|
+
*
|
|
66
|
+
* useEffect(() => {
|
|
67
|
+
* let unregister: (() => void) | null = null
|
|
68
|
+
* if (eventHandler && ref.current) {
|
|
69
|
+
* const handlers: Record<string, EventEmitterCallback> = {}
|
|
70
|
+
*
|
|
71
|
+
* if (onPointerClick) handlers.click = onPointerClick
|
|
72
|
+
* if (onPointerEnter) handlers.enter = onPointerEnter
|
|
73
|
+
* if (onPointerLeave) handlers.leave = onPointerLeave
|
|
74
|
+
* if (onPointerMove) handlers.move = onPointerMove
|
|
75
|
+
*
|
|
76
|
+
* if (Object.keys(handlers).length) {
|
|
77
|
+
* unregister = eventHandler.register(ref.current, handlers, id)
|
|
78
|
+
* }
|
|
79
|
+
* }
|
|
80
|
+
*
|
|
81
|
+
* return () => {
|
|
82
|
+
* if (unregister) unregister()
|
|
83
|
+
* }
|
|
84
|
+
* }, [eventHandler, onPointerClick, onPointerEnter, onPointerLeave, onPointerMove])
|
|
85
|
+
*
|
|
86
|
+
* @see {@link EventEmitter}
|
|
87
|
+
*
|
|
88
|
+
* @group Hooks
|
|
89
|
+
*/
|
|
90
|
+
export declare const useEventEmitter: () => EventEmitterContextProps;
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { PerspectiveCamera, Scene, Vector2, WebGLRenderer } from 'three';
|
|
2
|
+
import { Vec2, Vec3 } from '../../sdk';
|
|
3
|
+
import { Emitter, Listener } from './EventEmitterContext';
|
|
4
|
+
export type PickedObject = {
|
|
5
|
+
emitter: Emitter;
|
|
6
|
+
index: number;
|
|
7
|
+
};
|
|
8
|
+
export type PickResult = {
|
|
9
|
+
match: PickedObject | null;
|
|
10
|
+
position: Vec3;
|
|
11
|
+
point: Vec2;
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* Used internally by the `EventEmitter` component
|
|
15
|
+
* @internal
|
|
16
|
+
*/
|
|
17
|
+
export declare class PickingHelper {
|
|
18
|
+
private _size;
|
|
19
|
+
private _radius;
|
|
20
|
+
private _pbo;
|
|
21
|
+
private _buffer;
|
|
22
|
+
private _material;
|
|
23
|
+
constructor(options?: {});
|
|
24
|
+
private traverseObject;
|
|
25
|
+
updateListeners: () => void;
|
|
26
|
+
addListener: (listener: Listener) => void;
|
|
27
|
+
getListener: (id: number) => Listener | undefined;
|
|
28
|
+
removeListener: (id: number) => void;
|
|
29
|
+
render(pointer: Vector2, renderer: WebGLRenderer, scene: Scene, camera: PerspectiveCamera): Promise<PickResult>;
|
|
30
|
+
private pick;
|
|
31
|
+
dispose(): void;
|
|
32
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { Camera, Object3D, Scene, ShaderMaterial, WebGLRenderer } from 'three';
|
|
2
|
+
import { BufferGeometry } from 'three/webgpu';
|
|
3
|
+
import { Emitter, Listener } from './EventEmitterContext';
|
|
4
|
+
export declare class PickingMaterial extends ShaderMaterial {
|
|
5
|
+
listeners: Map<number, Listener>;
|
|
6
|
+
emitters: Map<number, Emitter>;
|
|
7
|
+
currentObjectMap: Array<number> | null;
|
|
8
|
+
constructor();
|
|
9
|
+
dispose(): void;
|
|
10
|
+
onBeforeRender(_renderer: WebGLRenderer, _scene: Scene, _camera: Camera, _geometry: BufferGeometry, object: Object3D): void;
|
|
11
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
import { PropsWithChildren } from 'react';
|
|
2
|
+
import { Color } from 'three';
|
|
3
|
+
import { CommonComponentProps } from '../../../common/types';
|
|
4
|
+
import { Vec3 } from '../../../sdk/types/common';
|
|
5
|
+
import { BoxPadding } from '../../ObservableGroup/ObservableGroup';
|
|
6
|
+
/**
|
|
7
|
+
* BoxGrid props
|
|
8
|
+
* @expand
|
|
9
|
+
*/
|
|
10
|
+
export type BoxGridProps = CommonComponentProps & {
|
|
11
|
+
size?: Vec3;
|
|
12
|
+
cellSize?: number;
|
|
13
|
+
subDivisions?: number;
|
|
14
|
+
gridScale?: Vec3;
|
|
15
|
+
gridOrigin?: Vec3;
|
|
16
|
+
originValue?: Vec3;
|
|
17
|
+
gridLineWidth?: number;
|
|
18
|
+
background?: string | Color | number;
|
|
19
|
+
backgroundOpacity?: number;
|
|
20
|
+
opacity?: number;
|
|
21
|
+
gridColorMajor?: string | number | Color;
|
|
22
|
+
gridColorMinor?: string | number | Color;
|
|
23
|
+
axesColor?: string | number | Color;
|
|
24
|
+
axesLineWidth?: number;
|
|
25
|
+
axesTickSize?: number;
|
|
26
|
+
enableProjection?: boolean;
|
|
27
|
+
projectionColor?: string | number | Color;
|
|
28
|
+
projectionResolution?: number;
|
|
29
|
+
projectionRefreshRate?: number;
|
|
30
|
+
showRulers?: boolean;
|
|
31
|
+
autoSize?: boolean;
|
|
32
|
+
autoSizePadding?: number | Vec3 | BoxPadding;
|
|
33
|
+
autoSizeUpdateRate?: number;
|
|
34
|
+
};
|
|
35
|
+
/**
|
|
36
|
+
* Renders 5 grid planes in a box form (bottom and sides). See `Grid` for more info.
|
|
37
|
+
*
|
|
38
|
+
* @example
|
|
39
|
+
* <BoxGrid
|
|
40
|
+
* size={[5000, 2000, 5000]}
|
|
41
|
+
* cellSize={100}
|
|
42
|
+
* gridLineWidth={0.01}
|
|
43
|
+
* axesColor="#eee"
|
|
44
|
+
* opacity={0.8}
|
|
45
|
+
* />
|
|
46
|
+
*
|
|
47
|
+
* @see [Storybook](/videx-3d/?path=/docs/components-grids-boxgrid--docs)
|
|
48
|
+
* @see {@link Grid}
|
|
49
|
+
*
|
|
50
|
+
* @group Components
|
|
51
|
+
*/
|
|
52
|
+
export declare const BoxGrid: ({ name, visible, castShadow, receiveShadow, layers, renderOrder, userData, size, cellSize, gridScale, gridOrigin, originValue, subDivisions, position, gridLineWidth, background, backgroundOpacity, opacity, gridColorMajor, gridColorMinor, axesColor, axesLineWidth, axesTickSize, enableProjection, projectionColor, projectionResolution, projectionRefreshRate, showRulers, autoSize, autoSizePadding, autoSizeUpdateRate, children, }: PropsWithChildren<BoxGridProps>) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import { Color, Texture } from 'three';
|
|
2
|
+
import { CommonComponentProps } from '../../../common/types';
|
|
3
|
+
import { Vec2 } from '../../../sdk/types/common';
|
|
4
|
+
/**
|
|
5
|
+
* Grid props
|
|
6
|
+
* @expand
|
|
7
|
+
*/
|
|
8
|
+
export type GridProps = CommonComponentProps & {
|
|
9
|
+
plane: 'xz' | 'xy' | 'zy';
|
|
10
|
+
size: Vec2;
|
|
11
|
+
cellSize?: number;
|
|
12
|
+
subDivisions?: number;
|
|
13
|
+
gridOrigin?: Vec2;
|
|
14
|
+
gridScale?: Vec2;
|
|
15
|
+
background?: string | Color | number;
|
|
16
|
+
backgroundOpacity?: number;
|
|
17
|
+
opacity?: number;
|
|
18
|
+
gridColorMajor?: string | number | Color;
|
|
19
|
+
gridColorMinor?: string | number | Color;
|
|
20
|
+
gridLineWidth?: number;
|
|
21
|
+
showAxes?: boolean;
|
|
22
|
+
showAxesLabels?: boolean;
|
|
23
|
+
trimAxesLabels?: boolean;
|
|
24
|
+
axesOffset?: Vec2;
|
|
25
|
+
axesColor?: string | number | Color;
|
|
26
|
+
axesLineWidth?: number;
|
|
27
|
+
axesTickSize?: number;
|
|
28
|
+
originValue?: Vec2;
|
|
29
|
+
radial?: boolean;
|
|
30
|
+
dynamicSegments?: boolean;
|
|
31
|
+
showRulers?: boolean;
|
|
32
|
+
rulerColor?: string | number | Color;
|
|
33
|
+
rulerLineWidth?: number;
|
|
34
|
+
rulerOpacity?: number;
|
|
35
|
+
planeOffset?: number;
|
|
36
|
+
dynamicCellSize?: boolean;
|
|
37
|
+
cellSizeDistanceFactors?: number[][];
|
|
38
|
+
side?: 'front' | 'back' | 'both';
|
|
39
|
+
texture?: Texture;
|
|
40
|
+
textureMix?: number;
|
|
41
|
+
enableProjection?: boolean;
|
|
42
|
+
projectionDistance?: number;
|
|
43
|
+
projectionColor?: string | number | Color;
|
|
44
|
+
projectionResolution?: number;
|
|
45
|
+
projectionRefreshRate?: number;
|
|
46
|
+
onRulerUpdate?: ((coords: Vec2 | null) => void) | null;
|
|
47
|
+
};
|
|
48
|
+
/**
|
|
49
|
+
* Renders an axis aligned grid plane (xz, xy or zy).
|
|
50
|
+
*
|
|
51
|
+
* @example
|
|
52
|
+
* <Grid plane="xz" size={[1000, 1000]} cellSize={10} />
|
|
53
|
+
*
|
|
54
|
+
* @remarks
|
|
55
|
+
* The Grid component is very flexible and has many different options which allows you
|
|
56
|
+
* to customize both behaviours and appearances. See the storybook linked below for examples.
|
|
57
|
+
*
|
|
58
|
+
* @see [Storybook](/videx-3d/?path=/docs/components-grids-grid--docs)
|
|
59
|
+
*
|
|
60
|
+
* @group Components
|
|
61
|
+
*/
|
|
62
|
+
export declare const Grid: ({ plane, size, position, gridOrigin, gridScale, cellSize, subDivisions, background, backgroundOpacity, opacity, gridColorMajor, gridColorMinor, gridLineWidth, showAxes, showAxesLabels, trimAxesLabels, axesOffset, axesColor, axesLineWidth, axesTickSize, originValue, radial, dynamicSegments, showRulers, rulerColor, rulerLineWidth, rulerOpacity, planeOffset, dynamicCellSize, cellSizeDistanceFactors, side, onRulerUpdate, texture, textureMix, enableProjection, projectionDistance, projectionColor, projectionResolution, projectionRefreshRate, name, userData, renderOrder, visible, castShadow, receiveShadow, layers, }: GridProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { Color } from 'three';
|
|
2
|
+
import { Vec2 } from '../../../sdk/types/common';
|
|
3
|
+
export type GridAxesLabelsProps = {
|
|
4
|
+
scale: Vec2;
|
|
5
|
+
units: number;
|
|
6
|
+
start: Vec2;
|
|
7
|
+
originOffset: Vec2;
|
|
8
|
+
size: Vec2;
|
|
9
|
+
axesTickSize: number;
|
|
10
|
+
plane: 'xz' | 'xy' | 'zy';
|
|
11
|
+
color?: string | number | Color;
|
|
12
|
+
side?: 'front' | 'back' | 'both';
|
|
13
|
+
axesOffset: Vec2;
|
|
14
|
+
trimAxesLabels: boolean;
|
|
15
|
+
renderOrder?: number;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Adds grid axes and labels to a `Grid` component. Used internally by the `Grid` component.
|
|
19
|
+
*
|
|
20
|
+
* @internal
|
|
21
|
+
*
|
|
22
|
+
* @group Components
|
|
23
|
+
*/
|
|
24
|
+
export declare const GridAxesLabels: ({ scale, start, size, units, originOffset, axesOffset, axesTickSize, plane, color, side, trimAxesLabels, renderOrder, }: GridAxesLabelsProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { GridProps } from './Grid';
|
|
2
|
+
/**
|
|
3
|
+
* UtmGrid props
|
|
4
|
+
* @expand
|
|
5
|
+
*/
|
|
6
|
+
export type UtmGridProps = GridProps & {
|
|
7
|
+
relativeValues?: boolean;
|
|
8
|
+
};
|
|
9
|
+
/**
|
|
10
|
+
* A convenience component for setting up a Grid component with Utm coordinates.
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* <UtmGrid
|
|
14
|
+
* size={[30000, 30000]}
|
|
15
|
+
* cellSize={1000}
|
|
16
|
+
* subDivisions={5}
|
|
17
|
+
* gridLineWidth={0.015}
|
|
18
|
+
* opacity={0.9}
|
|
19
|
+
* showAxes
|
|
20
|
+
* showRulers
|
|
21
|
+
* />
|
|
22
|
+
*
|
|
23
|
+
* @remarks
|
|
24
|
+
* This component needs to be a child of the `UtmArea` component in order to work.
|
|
25
|
+
*
|
|
26
|
+
* @see {@link Grid}
|
|
27
|
+
*
|
|
28
|
+
* @group Components
|
|
29
|
+
*/
|
|
30
|
+
export declare const UtmGrid: (props: UtmGridProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { Blending, Color } from 'three';
|
|
2
|
+
export type HighlighterProps = {
|
|
3
|
+
color?: string | number | Color;
|
|
4
|
+
blending?: Blending;
|
|
5
|
+
renderOrder?: number;
|
|
6
|
+
};
|
|
7
|
+
/**
|
|
8
|
+
* Adds highlighting to rendered objects by rendering a "ghost" object on top it.
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* <Highlighter />
|
|
12
|
+
*
|
|
13
|
+
* @remarks
|
|
14
|
+
* This component manages highlights in a global state and needs to be added to
|
|
15
|
+
* enable it as a feature. To interact with this component, you must use the
|
|
16
|
+
* `useHighlighter` hook from another component.
|
|
17
|
+
*
|
|
18
|
+
* @see {@link useHighlighter}
|
|
19
|
+
* @see {@link EventEmitter}
|
|
20
|
+
*
|
|
21
|
+
* @group Components
|
|
22
|
+
*/
|
|
23
|
+
export declare const Highlighter: ({ color, blending, renderOrder, }: HighlighterProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
import { Line, Mesh, Object3D } from 'three';
|
|
2
|
+
type ObjectRef = {
|
|
3
|
+
object: Mesh | Line;
|
|
4
|
+
instanceIndex?: number;
|
|
5
|
+
};
|
|
6
|
+
type HighlightState = {
|
|
7
|
+
highlighted: ObjectRef[];
|
|
8
|
+
set: (partial: ((state: HighlightState) => Partial<HighlightState>) | Partial<HighlightState>) => void;
|
|
9
|
+
};
|
|
10
|
+
export declare const useHighlightState: import('zustand').UseBoundStore<import('zustand').StoreApi<HighlightState>>;
|
|
11
|
+
/**
|
|
12
|
+
* Allows a component to interact with the `Highlighter` handler component.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* const highlighter = useHighlighter()
|
|
16
|
+
*
|
|
17
|
+
* return (
|
|
18
|
+
* <Wellbore
|
|
19
|
+
* id={wellbore.id}
|
|
20
|
+
* ...
|
|
21
|
+
* onPointerEnter={async (event) => {
|
|
22
|
+
* if (!isSelected) {
|
|
23
|
+
* highlighter.highlight(event.target)
|
|
24
|
+
* }
|
|
25
|
+
* }}
|
|
26
|
+
* onPointerLeave={async () => {
|
|
27
|
+
* highlighter.removeAll()
|
|
28
|
+
* }}
|
|
29
|
+
* ...
|
|
30
|
+
* />
|
|
31
|
+
* )
|
|
32
|
+
*
|
|
33
|
+
* @see {@link EventEmitter}
|
|
34
|
+
* @see {@link Highlighter}
|
|
35
|
+
*
|
|
36
|
+
* @group Hooks
|
|
37
|
+
*/
|
|
38
|
+
export declare const useHighlighter: () => {
|
|
39
|
+
highlight: (obj: Object3D, index?: number) => void;
|
|
40
|
+
removeHighlight: (obj: Object3D, index?: number) => void;
|
|
41
|
+
removeAll: () => void;
|
|
42
|
+
};
|
|
43
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare const DepthSelector: () => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { PanelProps } from '../Panel/Panel';
|
|
2
|
+
/**
|
|
3
|
+
* The `OutputPanel` is mainly intended as an example of the `Panel` component.
|
|
4
|
+
* It is used in storybooks as a debug/info panel. Not recommended to use for production.
|
|
5
|
+
* @see {@link useOutputPanel}
|
|
6
|
+
* @see {@link Panel}
|
|
7
|
+
* @internal
|
|
8
|
+
* @group Components
|
|
9
|
+
*/
|
|
10
|
+
export declare const OutputPanel: (panelProps: PanelProps) => import("react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
export type OutputPanelDetails = Record<string, {
|
|
2
|
+
label: string;
|
|
3
|
+
value: string | number;
|
|
4
|
+
}>;
|
|
5
|
+
export type OutputPanelGroup = {
|
|
6
|
+
label: string;
|
|
7
|
+
value?: string | number;
|
|
8
|
+
details?: OutputPanelDetails;
|
|
9
|
+
color?: string;
|
|
10
|
+
order?: number;
|
|
11
|
+
};
|
|
12
|
+
export type OutputPanelState = {
|
|
13
|
+
groups: Record<string, OutputPanelGroup>;
|
|
14
|
+
set: (partial: ((state: OutputPanelState) => Partial<OutputPanelState>) | Partial<OutputPanelState>) => void;
|
|
15
|
+
has: (id: string) => boolean;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Global state for `OutputPanel`
|
|
19
|
+
* @see {@link useOutputPanel}
|
|
20
|
+
* @internal
|
|
21
|
+
* @group Hooks
|
|
22
|
+
*/
|
|
23
|
+
export declare const useOutputPanelState: import('zustand').UseBoundStore<import('zustand').StoreApi<OutputPanelState>>;
|
|
24
|
+
/**
|
|
25
|
+
* Allow interaction with the `OutputPanel` component.
|
|
26
|
+
* The `OutputPanel` is mainly used as an example of the `Panel` component.
|
|
27
|
+
* It is used in storybooks as a debug/info panel. Not recommended to use for production.
|
|
28
|
+
* @see {@link OutputPanel}
|
|
29
|
+
* @internal
|
|
30
|
+
* @group Hooks
|
|
31
|
+
*/
|
|
32
|
+
export declare const useOutputPanel: () => {
|
|
33
|
+
add: (id: string, group: OutputPanelGroup) => void;
|
|
34
|
+
remove: (id: string) => void;
|
|
35
|
+
removeAll: () => void;
|
|
36
|
+
update: (id: string, value: string | number, details?: Record<string, string | number> | null) => void;
|
|
37
|
+
has: (id: string) => boolean;
|
|
38
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Panel props
|
|
3
|
+
* @expand
|
|
4
|
+
*/
|
|
5
|
+
export type PanelProps = {
|
|
6
|
+
width?: number;
|
|
7
|
+
height?: number;
|
|
8
|
+
offset?: [number, number];
|
|
9
|
+
opacity?: number;
|
|
10
|
+
padding?: number;
|
|
11
|
+
origin?: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
|
|
12
|
+
};
|
|
13
|
+
/**
|
|
14
|
+
* A simple HTML panel that can be used as an overlay on the 3d canvas.
|
|
15
|
+
* @see {@link OutputPanel}
|
|
16
|
+
* @group Components
|
|
17
|
+
*/
|
|
18
|
+
export declare const Panel: import('react').ForwardRefExoticComponent<PanelProps & {
|
|
19
|
+
children?: import('react').ReactNode | undefined;
|
|
20
|
+
} & import('react').RefAttributes<HTMLDivElement>>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
type Props = {
|
|
2
|
+
wellboreId: string;
|
|
3
|
+
color?: string;
|
|
4
|
+
opacity?: number;
|
|
5
|
+
width?: number;
|
|
6
|
+
dashed?: boolean;
|
|
7
|
+
};
|
|
8
|
+
export declare const ActiveTrack: ({ wellboreId, opacity, width, dashed, }: Props) => import("react/jsx-runtime").JSX.Element | null;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { PropsWithChildren } from 'react';
|
|
2
|
+
import { WellboreHeader } from '../../../sdk';
|
|
3
|
+
type Props = {
|
|
4
|
+
selected?: string;
|
|
5
|
+
color?: string;
|
|
6
|
+
setSelected?: (wellbore: string, depth: number) => void;
|
|
7
|
+
depth?: number;
|
|
8
|
+
setDepth?: (depth: number) => void;
|
|
9
|
+
onWellboreOver?: (wellbore: WellboreHeader | null, depth: number | undefined) => void;
|
|
10
|
+
colorMap?: Record<string, string>;
|
|
11
|
+
interactive?: boolean;
|
|
12
|
+
depthCursor?: boolean;
|
|
13
|
+
};
|
|
14
|
+
export declare const Schematic: ({ selected, setSelected, depth, setDepth, onWellboreOver, color, colorMap, interactive, depthCursor, children, }: PropsWithChildren<Props>) => import("react/jsx-runtime").JSX.Element;
|
|
15
|
+
export {};
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { WellboreHeader } from '../../../sdk';
|
|
2
|
+
type Props = {
|
|
3
|
+
wellboreId: string;
|
|
4
|
+
slot: number;
|
|
5
|
+
isSelected: boolean;
|
|
6
|
+
setSelected?: (wellbore: string, depth: number) => void;
|
|
7
|
+
setDepth?: (depth: number) => void;
|
|
8
|
+
onWellboreOver?: (wellbore: WellboreHeader | null, depth: number | undefined) => void;
|
|
9
|
+
interactive: boolean;
|
|
10
|
+
color?: string;
|
|
11
|
+
};
|
|
12
|
+
export declare const Track: ({ wellboreId, slot, isSelected, setSelected, setDepth, onWellboreOver, interactive, color, }: Props) => import("react/jsx-runtime").JSX.Element | null;
|
|
13
|
+
export {};
|