From 959e9f37eed57ca4347ce3befd25d38ee883a0e2 Mon Sep 17 00:00:00 2001 From: Nils Petter Fremming Date: Wed, 17 Jul 2024 10:09:47 +0200 Subject: [PATCH] Renaming + some adjustments --- .../concrete/clipping/commands/ApplyClipCommand.ts | 2 +- .../src/architecture/concrete/config/StoryBookConfig.ts | 6 +++--- .../{exampleDomainObject => example}/ExampleDomainObject.ts | 0 .../{exampleDomainObject => example}/ExampleDragger.ts | 0 .../{exampleDomainObject => example}/ExampleRenderStyle.ts | 0 .../{exampleDomainObject => example}/ExampleTool.ts | 0 .../{exampleDomainObject => example}/ExampleView.ts | 0 .../commands/DeleteAllExamplesCommand.ts | 0 .../commands/ResetAllExamplesCommand.ts | 0 .../commands/ShowAllExamplesCommand.ts | 0 .../commands/ShowExamplesOnTopCommand.ts | 0 .../SetTerrainVisibleCommand.ts | 0 .../{terrainDomainObject => terrain}/TerrainDomainObject.ts | 0 .../{terrainDomainObject => terrain}/TerrainRenderStyle.ts | 0 .../{terrainDomainObject => terrain}/TerrainThreeView.ts | 0 .../UpdateTerrainCommand.ts | 0 .../geometry/ContouringService.ts | 0 .../{terrainDomainObject => terrain}/geometry/Grid2.ts | 0 .../geometry/RegularGrid2.ts | 0 .../geometry/RegularGrid2Buffers.ts | 0 .../geometry/createFractalRegularGrid2.ts | 0 .../src/components/Architecture/CommandButton.tsx | 2 +- .../src/components/Architecture/OptionButton.tsx | 2 +- 23 files changed, 6 insertions(+), 6 deletions(-) rename react-components/src/architecture/concrete/{exampleDomainObject => example}/ExampleDomainObject.ts (100%) rename react-components/src/architecture/concrete/{exampleDomainObject => example}/ExampleDragger.ts (100%) rename react-components/src/architecture/concrete/{exampleDomainObject => example}/ExampleRenderStyle.ts (100%) rename react-components/src/architecture/concrete/{exampleDomainObject => example}/ExampleTool.ts (100%) rename react-components/src/architecture/concrete/{exampleDomainObject => example}/ExampleView.ts (100%) rename react-components/src/architecture/concrete/{exampleDomainObject => example}/commands/DeleteAllExamplesCommand.ts (100%) rename react-components/src/architecture/concrete/{exampleDomainObject => example}/commands/ResetAllExamplesCommand.ts (100%) rename react-components/src/architecture/concrete/{exampleDomainObject => example}/commands/ShowAllExamplesCommand.ts (100%) rename react-components/src/architecture/concrete/{exampleDomainObject => example}/commands/ShowExamplesOnTopCommand.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/SetTerrainVisibleCommand.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/TerrainDomainObject.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/TerrainRenderStyle.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/TerrainThreeView.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/UpdateTerrainCommand.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/geometry/ContouringService.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/geometry/Grid2.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/geometry/RegularGrid2.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/geometry/RegularGrid2Buffers.ts (100%) rename react-components/src/architecture/concrete/{terrainDomainObject => terrain}/geometry/createFractalRegularGrid2.ts (100%) diff --git a/react-components/src/architecture/concrete/clipping/commands/ApplyClipCommand.ts b/react-components/src/architecture/concrete/clipping/commands/ApplyClipCommand.ts index 553817fe8ef..44e927d42fc 100644 --- a/react-components/src/architecture/concrete/clipping/commands/ApplyClipCommand.ts +++ b/react-components/src/architecture/concrete/clipping/commands/ApplyClipCommand.ts @@ -53,10 +53,10 @@ export class ApplyClipCommand extends RenderTargetCommand { const cropBox = this.getSelectedCropBoxDomainObject(); if (cropBox !== undefined) { cropBox.setThisAsGlobalCropBox(); + renderTarget.fitView(); } else { ApplyClipCommand.setClippingPlanes(this.rootDomainObject); } - renderTarget.fitView(); return true; } diff --git a/react-components/src/architecture/concrete/config/StoryBookConfig.ts b/react-components/src/architecture/concrete/config/StoryBookConfig.ts index 99eae4d9f66..643c20f1cc4 100644 --- a/react-components/src/architecture/concrete/config/StoryBookConfig.ts +++ b/react-components/src/architecture/concrete/config/StoryBookConfig.ts @@ -6,11 +6,11 @@ import { FlexibleControlsType } from '@cognite/reveal'; import { type BaseCommand } from '../../base/commands/BaseCommand'; import { PopupStyle } from '../../base/domainObjectsHelpers/PopupStyle'; import { SetFlexibleControlsTypeCommand } from '../../base/concreteCommands/SetFlexibleControlsTypeCommand'; -import { SetTerrainVisibleCommand } from '../terrainDomainObject/SetTerrainVisibleCommand'; -import { UpdateTerrainCommand } from '../terrainDomainObject/UpdateTerrainCommand'; +import { SetTerrainVisibleCommand } from '../terrain/SetTerrainVisibleCommand'; +import { UpdateTerrainCommand } from '../terrain/UpdateTerrainCommand'; import { FitViewCommand } from '../../base/concreteCommands/FitViewCommand'; import { SetAxisVisibleCommand } from '../axis/SetAxisVisibleCommand'; -import { ExampleTool } from '../exampleDomainObject/ExampleTool'; +import { ExampleTool } from '../example/ExampleTool'; import { AxisGizmoTool } from '@cognite/reveal/tools'; import { BaseRevealConfig } from '../../base/renderTarget/BaseRevealConfig'; import { type RevealRenderTarget } from '../../base/renderTarget/RevealRenderTarget'; diff --git a/react-components/src/architecture/concrete/exampleDomainObject/ExampleDomainObject.ts b/react-components/src/architecture/concrete/example/ExampleDomainObject.ts similarity index 100% rename from react-components/src/architecture/concrete/exampleDomainObject/ExampleDomainObject.ts rename to react-components/src/architecture/concrete/example/ExampleDomainObject.ts diff --git a/react-components/src/architecture/concrete/exampleDomainObject/ExampleDragger.ts b/react-components/src/architecture/concrete/example/ExampleDragger.ts similarity index 100% rename from react-components/src/architecture/concrete/exampleDomainObject/ExampleDragger.ts rename to react-components/src/architecture/concrete/example/ExampleDragger.ts diff --git a/react-components/src/architecture/concrete/exampleDomainObject/ExampleRenderStyle.ts b/react-components/src/architecture/concrete/example/ExampleRenderStyle.ts similarity index 100% rename from react-components/src/architecture/concrete/exampleDomainObject/ExampleRenderStyle.ts rename to react-components/src/architecture/concrete/example/ExampleRenderStyle.ts diff --git a/react-components/src/architecture/concrete/exampleDomainObject/ExampleTool.ts b/react-components/src/architecture/concrete/example/ExampleTool.ts similarity index 100% rename from react-components/src/architecture/concrete/exampleDomainObject/ExampleTool.ts rename to react-components/src/architecture/concrete/example/ExampleTool.ts diff --git a/react-components/src/architecture/concrete/exampleDomainObject/ExampleView.ts b/react-components/src/architecture/concrete/example/ExampleView.ts similarity index 100% rename from react-components/src/architecture/concrete/exampleDomainObject/ExampleView.ts rename to react-components/src/architecture/concrete/example/ExampleView.ts diff --git a/react-components/src/architecture/concrete/exampleDomainObject/commands/DeleteAllExamplesCommand.ts b/react-components/src/architecture/concrete/example/commands/DeleteAllExamplesCommand.ts similarity index 100% rename from react-components/src/architecture/concrete/exampleDomainObject/commands/DeleteAllExamplesCommand.ts rename to react-components/src/architecture/concrete/example/commands/DeleteAllExamplesCommand.ts diff --git a/react-components/src/architecture/concrete/exampleDomainObject/commands/ResetAllExamplesCommand.ts b/react-components/src/architecture/concrete/example/commands/ResetAllExamplesCommand.ts similarity index 100% rename from react-components/src/architecture/concrete/exampleDomainObject/commands/ResetAllExamplesCommand.ts rename to react-components/src/architecture/concrete/example/commands/ResetAllExamplesCommand.ts diff --git a/react-components/src/architecture/concrete/exampleDomainObject/commands/ShowAllExamplesCommand.ts b/react-components/src/architecture/concrete/example/commands/ShowAllExamplesCommand.ts similarity index 100% rename from react-components/src/architecture/concrete/exampleDomainObject/commands/ShowAllExamplesCommand.ts rename to react-components/src/architecture/concrete/example/commands/ShowAllExamplesCommand.ts diff --git a/react-components/src/architecture/concrete/exampleDomainObject/commands/ShowExamplesOnTopCommand.ts b/react-components/src/architecture/concrete/example/commands/ShowExamplesOnTopCommand.ts similarity index 100% rename from react-components/src/architecture/concrete/exampleDomainObject/commands/ShowExamplesOnTopCommand.ts rename to react-components/src/architecture/concrete/example/commands/ShowExamplesOnTopCommand.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/SetTerrainVisibleCommand.ts b/react-components/src/architecture/concrete/terrain/SetTerrainVisibleCommand.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/SetTerrainVisibleCommand.ts rename to react-components/src/architecture/concrete/terrain/SetTerrainVisibleCommand.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/TerrainDomainObject.ts b/react-components/src/architecture/concrete/terrain/TerrainDomainObject.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/TerrainDomainObject.ts rename to react-components/src/architecture/concrete/terrain/TerrainDomainObject.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/TerrainRenderStyle.ts b/react-components/src/architecture/concrete/terrain/TerrainRenderStyle.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/TerrainRenderStyle.ts rename to react-components/src/architecture/concrete/terrain/TerrainRenderStyle.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/TerrainThreeView.ts b/react-components/src/architecture/concrete/terrain/TerrainThreeView.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/TerrainThreeView.ts rename to react-components/src/architecture/concrete/terrain/TerrainThreeView.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/UpdateTerrainCommand.ts b/react-components/src/architecture/concrete/terrain/UpdateTerrainCommand.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/UpdateTerrainCommand.ts rename to react-components/src/architecture/concrete/terrain/UpdateTerrainCommand.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/geometry/ContouringService.ts b/react-components/src/architecture/concrete/terrain/geometry/ContouringService.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/geometry/ContouringService.ts rename to react-components/src/architecture/concrete/terrain/geometry/ContouringService.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/geometry/Grid2.ts b/react-components/src/architecture/concrete/terrain/geometry/Grid2.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/geometry/Grid2.ts rename to react-components/src/architecture/concrete/terrain/geometry/Grid2.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/geometry/RegularGrid2.ts b/react-components/src/architecture/concrete/terrain/geometry/RegularGrid2.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/geometry/RegularGrid2.ts rename to react-components/src/architecture/concrete/terrain/geometry/RegularGrid2.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/geometry/RegularGrid2Buffers.ts b/react-components/src/architecture/concrete/terrain/geometry/RegularGrid2Buffers.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/geometry/RegularGrid2Buffers.ts rename to react-components/src/architecture/concrete/terrain/geometry/RegularGrid2Buffers.ts diff --git a/react-components/src/architecture/concrete/terrainDomainObject/geometry/createFractalRegularGrid2.ts b/react-components/src/architecture/concrete/terrain/geometry/createFractalRegularGrid2.ts similarity index 100% rename from react-components/src/architecture/concrete/terrainDomainObject/geometry/createFractalRegularGrid2.ts rename to react-components/src/architecture/concrete/terrain/geometry/createFractalRegularGrid2.ts diff --git a/react-components/src/components/Architecture/CommandButton.tsx b/react-components/src/components/Architecture/CommandButton.tsx index 96fe252878e..308332042ba 100644 --- a/react-components/src/components/Architecture/CommandButton.tsx +++ b/react-components/src/components/Architecture/CommandButton.tsx @@ -60,7 +60,7 @@ export const CommandButton = ({ return ( } + content={} appendTo={document.body} placement={placement}>