@veltdev/react 1.0.51 → 1.0.53

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/index.js CHANGED
@@ -94,7 +94,7 @@ var loadVelt = function (callback, version, staging) {
94
94
  }
95
95
  };
96
96
 
97
- var VELT_SDK_VERSION = '1.0.60';
97
+ var VELT_SDK_VERSION = '1.0.63';
98
98
 
99
99
  var SnippylyProvider = function (props) {
100
100
  var apiKey = props.apiKey, user = props.user, config = props.config, documentId = props.documentId, language = props.language, translations = props.translations, autoTranslation = props.autoTranslation, onClientLoad = props.onClientLoad, children = props.children;
@@ -178,15 +178,12 @@ var SnippylyCommentBubble = function (props) {
178
178
  };
179
179
 
180
180
  var SnippylyComments = function (props) {
181
- var autoCategorize = props.autoCategorize, streamViewContainerId = props.streamViewContainerId, pinHighlighterClass = props.pinHighlighterClass, textHighlighterClass = props.textHighlighterClass, signIn = props.signIn, onSignIn = props.onSignIn, onUpgrade = props.onUpgrade, textMode = props.textMode, popoverMode = props.popoverMode, popoverTriangleComponent = props.popoverTriangleComponent, floatingCommentsMode = props.floatingCommentsMode, floatingCommentDialog = props.floatingCommentDialog, moderatorMode = props.moderatorMode, streamMode = props.streamMode, signInButton = props.signInButton, upgradeButton = props.upgradeButton, allowAttachments = props.allowAttachments, attachments = props.attachments, recordings = props.recordings, reactions = props.reactions, showDeviceInfo = props.showDeviceInfo, deviceInfo = props.deviceInfo, showCommentIndex = props.showCommentIndex, commentIndex = props.commentIndex, dialogOnHover = props.dialogOnHover, dialogOnTargetElementClick = props.dialogOnTargetElementClick, showPriority = props.showPriority, priority = props.priority, inboxMode = props.inboxMode, suggestionMode = props.suggestionMode, mobileMode = props.mobileMode, inlineCommentMode = props.inlineCommentMode, privateCommentMode = props.privateCommentMode, minimap = props.minimap, persistentCommentMode = props.persistentCommentMode, ghostComments = props.ghostComments, ghostCommentsMessage = props.ghostCommentsMessage, ghostCommentsIndicator = props.ghostCommentsIndicator, commentsOnDom = props.commentsOnDom, commentTool = props.commentTool, sidebarButtonOnCommentDialog = props.sidebarButtonOnCommentDialog, scrollToComponent = props.scrollToComponent, allowedElementIds = props.allowedElementIds, commentAdded = props.commentAdded, onCommentAdd = props.onCommentAdd, onCommentUpdate = props.onCommentUpdate, commentAccepted = props.commentAccepted, onCommentAccept = props.onCommentAccept, commentRejected = props.commentRejected, onCommentReject = props.onCommentReject, onSidebarButtonOnCommentDialogClick = props.onSidebarButtonOnCommentDialogClick, customStatuses = props.customStatuses, customStatus = props.customStatus, customPriorities = props.customPriorities, customPriority = props.customPriority, customCategories = props.customCategories, customCategory = props.customCategory, showStatus = props.showStatus, status = props.status, showResolveButton = props.showResolveButton, resolveButton = props.resolveButton, darkMode = props.darkMode, onCustomPinInject = props.onCustomPinInject, children = props.children;
181
+ var autoCategorize = props.autoCategorize, streamViewContainerId = props.streamViewContainerId, onSignIn = props.onSignIn, onUpgrade = props.onUpgrade, textMode = props.textMode, popoverMode = props.popoverMode, popoverTriangleComponent = props.popoverTriangleComponent, floatingCommentDialog = props.floatingCommentDialog, moderatorMode = props.moderatorMode, streamMode = props.streamMode, signInButton = props.signInButton, upgradeButton = props.upgradeButton, attachments = props.attachments, recordings = props.recordings, reactions = props.reactions, deviceInfo = props.deviceInfo, commentIndex = props.commentIndex, dialogOnHover = props.dialogOnHover, dialogOnTargetElementClick = props.dialogOnTargetElementClick, priority = props.priority, inboxMode = props.inboxMode, suggestionMode = props.suggestionMode, mobileMode = props.mobileMode, inlineCommentMode = props.inlineCommentMode, privateCommentMode = props.privateCommentMode, minimap = props.minimap, persistentCommentMode = props.persistentCommentMode, ghostComments = props.ghostComments, ghostCommentsIndicator = props.ghostCommentsIndicator, commentsOnDom = props.commentsOnDom, commentTool = props.commentTool, sidebarButtonOnCommentDialog = props.sidebarButtonOnCommentDialog, scrollToComponent = props.scrollToComponent, userMentions = props.userMentions, allowedElementIds = props.allowedElementIds, onCommentAdd = props.onCommentAdd, onCommentUpdate = props.onCommentUpdate, onCommentAccept = props.onCommentAccept, onCommentReject = props.onCommentReject, onSidebarButtonOnCommentDialogClick = props.onSidebarButtonOnCommentDialogClick, customStatus = props.customStatus, customPriority = props.customPriority, customCategory = props.customCategory, status = props.status, resolveButton = props.resolveButton, darkMode = props.darkMode, onCustomPinInject = props.onCustomPinInject, children = props.children;
182
182
  var ref = React.useRef();
183
183
  React.useEffect(function () {
184
184
  if (ref.current) {
185
185
  var element = ref.current;
186
186
  element.addEventListener('onSignIn', function (event) {
187
- if (signIn) {
188
- signIn(event === null || event === void 0 ? void 0 : event.detail);
189
- }
190
187
  if (onSignIn) {
191
188
  onSignIn(event === null || event === void 0 ? void 0 : event.detail);
192
189
  }
@@ -197,9 +194,6 @@ var SnippylyComments = function (props) {
197
194
  }
198
195
  });
199
196
  element.addEventListener('onCommentAdd', function (event) {
200
- if (commentAdded) {
201
- commentAdded(event === null || event === void 0 ? void 0 : event.detail);
202
- }
203
197
  if (onCommentAdd) {
204
198
  onCommentAdd(event === null || event === void 0 ? void 0 : event.detail);
205
199
  }
@@ -210,17 +204,11 @@ var SnippylyComments = function (props) {
210
204
  }
211
205
  });
212
206
  element.addEventListener('onCommentAccept', function (event) {
213
- if (commentAccepted) {
214
- commentAccepted(event === null || event === void 0 ? void 0 : event.detail);
215
- }
216
207
  if (onCommentAccept) {
217
208
  onCommentAccept(event === null || event === void 0 ? void 0 : event.detail);
218
209
  }
219
210
  });
220
211
  element.addEventListener('onCommentReject', function (event) {
221
- if (commentRejected) {
222
- commentRejected(event === null || event === void 0 ? void 0 : event.detail);
223
- }
224
212
  if (onCommentReject) {
225
213
  onCommentReject(event === null || event === void 0 ? void 0 : event.detail);
226
214
  }
@@ -237,11 +225,11 @@ var SnippylyComments = function (props) {
237
225
  });
238
226
  }
239
227
  }, []);
240
- return (React__default["default"].createElement("velt-comments", { ref: ref, "auto-categorize": [true, false].includes(autoCategorize) ? (autoCategorize ? 'true' : 'false') : undefined, "data-stream-view-container-id": streamViewContainerId, "pin-highlighter-class": pinHighlighterClass, "text-highlighter-class": textHighlighterClass, "text-mode": [true, false].includes(textMode) ? (textMode ? 'true' : 'false') : undefined, "popover-mode": [true, false].includes(popoverMode) ? (popoverMode ? 'true' : 'false') : undefined, "popover-triangle-component": [true, false].includes(popoverTriangleComponent) ? (popoverTriangleComponent ? 'true' : 'false') : undefined, "floating-comments-mode": [true, false].includes(floatingCommentsMode) ? (floatingCommentsMode ? 'true' : 'false') : undefined, "floating-comment-dialog": [true, false].includes(floatingCommentDialog) ? (floatingCommentDialog ? 'true' : 'false') : undefined, "moderator-mode": [true, false].includes(moderatorMode) ? (moderatorMode ? 'true' : 'false') : undefined, "stream-mode": [true, false].includes(streamMode) ? (streamMode ? 'true' : 'false') : undefined, "sign-in-button": [true, false].includes(signInButton) ? (signInButton ? 'true' : 'false') : undefined, "upgrade-button": [true, false].includes(upgradeButton) ? (upgradeButton ? 'true' : 'false') : undefined, "allow-attachments": [true, false].includes(allowAttachments) ? (allowAttachments ? 'true' : 'false') : undefined, attachments: [true, false].includes(attachments) ? (attachments ? 'true' : 'false') : undefined, recordings: recordings, reactions: [true, false].includes(reactions) ? (reactions ? 'true' : 'false') : undefined, "show-device-info": [true, false].includes(showDeviceInfo) ? (showDeviceInfo ? 'true' : 'false') : undefined, "device-info": [true, false].includes(deviceInfo) ? (deviceInfo ? 'true' : 'false') : undefined, "show-comment-index": [true, false].includes(showCommentIndex) ? (showCommentIndex ? 'true' : 'false') : undefined, "comment-index": [true, false].includes(commentIndex) ? (commentIndex ? 'true' : 'false') : undefined, "dialog-on-hover": [true, false].includes(dialogOnHover) ? (dialogOnHover ? 'true' : 'false') : undefined, "dialog-on-target-element-click": [true, false].includes(dialogOnTargetElementClick) ? (dialogOnTargetElementClick ? 'true' : 'false') : undefined, "show-priority": [true, false].includes(showPriority) ? (showPriority ? 'true' : 'false') : undefined, priority: [true, false].includes(priority) ? (priority ? 'true' : 'false') : undefined, "show-status": [true, false].includes(showStatus) ? (showStatus ? 'true' : 'false') : undefined, status: [true, false].includes(status) ? (status ? 'true' : 'false') : undefined, "show-resolve-button": [true, false].includes(showResolveButton) ? (showResolveButton ? 'true' : 'false') : undefined, "resolve-button": [true, false].includes(resolveButton) ? (resolveButton ? 'true' : 'false') : undefined, "inbox-mode": [true, false].includes(inboxMode) ? (inboxMode ? 'true' : 'false') : undefined, "suggestion-mode": [true, false].includes(suggestionMode) ? (suggestionMode ? 'true' : 'false') : undefined, "mobile-mode": [true, false].includes(mobileMode) ? (mobileMode ? 'true' : 'false') : undefined, "inline-comment-mode": [true, false].includes(inlineCommentMode) ? (inlineCommentMode ? 'true' : 'false') : undefined, "private-comment-mode": [true, false].includes(privateCommentMode) ? (privateCommentMode ? 'true' : 'false') : undefined, minimap: [true, false].includes(minimap) ? (minimap ? 'true' : 'false') : undefined, "persistent-comment-mode": [true, false].includes(persistentCommentMode) ? (persistentCommentMode ? 'true' : 'false') : undefined, "ghost-comments": [true, false].includes(ghostComments) ? (ghostComments ? 'true' : 'false') : undefined, "ghost-comments-message": [true, false].includes(ghostCommentsMessage) ? (ghostCommentsMessage ? 'true' : 'false') : undefined, "ghost-comments-indicator": [true, false].includes(ghostCommentsIndicator) ? (ghostCommentsIndicator ? 'true' : 'false') : undefined, "comments-on-dom": [true, false].includes(commentsOnDom) ? (commentsOnDom ? 'true' : 'false') : undefined, "comment-tool": [true, false].includes(commentTool) ? (commentTool ? 'true' : 'false') : undefined, "sidebar-button-on-comment-dialog": [true, false].includes(sidebarButtonOnCommentDialog) ? (sidebarButtonOnCommentDialog ? 'true' : 'false') : undefined, "scroll-to-component": [true, false].includes(scrollToComponent) ? (scrollToComponent ? 'true' : 'false') : undefined, "allowed-element-ids": JSON.stringify(allowedElementIds), "custom-statuses": JSON.stringify(customStatuses), "custom-status": JSON.stringify(customStatus), "custom-priorities": JSON.stringify(customPriorities), "custom-priority": JSON.stringify(customPriority), "custom-categories": JSON.stringify(customCategories), "custom-category": JSON.stringify(customCategory), "dark-mode": [true, false].includes(darkMode) ? (darkMode ? 'true' : 'false') : undefined }, children));
228
+ return (React__default["default"].createElement("velt-comments", { ref: ref, "auto-categorize": [true, false].includes(autoCategorize) ? (autoCategorize ? 'true' : 'false') : undefined, "data-stream-view-container-id": streamViewContainerId, "text-mode": [true, false].includes(textMode) ? (textMode ? 'true' : 'false') : undefined, "popover-mode": [true, false].includes(popoverMode) ? (popoverMode ? 'true' : 'false') : undefined, "popover-triangle-component": [true, false].includes(popoverTriangleComponent) ? (popoverTriangleComponent ? 'true' : 'false') : undefined, "floating-comment-dialog": [true, false].includes(floatingCommentDialog) ? (floatingCommentDialog ? 'true' : 'false') : undefined, "moderator-mode": [true, false].includes(moderatorMode) ? (moderatorMode ? 'true' : 'false') : undefined, "stream-mode": [true, false].includes(streamMode) ? (streamMode ? 'true' : 'false') : undefined, "sign-in-button": [true, false].includes(signInButton) ? (signInButton ? 'true' : 'false') : undefined, "upgrade-button": [true, false].includes(upgradeButton) ? (upgradeButton ? 'true' : 'false') : undefined, attachments: [true, false].includes(attachments) ? (attachments ? 'true' : 'false') : undefined, recordings: recordings, reactions: [true, false].includes(reactions) ? (reactions ? 'true' : 'false') : undefined, "device-info": [true, false].includes(deviceInfo) ? (deviceInfo ? 'true' : 'false') : undefined, "comment-index": [true, false].includes(commentIndex) ? (commentIndex ? 'true' : 'false') : undefined, "dialog-on-hover": [true, false].includes(dialogOnHover) ? (dialogOnHover ? 'true' : 'false') : undefined, "dialog-on-target-element-click": [true, false].includes(dialogOnTargetElementClick) ? (dialogOnTargetElementClick ? 'true' : 'false') : undefined, priority: [true, false].includes(priority) ? (priority ? 'true' : 'false') : undefined, status: [true, false].includes(status) ? (status ? 'true' : 'false') : undefined, "resolve-button": [true, false].includes(resolveButton) ? (resolveButton ? 'true' : 'false') : undefined, "inbox-mode": [true, false].includes(inboxMode) ? (inboxMode ? 'true' : 'false') : undefined, "suggestion-mode": [true, false].includes(suggestionMode) ? (suggestionMode ? 'true' : 'false') : undefined, "mobile-mode": [true, false].includes(mobileMode) ? (mobileMode ? 'true' : 'false') : undefined, "inline-comment-mode": [true, false].includes(inlineCommentMode) ? (inlineCommentMode ? 'true' : 'false') : undefined, "private-comment-mode": [true, false].includes(privateCommentMode) ? (privateCommentMode ? 'true' : 'false') : undefined, minimap: [true, false].includes(minimap) ? (minimap ? 'true' : 'false') : undefined, "persistent-comment-mode": [true, false].includes(persistentCommentMode) ? (persistentCommentMode ? 'true' : 'false') : undefined, "ghost-comments": [true, false].includes(ghostComments) ? (ghostComments ? 'true' : 'false') : undefined, "ghost-comments-indicator": [true, false].includes(ghostCommentsIndicator) ? (ghostCommentsIndicator ? 'true' : 'false') : undefined, "comments-on-dom": [true, false].includes(commentsOnDom) ? (commentsOnDom ? 'true' : 'false') : undefined, "comment-tool": [true, false].includes(commentTool) ? (commentTool ? 'true' : 'false') : undefined, "sidebar-button-on-comment-dialog": [true, false].includes(sidebarButtonOnCommentDialog) ? (sidebarButtonOnCommentDialog ? 'true' : 'false') : undefined, "scroll-to-component": [true, false].includes(scrollToComponent) ? (scrollToComponent ? 'true' : 'false') : undefined, "user-mentions": [true, false].includes(userMentions) ? (userMentions ? 'true' : 'false') : undefined, "allowed-element-ids": JSON.stringify(allowedElementIds), "custom-status": JSON.stringify(customStatus), "custom-priority": JSON.stringify(customPriority), "custom-category": JSON.stringify(customCategory), "dark-mode": [true, false].includes(darkMode) ? (darkMode ? 'true' : 'false') : undefined }, children));
241
229
  };
242
230
 
243
231
  var SnippylyCommentsSidebar = function (props) {
244
- var embedMode = props.embedMode, enableUrlNavigation = props.enableUrlNavigation, urlNavigation = props.urlNavigation, pageMode = props.pageMode, openSidebar = props.openSidebar, onSidebarOpen = props.onSidebarOpen, onSidebarCommentClick = props.onSidebarCommentClick, onCommentClick = props.onCommentClick;
232
+ var embedMode = props.embedMode, enableUrlNavigation = props.enableUrlNavigation, urlNavigation = props.urlNavigation, pageMode = props.pageMode, currentLocationSuffix = props.currentLocationSuffix, filterConfig = props.filterConfig, groupConfig = props.groupConfig, filters = props.filters, openSidebar = props.openSidebar, onSidebarOpen = props.onSidebarOpen, onSidebarCommentClick = props.onSidebarCommentClick, onCommentClick = props.onCommentClick;
245
233
  var ref = React.useRef();
246
234
  React.useEffect(function () {
247
235
  if (ref.current) {
@@ -264,7 +252,7 @@ var SnippylyCommentsSidebar = function (props) {
264
252
  });
265
253
  }
266
254
  }, []);
267
- return (React__default["default"].createElement("velt-comments-sidebar", { ref: ref, "embed-mode": [true, false].includes(embedMode) ? (embedMode ? 'true' : 'false') : undefined, "enable-url-navigation": [true, false].includes(enableUrlNavigation) ? (enableUrlNavigation ? 'true' : 'false') : undefined, "url-navigation": [true, false].includes(urlNavigation) ? (urlNavigation ? 'true' : 'false') : undefined, "page-mode": [true, false].includes(pageMode) ? (pageMode ? 'true' : 'false') : undefined }));
255
+ return (React__default["default"].createElement("velt-comments-sidebar", { ref: ref, "embed-mode": [true, false].includes(embedMode) ? (embedMode ? 'true' : 'false') : undefined, "enable-url-navigation": [true, false].includes(enableUrlNavigation) ? (enableUrlNavigation ? 'true' : 'false') : undefined, "url-navigation": [true, false].includes(urlNavigation) ? (urlNavigation ? 'true' : 'false') : undefined, "page-mode": [true, false].includes(pageMode) ? (pageMode ? 'true' : 'false') : undefined, "current-location-suffix": [true, false].includes(currentLocationSuffix) ? (currentLocationSuffix ? 'true' : 'false') : undefined, "filter-config": filterConfig ? JSON.stringify(filterConfig) : undefined, "group-config": groupConfig ? JSON.stringify(groupConfig) : undefined, filters: filters ? JSON.stringify(filters) : undefined }));
268
256
  };
269
257
 
270
258
  var SnippylyCommentTool = function (props) {