@atlaskit/editor-card-provider 6.6.17 → 6.6.18
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 +7 -0
- package/dist/cjs/provider.js +10 -2
- package/dist/es2019/provider.js +7 -2
- package/dist/esm/provider.js +10 -2
- package/package.json +4 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# @atlaskit/editor-card-provider
|
|
2
2
|
|
|
3
|
+
## 6.6.18
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`0a0e9381986bc`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/0a0e9381986bc) -
|
|
8
|
+
[ux] Default to embed appearance for Loom screenshot URLs behind feature gate
|
|
9
|
+
|
|
3
10
|
## 6.6.17
|
|
4
11
|
|
|
5
12
|
### Patch Changes
|
package/dist/cjs/provider.js
CHANGED
|
@@ -74,7 +74,7 @@ var isConfluenceDatabase = function isConfluenceDatabase(url) {
|
|
|
74
74
|
var isYoutubeVideo = function isYoutubeVideo(url) {
|
|
75
75
|
return url.match(/^https:\/\/(.*?\.)?(youtube\..*?\/(watch\?|v\/|shorts\/)|youtu\.be)/);
|
|
76
76
|
};
|
|
77
|
-
var
|
|
77
|
+
var isLoomVideoUrl = function isLoomVideoUrl(url) {
|
|
78
78
|
return url.match(
|
|
79
79
|
/*#__PURE__*/
|
|
80
80
|
// @ts-ignore - TS1503 TypeScript 5.9.2 upgrade
|
|
@@ -82,6 +82,14 @@ var isLoomUrl = function isLoomUrl(url) {
|
|
|
82
82
|
videoId: 5
|
|
83
83
|
}));
|
|
84
84
|
};
|
|
85
|
+
var isLoomScreenshotUrl = function isLoomScreenshotUrl(url) {
|
|
86
|
+
return url.match(
|
|
87
|
+
/*#__PURE__*/
|
|
88
|
+
// @ts-ignore - TS1503 TypeScript 5.9.2 upgrade
|
|
89
|
+
_wrapRegExp(/^https:\/\/(.*?\.)?loom\..*?\/i\/([a-f0-9]{32})/, {
|
|
90
|
+
id: 2
|
|
91
|
+
}));
|
|
92
|
+
};
|
|
85
93
|
var isJiraDashboard = function isJiraDashboard(url) {
|
|
86
94
|
return url.match(/^https:\/\/.*?\/jira\/dashboards\/[0-9]+.*/);
|
|
87
95
|
};
|
|
@@ -588,7 +596,7 @@ var EditorCardProvider = exports.EditorCardProvider = /*#__PURE__*/function (_re
|
|
|
588
596
|
if ((0, _platformFeatureFlags.fg)('tc_smart_link_embed_view')) {
|
|
589
597
|
isConfluenceTeamCalendarsEvaluated = isConfluenceTeamCalendars(url);
|
|
590
598
|
}
|
|
591
|
-
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isJiraList(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url) || isConfluenceDatabase(url) || isYoutubeVideo(url) ||
|
|
599
|
+
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isJiraList(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url) || isConfluenceDatabase(url) || isYoutubeVideo(url) || isLoomVideoUrl(url) || isLoomScreenshotUrl(url) && (0, _platformFeatureFlags.fg)('loom-support-screenshot-sl-resolution') || isJiraDashboard(url) || isJiraBacklog(url) || isJiraBoard(url) || isRovoAgentProfilePage(url) || isJiraVersion(url) || isJiraPlanEvaluated || isJiraFormEvaluated || isJiraSummaryEvaluated || isCustomer360LandingPage(url) || isConfluenceTeamCalendarsEvaluated || isJiraIssueNavigator(url) || isAvpVisualizationView(url) && (0, _platformFeatureFlags.fg)('avp_unfurl_shared_charts_embed_by_default_2')) {
|
|
592
600
|
return 'embed';
|
|
593
601
|
}
|
|
594
602
|
}
|
package/dist/es2019/provider.js
CHANGED
|
@@ -27,11 +27,16 @@ url.match(/\/wiki\/spaces\/?.*\/whiteboard\/(?<resourceId>\d+)(\?\/)?/) || url.m
|
|
|
27
27
|
/\/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})(\?\/)?/);
|
|
28
28
|
const isConfluenceDatabase = url => url.match(/\/wiki\/spaces\/~?[\d\w]+\/database\/\d+(\?.*)?$/);
|
|
29
29
|
const isYoutubeVideo = url => url.match(/^https:\/\/(.*?\.)?(youtube\..*?\/(watch\?|v\/|shorts\/)|youtu\.be)/);
|
|
30
|
-
const
|
|
30
|
+
const isLoomVideoUrl = url => {
|
|
31
31
|
return url.match(
|
|
32
32
|
// @ts-ignore - TS1503 TypeScript 5.9.2 upgrade
|
|
33
33
|
/^https:\/\/(.*?\.)?(loom\..*?\/(share|embed))\/([a-zA-Z0-9-]*-)?(?<videoId>[a-f0-9]{32})/);
|
|
34
34
|
};
|
|
35
|
+
const isLoomScreenshotUrl = url => {
|
|
36
|
+
return url.match(
|
|
37
|
+
// @ts-ignore - TS1503 TypeScript 5.9.2 upgrade
|
|
38
|
+
/^https:\/\/(.*?\.)?loom\..*?\/i\/(?<id>[a-f0-9]{32})/);
|
|
39
|
+
};
|
|
35
40
|
const isJiraDashboard = url => {
|
|
36
41
|
return url.match(/^https:\/\/.*?\/jira\/dashboards\/[0-9]+.*/);
|
|
37
42
|
};
|
|
@@ -297,7 +302,7 @@ export class EditorCardProvider extends NodeDataProvider {
|
|
|
297
302
|
if (fg('tc_smart_link_embed_view')) {
|
|
298
303
|
isConfluenceTeamCalendarsEvaluated = isConfluenceTeamCalendars(url);
|
|
299
304
|
}
|
|
300
|
-
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isJiraList(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url) || isConfluenceDatabase(url) || isYoutubeVideo(url) ||
|
|
305
|
+
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isJiraList(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url) || isConfluenceDatabase(url) || isYoutubeVideo(url) || isLoomVideoUrl(url) || isLoomScreenshotUrl(url) && fg('loom-support-screenshot-sl-resolution') || isJiraDashboard(url) || isJiraBacklog(url) || isJiraBoard(url) || isRovoAgentProfilePage(url) || isJiraVersion(url) || isJiraPlanEvaluated || isJiraFormEvaluated || isJiraSummaryEvaluated || isCustomer360LandingPage(url) || isConfluenceTeamCalendarsEvaluated || isJiraIssueNavigator(url) || isAvpVisualizationView(url) && fg('avp_unfurl_shared_charts_embed_by_default_2')) {
|
|
301
306
|
return 'embed';
|
|
302
307
|
}
|
|
303
308
|
}
|
package/dist/esm/provider.js
CHANGED
|
@@ -66,7 +66,7 @@ var isConfluenceDatabase = function isConfluenceDatabase(url) {
|
|
|
66
66
|
var isYoutubeVideo = function isYoutubeVideo(url) {
|
|
67
67
|
return url.match(/^https:\/\/(.*?\.)?(youtube\..*?\/(watch\?|v\/|shorts\/)|youtu\.be)/);
|
|
68
68
|
};
|
|
69
|
-
var
|
|
69
|
+
var isLoomVideoUrl = function isLoomVideoUrl(url) {
|
|
70
70
|
return url.match(
|
|
71
71
|
/*#__PURE__*/
|
|
72
72
|
// @ts-ignore - TS1503 TypeScript 5.9.2 upgrade
|
|
@@ -74,6 +74,14 @@ var isLoomUrl = function isLoomUrl(url) {
|
|
|
74
74
|
videoId: 5
|
|
75
75
|
}));
|
|
76
76
|
};
|
|
77
|
+
var isLoomScreenshotUrl = function isLoomScreenshotUrl(url) {
|
|
78
|
+
return url.match(
|
|
79
|
+
/*#__PURE__*/
|
|
80
|
+
// @ts-ignore - TS1503 TypeScript 5.9.2 upgrade
|
|
81
|
+
_wrapRegExp(/^https:\/\/(.*?\.)?loom\..*?\/i\/([a-f0-9]{32})/, {
|
|
82
|
+
id: 2
|
|
83
|
+
}));
|
|
84
|
+
};
|
|
77
85
|
var isJiraDashboard = function isJiraDashboard(url) {
|
|
78
86
|
return url.match(/^https:\/\/.*?\/jira\/dashboards\/[0-9]+.*/);
|
|
79
87
|
};
|
|
@@ -580,7 +588,7 @@ export var EditorCardProvider = /*#__PURE__*/function (_ref) {
|
|
|
580
588
|
if (fg('tc_smart_link_embed_view')) {
|
|
581
589
|
isConfluenceTeamCalendarsEvaluated = isConfluenceTeamCalendars(url);
|
|
582
590
|
}
|
|
583
|
-
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isJiraList(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url) || isConfluenceDatabase(url) || isYoutubeVideo(url) ||
|
|
591
|
+
if (isJiraRoadmapOrTimeline(url) || isPolarisView(url) || isJwmView(url) || isJiraList(url) || isGiphyMedia(url) || isProformaView(url) || isConfluenceWhiteboard(url) || isConfluenceDatabase(url) || isYoutubeVideo(url) || isLoomVideoUrl(url) || isLoomScreenshotUrl(url) && fg('loom-support-screenshot-sl-resolution') || isJiraDashboard(url) || isJiraBacklog(url) || isJiraBoard(url) || isRovoAgentProfilePage(url) || isJiraVersion(url) || isJiraPlanEvaluated || isJiraFormEvaluated || isJiraSummaryEvaluated || isCustomer360LandingPage(url) || isConfluenceTeamCalendarsEvaluated || isJiraIssueNavigator(url) || isAvpVisualizationView(url) && fg('avp_unfurl_shared_charts_embed_by_default_2')) {
|
|
584
592
|
return 'embed';
|
|
585
593
|
}
|
|
586
594
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-card-provider",
|
|
3
|
-
"version": "6.6.
|
|
3
|
+
"version": "6.6.18",
|
|
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",
|
|
@@ -62,6 +62,9 @@
|
|
|
62
62
|
},
|
|
63
63
|
"avp_unfurl_shared_charts_embed_by_default_2": {
|
|
64
64
|
"type": "boolean"
|
|
65
|
+
},
|
|
66
|
+
"loom-support-screenshot-sl-resolution": {
|
|
67
|
+
"type": "boolean"
|
|
65
68
|
}
|
|
66
69
|
},
|
|
67
70
|
"compassUnitTestMetricSourceId": "ari:cloud:compass:a436116f-02ce-4520-8fbb-7301462a1674:metric-source/c5751cc6-3513-4070-9deb-af31e86aed34/e145f3e3-514b-410f-a274-a92e6e6f9c47"
|