@synerise/ds-column-manager 0.11.33 → 0.11.35
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
|
@@ -3,6 +3,22 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [0.11.35](https://github.com/Synerise/synerise-design/compare/@synerise/ds-column-manager@0.11.34...@synerise/ds-column-manager@0.11.35) (2024-03-20)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @synerise/ds-column-manager
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
## [0.11.34](https://github.com/Synerise/synerise-design/compare/@synerise/ds-column-manager@0.11.33...@synerise/ds-column-manager@0.11.34) (2024-03-18)
|
|
15
|
+
|
|
16
|
+
**Note:** Version bump only for package @synerise/ds-column-manager
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
6
22
|
## [0.11.33](https://github.com/Synerise/synerise-design/compare/@synerise/ds-column-manager@0.11.32...@synerise/ds-column-manager@0.11.33) (2024-03-13)
|
|
7
23
|
|
|
8
24
|
**Note:** Version bump only for package @synerise/ds-column-manager
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
1
|
+
import { ReactText } from 'react';
|
|
2
|
+
import { InputProps } from '@synerise/ds-input';
|
|
3
3
|
import { Props as NumberInputProps } from '@synerise/ds-input-number/dist/InputNumber.types';
|
|
4
|
-
type RangeInputProps = Omit<
|
|
5
|
-
value:
|
|
6
|
-
onChange: (value:
|
|
4
|
+
type RangeInputProps = Omit<InputProps, 'value' | 'onChange'> & Omit<NumberInputProps, 'value' | 'onChange'> & {
|
|
5
|
+
value: ReactText | undefined;
|
|
6
|
+
onChange: (value: ReactText | undefined) => void;
|
|
7
7
|
};
|
|
8
|
-
declare const RangeInput:
|
|
8
|
+
declare const RangeInput: ({ type, value, onChange, handleInputRef, ...inputProps }: RangeInputProps) => JSX.Element;
|
|
9
9
|
export default RangeInput;
|
|
@@ -1,20 +1,26 @@
|
|
|
1
|
-
var _excluded = ["type", "onChange"];
|
|
1
|
+
var _excluded = ["type", "value", "onChange", "handleInputRef"];
|
|
2
2
|
|
|
3
3
|
function _extends() { _extends = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
|
|
4
4
|
|
|
5
5
|
function _objectWithoutPropertiesLoose(source, excluded) { if (source == null) return {}; var target = {}; var sourceKeys = Object.keys(source); var key, i; for (i = 0; i < sourceKeys.length; i++) { key = sourceKeys[i]; if (excluded.indexOf(key) >= 0) continue; target[key] = source[key]; } return target; }
|
|
6
6
|
|
|
7
|
-
import
|
|
8
|
-
import InputNumber from '@synerise/ds-input-number';
|
|
7
|
+
import React, { useMemo } from 'react';
|
|
9
8
|
import { MaskedInput } from '@synerise/ds-input';
|
|
9
|
+
import InputNumber from '@synerise/ds-input-number';
|
|
10
10
|
import * as S from './RangesForm.styles';
|
|
11
11
|
|
|
12
|
+
var isInputOfNumberType = function isInputOfNumberType(type, value) {
|
|
13
|
+
return type === 'number' && (typeof value === 'number' || typeof value === 'undefined');
|
|
14
|
+
};
|
|
15
|
+
|
|
12
16
|
var RangeInput = function RangeInput(_ref) {
|
|
13
17
|
var type = _ref.type,
|
|
18
|
+
value = _ref.value,
|
|
14
19
|
_onChange = _ref.onChange,
|
|
20
|
+
handleInputRef = _ref.handleInputRef,
|
|
15
21
|
inputProps = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
16
22
|
|
|
17
|
-
var inputMask =
|
|
23
|
+
var inputMask = useMemo(function () {
|
|
18
24
|
switch (type) {
|
|
19
25
|
case 'text':
|
|
20
26
|
return 'A';
|
|
@@ -26,11 +32,14 @@ var RangeInput = function RangeInput(_ref) {
|
|
|
26
32
|
return '1';
|
|
27
33
|
}
|
|
28
34
|
}, [type]);
|
|
29
|
-
return type
|
|
30
|
-
|
|
31
|
-
|
|
35
|
+
return isInputOfNumberType(type, value) ? /*#__PURE__*/React.createElement(S.InputNumberWrapper, null, /*#__PURE__*/React.createElement(InputNumber, _extends({}, inputProps, {
|
|
36
|
+
value: value,
|
|
37
|
+
onChange: function onChange(val) {
|
|
38
|
+
return _onChange(val);
|
|
32
39
|
}
|
|
33
40
|
}))) : /*#__PURE__*/React.createElement(MaskedInput, _extends({}, inputProps, {
|
|
41
|
+
handleInputRef: handleInputRef,
|
|
42
|
+
value: value,
|
|
34
43
|
mask: inputMask,
|
|
35
44
|
placeholderChar: "_",
|
|
36
45
|
resetMargin: true,
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@synerise/ds-column-manager",
|
|
3
|
-
"version": "0.11.
|
|
3
|
+
"version": "0.11.35",
|
|
4
4
|
"description": "ColumnManager UI Component for the Synerise Design System",
|
|
5
5
|
"license": "ISC",
|
|
6
6
|
"repository": "Synerise/synerise-design",
|
|
@@ -30,24 +30,24 @@
|
|
|
30
30
|
"sideEffects": false,
|
|
31
31
|
"types": "dist/index.d.ts",
|
|
32
32
|
"dependencies": {
|
|
33
|
-
"@synerise/ds-alert": "^0.8.
|
|
34
|
-
"@synerise/ds-button": "^0.19.
|
|
35
|
-
"@synerise/ds-drawer": "^0.6.
|
|
36
|
-
"@synerise/ds-dropdown": "^0.17.
|
|
37
|
-
"@synerise/ds-icon": "^0.60.
|
|
38
|
-
"@synerise/ds-input": "^0.20.
|
|
39
|
-
"@synerise/ds-input-number": "^0.9.
|
|
40
|
-
"@synerise/ds-item-filter": "^0.8.
|
|
41
|
-
"@synerise/ds-menu": "^0.18.
|
|
42
|
-
"@synerise/ds-modal": "^0.17.
|
|
43
|
-
"@synerise/ds-result": "^0.6.
|
|
44
|
-
"@synerise/ds-scrollbar": "^0.
|
|
45
|
-
"@synerise/ds-search-bar": "^0.6.
|
|
46
|
-
"@synerise/ds-select": "^0.15.
|
|
47
|
-
"@synerise/ds-switch": "^0.4.
|
|
48
|
-
"@synerise/ds-tooltip": "^0.14.
|
|
33
|
+
"@synerise/ds-alert": "^0.8.7",
|
|
34
|
+
"@synerise/ds-button": "^0.19.4",
|
|
35
|
+
"@synerise/ds-drawer": "^0.6.11",
|
|
36
|
+
"@synerise/ds-dropdown": "^0.17.101",
|
|
37
|
+
"@synerise/ds-icon": "^0.60.4",
|
|
38
|
+
"@synerise/ds-input": "^0.20.2",
|
|
39
|
+
"@synerise/ds-input-number": "^0.9.8",
|
|
40
|
+
"@synerise/ds-item-filter": "^0.8.111",
|
|
41
|
+
"@synerise/ds-menu": "^0.18.16",
|
|
42
|
+
"@synerise/ds-modal": "^0.17.22",
|
|
43
|
+
"@synerise/ds-result": "^0.6.48",
|
|
44
|
+
"@synerise/ds-scrollbar": "^0.9.0",
|
|
45
|
+
"@synerise/ds-search-bar": "^0.6.64",
|
|
46
|
+
"@synerise/ds-select": "^0.15.41",
|
|
47
|
+
"@synerise/ds-switch": "^0.4.63",
|
|
48
|
+
"@synerise/ds-tooltip": "^0.14.21",
|
|
49
49
|
"@synerise/ds-typography": "^0.14.3",
|
|
50
|
-
"@synerise/ds-utils": "^0.
|
|
50
|
+
"@synerise/ds-utils": "^0.26.0",
|
|
51
51
|
"react-intl": "3.12.0",
|
|
52
52
|
"react-sortablejs": "^6.0.0",
|
|
53
53
|
"uuid": "^8.3.2"
|
|
@@ -62,5 +62,5 @@
|
|
|
62
62
|
"@testing-library/jest-dom": "5.1.1",
|
|
63
63
|
"@testing-library/react": "10.0.1"
|
|
64
64
|
},
|
|
65
|
-
"gitHead": "
|
|
65
|
+
"gitHead": "2df913352aa96e8aed75894489afb3a4ee303370"
|
|
66
66
|
}
|