@atlaskit/smart-card 30.3.0 → 30.3.2

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.
Files changed (56) hide show
  1. package/CHANGELOG.md +18 -0
  2. package/dist/cjs/state/analytics/useSmartLinkAnalytics.js +146 -216
  3. package/dist/cjs/utils/analytics/analytics.js +78 -140
  4. package/dist/cjs/utils/analytics/index.js +0 -6
  5. package/dist/cjs/view/BlockCard/components/Name.js +1 -3
  6. package/dist/cjs/view/BlockCard/views/ResolvingView.js +1 -2
  7. package/dist/cjs/view/CardWithUrl/component.js +14 -41
  8. package/dist/cjs/view/EmbedCard/components/styled.js +4 -11
  9. package/dist/cjs/view/EmbedCard/views/ErroredView.js +2 -2
  10. package/dist/cjs/view/EmbedCard/views/unresolved-view/index.js +1 -1
  11. package/dist/cjs/view/EmbedModal/components/link-info/styled.js +2 -3
  12. package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +1 -6
  13. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +1 -4
  14. package/dist/cjs/view/FlexibleCard/components/elements/link/index.js +1 -1
  15. package/dist/cjs/view/LinkUrl/index.js +1 -1
  16. package/dist/es2019/state/analytics/useSmartLinkAnalytics.js +1 -69
  17. package/dist/es2019/utils/analytics/analytics.js +1 -63
  18. package/dist/es2019/utils/analytics/index.js +1 -1
  19. package/dist/es2019/view/BlockCard/components/Name.js +1 -3
  20. package/dist/es2019/view/BlockCard/views/ResolvingView.js +1 -2
  21. package/dist/es2019/view/CardWithUrl/component.js +14 -41
  22. package/dist/es2019/view/EmbedCard/components/styled.js +4 -11
  23. package/dist/es2019/view/EmbedCard/views/ErroredView.js +2 -2
  24. package/dist/es2019/view/EmbedCard/views/unresolved-view/index.js +1 -1
  25. package/dist/es2019/view/EmbedModal/components/link-info/styled.js +2 -3
  26. package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +1 -6
  27. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +1 -4
  28. package/dist/es2019/view/FlexibleCard/components/elements/link/index.js +1 -1
  29. package/dist/es2019/view/LinkUrl/index.js +1 -1
  30. package/dist/esm/state/analytics/useSmartLinkAnalytics.js +147 -217
  31. package/dist/esm/utils/analytics/analytics.js +77 -139
  32. package/dist/esm/utils/analytics/index.js +1 -1
  33. package/dist/esm/view/BlockCard/components/Name.js +1 -3
  34. package/dist/esm/view/BlockCard/views/ResolvingView.js +1 -2
  35. package/dist/esm/view/CardWithUrl/component.js +14 -41
  36. package/dist/esm/view/EmbedCard/components/styled.js +4 -11
  37. package/dist/esm/view/EmbedCard/views/ErroredView.js +2 -2
  38. package/dist/esm/view/EmbedCard/views/unresolved-view/index.js +1 -1
  39. package/dist/esm/view/EmbedModal/components/link-info/styled.js +2 -3
  40. package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +1 -6
  41. package/dist/esm/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +1 -4
  42. package/dist/esm/view/FlexibleCard/components/elements/link/index.js +1 -1
  43. package/dist/esm/view/LinkUrl/index.js +1 -1
  44. package/dist/types/state/analytics/useSmartLinkAnalytics.d.ts +1 -29
  45. package/dist/types/state/hooks/useSmartLink.d.ts +0 -2
  46. package/dist/types/utils/analytics/analytics.d.ts +1 -9
  47. package/dist/types/utils/analytics/index.d.ts +1 -1
  48. package/dist/types/utils/analytics/types.d.ts +0 -12
  49. package/dist/types/utils/mocks.d.ts +0 -2
  50. package/dist/types-ts4.5/state/analytics/useSmartLinkAnalytics.d.ts +1 -29
  51. package/dist/types-ts4.5/state/hooks/useSmartLink.d.ts +0 -2
  52. package/dist/types-ts4.5/utils/analytics/analytics.d.ts +1 -9
  53. package/dist/types-ts4.5/utils/analytics/index.d.ts +1 -1
  54. package/dist/types-ts4.5/utils/analytics/types.d.ts +0 -12
  55. package/dist/types-ts4.5/utils/mocks.d.ts +0 -2
  56. package/package.json +3 -6
