@atlaskit/editor-common 126.2.1 → 126.2.2

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,11 @@
1
1
  # @atlaskit/editor-common
2
2
 
3
+ ## 126.2.2
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
3
9
  ## 126.2.1
4
10
 
5
11
  ### Patch Changes
@@ -45,11 +45,11 @@ function createParagraphAtEnd() {
45
45
  };
46
46
  }
47
47
 
48
- // Remove this when cleaning up platform_editor_toolbar_aifc
49
48
  // eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
50
49
  /**
50
+ * Command-based image alignment retained for legacy alignment call sites.
51
51
  *
52
- * @deprecated use changeImageAlignmentTr instead
52
+ * @deprecated use changeImageAlignmentNext instead
53
53
  */
54
54
  var changeImageAlignment = exports.changeImageAlignment = function changeImageAlignment(align) {
55
55
  return function (state, dispatch) {
@@ -96,9 +96,9 @@ var changeImageAlignmentNext = exports.changeImageAlignmentNext = function chang
96
96
  };
97
97
  };
98
98
 
99
- // Remove this when cleaning up platform_editor_toolbar_aifc
100
99
  // eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
101
100
  /**
101
+ * Command-based block-mark updates retained for media linking and toggleBlockMark.
102
102
  *
103
103
  * @deprecated use createToggleBlockMarkOnRangeNext instead, which does not require passing editorState
104
104
  */
@@ -181,15 +181,16 @@ var createToggleInlineMarkOnRange = exports.createToggleInlineMarkOnRange = func
181
181
  };
182
182
  };
183
183
 
184
- // Remove this when cleaning up platform_editor_toolbar_aifc
185
184
  // eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
186
185
  /**
187
- * @deprecated use toggleBlockMarkTr instead
188
186
  * Toggles block mark based on the return type of `getAttrs`.
189
187
  * This is similar to ProseMirror's `getAttrs` from `AttributeSpec`
190
188
  * return `false` to remove the mark.
191
- * return `undefined for no-op.
189
+ * return `undefined` for no-op.
192
190
  * return an `object` to update the mark.
191
+ * Retained for Command-based alignment and indentation paths.
192
+ *
193
+ * @deprecated use toggleBlockMarkNext instead
193
194
  */
