@ntbjs/react-components 2.0.2-rc.3 → 2.0.2-rc.4
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/build/inputs/ActionButton/ActionButton.js +5 -9
- package/build/inputs/ActionButton/ActionButton.js.map +1 -1
- package/build/inputs/ActionButton/ActionButton.styled.js +13 -16
- package/build/inputs/ActionButton/ActionButton.styled.js.map +1 -1
- package/build/inputs/CompactTextInput/CompactTextInput.js +71 -58
- package/build/inputs/CompactTextInput/CompactTextInput.js.map +1 -1
- package/build/inputs/CompactTextInput/CompactTextInput.styled.js +208 -133
- package/build/inputs/CompactTextInput/CompactTextInput.styled.js.map +1 -1
- package/build/inputs/TextArea/TextArea.js +77 -67
- package/build/inputs/TextArea/TextArea.js.map +1 -1
- package/build/inputs/TextArea/TextArea.styled.js +204 -171
- package/build/inputs/TextArea/TextArea.styled.js.map +1 -1
- package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryCompactCard/AssetGalleryCompactCard.js +26 -20
- package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryCompactCard/AssetGalleryCompactCard.js.map +1 -1
- package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryCompactCard/AssetGalleryCompactCard.styled.js +15 -19
- package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryCompactCard/AssetGalleryCompactCard.styled.js.map +1 -1
- package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryGridCard/AssetGalleryGridCard.js +16 -18
- package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryGridCard/AssetGalleryGridCard.js.map +1 -1
- package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryGridCard/AssetGalleryGridCard.styled.js +34 -75
- package/build/widgets/AssetGallery/AssetGalleryBase/AssetGalleryGridCard/AssetGalleryGridCard.styled.js.map +1 -1
- package/build/widgets/Instructions/Instructions.js +9 -0
- package/build/widgets/Instructions/Instructions.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { extends as _extends } from '../../_virtual/_rollupPluginBabelHelpers.js';
|
|
2
|
-
import React__default, { useRef, useState, useEffect, useCallback
|
|
2
|
+
import React__default, { useRef, useState, useMemo, useEffect, useCallback } from 'react';
|
|
3
3
|
import { isEmpty } from 'lodash';
|
|
4
4
|
import useMergedRefs from '@restart/hooks/useMergedRefs';
|
|
5
5
|
import { nanoid } from 'nanoid';
|
|
@@ -12,7 +12,7 @@ import '../../data/Tabs/Tabs.js';
|
|
|
12
12
|
import Tooltip from '../../data/Tooltip/Tooltip.js';
|
|
13
13
|
import '../../data/VerificationStatusIcon/VerificationStatusIcon.js';
|
|
14
14
|
import { ReactComponent as SvgEditNote } from '../../icons/edit-note.svg.js';
|
|
15
|
-
import {
|
|
15
|
+
import { TextAreaContainter, Label, SuccessContainerLabel, TextInput, TextInputFieldIconAlert, TextInputField, SuccessContainer, InputIconContainer, TextInputLabel, Description } from './TextArea.styled.js';
|
|
16
16
|
|
|
17
17
|
const TextArea = React__default.forwardRef(function TextArea({
|
|
18
18
|
value,
|
|
@@ -46,77 +46,89 @@ const TextArea = React__default.forwardRef(function TextArea({
|
|
|
46
46
|
const textInputDomNode = useRef(null);
|
|
47
47
|
const textInputRef = useMergedRefs(forwardedRef, textInputDomNode);
|
|
48
48
|
const [inputIsEmpty, setInputIsEmpty] = useState(!(value || defaultValue));
|
|
49
|
-
const [
|
|
49
|
+
const [autoFocus, setAutoFocus] = useState(false);
|
|
50
|
+
const [uniqueId] = useState(nanoid());
|
|
51
|
+
const memoizedDescriptionToolTip = useMemo(() => {
|
|
52
|
+
return descriptionToolTip;
|
|
53
|
+
}, [descriptionToolTip]);
|
|
50
54
|
useEffect(() => {
|
|
51
|
-
|
|
55
|
+
setAutoFocus(false);
|
|
52
56
|
}, [value, defaultValue]);
|
|
53
57
|
const onKeyDown = useCallback(event => {
|
|
54
58
|
if (event.key === 'Enter') {
|
|
55
59
|
event.stopPropagation();
|
|
56
60
|
}
|
|
57
61
|
}, []);
|
|
58
|
-
const
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
62
|
+
const input = () => {
|
|
63
|
+
return React__default.createElement(TextAreaContainter, null, fieldLabel && React__default.createElement(Label, {
|
|
64
|
+
htmlFor: uniqueId,
|
|
65
|
+
disabled: disabled
|
|
66
|
+
}, fieldLabel, React__default.createElement(SuccessContainerLabel, null, type === 'loading' && loadingIcon, type === 'success' && successIcon)), React__default.createElement(TextInput, {
|
|
67
|
+
$fieldLabel: !isEmpty(fieldLabel),
|
|
68
|
+
disabled: disabled,
|
|
69
|
+
readOnly: readOnly,
|
|
70
|
+
$type: type,
|
|
71
|
+
className: className,
|
|
72
|
+
style: style
|
|
73
|
+
}, React__default.createElement(TextInputFieldIconAlert, {
|
|
74
|
+
$type: type
|
|
75
|
+
}, icon), React__default.createElement(TextInputField, _extends({
|
|
76
|
+
autoFocus: autoFocus,
|
|
77
|
+
$borderRadius: borderRadius,
|
|
78
|
+
ref: textInputRef,
|
|
79
|
+
rows: rows,
|
|
80
|
+
value: value,
|
|
81
|
+
defaultValue: defaultValue,
|
|
82
|
+
name: name,
|
|
83
|
+
placeholder: placeholder || ' ',
|
|
84
|
+
required: required,
|
|
85
|
+
readOnly: readOnly,
|
|
86
|
+
disabled: disabled,
|
|
87
|
+
$edit: edit,
|
|
88
|
+
$type: type,
|
|
89
|
+
autoComplete: autoComplete,
|
|
90
|
+
$hasIcon: Boolean(icon),
|
|
91
|
+
id: `text-input-${uniqueId}`,
|
|
92
|
+
key: uniqueId,
|
|
93
|
+
$padding: padding,
|
|
94
|
+
onChange: e => {
|
|
95
|
+
if (e.target.value) {
|
|
96
|
+
setInputIsEmpty(false);
|
|
97
|
+
if (!autoFocus) {
|
|
98
|
+
setAutoFocus(true);
|
|
99
|
+
}
|
|
100
|
+
} else {
|
|
101
|
+
setInputIsEmpty(true);
|
|
102
|
+
if (!autoFocus) {
|
|
103
|
+
setAutoFocus(true);
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
onChange(e);
|
|
107
|
+
},
|
|
108
|
+
onKeyDown: onKeyDown,
|
|
109
|
+
onBlur: onBlur,
|
|
110
|
+
$noBorder: noBorder
|
|
111
|
+
}, rest)), !fieldLabel && (type === 'loading' || type === 'success') && React__default.createElement(SuccessContainer, null, type === 'loading' && loadingIcon, type === 'success' && successIcon), !readOnly && (edit || noBorder) && React__default.createElement(InputIconContainer, {
|
|
112
|
+
disabled: disabled
|
|
113
|
+
}, React__default.createElement(SvgEditNote, {
|
|
114
|
+
className: padding === 'small' ? 'smallPadingIcon' : undefined
|
|
115
|
+
})), label && React__default.createElement(TextInputLabel, {
|
|
116
|
+
htmlFor: `text-input-${uniqueId}`,
|
|
117
|
+
$hasPlaceholder: Boolean(placeholder),
|
|
118
|
+
$hasIcon: Boolean(icon),
|
|
119
|
+
$inputIsEmpty: inputIsEmpty
|
|
120
|
+
}, label, required && ' *'), typeof description === 'string' && description.length > 0 && React__default.createElement(Description, {
|
|
121
|
+
$type: type
|
|
122
|
+
}, description)));
|
|
123
|
+
};
|
|
112
124
|
if (hidden) return null;
|
|
113
|
-
return React__default.createElement(Tooltip, {
|
|
114
|
-
content:
|
|
125
|
+
return React__default.createElement(React__default.Fragment, null, !memoizedDescriptionToolTip && input(), memoizedDescriptionToolTip && React__default.createElement("div", null, React__default.createElement(Tooltip, {
|
|
126
|
+
content: memoizedDescriptionToolTip,
|
|
127
|
+
key: "tooltipTextArea1",
|
|
115
128
|
placement: "bottom-end",
|
|
116
|
-
trigger:
|
|
117
|
-
zIndex: 999999
|
|
118
|
-
|
|
119
|
-
}, wrappedInput);
|
|
129
|
+
trigger: 'mouseenter',
|
|
130
|
+
zIndex: 999999
|
|
131
|
+
}, input())));
|
|
120
132
|
});
|
|
121
133
|
TextArea.defaultProps = {
|
|
122
134
|
rows: 4,
|
|
@@ -152,14 +164,12 @@ TextArea.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
|
152
164
|
onChange: PropTypes.func,
|
|
153
165
|
onBlur: PropTypes.func,
|
|
154
166
|
noBorder: PropTypes.bool,
|
|
155
|
-
isExpanded: PropTypes.func,
|
|
156
167
|
type: PropTypes.oneOf(['', 'error', 'error-border', 'warning-border', 'warning', 'loading', 'success']),
|
|
157
168
|
loadingIcon: PropTypes.element,
|
|
158
169
|
successIcon: PropTypes.element,
|
|
159
170
|
descriptionToolTip: PropTypes.string,
|
|
160
171
|
borderRadius: PropTypes.number
|
|
161
172
|
} : {};
|
|
162
|
-
var TextArea$1 = memo(TextArea);
|
|
163
173
|
|
|
164
|
-
export { TextArea
|
|
174
|
+
export { TextArea as default };
|
|
165
175
|
//# sourceMappingURL=TextArea.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"TextArea.js","sources":["../../../src/components/inputs/TextArea/TextArea.js"],"sourcesContent":["import React, { useCallback, useEffect, useRef, useState, useMemo, memo } from 'react';\nimport { isEmpty } from 'lodash';\nimport useMergedRefs from '@restart/hooks/useMergedRefs';\nimport { nanoid } from 'nanoid';\nimport PropTypes from 'prop-types';\nimport { Tooltip } from '../../data';\n\nimport { ReactComponent as EditNoteIcon } from '../../../icons/edit-note.svg';\nimport * as S from './TextArea.styled';\n\n/**\n * Text areas let users enter and edit text in the UI. They typically appear in forms and dialogs.\n *\n * ### Import\n *\n * ``` js\n * import { TextArea } from '@ntbjs/react-components/inputs'\n * // or\n * import TextArea from '@ntbjs/react-components/inputs/TextArea'\n * ```\n */\nconst TextArea = React.forwardRef(function TextArea(\n {\n value,\n defaultValue,\n name,\n label,\n placeholder,\n required,\n disabled,\n hidden,\n readOnly,\n edit,\n autoComplete,\n description,\n type,\n icon,\n rows,\n className,\n style,\n onChange,\n onBlur,\n noBorder,\n loadingIcon,\n successIcon,\n padding,\n descriptionToolTip,\n borderRadius,\n fieldLabel,\n ...rest\n },\n forwardedRef\n) {\n const textInputDomNode = useRef(null);\n const textInputRef = useMergedRefs(forwardedRef, textInputDomNode);\n\n const [inputIsEmpty, setInputIsEmpty] = useState(!(value || defaultValue));\n const [uniqueId] = useState(() => nanoid());\n\n useEffect(() => {\n setInputIsEmpty(!(value || defaultValue));\n }, [value, defaultValue]);\n\n const onKeyDown = useCallback(event => {\n if (event.key === 'Enter') {\n event.stopPropagation();\n }\n }, []);\n\n const handleChange = useCallback(\n e => {\n setInputIsEmpty(!e.target.value);\n onChange(e);\n },\n [onChange]\n );\n\n const textAreaElement = useMemo(\n () => (\n <S.TextInputField\n ref={textInputRef}\n rows={rows}\n value={value}\n defaultValue={defaultValue}\n name={name}\n placeholder={placeholder}\n required={required}\n readOnly={readOnly}\n disabled={disabled}\n $edit={edit}\n $type={type}\n autoComplete={autoComplete}\n $hasIcon={Boolean(icon)}\n id={`text-input-${uniqueId}`}\n $padding={padding}\n $borderRadius={borderRadius}\n $noBorder={noBorder}\n onChange={handleChange}\n onKeyDown={onKeyDown}\n onBlur={onBlur}\n {...rest}\n />\n ),\n [\n textInputRef,\n rows,\n value,\n defaultValue,\n name,\n placeholder,\n required,\n readOnly,\n disabled,\n edit,\n type,\n autoComplete,\n icon,\n uniqueId,\n padding,\n borderRadius,\n noBorder,\n handleChange,\n onKeyDown,\n onBlur,\n rest\n ]\n );\n\n const wrappedInput = useMemo(\n () => (\n <S.TextAreaContainter>\n {fieldLabel && (\n <S.Label htmlFor={uniqueId} $disabled={disabled}>\n {fieldLabel}\n <S.SuccessContainerLabel $type={type}>\n {type === 'loading' && loadingIcon}\n {type === 'success' && successIcon}\n </S.SuccessContainerLabel>\n </S.Label>\n )}\n <S.TextInput\n $fieldLabel={!isEmpty(fieldLabel)}\n disabled={disabled}\n readOnly={readOnly}\n $type={type}\n className={className}\n style={style}\n >\n {icon && <S.TextInputFieldIconAlert $type={type}>{icon}</S.TextInputFieldIconAlert>}\n {textAreaElement}\n {!fieldLabel && (type === 'loading' || type === 'success') && (\n <S.SuccessContainer $type={type}>\n {type === 'loading' && loadingIcon}\n {type === 'success' && successIcon}\n </S.SuccessContainer>\n )}\n {!readOnly && noBorder && (\n <S.InputIconContainer $disabled={disabled}>\n <EditNoteIcon className={padding === 'small' ? 'smallPadingIcon' : undefined} />\n </S.InputIconContainer>\n )}\n {label && (\n <S.TextInputLabel\n htmlFor={`text-input-${uniqueId}`}\n $hasPlaceholder={Boolean(placeholder)}\n $hasIcon={Boolean(icon)}\n $inputIsEmpty={inputIsEmpty}\n >\n {label}\n {required && ' *'}\n </S.TextInputLabel>\n )}\n {typeof description === 'string' && description.length > 0 && (\n <S.Description $type={type}>{description}</S.Description>\n )}\n </S.TextInput>\n </S.TextAreaContainter>\n ),\n [\n fieldLabel,\n uniqueId,\n disabled,\n type,\n loadingIcon,\n successIcon,\n icon,\n textAreaElement,\n readOnly,\n noBorder,\n padding,\n label,\n placeholder,\n inputIsEmpty,\n required,\n description,\n className,\n style\n ]\n );\n\n if (hidden) return null;\n\n return (\n <Tooltip\n content={descriptionToolTip || ''}\n placement=\"bottom-end\"\n trigger=\"mouseenter\"\n zIndex={999999}\n disabled={!descriptionToolTip}\n >\n {wrappedInput}\n </Tooltip>\n );\n});\n\nTextArea.defaultProps = {\n rows: 4,\n noBorder: false,\n readOnly: false,\n edit: false,\n hidden: false,\n type: '',\n padding: 'medium',\n descriptionToolTip: '',\n onChange: () => {},\n borderRadius: 0\n};\n\nTextArea.propTypes = {\n /**\n * Value to be sent. Typically the content of the text area.\n */\n value: PropTypes.string,\n\n /**\n * Default value/text to be displayed in the text area by default.\n */\n defaultValue: PropTypes.string,\n\n /**\n * Name of the text area (used when sending form data)\n */\n name: PropTypes.string,\n\n /**\n * Label text for the text area. If the text area is empty (no input and no placeholder)\n * and isn't in focus, the label text will be displayed grayed out in the text area itself.\n * Otherwise, the label text will be displayed in the top left corner.\n */\n label: PropTypes.string,\n\n /**\n * Field Label text for the text area field. I\n */\n fieldLabel: PropTypes.string,\n\n /**\n * Placeholder text to be displayed if the text area is empty (no input)\n */\n placeholder: PropTypes.string,\n\n /**\n * Whether the user is required to fill in the text area\n */\n required: PropTypes.bool,\n\n /**\n * Whether the text area is disabled\n */\n disabled: PropTypes.bool,\n /**\n * Whether the component is hidden or visible.\n */\n hidden: PropTypes.bool,\n /**\n * Whether the text area is read-only\n */\n readOnly: PropTypes.bool,\n /**\n * Displays a grey background to show that value is editable\n */\n edit: PropTypes.bool,\n /**\n * ?\n */\n autoComplete: PropTypes.string,\n /**\n * Descriptive text displayed below the text area\n */\n description: PropTypes.string,\n\n /**\n * Optional icon to be displayed left of the text inside the text area\n */\n icon: PropTypes.element,\n /**\n * How many rows/lines of text to be displayed by default\n */\n rows: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),\n /**\n * Add custom class names to the HTML element\n */\n className: PropTypes.string,\n /**\n * Add custom CSS styling\n */\n style: PropTypes.object,\n /**\n * Add padding (small-medium-large)\n */\n padding: PropTypes.oneOf(['small', 'medium', 'large']),\n /**\n * Optional callback function for the `onChange` event\n */\n onChange: PropTypes.func,\n /**\n * Optional callback function for the `onBlur` event\n */\n onBlur: PropTypes.func,\n noBorder: PropTypes.bool,\n // warningAlert: PropTypes.bool,\n // errorAlert: PropTypes.bool,\n isExpanded: PropTypes.func,\n /**\n * Define the type based on error,error-border , warning, loading and success.\n */\n type: PropTypes.oneOf([\n '',\n 'error',\n 'error-border',\n 'warning-border',\n 'warning',\n 'loading',\n 'success'\n ]),\n /**\n * Icon element – E.g: `icon={<Spinner />}`\n */\n loadingIcon: PropTypes.element,\n /**\n * Icon element – E.g: `icon={<Check />}`\n */\n successIcon: PropTypes.element,\n /**\n * Description ToolTip text.\n */\n descriptionToolTip: PropTypes.string,\n /**\n * Border Radius for rounded borders.\n */\n borderRadius: PropTypes.number\n};\n\nexport default memo(TextArea);\n"],"names":["TextArea","React","forwardRef","value","defaultValue","name","label","placeholder","required","disabled","hidden","readOnly","edit","autoComplete","description","type","icon","rows","className","style","onChange","onBlur","noBorder","loadingIcon","successIcon","padding","descriptionToolTip","borderRadius","fieldLabel","rest","forwardedRef","textInputDomNode","useRef","textInputRef","useMergedRefs","inputIsEmpty","setInputIsEmpty","useState","uniqueId","nanoid","useEffect","onKeyDown","useCallback","event","key","stopPropagation","handleChange","e","target","textAreaElement","useMemo","createElement","S","_extends","ref","$edit","$type","$hasIcon","Boolean","id","$padding","$borderRadius","$noBorder","wrappedInput","htmlFor","$disabled","$fieldLabel","isEmpty","EditNoteIcon","undefined","$hasPlaceholder","$inputIsEmpty","length","Tooltip","content","placement","trigger","zIndex","defaultProps","propTypes","process","env","NODE_ENV","PropTypes","string","bool","element","oneOfType","number","object","oneOf","func","isExpanded","memo"],"mappings":";;;;;;;;;;;;;;;;AAqBA,MAAMA,QAAQ,GAAGC,cAAK,CAACC,UAAU,CAAC,SAASF,QAAQA,CACjD;EACEG,KAAK;EACLC,YAAY;EACZC,IAAI;EACJC,KAAK;EACLC,WAAW;EACXC,QAAQ;EACRC,QAAQ;EACRC,MAAM;EACNC,QAAQ;EACRC,IAAI;EACJC,YAAY;EACZC,WAAW;EACXC,IAAI;EACJC,IAAI;EAC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AAE+D,SAAS,CAACQ,IAAI;EAIxBtE,MAAM,EAAE8D,SAAS,CAACQ,IAAI;EACtBrE,QAAQ,EAAE6D,SAAS,CAACE,IAAI;EAGxBO,UAAU,EAAET,SAAS,CAACQ,IAAI;EAI1B5E,IAAI,EAAEoE,SAAS,CAACO,KAAK,CAAC,CACpB,EAAE,EACF,OAAO,EACP,cAAc,EACd,gBAAgB,EAChB,SAAS,EACT,SAAS,EACT,SAAS,CACV,CAAC;EAIFnE,WAAW,EAAE4D,SAAS,CAACG,OAAO;EAI9B9D,WAAW,EAAE2D,SAAS,CAACG,OAAO;EAI9B5D,kBAAkB,EAAEyD,SAAS,CAACC,MAAM;EAIpCzD,YAAY,EAAEwD,SAAS,CAACK,MAAAA;AAC1B,CAAC,GAAA,EAAA,CAAA;AAED,iBAAeK,IAAI,CAAC7F,QAAQ,CAAC;;;;"}
|
|
1
|
+
{"version":3,"file":"TextArea.js","sources":["../../../src/components/inputs/TextArea/TextArea.js"],"sourcesContent":["import React, { useCallback, useEffect, useRef, useState, useMemo } from 'react';\n\nimport { isEmpty } from 'lodash';\nimport useMergedRefs from '@restart/hooks/useMergedRefs';\nimport { nanoid } from 'nanoid';\nimport PropTypes from 'prop-types';\nimport { Tooltip } from '../../data';\n\nimport { ReactComponent as EditNoteIcon } from '../../../icons/edit-note.svg';\nimport * as S from './TextArea.styled';\n\n/**\n * Text areas let users enter and edit text in the UI. They typically appear in forms and dialogs.\n *\n * ### Import\n *\n * ``` js\n * import { TextArea } from '@ntbjs/react-components/inputs'\n * // or\n * import TextArea from '@ntbjs/react-components/inputs/TextArea'\n * ```\n */\nconst TextArea = React.forwardRef(function TextArea(\n {\n value,\n defaultValue,\n name,\n label,\n placeholder,\n required,\n disabled,\n hidden,\n readOnly,\n edit,\n autoComplete,\n description,\n type,\n icon,\n rows,\n className,\n style,\n onChange,\n onBlur,\n noBorder,\n loadingIcon,\n successIcon,\n padding,\n descriptionToolTip,\n borderRadius,\n fieldLabel,\n ...rest\n },\n forwardedRef\n) {\n const textInputDomNode = useRef(null);\n const textInputRef = useMergedRefs(forwardedRef, textInputDomNode);\n\n const [inputIsEmpty, setInputIsEmpty] = useState(!(value || defaultValue));\n const [autoFocus, setAutoFocus] = useState(false);\n\n const [uniqueId] = useState(nanoid());\n\n const memoizedDescriptionToolTip = useMemo(() => {\n return descriptionToolTip;\n }, [descriptionToolTip]);\n\n useEffect(() => {\n setAutoFocus(false);\n }, [value, defaultValue]);\n\n const onKeyDown = useCallback(event => {\n if (event.key === 'Enter') {\n event.stopPropagation();\n }\n }, []);\n\n const input = () => {\n return (\n <S.TextAreaContainter>\n {fieldLabel && (\n <S.Label htmlFor={uniqueId} disabled={disabled}>\n {fieldLabel}\n <S.SuccessContainerLabel>\n {type === 'loading' && loadingIcon}\n {type === 'success' && successIcon}\n </S.SuccessContainerLabel>\n </S.Label>\n )}\n <S.TextInput\n $fieldLabel={!isEmpty(fieldLabel)}\n disabled={disabled}\n readOnly={readOnly}\n $type={type}\n className={className}\n style={style}\n >\n <S.TextInputFieldIconAlert $type={type}>{icon}</S.TextInputFieldIconAlert>\n <S.TextInputField\n autoFocus={autoFocus}\n $borderRadius={borderRadius}\n ref={textInputRef}\n rows={rows}\n value={value}\n defaultValue={defaultValue}\n name={name}\n placeholder={placeholder || ' '}\n required={required}\n readOnly={readOnly}\n disabled={disabled}\n $edit={edit}\n $type={type}\n autoComplete={autoComplete}\n $hasIcon={Boolean(icon)}\n id={`text-input-${uniqueId}`}\n key={uniqueId}\n $padding={padding}\n onChange={e => {\n if (e.target.value) {\n setInputIsEmpty(false);\n if (!autoFocus) {\n setAutoFocus(true);\n }\n } else {\n setInputIsEmpty(true);\n if (!autoFocus) {\n setAutoFocus(true);\n }\n }\n onChange(e);\n }}\n onKeyDown={onKeyDown}\n onBlur={onBlur}\n $noBorder={noBorder}\n {...rest}\n />\n {!fieldLabel && (type === 'loading' || type === 'success') && (\n <S.SuccessContainer>\n {type === 'loading' && loadingIcon}\n {type === 'success' && successIcon}\n </S.SuccessContainer>\n )}\n {!readOnly && (edit || noBorder) && (\n <S.InputIconContainer disabled={disabled}>\n <EditNoteIcon className={padding === 'small' ? 'smallPadingIcon' : undefined} />\n </S.InputIconContainer>\n )}\n {label && (\n <S.TextInputLabel\n htmlFor={`text-input-${uniqueId}`}\n $hasPlaceholder={Boolean(placeholder)}\n $hasIcon={Boolean(icon)}\n $inputIsEmpty={inputIsEmpty}\n >\n {label}\n {required && ' *'}\n </S.TextInputLabel>\n )}\n {typeof description === 'string' && description.length > 0 && (\n <S.Description $type={type}>{description}</S.Description>\n )}\n </S.TextInput>\n </S.TextAreaContainter>\n );\n };\n\n if (hidden) return null;\n\n return (\n <>\n {!memoizedDescriptionToolTip && input()}\n {memoizedDescriptionToolTip && (\n <div>\n <Tooltip\n content={memoizedDescriptionToolTip}\n key=\"tooltipTextArea1\"\n placement=\"bottom-end\"\n trigger={'mouseenter'}\n zIndex={999999}\n >\n {input()}\n </Tooltip>\n </div>\n )}\n </>\n );\n});\n\nTextArea.defaultProps = {\n rows: 4,\n noBorder: false,\n readOnly: false,\n edit: false,\n hidden: false,\n type: '',\n padding: 'medium',\n descriptionToolTip: '',\n onChange: () => {},\n borderRadius: 0\n};\n\nTextArea.propTypes = {\n /**\n * Value to be sent. Typically the content of the text area.\n */\n value: PropTypes.string,\n\n /**\n * Default value/text to be displayed in the text area by default.\n */\n defaultValue: PropTypes.string,\n\n /**\n * Name of the text area (used when sending form data)\n */\n name: PropTypes.string,\n\n /**\n * Label text for the text area. If the text area is empty (no input and no placeholder)\n * and isn't in focus, the label text will be displayed grayed out in the text area itself.\n * Otherwise, the label text will be displayed in the top left corner.\n */\n label: PropTypes.string,\n\n /**\n * Field Label text for the text area field. I\n */\n fieldLabel: PropTypes.string,\n\n /**\n * Placeholder text to be displayed if the text area is empty (no input)\n */\n placeholder: PropTypes.string,\n\n /**\n * Whether the user is required to fill in the text area\n */\n required: PropTypes.bool,\n\n /**\n * Whether the text area is disabled\n */\n disabled: PropTypes.bool,\n /**\n * Whether the component is hidden or visible.\n */\n hidden: PropTypes.bool,\n /**\n * Whether the text area is read-only\n */\n readOnly: PropTypes.bool,\n /**\n * Displays a grey background to show that value is editable\n */\n edit: PropTypes.bool,\n /**\n * ?\n */\n autoComplete: PropTypes.string,\n /**\n * Descriptive text displayed below the text area\n */\n description: PropTypes.string,\n\n /**\n * Optional icon to be displayed left of the text inside the text area\n */\n icon: PropTypes.element,\n /**\n * How many rows/lines of text to be displayed by default\n */\n rows: PropTypes.oneOfType([PropTypes.number, PropTypes.string]),\n /**\n * Add custom class names to the HTML element\n */\n className: PropTypes.string,\n /**\n * Add custom CSS styling\n */\n style: PropTypes.object,\n /**\n * Add padding (small-medium-large)\n */\n padding: PropTypes.oneOf(['small', 'medium', 'large']),\n /**\n * Optional callback function for the `onChange` event\n */\n onChange: PropTypes.func,\n /**\n * Optional callback function for the `onBlur` event\n */\n onBlur: PropTypes.func,\n noBorder: PropTypes.bool,\n // warningAlert: PropTypes.bool,\n // errorAlert: PropTypes.bool,\n /**\n * Define the type based on error,error-border , warning, loading and success.\n */\n type: PropTypes.oneOf([\n '',\n 'error',\n 'error-border',\n 'warning-border',\n 'warning',\n 'loading',\n 'success'\n ]),\n /**\n * Icon element â€\" E.g: `icon={<Spinner />}`\n */\n loadingIcon: PropTypes.element,\n /**\n * Icon element â€\" E.g: `icon={<Check />}`\n */\n successIcon: PropTypes.element,\n /**\n * Description ToolTip text.\n */\n descriptionToolTip: PropTypes.string,\n /**\n * Border Radius for rounded borders.\n */\n borderRadius: PropTypes.number\n};\n\nexport default TextArea;\n"],"names":["TextArea","React","forwardRef","value","defaultValue","name","label","placeholder","required","disabled","hidden","readOnly","edit","autoComplete","description","type","icon","rows","className","style","onChange","onBlur","noBorder","loadingIcon","successIcon","padding","descriptionToolTip","borderRadius","fieldLabel","rest","forwardedRef","textInputDomNode","useRef","textInputRef","useMergedRefs","inputIsEmpty","setInputIsEmpty","useState","autoFocus","setAutoFocus","uniqueId","nanoid","memoizedDescriptionToolTip","useMemo","useEffect","onKeyDown","useCallback","event","key","stopPropagation","input","createElement","S","htmlFor","$fieldLabel","isEmpty","$type","_extends","$borderRadius","ref","$edit","$hasIcon","Boolean","id","$padding","e","target","$noBorder","EditNoteIcon","undefined","$hasPlaceholder","$inputIsEmpty","length","Fragment","Tooltip","content","placement","trigger","zIndex","defaultProps","propTypes","process","env","NODE_ENV","PropTypes","string","bool","element","oneOfType","number","object","oneOf","func"],"mappings":";;;;;;;;;;;;;;;;AAsBMA,MAAAA,QAAQ,GAAGC,cAAK,CAACC,UAAU,CAAC,SAASF,QAAQA,CACjD;EACEG,KAAK;EACLC,YAAY;EACZC,IAAI;EACJC,KAAK;EACLC,WAAW;EACXC,QAAQ;EACRC,QAAQ;EACRC,MAAM;EACNC,QAAQ;EACRC,IAAI;EACJC,YAAY;EACZC,WAAW;EACXC,IAAI;EACJC,IAAI;EACJC,IAAI;EACJC,SAAS;EACTC,KAAK;EACLC,QAAQ;EACRC,MAAM;EACNC,QAAQ;EACRC,WAAW;EACXC,WAAW;EACXC,OAAO;EACPC,kBAAkB;EAClBC,YAAY;EACZC,UAAU;EACV,GAAGC,IAAAA;AACL,CAAC,EACDC,YAAY,EACZ;AACA,EAAA,MAAMC,gBAAgB,GAAGC,MAAM,CAAC,IAAI,CAAC,CAAA;AACrC,EAAA,MAAMC,YAAY,GAAGC,aAAa,CAACJ,YAAY,EAAEC,gBAAgB,CAAC,CAAA;AAElE,EAAA,MAAM,CAACI,YAAY,EAAEC,eAAe,CAAC,GAAGC,QAAQ,CAAC,EAAElC,KAAK,IAAIC,YAAY,CAAC,CAAC,CAAA;EAC1E,MAAM,CAACkC,SAAS,EAAEC,YAAY,CAAC,GAAGF,QAAQ,CAAC,KAAK,CAAC,CAAA;EAEjD,MAAM,CAACG,QAAQ,CAAC,GAAGH,QAAQ,CAACI,MAAM,EAAE,CAAC,CAAA;AAErC,EAAA,MAAMC,0BAA0B,GAAGC,OAAO,CAAC,MAAM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