@gridsuite/commons-ui 0.241.0 → 0.242.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (147) hide show
  1. package/README.md +4 -0
  2. package/dist/components/composite/grid/grid-item.d.ts +2 -1
  3. package/dist/components/composite/grid/grid-item.js +9 -2
  4. package/dist/components/ui/inputs/checkbox-autocomplete/checkbox-autocomplete.d.ts +1 -2
  5. package/dist/features/index.js +87 -3
  6. package/dist/features/network-modification-table/index.js +2 -1
  7. package/dist/features/network-modification-table/use-modifications-drag-and-drop.js +2 -1
  8. package/dist/features/network-modification-table/utils.d.ts +1 -0
  9. package/dist/features/network-modification-table/utils.js +5 -1
  10. package/dist/features/network-modifications/battery/creation/BatteryCreationForm.js +3 -0
  11. package/dist/features/network-modifications/battery/creation/batteryCreation.utils.js +3 -0
  12. package/dist/features/network-modifications/battery/modification/BatteryDialogHeader.js +3 -0
  13. package/dist/features/network-modifications/battery/modification/BatteryDialogTabsContent.js +3 -0
  14. package/dist/features/network-modifications/battery/modification/batteryModification.utils.js +3 -0
  15. package/dist/features/network-modifications/common/connectivity/connectivityForm.utils.d.ts +71 -2
  16. package/dist/features/network-modifications/common/connectivity/connectivityForm.utils.js +26 -8
  17. package/dist/features/network-modifications/common/connectivity/index.js +3 -1
  18. package/dist/features/network-modifications/common/currentLimits/LimitsPane.d.ts +7 -0
  19. package/dist/features/network-modifications/common/currentLimits/LimitsPane.js +243 -0
  20. package/dist/features/network-modifications/common/currentLimits/LimitsTagChip.d.ts +9 -0
  21. package/dist/features/network-modifications/common/currentLimits/LimitsTagChip.js +29 -0
  22. package/dist/features/network-modifications/common/currentLimits/SelectedOperationalLimitGroup.d.ts +9 -0
  23. package/dist/features/network-modifications/common/currentLimits/SelectedOperationalLimitGroup.js +100 -0
  24. package/dist/features/network-modifications/common/currentLimits/index.d.ts +12 -0
  25. package/dist/features/network-modifications/common/currentLimits/index.js +47 -0
  26. package/dist/features/network-modifications/common/currentLimits/limits.types.d.ts +52 -0
  27. package/dist/features/network-modifications/common/currentLimits/limits.types.js +17 -0
  28. package/dist/features/network-modifications/common/currentLimits/limitsEditor/LimitsEditor.d.ts +10 -0
  29. package/dist/features/network-modifications/common/currentLimits/limitsEditor/LimitsEditor.js +285 -0
  30. package/dist/features/network-modifications/common/currentLimits/limitsEditor/LimitsPropertiesSideStack.d.ts +5 -0
  31. package/dist/features/network-modifications/common/currentLimits/limitsEditor/LimitsPropertiesSideStack.js +184 -0
  32. package/dist/features/network-modifications/common/currentLimits/limitsEditor/TemporaryLimitsTable.d.ts +14 -0
  33. package/dist/features/network-modifications/common/currentLimits/limitsEditor/TemporaryLimitsTable.js +166 -0
  34. package/dist/features/network-modifications/common/currentLimits/limitsEditor/index.d.ts +10 -0
  35. package/dist/features/network-modifications/common/currentLimits/limitsEditor/index.js +10 -0
  36. package/dist/features/network-modifications/common/currentLimits/limitsEditor/limitsChart.d.ts +11 -0
  37. package/dist/features/network-modifications/common/currentLimits/limitsEditor/limitsChart.js +177 -0
  38. package/dist/features/network-modifications/common/currentLimits/limitsPane.utils.d.ts +213 -0
  39. package/dist/features/network-modifications/common/currentLimits/limitsPane.utils.js +337 -0
  40. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/LimitsGroupsContextualMenu.d.ts +25 -0
  41. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/LimitsGroupsContextualMenu.js +92 -0
  42. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/LimitsPropertiesStack.d.ts +10 -0
  43. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/LimitsPropertiesStack.js +25 -0
  44. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/OperationalLimitsGroupTabLabel.d.ts +10 -0
  45. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/OperationalLimitsGroupTabLabel.js +73 -0
  46. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/OperationalLimitsGroups.d.ts +16 -0
  47. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/OperationalLimitsGroups.js +121 -0
  48. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/index.d.ts +11 -0
  49. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/index.js +12 -0
  50. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/operationalLimitsGroups.types.d.ts +71 -0
  51. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/operationalLimitsGroups.types.js +15 -0
  52. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/operationalLimitsGroupsStyles.d.ts +46 -0
  53. package/dist/features/network-modifications/common/currentLimits/operationalLimitsGroups/operationalLimitsGroupsStyles.js +45 -0
  54. package/dist/features/network-modifications/common/index.d.ts +1 -0
  55. package/dist/features/network-modifications/common/index.js +50 -2
  56. package/dist/features/network-modifications/common/measurements/branchActiveReactivePowerForm.utils.d.ts +11 -0
  57. package/dist/features/network-modifications/common/measurements/branchActiveReactivePowerForm.utils.js +6 -4
  58. package/dist/features/network-modifications/common/measurements/index.js +2 -1
  59. package/dist/features/network-modifications/common/reactiveLimits/reactiveCapabilityCurve/ReactiveCapabilityCurveTableForm.js +1 -1
  60. package/dist/features/network-modifications/common/voltageRegulation/VoltageRegulationForm.js +3 -7
  61. package/dist/features/network-modifications/equipmentDeletion/EquipmentDeletionForm.js +3 -0
  62. package/dist/features/network-modifications/generator/creation/GeneratorCreationForm.js +9 -6
  63. package/dist/features/network-modifications/generator/creation/generatorCreation.utils.js +3 -0
  64. package/dist/features/network-modifications/generator/modification/GeneratorDialogHeader.js +3 -0
  65. package/dist/features/network-modifications/generator/modification/GeneratorDialogTabsContent.js +9 -6
  66. package/dist/features/network-modifications/generator/modification/generatorModification.utils.js +3 -0
  67. package/dist/features/network-modifications/index.d.ts +1 -0
  68. package/dist/features/network-modifications/index.js +85 -2
  69. package/dist/features/{parameters/dynamic-simulation/curve/curve-parameters.type.d.ts → network-modifications/line/catalog/index.d.ts} +3 -1
  70. package/dist/features/network-modifications/line/catalog/index.js +14 -0
  71. package/dist/features/network-modifications/line/catalog/lineCatalog.type.d.ts +66 -0
  72. package/dist/features/network-modifications/line/catalog/lineCatalog.type.js +7 -0
  73. package/dist/features/network-modifications/line/catalog/segment.utils.d.ts +90 -0
  74. package/dist/features/network-modifications/line/catalog/segment.utils.js +100 -0
  75. package/dist/features/network-modifications/line/characteristics/LineCharacteristicsPane.d.ts +8 -0
  76. package/dist/features/network-modifications/line/characteristics/LineCharacteristicsPane.js +152 -0
  77. package/dist/features/network-modifications/line/characteristics/index.d.ts +9 -0
  78. package/dist/features/network-modifications/line/characteristics/index.js +9 -0
  79. package/dist/features/network-modifications/line/characteristics/lineCharacteristicsPane.types.d.ts +14 -0
  80. package/dist/features/network-modifications/line/characteristics/lineCharacteristicsPane.utils.d.ts +52 -0
  81. package/dist/features/network-modifications/line/characteristics/lineCharacteristicsPane.utils.js +53 -0
  82. package/dist/features/network-modifications/line/common/LineDialogHeader.d.ts +6 -0
  83. package/dist/features/network-modifications/line/common/LineDialogHeader.js +103 -0
  84. package/dist/features/network-modifications/line/common/LineDialogTabs.d.ts +9 -0
  85. package/dist/features/network-modifications/line/common/LineDialogTabs.js +61 -0
  86. package/dist/features/network-modifications/line/common/LineDialogTabsContent.d.ts +8 -0
  87. package/dist/features/network-modifications/line/common/LineDialogTabsContent.js +96 -0
  88. package/dist/features/network-modifications/line/common/LineForm.d.ts +6 -0
  89. package/dist/features/network-modifications/line/common/LineForm.js +50 -0
  90. package/dist/features/network-modifications/line/common/index.d.ts +12 -0
  91. package/dist/features/network-modifications/line/common/index.js +13 -0
  92. package/dist/features/network-modifications/line/common/line.types.d.ts +47 -0
  93. package/dist/features/network-modifications/line/common/line.types.js +1 -0
  94. package/dist/features/network-modifications/line/common/line.utils.d.ts +13 -0
  95. package/dist/features/network-modifications/line/common/line.utils.js +34 -0
  96. package/dist/features/network-modifications/line/creation/index.d.ts +8 -0
  97. package/dist/features/network-modifications/line/creation/index.js +7 -0
  98. package/dist/features/network-modifications/line/creation/lineCreation.types.d.ts +39 -0
  99. package/dist/features/network-modifications/line/creation/lineCreation.types.js +1 -0
  100. package/dist/features/network-modifications/line/creation/lineCreation.utils.d.ts +151 -0
  101. package/dist/features/network-modifications/line/creation/lineCreation.utils.js +172 -0
  102. package/dist/features/network-modifications/line/index.d.ts +10 -0
  103. package/dist/features/network-modifications/line/index.js +37 -0
  104. package/dist/features/network-modifications/load/common/LoadDialogHeader.js +3 -0
  105. package/dist/features/network-modifications/load/modification/loadModification.utils.js +3 -0
  106. package/dist/features/network-modifications/shunt-compensator/common/CharacteristicsForm.js +7 -6
  107. package/dist/features/network-modifications/shunt-compensator/creation/ShuntCompensatorCreationForm.js +3 -0
  108. package/dist/features/network-modifications/shunt-compensator/creation/shuntCompensatorCreation.utils.js +3 -0
  109. package/dist/features/network-modifications/shunt-compensator/modification/ShuntCompensatorModificationForm.js +3 -0
  110. package/dist/features/network-modifications/shunt-compensator/modification/shuntCompensatorModification.utils.js +3 -0
  111. package/dist/features/network-modifications/substation/creation/SubstationCreationForm.js +3 -0
  112. package/dist/features/network-modifications/substation/modification/SubstationModificationForm.js +3 -0
  113. package/dist/features/network-modifications/voltageLevel/creation/VoltageLevelCreationForm.js +3 -0
  114. package/dist/features/network-modifications/voltageLevel/creation/index.js +3 -0
  115. package/dist/features/network-modifications/voltageLevel/creation/tabs/substationTab/SubstationCreationSection.js +3 -0
  116. package/dist/features/network-modifications/voltageLevel/creation/voltageLevelCreation.utils.js +3 -0
  117. package/dist/features/network-modifications/voltageLevel/index.js +3 -0
  118. package/dist/features/network-modifications/voltageLevel/modification/VoltageLevelModificationForm.js +4 -1
  119. package/dist/features/parameters/common/contingency-table/contingency-table.js +22 -10
  120. package/dist/features/parameters/common/contingency-table/types.d.ts +7 -8
  121. package/dist/features/parameters/common/contingency-table/utils.d.ts +13 -0
  122. package/dist/features/parameters/common/contingency-table/utils.js +31 -0
  123. package/dist/features/parameters/loadflow/load-flow-general-parameters.js +5 -1
  124. package/dist/features/parameters/loadflow/load-flow-parameters-dialog.js +2 -2
  125. package/dist/features/parameters/network-visualizations/network-visualizations-parameters-dialog.js +2 -2
  126. package/dist/features/parameters/pcc-min/pcc-min-parameters-dialog.js +2 -2
  127. package/dist/features/parameters/security-analysis/security-analysis-parameters-dialog.js +3 -3
  128. package/dist/features/parameters/security-analysis/security-analysis-parameters-form.js +19 -31
  129. package/dist/features/parameters/sensi/sensitivity-analysis-parameters-dialog.js +3 -3
  130. package/dist/features/parameters/short-circuit/short-circuit-parameters-dialog.js +2 -2
  131. package/dist/features/parameters/voltage-init/voltage-init-parameters-dialog.js +2 -2
  132. package/dist/hooks/useModificationLabelComputer.js +1 -0
  133. package/dist/index.js +87 -3
  134. package/dist/translations/en/networkModificationsEn.d.ts +28 -0
  135. package/dist/translations/en/networkModificationsEn.js +28 -0
  136. package/dist/translations/en/parameters.d.ts +3 -1
  137. package/dist/translations/en/parameters.js +3 -1
  138. package/dist/translations/fr/networkModificationsFr.d.ts +28 -0
  139. package/dist/translations/fr/networkModificationsFr.js +28 -0
  140. package/dist/translations/fr/parameters.d.ts +3 -1
  141. package/dist/translations/fr/parameters.js +3 -1
  142. package/dist/utils/constants/fieldConstants.d.ts +47 -1
  143. package/dist/utils/constants/fieldConstants.js +46 -0
  144. package/dist/utils/types/modificationType.d.ts +4 -0
  145. package/dist/utils/types/modificationType.js +5 -0
  146. package/package.json +11 -4
  147. /package/dist/features/{parameters/dynamic-simulation/curve/curve-parameters.type.js → network-modifications/line/characteristics/lineCharacteristicsPane.types.js} +0 -0