194
195
  var toggleBlockMark = exports.toggleBlockMark = function toggleBlockMark(markType, getAttrs, allowedBlocks) {
195
196
  return function (state, dispatch) {
@@ -27,7 +27,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
27
27
  var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
28
28
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
29
29
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
30
- var packageVersion = "126.2.0";
30
+ var packageVersion = "126.2.1";
31
31
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
32
32
  // Remove URL as it has UGC
33
33
  // Ignored via go/ees007
@@ -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 = "126.2.0";
27
+ var packageVersion = "126.2.1";
28
28
  var halfFocusRing = 1;
29
29
  var dropOffset = '0, 8';
30
30
  var fadeIn = (0, _react2.keyframes)({
@@ -36,11 +36,11 @@ export function createParagraphAtEnd() {
36
36
  };
37
37
  }
38
38
 
39
- // Remove this when cleaning up platform_editor_toolbar_aifc
40
39
  // eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
41
40
  /**
41
+ * Command-based image alignment retained for legacy alignment call sites.
42
42
  *
43
- * @deprecated use changeImageAlignmentTr instead
43
+ * @deprecated use changeImageAlignmentNext instead
44
44
  */
45
45
  export const changeImageAlignment = align => (state, dispatch) => {
46
46
  const {
@@ -87,9 +87,9 @@ export const changeImageAlignmentNext = align => tr => {
87
87
  return false;
88
88
  };
89
89
 
90
- // Remove this when cleaning up platform_editor_toolbar_aifc
91
90
  // eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
92
91
  /**
92
+ * Command-based block-mark updates retained for media linking and toggleBlockMark.
93
93
  *
94
94
  * @deprecated use createToggleBlockMarkOnRangeNext instead, which does not require passing editorState
95
95
  */
@@ -154,15 +154,16 @@ export const createToggleInlineMarkOnRange = (markType, getAttrs) => (from, to,
154
154
  return markApplied;
155
155
  };
156
156
 
157
- // Remove this when cleaning up platform_editor_toolbar_aifc
158
157
  // eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
159
158
  /**
160
- * @deprecated use toggleBlockMarkTr instead
161
159
  * Toggles block mark based on the return type of `getAttrs`.
162
160
  * This is similar to ProseMirror's `getAttrs` from `AttributeSpec`
163
161
  * return `false` to remove the mark.
164
- * return `undefined for no-op.
162
+ * return `undefined` for no-op.
165
163
  * return an `object` to update the mark.
164
+ * Retained for Command-based alignment and indentation paths.
165
+ *
166
+ * @deprecated use toggleBlockMarkNext instead
166
167
  */
167
168
  export const toggleBlockMark = (markType, getAttrs, allowedBlocks) => (state, dispatch) => {
168
169
  let markApplied = false;
@@ -13,7 +13,7 @@ const NETWORK_FAILURE_REGEX = /^network failure/i;
13
13
  const RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
14
14
  const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
15
15
  const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
16
- const packageVersion = "126.2.0";
16
+ const packageVersion = "126.2.1";
17
17
  const sanitiseSentryEvents = (data, _hint) => {
18
18
  // Remove URL as it has UGC
19
19
  // Ignored via go/ees007
@@ -14,7 +14,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
14
14
  import { fg } from '@atlaskit/platform-feature-flags/fg';
15
15
  import Layer from '../Layer';
16
16
  const packageName = "@atlaskit/editor-common";
17
- const packageVersion = "126.2.0";
17
+ const packageVersion = "126.2.1";
18
18
  const halfFocusRing = 1;
19
19
  const dropOffset = '0, 8';
20
20
  const fadeIn = keyframes({
@@ -27,11 +27,11 @@ export function createParagraphAtEnd() {
27
27
  };
28
28
  }
29
29
 
30
- // Remove this when cleaning up platform_editor_toolbar_aifc
31
30
  // eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
32
31
  /**
32
+ * Command-based image alignment retained for legacy alignment call sites.
33
33
  *
34
- * @deprecated use changeImageAlignmentTr instead
34
+ * @deprecated use changeImageAlignmentNext instead
35
35
  */
36
36
  export var changeImageAlignment = function changeImageAlignment(align) {
37
37
  return function (state, dispatch) {
@@ -78,9 +78,9 @@ export var changeImageAlignmentNext = function changeImageAlignmentNext(align) {
78
78
  };
79
79
  };
80
80
 
81
- // Remove this when cleaning up platform_editor_toolbar_aifc
82
81
  // eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
83
82
  /**
83
+ * Command-based block-mark updates retained for media linking and toggleBlockMark.
84
84
  *
85
85
  * @deprecated use createToggleBlockMarkOnRangeNext instead, which does not require passing editorState
86
86
  */
@@ -163,15 +163,16 @@ export var createToggleInlineMarkOnRange = function createToggleInlineMarkOnRang
163
163
  };
164
164
  };
165
165
 
166
- // Remove this when cleaning up platform_editor_toolbar_aifc
167
166
  // eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
168
167
  /**
169
- * @deprecated use toggleBlockMarkTr instead
170
168
  * Toggles block mark based on the return type of `getAttrs`.
171
169
  * This is similar to ProseMirror's `getAttrs` from `AttributeSpec`
172
170
  * return `false` to remove the mark.
173
- * return `undefined for no-op.
171
+ * return `undefined` for no-op.
174
172
  * return an `object` to update the mark.
173
+ * Retained for Command-based alignment and indentation paths.
174
+ *
175
+ * @deprecated use toggleBlockMarkNext instead
175
176
  */
176
177
  export var toggleBlockMark = function toggleBlockMark(markType, getAttrs, allowedBlocks) {
177
178
  return function (state, dispatch) {
@@ -19,7 +19,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
19
19
  var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
20
20
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
21
21
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
22
- var packageVersion = "126.2.0";
22
+ var packageVersion = "126.2.1";
23
23
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
24
24
  // Remove URL as it has UGC
25
25
  // Ignored via go/ees007
@@ -21,7 +21,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
21
21
  import { fg } from '@atlaskit/platform-feature-flags/fg';
22
22
  import Layer from '../Layer';
23
23
  var packageName = "@atlaskit/editor-common";
24
- var packageVersion = "126.2.0";
24
+ var packageVersion = "126.2.1";
25
25
  var halfFocusRing = 1;
26
26
  var dropOffset = '0, 8';
27
27
  var fadeIn = keyframes({
@@ -6,32 +6,36 @@ type AlignmentState = 'start' | 'end' | 'center';
6
6
  export declare function addParagraphAtEnd(tr: Transaction): void;
7
7
  export declare function createParagraphAtEnd(): Command;
8
8
  /**
9
+ * Command-based image alignment retained for legacy alignment call sites.
9
10
  *
10
- * @deprecated use changeImageAlignmentTr instead
11
+ * @deprecated use changeImageAlignmentNext instead
11
12
  */
12
13
  export declare const changeImageAlignment: (align?: AlignmentState) => Command;
13
14
  export declare const changeImageAlignmentNext: (align?: AlignmentState) => (tr: Transaction) => boolean;
14
15
  /**
16
+ * Command-based block-mark updates retained for media linking and toggleBlockMark.
15
17
  *
16
18
  * @deprecated use createToggleBlockMarkOnRangeNext instead, which does not require passing editorState
17
19
  */
18
- export declare const createToggleBlockMarkOnRange: <T extends Object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: Array<NodeType> | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean)) => (from: number, to: number, tr: Transaction, state: EditorState) => boolean;
19
- export declare const createToggleBlockMarkOnRangeNext: <T extends Object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: Array<NodeType> | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean)) => (from: number, to: number, tr: Transaction) => boolean;
20
- export declare const createToggleInlineMarkOnRange: <T extends Object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false) => (from: number, to: number, tr: Transaction, state: EditorState) => boolean;
20
+ export declare const createToggleBlockMarkOnRange: <T extends object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: Array<NodeType> | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean)) => (from: number, to: number, tr: Transaction, state: EditorState) => boolean;
21
+ export declare const createToggleBlockMarkOnRangeNext: <T extends object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: Array<NodeType> | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean)) => (from: number, to: number, tr: Transaction) => boolean;
22
+ export declare const createToggleInlineMarkOnRange: <T extends object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false) => (from: number, to: number, tr: Transaction, state: EditorState) => boolean;
21
23
  /**
22
- * @deprecated use toggleBlockMarkTr instead
23
24
  * Toggles block mark based on the return type of `getAttrs`.
24
25
  * This is similar to ProseMirror's `getAttrs` from `AttributeSpec`
25
26
  * return `false` to remove the mark.
26
- * return `undefined for no-op.
27
+ * return `undefined` for no-op.
27
28
  * return an `object` to update the mark.
29
+ * Retained for Command-based alignment and indentation paths.
30
+ *
31
+ * @deprecated use toggleBlockMarkNext instead
28
32
  */
29
- export declare const toggleBlockMark: <T extends Object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: Array<NodeType> | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean)) => Command;
33
+ export declare const toggleBlockMark: <T extends object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: Array<NodeType> | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean)) => Command;
30
34
  /**
31
35
  * Toggles block mark based on the return type of `getAttrs`.
32
36
  * @returns true if the mark is applied, false otherwise.
33
37
  */
