@atlaskit/analytics-next 11.1.2 → 11.1.4

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 (36) hide show
  1. package/CHANGELOG.md +15 -20
  2. package/afm-cc/tsconfig.json +3 -2
  3. package/afm-jira/tsconfig.json +4 -3
  4. package/{afm-adminhub → afm-products}/tsconfig.json +5 -4
  5. package/dist/cjs/components/AnalyticsContext/index.js +3 -3
  6. package/dist/cjs/components/AnalyticsErrorBoundary.js +1 -1
  7. package/dist/cjs/components/AnalyticsListener/index.js +3 -3
  8. package/dist/es2019/components/AnalyticsContext/index.js +3 -3
  9. package/dist/es2019/components/AnalyticsErrorBoundary.js +1 -1
  10. package/dist/es2019/components/AnalyticsListener/index.js +3 -3
  11. package/dist/esm/components/AnalyticsContext/index.js +3 -3
  12. package/dist/esm/components/AnalyticsErrorBoundary.js +1 -1
  13. package/dist/esm/components/AnalyticsListener/index.js +3 -3
  14. package/dist/types/components/AnalyticsContext/index.d.ts +2 -2
  15. package/dist/types/components/AnalyticsListener/index.d.ts +2 -2
  16. package/dist/types/utils/createAndFireEvent.d.ts +2 -1
  17. package/dist/types-ts4.5/components/AnalyticsContext/index.d.ts +2 -2
  18. package/dist/types-ts4.5/components/AnalyticsListener/index.d.ts +2 -2
  19. package/dist/types-ts4.5/utils/createAndFireEvent.d.ts +2 -1
  20. package/docs/0-intro.tsx +2 -1
  21. package/docs/10-concepts.tsx +2 -1
  22. package/docs/20-usage-with-presentational-components.tsx +2 -1
  23. package/docs/30-usage-for-container-components.tsx +2 -1
  24. package/docs/40-listeners.tsx +3 -2
  25. package/docs/50-error-boundary.tsx +2 -1
  26. package/docs/60-events.tsx +2 -1
  27. package/docs/70-advanced-usage.tsx +2 -1
  28. package/docs/80-upgrade-guide.tsx +2 -1
  29. package/package.json +5 -5
  30. package/afm-dev-agents/tsconfig.json +0 -32
  31. package/afm-passionfruit/tsconfig.json +0 -32
  32. package/afm-post-office/tsconfig.json +0 -32
  33. package/afm-rovo-extension/tsconfig.json +0 -32
  34. package/afm-townsquare/tsconfig.json +0 -32
  35. package/afm-volt/tsconfig.json +0 -32
  36. package/build/tsconfig.json +0 -25
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @atlaskit/analytics-next
2
2
 
3
+ ## 11.1.4
4
+
5
+ ### Patch Changes
6
+
7
+ - [`0ca7d810bc817`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0ca7d810bc817) -
8
+ Re-implement legacy analytics context and listener behind a feature gate
9
+
10
+ ## 11.1.3
11
+
12
+ ### Patch Changes
13
+
14
+ - [`2752a069d8a01`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/2752a069d8a01) -
15
+ Cleaning up feature flag changes that remove the legacy contextTypes API, which is deprecated and
16
+ will be removed in the next major React release.
17
+
3
18
  ## 11.1.2
4
19
 
5
20
  ### Patch Changes
