@atlaskit/editor-plugin-media-insert 25.0.7 → 25.0.8
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
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-media-insert
|
|
2
2
|
|
|
3
|
+
## 25.0.8
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`8e5e159447746`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/8e5e159447746) -
|
|
8
|
+
Clean up prefer static regex violations
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
3
11
|
## 25.0.7
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
|
@@ -32,6 +32,9 @@ var _excluded = ["value", "onChange"];
|
|
|
32
32
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t2 in e) "default" !== _t2 && {}.hasOwnProperty.call(e, _t2) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t2)) && (i.get || i.set) ? o(f, _t2, i) : f[_t2] = e[_t2]); return f; })(e, t); }
|
|
33
33
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
34
34
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } // eslint-disable-next-line @atlaskit/design-system/no-emotion-primitives -- to be migrated to @atlaskit/primitives/compiled – go/akcss
|
|
35
|
+
// Ignored via go/ees005
|
|
36
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
37
|
+
var WHITESPACE_REGEX = /\s/;
|
|
35
38
|
var PreviewBoxStyles = (0, _primitives.xcss)({
|
|
36
39
|
borderWidth: 'border.width',
|
|
37
40
|
borderStyle: 'dashed',
|
|
@@ -61,9 +64,7 @@ var MAX_URL_LENGTH = 2048;
|
|
|
61
64
|
var isValidUrl = exports.isValidUrl = function isValidUrl(value) {
|
|
62
65
|
try {
|
|
63
66
|
// Check for spaces and length first to avoid the expensive URL parsing
|
|
64
|
-
|
|
65
|
-
// eslint-disable-next-line require-unicode-regexp
|
|
66
|
-
if (/\s/.test(value) || value.length > MAX_URL_LENGTH) {
|
|
67
|
+
if (WHITESPACE_REGEX.test(value) || value.length > MAX_URL_LENGTH) {
|
|
67
68
|
return false;
|
|
68
69
|
}
|
|
69
70
|
new URL(value);
|
|
@@ -15,6 +15,10 @@ import SectionMessage from '@atlaskit/section-message';
|
|
|
15
15
|
import TextField from '@atlaskit/textfield';
|
|
16
16
|
import { MediaCard } from './MediaCard';
|
|
17
17
|
import { useAnalyticsEvents } from './useAnalyticsEvents';
|
|
18
|
+
|
|
19
|
+
// Ignored via go/ees005
|
|
20
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
21
|
+
const WHITESPACE_REGEX = /\s/;
|
|
18
22
|
const PreviewBoxStyles = xcss({
|
|
19
23
|
borderWidth: 'border.width',
|
|
20
24
|
borderStyle: 'dashed',
|
|
@@ -44,9 +48,7 @@ const MAX_URL_LENGTH = 2048;
|
|
|
44
48
|
export const isValidUrl = value => {
|
|
45
49
|
try {
|
|
46
50
|
// Check for spaces and length first to avoid the expensive URL parsing
|
|
47
|
-
|
|
48
|
-
// eslint-disable-next-line require-unicode-regexp
|
|
49
|
-
if (/\s/.test(value) || value.length > MAX_URL_LENGTH) {
|
|
51
|
+
if (WHITESPACE_REGEX.test(value) || value.length > MAX_URL_LENGTH) {
|
|
50
52
|
return false;
|
|
51
53
|
}
|
|
52
54
|
new URL(value);
|
|
@@ -23,6 +23,10 @@ import SectionMessage from '@atlaskit/section-message';
|
|
|
23
23
|
import TextField from '@atlaskit/textfield';
|
|
24
24
|
import { MediaCard } from './MediaCard';
|
|
25
25
|
import { useAnalyticsEvents } from './useAnalyticsEvents';
|
|
26
|
+
|
|
27
|
+
// Ignored via go/ees005
|
|
28
|
+
// eslint-disable-next-line require-unicode-regexp
|
|
29
|
+
var WHITESPACE_REGEX = /\s/;
|
|
26
30
|
var PreviewBoxStyles = xcss({
|
|
27
31
|
borderWidth: 'border.width',
|
|
28
32
|
borderStyle: 'dashed',
|
|
@@ -52,9 +56,7 @@ var MAX_URL_LENGTH = 2048;
|
|
|
52
56
|
export var isValidUrl = function isValidUrl(value) {
|
|
53
57
|
try {
|
|
54
58
|
// Check for spaces and length first to avoid the expensive URL parsing
|
|
55
|
-
|
|
56
|
-
// eslint-disable-next-line require-unicode-regexp
|
|
57
|
-
if (/\s/.test(value) || value.length > MAX_URL_LENGTH) {
|
|
59
|
+
if (WHITESPACE_REGEX.test(value) || value.length > MAX_URL_LENGTH) {
|
|
58
60
|
return false;
|
|
59
61
|
}
|
|
60
62
|
new URL(value);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-media-insert",
|
|
3
|
-
"version": "25.0.
|
|
3
|
+
"version": "25.0.8",
|
|
4
4
|
"description": "Media Insert plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -38,11 +38,11 @@
|
|
|
38
38
|
"@atlaskit/section-message": "^9.0.0",
|
|
39
39
|
"@atlaskit/tabs": "^20.0.0",
|
|
40
40
|
"@atlaskit/textfield": "^9.0.0",
|
|
41
|
-
"@atlaskit/tmp-editor-statsig": "^109.
|
|
41
|
+
"@atlaskit/tmp-editor-statsig": "^109.1.0",
|
|
42
42
|
"@babel/runtime": "^7.0.0"
|
|
43
43
|
},
|
|
44
44
|
"peerDependencies": {
|
|
45
|
-
"@atlaskit/editor-common": "^116.
|
|
45
|
+
"@atlaskit/editor-common": "^116.8.0",
|
|
46
46
|
"@atlaskit/tokens": "^14.0.0",
|
|
47
47
|
"react": "^18.2.0",
|
|
48
48
|
"react-dom": "^18.2.0",
|