@synerise/ds-input 1.1.3 → 1.2.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
@@ -3,6 +3,25 @@
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
+ # [1.2.0](https://github.com/synerise/synerise-design/compare/@synerise/ds-input@1.1.4...@synerise/ds-input@1.2.0) (2025-06-05)
7
+
8
+
9
+ ### Features
10
+
11
+ * **factors:** relative date type ([e3d17f1](https://github.com/synerise/synerise-design/commit/e3d17f18350044322c06c6b51263d69f97ee7dba))
12
+
13
+
14
+
15
+
16
+
17
+ ## [1.1.4](https://github.com/synerise/synerise-design/compare/@synerise/ds-input@1.1.3...@synerise/ds-input@1.1.4) (2025-05-26)
18
+
19
+ **Note:** Version bump only for package @synerise/ds-input
20
+
21
+
22
+
23
+
24
+
6
25
  ## [1.1.3](https://github.com/synerise/synerise-design/compare/@synerise/ds-input@1.1.2...@synerise/ds-input@1.1.3) (2025-05-19)
7
26
 
8
27
  **Note:** Version bump only for package @synerise/ds-input
package/dist/Input.d.ts CHANGED
@@ -2,7 +2,7 @@ import React from 'react';
2
2
  import '@synerise/ds-core/dist/js/style';
3
3
  import './style/index.less';
4
4
  import type { InputProps } from './Input.types';
5
- export declare const Input: ({ className, errorText, label, description, counterLimit, tooltip, tooltipConfig, icon1, icon1Tooltip, autoResize, icon2, icon2Tooltip, resetMargin, handleInputRef, prefixel, suffixel, error, expandable, expandableTooltip, renderCustomCounter, ...antdInputProps }: InputProps) => React.JSX.Element;
5
+ export declare const Input: ({ className, errorText, label, description, counterLimit, tooltip, tooltipConfig, icon1, icon1Tooltip, autoResize, icon2, icon2Tooltip, resetMargin, handleInputRef, prefixel, suffixel, error, expandable, expandableTooltip, renderCustomCounter, autoResizeProps, ...antdInputProps }: InputProps) => React.JSX.Element;
6
6
  export declare const RawInput: (props: InputProps) => React.JSX.Element;
7
7
  export { default as InputGroup } from './InputGroup';
8
8
  export { default as InputMultivalue } from './InputMultivalue/InputMultivalue';
package/dist/Input.js CHANGED
@@ -1,4 +1,4 @@
1
- var _excluded = ["className", "errorText", "label", "description", "counterLimit", "tooltip", "tooltipConfig", "icon1", "icon1Tooltip", "autoResize", "icon2", "icon2Tooltip", "resetMargin", "handleInputRef", "prefixel", "suffixel", "error", "expandable", "expandableTooltip", "renderCustomCounter"];
1
+ var _excluded = ["className", "errorText", "label", "description", "counterLimit", "tooltip", "tooltipConfig", "icon1", "icon1Tooltip", "autoResize", "icon2", "icon2Tooltip", "resetMargin", "handleInputRef", "prefixel", "suffixel", "error", "expandable", "expandableTooltip", "renderCustomCounter", "autoResizeProps"];
2
2
  function _extends() { return _extends = Object.assign ? Object.assign.bind() : function (n) { for (var e = 1; e < arguments.length; e++) { var t = arguments[e]; for (var r in t) ({}).hasOwnProperty.call(t, r) && (n[r] = t[r]); } return n; }, _extends.apply(null, arguments); }
3
3
  function _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }
4
4
  import React, { useState, useEffect, useRef, useMemo, useCallback } from 'react';
@@ -34,6 +34,7 @@ export var Input = function Input(_ref) {
34
34
  expandable = _ref.expandable,
35
35
  expandableTooltip = _ref.expandableTooltip,
36
36
  renderCustomCounter = _ref.renderCustomCounter,
37
+ autoResizeProps = _ref.autoResizeProps,
37
38
  antdInputProps = _objectWithoutPropertiesLoose(_ref, _excluded);
38
39
  var id = useMemo(function () {
39
40
  return uuid();
@@ -158,12 +159,12 @@ export var Input = function Input(_ref) {
158
159
  counterLimit: counterLimit,
159
160
  charCount: charCount
160
161
  });
161
- var autoSizedComponent = /*#__PURE__*/React.createElement(AutosizeWrapper, {
162
+ var autoSizedComponent = /*#__PURE__*/React.createElement(AutosizeWrapper, _extends({}, autoResizeProps, {
162
163
  preAutosize: preAutosize,
163
164
  onAutosize: onAutosize,
164
165
  value: antdInputProps.value,
165
166
  autoResize: !!autoResize
166
- }, /*#__PURE__*/React.createElement(S.AntdInput, _extends({
167
+ }), /*#__PURE__*/React.createElement(S.AntdInput, _extends({
167
168
  autoResize: autoResize,
168
169
  "data-testid": "input-autosize-input"
169
170
  }, antdInputProps, {
@@ -1,6 +1,7 @@
1
1
  import type { ReactNode, ReactElement, MutableRefObject } from 'react';
2
2
  import type { InputProps as AntdInputProps, TextAreaProps as AntdTextAreaProps } from 'antd/lib/input';
3
3
  import type { FormFieldCommonProps } from '@synerise/ds-form-field';
4
+ import type { AutosizeInputProps } from './AutosizeInput/AutosizeInput.types';
4
5
  export type AutoResizeProp = boolean | {
5
6
  minWidth: string;
6
7
  maxWidth?: string;
@@ -21,6 +22,7 @@ export type BaseProps<RefElementType extends HTMLTextAreaElement | HTMLInputElem
21
22
  prefixel?: ReactNode;
22
23
  suffixel?: ReactNode;
23
24
  autoResize?: AutoResizeProp;
25
+ autoResizeProps?: Partial<Pick<AutosizeInputProps, 'placeholderIsMinWidth' | 'wrapperClassName' | 'wrapperStyle' | 'extraWidth'>>;
24
26
  expandable?: boolean;
25
27
  expandableTooltip?: ReactNode;
26
28
  } & FormFieldCommonProps;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@synerise/ds-input",
3
- "version": "1.1.3",
3
+ "version": "1.2.0",
4
4
  "description": "Input UI Component for the Synerise Design System",
5
5
  "license": "ISC",
6
6
  "repository": "synerise/synerise-design",
@@ -34,11 +34,11 @@
34
34
  ],
35
35
  "types": "dist/index.d.ts",
36
36
  "dependencies": {
37
- "@synerise/ds-form-field": "^1.1.3",
38
- "@synerise/ds-icon": "^1.5.0",
39
- "@synerise/ds-scrollbar": "^1.0.8",
40
- "@synerise/ds-tooltip": "^1.1.7",
41
- "@synerise/ds-utils": "^1.1.0",
37
+ "@synerise/ds-form-field": "^1.1.5",
38
+ "@synerise/ds-icon": "^1.5.2",
39
+ "@synerise/ds-scrollbar": "^1.0.10",
40
+ "@synerise/ds-tooltip": "^1.1.9",
41
+ "@synerise/ds-utils": "^1.2.0",
42
42
  "csstype": "2.6.9",
43
43
  "uuid": "^8.3.2"
44
44
  },
@@ -48,5 +48,5 @@
48
48
  "react": ">=16.9.0 <= 18.3.1",
49
49
  "styled-components": "^5.3.3"
50
50
  },
51
- "gitHead": "8aa16b27c86c97e3ac774d92561ab0a03176c439"
51
+ "gitHead": "93bc81d59d20bc8f3bc80c5d56ae7f7c0838380d"
52
52
  }