@mtes-mct/monitor-ui 21.2.1 → 21.3.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 +14 -0
- package/fields/NumberInput.d.ts +2 -1
- package/fields/NumberInput.d.ts.map +1 -1
- package/index.js +11 -1
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
## [21.2.1](https://github.com/MTES-MCT/monitor-ui/compare/v21.2.0...v21.2.1) (2024-09-06)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* **utils:** sort by French natural order in getOptionsFromLabelledEnum() ([3803823](https://github.com/MTES-MCT/monitor-ui/commit/38038234d4aa389178c80fe89f88e6429aef530c))
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
### Buid System & Dependencies
|
|
10
|
+
|
|
11
|
+
* **deps:** bump micromatch from 4.0.5 to 4.0.8 ([7866fa1](https://github.com/MTES-MCT/monitor-ui/commit/7866fa1c8c0c68aa038e3fb3a0a66994437eef54))
|
|
12
|
+
* **deps:** bump the non-major-dependencies group with 3 updates ([0ac790e](https://github.com/MTES-MCT/monitor-ui/commit/0ac790ed596abe0192b68b4cdd5760352cac7862))
|
|
13
|
+
* **dev-deps:** bump the all-non-major-dependencies group ([ca16c6b](https://github.com/MTES-MCT/monitor-ui/commit/ca16c6b6a6974ec339ca131017aa04b1146e5dea))
|
|
14
|
+
|
|
1
15
|
## [21.2.0](https://github.com/MTES-MCT/monitor-ui/compare/v21.1.1...v21.2.0) (2024-08-27)
|
|
2
16
|
|
|
3
17
|
|
package/fields/NumberInput.d.ts
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { type InputProps } from 'rsuite';
|
|
2
2
|
import type { Promisable } from 'type-fest';
|
|
3
3
|
export type NumberInputProps = Omit<InputProps, 'as' | 'defaultValue' | 'id' | 'onChange' | 'type' | 'value'> & {
|
|
4
|
+
areArrowsHidden?: boolean | undefined;
|
|
4
5
|
disabled?: boolean | undefined;
|
|
5
6
|
error?: string | undefined;
|
|
6
7
|
isErrorMessageHidden?: boolean | undefined;
|
|
@@ -15,5 +16,5 @@ export type NumberInputProps = Omit<InputProps, 'as' | 'defaultValue' | 'id' | '
|
|
|
15
16
|
readOnly?: boolean | undefined;
|
|
16
17
|
value?: number | undefined;
|
|
17
18
|
};
|
|
18
|
-
export declare function NumberInput({ className, disabled, error, isErrorMessageHidden, isLabelHidden, isLight, isRequired, isTransparent, isUndefinedWhenDisabled, label, name, onBlur, onChange, onFocus, readOnly, style, value, ...originalProps }: NumberInputProps): import("react/jsx-runtime").JSX.Element;
|
|
19
|
+
export declare function NumberInput({ areArrowsHidden, className, disabled, error, isErrorMessageHidden, isLabelHidden, isLight, isRequired, isTransparent, isUndefinedWhenDisabled, label, name, onBlur, onChange, onFocus, readOnly, style, value, ...originalProps }: NumberInputProps): import("react/jsx-runtime").JSX.Element;
|
|
19
20
|
//# sourceMappingURL=NumberInput.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"NumberInput.d.ts","sourceRoot":"","sources":["../../src/fields/NumberInput.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAS,KAAK,UAAU,EAAE,MAAM,QAAQ,CAAA;AAiB/C,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAA;AAE3C,MAAM,MAAM,gBAAgB,GAAG,IAAI,CAAC,UAAU,EAAE,IAAI,GAAG,cAAc,GAAG,IAAI,GAAG,UAAU,GAAG,MAAM,GAAG,OAAO,CAAC,GAAG;IAC9G,QAAQ,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAC9B,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,oBAAoB,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAC1C,aAAa,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IACnC,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B,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAC1C,aAAa,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IACnC,OAAO,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAC7B,UAAU,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAChC,aAAa,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IACnC,uBAAuB,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAC7C,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,MAAM,CAAA;IACZ,QAAQ,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,GAAG,SAAS,KAAK,UAAU,CAAC,IAAI,CAAC,CAAA;IAC9D,QAAQ,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IAC9B,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAC3B,CAAA;AACD,wBAAgB,WAAW,CAAC,EAC1B,eAAuB,EACvB,SAAS,EACT,QAAgB,EAChB,KAAK,EACL,oBAA4B,EAC5B,aAAqB,EACrB,OAAe,EACf,UAAkB,EAClB,aAAqB,EACrB,uBAA+B,EAC/B,KAAK,EACL,IAAI,EACJ,MAAM,EACN,QAAQ,EACR,OAAO,EACP,QAAgB,EAChB,KAAK,EACL,KAAK,EACL,GAAG,aAAa,EACjB,EAAE,gBAAgB,2CA+ElB"}
|
package/index.js
CHANGED
|
@@ -68560,7 +68560,7 @@ const Link = styled.a`
|
|
|
68560
68560
|
}
|
|
68561
68561
|
`;
|
|
68562
68562
|
|
|
68563
|
-
function NumberInput({ className, disabled = false, error, isErrorMessageHidden = false, isLabelHidden = false, isLight = false, isRequired = false, isTransparent = false, isUndefinedWhenDisabled = false, label, name, onBlur, onChange, onFocus, readOnly = false, style, value, ...originalProps }) {
|
|
68563
|
+
function NumberInput({ areArrowsHidden = false, className, disabled = false, error, isErrorMessageHidden = false, isLabelHidden = false, isLight = false, isRequired = false, isTransparent = false, isUndefinedWhenDisabled = false, label, name, onBlur, onChange, onFocus, readOnly = false, style, value, ...originalProps }) {
|
|
68564
68564
|
// eslint-disable-next-line no-null/no-null
|
|
68565
68565
|
const inputRef = useRef(null);
|
|
68566
68566
|
const controlledClassname = useMemo(()=>classnames('Field-NumberInput', className), [
|
|
@@ -68620,6 +68620,7 @@ function NumberInput({ className, disabled = false, error, isErrorMessageHidden
|
|
|
68620
68620
|
}),
|
|
68621
68621
|
/*#__PURE__*/ jsx(StyledInput, {
|
|
68622
68622
|
ref: inputRef,
|
|
68623
|
+
$areArrowsHidden: areArrowsHidden,
|
|
68623
68624
|
$hasError: hasError,
|
|
68624
68625
|
$isDisabled: disabled,
|
|
68625
68626
|
$isLight: isLight,
|
|
@@ -68654,6 +68655,15 @@ const StyledInput = styled(Input)`
|
|
|
68654
68655
|
vertical-align: center;
|
|
68655
68656
|
width: 100%;
|
|
68656
68657
|
|
|
68658
|
+
${(p)=>p.$areArrowsHidden && css`
|
|
68659
|
+
-moz-appearance: textfield;
|
|
68660
|
+
|
|
68661
|
+
&::-webkit-outer-spin-button,
|
|
68662
|
+
&::-webkit-inner-spin-button {
|
|
68663
|
+
-webkit-appearance: none;
|
|
68664
|
+
}
|
|
68665
|
+
`}
|
|
68666
|
+
|
|
68657
68667
|
&::placeholder {
|
|
68658
68668
|
color: ${getFieldPlaceholderColorFactoryForState('default')};
|
|
68659
68669
|
}
|
package/package.json
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
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": "21.
|
|
4
|
+
"version": "21.3.0",
|
|
5
5
|
"license": "AGPL-3.0",
|
|
6
6
|
"type": "module",
|
|
7
7
|
"engines": {
|
|
8
8
|
"node": ">=20"
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
|
-
"@babel/runtime": "7.25.
|
|
11
|
+
"@babel/runtime": "7.25.6",
|
|
12
12
|
"@tanstack/react-table": "8.20.5",
|
|
13
13
|
"@tanstack/react-virtual": "beta",
|
|
14
14
|
"prop-types": "15.8.1",
|