34
- export declare const toggleBlockMarkNext: <T extends Object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: Array<NodeType> | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean)) => (tr: Transaction) => boolean;
38
+ export declare const toggleBlockMarkNext: <T extends object = object>(markType: MarkType, getAttrs: (prevAttrs?: T, node?: PMNode) => T | undefined | false, allowedBlocks?: Array<NodeType> | ((schema: Schema, node: PMNode, parent: PMNode | null) => boolean)) => (tr: Transaction) => boolean;
35
39
  export declare const clearEditorContent: Command;
36
40
  export declare function findCutBefore($pos: ResolvedPos): ResolvedPos | null;
37
41
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-common",
3
- "version": "126.2.1",
3
+ "version": "126.2.2",
4
4
  "description": "A package that contains common classes and components for editor and renderer",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -85,7 +85,7 @@
85
85
  "@atlaskit/task-decision": "^21.11.0",
86
86
  "@atlaskit/teams-app-config": "^3.1.0",
87
87
  "@atlaskit/textfield": "^10.2.0",
88
- "@atlaskit/tmp-editor-statsig": "^213.0.0",
88
+ "@atlaskit/tmp-editor-statsig": "^214.0.0",
89
89
  "@atlaskit/tokens": "^20.1.0",
90
90
  "@atlaskit/tooltip": "^24.3.0",
91
91
  "@atlaskit/width-detector": "^7.2.0",