Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
…-components into cypress_component_test
  • Loading branch information
Sanghavi committed Nov 16, 2022
2 parents 9c97b25 + 96f7363 commit 624605c
Show file tree
Hide file tree
Showing 13 changed files with 105 additions and 40 deletions.
1 change: 1 addition & 0 deletions react/src/demo/example-data/vtk-grid/Simgrid2x_points.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions react/src/demo/example-data/vtk-grid/Simgrid2x_polys.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions react/src/demo/example-data/vtk-grid/Simgrid2x_scalar.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions react/src/demo/example-data/vtk-grid/Simgrid4x_points.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions react/src/demo/example-data/vtk-grid/Simgrid4x_polys.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions react/src/demo/example-data/vtk-grid/Simgrid4x_scalar.json

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions react/src/demo/example-data/vtk-grid/Simgrid_points.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions react/src/demo/example-data/vtk-grid/Simgrid_polys.json

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions react/src/demo/example-data/vtk-grid/Simgrid_scalar.json

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ const Template: ComponentStory<typeof DeckGLMap> = (args) => (
);

const defaultProps = {
bounds: [6063, 1551, 17489, 14440] as NumberQuad,
bounds: [456150, 5925800, 467400, 5939500] as NumberQuad,
views: {
layout: [1, 1] as [number, number],
viewports: [
Expand All @@ -30,68 +30,121 @@ const defaultProps = {
const grid3dLayer = {
"@@type": "Grid3DLayer",
id: "Grid3DLayer",
pointsUrl: "vtk-grid/points.json",
polysUrl: "vtk-grid/polys.json",
propertiesUrl: "vtk-grid/scalar.json",
material: true,
colorMapName: "Rainbow",
scaleZ: 5,
scaleZ: 1,
};

const axes = {
"@@type": "AxesLayer",
id: "axes-layer2",
bounds: [6063, 1551, -10027, 17489, 14440, -7837],
bounds: [453150, 5925800, -2000, 469400, 5939500, 0],
};

export const Grid3D = Template.bind({});
Grid3D.args = {
...defaultProps,
id: "grid-3d",
layers: [axes, grid3dLayer],
};

Grid3D.parameters = {
const parameters = {
docs: {
description: {
story: "3D grid with vtk polydata.",
story: "Simgrid.",
},
inlineStories: false,
iframeHeight: 500,
},
};

// Intersection story.
const intersection_axes = {
"@@type": "AxesLayer",
id: "axes-layer2",
bounds: [463256, 5930542.5, -9060, 464465, 5932768, -7999],
export const Simgrid = Template.bind({});
Simgrid.args = {
...defaultProps,
id: "grid-3d",
layers: [
axes,
{
...grid3dLayer,
pointsUrl: "vtk-grid/Simgrid_points.json",
polysUrl: "vtk-grid/Simgrid_polys.json",
propertiesUrl: "vtk-grid/Simgrid_scalar.json",
},
],
};
Simgrid.parameters = parameters;

const intersection = {
"@@type": "Grid3DLayer",
id: "Grid3DLayer",
pointsUrl: "vtk-grid/intersection_points.json",
polysUrl: "vtk-grid/intersection_polys.json",
propertiesUrl: "vtk-grid/intersection_scalar.json",
material: true,
colorMapName: "Rainbow",
scaleZ: 5,
export const Simgrid2x = Template.bind({});
Simgrid2x.args = {
...defaultProps,
id: "grid-3d",
layers: [
axes,
{
...grid3dLayer,
pointsUrl: "vtk-grid/Simgrid2x_points.json",
polysUrl: "vtk-grid/Simgrid2x_polys.json",
propertiesUrl: "vtk-grid/Simgrid2x_scalar.json",
},
],
};
Simgrid2x.parameters = parameters;

export const Intersection = Template.bind({});
Intersection.args = {
export const Simgrid4x = Template.bind({});
Simgrid4x.args = {
...defaultProps,
id: "grid-3d",
layers: [intersection_axes, intersection],
layers: [
axes,
{
...grid3dLayer,
pointsUrl: "vtk-grid/Simgrid4x_points.json",
polysUrl: "vtk-grid/Simgrid4x_polys.json",
propertiesUrl: "vtk-grid/Simgrid4x_scalar.json",
},
],
};
Simgrid4x.parameters = parameters;

Intersection.parameters = {
docs: {
description: {
story: "3D grid intersection geometry using vtk polydata format.",
export const Simgrid8xIJonly = Template.bind({});
Simgrid8xIJonly.args = {
...defaultProps,
id: "grid-3d",
layers: [
axes,
{
...grid3dLayer,
pointsUrl: "vtk-grid/Simgrid8xIJonly_points.json",
polysUrl: "vtk-grid/Simgrid8xIJonly_polys.json",
propertiesUrl: "vtk-grid/Simgrid8xIJonly_scalar.json",
},
inlineStories: false,
iframeHeight: 500,
},
],
};
Simgrid8xIJonly.parameters = parameters;

// // Intersection story.
// const intersection_axes = {
// "@@type": "AxesLayer",
// id: "axes-layer2",
// bounds: [463256, 5930542.5, -9060, 464465, 5932768, -7999],
// };

// const intersection = {
// "@@type": "Grid3DLayer",
// id: "Grid3DLayer",
// pointsUrl: "vtk-grid/intersection_points.json",
// polysUrl: "vtk-grid/intersection_polys.json",
// propertiesUrl: "vtk-grid/intersection_scalar.json",
// material: true,
// colorMapName: "Rainbow",
// scaleZ: 5,
// };

// export const Intersection = Template.bind({});
// Intersection.args = {
// ...defaultProps,
// id: "grid-3d",
// layers: [intersection_axes, intersection],
// };

// Intersection.parameters = {
// docs: {
// description: {
// story: "3D grid intersection geometry using vtk polydata format.",
// },
// inlineStories: false,
// iframeHeight: 500,
// },
// };

0 comments on commit 624605c

Please sign in to comment.