forked from equinor/webviz
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add more module previews (equinor#374)
- Loading branch information
1 parent
e50e4b9
commit bb83fa9
Showing
15 changed files
with
181 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { DrawPreviewFunc } from "@framework/Preview"; | ||
import previewImg from "./preview.webp"; | ||
|
||
export const preview: DrawPreviewFunc = function (width: number, height: number) { | ||
return ( | ||
<img src={previewImg} style={{width, height}} className="object-cover object-center" /> | ||
); | ||
}; |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
import { ModuleRegistry } from "@framework/ModuleRegistry"; | ||
|
||
import { preview } from "./preview"; | ||
import state from "./state"; | ||
|
||
ModuleRegistry.registerModule<state>({ moduleName: "Grid3D", defaultTitle: "3D grid" }); | ||
ModuleRegistry.registerModule<state>({ moduleName: "Grid3D", defaultTitle: "3D grid", preview }); |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import { DrawPreviewFunc } from "@framework/Preview"; | ||
import previewImg from "./preview.svg"; | ||
|
||
export const preview: DrawPreviewFunc = function (width: number, height: number) { | ||
return <img src={previewImg} style={{width, height}} /> | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
import { ModuleRegistry } from "@framework/ModuleRegistry"; | ||
|
||
import { preview } from "./preview"; | ||
import state from "./state"; | ||
|
||
ModuleRegistry.registerModule<state>({ moduleName: "Grid3DIntersection", defaultTitle: "3D grid intersection" }); | ||
ModuleRegistry.registerModule<state>({ moduleName: "Grid3DIntersection", defaultTitle: "3D grid intersection", preview }); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
import { DrawPreviewFunc } from "@framework/Preview"; | ||
import previewImg from "./preview.webp"; | ||
|
||
export const preview: DrawPreviewFunc = function (width: number, height: number) { | ||
return ( | ||
<img src={previewImg} style={{width, height}} className="object-cover object-center" /> | ||
); | ||
}; |
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,12 @@ | ||
import { ModuleRegistry } from "@framework/ModuleRegistry"; | ||
import { SyncSettingKey } from "@framework/SyncSettings"; | ||
|
||
import { preview } from "./preview"; | ||
import { MapState } from "./MapState"; | ||
|
||
ModuleRegistry.registerModule<MapState>({ | ||
moduleName: "Map", | ||
defaultTitle: "Map", | ||
syncableSettingKeys: [SyncSettingKey.ENSEMBLE, SyncSettingKey.SURFACE, SyncSettingKey.DATE], | ||
preview | ||
}); |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import { DrawPreviewFunc } from "@framework/Preview"; | ||
import previewImg from "./preview.svg"; | ||
|
||
export const preview: DrawPreviewFunc = function (width: number, height: number) { | ||
return <img src={previewImg} style={{width, height}} /> | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
import { ModuleRegistry } from "@framework/ModuleRegistry"; | ||
|
||
import { preview } from "./preview"; | ||
import state from "./state"; | ||
|
||
ModuleRegistry.registerModule<state>({ moduleName: "Pvt", defaultTitle: "PVT" }); | ||
ModuleRegistry.registerModule<state>({ moduleName: "Pvt", defaultTitle: "PVT", preview }); |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
import { DrawPreviewFunc } from "@framework/Preview"; | ||
import previewImg from "./preview.svg"; | ||
|
||
export const preview: DrawPreviewFunc = function (width: number, height: number) { | ||
return <img src={previewImg} style={{width, height}} /> | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
import { ModuleRegistry } from "@framework/ModuleRegistry"; | ||
|
||
import { preview } from "./preview"; | ||
import { State } from "./state"; | ||
|
||
ModuleRegistry.registerModule<State>({ moduleName: "WellCompletions", defaultTitle: "Well Completions" }); | ||
ModuleRegistry.registerModule<State>({ moduleName: "WellCompletions", defaultTitle: "Well Completions", preview }); |