@@ -6,7 +6,7 @@ import { useMemo } from 'react';
6
6
  import { useSmartLinkContext } from '@atlaskit/link-provider';
7
7
  import { getUrl } from '@atlaskit/linking-common';
8
8
  import { chunkloadFailedEvent as _chunkloadFailedEvent, connectFailedEvent as _connectFailedEvent, connectSucceededEvent as _connectSucceededEvent, context, instrumentEvent, invokeFailedEvent as _invokeFailedEvent, invokeSucceededEvent as _invokeSucceededEvent, screenAuthPopupEvent, trackAppAccountAuthStarted, trackAppAccountConnected, uiActionClickedEvent, uiAuthAlternateAccountEvent, uiAuthEvent, uiCardClickedEvent, uiClosedAuthEvent, uiHoverCardDismissedEvent, uiHoverCardOpenLinkClickedEvent, uiHoverCardViewedEvent, uiLearnMoreLinkClickedEvent, uiRenderFailedEvent, uiRenderSuccessEvent, uiSmartLinkStatusListItemButtonClicked, uiSmartLinkStatusLozengeButtonClicked, uiSmartLinkStatusOpenPreviewButtonClicked } from '../../utils/analytics';
9
- import { trackHoverCardResolutionStarted, trackSmartLinkQuickActionFailed, trackSmartLinkQuickActionStarted, trackSmartLinkQuickActionSuccess, uiIframeDwelledEvent, uiIframeFocusedEvent, uiServerActionClicked } from '../../utils/analytics/analytics';
9
+ import { trackHoverCardResolutionStarted, trackSmartLinkQuickActionFailed, trackSmartLinkQuickActionStarted, trackSmartLinkQuickActionSuccess, uiServerActionClicked } from '../../utils/analytics/analytics';
10
10
  import { getDefinitionId, getExtensionKey, getProduct, getResourceType, getStatusDetails, getSubproduct } from '../helpers';
11
11
  import { failUfoExperience, startUfoExperience, succeedUfoExperience } from './ufoExperiences';
12
12
  import { useDispatchAnalytics } from './useDispatchAnalytics';
@@ -168,94 +168,24 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
168
168
  }), commonAttributes));
169
169
  },
170
170
  /**
171
- * This fires an event that represents when a user dwells their cursor on a Smart Link's iframe.
171
+ * This fires an event that represents when a user clicks on a Smart Link action.
172
+ * Note: This also starts the UFO smart-link-action-invocation experience.
172
173
  * @param id The unique ID for this Smart Link.
173
- * @param display Whether the card was an Inline, Block, Embed or Flexible UI.
174
- * @param status What status the Smart Link is currently in (e.g. resolved, unresolved)
175
- * @param definitionId The definitionId of the Smart Link resolver invoked.
176
174
  * @param extensionKey The extensionKey of the Smart Link resovler invoked.
177
- * @param location Where the Smart Link is currently rendered.
178
- * @param destinationProduct The product the Smart Link is linked to.
179
- * @param dwellTime Total seconds that the user has dwelled on this iframe
180
- * @param dwellPercentVisible Percentage element was visible at end of dwell
175
+ * @param actionType The type of the action that was clicked, e.g. PreviewAction
176
+ * @param display Whether the card was an Inline, Block, Embed or Flexible UI.
181
177
  * @returns
182
- * @deprecated
183
178
  */
