UNPKG

videx-3d

Version:

React 3D component library designed for sub surface visualizations in the browser

35 lines (34 loc) 1.2 kB
import { StoreApi, UseBoundStore } from 'zustand'; import { WellMapState } from './well-map-state'; /** * Context for providing `WellMap` state. * * @see {@link useWellMapState} * @see {@link WellMap} * * @group Contexts */ export declare const WellMapContext: import('react').Context<UseBoundStore<StoreApi<WellMapState>>>; /** * Allow child components of the `WellMap` component to get information from the well map state * * @example * const wellMapState = useWellMapState() * * const wellboresById = wellMapState(state => state.wellboresById) * const wellboresByName = wellMapState(state => state.wellboresByName) * const ratio = wellMapState(state => state.measures.ratio) * const domain = wellMapState(state => state.domain) * const range = wellMapState(state => state.measures.range) * const slotsById = wellMapState(state => state.slotsById) * const styles = wellMapState(state => state.styles) * const getSlotPosition = wellMapState(state => state.measures.getSlotPosition) * * @remarks * This is meant to be used for WellMap addons * * @see {@link WellMap} * * @group Hooks */ export declare const useWellMapState: () => UseBoundStore<StoreApi<WellMapState>>;