@azure/communication-react 1.5.1-alpha-202304190014 → 1.5.1-alpha-202304210012

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.
@@ -162,7 +162,7 @@ const _toCommunicationIdentifier = (id) => {
162
162
  // Copyright (c) Microsoft Corporation.
163
163
  // Licensed under the MIT license.
164
164
  // GENERATED FILE. DO NOT EDIT MANUALLY.
165
- var telemetryVersion = '1.5.1-alpha-202304190014';
165
+ var telemetryVersion = '1.5.1-alpha-202304210012';
166
166
 
167
167
  // Copyright (c) Microsoft Corporation.
168
168
  /**
@@ -7146,6 +7146,15 @@ const MessageContentWithLiveAria = (props) => {
7146
7146
  };
7147
7147
  const MessageContentAsRichTextHTML = (props) => {
7148
7148
  const liveAuthor = _formatString(props.strings.liveAuthorIntro, { author: `${props.message.senderDisplayName}` });
7149
+ /* @conditional-compile-remove(teams-inline-images) */
7150
+ React.useEffect(() => {
7151
+ var _a;
7152
+ (_a = props.message.attachedFilesMetadata) === null || _a === void 0 ? void 0 : _a.map((fileMetadata) => {
7153
+ if (props.onFetchAttachment && props.attachmentsMap && props.attachmentsMap[fileMetadata.id] === undefined) {
7154
+ props.onFetchAttachment(fileMetadata);
7155
+ }
7156
+ });
7157
+ }, [props]);
7149
7158
  return (React__default['default'].createElement(MessageContentWithLiveAria, { message: props.message, liveMessage: `${props.message.mine ? '' : liveAuthor} ${extractContent(props.message.content || '')}`, ariaLabel: messageContentAriaText(props), content: processHtmlToReact(props) }));
7150
7159
  };
7151
7160
  const MessageContentAsText = (props) => {
@@ -7210,20 +7219,9 @@ const processHtmlToReact = (props) => {
7210
7219
  ((_a = props.message.attachedFilesMetadata) === null || _a === void 0 ? void 0 : _a.find((f) => f.id === node.attribs.id)));
7211
7220
  },
7212
7221
  processNode: (node, children, index) => {
7213
- var _a;
7214
7222
  // logic to check id in map/list
7215
- const fileMetadata = (_a = props.message.attachedFilesMetadata) === null || _a === void 0 ? void 0 : _a.find((f) => f.id === node.attribs.id);
7216
- // if in cache, early return
7217
7223
  if (props.attachmentsMap && node.attribs.id in props.attachmentsMap) {
7218
7224
  node.attribs = Object.assign(Object.assign({}, node.attribs), { src: props.attachmentsMap[node.attribs.id] });
7219
- return processNodeDefinitions.processDefaultNode(node, children, index);
7220
- }
7221
- // not yet in cache
7222
- if (fileMetadata && props.onFetchAttachment && props.attachmentsMap) {
7223
- props.onFetchAttachment(fileMetadata);
7224
- if (node.attribs.id in props.attachmentsMap) {
7225
- node.attribs = Object.assign(Object.assign({}, node.attribs), { src: props.attachmentsMap[node.attribs.id] });
7226
- }
7227
7225
  }
7228
7226
  return processNodeDefinitions.processDefaultNode(node, children, index);
7229
7227
  }
@@ -7839,6 +7837,7 @@ const MessageThread = (props) => {
7839
7837
  if (!onFetchAttachments || attachment.id in inlineAttachments) {
7840
7838
  return;
7841
7839
  }
7840
+ setInlineAttachments((prev) => (Object.assign(Object.assign({}, prev), { [attachment.id]: '' })));
7842
7841
  const attachmentDownloadResult = yield onFetchAttachments(attachment);
7843
7842
  if (attachmentDownloadResult[0]) {
7844
7843
  setInlineAttachments((prev) => (Object.assign(Object.assign({}, prev), { [attachment.id]: attachmentDownloadResult[0].blobUrl })));
@@ -13942,6 +13941,22 @@ const _VideoBackgroundEffectsPicker = (props) => {
13942
13941
  })));
13943
13942
  };
13944
13943
 
13944
+ // Copyright (c) Microsoft Corporation.
13945
+ // Licensed under the MIT license.
13946
+ /**
13947
+ * @private
13948
+ */
13949
+ const scrollbarStyles = {
13950
+ '::-webkit-scrollbar, *::-webkit-scrollbar': {
13951
+ width: '0.3rem',
13952
+ height: '0.3rem'
13953
+ },
13954
+ '::-webkit-scrollbar-thumb, *::-webkit-scrollbar-thumb': {
13955
+ borderRadius: '10px',
13956
+ background: 'rgba(150, 150, 150)'
13957
+ }
13958
+ };
13959
+
13945
13960
  // Copyright (c) Microsoft Corporation.
13946
13961
  /**
13947
13962
  * @private
@@ -13976,11 +13991,7 @@ const captionContainerClassName = react.mergeStyles({
13976
13991
  /**
13977
13992
  * @private
13978
13993
  */
13979
- const captionsBannerClassName = react.mergeStyles({
13980
- height: _pxToRem(100),
13981
- overflowY: 'auto',
13982
- overflowX: 'hidden'
13983
- });
13994
+ const captionsBannerClassName = react.mergeStyles(Object.assign({ height: _pxToRem(100), overflowY: 'auto', overflowX: 'hidden' }, scrollbarStyles));
13984
13995
  /**
13985
13996
  * @private
13986
13997
  */
@@ -14158,7 +14169,7 @@ const buttonStyles = (theme) => {
14158
14169
  * @private
14159
14170
  */
14160
14171
  const dropdownStyles = {
14161
- callout: { height: _pxToRem(300), overflow: 'auto' }
14172
+ callout: Object.assign({ height: _pxToRem(300), overflow: 'auto' }, scrollbarStyles)
14162
14173
  };
14163
14174
 
14164
14175
  var __awaiter$q = (window && window.__awaiter) || function (thisArg, _arguments, P, generator) {