sceyt-chat-react-uikit 1.6.7-beta.7 → 1.6.7-beta.9
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/index.js +20 -6
- package/index.modern.js +20 -6
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -11176,7 +11176,9 @@ var ReplyMessageText = styled__default.span(_templateObject29 || (_templateObjec
|
|
|
11176
11176
|
var CloseIcon = styled__default(SvgClose)(_templateObject30 || (_templateObject30 = _taggedTemplateLiteralLoose(["\n position: absolute;\n top: 13px;\n right: 13px;\n cursor: pointer;\n padding: 15px;\n box-sizing: content-box;\n color: ", ";\n"])), function (props) {
|
|
11177
11177
|
return props.color;
|
|
11178
11178
|
});
|
|
11179
|
-
var ClearTypedText = styled__default(CloseIcon)(_templateObject31 || (_templateObject31 = _taggedTemplateLiteralLoose(["\n position: absolute;\n top: 8px;\n right: 10px;\n cursor: pointer;\n padding: 4px;\n"])))
|
|
11179
|
+
var ClearTypedText = styled__default(CloseIcon)(_templateObject31 || (_templateObject31 = _taggedTemplateLiteralLoose(["\n position: absolute;\n top: 8px;\n right: 10px;\n cursor: pointer;\n padding: 4px;\n color: ", ";\n"])), function (props) {
|
|
11180
|
+
return props.color;
|
|
11181
|
+
});
|
|
11180
11182
|
var StyledSearchSvg = styled__default(SvgSearch)(_templateObject32 || (_templateObject32 = _taggedTemplateLiteralLoose(["\n cursor: pointer;\n position: absolute;\n top: 12px;\n left: ", ";\n"])), function (props) {
|
|
11181
11183
|
return props.left || '14px';
|
|
11182
11184
|
});
|
|
@@ -19603,7 +19605,8 @@ var ChannelSearch = function ChannelSearch(_ref) {
|
|
|
19603
19605
|
var _useColor = useColors(),
|
|
19604
19606
|
textPrimary = _useColor[THEME_COLORS.TEXT_PRIMARY],
|
|
19605
19607
|
surface1Background = _useColor[THEME_COLORS.SURFACE_1],
|
|
19606
|
-
textSecondary = _useColor[THEME_COLORS.TEXT_SECONDARY]
|
|
19608
|
+
textSecondary = _useColor[THEME_COLORS.TEXT_SECONDARY],
|
|
19609
|
+
iconPrimary = _useColor[THEME_COLORS.ICON_PRIMARY];
|
|
19607
19610
|
return /*#__PURE__*/React__default.createElement(SearchInputContainer, {
|
|
19608
19611
|
inline: inline,
|
|
19609
19612
|
borderColor: surface1Background
|
|
@@ -19620,7 +19623,8 @@ var ChannelSearch = function ChannelSearch(_ref) {
|
|
|
19620
19623
|
placeholder: 'Search for channels',
|
|
19621
19624
|
fontSize: fontSize
|
|
19622
19625
|
}), searchValue && /*#__PURE__*/React__default.createElement(ClearTypedText, {
|
|
19623
|
-
onClick: getMyChannels
|
|
19626
|
+
onClick: getMyChannels,
|
|
19627
|
+
color: iconPrimary
|
|
19624
19628
|
}));
|
|
19625
19629
|
};
|
|
19626
19630
|
|
|
@@ -27846,6 +27850,7 @@ var VideoCont = styled__default.div(_templateObject11$3 || (_templateObject11$3
|
|
|
27846
27850
|
|
|
27847
27851
|
var _templateObject$v, _templateObject2$r, _templateObject3$l, _templateObject4$i;
|
|
27848
27852
|
var RepliedMessage = function RepliedMessage(_ref) {
|
|
27853
|
+
var _message$parentMessag;
|
|
27849
27854
|
var message = _ref.message,
|
|
27850
27855
|
theme = _ref.theme,
|
|
27851
27856
|
handleScrollToRepliedMessage = _ref.handleScrollToRepliedMessage,
|
|
@@ -27879,6 +27884,12 @@ var RepliedMessage = function RepliedMessage(_ref) {
|
|
|
27879
27884
|
var parentNotLinkAttachment = message.parentMessage && message.parentMessage.attachments && message.parentMessage.attachments.some(function (a) {
|
|
27880
27885
|
return a.type !== attachmentTypes.link;
|
|
27881
27886
|
});
|
|
27887
|
+
var attachementsLength = React.useMemo(function () {
|
|
27888
|
+
if (message.parentMessage.attachments && !!message.parentMessage.attachments.length && message.parentMessage.attachments[0].type !== attachmentTypes.voice && parentNotLinkAttachment) {
|
|
27889
|
+
return message.parentMessage.attachments.length;
|
|
27890
|
+
}
|
|
27891
|
+
return 0;
|
|
27892
|
+
}, [message.parentMessage.attachments, parentNotLinkAttachment, (_message$parentMessag = message.parentMessage.attachments[0]) === null || _message$parentMessag === void 0 ? void 0 : _message$parentMessag.type, message.parentMessage.attachments.length]);
|
|
27882
27893
|
return /*#__PURE__*/React__default.createElement(ReplyMessageContainer, {
|
|
27883
27894
|
withSenderName: showMessageSenderName,
|
|
27884
27895
|
withBody: !!message.body,
|
|
@@ -27888,7 +27899,7 @@ var RepliedMessage = function RepliedMessage(_ref) {
|
|
|
27888
27899
|
onClick: function onClick() {
|
|
27889
27900
|
return handleScrollToRepliedMessage && !selectionIsActive && handleScrollToRepliedMessage(message.parentMessage.id);
|
|
27890
27901
|
}
|
|
27891
|
-
},
|
|
27902
|
+
}, attachementsLength > 0 && message.parentMessage.attachments.map(function (attachment, index) {
|
|
27892
27903
|
return /*#__PURE__*/React__default.createElement(Attachment$1, {
|
|
27893
27904
|
key: attachment.tid || attachment.url,
|
|
27894
27905
|
backgroundColor: message.incoming ? incomingRepliedMessageBackground || bubbleIncomingX : ownRepliedMessageBackground || bubbleOutgoingX,
|
|
@@ -27908,7 +27919,8 @@ var RepliedMessage = function RepliedMessage(_ref) {
|
|
|
27908
27919
|
videoAttachmentMaxHeight: videoAttachmentMaxHeight
|
|
27909
27920
|
});
|
|
27910
27921
|
}), /*#__PURE__*/React__default.createElement(ReplyMessageBody, {
|
|
27911
|
-
rtlDirection: ownMessageOnRightSide && !message.incoming
|
|
27922
|
+
rtlDirection: ownMessageOnRightSide && !message.incoming,
|
|
27923
|
+
maxWidth: "calc(100% - " + (attachementsLength * 40 + 10) + "px)"
|
|
27912
27924
|
}, /*#__PURE__*/React__default.createElement(MessageOwner, {
|
|
27913
27925
|
className: 'reply-message-owner',
|
|
27914
27926
|
color: accentColor,
|
|
@@ -27945,8 +27957,10 @@ var ReplyMessageContainer = styled__default.div(_templateObject$v || (_templateO
|
|
|
27945
27957
|
}, function (props) {
|
|
27946
27958
|
return !props.withSenderName && props.withAttachments && '8px';
|
|
27947
27959
|
});
|
|
27948
|
-
var ReplyMessageBody = styled__default.div(_templateObject2$r || (_templateObject2$r = _taggedTemplateLiteralLoose(["\n margin-top: auto;\n margin-bottom: auto;\n direction: ", ";\n max-width:
|
|
27960
|
+
var ReplyMessageBody = styled__default.div(_templateObject2$r || (_templateObject2$r = _taggedTemplateLiteralLoose(["\n margin-top: auto;\n margin-bottom: auto;\n direction: ", ";\n max-width: ", ";\n"])), function (props) {
|
|
27949
27961
|
return props.rtlDirection ? 'initial' : '';
|
|
27962
|
+
}, function (props) {
|
|
27963
|
+
return props.maxWidth || '100%';
|
|
27950
27964
|
});
|
|
27951
27965
|
var MessageStatusDeleted = styled__default.span(_templateObject3$l || (_templateObject3$l = _taggedTemplateLiteralLoose(["\n color: ", ";\n font-size: ", ";\n font-style: italic;\n"])), function (props) {
|
|
27952
27966
|
return props.color;
|
package/index.modern.js
CHANGED
|
@@ -11153,7 +11153,9 @@ var ReplyMessageText = styled.span(_templateObject29 || (_templateObject29 = _ta
|
|
|
11153
11153
|
var CloseIcon = styled(SvgClose)(_templateObject30 || (_templateObject30 = _taggedTemplateLiteralLoose(["\n position: absolute;\n top: 13px;\n right: 13px;\n cursor: pointer;\n padding: 15px;\n box-sizing: content-box;\n color: ", ";\n"])), function (props) {
|
|
11154
11154
|
return props.color;
|
|
11155
11155
|
});
|
|
11156
|
-
var ClearTypedText = styled(CloseIcon)(_templateObject31 || (_templateObject31 = _taggedTemplateLiteralLoose(["\n position: absolute;\n top: 8px;\n right: 10px;\n cursor: pointer;\n padding: 4px;\n"])))
|
|
11156
|
+
var ClearTypedText = styled(CloseIcon)(_templateObject31 || (_templateObject31 = _taggedTemplateLiteralLoose(["\n position: absolute;\n top: 8px;\n right: 10px;\n cursor: pointer;\n padding: 4px;\n color: ", ";\n"])), function (props) {
|
|
11157
|
+
return props.color;
|
|
11158
|
+
});
|
|
11157
11159
|
var StyledSearchSvg = styled(SvgSearch)(_templateObject32 || (_templateObject32 = _taggedTemplateLiteralLoose(["\n cursor: pointer;\n position: absolute;\n top: 12px;\n left: ", ";\n"])), function (props) {
|
|
11158
11160
|
return props.left || '14px';
|
|
11159
11161
|
});
|
|
@@ -19580,7 +19582,8 @@ var ChannelSearch = function ChannelSearch(_ref) {
|
|
|
19580
19582
|
var _useColor = useColors(),
|
|
19581
19583
|
textPrimary = _useColor[THEME_COLORS.TEXT_PRIMARY],
|
|
19582
19584
|
surface1Background = _useColor[THEME_COLORS.SURFACE_1],
|
|
19583
|
-
textSecondary = _useColor[THEME_COLORS.TEXT_SECONDARY]
|
|
19585
|
+
textSecondary = _useColor[THEME_COLORS.TEXT_SECONDARY],
|
|
19586
|
+
iconPrimary = _useColor[THEME_COLORS.ICON_PRIMARY];
|
|
19584
19587
|
return /*#__PURE__*/React__default.createElement(SearchInputContainer, {
|
|
19585
19588
|
inline: inline,
|
|
19586
19589
|
borderColor: surface1Background
|
|
@@ -19597,7 +19600,8 @@ var ChannelSearch = function ChannelSearch(_ref) {
|
|
|
19597
19600
|
placeholder: 'Search for channels',
|
|
19598
19601
|
fontSize: fontSize
|
|
19599
19602
|
}), searchValue && /*#__PURE__*/React__default.createElement(ClearTypedText, {
|
|
19600
|
-
onClick: getMyChannels
|
|
19603
|
+
onClick: getMyChannels,
|
|
19604
|
+
color: iconPrimary
|
|
19601
19605
|
}));
|
|
19602
19606
|
};
|
|
19603
19607
|
|
|
@@ -27823,6 +27827,7 @@ var VideoCont = styled.div(_templateObject11$3 || (_templateObject11$3 = _tagged
|
|
|
27823
27827
|
|
|
27824
27828
|
var _templateObject$v, _templateObject2$r, _templateObject3$l, _templateObject4$i;
|
|
27825
27829
|
var RepliedMessage = function RepliedMessage(_ref) {
|
|
27830
|
+
var _message$parentMessag;
|
|
27826
27831
|
var message = _ref.message,
|
|
27827
27832
|
theme = _ref.theme,
|
|
27828
27833
|
handleScrollToRepliedMessage = _ref.handleScrollToRepliedMessage,
|
|
@@ -27856,6 +27861,12 @@ var RepliedMessage = function RepliedMessage(_ref) {
|
|
|
27856
27861
|
var parentNotLinkAttachment = message.parentMessage && message.parentMessage.attachments && message.parentMessage.attachments.some(function (a) {
|
|
27857
27862
|
return a.type !== attachmentTypes.link;
|
|
27858
27863
|
});
|
|
27864
|
+
var attachementsLength = useMemo(function () {
|
|
27865
|
+
if (message.parentMessage.attachments && !!message.parentMessage.attachments.length && message.parentMessage.attachments[0].type !== attachmentTypes.voice && parentNotLinkAttachment) {
|
|
27866
|
+
return message.parentMessage.attachments.length;
|
|
27867
|
+
}
|
|
27868
|
+
return 0;
|
|
27869
|
+
}, [message.parentMessage.attachments, parentNotLinkAttachment, (_message$parentMessag = message.parentMessage.attachments[0]) === null || _message$parentMessag === void 0 ? void 0 : _message$parentMessag.type, message.parentMessage.attachments.length]);
|
|
27859
27870
|
return /*#__PURE__*/React__default.createElement(ReplyMessageContainer, {
|
|
27860
27871
|
withSenderName: showMessageSenderName,
|
|
27861
27872
|
withBody: !!message.body,
|
|
@@ -27865,7 +27876,7 @@ var RepliedMessage = function RepliedMessage(_ref) {
|
|
|
27865
27876
|
onClick: function onClick() {
|
|
27866
27877
|
return handleScrollToRepliedMessage && !selectionIsActive && handleScrollToRepliedMessage(message.parentMessage.id);
|
|
27867
27878
|
}
|
|
27868
|
-
},
|
|
27879
|
+
}, attachementsLength > 0 && message.parentMessage.attachments.map(function (attachment, index) {
|
|
27869
27880
|
return /*#__PURE__*/React__default.createElement(Attachment$1, {
|
|
27870
27881
|
key: attachment.tid || attachment.url,
|
|
27871
27882
|
backgroundColor: message.incoming ? incomingRepliedMessageBackground || bubbleIncomingX : ownRepliedMessageBackground || bubbleOutgoingX,
|
|
@@ -27885,7 +27896,8 @@ var RepliedMessage = function RepliedMessage(_ref) {
|
|
|
27885
27896
|
videoAttachmentMaxHeight: videoAttachmentMaxHeight
|
|
27886
27897
|
});
|
|
27887
27898
|
}), /*#__PURE__*/React__default.createElement(ReplyMessageBody, {
|
|
27888
|
-
rtlDirection: ownMessageOnRightSide && !message.incoming
|
|
27899
|
+
rtlDirection: ownMessageOnRightSide && !message.incoming,
|
|
27900
|
+
maxWidth: "calc(100% - " + (attachementsLength * 40 + 10) + "px)"
|
|
27889
27901
|
}, /*#__PURE__*/React__default.createElement(MessageOwner, {
|
|
27890
27902
|
className: 'reply-message-owner',
|
|
27891
27903
|
color: accentColor,
|
|
@@ -27922,8 +27934,10 @@ var ReplyMessageContainer = styled.div(_templateObject$v || (_templateObject$v =
|
|
|
27922
27934
|
}, function (props) {
|
|
27923
27935
|
return !props.withSenderName && props.withAttachments && '8px';
|
|
27924
27936
|
});
|
|
27925
|
-
var ReplyMessageBody = styled.div(_templateObject2$r || (_templateObject2$r = _taggedTemplateLiteralLoose(["\n margin-top: auto;\n margin-bottom: auto;\n direction: ", ";\n max-width:
|
|
27937
|
+
var ReplyMessageBody = styled.div(_templateObject2$r || (_templateObject2$r = _taggedTemplateLiteralLoose(["\n margin-top: auto;\n margin-bottom: auto;\n direction: ", ";\n max-width: ", ";\n"])), function (props) {
|
|
27926
27938
|
return props.rtlDirection ? 'initial' : '';
|
|
27939
|
+
}, function (props) {
|
|
27940
|
+
return props.maxWidth || '100%';
|
|
27927
27941
|
});
|
|
27928
27942
|
var MessageStatusDeleted = styled.span(_templateObject3$l || (_templateObject3$l = _taggedTemplateLiteralLoose(["\n color: ", ";\n font-size: ", ";\n font-style: italic;\n"])), function (props) {
|
|
27929
27943
|
return props.color;
|