@mtes-mct/monitor-ui 23.5.0 → 24.0.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.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,23 @@
1
+ ## [23.5.0](https://github.com/MTES-MCT/monitor-ui/compare/v23.4.0...v23.5.0) (2024-10-07)
2
+
3
+
4
+ ### Features
5
+
6
+ * **fields:** rollback pointer-events hack in Select ([799e911](https://github.com/MTES-MCT/monitor-ui/commit/799e911d7c63a9e7c726f0c25f9a0e41a04a0bb6))
7
+
8
+
9
+ ### Bug Fixes
10
+
11
+ * **cypress:** pass missing option to retry in clickButton() ([e70f974](https://github.com/MTES-MCT/monitor-ui/commit/e70f974b69cf63fed285733ca5266fb5ebcffc7f))
12
+
13
+
14
+ ### Buid System & Dependencies
15
+
16
+ * **deps:** bump @babel/runtime in the non-major-dependencies group ([7c18617](https://github.com/MTES-MCT/monitor-ui/commit/7c18617e56f86c851b388e33be61b23874aaec5d))
17
+ * **dev-deps:** bump @semantic-release/release-notes-generator ([418147a](https://github.com/MTES-MCT/monitor-ui/commit/418147a72baa1ee0ec195d8cd71e330c727fc1db))
18
+ * **dev-deps:** bump the all-non-major-dependencies group ([0fd5de1](https://github.com/MTES-MCT/monitor-ui/commit/0fd5de1837b981e902a5c7b3ac68f275f421e5f4))
19
+ * **dev-deps:** bump the non-major-dev-dependencies group with 20 updates ([fe9aa0e](https://github.com/MTES-MCT/monitor-ui/commit/fe9aa0ee317ef2a3d9a4da392d1cc6b11b018617))
20
+
1
21
  ## [23.4.0](https://github.com/MTES-MCT/monitor-ui/compare/v23.3.0...v23.4.0) (2024-09-30)
2
22
 
3
23
 
@@ -3,7 +3,7 @@ import { type IconProps } from '@types_/definitions';
3
3
  import { type ButtonHTMLAttributes, type FunctionComponent, type ReactNode } from 'react';
4
4
  export type LinkButtonProps = ButtonHTMLAttributes<HTMLButtonElement> & {
5
5
  Icon?: FunctionComponent<IconProps> | undefined;
6
- children?: string | ReactNode | undefined;
6
+ children: string | ReactNode;
7
7
  size?: Size | undefined;
8
8
  };
9
9
  export declare function LinkButton({ children, className, Icon, size, ...props }: Readonly<LinkButtonProps>): import("react/jsx-runtime").JSX.Element;
@@ -1 +1 @@
1
- {"version":3,"file":"LinkButton.d.ts","sourceRoot":"","sources":["../../src/elements/LinkButton.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,YAAY,CAAA;AAEjC,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,qBAAqB,CAAA;AAGpD,OAAO,EAAE,KAAK,oBAAoB,EAAE,KAAK,iBAAiB,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAGzF,MAAM,MAAM,eAAe,GAAG,oBAAoB,CAAC,iBAAiB,CAAC,GAAG;IACtE,IAAI,CAAC,EAAE,iBAAiB,CAAC,SAAS,CAAC,GAAG,SAAS,CAAA;IAC/C,QAAQ,CAAC,EAAE,MAAM,GAAG,SAAS,GAAG,SAAS,CAAA;IACzC,IAAI,CAAC,EAAE,IAAI,GAAG,SAAS,CAAA;CACxB,CAAA;AACD,wBAAgB,UAAU,CAAC,EAAE,QAAQ,EAAE,SAAS,EAAE,IAAI,EAAE,IAAkB,EAAE,GAAG,KAAK,EAAE,EAAE,QAAQ,CAAC,eAAe,CAAC,2CAWhH"}
1
+ {"version":3,"file":"LinkButton.d.ts","sourceRoot":"","sources":["../../src/elements/LinkButton.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,YAAY,CAAA;AAEjC,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,qBAAqB,CAAA;AAEpD,OAAO,EAAE,KAAK,oBAAoB,EAAE,KAAK,iBAAiB,EAAE,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAGzF,MAAM,MAAM,eAAe,GAAG,oBAAoB,CAAC,iBAAiB,CAAC,GAAG;IACtE,IAAI,CAAC,EAAE,iBAAiB,CAAC,SAAS,CAAC,GAAG,SAAS,CAAA;IAC/C,QAAQ,EAAE,MAAM,GAAG,SAAS,CAAA;IAC5B,IAAI,CAAC,EAAE,IAAI,GAAG,SAAS,CAAA;CACxB,CAAA;AACD,wBAAgB,UAAU,CAAC,EAAE,QAAQ,EAAE,SAAS,EAAE,IAAI,EAAE,IAAkB,EAAE,GAAG,KAAK,EAAE,EAAE,QAAQ,CAAC,eAAe,CAAC,2CAWhH"}
package/index.js CHANGED
@@ -21874,43 +21874,43 @@ var index = /*#__PURE__*/Object.freeze({
21874
21874
  Warning: Warning
21875
21875
  });
21876
21876
 
21877
- var Accent;
21878
- (function(Accent) {
21877
+ var Accent = /*#__PURE__*/ function(Accent) {
21879
21878
  Accent["ERROR"] = "ERROR";
21880
21879
  Accent["PRIMARY"] = "PRIMARY";
21881
21880
  Accent["SECONDARY"] = "SECONDARY";
21882
21881
  Accent["TERTIARY"] = "TERTIARY";
21883
21882
  Accent["WARNING"] = "WARNING";
21884
- })(Accent || (Accent = {}));
21885
- var Level;
21886
- (function(Level) {
21883
+ return Accent;
21884
+ }({});
21885
+ var Level = /*#__PURE__*/ function(Level) {
21887
21886
  Level["ERROR"] = "ERROR";
21888
21887
  Level["INFO"] = "INFO";
21889
21888
  Level["SUCCESS"] = "SUCCESS";
21890
21889
  Level["WARNING"] = "WARNING";
21891
- })(Level || (Level = {}));
21892
- var CoordinatesFormat;
21893
- (function(CoordinatesFormat) {
21890
+ return Level;
21891
+ }({});
21892
+ var CoordinatesFormat = /*#__PURE__*/ function(CoordinatesFormat) {
21894
21893
  CoordinatesFormat["DECIMAL_DEGREES"] = "DD";
21895
21894
  CoordinatesFormat["DEGREES_MINUTES_DECIMALS"] = "DMD";
21896
21895
  CoordinatesFormat["DEGREES_MINUTES_SECONDS"] = "DMS";
21897
- })(CoordinatesFormat || (CoordinatesFormat = {}));
21898
- var RichBoolean;
21899
- (function(RichBoolean) {
21896
+ return CoordinatesFormat;
21897
+ }({});
21898
+ var RichBoolean = /*#__PURE__*/ function(RichBoolean) {
21900
21899
  RichBoolean["BOTH"] = "BOTH";
21901
21900
  RichBoolean["FALSE"] = "FALSE";
21902
21901
  RichBoolean["TRUE"] = "TRUE";
21903
- })(RichBoolean || (RichBoolean = {}));
21904
- var Size;
21905
- (function(Size) {
21902
+ return RichBoolean;
21903
+ }({});
21904
+ var Size = /*#__PURE__*/ function(Size) {
21906
21905
  Size["LARGE"] = "LARGE";
21907
21906
  Size["NORMAL"] = "NORMAL";
21908
21907
  Size["SMALL"] = "SMALL";
21909
- })(Size || (Size = {}));
21910
- var TagBullet;
21911
- (function(TagBullet) {
21908
+ return Size;
21909
+ }({});
21910
+ var TagBullet = /*#__PURE__*/ function(TagBullet) {
21912
21911
  TagBullet["DISK"] = "DISK";
21913
- })(TagBullet || (TagBullet = {}));
21912
+ return TagBullet;
21913
+ }({});
21914
21914
  const WSG84_PROJECTION = 'EPSG:4326';
21915
21915
  const OPENLAYERS_PROJECTION = 'EPSG:3857';
21916
21916
 
@@ -53986,7 +53986,7 @@ const Box$c = styled.div`
53986
53986
 
53987
53987
  function LinkButton({ children, className, Icon, size = Size.NORMAL, ...props }) {
53988
53988
  const controlledClassName = classnames('Element-LinkButton', className);
53989
- return /*#__PURE__*/ jsx(StyledLinkButton, {
53989
+ return /*#__PURE__*/ jsx(StyledLinkButton$1, {
53990
53990
  $size: size,
53991
53991
  className: controlledClassName,
53992
53992
  ...props,
@@ -53996,11 +53996,7 @@ function LinkButton({ children, className, Icon, size = Size.NORMAL, ...props })
53996
53996
  color: THEME.color.slateGray,
53997
53997
  size: ICON_SIZE$1[size]
53998
53998
  }),
53999
- lodashExports.isString(children) ? /*#__PURE__*/ jsx("p", {
54000
- children: children
54001
- }) : /*#__PURE__*/ jsx(Fragment, {
54002
- children: children
54003
- })
53999
+ children
54004
54000
  ]
54005
54001
  })
54006
54002
  });
@@ -54015,7 +54011,7 @@ const ICON_SIZE$1 = {
54015
54011
  [Size.NORMAL]: 13,
54016
54012
  [Size.SMALL]: 11
54017
54013
  };
54018
- const StyledLinkButton = styled.button`
54014
+ const StyledLinkButton$1 = styled.button`
54019
54015
  align-items: flex-end;
54020
54016
  background: transparent;
54021
54017
  color: ${(p)=>p.theme.color.slateGray};
@@ -54029,6 +54025,7 @@ const StyledLinkButton = styled.button`
54029
54025
  &:hover,
54030
54026
  &._hover {
54031
54027
  color: ${(p)=>p.theme.color.blueYonder};
54028
+
54032
54029
  svg {
54033
54030
  color: ${(p)=>p.theme.color.blueYonder};
54034
54031
  }
@@ -54037,6 +54034,7 @@ const StyledLinkButton = styled.button`
54037
54034
  &:active,
54038
54035
  &._active {
54039
54036
  color: ${(p)=>p.theme.color.blueGray};
54037
+
54040
54038
  svg {
54041
54039
  color: ${(p)=>p.theme.color.blueGray};
54042
54040
  }
@@ -54045,6 +54043,7 @@ const StyledLinkButton = styled.button`
54045
54043
  &:disabled,
54046
54044
  &._disabled {
54047
54045
  color: ${(p)=>p.theme.color.lightGray};
54046
+
54048
54047
  svg {
54049
54048
  color: ${(p)=>p.theme.color.lightGray};
54050
54049
  }
@@ -54161,12 +54160,10 @@ function Banner({ children, className = undefined, closingDelay = 3000, isClosab
54161
54160
  Icon: Close,
54162
54161
  title: isClosable ? 'Fermer' : 'Masquer'
54163
54162
  }),
54164
- !isClosable && isCollapsible && /*#__PURE__*/ jsx(LinkButton, {
54163
+ !isClosable && isCollapsible && /*#__PURE__*/ jsx(StyledLinkButton, {
54164
+ $level: level,
54165
54165
  size: Size.LARGE,
54166
- children: /*#__PURE__*/ jsx(HideText, {
54167
- $level: level,
54168
- children: "Masquer"
54169
- })
54166
+ children: "Masquer"
54170
54167
  })
54171
54168
  ]
54172
54169
  })
@@ -54204,7 +54201,7 @@ const ContentWrapper = styled.div`
54204
54201
  const ButtonWrapper = styled.div`
54205
54202
  align-self: center;
54206
54203
  `;
54207
- const HideText = styled.span`
54204
+ const StyledLinkButton = styled(LinkButton)`
54208
54205
  ${(p)=>p.$level === Level.ERROR ? css`
54209
54206
  color: ${getBannerPalette(p.$level).color};
54210
54207
  text-decoration: ${getBannerPalette(p.$level).color} underline;
@@ -54551,7 +54548,7 @@ const Link$1 = styled.a`
54551
54548
  }
54552
54549
  }
54553
54550
  `;
54554
- Link$1.displayName = 'LinkButton';
54551
+ Link$1.displayName = 'Link';
54555
54552
 
54556
54553
  function Tag({ accent, backgroundColor, borderColor, children, className, color, Icon, iconColor, isLight = false, withCircleIcon = false, ...nativeProps }) {
54557
54554
  const commonChildren = useMemo(()=>{
@@ -56361,11 +56358,6 @@ function addCommon() {
56361
56358
 
56362
56359
  addCommon();
56363
56360
 
56364
- var CoordinateLatLon;
56365
- (function(CoordinateLatLon) {
56366
- CoordinateLatLon["LATITUDE"] = "LATITUDE";
56367
- CoordinateLatLon["LONGITUDE"] = "LONGITUDE";
56368
- })(CoordinateLatLon || (CoordinateLatLon = {}));
56369
56361
  /**
56370
56362
  * Get coordinates in the specified format
56371
56363
  * @param {number[]} coordinates - Coordinates ([longitude, latitude]) in decimal format.
@@ -66111,12 +66103,6 @@ const RSUITE_CALENDAR_LOCALE = {
66111
66103
  wednesday: 'M',
66112
66104
  yesterday: 'Hier'
66113
66105
  };
66114
- var STATUS;
66115
- (function(STATUS) {
66116
- STATUS["END_DATE"] = "END_DATE";
66117
- STATUS["NO_DATE"] = "NO_DATE";
66118
- STATUS["START_DATE"] = "START_DATE";
66119
- })(STATUS || (STATUS = {}));
66120
66106
 
66121
66107
  function formatNumberAsDoubleDigit(numberLike) {
66122
66108
  return String(numberLike).padStart(2, '0');
@@ -67321,11 +67307,11 @@ function RangeCalendarPicker({ defaultValue, hasSingleCalendar = false, isHistor
67321
67307
  });
67322
67308
  }
67323
67309
 
67324
- var DateRangePosition;
67325
- (function(DateRangePosition) {
67310
+ var DateRangePosition = /*#__PURE__*/ function(DateRangePosition) {
67326
67311
  DateRangePosition["END"] = "END";
67327
67312
  DateRangePosition["START"] = "START";
67328
- })(DateRangePosition || (DateRangePosition = {}));
67313
+ return DateRangePosition;
67314
+ }({});
67329
67315
 
67330
67316
  function DateRangePicker({ baseContainer, className, defaultValue, disabled = false, error, hasSingleCalendar = false, isCompact = false, isErrorMessageHidden = false, isHistorical = false, isLabelHidden = false, isLight = false, isRequired = false, isStringDate = false, isTransparent = false, isUndefinedWhenDisabled = false, label, minutesRange = 15, name, onChange, // eslint-disable-next-line @typescript-eslint/naming-convention
67331
67317
  readOnly = false, style, withTime = false, ...nativeProps }) {
@@ -70132,7 +70118,6 @@ const Dot = styled.span`
70132
70118
  background-color: ${(p)=>p.$backgroundColor ?? 'transparent'};
70133
70119
  `;
70134
70120
 
70135
- var ControlUnit;
70136
70121
  (function(ControlUnit) {
70137
70122
  (function(ControlUnitContactPredefinedName) {
70138
70123
  ControlUnitContactPredefinedName["ADJUNCT"] = "Adjoint";
@@ -70224,12 +70209,6 @@ var ControlUnit;
70224
70209
  ["TRAINING_SHIP"]: 'Bâtiment-école',
70225
70210
  ["TUGBOAT"]: 'Remorqueur'
70226
70211
  };
70227
- // List of PAM units identifiers
70228
- // 10141 PAM Gyptis
70229
- // 10404 PAM Iris
70230
- // 10121 PAM Jeanne Barret
70231
- // 10345 PAM Osiris
70232
- // 10080 PAM Themis
70233
70212
  ControlUnit.PAMControlUnitIds = [
70234
70213
  10141,
70235
70214
  10404,
@@ -70238,6 +70217,7 @@ var ControlUnit;
70238
70217
  10080
70239
70218
  ];
70240
70219
  })(ControlUnit || (ControlUnit = {}));
70220
+ var ControlUnit;
70241
70221
 
70242
70222
  function getControlUnitResourceCategoryFromType(type) {
70243
70223
  switch(type){
@@ -70274,7 +70254,6 @@ function getControlUnitResourceCategoryFromType(type) {
70274
70254
  }
70275
70255
  }
70276
70256
 
70277
- var Mission;
70278
70257
  (function(Mission) {
70279
70258
  (function(MissionSourceEnum) {
70280
70259
  MissionSourceEnum["MONITORENV"] = "MONITORENV";
@@ -70284,6 +70263,7 @@ var Mission;
70284
70263
  MissionSourceEnum["RAPPORTNAV"] = "RAPPORTNAV";
70285
70264
  })(Mission.MissionSourceEnum || (Mission.MissionSourceEnum = {}));
70286
70265
  })(Mission || (Mission = {}));
70266
+ var Mission;
70287
70267
 
70288
70268
  function useDeepCompareEffect(effect, deps) {
70289
70269
  const previousValue = usePrevious(deps);
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@mtes-mct/monitor-ui",
3
3
  "description": "Common React components, hooks, utilities and CSS stylesheets for MonitorFish, MonitorEnv and RapportNav.",
4
- "version": "23.5.0",
4
+ "version": "24.0.0",
5
5
  "license": "AGPL-3.0",
6
6
  "type": "module",
7
7
  "engines": {