Skip to content

Commit

Permalink
fix: Property "setControllerDefaultZoom" does not exist on type "Well…
Browse files Browse the repository at this point in the history
…LogController" (equinor#2136)

…LogController"

Co-authored-by: DShamakin <denis.shamakin@emerson.com>
Co-authored-by: t0oF <93762994+w1nklr@users.noreply.github.com>
  • Loading branch information
3 people authored Jul 8, 2024
1 parent 888d147 commit a2390e2
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -162,7 +162,8 @@ const Template = (args) => {
if (infoRef.current) infoRef.current.innerHTML = info;
};

const [controller, setController] = React.useState(null); // the first WellLog
const [controller, setController] =
React.useState<WellLogController | null>(null); // the first WellLog
const [controllers, setControllers] = React.useState<WellLogController[]>(
[]
); // all WellLogs
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ import { getDiscreteMeta, indexOfElementByName } from "./utils/tracks";

import type WellLogView from "./components/WellLogView";
import type {
WellLogController,
WellLogViewOptions,
TrackMouseEvent,
} from "./components/WellLogView";
Expand Down Expand Up @@ -118,7 +119,8 @@ const StoryTemplate = (args) => {
const setInfo = function (info) {
if (infoRef.current) infoRef.current.innerHTML = info;
};
const [controller, setController] = React.useState(null);
const [controller, setController] =
React.useState<WellLogController | null>(null);
const onCreateController = React.useCallback(
(controller) => {
setController(controller);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -931,6 +931,7 @@ export interface WellLogController {
getContentSelection(): [number | undefined, number | undefined]; // [current, pinned]
setContentScale(value: number): void;
getContentScale(): number;
setControllerDefaultZoom(): void;

scrollTrackTo(pos: number): void;
scrollTrackBy(delta: number): void;
Expand Down

0 comments on commit a2390e2

Please sign in to comment.