@elliemae/ds-chat 2.1.1-rc.1 → 3.0.0-next.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/cjs/parts/chat-composer/ChatContainerComposer.js +2 -3
- package/cjs/parts/chat-composer/props.js +0 -2
- package/esm/parts/chat-composer/ChatContainerComposer.js +2 -3
- package/esm/parts/chat-composer/props.js +0 -2
- package/package.json +10 -10
- package/types/parts/chat-composer/ChatContainerComposer.d.ts +0 -3
|
@@ -48,7 +48,6 @@ const ChatComposer = props => {
|
|
|
48
48
|
placeholder,
|
|
49
49
|
inputMaxLength,
|
|
50
50
|
maxLengthMessage,
|
|
51
|
-
ariaMaxLengthMessage,
|
|
52
51
|
buttonDisabled,
|
|
53
52
|
dataTestid,
|
|
54
53
|
actionRef
|
|
@@ -152,8 +151,8 @@ const ChatComposer = props => {
|
|
|
152
151
|
}, void 0, inputMaxLength && hasError ? /*#__PURE__*/jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
153
152
|
children: [/*#__PURE__*/_jsx__default["default"](styled.StyledCounterErrorA11y, {
|
|
154
153
|
role: "alert"
|
|
155
|
-
}, void 0,
|
|
156
|
-
}) : '', inputMaxLength ? " ".concat(inputLength, " / ").concat(inputMaxLength) : ''), _Grid || (_Grid = /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {}))));
|
|
154
|
+
}, void 0, maxLengthMessage || "You have entered ".concat(inputLength, " characters and have exceeded the limit by ").concat(inputLength - inputMaxLength, ". Please limit to less than ").concat(inputMaxLength, " characters. ")), maxLengthMessage || "Please limit to less than ".concat(inputMaxLength, " characters. ")]
|
|
155
|
+
}) : '', inputMaxLength && !maxLengthMessage ? " ".concat(inputLength, " / ").concat(inputMaxLength) : ''), _Grid || (_Grid = /*#__PURE__*/_jsx__default["default"](dsGrid.Grid, {}))));
|
|
157
156
|
};
|
|
158
157
|
|
|
159
158
|
ChatComposer.defaultProps = props.defaultComposerPros;
|
|
@@ -8,7 +8,6 @@ var lodash = require('lodash');
|
|
|
8
8
|
const defaultComposerPros = {
|
|
9
9
|
placeholder: 'Type your message',
|
|
10
10
|
inputValue: '',
|
|
11
|
-
ariaMaxLengthMessage: '',
|
|
12
11
|
onChange: lodash.noop,
|
|
13
12
|
onResize: lodash.noop,
|
|
14
13
|
onSend: lodash.noop,
|
|
@@ -25,7 +24,6 @@ const defaultComposerPros = {
|
|
|
25
24
|
const composerProps = {
|
|
26
25
|
placeholder: reactDesc.PropTypes.string.description('Input Placeholder').defaultValue(defaultComposerPros.placeholder),
|
|
27
26
|
inputValue: reactDesc.PropTypes.string.description('Input value').defaultValue(defaultComposerPros.inputValue),
|
|
28
|
-
ariaMaxLengthMessage: reactDesc.PropTypes.string.description('Aria message for Max length message when exceeded').defaultValue(defaultComposerPros.maxLengthMessage),
|
|
29
27
|
maxLengthMessage: reactDesc.PropTypes.string.description('Max length message').defaultValue(defaultComposerPros.maxLengthMessage),
|
|
30
28
|
onChange: reactDesc.PropTypes.func.description('Called when the user types').defaultValue(defaultComposerPros.onChange),
|
|
31
29
|
onResize: reactDesc.PropTypes.func.description('Called the input changes his height').defaultValue(defaultComposerPros.onResize),
|
|
@@ -38,7 +38,6 @@ const ChatComposer = props => {
|
|
|
38
38
|
placeholder,
|
|
39
39
|
inputMaxLength,
|
|
40
40
|
maxLengthMessage,
|
|
41
|
-
ariaMaxLengthMessage,
|
|
42
41
|
buttonDisabled,
|
|
43
42
|
dataTestid,
|
|
44
43
|
actionRef
|
|
@@ -142,8 +141,8 @@ const ChatComposer = props => {
|
|
|
142
141
|
}, void 0, inputMaxLength && hasError ? /*#__PURE__*/jsxs(Fragment, {
|
|
143
142
|
children: [/*#__PURE__*/_jsx(StyledCounterErrorA11y, {
|
|
144
143
|
role: "alert"
|
|
145
|
-
}, void 0,
|
|
146
|
-
}) : '', inputMaxLength ? " ".concat(inputLength, " / ").concat(inputMaxLength) : ''), _Grid || (_Grid = /*#__PURE__*/_jsx(Grid, {}))));
|
|
144
|
+
}, void 0, maxLengthMessage || "You have entered ".concat(inputLength, " characters and have exceeded the limit by ").concat(inputLength - inputMaxLength, ". Please limit to less than ").concat(inputMaxLength, " characters. ")), maxLengthMessage || "Please limit to less than ".concat(inputMaxLength, " characters. ")]
|
|
145
|
+
}) : '', inputMaxLength && !maxLengthMessage ? " ".concat(inputLength, " / ").concat(inputMaxLength) : ''), _Grid || (_Grid = /*#__PURE__*/_jsx(Grid, {}))));
|
|
147
146
|
};
|
|
148
147
|
|
|
149
148
|
ChatComposer.defaultProps = defaultComposerPros;
|
|
@@ -4,7 +4,6 @@ import { noop } from 'lodash';
|
|
|
4
4
|
const defaultComposerPros = {
|
|
5
5
|
placeholder: 'Type your message',
|
|
6
6
|
inputValue: '',
|
|
7
|
-
ariaMaxLengthMessage: '',
|
|
8
7
|
onChange: noop,
|
|
9
8
|
onResize: noop,
|
|
10
9
|
onSend: noop,
|
|
@@ -21,7 +20,6 @@ const defaultComposerPros = {
|
|
|
21
20
|
const composerProps = {
|
|
22
21
|
placeholder: PropTypes.string.description('Input Placeholder').defaultValue(defaultComposerPros.placeholder),
|
|
23
22
|
inputValue: PropTypes.string.description('Input value').defaultValue(defaultComposerPros.inputValue),
|
|
24
|
-
ariaMaxLengthMessage: PropTypes.string.description('Aria message for Max length message when exceeded').defaultValue(defaultComposerPros.maxLengthMessage),
|
|
25
23
|
maxLengthMessage: PropTypes.string.description('Max length message').defaultValue(defaultComposerPros.maxLengthMessage),
|
|
26
24
|
onChange: PropTypes.func.description('Called when the user types').defaultValue(defaultComposerPros.onChange),
|
|
27
25
|
onResize: PropTypes.func.description('Called the input changes his height').defaultValue(defaultComposerPros.onResize),
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@elliemae/ds-chat",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.0.0-next.0",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "ICE MT - Dimsum - Chat",
|
|
6
6
|
"module": "./esm/index.js",
|
|
@@ -305,15 +305,15 @@
|
|
|
305
305
|
"generateSubmodules": true
|
|
306
306
|
},
|
|
307
307
|
"dependencies": {
|
|
308
|
-
"@elliemae/ds-banner": "
|
|
309
|
-
"@elliemae/ds-button": "
|
|
310
|
-
"@elliemae/ds-grid": "
|
|
311
|
-
"@elliemae/ds-icons": "
|
|
312
|
-
"@elliemae/ds-indeterminate-progress-indicator": "
|
|
313
|
-
"@elliemae/ds-props-helpers": "
|
|
314
|
-
"@elliemae/ds-system": "
|
|
315
|
-
"@elliemae/ds-tooltip": "
|
|
316
|
-
"@elliemae/ds-truncated-tooltip-text": "
|
|
308
|
+
"@elliemae/ds-banner": "3.0.0-next.0",
|
|
309
|
+
"@elliemae/ds-button": "3.0.0-next.0",
|
|
310
|
+
"@elliemae/ds-grid": "3.0.0-next.0",
|
|
311
|
+
"@elliemae/ds-icons": "3.0.0-next.0",
|
|
312
|
+
"@elliemae/ds-indeterminate-progress-indicator": "3.0.0-next.0",
|
|
313
|
+
"@elliemae/ds-props-helpers": "3.0.0-next.0",
|
|
314
|
+
"@elliemae/ds-system": "3.0.0-next.0",
|
|
315
|
+
"@elliemae/ds-tooltip": "3.0.0-next.0",
|
|
316
|
+
"@elliemae/ds-truncated-tooltip-text": "3.0.0-next.0",
|
|
317
317
|
"prop-types": "~15.7.2",
|
|
318
318
|
"react-desc": "~4.1.2",
|
|
319
319
|
"react-virtual": "~2.3.2"
|
|
@@ -10,9 +10,6 @@ declare const ChatComposer: {
|
|
|
10
10
|
inputValue: {
|
|
11
11
|
deprecated: import("react-desc").PropTypesDescValidator;
|
|
12
12
|
};
|
|
13
|
-
ariaMaxLengthMessage: {
|
|
14
|
-
deprecated: import("react-desc").PropTypesDescValidator;
|
|
15
|
-
};
|
|
16
13
|
maxLengthMessage: {
|
|
17
14
|
deprecated: import("react-desc").PropTypesDescValidator;
|
|
18
15
|
};
|