Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ export function defaultSidePanel(parent: SyncLogViewer): JSX.Element {
(welllog: WellLog, iWellLog: number) => (
<WellLogInfoPanel
key={iWellLog}
header={"Readout " + welllog.header.well}
header={"Readout " + welllog?.header.well}
readoutOptions={parent.props.readoutOptions}
callbackManager={parent.callbackManagers[iWellLog]}
/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ const ComponentCode =
' <div style={{ height: "92vh" }}> \r\n' +
" <Scroller \r\n" +
" ref={(el) => { \r\n" +
" el.zoom(10, 10); \r\n" +
" el.scrollTo(0.2, 0.2); \r\n" +
" el?.zoom(10, 10); \r\n" +
" el?.scrollTo(0.2, 0.2); \r\n" +
" }} \r\n" +
" onScroll={(x, y) => { \r\n" +
" setInfo( \r\n" +
Expand Down Expand Up @@ -60,8 +60,8 @@ const Template = (args) => {
<div style={{ height: "92vh" }}>
<Scroller
ref={(el) => {
el.zoom(10, 10);
el.scrollTo(0.2, 0.2);
el?.zoom(10, 10);
el?.scrollTo(0.2, 0.2);
}}
onScroll={(x, y) => {
setInfo(
Expand All @@ -70,7 +70,7 @@ const Template = (args) => {
", Y=" +
y.toFixed(2)
);
args.onScroll(x, y); // for storybook addon Actions Tab
args.onScroll?.(x, y); // for storybook addon Actions Tab
}}
>
<div ref={infoRef}></div>
Expand Down