From 7e774162a3a5847728358510324018cfdc9cfdc6 Mon Sep 17 00:00:00 2001 From: Sylvain Leclerc Date: Mon, 6 Jan 2025 10:22:44 +0100 Subject: [PATCH] Revert "refactor(ui): update clusters group names to lowercase (#2271)" This reverts commit 961df68a04ee29cba12ada211a20c1996c467c1b. --- .../Modelization/Areas/Renewables/Fields.tsx | 1 - .../Modelization/Areas/Renewables/Form.tsx | 1 + .../Modelization/Areas/Renewables/utils.ts | 18 ++++++++--------- .../Modelization/Areas/Storages/Fields.tsx | 1 - .../Modelization/Areas/Storages/Form.tsx | 1 + .../Modelization/Areas/Storages/utils.ts | 18 ++++++++--------- .../Modelization/Areas/Thermal/Fields.tsx | 1 - .../Modelization/Areas/Thermal/utils.ts | 20 +++++++++---------- 8 files changed, 30 insertions(+), 31 deletions(-) diff --git a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/Fields.tsx b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/Fields.tsx index 8983dde2e8..0ee371d7fa 100644 --- a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/Fields.tsx +++ b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/Fields.tsx @@ -47,7 +47,6 @@ function Fields() { name="group" control={control} options={RENEWABLE_GROUPS} - startCaseLabel={false} sx={{ alignSelf: "center", }} diff --git a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/Form.tsx b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/Form.tsx index 5c3e62b81f..a180b0fe05 100644 --- a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/Form.tsx +++ b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/Form.tsx @@ -81,6 +81,7 @@ function Renewables() { config={{ defaultValues }} onSubmit={handleSubmit} enableUndoRedo + sx={{ height: "50%" }} > diff --git a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/utils.ts b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/utils.ts index 8ad72eeffc..f3e2520aa2 100644 --- a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/utils.ts +++ b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Renewables/utils.ts @@ -26,15 +26,15 @@ import type { ClusterWithCapacity } from "../common/clustersUtils"; //////////////////////////////////////////////////////////////// export const RENEWABLE_GROUPS = [ - "wind onshore", - "wind offshore", - "solar thermal", - "solar pv", - "solar rooftop", - "other res 1", - "other res 2", - "other res 3", - "other res 4", + "Wind Onshore", + "Wind Offshore", + "Solar Thermal", + "Solar PV", + "Solar Rooftop", + "Other RES 1", + "Other RES 2", + "Other RES 3", + "Other RES 4", ] as const; export const TS_INTERPRETATION_OPTIONS = [ diff --git a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/Fields.tsx b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/Fields.tsx index e3cacb065d..62f351772a 100644 --- a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/Fields.tsx +++ b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/Fields.tsx @@ -49,7 +49,6 @@ function Fields() { name="group" control={control} options={STORAGE_GROUPS} - startCaseLabel={false} sx={{ alignSelf: "center", }} diff --git a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/Form.tsx b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/Form.tsx index 4ee29080d4..22899502df 100644 --- a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/Form.tsx +++ b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/Form.tsx @@ -95,6 +95,7 @@ function Storages() { }} onSubmit={handleSubmit} enableUndoRedo + sx={{ height: "50%" }} > diff --git a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/utils.ts b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/utils.ts index 3d05b9a659..83bd3c60f7 100644 --- a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/utils.ts +++ b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Storages/utils.ts @@ -21,15 +21,15 @@ import type { PartialExceptFor } from "../../../../../../../utils/tsUtils"; //////////////////////////////////////////////////////////////// export const STORAGE_GROUPS = [ - "psp_open", - "psp_closed", - "pondage", - "battery", - "other1", - "other2", - "other3", - "other4", - "other5", + "PSP_open", + "PSP_closed", + "Pondage", + "Battery", + "Other1", + "Other2", + "Other3", + "Other4", + "Other5", ] as const; //////////////////////////////////////////////////////////////// diff --git a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Thermal/Fields.tsx b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Thermal/Fields.tsx index 7d3d5bb0de..3aaf182b48 100644 --- a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Thermal/Fields.tsx +++ b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Thermal/Fields.tsx @@ -59,7 +59,6 @@ function Fields() { name="group" control={control} options={THERMAL_GROUPS} - startCaseLabel={false} sx={{ alignSelf: "center", }} diff --git a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Thermal/utils.ts b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Thermal/utils.ts index 6747954f6b..3a5895c8f6 100644 --- a/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Thermal/utils.ts +++ b/webapp/src/components/App/Singlestudy/explore/Modelization/Areas/Thermal/utils.ts @@ -42,16 +42,16 @@ export const TS_GEN_MATRIX_COLS = [ ] as const; export const THERMAL_GROUPS = [ - "gas", - "hard coal", - "lignite", - "mixed fuel", - "nuclear", - "oil", - "other 1", - "other 2", - "other 3", - "other 4", + "Gas", + "Hard Coal", + "Lignite", + "Mixed fuel", + "Nuclear", + "Oil", + "Other 1", + "Other 2", + "Other 3", + "Other 4", ] as const; export const THERMAL_POLLUTANTS = [