@@ -386,11 +401,9 @@
386
401
  - [#4749](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/4749)
387
402
  [`0e2a914932`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0e2a914932) - ###
388
403
  Additions
389
-
390
404
  - Added a new hook `useAnalyticsEventHandler` for sole use in Atlaskit components
391
405
 
392
406
  ### Removals
393
-
394
407
  - Removed some entry points that were unintentionally exposed
395
408
  - `AnalyticsContextConsumer`
396
409
  - `withAnalyticsHook`
@@ -400,7 +413,6 @@
400
413
  - `AnalyticsEventMap`
401
414
 
402
415
  ### Improvements
403
-
404
416
  - Optimization of components to prevent unnecessary re-renders via inline callbacks or jsons
405
417
  - Conversion to Function Components where possible
406
418
  - Preparation for dropping legacy React context in a future major release (see note below)
@@ -507,7 +519,6 @@
507
519
 
508
520
  Remove namespace imports from React, ReactDom, and PropTypes- Updated dependencies
509
521
  [6548261c9a](https://bitbucket.org/atlassian/atlassian-frontend/commits/6548261c9a):
510
-
511
522
  - @atlaskit/docs@8.3.2
512
523
  - @atlaskit/button@13.3.7
513
524
  - @atlaskit/textfield@3.1.6
@@ -532,7 +543,6 @@
532
543
 
533
544
  Fixes data type to Object- Updated dependencies
534
545
  [24865cfaff](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/24865cfaff):
535
-
536
546
  - @atlaskit/field-text@9.0.14
537
547
 
538
548
  ## 6.3.2
@@ -566,7 +576,6 @@
566
576
  ### Minor Changes
567
577
 
568
578
  - [minor][42fd897e16](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/42fd897e16):
569
-
570
579
  - Introduces a new custom React hook, `useAnalyticsEvents_experimental`, for creating analytics
571
580
  events within functional components. This hook replaces the need for the `withAnalyticsEvents`
572
581
  HOC. See the
@@ -619,12 +628,10 @@
619
628
  safety. Flow types are no longer provided. No behavioural changes.
620
629
 
621
630
  **Breaking changes**
622
-
623
631
  - `withAnalyticsForSumTypeProps` alias has been removed, please use `withAnalyticsEvents`
624
632
  - `AnalyticsContextWrappedComp` alias has been removed, please use `withAnalyticsContext`
625
633
 
626
634
  **Breaking changes to TypeScript annotations**
627
-
628
635
  - `withAnalyticsEvents` now infers proptypes automatically, consumers no longer need to provide
629
636
  props as a generic type.
630
637
  - `withAnalyticsContext` now infers proptypes automatically, consumers no longer need to provide
@@ -655,7 +662,6 @@
655
662
  ### Minor Changes
656
663
 
657
664
  - [minor][e1f8aaf33b](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/e1f8aaf33b):
658
-
659
665
  - Adding entry point for `AnalyticsErrorBoundary` package
660
666
 
661
667
  ```
@@ -692,7 +698,6 @@
692
698
  ```
693
699
 
694
700
  Notes on new API:
695
-
696
701
  - Plug-and-play component. As soon and it's wrapping a component it's fully integrated.
697
702
  - It has Analytics context and events integrated already. Keep in mind it requires
698
703
  `AnalyticsListener` as a top level component to work properly, otherwise it won't trigger
@@ -782,27 +787,23 @@
782
787
  ### Patch Changes
783
788
 
784
789
  - [patch][47acb57783](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/47acb57783):
785
-
786
790
  - Avoid unnecessary re-renders on components that use withAnalytics
787
791
 
788
792
  ## 5.0.0
789
793
 
790
794
  - [major][7c17b35107](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/7c17b35107):
791
-
792
795
  - Updates react and react-dom peer dependencies to react@^16.8.0 and react-dom@^16.8.0. To use
793
796
  this package, please ensure you use at least this version of react and react-dom.
794
797
 
795
798
  ## 4.0.5
796
799
 
797
800
  - [patch][3f28e6443c](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/3f28e6443c):
798
-
799
801
  - @atlaskit/analytics-next-types is deprecated. Now you can use types for @atlaskit/analytics-next
800
802
  supplied from itself.
801
803
 
802
804
  ## 4.0.4
803
805
 
804
806
  - [patch][9321da655d](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/9321da655d):
805
-
806
807
  - Update AnalyticsEventMap, as per major inline edit rewrite
807
808
 
808
809
  ## 4.0.3
@@ -816,7 +817,6 @@
816
817
  ## 4.0.2
817
818
 
818
819
  - [patch][98e11001ff](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/98e11001ff):
819
-
820
820
  - Removes duplicate babel-runtime dependency
821
821
 
822
822
  ## 4.0.1
@@ -830,7 +830,6 @@
830
830
  ## 4.0.0
831
831
 
832
832
  - [major][76299208e6](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/76299208e6):
833
-
834
833
  - Drop ES5 from all the flow modules
835
834
 
836
835
  ### Dropping CJS support in all @atlaskit packages
@@ -875,13 +874,11 @@
875
874
  ## 3.2.1
876
875
 
877
876
  - [patch][8de4c3f](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/8de4c3f):
878
-
879
877
  - Added missing export
880
878
 
881
879
  ## 3.2.0
882
880
 
883
881
  - [minor][c3fa0b6](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/c3fa0b6):
884
-
885
882
  - Added support for props of Sum type
886
883
 
887
884
  ## 3.1.2
@@ -901,7 +898,6 @@
901
898
  ## 3.1.0
902
899
 
903
900
  - [minor][cffeed0](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/cffeed0):
904
-
905
901
  - Type `withAnalyticsEvents` and `withAnalyticsContext` HOCs so that they do not lose flow types
906
902
  of the components they wrap when chained together.
907
903
 
@@ -917,7 +913,6 @@
917
913
  ## 3.0.11
918
914
 
919
915
  - [patch][d903ab5](https://bitbucket.org/atlassian/atlaskit-mk-2/commits/d903ab5):
920
-
921
916
  - Updates list of instrumented components
922
917
 
923
918
  ## 3.0.10
@@ -1,11 +1,12 @@
1
1
  {
2
- "extends": "../../../../tsconfig.entry-points.confluence.json",
2
+ "extends": "../../../../tsconfig.local-consumption.json",
3
3
  "compilerOptions": {
4
4
  "declaration": true,
5
5
  "target": "es5",
6
6
  "outDir": "../../../../../confluence/tsDist/@atlaskit__analytics-next",
7
7
  "rootDir": "../",
8
- "composite": true
8
+ "composite": true,
9
+ "noCheck": true
9
10
  },
10
11
  "include": [
11
12
  "../src/**/*.ts",
@@ -1,11 +1,12 @@
1
1
  {
2
- "extends": "../../../../tsconfig.entry-points.jira.json",
2
+ "extends": "../../../../tsconfig.local-consumption.json",
3
3
  "compilerOptions": {
4
4
  "declaration": true,
5
5
  "target": "es5",
6
- "outDir": "../../../../../tsDist/@atlaskit__analytics-next/app",
6
+ "outDir": "../../../../../jira/tsDist/@atlaskit__analytics-next/app",
7
7
  "rootDir": "../",
8
- "composite": true
8
+ "composite": true,
9
+ "noCheck": true
9
10
  },
10
11
  "include": [
11
12
  "../src/**/*.ts",
@@ -1,11 +1,12 @@
1
1
  {
2
- "extends": "../../../../tsconfig.entry-points.adminhub.json",
2
+ "extends": "../../../../tsconfig.local-consumption.json",
3
3
  "compilerOptions": {
4
4
  "declaration": true,
5
5
  "target": "es5",
6
- "outDir": "../../../../../adminhub/tsDist/@atlaskit__analytics-next/app",
6
+ "outDir": "../../../../../tsDist/@atlaskit__analytics-next/app",
7
7
  "rootDir": "../",
8
- "composite": true
8
+ "composite": true,
9
+ "noCheck": true
9
10
  },
10
11
  "include": [
11
12
  "../src/**/*.ts",
@@ -26,7 +27,7 @@
26
27
  ],
27
28
  "references": [
28
29
  {
29
- "path": "../../../platform/feature-flags/afm-adminhub/tsconfig.json"
30
+ "path": "../../../platform/feature-flags/afm-products/tsconfig.json"
30
31
  }
31
32
  ]
32
33
  }
@@ -10,8 +10,8 @@ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
10
10
  var _isModernContextEnabledEnv = _interopRequireDefault(require("../../utils/isModernContextEnabledEnv"));
11
11
  var _LegacyAnalyticsContext = _interopRequireDefault(require("./LegacyAnalyticsContext"));
12
12
  var _ModernAnalyticsContext = _interopRequireDefault(require("./ModernAnalyticsContext"));
13
- var ExportedAnalyticsContext = function ExportedAnalyticsContext(props) {
14
- var isModernContext = _isModernContextEnabledEnv.default || (0, _platformFeatureFlags.fg)('analytics-next-use-modern-context_jira');
13
+ var AnalyticsContext = function AnalyticsContext(props) {
14
+ var isModernContext = _isModernContextEnabledEnv.default || (0, _platformFeatureFlags.fg)('analytics-next-use-legacy-context') === false;
15
15
  return isModernContext ? /*#__PURE__*/_react.default.createElement(_ModernAnalyticsContext.default, props) : /*#__PURE__*/_react.default.createElement(_LegacyAnalyticsContext.default, props);
16
16
  };
17
- var _default = exports.default = ExportedAnalyticsContext;
17
+ var _default = exports.default = AnalyticsContext;
@@ -52,7 +52,7 @@ var AnalyticsErrorBoundary = exports.default = /*#__PURE__*/function (_Component
52
52
  children = _this$props.children,
53
53
  ErrorComponent = _this$props.ErrorComponent;
54
54
  var hasError = this.state.hasError;
55
- var isModernContext = _isModernContextEnabledEnv.default || (0, _platformFeatureFlags.fg)('analytics-next-use-modern-context_jira');
55
+ var isModernContext = _isModernContextEnabledEnv.default || (0, _platformFeatureFlags.fg)('analytics-next-use-legacy-context') === false;
56
56
  if (hasError) {
57
57
  if (ErrorComponent) {
58
58
  if (isModernContext) {
@@ -10,8 +10,8 @@ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
10
10
  var _isModernContextEnabledEnv = _interopRequireDefault(require("../../utils/isModernContextEnabledEnv"));
11
11
  var _LegacyAnalyticsListener = _interopRequireDefault(require("./LegacyAnalyticsListener"));
12
12
  var _ModernAnalyticsListener = _interopRequireDefault(require("./ModernAnalyticsListener"));
13
- var ExportedAnalyticsListener = function ExportedAnalyticsListener(props) {
14
- var isModernContext = _isModernContextEnabledEnv.default || (0, _platformFeatureFlags.fg)('analytics-next-use-modern-context_jira');
13
+ var AnalyticsListener = function AnalyticsListener(props) {
14
+ var isModernContext = _isModernContextEnabledEnv.default || (0, _platformFeatureFlags.fg)('analytics-next-use-legacy-context') === false;
15
15
  return isModernContext ? /*#__PURE__*/_react.default.createElement(_ModernAnalyticsListener.default, props) : /*#__PURE__*/_react.default.createElement(_LegacyAnalyticsListener.default, props);
16
16
  };
17
- var _default = exports.default = ExportedAnalyticsListener;
17
+ var _default = exports.default = AnalyticsListener;
@@ -3,8 +3,8 @@ import { fg } from '@atlaskit/platform-feature-flags';
3
3
  import isModernContextEnabledEnv from '../../utils/isModernContextEnabledEnv';
4
4
  import LegacyAnalyticsContext from './LegacyAnalyticsContext';
5
5
  import ModernAnalyticsContext from './ModernAnalyticsContext';
6
- const ExportedAnalyticsContext = props => {
7
- const isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-modern-context_jira');
6
+ const AnalyticsContext = props => {
7
+ const isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-legacy-context') === false;
8
8
  return isModernContext ? /*#__PURE__*/React.createElement(ModernAnalyticsContext, props) : /*#__PURE__*/React.createElement(LegacyAnalyticsContext, props);
9
9
  };
10
- export default ExportedAnalyticsContext;
10
+ export default AnalyticsContext;
@@ -33,7 +33,7 @@ export default class AnalyticsErrorBoundary extends Component {
33
33
  const {
34
34
  hasError
35
35
  } = this.state;
36
- const isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-modern-context_jira');
36
+ const isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-legacy-context') === false;
37
37
  if (hasError) {
38
38
  if (ErrorComponent) {
39
39
  if (isModernContext) {
@@ -3,8 +3,8 @@ import { fg } from '@atlaskit/platform-feature-flags';
3
3
  import isModernContextEnabledEnv from '../../utils/isModernContextEnabledEnv';
4
4
  import LegacyAnalyticsListener from './LegacyAnalyticsListener';
5
5
  import ModernAnalyticsListener from './ModernAnalyticsListener';
6
- const ExportedAnalyticsListener = props => {
7
- const isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-modern-context_jira');
6
+ const AnalyticsListener = props => {
7
+ const isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-legacy-context') === false;
8
8
  return isModernContext ? /*#__PURE__*/React.createElement(ModernAnalyticsListener, props) : /*#__PURE__*/React.createElement(LegacyAnalyticsListener, props);
9
9
  };
10
- export default ExportedAnalyticsListener;
10
+ export default AnalyticsListener;
@@ -3,8 +3,8 @@ import { fg } from '@atlaskit/platform-feature-flags';
3
3
  import isModernContextEnabledEnv from '../../utils/isModernContextEnabledEnv';
4
4
  import LegacyAnalyticsContext from './LegacyAnalyticsContext';
5
5
  import ModernAnalyticsContext from './ModernAnalyticsContext';
6
- var ExportedAnalyticsContext = function ExportedAnalyticsContext(props) {
7
- var isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-modern-context_jira');
6
+ var AnalyticsContext = function AnalyticsContext(props) {
7
+ var isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-legacy-context') === false;
8
8
  return isModernContext ? /*#__PURE__*/React.createElement(ModernAnalyticsContext, props) : /*#__PURE__*/React.createElement(LegacyAnalyticsContext, props);
9
9
  };
10
- export default ExportedAnalyticsContext;
10
+ export default AnalyticsContext;
@@ -43,7 +43,7 @@ var AnalyticsErrorBoundary = /*#__PURE__*/function (_Component) {
43
43
  children = _this$props.children,
44
44
  ErrorComponent = _this$props.ErrorComponent;
45
45
  var hasError = this.state.hasError;
46
- var isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-modern-context_jira');
46
+ var isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-legacy-context') === false;
47
47
  if (hasError) {
48
48
  if (ErrorComponent) {
49
49
  if (isModernContext) {
@@ -3,8 +3,8 @@ import { fg } from '@atlaskit/platform-feature-flags';
3
3
  import isModernContextEnabledEnv from '../../utils/isModernContextEnabledEnv';
4
4
  import LegacyAnalyticsListener from './LegacyAnalyticsListener';
5
5
  import ModernAnalyticsListener from './ModernAnalyticsListener';
6
- var ExportedAnalyticsListener = function ExportedAnalyticsListener(props) {
7
- var isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-modern-context_jira');
6
+ var AnalyticsListener = function AnalyticsListener(props) {
7
+ var isModernContext = isModernContextEnabledEnv || fg('analytics-next-use-legacy-context') === false;
8
8
  return isModernContext ? /*#__PURE__*/React.createElement(ModernAnalyticsListener, props) : /*#__PURE__*/React.createElement(LegacyAnalyticsListener, props);
9
9
  };
10
- export default ExportedAnalyticsListener;
10
+ export default AnalyticsListener;
@@ -1,3 +1,3 @@
1
1
  import { type AnalyticsContextFunction } from './types';
2
- declare const ExportedAnalyticsContext: AnalyticsContextFunction;
3
- export default ExportedAnalyticsContext;
2
+ declare const AnalyticsContext: AnalyticsContextFunction;
3
+ export default AnalyticsContext;
@@ -1,3 +1,3 @@
1
1
  import { type AnalyticsListenerFunction } from './types';
2
- declare const ExportedAnalyticsListener: AnalyticsListenerFunction;
3
- export default ExportedAnalyticsListener;
2
+ declare const AnalyticsListener: AnalyticsListenerFunction;
3
+ export default AnalyticsListener;
@@ -1,4 +1,5 @@
1
1
  import { type AnalyticsEventPayload } from '../events/AnalyticsEvent';
2
+ import type UIAnalyticsEvent from '../events/UIAnalyticsEvent';
2
3
  import { type CreateUIAnalyticsEvent } from '../types';
3
- declare const _default: (channel?: string) => (payload: AnalyticsEventPayload) => (createAnalyticsEvent: CreateUIAnalyticsEvent) => import("..").UIAnalyticsEvent;
4
+ declare const _default: (channel?: string) => (payload: AnalyticsEventPayload) => (createAnalyticsEvent: CreateUIAnalyticsEvent) => UIAnalyticsEvent;
4
5
  export default _default;
@@ -1,3 +1,3 @@
1
1
  import { type AnalyticsContextFunction } from './types';
2
- declare const ExportedAnalyticsContext: AnalyticsContextFunction;
3
- export default ExportedAnalyticsContext;
2
+ declare const AnalyticsContext: AnalyticsContextFunction;
3
+ export default AnalyticsContext;
@@ -1,3 +1,3 @@
1
1
  import { type AnalyticsListenerFunction } from './types';
2
- declare const ExportedAnalyticsListener: AnalyticsListenerFunction;
3
- export default ExportedAnalyticsListener;
2
+ declare const AnalyticsListener: AnalyticsListenerFunction;
3
+ export default AnalyticsListener;
@@ -1,4 +1,5 @@
1
1
  import { type AnalyticsEventPayload } from '../events/AnalyticsEvent';
2
+ import type UIAnalyticsEvent from '../events/UIAnalyticsEvent';
2
3
  import { type CreateUIAnalyticsEvent } from '../types';
3
- declare const _default: (channel?: string) => (payload: AnalyticsEventPayload) => (createAnalyticsEvent: CreateUIAnalyticsEvent) => import("..").UIAnalyticsEvent;
4
+ declare const _default: (channel?: string) => (payload: AnalyticsEventPayload) => (createAnalyticsEvent: CreateUIAnalyticsEvent) => UIAnalyticsEvent;
4
5
  export default _default;
package/docs/0-intro.tsx CHANGED
@@ -4,7 +4,7 @@ import { md } from '@atlaskit/docs';
4
4
  import Link from '@atlaskit/link';
5
5
  import SectionMessage from '@atlaskit/section-message';
6
6
 
7
- export default md`
7
+ const _default_1: any = md`
8
8
 
9
9
  ${(
10
10
  <SectionMessage
@@ -39,3 +39,4 @@ This package aims to help assist consumers track the way their React components
39
39
  - [Advanced usage](./analytics-next/docs/advanced-usage)
40
40
  - [Ugprade guide](./analytics-next/docs/upgrade-guide)
41
41
  `;
42
+ export default _default_1;
@@ -1,6 +1,6 @@
1
1
  import { code, md } from '@atlaskit/docs';
2
2
 
3
- export default md`
3
+ const _default_1: any = md`
4
4
  There are 3 abstract layers as part of \`@atlaskit/analytics-next\`:
5
5
 
6
6
  - [Analytics Listeners](./listeners) (responsible for sending events over the network)
@@ -119,3 +119,4 @@ ${code`
119
119
  [legacy-context]: https://reactjs.org/docs/legacy-context.html
120
120
  [modern-context]: https://reactjs.org/docs/context.html
121
121
  `;
122
+ export default _default_1;
@@ -3,7 +3,7 @@ import React from 'react';
3
3
  import { code, md } from '@atlaskit/docs';
4
4
  import Link from '@atlaskit/link';
5
5
 
6
- export default md`
6
+ const _default_1: any = md`
7
7
  This section will guide how to add analytics tracking to presentational and other
8
8
  components that don't fit into the "Container" category.
9
9
 
@@ -358,3 +358,4 @@ export MyButton;
358
358
  `}
359
359
 
360
360
  `;
361
+ export default _default_1;
@@ -1,6 +1,6 @@
1
1
  import { code, md } from '@atlaskit/docs';
2
2
 
3
- export default md`
3
+ const _default_1: any = md`
4
4
  This guide describes how to set up analytics for a React component that is a
5
5
  container for children that fire analytics events, and where you wish to include
6
6
  contextual information to those children about where it is embeded in the event fired.
@@ -61,3 +61,4 @@ While it is possible to use the React context from \`@atlaskit/analytics-next-st
61
61
  we encourage you to use one of these two approaches instead, as they are optimised to ensure the value provided
62
62
  to React Context is a stable reference, and won't introduce unnecessary re-renders.
63
63
  `;
64
+ export default _default_1;
@@ -2,7 +2,7 @@ import React from 'react';
2
2
 
3
3
  import { code, md, Props } from '@atlaskit/docs';
4
4
 
5
- export default md`
5
+ const _default_1: any = md`
6
6
  ${code`import { AnalyticsListener } from '@atlaskit/analytics-next';`}
7
7
 
8
8
  An \`AnalyticsListener\` wraps your app and listens to any events which are fired within it.
@@ -10,7 +10,8 @@ export default md`
10
10
  ${(
11
11
  <Props
12
12
  heading="AnalyticsListener Props"
13
- props={require('!!extract-react-types-loader!../src/components/AnalyticsListener/LegacyAnalyticsListener')}
13
+ props={require('!!extract-react-types-loader!../src/components/AnalyticsListener/ModernAnalyticsListener')}
14
14
  />
15
15
  )}
16
16
  `;
17
+ export default _default_1;
@@ -2,7 +2,7 @@ import React from 'react';
2
2
 
3
3
  import { code, md, Props } from '@atlaskit/docs';
4
4
 
5
- export default md`
5
+ const _default_1: any = md`
6
6
  ${code`import { AnalyticsErrorBoundary } from '@atlaskit/analytics-next';`}
7
7
 
8
8
  Wrap part of your tree in \`AnalyticsErrorBoundary\` to provide error boundary track to any events created beneath it.
@@ -52,3 +52,4 @@ class ButtonWithAnalyticsErrorBoundary extends React.Component {
52
52
  />
53
53
  )}
54
54
  `;
55
+ export default _default_1;
@@ -1,6 +1,6 @@
1
1
  import { code, md } from '@atlaskit/docs';
2
2
 
3
- export default md`
3
+ const _default_1: any = md`
4
4
  <a name="UIAnalyticsEvent"></a>
5
5
  ### UIAnalyticsEvent
6
6
 
@@ -52,3 +52,4 @@ update(
52
52
 
53
53
  Please see [UIAnalyticsEvent](#UIAnalyticsEvent) for more information.
54
54
  `;
55
+ export default _default_1;
@@ -2,7 +2,7 @@ import React from 'react';
2
2
 
3
3
  import { code, Example, md } from '@atlaskit/docs';
4
4
 
5
- export default md`
5
+ const _default_1: any = md`
6
6
  ### Contents
7
7
 
8
8
  * [Adding more information to an event](#adding-more-information-to-an-event)
@@ -268,3 +268,4 @@ const fetchBacon = async () => {
268
268
  };
269
269
  `}
270
270
  `;
271
+ export default _default_1;
@@ -1,6 +1,6 @@
1
1
  import { code, md } from '@atlaskit/docs';
2
2
 
3
- export default md`
3
+ const _default_1: any = md`
4
4
  ## v5 to v6
5
5
 
6
6
  ### ✨ TypeScript support
@@ -119,3 +119,4 @@ export default withAnalyticsContext({})(
119
119
 
120
120
 
121
121
  `;
122
+ export default _default_1;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/analytics-next",
3
- "version": "11.1.2",
3
+ "version": "11.1.4",
4
4
  "description": "React components, HOCs and hooks to assist with tracking user activity with React components",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -41,9 +41,9 @@
41
41
  "react-dom": "^18.2.0"
42
42
  },
43
43
  "devDependencies": {
44
- "@atlassian/feature-flags-test-utils": "^0.3.0",
45
- "@atlassian/ssr-tests": "^0.3.0",
46
- "@testing-library/react": "^13.4.0",
44
+ "@atlassian/feature-flags-test-utils": "^1.0.0",
45
+ "@atlassian/ssr-tests": "workspace:^",
46
+ "@testing-library/react": "^16.3.0",
47
47
  "storybook-addon-performance": "^0.17.3"
48
48
  },
49
49
  "overrides": {
@@ -74,7 +74,7 @@
74
74
  }
75
75
  },
76
76
  "platform-feature-flags": {
77
- "analytics-next-use-modern-context_jira": {
77
+ "analytics-next-use-legacy-context": {
78
78
  "type": "boolean"
79
79
  }
80
80
  }
@@ -1,32 +0,0 @@
1
- {
2
- "extends": "../../../../tsconfig.entry-points.dev-agents.json",
3
- "compilerOptions": {
4
- "declaration": true,
5
- "target": "es5",
6
- "outDir": "../../../../../dev-agents/tsDist/@atlaskit__analytics-next/app",
7
- "rootDir": "../",
8
- "composite": true
9
- },
10
- "include": [
11
- "../src/**/*.ts",
12
- "../src/**/*.tsx"
13
- ],
14
- "exclude": [
15
- "../src/**/__tests__/*",
16
- "../src/**/*.test.*",
17
- "../src/**/test.*",
18
- "../src/performance/examples.tsx",
19
- "../docs/*",
20
- "../src/**/examples.*",
21
- "../src/**/examples/*",
22
- "../src/**/examples/**/*",
23
- "../src/**/*.stories.*",
24
- "../src/**/stories/*",
25
- "../src/**/stories/**/*"
26
- ],
27
- "references": [
28
- {
29
- "path": "../../../platform/feature-flags/afm-dev-agents/tsconfig.json"
30
- }
31
- ]
32
- }
@@ -1,32 +0,0 @@
1
- {
2
- "extends": "../../../../tsconfig.entry-points.passionfruit.json",
3
- "compilerOptions": {
4
- "declaration": true,
5
- "target": "es5",
6
- "outDir": "../../../../../passionfruit/tsDist/@atlaskit__analytics-next/app",
7
- "rootDir": "../",
8
- "composite": true
9
- },
10
- "include": [
11
- "../src/**/*.ts",
12
- "../src/**/*.tsx"
13
- ],
14
- "exclude": [
15
- "../src/**/__tests__/*",
16
- "../src/**/*.test.*",
17
- "../src/**/test.*",
18
- "../src/performance/examples.tsx",
19
- "../docs/*",
20
- "../src/**/examples.*",
21
- "../src/**/examples/*",
22
- "../src/**/examples/**/*",
23
- "../src/**/*.stories.*",
24
- "../src/**/stories/*",
25
- "../src/**/stories/**/*"
26
- ],
27
- "references": [
28
- {
29
- "path": "../../../platform/feature-flags/afm-passionfruit/tsconfig.json"
30
- }
31
- ]
32
- }
@@ -1,32 +0,0 @@
1
- {
2
- "extends": "../../../../tsconfig.entry-points.post-office.json",
3
- "compilerOptions": {
4
- "declaration": true,
5
- "target": "es5",
6
- "outDir": "../../../../../post-office/tsDist/@atlaskit__analytics-next/app",
7
- "rootDir": "../",
8
- "composite": true
9
- },
10
- "include": [
11
- "../src/**/*.ts",
12
- "../src/**/*.tsx"
13
- ],
14
- "exclude": [
15
- "../src/**/__tests__/*",
16
- "../src/**/*.test.*",
17
- "../src/**/test.*",
18
- "../src/performance/examples.tsx",
19
- "../docs/*",
20
- "../src/**/examples.*",
21
- "../src/**/examples/*",
22
- "../src/**/examples/**/*",
23
- "../src/**/*.stories.*",
24
- "../src/**/stories/*",
25
- "../src/**/stories/**/*"
26
- ],
27
- "references": [
28
- {
29
- "path": "../../../platform/feature-flags/afm-post-office/tsconfig.json"
30
- }
31
- ]
32
- }
@@ -1,32 +0,0 @@
1
- {
2
- "extends": "../../../../tsconfig.entry-points.rovo-extension.json",
3
- "compilerOptions": {
4
- "declaration": true,
5
- "target": "es5",
6
- "outDir": "../../../../../rovo-extension/tsDist/@atlaskit__analytics-next/app",
7
- "rootDir": "../",
8
- "composite": true
9
- },
10
- "include": [
11
- "../src/**/*.ts",
12
- "../src/**/*.tsx"
13
- ],
14
- "exclude": [
15
- "../src/**/__tests__/*",
16
- "../src/**/*.test.*",
17
- "../src/**/test.*",
18
- "../src/performance/examples.tsx",
19
- "../docs/*",
20
- "../src/**/examples.*",
21
- "../src/**/examples/*",
22
- "../src/**/examples/**/*",
23
- "../src/**/*.stories.*",
24
- "../src/**/stories/*",
25
- "../src/**/stories/**/*"
26
- ],
27
- "references": [
28
- {
29
- "path": "../../../platform/feature-flags/afm-rovo-extension/tsconfig.json"
30
- }
31
- ]
32
- }
@@ -1,32 +0,0 @@
1
- {
2
- "extends": "../../../../tsconfig.entry-points.townsquare.json",
3
- "compilerOptions": {
4
- "declaration": true,
5
- "target": "es5",
6
- "outDir": "../../../../../townsquare/tsDist/@atlaskit__analytics-next/app",
7
- "rootDir": "../",
8
- "composite": true
9
- },
10
- "include": [
11
- "../src/**/*.ts",
12
- "../src/**/*.tsx"
13
- ],
14
- "exclude": [
15
- "../src/**/__tests__/*",
16
- "../src/**/*.test.*",
17
- "../src/**/test.*",
18
- "../src/performance/examples.tsx",
19
- "../docs/*",
20
- "../src/**/examples.*",
21
- "../src/**/examples/*",
22
- "../src/**/examples/**/*",
23
- "../src/**/*.stories.*",
24
- "../src/**/stories/*",
25
- "../src/**/stories/**/*"
26
- ],
27
- "references": [
28
- {
29
- "path": "../../../platform/feature-flags/afm-townsquare/tsconfig.json"
30
- }
31
- ]
32
- }
@@ -1,32 +0,0 @@
1
- {
2
- "extends": "../../../../tsconfig.entry-points.volt.json",
3
- "compilerOptions": {
4
- "declaration": true,
5
- "target": "es5",
6
- "outDir": "../../../../../volt/tsDist/@atlaskit__analytics-next/app",
7
- "rootDir": "../",
8
- "composite": true
9
- },
10
- "include": [
11
- "../src/**/*.ts",
12
- "../src/**/*.tsx"
13
- ],
14
- "exclude": [
15
- "../src/**/__tests__/*",
16
- "../src/**/*.test.*",
17
- "../src/**/test.*",
18
- "../src/performance/examples.tsx",
19
- "../docs/*",
20
- "../src/**/examples.*",
21
- "../src/**/examples/*",
22
- "../src/**/examples/**/*",
23
- "../src/**/*.stories.*",
24
- "../src/**/stories/*",
25
- "../src/**/stories/**/*"
26
- ],
27
- "references": [
28
- {
29
- "path": "../../../platform/feature-flags/afm-volt/tsconfig.json"
30
- }
31
- ]
32
- }
@@ -1,25 +0,0 @@
1
- {
2
- "extends": "../tsconfig",
3
- "compilerOptions": {
4
- "declaration": true,
5
- "target": "es5",
6
- "paths": {}
7
- },
8
- "include": [
9
- "../src/**/*.ts",
10
- "../src/**/*.tsx"
11
- ],
12
- "exclude": [
13
- "../src/**/__tests__/*",
14
- "../src/**/*.test.*",
15
- "../src/**/test.*",
16
- "../src/performance/examples.tsx",
17
- "../docs/*",
18
- "../src/**/examples.*",
19
- "../src/**/examples/*",
20
- "../src/**/examples/**/*",
21
- "../src/**/*.stories.*",
22
- "../src/**/stories/*",
23
- "../src/**/stories/**/*"
24
- ]
25
- }