@zohoim/chat-components 1.1.5 → 1.1.6

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/README.md CHANGED
@@ -10,6 +10,11 @@ In this Library, We Provide Some Basic Message Components to Build Your Chat App
10
10
 
11
11
  > import MessageBubble from '@zohoim/chat-components/es/MessageBubble/MessageBubble’;
12
12
 
13
+ # 1.1.6
14
+
15
+ - In the message component, MP3 format support has been added for some integrations.
16
+ - **ReplyComposer** Added support for bodyElement rendering.
17
+
13
18
  # 1.1.5
14
19
 
15
20
  - lib folder added
@@ -49,6 +49,7 @@ export default function ReplyComposer(props) {
49
49
  onFileSubmit: propOnFileSubmit,
50
50
  attachmentPreviewTexts,
51
51
  renderHeader,
52
+ renderBody,
52
53
  renderFooter,
53
54
  renderStencils,
54
55
  getEditorState: propGetEditorState,
@@ -104,6 +105,7 @@ export default function ReplyComposer(props) {
104
105
  isLoaded
105
106
  }, newStyle);
106
107
  const headerElement = useMemo(() => renderHandler(renderHeader)(), [renderHeader]);
108
+ const bodyElement = useMemo(() => renderBody ? renderHandler(renderBody)() : null, [renderBody]);
107
109
  const stencilsElement = useMemo(() => isLoading ? renderHandler(renderStencils)({
108
110
  needFooter
109
111
  }) : null, [renderStencils, needFooter, isLoading]);
@@ -125,7 +127,7 @@ export default function ReplyComposer(props) {
125
127
  onDescriptionChange: onChangeFileDescription,
126
128
  onSubmit: onFileSubmit,
127
129
  texts: attachmentPreviewTexts
128
- }, attachmentPreviewCustomProps)) : null, isLoaded ? headerElement : null, stencilsElement || null, /*#__PURE__*/React.createElement("div", {
130
+ }, attachmentPreviewCustomProps)) : null, isLoaded ? headerElement : null, stencilsElement || null, bodyElement || /*#__PURE__*/React.createElement("div", {
129
131
  className: replEditorWrapperClass
130
132
  }, /*#__PURE__*/React.createElement(ReplyEditor, _extends({
131
133
  content: content,
@@ -69,6 +69,7 @@ function ReplyComposer(props) {
69
69
  propOnFileSubmit = props.onFileSubmit,
70
70
  attachmentPreviewTexts = props.attachmentPreviewTexts,
71
71
  renderHeader = props.renderHeader,
72
+ renderBody = props.renderBody,
72
73
  renderFooter = props.renderFooter,
73
74
  renderStencils = props.renderStencils,
74
75
  propGetEditorState = props.getEditorState,
@@ -126,6 +127,9 @@ function ReplyComposer(props) {
126
127
  var headerElement = (0, _react.useMemo)(function () {
127
128
  return (0, _renderHandler["default"])(renderHeader)();
128
129
  }, [renderHeader]);
130
+ var bodyElement = (0, _react.useMemo)(function () {
131
+ return renderBody ? (0, _renderHandler["default"])(renderBody)() : null;
132
+ }, [renderBody]);
129
133
  var stencilsElement = (0, _react.useMemo)(function () {
130
134
  return isLoading ? (0, _renderHandler["default"])(renderStencils)({
131
135
  needFooter: needFooter
@@ -149,7 +153,7 @@ function ReplyComposer(props) {
149
153
  onDescriptionChange: onChangeFileDescription,
150
154
  onSubmit: onFileSubmit,
151
155
  texts: attachmentPreviewTexts
152
- }, attachmentPreviewCustomProps)) : null, isLoaded ? headerElement : null, stencilsElement || null, /*#__PURE__*/_react["default"].createElement("div", {
156
+ }, attachmentPreviewCustomProps)) : null, isLoaded ? headerElement : null, stencilsElement || null, bodyElement || /*#__PURE__*/_react["default"].createElement("div", {
153
157
  className: replEditorWrapperClass
154
158
  }, /*#__PURE__*/_react["default"].createElement(_ReplyEditor["default"], _extends({
155
159
  content: content,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zohoim/chat-components",
3
- "version": "1.1.5",
3
+ "version": "1.1.6",
4
4
  "description": "Chat Components",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",
@@ -35,7 +35,7 @@
35
35
  "@zoho/SecurityJS": "7.2.4",
36
36
  "@zohodesk-private/color-variable-preprocessor": "1.2.1",
37
37
  "@zohodesk-private/css-variable-migrator": "1.0.8",
38
- "@zohodesk/a11y": "2.3.5",
38
+ "@zohodesk/a11y": "2.3.6",
39
39
  "@zohodesk/components": "1.4.3",
40
40
  "@zohodesk/hooks": "2.0.5",
41
41
  "@zohodesk/icon": "1.3.15",
@@ -55,7 +55,7 @@
55
55
  },
56
56
  "peerDependencies": {
57
57
  "@zoho/SecurityJS": "7.2.4",
58
- "@zohodesk/a11y": "2.3.5",
58
+ "@zohodesk/a11y": "2.3.6",
59
59
  "@zohodesk/components": "1.4.3",
60
60
  "@zohodesk/hooks": "2.0.5",
61
61
  "@zohodesk/icon": "1.3.15",
@@ -65,10 +65,10 @@
65
65
  "@zohodesk/utils": "1.3.14",
66
66
  "@zohodesk/variables": "1.0.0",
67
67
  "@zohodesk/virtualizer": "1.0.13",
68
- "@zohoim/chat-components-hooks": "1.1.4-beta.2",
69
- "@zohoim/chat-components-utils": "1.1.4-beta.2",
68
+ "@zohoim/chat-components-hooks": "1.1.5",
69
+ "@zohoim/chat-components-utils": "1.1.5",
70
70
  "react-sortable-hoc": "1.11.0",
71
71
  "velocity-react": "1.4.3"
72
72
  },
73
- "gitHead": "6908c5dc26f36e0bc17fa00d3d3d8fd79d821c82"
73
+ "gitHead": "12f5b46c16bcfb53245611851fe4ff5fb429567d"
74
74
  }