@@ -0,0 +1,121 @@
1
+ import { jsxs, jsx } from "react/jsx-runtime";
2
+ import { Grid2, Tabs, Tab } from "@mui/material";
3
+ import { useState, useCallback, useEffect } from "react";
4
+ import { useWatch } from "react-hook-form";
5
+ import { LimitsGroupsContextualMenu } from "./LimitsGroupsContextualMenu.js";
6
+ import { OperationalLimitsGroupTabLabel } from "./OperationalLimitsGroupTabLabel.js";
7
+ import { limitsStyles } from "./operationalLimitsGroupsStyles.js";
8
+ import { FieldConstants } from "../../../../../utils/constants/fieldConstants.js";
9
+ import "../../../../../utils/conversionUtils.js";
10
+ import "../../../../../utils/types/equipmentType.js";
11
+ import "@mui/icons-material";
12
+ function OperationalLimitsGroups({
13
+ parentFormName,
14
+ setIndexSelectedLimitSet,
15
+ indexSelectedLimitSet,
16
+ editable,
17
+ appendToLimitsGroups,
18
+ removeLimitsGroups,
19
+ currentLimitsToModify
20
+ }) {
21
+ const [hoveredRowIndex, setHoveredRowIndex] = useState(-1);
22
+ const [contextMenuCoordinates, setContextMenuCoordinates] = useState({
23
+ x: null,
24
+ y: null,
25
+ tabIndex: null
26
+ });
27
+ const selectedLimitsGroups1 = useWatch({
28
+ name: `${parentFormName}.${FieldConstants.SELECTED_OPERATIONAL_LIMITS_GROUP_ID1}`
29
+ });
30
+ const selectedLimitsGroups2 = useWatch({
31
+ name: `${parentFormName}.${FieldConstants.SELECTED_OPERATIONAL_LIMITS_GROUP_ID2}`
32
+ });
33
+ const operationalLimitsGroups = useWatch({
34
+ name: `${parentFormName}.${FieldConstants.OPERATIONAL_LIMITS_GROUPS}`
35
+ });
36
+ const handleOpenMenu = useCallback(
37
+ (event, index) => {
38
+ if (!editable) {
39
+ return;
40
+ }
41
+ event.preventDefault();
42
+ event.stopPropagation();
43
+ setIndexSelectedLimitSet(index);
44
+ setContextMenuCoordinates({
45
+ x: event.clientX,
46
+ y: event.clientY,
47
+ tabIndex: index
48
+ });
49
+ },
50
+ [editable, setIndexSelectedLimitSet]
51
+ );
52
+ const handleCloseMenu = useCallback(() => {
53
+ setContextMenuCoordinates({
54
+ x: null,
55
+ y: null,
56
+ tabIndex: null
57
+ });
58
+ }, [setContextMenuCoordinates]);
59
+ useEffect(() => {
60
+ if (indexSelectedLimitSet === null && operationalLimitsGroups?.length) {
61
+ setIndexSelectedLimitSet(0);
62
+ }
63
+ }, [indexSelectedLimitSet, setIndexSelectedLimitSet, operationalLimitsGroups]);
64
+ const handleTabChange = useCallback(
65
+ (_event, newValue) => {
66
+ setIndexSelectedLimitSet(newValue);
67
+ },
68
+ [setIndexSelectedLimitSet]
69
+ );
70
+ return /* @__PURE__ */ jsxs(Grid2, { children: [
71
+ /* @__PURE__ */ jsx(
72
+ Tabs,
73
+ {
74
+ orientation: "vertical",
75
+ variant: "scrollable",
76
+ value: indexSelectedLimitSet !== null && indexSelectedLimitSet,
77
+ onChange: handleTabChange,
78
+ sx: limitsStyles.tabs,
79
+ children: operationalLimitsGroups?.map((opLg, index) => /* @__PURE__ */ jsx(
80
+ Tab,
81
+ {
82
+ onMouseEnter: () => setHoveredRowIndex(index),
83
+ onContextMenu: (e) => handleOpenMenu(e, index),
84
+ disableRipple: true,
85
+ sx: limitsStyles.tabBackground,
86
+ label: /* @__PURE__ */ jsx(
87
+ OperationalLimitsGroupTabLabel,
88
+ {
89
+ operationalLimitsGroup: opLg,
90
+ showIconButton: editable && index === hoveredRowIndex,
91
+ limitsPropertiesName: `${parentFormName}.${FieldConstants.OPERATIONAL_LIMITS_GROUPS}[${index}].${FieldConstants.LIMITS_PROPERTIES}`,
92
+ handleOpenMenu,
93
+ index
94
+ }
95
+ )
96
+ },
97
+ opLg.id
98
+ ))
99
+ }
100
+ ),
101
+ /* @__PURE__ */ jsx(
102
+ LimitsGroupsContextualMenu,
103
+ {
104
+ parentFormName,
105
+ indexSelectedLimitSet,
106
+ setIndexSelectedLimitSet,
107
+ handleCloseMenu,
108
+ contextMenuCoordinates,
109
+ selectedLimitsGroups1,
110
+ selectedLimitsGroups2,
111
+ currentLimitsToModify,
112
+ operationalLimitsGroups,
113
+ appendToLimitsGroups,
114
+ removeLimitsGroups
115
+ }
116
+ )
117
+ ] });
118
+ }
119
+ export {
120
+ OperationalLimitsGroups
121
+ };
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Copyright (c) 2026, RTE (http://www.rte-france.com)
3
+ * This Source Code Form is subject to the terms of the Mozilla Public
4
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
5
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
6
+ */
7
+ export * from './operationalLimitsGroups.types';
8
+ export * from './LimitsGroupsContextualMenu';
9
+ export * from './LimitsPropertiesStack';
10
+ export * from './OperationalLimitsGroups';
11
+ export * from './OperationalLimitsGroupTabLabel';
@@ -0,0 +1,12 @@
1
+ import { OPERATIONAL_LIMITS_GROUPS_MODIFICATION_TYPE } from "./operationalLimitsGroups.types.js";
2
+ import { LimitsGroupsContextualMenu } from "./LimitsGroupsContextualMenu.js";
3
+ import { LimitsPropertiesStack } from "./LimitsPropertiesStack.js";
4
+ import { OperationalLimitsGroups } from "./OperationalLimitsGroups.js";
5
+ import { OperationalLimitsGroupTabLabel } from "./OperationalLimitsGroupTabLabel.js";
6
+ export {
7
+ LimitsGroupsContextualMenu,
8
+ LimitsPropertiesStack,
9
+ OPERATIONAL_LIMITS_GROUPS_MODIFICATION_TYPE,
10
+ OperationalLimitsGroupTabLabel,
11
+ OperationalLimitsGroups
12
+ };
@@ -0,0 +1,71 @@
1
+ import { AttributeModification, FieldConstants } from '../../../../../utils';
2
+ import { CurrentLimits, LimitsProperty } from '../limits.types';
3
+ export declare const OPERATIONAL_LIMITS_GROUPS_MODIFICATION_TYPE: {
4
+ readonly ADD: "ADD";
5
+ readonly MODIFY: "MODIFY";
6
+ readonly MODIFY_OR_ADD: "MODIFY_OR_ADD";
7
+ readonly REPLACE: "REPLACE";
8
+ readonly DELETE: "DELETE";
9
+ };
10
+ export interface LimitsFormSchema {
11
+ [FieldConstants.LIMITS]: OperationalLimitsGroupsFormSchema;
12
+ }
13
+ export interface OperationalLimitsGroupsFormSchema {
14
+ [FieldConstants.OPERATIONAL_LIMITS_GROUPS]: OperationalLimitsGroupFormSchema[];
15
+ [FieldConstants.SELECTED_OPERATIONAL_LIMITS_GROUP_ID1]?: string;
16
+ [FieldConstants.SELECTED_OPERATIONAL_LIMITS_GROUP_ID2]?: string;
17
+ [FieldConstants.ENABLE_OLG_MODIFICATION]: boolean;
18
+ }
19
+ export interface OperationalLimitsGroupFormSchema {
20
+ [FieldConstants.ID]: string;
21
+ [FieldConstants.NAME]: string;
22
+ [FieldConstants.APPLICABILITY_FIELD]: string;
23
+ [FieldConstants.OLG_IS_DUPLICATE]?: boolean;
24
+ [FieldConstants.CURRENT_LIMITS]: CurrentLimitsFormSchema;
25
+ [FieldConstants.LIMITS_PROPERTIES]?: LimitsPropertyFormSchema[];
26
+ }
27
+ export interface CurrentLimitsFormSchema {
28
+ [FieldConstants.ID]?: string;
29
+ [FieldConstants.PERMANENT_LIMIT]: number;
30
+ [FieldConstants.TEMPORARY_LIMITS]: TemporaryLimitFormSchema[];
31
+ }
32
+ interface LimitsPropertyFormSchema {
33
+ [FieldConstants.NAME]: string;
34
+ [FieldConstants.VALUE]: string;
35
+ }
36
+ export interface TemporaryLimitFormSchema {
37
+ [FieldConstants.TEMPORARY_LIMIT_DURATION]?: number | null;
38
+ [FieldConstants.TEMPORARY_LIMIT_VALUE]?: number | null;
39
+ [FieldConstants.TEMPORARY_LIMIT_NAME]?: string | null;
40
+ }
41
+ export interface OperationalLimitsGroup {
42
+ id: string;
43
+ name: string;
44
+ applicability?: string;
45
+ limitsProperties?: LimitsProperty[];
46
+ currentLimits: CurrentLimits;
47
+ modificationType?: string | null;
48
+ }
49
+ export interface LimitsPropertyInfos {
50
+ name: string;
51
+ value: string;
52
+ }
53
+ export interface CurrentTemporaryLimitModificationInfos {
54
+ name: AttributeModification<string> | null;
55
+ value: AttributeModification<number> | null;
56
+ acceptableDuration: AttributeModification<number> | null;
57
+ modificationType: string | null;
58
+ }
59
+ export interface CurrentLimitsModificationInfos {
60
+ permanentLimit: number | null;
61
+ temporaryLimits: CurrentTemporaryLimitModificationInfos[] | null;
62
+ }
63
+ export interface OperationalLimitsGroupModificationInfos {
64
+ id: string;
65
+ currentLimits: CurrentLimitsModificationInfos | null;
66
+ modificationType?: string | null;
67
+ temporaryLimitsModificationType?: string | null;
68
+ limitsProperties?: LimitsPropertyInfos[] | null;
69
+ applicability: string | null;
70
+ }
71
+ export {};
@@ -0,0 +1,15 @@
1
+ const OPERATIONAL_LIMITS_GROUPS_MODIFICATION_TYPE = {
2
+ ADD: "ADD",
3
+ // Modification types for Tabular modifications :
4
+ MODIFY: "MODIFY",
5
+ // standard mode : the olg modifications are applied. The unspecified olg are not changed at all
6
+ MODIFY_OR_ADD: "MODIFY_OR_ADD",
7
+ // if the opLG exists it is modified, if not it is created
8
+ // Modification type for simple form modifications :
9
+ REPLACE: "REPLACE",
10
+ // All the olg are removed, then the olg modification/add etc are applied
11
+ DELETE: "DELETE"
12
+ };
13
+ export {
14
+ OPERATIONAL_LIMITS_GROUPS_MODIFICATION_TYPE
15
+ };
@@ -0,0 +1,46 @@
1
+ /**
2
+ * Copyright (c) 2025, RTE (http://www.rte-france.com)
3
+ * This Source Code Form is subject to the terms of the Mozilla Public
4
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
5
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
6
+ */
7
+ export declare const limitsStyles: {
8
+ readonly tabs: () => {
9
+ maxHeight: string;
10
+ height: string;
11
+ borderRight: number;
12
+ borderColor: "divider";
13
+ transition: "transform 0.3s ease-in-out";
14
+ '& .MuiTabs-indicator': {
15
+ borderRight: string;
16
+ };
17
+ '.MuiTab-root.MuiButtonBase-root': {
18
+ textTransform: "none";
19
+ textAlign: "left";
20
+ alignItems: "stretch";
21
+ p: number;
22
+ };
23
+ };
24
+ readonly tabBackground: {
25
+ readonly '&:hover': {
26
+ readonly backgroundColor: "rgba(25, 118, 210, 0.05)";
27
+ };
28
+ readonly maxWidth: 600;
29
+ readonly width: "100%";
30
+ readonly p: 1;
31
+ readonly minHeight: 60;
32
+ };
33
+ readonly copyLimitsToRightBackground: {
34
+ readonly height: 200;
35
+ readonly display: "flex";
36
+ };
37
+ readonly copyLimitsToLeftBackground: {
38
+ readonly height: "50%";
39
+ };
40
+ readonly copyLimitsButtons: {
41
+ readonly alignSelf: "flex-end";
42
+ readonly minWidth: "0px";
43
+ readonly height: "auto";
44
+ readonly padding: "1";
45
+ };
46
+ };
@@ -0,0 +1,45 @@
1
+ import { blue } from "@mui/material/colors";
2
+ const limitsStyles = {
3
+ tabs: () => ({
4
+ maxHeight: "45vh",
5
+ height: "100%",
6
+ borderRight: 1,
7
+ borderColor: "divider",
8
+ transition: "transform 0.3s ease-in-out",
9
+ "& .MuiTabs-indicator": {
10
+ borderRight: `3px solid ${blue[700]}`
11
+ },
12
+ ".MuiTab-root.MuiButtonBase-root": {
13
+ textTransform: "none",
14
+ textAlign: "left",
15
+ alignItems: "stretch",
16
+ p: 0
17
+ }
18
+ }),
19
+ tabBackground: {
20
+ "&:hover": {
21
+ backgroundColor: "rgba(25, 118, 210, 0.05)"
22
+ // blue[700]
23
+ },
24
+ maxWidth: 600,
25
+ width: "100%",
26
+ p: 1,
27
+ minHeight: 60
28
+ },
29
+ copyLimitsToRightBackground: {
30
+ height: 200,
31
+ display: "flex"
32
+ },
33
+ copyLimitsToLeftBackground: {
34
+ height: "50%"
35
+ },
36
+ copyLimitsButtons: {
37
+ alignSelf: "flex-end",
38
+ minWidth: "0px",
39
+ height: "auto",
40
+ padding: "1"
41
+ }
42
+ };
43
+ export {
44
+ limitsStyles
45
+ };
@@ -14,3 +14,4 @@ export * from './shortCircuit';
14
14
  export * from './reactiveLimits';
15
15
  export * from './regulatingTerminal';
16
16
  export * from './voltageRegulation';
17
+ export * from './currentLimits';
@@ -4,14 +4,14 @@ import { PropertyForm } from "./properties/PropertyForm.js";
4
4
  import { copyEquipmentPropertiesForCreation, createPropertyModification, creationPropertiesSchema, emptyProperties, fetchPredefinedProperties, getConcatenatedProperties, getFilledPropertiesFromModification, getPropertiesFromModification, getPropertyValue, initializedProperty, mergeModificationAndEquipmentProperties, modificationPropertiesSchema, toModificationProperties } from "./properties/propertyUtils.js";
5
5
  import { getPowerWithValidityEditData, getPowerWithValidityEmptyFormData, getPowerWithValidityValidationSchema } from "./measurements/powerWithValidity.utils.js";
6
6
  import { getInjectionActiveReactivePowerEditData, getInjectionActiveReactivePowerEditDataProperties, getInjectionActiveReactivePowerEmptyFormData, getInjectionActiveReactivePowerEmptyFormDataProperties, getInjectionActiveReactivePowerValidationSchema, getInjectionActiveReactivePowerValidationSchemaProperties } from "./measurements/injectionActiveReactivePowerForm.utils.js";
7
- import { getBranchActiveReactivePowerEditData, getBranchActiveReactivePowerEditDataProperties, getBranchActiveReactivePowerEmptyFormData, getBranchActiveReactivePowerEmptyFormDataProperties, getBranchActiveReactivePowerValidationSchema, getBranchActiveReactivePowerValidationSchemaProperties } from "./measurements/branchActiveReactivePowerForm.utils.js";
7
+ import { getBranchActiveReactivePowerEditData, getBranchActiveReactivePowerEditDataProperties, getBranchActiveReactivePowerEmptyFormData, getBranchActiveReactivePowerEmptyFormDataProperties, getBranchActiveReactivePowerValidationSchema, getBranchActiveReactivePowerValidationSchemaObject, getBranchActiveReactivePowerValidationSchemaProperties } from "./measurements/branchActiveReactivePowerForm.utils.js";
8
8
  import { PowerWithValidityForm } from "./measurements/PowerWithValidityForm.js";
9
9
  import { PowerMeasurementsForm } from "./measurements/PowerMeasurementsForm.js";
10
10
  import { BranchActiveReactivePowerMeasurementsForm } from "./measurements/BranchActiveReactivePowerMeasurementsForm.js";
11
11
  import { BusbarSectionVoltageMeasurementsForm } from "./measurements/BusbarSectionVoltageMeasurementsForm.js";
12
12
  import { getActivePowerSetPointSchema, getReactivePowerSetPointSchema, getSetPointsEmptyFormData, getSetPointsSchema, testValueWithinPowerInterval } from "./setpoints/setPoints.utils.js";
13
13
  import { SetPointsForm } from "./setpoints/SetPointsForm.js";
14
- import { createConnectivityData, getCon1andCon2WithPositionValidationSchema, getConnectivityBusBarSectionData, getConnectivityData, getConnectivityFormData, getConnectivityFormDataProps, getConnectivityPropertiesData, getConnectivityPropertiesEmptyFormData, getConnectivityPropertiesValidationSchema, getConnectivityVoltageLevelData, getConnectivityWithPositionEmptyFormData, getConnectivityWithPositionEmptyFormDataProps, getConnectivityWithPositionSchema, getConnectivityWithPositionValidationSchema, getConnectivityWithoutPositionEmptyFormData, getConnectivityWithoutPositionValidationSchema, getCont1Cont2WithPositionEmptyFormData, getNewVoltageLevelData } from "./connectivity/connectivityForm.utils.js";
14
+ import { createConnectivityData, getBranchConnectivityWithPositionEmptyFormDataProps, getBranchConnectivityWithPositionSchema, getCon1andCon2WithPositionValidationSchema, getConnectivityBusBarSectionData, getConnectivityData, getConnectivityFormData, getConnectivityFormDataProps, getConnectivityPropertiesData, getConnectivityPropertiesEmptyFormData, getConnectivityPropertiesValidationSchema, getConnectivityVoltageLevelData, getConnectivityWithPositionEmptyFormData, getConnectivityWithPositionEmptyFormDataProps, getConnectivityWithPositionSchema, getConnectivityWithPositionValidationSchema, getConnectivityWithoutPositionEmptyFormData, getConnectivityWithoutPositionValidationSchema, getCont1Cont2WithPositionEmptyFormData, getNewVoltageLevelData } from "./connectivity/connectivityForm.utils.js";
15
15
  import { ConnectivityForm } from "./connectivity/ConnectivityForm.js";
16
16
  import { BranchConnectivityForm } from "./connectivity/BranchConnectivityForm.js";
17
17
  import { VoltageLevelConnectivityForm } from "./connectivity/VoltageLevelConnectivityForm.js";
@@ -28,13 +28,37 @@ import { RegulatingTerminalForm } from "./regulatingTerminal/RegulatingTerminalF
28
28
  import { getRegulatingTerminalEmptyFormData, getRegulatingTerminalEquipmentData, getRegulatingTerminalFormData, getRegulatingTerminalVoltageLevelData } from "./regulatingTerminal/regulatingTerminal.utils.js";
29
29
  import { VoltageRegulationForm } from "./voltageRegulation/VoltageRegulationForm.js";
30
30
  import { REGULATION_TYPES, getVoltageRegulationEmptyFormData, getVoltageRegulationSchema } from "./voltageRegulation/voltageRegulation.utils.js";
31
+ import { APPLICABILITY, TEMPORARY_LIMIT_MODIFICATION_TYPE } from "./currentLimits/limits.types.js";
32
+ import { LimitsTagChip, getPropertyAvatar } from "./currentLimits/LimitsTagChip.js";
33
+ import { LimitsPane } from "./currentLimits/LimitsPane.js";
34
+ import { addModificationTypeToOpLimitsGroups, addModificationTypeToTemporaryLimits, addOperationTypeToSelectedOpLG, convertToOperationalLimitsGroupFormSchema, formatMapInfosToTemporaryLimitsFormSchema, formatOpLimitGroupsToFormInfos, formatTemporaryLimitsModificationToFormSchema, generateEmptyOperationalLimitsGroup, generateUniqueId, getAllLimitsFormData, getAllLimitsFormDataProperties, getLimitsEmptyFormData, getLimitsEmptyFormDataProps, getLimitsValidationSchema, getLimitsValidationSchemaProps, mapServerLimitsGroupsToFormInfos, sanitizeLimitNames, sanitizeLimitsGroups } from "./currentLimits/limitsPane.utils.js";
35
+ import { LimitsChart } from "./currentLimits/limitsEditor/limitsChart.js";
36
+ import { LimitsPropertiesSideStack } from "./currentLimits/limitsEditor/LimitsPropertiesSideStack.js";
37
+ import { LimitsEditor } from "./currentLimits/limitsEditor/LimitsEditor.js";
38
+ import { TemporaryLimitsTable } from "./currentLimits/limitsEditor/TemporaryLimitsTable.js";
39
+ import { OPERATIONAL_LIMITS_GROUPS_MODIFICATION_TYPE } from "./currentLimits/operationalLimitsGroups/operationalLimitsGroups.types.js";
40
+ import { LimitsGroupsContextualMenu } from "./currentLimits/operationalLimitsGroups/LimitsGroupsContextualMenu.js";
41
+ import { LimitsPropertiesStack } from "./currentLimits/operationalLimitsGroups/LimitsPropertiesStack.js";
42
+ import { OperationalLimitsGroups } from "./currentLimits/operationalLimitsGroups/OperationalLimitsGroups.js";
43
+ import { OperationalLimitsGroupTabLabel } from "./currentLimits/operationalLimitsGroups/OperationalLimitsGroupTabLabel.js";
31
44
  export {
45
+ APPLICABILITY,
32
46
  ActivePowerControlForm,
33
47
  BranchActiveReactivePowerMeasurementsForm,
34
48
  BranchConnectivityForm,
35
49
  BusbarSectionVoltageMeasurementsForm,
36
50
  ConnectivityForm,
37
51
  INSERT,
52
+ LimitsChart,
53
+ LimitsEditor,
54
+ LimitsGroupsContextualMenu,
55
+ LimitsPane,
56
+ LimitsPropertiesSideStack,
57
+ LimitsPropertiesStack,
58
+ LimitsTagChip,
59
+ OPERATIONAL_LIMITS_GROUPS_MODIFICATION_TYPE,
60
+ OperationalLimitsGroupTabLabel,
61
+ OperationalLimitsGroups,
38
62
  PowerMeasurementsForm,
39
63
  PowerWithValidityForm,
40
64
  PropertiesForm,
@@ -48,8 +72,14 @@ export {
48
72
  RegulatingTerminalForm,
49
73
  SetPointsForm,
50
74
  ShortCircuitForm,
75
+ TEMPORARY_LIMIT_MODIFICATION_TYPE,
76
+ TemporaryLimitsTable,
51
77
  VoltageLevelConnectivityForm,
52
78
  VoltageRegulationForm,
79
+ addModificationTypeToOpLimitsGroups,
80
+ addModificationTypeToTemporaryLimits,
81
+ addOperationTypeToSelectedOpLG,
82
+ convertToOperationalLimitsGroupFormSchema,
53
83
  copyEquipmentPropertiesForCreation,
54
84
  createConnectivityData,
55
85
  createPropertyModification,
@@ -57,15 +87,25 @@ export {
57
87
  emptyProperties,
58
88
  fetchPredefinedProperties,
59
89
  filledTextField,
90
+ formatMapInfosToTemporaryLimitsFormSchema,
91
+ formatOpLimitGroupsToFormInfos,
92
+ formatTemporaryLimitsModificationToFormSchema,
93
+ generateEmptyOperationalLimitsGroup,
94
+ generateUniqueId,
60
95
  getActivePowerControlEmptyFormData,
61
96
  getActivePowerControlSchema,
62
97
  getActivePowerSetPointSchema,
98
+ getAllLimitsFormData,
99
+ getAllLimitsFormDataProperties,
63
100
  getBranchActiveReactivePowerEditData,
64
101
  getBranchActiveReactivePowerEditDataProperties,
65
102
  getBranchActiveReactivePowerEmptyFormData,
66
103
  getBranchActiveReactivePowerEmptyFormDataProperties,
67
104
  getBranchActiveReactivePowerValidationSchema,
105
+ getBranchActiveReactivePowerValidationSchemaObject,
68
106
  getBranchActiveReactivePowerValidationSchemaProperties,
107
+ getBranchConnectivityWithPositionEmptyFormDataProps,
108
+ getBranchConnectivityWithPositionSchema,
69
109
  getCon1andCon2WithPositionValidationSchema,
70
110
  getConcatenatedProperties,
71
111
  getConnectivityBusBarSectionData,
@@ -90,11 +130,16 @@ export {
90
130
  getInjectionActiveReactivePowerEmptyFormDataProperties,
91
131
  getInjectionActiveReactivePowerValidationSchema,
92
132
  getInjectionActiveReactivePowerValidationSchemaProperties,
133
+ getLimitsEmptyFormData,
134
+ getLimitsEmptyFormDataProps,
135
+ getLimitsValidationSchema,
136
+ getLimitsValidationSchemaProps,
93
137
  getNewVoltageLevelData,
94
138
  getPowerWithValidityEditData,
95
139
  getPowerWithValidityEmptyFormData,
96
140
  getPowerWithValidityValidationSchema,
97
141
  getPropertiesFromModification,
142
+ getPropertyAvatar,
98
143
  getPropertyValue,
99
144
  getReactiveCapabilityCurveValidationSchema,
100
145
  getReactiveCapabilityCurveValidationSchemaArray,
@@ -119,8 +164,11 @@ export {
119
164
  getVoltageRegulationSchema,
120
165
  initializedProperty,
121
166
  italicFontTextField,
167
+ mapServerLimitsGroupsToFormInfos,
122
168
  mergeModificationAndEquipmentProperties,
123
169
  modificationPropertiesSchema,
170
+ sanitizeLimitNames,
171
+ sanitizeLimitsGroups,
124
172
  setCurrentReactiveCapabilityCurveTable,
125
173
  setSelectedReactiveLimits,
126
174
  standardTextField,
@@ -27,6 +27,17 @@ export declare const getBranchActiveReactivePowerValidationSchemaProperties: ()
27
27
  validity: undefined;
28
28
  }, "">;
29
29
  };
30
+ export declare const getBranchActiveReactivePowerValidationSchemaObject: () => import('yup').ObjectSchema<{
31
+ [x: string]: {
32
+ validity?: boolean | null | undefined;
33
+ value?: number | null | undefined;
34
+ };
35
+ }, import('yup').AnyObject, {
36
+ [x: string]: {
37
+ value: undefined;
38
+ validity: undefined;
39
+ };
40
+ }, "">;
30
41
  export declare const getBranchActiveReactivePowerValidationSchema: (id: string) => {
31
42
  [x: string]: import('yup').ObjectSchema<{
32
43
  [x: string]: {
@@ -1,5 +1,5 @@
1
1
  import { object } from "yup";
2
- import { getPowerWithValidityEditData, getPowerWithValidityEmptyFormData, getPowerWithValidityValidationSchema } from "./powerWithValidity.utils.js";
2
+ import { getPowerWithValidityEmptyFormData, getPowerWithValidityEditData, getPowerWithValidityValidationSchema } from "./powerWithValidity.utils.js";
3
3
  import { FieldConstants } from "../../../../utils/constants/fieldConstants.js";
4
4
  import "../../../../utils/conversionUtils.js";
5
5
  import "../../../../utils/types/equipmentType.js";
@@ -26,10 +26,11 @@ const getBranchActiveReactivePowerValidationSchemaProperties = () => ({
26
26
  ...getPowerWithValidityValidationSchema(FieldConstants.MEASUREMENT_P2),
27
27
  ...getPowerWithValidityValidationSchema(FieldConstants.MEASUREMENT_Q2)
28
28
  });
29
+ const getBranchActiveReactivePowerValidationSchemaObject = () => object().shape({
30
+ ...getBranchActiveReactivePowerValidationSchemaProperties()
31
+ });
29
32
  const getBranchActiveReactivePowerValidationSchema = (id) => ({
30
- [id]: object().shape({
31
- ...getBranchActiveReactivePowerValidationSchemaProperties()
32
- })
33
+ [id]: getBranchActiveReactivePowerValidationSchemaObject()
33
34
  });
34
35
  function getBranchActiveReactivePowerEditDataProperties(branchData) {
35
36
  return {
@@ -64,5 +65,6 @@ export {
64
65
  getBranchActiveReactivePowerEmptyFormData,
65
66
  getBranchActiveReactivePowerEmptyFormDataProperties,
66
67
  getBranchActiveReactivePowerValidationSchema,
68
+ getBranchActiveReactivePowerValidationSchemaObject,
67
69
  getBranchActiveReactivePowerValidationSchemaProperties
68
70
  };
@@ -1,6 +1,6 @@
1
1
  import { getPowerWithValidityEditData, getPowerWithValidityEmptyFormData, getPowerWithValidityValidationSchema } from "./powerWithValidity.utils.js";
2
2
  import { getInjectionActiveReactivePowerEditData, getInjectionActiveReactivePowerEditDataProperties, getInjectionActiveReactivePowerEmptyFormData, getInjectionActiveReactivePowerEmptyFormDataProperties, getInjectionActiveReactivePowerValidationSchema, getInjectionActiveReactivePowerValidationSchemaProperties } from "./injectionActiveReactivePowerForm.utils.js";
3
- import { getBranchActiveReactivePowerEditData, getBranchActiveReactivePowerEditDataProperties, getBranchActiveReactivePowerEmptyFormData, getBranchActiveReactivePowerEmptyFormDataProperties, getBranchActiveReactivePowerValidationSchema, getBranchActiveReactivePowerValidationSchemaProperties } from "./branchActiveReactivePowerForm.utils.js";
3
+ import { getBranchActiveReactivePowerEditData, getBranchActiveReactivePowerEditDataProperties, getBranchActiveReactivePowerEmptyFormData, getBranchActiveReactivePowerEmptyFormDataProperties, getBranchActiveReactivePowerValidationSchema, getBranchActiveReactivePowerValidationSchemaObject, getBranchActiveReactivePowerValidationSchemaProperties } from "./branchActiveReactivePowerForm.utils.js";
4
4
  import { PowerWithValidityForm } from "./PowerWithValidityForm.js";
5
5
  import { PowerMeasurementsForm } from "./PowerMeasurementsForm.js";
6
6
  import { BranchActiveReactivePowerMeasurementsForm } from "./BranchActiveReactivePowerMeasurementsForm.js";
@@ -15,6 +15,7 @@ export {
15
15
  getBranchActiveReactivePowerEmptyFormData,
16
16
  getBranchActiveReactivePowerEmptyFormDataProperties,
17
17
  getBranchActiveReactivePowerValidationSchema,
18
+ getBranchActiveReactivePowerValidationSchemaObject,
18
19
  getBranchActiveReactivePowerValidationSchemaProperties,
19
20
  getInjectionActiveReactivePowerEditData,
20
21
  getInjectionActiveReactivePowerEditDataProperties,
@@ -84,7 +84,7 @@ function ReactiveCapabilityCurveTableForm({
84
84
  } else {
85
85
  labelSuffix = index - 1;
86
86
  }
87
- return /* @__PURE__ */ jsxs(Grid2, { container: true, spacing: 3, children: [
87
+ return /* @__PURE__ */ jsxs(Grid2, { container: true, spacing: 3, width: "100%", children: [
88
88
  /* @__PURE__ */ jsx(ReactiveCapabilityCurveRowForm, { id, index, labelSuffix }),
89
89
  /* @__PURE__ */ jsx(Grid2, { size: 1, children: /* @__PURE__ */ jsx(
90
90
  IconButton,
@@ -1,5 +1,5 @@
1
1
  import { jsxs, Fragment, jsx } from "react/jsx-runtime";
2
- import { Box, Grid2 } from "@mui/material";
2
+ import { Grid2 } from "@mui/material";
3
3
  import { useMemo } from "react";
4
4
  import { useWatch } from "react-hook-form";
5
5
  import { useIntl, FormattedMessage } from "react-intl";
@@ -82,10 +82,7 @@ function VoltageRegulationForm({
82
82
  previousValue: translatedPreviousRegulationLabel ?? void 0
83
83
  }
84
84
  ) }),
85
- /* @__PURE__ */ jsx(Box, { sx: { width: "100%" } }),
86
- /* @__PURE__ */ jsx(Grid2, { size: 4, justifySelf: "end" }),
87
- /* @__PURE__ */ jsx(Box, { sx: { width: "100%" } }),
88
- isDistantRegulation && /* @__PURE__ */ jsxs(Fragment, { children: [
85
+ isDistantRegulation && /* @__PURE__ */ jsxs(Grid2, { container: true, size: 12, spacing: 2, children: [
89
86
  /* @__PURE__ */ jsx(Grid2, { size: 4, justifySelf: "end", children: /* @__PURE__ */ jsx(FormattedMessage, { id: "RegulatingTerminalGenerator" }) }),
90
87
  /* @__PURE__ */ jsx(GridItem, { size: 8, children: /* @__PURE__ */ jsx(
91
88
  RegulatingTerminalForm,
@@ -98,8 +95,7 @@ function VoltageRegulationForm({
98
95
  equipmentSectionType: previousEquipmentSectionType
99
96
  }
100
97
  ) }),
101
- /* @__PURE__ */ jsx(Grid2, { size: 4, justifySelf: "end" }),
102
- /* @__PURE__ */ jsx(GridItem, { size: 4, children: /* @__PURE__ */ jsx(
98
+ /* @__PURE__ */ jsx(GridItem, { size: 4, offset: 4, children: /* @__PURE__ */ jsx(
103
99
  FloatInput,
104
100
  {
105
101
  name: FieldConstants.Q_PERCENT,
@@ -65,6 +65,9 @@ import "react-window";
65
65
  import "../../../components/composite/report/report-treeview/treeview-item.js";
66
66
  import "../../../components/composite/report/report-viewer/context/report-viewer-context.js";
67
67
  import "../common/regulatingTerminal/RegulatingTerminalForm.js";
68
+ import "@mui/material/colors";
69
+ import "@mui/x-charts";
70
+ import "../common/currentLimits/limitsPane.utils.js";
68
71
  import { HvdcLccDeletionSpecificForm } from "./hvdcLccDeletion/HvdcLccDeletionSpecificForm.js";
69
72
  const NULL_UUID = "00000000-0000-0000-0000-000000000000";
70
73
  const EQUIPMENT_TYPE_ORDER = [
@@ -1,5 +1,5 @@
1
1
  import { jsx, jsxs, Fragment } from "react/jsx-runtime";
2
- import { Box, Grid2 } from "@mui/material";
2
+ import { Box, Grid2, Stack } from "@mui/material";
3
3
  import { FormattedMessage } from "react-intl";
4
4
  import { useWatch } from "react-hook-form";
5
5
  import { filledTextField, italicFontTextField } from "../../common/form.utils.js";
@@ -74,6 +74,9 @@ import { ShortCircuitForm } from "../../common/shortCircuit/ShortCircuitForm.js"
74
74
  import { ReactiveLimitsForm } from "../../common/reactiveLimits/ReactiveLimitsForm.js";
75
75
  import "../../common/regulatingTerminal/RegulatingTerminalForm.js";
76
76
  import { VoltageRegulationForm } from "../../common/voltageRegulation/VoltageRegulationForm.js";
77
+ import "@mui/material/colors";
78
+ import "@mui/x-charts";
79
+ import "../../common/currentLimits/limitsPane.utils.js";
77
80
  function GeneratorCreationForm({
78
81
  voltageLevelOptions,
79
82
  fetchBusesOrBusbarSections,
@@ -166,7 +169,6 @@ function GeneratorCreationForm({
166
169
  /* @__PURE__ */ jsx(ReactiveLimitsForm, {}),
167
170
  /* @__PURE__ */ jsx(SetPointsForm, {}),
168
171
  /* @__PURE__ */ jsxs(Grid2, { container: true, spacing: 2, paddingTop: 2, children: [
169
- /* @__PURE__ */ jsx(Box, { sx: { width: "100%" } }),
170
172
  /* @__PURE__ */ jsx(
171
173
  GridItem,
172
174
  {
@@ -176,15 +178,16 @@ function GeneratorCreationForm({
176
178
  }
177
179
  ),
178
180
  voltageRegulationFields,
179
- /* @__PURE__ */ jsx(Box, { sx: { width: "100%" } }),
180
181
  /* @__PURE__ */ jsx(ActivePowerControlForm, {})
181
182
  ] }),
182
183
  /* @__PURE__ */ jsx(GridSection, { title: "ShortCircuit" }),
183
184
  /* @__PURE__ */ jsx(ShortCircuitForm, {}),
184
185
  /* @__PURE__ */ jsx(GridSection, { title: "GenerationDispatch" }),
185
- /* @__PURE__ */ jsxs(Grid2, { container: true, spacing: 2, children: [
186
- /* @__PURE__ */ jsx(GridItem, { size: 4, children: plannedActivePowerSetPointField }),
187
- /* @__PURE__ */ jsx(GridItem, { size: 4, children: marginalCostField }),
186
+ /* @__PURE__ */ jsxs(Stack, { spacing: 2, children: [
187
+ /* @__PURE__ */ jsxs(Grid2, { container: true, spacing: 2, children: [
188
+ /* @__PURE__ */ jsx(GridItem, { size: 4, children: plannedActivePowerSetPointField }),
189
+ /* @__PURE__ */ jsx(GridItem, { size: 4, children: marginalCostField })
190
+ ] }),
188
191
  /* @__PURE__ */ jsxs(Grid2, { container: true, spacing: 2, children: [
189
192
  /* @__PURE__ */ jsx(GridItem, { size: 4, children: plannedOutageRateField }),
190
193
  /* @__PURE__ */ jsx(GridItem, { size: 4, children: forcedOutageRateField })
@@ -69,6 +69,9 @@ import { getReactiveLimitsValidationSchema, getReactiveLimitsEmptyFormDataProps,
69
69
  import "../../common/regulatingTerminal/RegulatingTerminalForm.js";
70
70
  import { getRegulatingTerminalEquipmentData, getRegulatingTerminalVoltageLevelData } from "../../common/regulatingTerminal/regulatingTerminal.utils.js";
71
71
  import { getVoltageRegulationSchema, getVoltageRegulationEmptyFormData, REGULATION_TYPES } from "../../common/voltageRegulation/voltageRegulation.utils.js";
72
+ import "@mui/material/colors";
73
+ import "@mui/x-charts";
74
+ import "../../common/currentLimits/limitsPane.utils.js";
72
75
  const generatorCreationFormSchema = object().shape({
73
76
  [FieldConstants.EQUIPMENT_ID]: string().required(),
74
77
  [FieldConstants.EQUIPMENT_NAME]: string().nullable(),
@@ -62,6 +62,9 @@ import "react-window";
62
62
  import "../../../../components/composite/report/report-treeview/treeview-item.js";
63
63
  import "../../../../components/composite/report/report-viewer/context/report-viewer-context.js";
64
64
  import "../../common/regulatingTerminal/RegulatingTerminalForm.js";
65
+ import "@mui/material/colors";
66
+ import "@mui/x-charts";
67
+ import "../../common/currentLimits/limitsPane.utils.js";
65
68
  function GeneratorDialogHeader({ generatorToModify, equipmentId }) {
66
69
  const intl = useIntl();
67
70
  const energySourceLabelId = getEnergySourceLabel(generatorToModify?.energySource);