@atlaskit/editor-common 110.16.3 → 110.17.0
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/monitoring/error.js +1 -1
- package/dist/cjs/transforms/sync-block.js +14 -0
- package/dist/cjs/ui/DropList/index.js +1 -1
- package/dist/es2019/monitoring/error.js +1 -1
- package/dist/es2019/transforms/sync-block.js +14 -0
- package/dist/es2019/ui/DropList/index.js +1 -1
- package/dist/esm/monitoring/error.js +1 -1
- package/dist/esm/transforms/sync-block.js +14 -0
- package/dist/esm/ui/DropList/index.js +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# @atlaskit/editor-common
|
|
2
2
|
|
|
3
|
+
## 110.17.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`991e0a08a6318`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/991e0a08a6318) -
|
|
8
|
+
EDITOR-2436 Source Block copy should convert to Reference sync block on paste
|
|
9
|
+
|
|
3
10
|
## 110.16.3
|
|
4
11
|
|
|
5
12
|
### Patch Changes
|
|
@@ -16,7 +16,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
16
16
|
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 _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
17
17
|
var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
|
|
18
18
|
var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
|
|
19
|
-
var packageVersion = "110.16.
|
|
19
|
+
var packageVersion = "110.16.3";
|
|
20
20
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
21
21
|
// Remove URL as it has UGC
|
|
22
22
|
// Ignored via go/ees007
|
|
@@ -13,11 +13,25 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
13
13
|
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; }
|
|
14
14
|
var transformToNewReferenceSyncBlock = exports.transformToNewReferenceSyncBlock = function transformToNewReferenceSyncBlock(slice, schema) {
|
|
15
15
|
slice = (0, _slice.mapSlice)(slice, function (node) {
|
|
16
|
+
// sync blocks need a unique localId to function correctly
|
|
16
17
|
if (node.type === schema.nodes.syncBlock) {
|
|
17
18
|
var newAttrs = _objectSpread(_objectSpread({}, node.attrs), {}, {
|
|
18
19
|
localId: _adfSchema.uuid.generate()
|
|
19
20
|
});
|
|
20
21
|
return schema.nodes.syncBlock.create(newAttrs, null, (0, _toConsumableArray2.default)(node.marks));
|
|
22
|
+
} else if (node.type === schema.nodes.bodiedSyncBlock) {
|
|
23
|
+
// bodied sync blocks need a unique localId and convert to a reference sync block
|
|
24
|
+
// when converting we want to be specific about attributes and marks we carry over
|
|
25
|
+
var _newAttrs = {
|
|
26
|
+
resourceId: node.attrs.resourceId,
|
|
27
|
+
localId: _adfSchema.uuid.generate()
|
|
28
|
+
};
|
|
29
|
+
var newMarks = schema.nodes.syncBlock.markSet ? node.marks.filter(function (mark) {
|
|
30
|
+
var _schema$nodes$syncBlo;
|
|
31
|
+
return (_schema$nodes$syncBlo = schema.nodes.syncBlock.markSet) === null || _schema$nodes$syncBlo === void 0 ? void 0 : _schema$nodes$syncBlo.includes(mark.type);
|
|
32
|
+
}) : node.marks; // schema.nodes.syncBlock.markSet is null meaning all marks are allowed
|
|
33
|
+
|
|
34
|
+
return schema.nodes.syncBlock.create(_newAttrs, null, newMarks);
|
|
21
35
|
}
|
|
22
36
|
return node;
|
|
23
37
|
});
|
|
@@ -24,7 +24,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
24
24
|
* @jsx jsx
|
|
25
25
|
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
26
26
|
var packageName = "@atlaskit/editor-common";
|
|
27
|
-
var packageVersion = "110.16.
|
|
27
|
+
var packageVersion = "110.16.3";
|
|
28
28
|
var halfFocusRing = 1;
|
|
29
29
|
var dropOffset = '0, 8';
|
|
30
30
|
var fadeIn = (0, _react2.keyframes)({
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { isFedRamp } from './environment';
|
|
2
2
|
const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
|
|
3
3
|
const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
|
|
4
|
-
const packageVersion = "110.16.
|
|
4
|
+
const packageVersion = "110.16.3";
|
|
5
5
|
const sanitiseSentryEvents = (data, _hint) => {
|
|
6
6
|
// Remove URL as it has UGC
|
|
7
7
|
// Ignored via go/ees007
|
|
@@ -2,12 +2,26 @@ import { uuid } from '@atlaskit/adf-schema';
|
|
|
2
2
|
import { mapSlice } from '../utils/slice';
|
|
3
3
|
export const transformToNewReferenceSyncBlock = (slice, schema) => {
|
|
4
4
|
slice = mapSlice(slice, node => {
|
|
5
|
+
// sync blocks need a unique localId to function correctly
|
|
5
6
|
if (node.type === schema.nodes.syncBlock) {
|
|
6
7
|
const newAttrs = {
|
|
7
8
|
...node.attrs,
|
|
8
9
|
localId: uuid.generate()
|
|
9
10
|
};
|
|
10
11
|
return schema.nodes.syncBlock.create(newAttrs, null, [...node.marks]);
|
|
12
|
+
} else if (node.type === schema.nodes.bodiedSyncBlock) {
|
|
13
|
+
// bodied sync blocks need a unique localId and convert to a reference sync block
|
|
14
|
+
// when converting we want to be specific about attributes and marks we carry over
|
|
15
|
+
const newAttrs = {
|
|
16
|
+
resourceId: node.attrs.resourceId,
|
|
17
|
+
localId: uuid.generate()
|
|
18
|
+
};
|
|
19
|
+
const newMarks = schema.nodes.syncBlock.markSet ? node.marks.filter(mark => {
|
|
20
|
+
var _schema$nodes$syncBlo;
|
|
21
|
+
return (_schema$nodes$syncBlo = schema.nodes.syncBlock.markSet) === null || _schema$nodes$syncBlo === void 0 ? void 0 : _schema$nodes$syncBlo.includes(mark.type);
|
|
22
|
+
}) : node.marks; // schema.nodes.syncBlock.markSet is null meaning all marks are allowed
|
|
23
|
+
|
|
24
|
+
return schema.nodes.syncBlock.create(newAttrs, null, newMarks);
|
|
11
25
|
}
|
|
12
26
|
return node;
|
|
13
27
|
});
|
|
@@ -14,7 +14,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
|
14
14
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
15
15
|
import Layer from '../Layer';
|
|
16
16
|
const packageName = "@atlaskit/editor-common";
|
|
17
|
-
const packageVersion = "110.16.
|
|
17
|
+
const packageVersion = "110.16.3";
|
|
18
18
|
const halfFocusRing = 1;
|
|
19
19
|
const dropOffset = '0, 8';
|
|
20
20
|
const fadeIn = keyframes({
|
|
@@ -7,7 +7,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
7
7
|
import { isFedRamp } from './environment';
|
|
8
8
|
var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
|
|
9
9
|
var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
|
|
10
|
-
var packageVersion = "110.16.
|
|
10
|
+
var packageVersion = "110.16.3";
|
|
11
11
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
12
12
|
// Remove URL as it has UGC
|
|
13
13
|
// Ignored via go/ees007
|
|
@@ -6,11 +6,25 @@ import { uuid } from '@atlaskit/adf-schema';
|
|
|
6
6
|
import { mapSlice } from '../utils/slice';
|
|
7
7
|
export var transformToNewReferenceSyncBlock = function transformToNewReferenceSyncBlock(slice, schema) {
|
|
8
8
|
slice = mapSlice(slice, function (node) {
|
|
9
|
+
// sync blocks need a unique localId to function correctly
|
|
9
10
|
if (node.type === schema.nodes.syncBlock) {
|
|
10
11
|
var newAttrs = _objectSpread(_objectSpread({}, node.attrs), {}, {
|
|
11
12
|
localId: uuid.generate()
|
|
12
13
|
});
|
|
13
14
|
return schema.nodes.syncBlock.create(newAttrs, null, _toConsumableArray(node.marks));
|
|
15
|
+
} else if (node.type === schema.nodes.bodiedSyncBlock) {
|
|
16
|
+
// bodied sync blocks need a unique localId and convert to a reference sync block
|
|
17
|
+
// when converting we want to be specific about attributes and marks we carry over
|
|
18
|
+
var _newAttrs = {
|
|
19
|
+
resourceId: node.attrs.resourceId,
|
|
20
|
+
localId: uuid.generate()
|
|
21
|
+
};
|
|
22
|
+
var newMarks = schema.nodes.syncBlock.markSet ? node.marks.filter(function (mark) {
|
|
23
|
+
var _schema$nodes$syncBlo;
|
|
24
|
+
return (_schema$nodes$syncBlo = schema.nodes.syncBlock.markSet) === null || _schema$nodes$syncBlo === void 0 ? void 0 : _schema$nodes$syncBlo.includes(mark.type);
|
|
25
|
+
}) : node.marks; // schema.nodes.syncBlock.markSet is null meaning all marks are allowed
|
|
26
|
+
|
|
27
|
+
return schema.nodes.syncBlock.create(_newAttrs, null, newMarks);
|
|
14
28
|
}
|
|
15
29
|
return node;
|
|
16
30
|
});
|
|
@@ -21,7 +21,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
|
21
21
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
22
22
|
import Layer from '../Layer';
|
|
23
23
|
var packageName = "@atlaskit/editor-common";
|
|
24
|
-
var packageVersion = "110.16.
|
|
24
|
+
var packageVersion = "110.16.3";
|
|
25
25
|
var halfFocusRing = 1;
|
|
26
26
|
var dropOffset = '0, 8';
|
|
27
27
|
var fadeIn = keyframes({
|
package/package.json
CHANGED