184
- iframeDwelledEvent: function iframeDwelledEvent(_ref4) {
179
+ actionClickedEvent: function actionClickedEvent(_ref4) {
185
180
  var id = _ref4.id,
181
+ actionType = _ref4.actionType,
186
182
  display = _ref4.display,
187
- status = _ref4.status,
183
+ overrideExtensionKey = _ref4.extensionKey,
188
184
  definitionId = _ref4.definitionId,
189
- extensionKey = _ref4.extensionKey,
190
- location = _ref4.location,
185
+ resourceType = _ref4.resourceType,
191
186
  destinationProduct = _ref4.destinationProduct,
192
187
  destinationSubproduct = _ref4.destinationSubproduct,
193
- dwellTime = _ref4.dwellTime,
194
- dwellPercentVisible = _ref4.dwellPercentVisible;
195
- return dispatchAnalytics(applyCommonAttributes(uiIframeDwelledEvent({
196
- id: id,
197
- display: display,
198
- status: status,
199
- definitionId: definitionId,
200
- extensionKey: extensionKey,
201
- location: location,
202
- destinationProduct: destinationProduct,
203
- destinationSubproduct: destinationSubproduct,
204
- dwellTime: dwellTime,
205
- dwellPercentVisible: dwellPercentVisible
206
- }), commonAttributes));
207
- },
208
- /**
209
- * This fires an event that represents when a user clicks or tabs into a Smart Link's iframe.
210
- * @param id The unique ID for this Smart Link.
211
- * @param display Whether the card was an Inline, Block, Embed or Flexible UI.
212
- * @param status What status the Smart Link is currently in (e.g. resolved, unresolved)
213
- * @param definitionId The definitionId of the Smart Link resolver invoked.
214
- * @param extensionKey The extensionKey of the Smart Link resovler invoked.
215
- * @param location Where the Smart Link is currently rendered.
216
- * @param destinationProduct The product the Smart Link is linked to.
217
- * @returns
218
- * @deprecated
219
- */
220
- iframeFocusedEvent: function iframeFocusedEvent(_ref5) {
221
- var id = _ref5.id,
222
- display = _ref5.display,
223
- status = _ref5.status,
224
- definitionId = _ref5.definitionId,
225
- extensionKey = _ref5.extensionKey,
226
- location = _ref5.location,
227
- destinationProduct = _ref5.destinationProduct,
228
- destinationSubproduct = _ref5.destinationSubproduct;
229
- return dispatchAnalytics(applyCommonAttributes(uiIframeFocusedEvent({
230
- id: id,
231
- display: display,
232
- status: status,
233
- definitionId: definitionId,
234
- extensionKey: extensionKey,
235
- location: location,
236
- destinationProduct: destinationProduct,
237
- destinationSubproduct: destinationSubproduct
238
- }), commonAttributes));
239
- },
240
- /**
241
- * This fires an event that represents when a user clicks on a Smart Link action.
242
- * Note: This also starts the UFO smart-link-action-invocation experience.
243
- * @param id The unique ID for this Smart Link.
244
- * @param extensionKey The extensionKey of the Smart Link resovler invoked.
245
- * @param actionType The type of the action that was clicked, e.g. PreviewAction
246
- * @param display Whether the card was an Inline, Block, Embed or Flexible UI.
247
- * @returns
248
- */
249
- actionClickedEvent: function actionClickedEvent(_ref6) {
250
- var id = _ref6.id,
251
- actionType = _ref6.actionType,
252
- display = _ref6.display,
253
- overrideExtensionKey = _ref6.extensionKey,
254
- definitionId = _ref6.definitionId,
255
- resourceType = _ref6.resourceType,
256
- destinationProduct = _ref6.destinationProduct,
257
- destinationSubproduct = _ref6.destinationSubproduct,
258
- location = _ref6.location;
188
+ location = _ref4.location;
259
189
  var extensionKey = overrideExtensionKey !== null && overrideExtensionKey !== void 0 ? overrideExtensionKey : extractedExtensionKey;
260
190
  dispatchAnalytics(applyCommonAttributes(uiActionClickedEvent({
261
191
  id: id !== null && id !== void 0 ? id : defaultId,
@@ -277,14 +207,14 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
277
207
  * @param extensionKey The extensionKey of the Smart Link resovler invoked.
278
208
  * @param previewInvokeMethod How the preview was triggered.
279
209
  */
280
- hoverCardOpenLinkClickedEvent: function hoverCardOpenLinkClickedEvent(_ref7) {
281
- var previewDisplay = _ref7.previewDisplay,
282
- definitionId = _ref7.definitionId,
283
- extensionKey = _ref7.extensionKey,
284
- destinationProduct = _ref7.destinationProduct,
285
- destinationSubproduct = _ref7.destinationSubproduct,
286
- location = _ref7.location,
287
- previewInvokeMethod = _ref7.previewInvokeMethod;
210
+ hoverCardOpenLinkClickedEvent: function hoverCardOpenLinkClickedEvent(_ref5) {
211
+ var previewDisplay = _ref5.previewDisplay,
212
+ definitionId = _ref5.definitionId,
213
+ extensionKey = _ref5.extensionKey,
214
+ destinationProduct = _ref5.destinationProduct,
215
+ destinationSubproduct = _ref5.destinationSubproduct,
216
+ location = _ref5.location,
217
+ previewInvokeMethod = _ref5.previewInvokeMethod;
288
218
  dispatchAnalytics(applyCommonAttributes(uiHoverCardOpenLinkClickedEvent({
289
219
  id: defaultId,
290
220
  previewDisplay: previewDisplay,
@@ -303,14 +233,14 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
303
233
  * @param extensionKey The extensionKey of the Smart Link resovler invoked.
304
234
  * @returns
305
235
  */
306
- closedAuthEvent: function closedAuthEvent(_ref8) {
307
- var display = _ref8.display,
308
- extensionKey = _ref8.extensionKey,
309
- definitionId = _ref8.definitionId,
310
- resourceType = _ref8.resourceType,
311
- destinationProduct = _ref8.destinationProduct,
312
- destinationSubproduct = _ref8.destinationSubproduct,
313
- location = _ref8.location;
236
+ closedAuthEvent: function closedAuthEvent(_ref6) {
237
+ var display = _ref6.display,
238
+ extensionKey = _ref6.extensionKey,
239
+ definitionId = _ref6.definitionId,
240
+ resourceType = _ref6.resourceType,
241
+ destinationProduct = _ref6.destinationProduct,
242
+ destinationSubproduct = _ref6.destinationSubproduct,
243
+ location = _ref6.location;
314
244
  return dispatchAnalytics(applyCommonAttributes(uiClosedAuthEvent({
315
245
  display: display,
316
246
  extensionKey: extensionKey,
@@ -343,18 +273,18 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
343
273
  * @param extensionKey The extensionKey of the Smart Link resovler invoked.
344
274
  * @param canBeDatasource An indicator that shows that a smart link can be converted to a datasource
345
275
  */
346
- renderSuccessEvent: function renderSuccessEvent(_ref9) {
347
- var display = _ref9.display,
348
- status = _ref9.status,
349
- id = _ref9.id,
350
- extensionKey = _ref9.extensionKey,
351
- definitionId = _ref9.definitionId,
352
- resourceType = _ref9.resourceType,
353
- destinationProduct = _ref9.destinationProduct,
354
- destinationSubproduct = _ref9.destinationSubproduct,
355
- location = _ref9.location,
356
- _ref9$canBeDatasource = _ref9.canBeDatasource,
357
- canBeDatasource = _ref9$canBeDatasource === void 0 ? false : _ref9$canBeDatasource;
276
+ renderSuccessEvent: function renderSuccessEvent(_ref7) {
277
+ var display = _ref7.display,
278
+ status = _ref7.status,
279
+ id = _ref7.id,
280
+ extensionKey = _ref7.extensionKey,
281
+ definitionId = _ref7.definitionId,
282
+ resourceType = _ref7.resourceType,
283
+ destinationProduct = _ref7.destinationProduct,
284
+ destinationSubproduct = _ref7.destinationSubproduct,
285
+ location = _ref7.location,
286
+ _ref7$canBeDatasource = _ref7.canBeDatasource,
287
+ canBeDatasource = _ref7$canBeDatasource === void 0 ? false : _ref7$canBeDatasource;
358
288
  var experienceId = id ? id : defaultId;
359
289
  succeedUfoExperience('smart-link-rendered', experienceId, {
360
290
  extensionKey: extensionKey,
@@ -384,17 +314,17 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
384
314
  * @param error: An error representing why the Smart Link render failed.
385
315
  * @param errorInfo: Additional details about the error including the stack trace.
386
316
  */
387
- renderFailedEvent: function renderFailedEvent(_ref10) {
388
- var display = _ref10.display,
389
- id = _ref10.id,
390
- error = _ref10.error,
391
- errorInfo = _ref10.errorInfo,
392
- extensionKey = _ref10.extensionKey,
393
- definitionId = _ref10.definitionId,
394
- resourceType = _ref10.resourceType,
395
- destinationProduct = _ref10.destinationProduct,
396
- destinationSubproduct = _ref10.destinationSubproduct,
397
- location = _ref10.location;
317
+ renderFailedEvent: function renderFailedEvent(_ref8) {
318
+ var display = _ref8.display,
319
+ id = _ref8.id,
320
+ error = _ref8.error,
321
+ errorInfo = _ref8.errorInfo,
322
+ extensionKey = _ref8.extensionKey,
323
+ definitionId = _ref8.definitionId,
324
+ resourceType = _ref8.resourceType,
325
+ destinationProduct = _ref8.destinationProduct,
326
+ destinationSubproduct = _ref8.destinationSubproduct,
327
+ location = _ref8.location;
398
328
  var experienceId = id ? id : defaultId;
399
329
  // Start and fail the smart-link-rendered experience. If it has already
400
330
  // been started nothing happens.
@@ -421,17 +351,17 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
421
351
  * @param previewInvokeMethod How the preview was triggered.
422
352
  * @returns
423
353
  */
424
- hoverCardViewedEvent: function hoverCardViewedEvent(_ref11) {
425
- var previewDisplay = _ref11.previewDisplay,
426
- previewInvokeMethod = _ref11.previewInvokeMethod,
427
- id = _ref11.id,
428
- extensionKey = _ref11.extensionKey,
429
- definitionId = _ref11.definitionId,
430
- resourceType = _ref11.resourceType,
431
- destinationProduct = _ref11.destinationProduct,
432
- destinationSubproduct = _ref11.destinationSubproduct,
433
- location = _ref11.location,
434
- status = _ref11.status;
354
+ hoverCardViewedEvent: function hoverCardViewedEvent(_ref9) {
355
+ var previewDisplay = _ref9.previewDisplay,
356
+ previewInvokeMethod = _ref9.previewInvokeMethod,
357
+ id = _ref9.id,
358
+ extensionKey = _ref9.extensionKey,
359
+ definitionId = _ref9.definitionId,
360
+ resourceType = _ref9.resourceType,
361
+ destinationProduct = _ref9.destinationProduct,
362
+ destinationSubproduct = _ref9.destinationSubproduct,
363
+ location = _ref9.location,
364
+ status = _ref9.status;
435
365
  return dispatchAnalytics(applyCommonAttributes(uiHoverCardViewedEvent({
436
366
  id: id,
437
367
  previewDisplay: previewDisplay,
@@ -454,18 +384,18 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
454
384
  * @param previewInvokeMethod How the preview was triggered.
455
385
  * @returns
456
386
  */
457
- hoverCardDismissedEvent: function hoverCardDismissedEvent(_ref12) {
458
- var id = _ref12.id,
459
- previewDisplay = _ref12.previewDisplay,
460
- hoverTime = _ref12.hoverTime,
461
- previewInvokeMethod = _ref12.previewInvokeMethod,
462
- extensionKey = _ref12.extensionKey,
463
- definitionId = _ref12.definitionId,
464
- resourceType = _ref12.resourceType,
465
- destinationProduct = _ref12.destinationProduct,
466
- destinationSubproduct = _ref12.destinationSubproduct,
467
- location = _ref12.location,
468
- status = _ref12.status;
387
+ hoverCardDismissedEvent: function hoverCardDismissedEvent(_ref10) {
388
+ var id = _ref10.id,
389
+ previewDisplay = _ref10.previewDisplay,
390
+ hoverTime = _ref10.hoverTime,
391
+ previewInvokeMethod = _ref10.previewInvokeMethod,
392
+ extensionKey = _ref10.extensionKey,
393
+ definitionId = _ref10.definitionId,
394
+ resourceType = _ref10.resourceType,
395
+ destinationProduct = _ref10.destinationProduct,
396
+ destinationSubproduct = _ref10.destinationSubproduct,
397
+ location = _ref10.location,
398
+ status = _ref10.status;
469
399
  return dispatchAnalytics(applyCommonAttributes(uiHoverCardDismissedEvent({
470
400
  previewDisplay: previewDisplay,
471
401
  id: id,
@@ -522,16 +452,16 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
522
452
  * @param actionType The type of action invoked, e.g. PreviewAction
523
453
  * @param display Whether the card was an Inline, Block, Embed or Flexible UI.
524
454
  */
525
- invokeSucceededEvent: function invokeSucceededEvent(_ref13) {
526
- var id = _ref13.id,
527
- actionType = _ref13.actionType,
528
- display = _ref13.display,
529
- extensionKey = _ref13.extensionKey,
530
- definitionId = _ref13.definitionId,
531
- resourceType = _ref13.resourceType,
532
- destinationProduct = _ref13.destinationProduct,
533
- destinationSubproduct = _ref13.destinationSubproduct,
534
- location = _ref13.location;
455
+ invokeSucceededEvent: function invokeSucceededEvent(_ref11) {
456
+ var id = _ref11.id,
457
+ actionType = _ref11.actionType,
458
+ display = _ref11.display,
459
+ extensionKey = _ref11.extensionKey,
460
+ definitionId = _ref11.definitionId,
461
+ resourceType = _ref11.resourceType,
462
+ destinationProduct = _ref11.destinationProduct,
463
+ destinationSubproduct = _ref11.destinationSubproduct,
464
+ location = _ref11.location;
535
465
  dispatchAnalytics(applyCommonAttributes(_invokeSucceededEvent({
536
466
  id: id !== null && id !== void 0 ? id : defaultId,
537
467
  actionType: actionType,
@@ -552,17 +482,17 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
552
482
  * @param display Whether the card was an Inline, Block, Embed or Flexible UI.
553
483
  * @param reason The reason the invocation failed.
554
484
  */
555
- invokeFailedEvent: function invokeFailedEvent(_ref14) {
556
- var id = _ref14.id,
557
- actionType = _ref14.actionType,
558
- display = _ref14.display,
559
- reason = _ref14.reason,
560
- extensionKey = _ref14.extensionKey,
561
- definitionId = _ref14.definitionId,
562
- resourceType = _ref14.resourceType,
563
- destinationProduct = _ref14.destinationProduct,
564
- destinationSubproduct = _ref14.destinationSubproduct,
565
- location = _ref14.location;
485
+ invokeFailedEvent: function invokeFailedEvent(_ref12) {
486
+ var id = _ref12.id,
487
+ actionType = _ref12.actionType,
488
+ display = _ref12.display,
489
+ reason = _ref12.reason,
490
+ extensionKey = _ref12.extensionKey,
491
+ definitionId = _ref12.definitionId,
492
+ resourceType = _ref12.resourceType,
493
+ destinationProduct = _ref12.destinationProduct,
494
+ destinationSubproduct = _ref12.destinationSubproduct,
495
+ location = _ref12.location;
566
496
  dispatchAnalytics(applyCommonAttributes(_invokeFailedEvent({
567
497
  id: id !== null && id !== void 0 ? id : defaultId,
568
498
  actionType: actionType,
@@ -582,14 +512,14 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
582
512
  * @param definitionId The definitionId of the Smart Link resolver invoked.
583
513
  * @param extensionKey The extensionKey of the Smart Link resovler invoked.
584
514
  */
585
- connectSucceededEvent: function connectSucceededEvent(_ref15) {
586
- var id = _ref15.id,
587
- extensionKey = _ref15.extensionKey,
588
- definitionId = _ref15.definitionId,
589
- resourceType = _ref15.resourceType,
590
- destinationProduct = _ref15.destinationProduct,
591
- destinationSubproduct = _ref15.destinationSubproduct,
592
- location = _ref15.location;
515
+ connectSucceededEvent: function connectSucceededEvent(_ref13) {
516
+ var id = _ref13.id,
517
+ extensionKey = _ref13.extensionKey,
518
+ definitionId = _ref13.definitionId,
519
+ resourceType = _ref13.resourceType,
520
+ destinationProduct = _ref13.destinationProduct,
521
+ destinationSubproduct = _ref13.destinationSubproduct,
522
+ location = _ref13.location;
593
523
  var experienceId = id ? id : defaultId;
594
524
  startUfoExperience('smart-link-authenticated', experienceId, {
595
525
  extensionKey: extensionKey,
@@ -612,15 +542,15 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
612
542
  * @param extensionKey The extensionKey of the Smart Link resovler invoked.
613
543
  * @param reason The reason why the Smart Link connect account failed.
614
544
  */
615
- connectFailedEvent: function connectFailedEvent(_ref16) {
616
- var id = _ref16.id,
617
- reason = _ref16.reason,
618
- extensionKey = _ref16.extensionKey,
619
- definitionId = _ref16.definitionId,
620
- resourceType = _ref16.resourceType,
621
- destinationProduct = _ref16.destinationProduct,
622
- destinationSubproduct = _ref16.destinationSubproduct,
623
- location = _ref16.location;
545
+ connectFailedEvent: function connectFailedEvent(_ref14) {
546
+ var id = _ref14.id,
547
+ reason = _ref14.reason,
548
+ extensionKey = _ref14.extensionKey,
549
+ definitionId = _ref14.definitionId,
550
+ resourceType = _ref14.resourceType,
551
+ destinationProduct = _ref14.destinationProduct,
552
+ destinationSubproduct = _ref14.destinationSubproduct,
553
+ location = _ref14.location;
624
554
  var experienceId = id ? id : defaultId;
625
555
  startUfoExperience('smart-link-authenticated', experienceId, {
626
556
  extensionKey: extensionKey,
@@ -646,16 +576,16 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
646
576
  * @param resourceType The type of resource that was invoked. This is provider specific (e.g. File, PullRequest).
647
577
  * @param error An error representing why the Smart Link request failed.
648
578
  */
649
- instrument: function instrument(_ref17) {
650
- var id = _ref17.id,
651
- status = _ref17.status,
652
- extensionKey = _ref17.extensionKey,
653
- definitionId = _ref17.definitionId,
654
- resourceType = _ref17.resourceType,
655
- destinationProduct = _ref17.destinationProduct,
656
- destinationSubproduct = _ref17.destinationSubproduct,
657
- location = _ref17.location,
658
- error = _ref17.error;
579
+ instrument: function instrument(_ref15) {
580
+ var id = _ref15.id,
581
+ status = _ref15.status,
582
+ extensionKey = _ref15.extensionKey,
583
+ definitionId = _ref15.definitionId,
584
+ resourceType = _ref15.resourceType,
585
+ destinationProduct = _ref15.destinationProduct,
586
+ destinationSubproduct = _ref15.destinationSubproduct,
587
+ location = _ref15.location,
588
+ error = _ref15.error;
659
589
  var event = instrumentEvent(_objectSpread(_objectSpread({}, commonAttributes), {}, {
660
590
  id: id,
661
591
  status: status,
@@ -678,16 +608,16 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
678
608
  * @param error: An error representing why the Smart Link render failed.
679
609
  * @param errorInfo: Additional details about the error including the stack trace.
680
610
  */
681
- chunkloadFailedEvent: function chunkloadFailedEvent(_ref18) {
682
- var display = _ref18.display,
683
- error = _ref18.error,
684
- errorInfo = _ref18.errorInfo,
685
- extensionKey = _ref18.extensionKey,
686
- definitionId = _ref18.definitionId,
687
- resourceType = _ref18.resourceType,
688
- destinationProduct = _ref18.destinationProduct,
689
- destinationSubproduct = _ref18.destinationSubproduct,
690
- location = _ref18.location;
611
+ chunkloadFailedEvent: function chunkloadFailedEvent(_ref16) {
612
+ var display = _ref16.display,
613
+ error = _ref16.error,
614
+ errorInfo = _ref16.errorInfo,
615
+ extensionKey = _ref16.extensionKey,
616
+ definitionId = _ref16.definitionId,
617
+ resourceType = _ref16.resourceType,
618
+ destinationProduct = _ref16.destinationProduct,
619
+ destinationSubproduct = _ref16.destinationSubproduct,
620
+ location = _ref16.location;
691
621
  dispatchAnalytics(applyCommonAttributes(_chunkloadFailedEvent({
692
622
  display: display,
693
623
  error: error,
@@ -713,13 +643,13 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
713
643
  * @returns
714
644
  * @deprecated
715
645
  */
716
- appAccountConnected: function appAccountConnected(_ref19) {
717
- var extensionKey = _ref19.extensionKey,
718
- definitionId = _ref19.definitionId,
719
- resourceType = _ref19.resourceType,
720
- destinationProduct = _ref19.destinationProduct,
721
- destinationSubproduct = _ref19.destinationSubproduct,
722
- location = _ref19.location;
646
+ appAccountConnected: function appAccountConnected(_ref17) {
647
+ var extensionKey = _ref17.extensionKey,
648
+ definitionId = _ref17.definitionId,
649
+ resourceType = _ref17.resourceType,
650
+ destinationProduct = _ref17.destinationProduct,
651
+ destinationSubproduct = _ref17.destinationSubproduct,
652
+ location = _ref17.location;
723
653
  return dispatchAnalytics(applyCommonAttributes(trackAppAccountConnected(_objectSpread(_objectSpread({}, commonAttributes), {}, {
724
654
  extensionKey: extensionKey,
725
655
  definitionId: definitionId,
@@ -736,9 +666,9 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
736
666
  * @returns
737
667
  * @deprecated
738
668
  */
739
- appAccountAuthStarted: function appAccountAuthStarted(_ref20) {
740
- var extensionKey = _ref20.extensionKey,
741
- location = _ref20.location;
669
+ appAccountAuthStarted: function appAccountAuthStarted(_ref18) {
670
+ var extensionKey = _ref18.extensionKey,
671
+ location = _ref18.location;
742
672
  return dispatchAnalytics(applyCommonAttributes(trackAppAccountAuthStarted(_objectSpread(_objectSpread({}, commonAttributes), {}, {
743
673
  extensionKey: extensionKey,
744
674
  location: location
@@ -786,13 +716,13 @@ export var useSmartLinkAnalytics = function useSmartLinkAnalytics(url, id, defau
786
716
  * @param extensionKey The extensionKey of the Smart Link resovler invoked.
787
717
  * @returns
788
718
  */
789
- authPopupEvent: function authPopupEvent(_ref21) {
790
- var extensionKey = _ref21.extensionKey,
791
- definitionId = _ref21.definitionId,
792
- resourceType = _ref21.resourceType,
793
- destinationProduct = _ref21.destinationProduct,
794
- destinationSubproduct = _ref21.destinationSubproduct,
795
- location = _ref21.location;
719
+ authPopupEvent: function authPopupEvent(_ref19) {
720
+ var extensionKey = _ref19.extensionKey,
721
+ definitionId = _ref19.definitionId,
722
+ resourceType = _ref19.resourceType,
723
+ destinationProduct = _ref19.destinationProduct,
724
+ destinationSubproduct = _ref19.destinationSubproduct,
725
+ location = _ref19.location;
796
726
  return dispatchAnalytics(applyCommonAttributes(screenAuthPopupEvent(_objectSpread(_objectSpread({}, commonAttributes), {}, {
797
727
  extensionKey: extensionKey,
798
728
  definitionId: definitionId,