@atlaskit/editor-card-provider 3.1.8 → 3.1.10
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 +30 -18
- package/dist/cjs/api.js +1 -2
- package/dist/cjs/environments.js +4 -8
- package/dist/cjs/provider.js +6 -5
- package/dist/cjs/transformer.js +2 -3
- package/dist/es2019/provider.js +2 -1
- package/dist/esm/provider.js +4 -1
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -1,35 +1,47 @@
|
|
|
1
1
|
# @atlaskit/editor-card-provider
|
|
2
2
|
|
|
3
|
+
## 3.1.10
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#42239](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/42239) [`3ebc0b4f999`](https://bitbucket.org/atlassian/atlassian-frontend/commits/3ebc0b4f999) - [ux] Updated default smart card view for Confluence Databases to include check for entryId and savedViewId parameters
|
|
8
|
+
|
|
9
|
+
## 3.1.9
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#40406](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/40406) [`542d0dd0b1d`](https://bitbucket.org/atlassian/atlassian-frontend/commits/542d0dd0b1d) - [ux] Changed default smart card view for Confluence Databases route from inline to embed.
|
|
14
|
+
|
|
3
15
|
## 3.1.8
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
|
6
18
|
|
|
7
|
-
- [`1fedffbd64b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/1fedffbd64b) - Update json-ld-types dependencies to be compatible with version
|
|
19
|
+
- [#40491](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/40491) [`1fedffbd64b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/1fedffbd64b) - Update json-ld-types dependencies to be compatible with version
|
|
8
20
|
|
|
9
21
|
## 3.1.7
|
|
10
22
|
|
|
11
23
|
### Patch Changes
|
|
12
24
|
|
|
13
|
-
- [`2cd7af71b63`](https://bitbucket.org/atlassian/atlassian-frontend/commits/2cd7af71b63) - Bump json-ld-types 3.8.0 -> 3.9.1
|
|
25
|
+
- [#40127](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/40127) [`2cd7af71b63`](https://bitbucket.org/atlassian/atlassian-frontend/commits/2cd7af71b63) - Bump json-ld-types 3.8.0 -> 3.9.1
|
|
14
26
|
|
|
15
27
|
## 3.1.6
|
|
16
28
|
|
|
17
29
|
### Patch Changes
|
|
18
30
|
|
|
19
|
-
- [`e74ae7f06d4`](https://bitbucket.org/atlassian/atlassian-frontend/commits/e74ae7f06d4) - Update dependency json-ld-types@3.8.0
|
|
31
|
+
- [#37720](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/37720) [`e74ae7f06d4`](https://bitbucket.org/atlassian/atlassian-frontend/commits/e74ae7f06d4) - Update dependency json-ld-types@3.8.0
|
|
20
32
|
|
|
21
33
|
## 3.1.5
|
|
22
34
|
|
|
23
35
|
### Patch Changes
|
|
24
36
|
|
|
25
|
-
- [`83f06b6e7f6`](https://bitbucket.org/atlassian/atlassian-frontend/commits/83f06b6e7f6) - Update to use 'getStatus' from '@atlaskit/linking-common'
|
|
37
|
+
- [#37136](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/37136) [`83f06b6e7f6`](https://bitbucket.org/atlassian/atlassian-frontend/commits/83f06b6e7f6) - Update to use 'getStatus' from '@atlaskit/linking-common'
|
|
26
38
|
- Updated dependencies
|
|
27
39
|
|
|
28
40
|
## 3.1.4
|
|
29
41
|
|
|
30
42
|
### Patch Changes
|
|
31
43
|
|
|
32
|
-
- [`b9355830504`](https://bitbucket.org/atlassian/atlassian-frontend/commits/b9355830504) - Opt out of peer dependency enforcement
|
|
44
|
+
- [#37340](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/37340) [`b9355830504`](https://bitbucket.org/atlassian/atlassian-frontend/commits/b9355830504) - Opt out of peer dependency enforcement
|
|
33
45
|
|
|
34
46
|
## 3.1.3
|
|
35
47
|
|
|
@@ -41,20 +53,20 @@
|
|
|
41
53
|
|
|
42
54
|
### Patch Changes
|
|
43
55
|
|
|
44
|
-
- [`3fb20c4aeba`](https://bitbucket.org/atlassian/atlassian-frontend/commits/3fb20c4aeba) - Add postinstall check to enforce internal peer dependencies
|
|
56
|
+
- [#36757](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/36757) [`3fb20c4aeba`](https://bitbucket.org/atlassian/atlassian-frontend/commits/3fb20c4aeba) - Add postinstall check to enforce internal peer dependencies
|
|
45
57
|
|
|
46
58
|
## 3.1.1
|
|
47
59
|
|
|
48
60
|
### Patch Changes
|
|
49
61
|
|
|
50
|
-
- [`1e7190077d4`](https://bitbucket.org/atlassian/atlassian-frontend/commits/1e7190077d4) - Move off deprecated @atlaskit/linking-common/extractors to @atlaskit/link-extractors
|
|
62
|
+
- [#36089](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/36089) [`1e7190077d4`](https://bitbucket.org/atlassian/atlassian-frontend/commits/1e7190077d4) - Move off deprecated @atlaskit/linking-common/extractors to @atlaskit/link-extractors
|
|
51
63
|
- Updated dependencies
|
|
52
64
|
|
|
53
65
|
## 3.1.0
|
|
54
66
|
|
|
55
67
|
### Minor Changes
|
|
56
68
|
|
|
57
|
-
- [`04295e9d5bc`](https://bitbucket.org/atlassian/atlassian-frontend/commits/04295e9d5bc) - [ux] Updating ORS response to include datasources and facilitating pasting JQL links turning into datasource tables
|
|
69
|
+
- [#35032](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/35032) [`04295e9d5bc`](https://bitbucket.org/atlassian/atlassian-frontend/commits/04295e9d5bc) - [ux] Updating ORS response to include datasources and facilitating pasting JQL links turning into datasource tables
|
|
58
70
|
|
|
59
71
|
### Patch Changes
|
|
60
72
|
|
|
@@ -70,34 +82,34 @@
|
|
|
70
82
|
|
|
71
83
|
### Patch Changes
|
|
72
84
|
|
|
73
|
-
- [`1674b5907b4`](https://bitbucket.org/atlassian/atlassian-frontend/commits/1674b5907b4) - [ux] Make confluence whiteboard urls default to embed view
|
|
85
|
+
- [#35428](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/35428) [`1674b5907b4`](https://bitbucket.org/atlassian/atlassian-frontend/commits/1674b5907b4) - [ux] Make confluence whiteboard urls default to embed view
|
|
74
86
|
|
|
75
87
|
## 3.0.3
|
|
76
88
|
|
|
77
89
|
### Patch Changes
|
|
78
90
|
|
|
79
|
-
- [`f10ed88032c`](https://bitbucket.org/atlassian/atlassian-frontend/commits/f10ed88032c) - With the renaming of Jira Roadmaps to Timeline, we are updating the regex rules to match timeline in conjunction to roadmaps
|
|
91
|
+
- [#33699](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33699) [`f10ed88032c`](https://bitbucket.org/atlassian/atlassian-frontend/commits/f10ed88032c) - With the renaming of Jira Roadmaps to Timeline, we are updating the regex rules to match timeline in conjunction to roadmaps
|
|
80
92
|
- Updated dependencies
|
|
81
93
|
|
|
82
94
|
## 3.0.2
|
|
83
95
|
|
|
84
96
|
### Patch Changes
|
|
85
97
|
|
|
86
|
-
- [`9d00501a414`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9d00501a414) - Ensure legacy types are published for TS 4.5-4.8
|
|
98
|
+
- [#33793](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33793) [`9d00501a414`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9d00501a414) - Ensure legacy types are published for TS 4.5-4.8
|
|
87
99
|
- Updated dependencies
|
|
88
100
|
|
|
89
101
|
## 3.0.1
|
|
90
102
|
|
|
91
103
|
### Patch Changes
|
|
92
104
|
|
|
93
|
-
- [`41fae2c6f68`](https://bitbucket.org/atlassian/atlassian-frontend/commits/41fae2c6f68) - Upgrade Typescript from `4.5.5` to `4.9.5`
|
|
105
|
+
- [#33649](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33649) [`41fae2c6f68`](https://bitbucket.org/atlassian/atlassian-frontend/commits/41fae2c6f68) - Upgrade Typescript from `4.5.5` to `4.9.5`
|
|
94
106
|
- Updated dependencies
|
|
95
107
|
|
|
96
108
|
## 3.0.0
|
|
97
109
|
|
|
98
110
|
### Minor Changes
|
|
99
111
|
|
|
100
|
-
- [`56507598609`](https://bitbucket.org/atlassian/atlassian-frontend/commits/56507598609) - Skip minor dependency bump
|
|
112
|
+
- [#33258](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33258) [`56507598609`](https://bitbucket.org/atlassian/atlassian-frontend/commits/56507598609) - Skip minor dependency bump
|
|
101
113
|
|
|
102
114
|
### Patch Changes
|
|
103
115
|
|
|
@@ -107,28 +119,28 @@
|
|
|
107
119
|
|
|
108
120
|
### Patch Changes
|
|
109
121
|
|
|
110
|
-
- [`0624df1ffe1`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0624df1ffe1) - Bump json-ld-types dependency
|
|
122
|
+
- [#32541](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/32541) [`0624df1ffe1`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0624df1ffe1) - Bump json-ld-types dependency
|
|
111
123
|
- Updated dependencies
|
|
112
124
|
|
|
113
125
|
## 2.0.3
|
|
114
126
|
|
|
115
127
|
### Patch Changes
|
|
116
128
|
|
|
117
|
-
- [`2e01c9c74b5`](https://bitbucket.org/atlassian/atlassian-frontend/commits/2e01c9c74b5) - DUMMY remove before merging to master; dupe adf-schema via adf-utils
|
|
129
|
+
- [#32424](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/32424) [`2e01c9c74b5`](https://bitbucket.org/atlassian/atlassian-frontend/commits/2e01c9c74b5) - DUMMY remove before merging to master; dupe adf-schema via adf-utils
|
|
118
130
|
- Updated dependencies
|
|
119
131
|
|
|
120
132
|
## 2.0.2
|
|
121
133
|
|
|
122
134
|
### Patch Changes
|
|
123
135
|
|
|
124
|
-
- [`0ee9370595a`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0ee9370595a) - Update json-ld-types
|
|
136
|
+
- [#32360](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/32360) [`0ee9370595a`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0ee9370595a) - Update json-ld-types
|
|
125
137
|
- Updated dependencies
|
|
126
138
|
|
|
127
139
|
## 2.0.1
|
|
128
140
|
|
|
129
141
|
### Patch Changes
|
|
130
142
|
|
|
131
|
-
- [`0af4a6b6426`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0af4a6b6426) - Dependency update json-ld-types@3.4.0
|
|
143
|
+
- [#31388](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/31388) [`0af4a6b6426`](https://bitbucket.org/atlassian/atlassian-frontend/commits/0af4a6b6426) - Dependency update json-ld-types@3.4.0
|
|
132
144
|
- Updated dependencies
|
|
133
145
|
|
|
134
146
|
## 2.0.0
|
|
@@ -141,7 +153,7 @@
|
|
|
141
153
|
|
|
142
154
|
### Major Changes
|
|
143
155
|
|
|
144
|
-
- [`12223b3ee04`](https://bitbucket.org/atlassian/atlassian-frontend/commits/12223b3ee04) - Move EditorCardProvider to new package instead of using imports from Link Provider and Smart Card
|
|
156
|
+
- [#30266](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/30266) [`12223b3ee04`](https://bitbucket.org/atlassian/atlassian-frontend/commits/12223b3ee04) - Move EditorCardProvider to new package instead of using imports from Link Provider and Smart Card
|
|
145
157
|
|
|
146
158
|
### Patch Changes
|
|
147
159
|
|
package/dist/cjs/api.js
CHANGED
|
@@ -20,7 +20,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
20
20
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
21
21
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
22
22
|
var ALLOWED_RESPONSE_STATUS_CODES = [200, 401, 404];
|
|
23
|
-
var NetworkError = /*#__PURE__*/function (_Error) {
|
|
23
|
+
var NetworkError = exports.NetworkError = /*#__PURE__*/function (_Error) {
|
|
24
24
|
(0, _inherits2.default)(NetworkError, _Error);
|
|
25
25
|
var _super = _createSuper(NetworkError);
|
|
26
26
|
function NetworkError(error) {
|
|
@@ -31,7 +31,6 @@ var NetworkError = /*#__PURE__*/function (_Error) {
|
|
|
31
31
|
}( /*#__PURE__*/(0, _wrapNativeSuper2.default)(Error)); // NOTE: This is copied from @atlaskit/link-provider as we are in the middle of a deprecation.
|
|
32
32
|
// To read more, see https://hello.atlassian.net/browse/ENGHEALTH-661
|
|
33
33
|
// Also: https://product-fabric.atlassian.net/browse/EDM-5755
|
|
34
|
-
exports.NetworkError = NetworkError;
|
|
35
34
|
function request(_x, _x2, _x3, _x4) {
|
|
36
35
|
return _request.apply(this, arguments);
|
|
37
36
|
}
|
package/dist/cjs/environments.js
CHANGED
|
@@ -10,7 +10,7 @@ exports.getResolverUrl = exports.getBaseUrl = exports.default = exports.BaseUrls
|
|
|
10
10
|
var devBaseUrl = 'https://api-private.dev.atlassian.com';
|
|
11
11
|
var stgBaseUrl = 'https://pug.jira-dev.com/gateway/api';
|
|
12
12
|
var prodBaseUrl = 'https://api-private.atlassian.com';
|
|
13
|
-
var BaseUrls = {
|
|
13
|
+
var BaseUrls = exports.BaseUrls = {
|
|
14
14
|
dev: devBaseUrl,
|
|
15
15
|
development: devBaseUrl,
|
|
16
16
|
stg: stgBaseUrl,
|
|
@@ -19,8 +19,7 @@ var BaseUrls = {
|
|
|
19
19
|
prod: prodBaseUrl,
|
|
20
20
|
production: prodBaseUrl
|
|
21
21
|
};
|
|
22
|
-
exports.
|
|
23
|
-
var getBaseUrl = function getBaseUrl(envKey) {
|
|
22
|
+
var getBaseUrl = exports.getBaseUrl = function getBaseUrl(envKey) {
|
|
24
23
|
// If an environment is provided, then use Stargate.
|
|
25
24
|
if (envKey) {
|
|
26
25
|
return envKey in BaseUrls ? BaseUrls[envKey] : prodBaseUrl;
|
|
@@ -29,8 +28,7 @@ var getBaseUrl = function getBaseUrl(envKey) {
|
|
|
29
28
|
// Otherwise, use the current origin of the page.
|
|
30
29
|
return window.location.origin;
|
|
31
30
|
};
|
|
32
|
-
exports.
|
|
33
|
-
var getResolverUrl = function getResolverUrl(envKey, baseUrlOverride) {
|
|
31
|
+
var getResolverUrl = exports.getResolverUrl = function getResolverUrl(envKey, baseUrlOverride) {
|
|
34
32
|
// If an environment is provided, then use Stargate directly for requests.
|
|
35
33
|
if (envKey || baseUrlOverride) {
|
|
36
34
|
var baseUrl = baseUrlOverride || getBaseUrl(envKey);
|
|
@@ -41,6 +39,4 @@ var getResolverUrl = function getResolverUrl(envKey, baseUrlOverride) {
|
|
|
41
39
|
return '/gateway/api/object-resolver';
|
|
42
40
|
}
|
|
43
41
|
};
|
|
44
|
-
exports.
|
|
45
|
-
var _default = BaseUrls;
|
|
46
|
-
exports.default = _default;
|
|
42
|
+
var _default = exports.default = BaseUrls;
|
package/dist/cjs/provider.js
CHANGED
|
@@ -51,7 +51,10 @@ var isConfluenceWhiteboard = function isConfluenceWhiteboard(url) {
|
|
|
51
51
|
resourceId: 1
|
|
52
52
|
}));
|
|
53
53
|
};
|
|
54
|
-
var
|
|
54
|
+
var isConfluenceDatabase = function isConfluenceDatabase(url) {
|
|
55
|
+
return url.match(/\/wiki\/spaces\/~?[\d\w]+\/database\/\d+(\?.*(savedViewId=[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}|entryId=[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}).*)?$/);
|
|
56
|
+
};
|
|
57
|
+
var EditorCardProvider = exports.EditorCardProvider = /*#__PURE__*/function () {
|
|
55
58
|
function EditorCardProvider(envKey, baseUrlOverride) {
|
|
56
59
|
var _this = this;
|
|
57
60
|
(0, _classCallCheck2.default)(this, EditorCardProvider);
|
|
@@ -320,7 +323,7 @@ var EditorCardProvider = /*#__PURE__*/function () {
|
|
|
320
323
|
}, {
|
|
321
324
|
key: "getHardCodedAppearance",
|
|
322
325
|
value: function getHardCodedAppearance(url) {
|
|
323
|
-
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url)) {
|
|
326
|
+
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url) || isConfluenceDatabase(url)) {
|
|
324
327
|
return 'embed';
|
|
325
328
|
}
|
|
326
329
|
}
|
|
@@ -525,6 +528,4 @@ var EditorCardProvider = /*#__PURE__*/function () {
|
|
|
525
528
|
}]);
|
|
526
529
|
return EditorCardProvider;
|
|
527
530
|
}();
|
|
528
|
-
exports.
|
|
529
|
-
var editorCardProvider = new EditorCardProvider();
|
|
530
|
-
exports.editorCardProvider = editorCardProvider;
|
|
531
|
+
var editorCardProvider = exports.editorCardProvider = new EditorCardProvider();
|
package/dist/cjs/transformer.js
CHANGED
|
@@ -7,7 +7,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.Transformer = void 0;
|
|
8
8
|
var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
|
|
9
9
|
var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
|
|
10
|
-
var Transformer = /*#__PURE__*/function () {
|
|
10
|
+
var Transformer = exports.Transformer = /*#__PURE__*/function () {
|
|
11
11
|
function Transformer() {
|
|
12
12
|
(0, _classCallCheck2.default)(this, Transformer);
|
|
13
13
|
}
|
|
@@ -72,5 +72,4 @@ var Transformer = /*#__PURE__*/function () {
|
|
|
72
72
|
}
|
|
73
73
|
}]);
|
|
74
74
|
return Transformer;
|
|
75
|
-
}();
|
|
76
|
-
exports.Transformer = Transformer;
|
|
75
|
+
}();
|
package/dist/es2019/provider.js
CHANGED
|
@@ -18,6 +18,7 @@ const isJwmView = url => url.match(/^https:\/\/.*?\/jira\/core\/projects\/[^\/]+
|
|
|
18
18
|
const isGiphyMedia = url => url.match(/^https:\/\/(.*?\.)?giphy\.com\/(gifs|media|clips)\//);
|
|
19
19
|
const isProformaView = url => url.match(/^https:\/\/[^/]+\/jira\/(core|software(\/c)?|servicedesk)\/projects\/\w+\/forms\/form\/direct\/\d+\/\d+.*$/);
|
|
20
20
|
const isConfluenceWhiteboard = url => url.match(/\/wiki\/spaces\/?.*\/whiteboard\/(?<resourceId>\d+)(\?\/)?/) || url.match(/\/wiki\/spaces\/?.*\/whiteboard\/(?<resourceId>[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12})(\?\/)?/);
|
|
21
|
+
const isConfluenceDatabase = url => url.match(/\/wiki\/spaces\/~?[\d\w]+\/database\/\d+(\?.*(savedViewId=[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}|entryId=[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}).*)?$/);
|
|
21
22
|
export class EditorCardProvider {
|
|
22
23
|
constructor(envKey, baseUrlOverride) {
|
|
23
24
|
this.baseUrl = baseUrlOverride || getBaseUrl(envKey);
|
|
@@ -109,7 +110,7 @@ export class EditorCardProvider {
|
|
|
109
110
|
return (_this$providersData2 = this.providersData) === null || _this$providersData2 === void 0 ? void 0 : _this$providersData2.patterns.find(pattern => url.match(pattern.source));
|
|
110
111
|
}
|
|
111
112
|
getHardCodedAppearance(url) {
|
|
112
|
-
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url)) {
|
|
113
|
+
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url) || isConfluenceDatabase(url)) {
|
|
113
114
|
return 'embed';
|
|
114
115
|
}
|
|
115
116
|
}
|
package/dist/esm/provider.js
CHANGED
|
@@ -43,6 +43,9 @@ var isConfluenceWhiteboard = function isConfluenceWhiteboard(url) {
|
|
|
43
43
|
resourceId: 1
|
|
44
44
|
}));
|
|
45
45
|
};
|
|
46
|
+
var isConfluenceDatabase = function isConfluenceDatabase(url) {
|
|
47
|
+
return url.match(/\/wiki\/spaces\/~?[\d\w]+\/database\/\d+(\?.*(savedViewId=[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}|entryId=[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}).*)?$/);
|
|
48
|
+
};
|
|
46
49
|
export var EditorCardProvider = /*#__PURE__*/function () {
|
|
47
50
|
function EditorCardProvider(envKey, baseUrlOverride) {
|
|
48
51
|
var _this = this;
|
|
@@ -312,7 +315,7 @@ export var EditorCardProvider = /*#__PURE__*/function () {
|
|
|
312
315
|
}, {
|
|
313
316
|
key: "getHardCodedAppearance",
|
|
314
317
|
value: function getHardCodedAppearance(url) {
|
|
315
|
-
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url)) {
|
|
318
|
+
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url) || isConfluenceDatabase(url)) {
|
|
316
319
|
return 'embed';
|
|
317
320
|
}
|
|
318
321
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-card-provider",
|
|
3
|
-
"version": "3.1.
|
|
3
|
+
"version": "3.1.10",
|
|
4
4
|
"description": "Contains the EditorCardProvider, for determining smart card behaviour in the editor.",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -35,8 +35,8 @@
|
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
37
|
"@atlaskit/link-client-extension": "^1.7.0",
|
|
38
|
-
"@atlaskit/link-extractors": "^1.
|
|
39
|
-
"@atlaskit/linking-common": "^4.
|
|
38
|
+
"@atlaskit/link-extractors": "^1.2.0",
|
|
39
|
+
"@atlaskit/linking-common": "^4.12.0",
|
|
40
40
|
"@babel/runtime": "^7.0.0",
|
|
41
41
|
"dataloader": "^2.0.0",
|
|
42
42
|
"json-ld-types": "^3.9.1",
|