@atlaskit/link-create 1.12.1 → 1.13.1
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/CHANGELOG.md +13 -0
- package/analytics.spec.yaml +4 -0
- package/dist/cjs/common/utils/analytics/analytics.codegen.js +1 -1
- package/dist/cjs/common/utils/locale/fetch-messages-for-locale.js +8 -1
- package/dist/cjs/controllers/experience-tracker/index.js +4 -0
- package/dist/cjs/ui/main.js +1 -1
- package/dist/es2019/common/utils/analytics/analytics.codegen.js +1 -1
- package/dist/es2019/common/utils/locale/fetch-messages-for-locale.js +4 -0
- package/dist/es2019/controllers/experience-tracker/index.js +4 -0
- package/dist/es2019/ui/main.js +1 -1
- package/dist/esm/common/utils/analytics/analytics.codegen.js +1 -1
- package/dist/esm/common/utils/locale/fetch-messages-for-locale.js +8 -1
- package/dist/esm/controllers/experience-tracker/index.js +4 -0
- package/dist/esm/ui/main.js +1 -1
- package/dist/types/common/utils/analytics/analytics.codegen.d.ts +2 -1
- package/dist/types-ts4.5/common/utils/analytics/analytics.codegen.d.ts +2 -1
- package/package.json +9 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,18 @@
|
|
|
1
1
|
# @atlaskit/link-create
|
|
2
2
|
|
|
3
|
+
## 1.13.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#63626](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/63626) [`e71c8f5f586e`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/e71c8f5f586e) - loaderFn returns undefined if failed to dynamicaly import locale messages - fixes issue in Jira where default English replaces languages chunk.
|
|
8
|
+
- Updated dependencies
|
|
9
|
+
|
|
10
|
+
## 1.13.0
|
|
11
|
+
|
|
12
|
+
### Minor Changes
|
|
13
|
+
|
|
14
|
+
- [#63972](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/63972) [`3fe8708a6cf0`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/3fe8708a6cf0) - Log error message on experience failure for debugging purposes, when ff is enabled.
|
|
15
|
+
|
|
3
16
|
## 1.12.1
|
|
4
17
|
|
|
5
18
|
### Patch Changes
|
package/analytics.spec.yaml
CHANGED
|
@@ -138,6 +138,10 @@ events:
|
|
|
138
138
|
type: string
|
|
139
139
|
description: the name of the error
|
|
140
140
|
required: false
|
|
141
|
+
errorMessage:
|
|
142
|
+
type: string
|
|
143
|
+
description: the message of the error if available
|
|
144
|
+
required: false
|
|
141
145
|
experienceStatus:
|
|
142
146
|
type: ['SUCCEEDED', 'FAILED']
|
|
143
147
|
previousExperienceStatus:
|
|
@@ -11,7 +11,7 @@ var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/sli
|
|
|
11
11
|
*
|
|
12
12
|
* Generates Typescript types for analytics events from analytics.spec.yaml
|
|
13
13
|
*
|
|
14
|
-
* @codegen <<SignedSource::
|
|
14
|
+
* @codegen <<SignedSource::1c67626e82d39af8e93ced7a11389f4f>>
|
|
15
15
|
* @codegenCommand yarn workspace @atlaskit/link-create run codegen-analytics
|
|
16
16
|
*/
|
|
17
17
|
|
|
@@ -8,6 +8,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
8
8
|
exports.fetchMessagesForLocale = void 0;
|
|
9
9
|
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
10
10
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
11
|
+
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
11
12
|
var _en = _interopRequireDefault(require("../../../i18n/en"));
|
|
12
13
|
function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
|
|
13
14
|
function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
|
|
@@ -50,8 +51,14 @@ var fetchMessagesForLocale = exports.fetchMessagesForLocale = /*#__PURE__*/funct
|
|
|
50
51
|
_context.prev = 17;
|
|
51
52
|
_context.t1 = _context["catch"](9);
|
|
52
53
|
case 19:
|
|
54
|
+
if (!(0, _platformFeatureFlags.getBooleanFF)('platform.linking-platform.link-create.tmp-fix-translations')) {
|
|
55
|
+
_context.next = 21;
|
|
56
|
+
break;
|
|
57
|
+
}
|
|
58
|
+
return _context.abrupt("return");
|
|
59
|
+
case 21:
|
|
53
60
|
return _context.abrupt("return", _en.default);
|
|
54
|
-
case
|
|
61
|
+
case 22:
|
|
55
62
|
case "end":
|
|
56
63
|
return _context.stop();
|
|
57
64
|
}
|
|
@@ -54,6 +54,10 @@ var Experience = exports.Experience = function Experience(_ref) {
|
|
|
54
54
|
* The type of error that has failed the experience
|
|
55
55
|
*/
|
|
56
56
|
errorType: (0, _errors.getErrorType)(error),
|
|
57
|
+
/**
|
|
58
|
+
* Error message if instanceof Error
|
|
59
|
+
*/
|
|
60
|
+
errorMessage: (0, _platformFeatureFlags.getBooleanFF)('platform.linking-platform.link-create.tmp-log-error-message') && error instanceof Error ? error.message : null,
|
|
57
61
|
/**
|
|
58
62
|
* The current status of the experience (has failed)
|
|
59
63
|
*/
|
package/dist/cjs/ui/main.js
CHANGED
|
@@ -31,7 +31,7 @@ var LinkCreateWithAnalyticsContext = (0, _analytics.withLinkCreateAnalyticsConte
|
|
|
31
31
|
}));
|
|
32
32
|
var PACKAGE_DATA = exports.PACKAGE_DATA = {
|
|
33
33
|
packageName: "@atlaskit/link-create" || '',
|
|
34
|
-
packageVersion: "1.
|
|
34
|
+
packageVersion: "1.13.1" || '',
|
|
35
35
|
component: _constants.COMPONENT_NAME,
|
|
36
36
|
componentName: _constants.COMPONENT_NAME
|
|
37
37
|
};
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Generates Typescript types for analytics events from analytics.spec.yaml
|
|
5
5
|
*
|
|
6
|
-
* @codegen <<SignedSource::
|
|
6
|
+
* @codegen <<SignedSource::1c67626e82d39af8e93ced7a11389f4f>>
|
|
7
7
|
* @codegenCommand yarn workspace @atlaskit/link-create run codegen-analytics
|
|
8
8
|
*/
|
|
9
9
|
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
1
2
|
import messages from '../../../i18n/en';
|
|
2
3
|
export const fetchMessagesForLocale = async locale => {
|
|
3
4
|
try {
|
|
@@ -13,6 +14,9 @@ export const fetchMessagesForLocale = async locale => {
|
|
|
13
14
|
} catch (e) {
|
|
14
15
|
// ignore
|
|
15
16
|
}
|
|
17
|
+
if (getBooleanFF('platform.linking-platform.link-create.tmp-fix-translations')) {
|
|
18
|
+
return;
|
|
19
|
+
}
|
|
16
20
|
|
|
17
21
|
/**
|
|
18
22
|
* English bundled by default as this is the majority of users
|
|
@@ -42,6 +42,10 @@ export const Experience = ({
|
|
|
42
42
|
* The type of error that has failed the experience
|
|
43
43
|
*/
|
|
44
44
|
errorType: getErrorType(error),
|
|
45
|
+
/**
|
|
46
|
+
* Error message if instanceof Error
|
|
47
|
+
*/
|
|
48
|
+
errorMessage: getBooleanFF('platform.linking-platform.link-create.tmp-log-error-message') && error instanceof Error ? error.message : null,
|
|
45
49
|
/**
|
|
46
50
|
* The current status of the experience (has failed)
|
|
47
51
|
*/
|
package/dist/es2019/ui/main.js
CHANGED
|
@@ -23,7 +23,7 @@ const LinkCreateWithAnalyticsContext = withLinkCreateAnalyticsContext( /*#__PURE
|
|
|
23
23
|
}));
|
|
24
24
|
export const PACKAGE_DATA = {
|
|
25
25
|
packageName: "@atlaskit/link-create" || '',
|
|
26
|
-
packageVersion: "1.
|
|
26
|
+
packageVersion: "1.13.1" || '',
|
|
27
27
|
component: COMPONENT_NAME,
|
|
28
28
|
componentName: COMPONENT_NAME
|
|
29
29
|
};
|
|
@@ -4,7 +4,7 @@ import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
|
4
4
|
*
|
|
5
5
|
* Generates Typescript types for analytics events from analytics.spec.yaml
|
|
6
6
|
*
|
|
7
|
-
* @codegen <<SignedSource::
|
|
7
|
+
* @codegen <<SignedSource::1c67626e82d39af8e93ced7a11389f4f>>
|
|
8
8
|
* @codegenCommand yarn workspace @atlaskit/link-create run codegen-analytics
|
|
9
9
|
*/
|
|
10
10
|
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
2
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
3
|
+
import { getBooleanFF } from '@atlaskit/platform-feature-flags';
|
|
3
4
|
import messages from '../../../i18n/en';
|
|
4
5
|
export var fetchMessagesForLocale = /*#__PURE__*/function () {
|
|
5
6
|
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(locale) {
|
|
@@ -28,8 +29,14 @@ export var fetchMessagesForLocale = /*#__PURE__*/function () {
|
|
|
28
29
|
_context.prev = 17;
|
|
29
30
|
_context.t1 = _context["catch"](9);
|
|
30
31
|
case 19:
|
|
32
|
+
if (!getBooleanFF('platform.linking-platform.link-create.tmp-fix-translations')) {
|
|
33
|
+
_context.next = 21;
|
|
34
|
+
break;
|
|
35
|
+
}
|
|
36
|
+
return _context.abrupt("return");
|
|
37
|
+
case 21:
|
|
31
38
|
return _context.abrupt("return", messages);
|
|
32
|
-
case
|
|
39
|
+
case 22:
|
|
33
40
|
case "end":
|
|
34
41
|
return _context.stop();
|
|
35
42
|
}
|
|
@@ -44,6 +44,10 @@ export var Experience = function Experience(_ref) {
|
|
|
44
44
|
* The type of error that has failed the experience
|
|
45
45
|
*/
|
|
46
46
|
errorType: getErrorType(error),
|
|
47
|
+
/**
|
|
48
|
+
* Error message if instanceof Error
|
|
49
|
+
*/
|
|
50
|
+
errorMessage: getBooleanFF('platform.linking-platform.link-create.tmp-log-error-message') && error instanceof Error ? error.message : null,
|
|
47
51
|
/**
|
|
48
52
|
* The current status of the experience (has failed)
|
|
49
53
|
*/
|
package/dist/esm/ui/main.js
CHANGED
|
@@ -23,7 +23,7 @@ var LinkCreateWithAnalyticsContext = withLinkCreateAnalyticsContext( /*#__PURE__
|
|
|
23
23
|
}));
|
|
24
24
|
export var PACKAGE_DATA = {
|
|
25
25
|
packageName: "@atlaskit/link-create" || '',
|
|
26
|
-
packageVersion: "1.
|
|
26
|
+
packageVersion: "1.13.1" || '',
|
|
27
27
|
component: COMPONENT_NAME,
|
|
28
28
|
componentName: COMPONENT_NAME
|
|
29
29
|
};
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Generates Typescript types for analytics events from analytics.spec.yaml
|
|
5
5
|
*
|
|
6
|
-
* @codegen <<SignedSource::
|
|
6
|
+
* @codegen <<SignedSource::1c67626e82d39af8e93ced7a11389f4f>>
|
|
7
7
|
* @codegenCommand yarn workspace @atlaskit/link-create run codegen-analytics
|
|
8
8
|
*/
|
|
9
9
|
export type PackageMetaDataType = {
|
|
@@ -40,6 +40,7 @@ export type ObjectCreateFailedLinkCreateAttributesType = {
|
|
|
40
40
|
};
|
|
41
41
|
export type LinkCreateExperienceFailedAttributesType = {
|
|
42
42
|
errorType: string | null;
|
|
43
|
+
errorMessage: string | null;
|
|
43
44
|
experienceStatus: 'SUCCEEDED' | 'FAILED';
|
|
44
45
|
previousExperienceStatus: 'STARTED' | 'SUCCEEDED' | 'FAILED';
|
|
45
46
|
path: string | null;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*
|
|
4
4
|
* Generates Typescript types for analytics events from analytics.spec.yaml
|
|
5
5
|
*
|
|
6
|
-
* @codegen <<SignedSource::
|
|
6
|
+
* @codegen <<SignedSource::1c67626e82d39af8e93ced7a11389f4f>>
|
|
7
7
|
* @codegenCommand yarn workspace @atlaskit/link-create run codegen-analytics
|
|
8
8
|
*/
|
|
9
9
|
export type PackageMetaDataType = {
|
|
@@ -40,6 +40,7 @@ export type ObjectCreateFailedLinkCreateAttributesType = {
|
|
|
40
40
|
};
|
|
41
41
|
export type LinkCreateExperienceFailedAttributesType = {
|
|
42
42
|
errorType: string | null;
|
|
43
|
+
errorMessage: string | null;
|
|
43
44
|
experienceStatus: 'SUCCEEDED' | 'FAILED';
|
|
44
45
|
previousExperienceStatus: 'STARTED' | 'SUCCEEDED' | 'FAILED';
|
|
45
46
|
path: string | null;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/link-create",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.13.1",
|
|
4
4
|
"description": "The driver component of meta creation flow",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -42,8 +42,8 @@
|
|
|
42
42
|
"@atlaskit/empty-state": "^7.6.0",
|
|
43
43
|
"@atlaskit/form": "^9.0.3",
|
|
44
44
|
"@atlaskit/icon": "^22.0.0",
|
|
45
|
-
"@atlaskit/intl-messages-provider": "^1.0.
|
|
46
|
-
"@atlaskit/linking-common": "^5.
|
|
45
|
+
"@atlaskit/intl-messages-provider": "^1.0.2",
|
|
46
|
+
"@atlaskit/linking-common": "^5.1.0",
|
|
47
47
|
"@atlaskit/modal-dialog": "^12.10.0",
|
|
48
48
|
"@atlaskit/platform-feature-flags": "^0.2.1",
|
|
49
49
|
"@atlaskit/primitives": "^1.15.0",
|
|
@@ -122,6 +122,12 @@
|
|
|
122
122
|
},
|
|
123
123
|
"platform.linking-platform.link-create.better-observability": {
|
|
124
124
|
"type": "boolean"
|
|
125
|
+
},
|
|
126
|
+
"platform.linking-platform.link-create.tmp-log-error-message": {
|
|
127
|
+
"type": "boolean"
|
|
128
|
+
},
|
|
129
|
+
"platform.linking-platform.link-create.tmp-fix-translations": {
|
|
130
|
+
"type": "boolean"
|
|
125
131
|
}
|
|
126
132
|
}
|
|
127
133
|
}
|