@atlaskit/editor-plugin-paste-options-toolbar 13.3.0 → 13.5.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 CHANGED
@@ -1,5 +1,31 @@
1
1
  # @atlaskit/editor-plugin-paste-options-toolbar
2
2
 
3
+ ## 13.5.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [`894f9e2ba765a`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/894f9e2ba765a) -
8
+ Decouple paste-as-markdown GFM transformer rollout from `cc-markdown-mode` and gate it with the
9
+ new `platform_editor_paste_as_md_use_gfm` experiment for independent rollout control.
10
+
11
+ Consumers can gate the new transformer path with:
12
+ `expValEquals('platform_editor_paste_as_md_use_gfm', 'isEnabled', true)`.
13
+
14
+ ### Patch Changes
15
+
16
+ - Updated dependencies
17
+
18
+ ## 13.4.0
19
+
20
+ ### Minor Changes
21
+
22
+ - [`51c33ef5349b6`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/51c33ef5349b6) -
23
+ Enable compatibility with React 19.2.0
24
+
25
+ ### Patch Changes
26
+
27
+ - Updated dependencies
28
+
3
29
  ## 13.3.0
4
30
 
5
31
  ### Minor Changes
@@ -12,7 +12,6 @@ var _editorMarkdownTransformer = require("@atlaskit/editor-markdown-transformer"
12
12
  var _model = require("@atlaskit/editor-prosemirror/model");
13
13
  var _state = require("@atlaskit/editor-prosemirror/state");
14
14
  var _transform = require("@atlaskit/editor-prosemirror/transform");
15
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
16
15
  var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
17
16
  var _index = require("./index");
18
17
  // Ignored via go/ees005
@@ -153,7 +152,7 @@ function richTextSliceTransactionWithSelectionAdjust(_ref2) {
153
152
 
154
153
  /**
155
154
  * Parse markdown text into a slice for paste replacement, using markdown-plus
156
- * only when both markdown-mode experiment and paste parser gate are enabled.
155
+ * only when the paste parser experiment is enabled.
157
156
  */
158
157
  function getMarkdownSlice(text, schema, selection, markdownToPmConverter) {
159
158
  var targetOpenStartNode = selection.$from.parent;
@@ -170,7 +169,7 @@ function getMarkdownSlice(text, schema, selection, markdownToPmConverter) {
170
169
  }
171
170
  }
172
171
  textInput = textSplitByCodeBlock.join('```');
173
- var doc = markdownToPmConverter && (0, _expValEquals.expValEquals)('cc-markdown-mode', 'isEnabled', true) && (0, _platformFeatureFlags.fg)('platform_editor_paste_as_md_use_gfm_transformer') ? schema.nodes.doc.createAndFill({}, markdownToPmConverter({
172
+ var doc = markdownToPmConverter && (0, _expValEquals.expValEquals)('platform_editor_paste_as_md_use_gfm', 'isEnabled', true) ? schema.nodes.doc.createAndFill({}, markdownToPmConverter({
174
173
  markdown: textInput,
175
174
  schema: schema
176
175
  })) : new _editorMarkdownTransformer.MarkdownTransformer(schema, _paste.md).parse((0, _index.escapeLinks)(textInput));
@@ -5,7 +5,6 @@ import { MarkdownTransformer } from '@atlaskit/editor-markdown-transformer';
5
5
  import { Fragment, Slice } from '@atlaskit/editor-prosemirror/model';
6
6
  import { Selection } from '@atlaskit/editor-prosemirror/state';
7
7
  import { ReplaceStep } from '@atlaskit/editor-prosemirror/transform';
8
- import { fg } from '@atlaskit/platform-feature-flags';
9
8
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
10
9
  import { escapeLinks } from './index';
11
10
 
@@ -149,7 +148,7 @@ function richTextSliceTransactionWithSelectionAdjust({
149
148
 
150
149
  /**
151
150
  * Parse markdown text into a slice for paste replacement, using markdown-plus
152
- * only when both markdown-mode experiment and paste parser gate are enabled.
151
+ * only when the paste parser experiment is enabled.
153
152
  */
154
153
  export function getMarkdownSlice(text, schema, selection, markdownToPmConverter) {
155
154
  const targetOpenStartNode = selection.$from.parent;
@@ -166,7 +165,7 @@ export function getMarkdownSlice(text, schema, selection, markdownToPmConverter)
166
165
  }
167
166
  }
168
167
  textInput = textSplitByCodeBlock.join('```');
169
- const doc = markdownToPmConverter && expValEquals('cc-markdown-mode', 'isEnabled', true) && fg('platform_editor_paste_as_md_use_gfm_transformer') ? schema.nodes.doc.createAndFill({}, markdownToPmConverter({
168
+ const doc = markdownToPmConverter && expValEquals('platform_editor_paste_as_md_use_gfm', 'isEnabled', true) ? schema.nodes.doc.createAndFill({}, markdownToPmConverter({
170
169
  markdown: textInput,
171
170
  schema
172
171
  })) : new MarkdownTransformer(schema, md).parse(escapeLinks(textInput));
@@ -5,7 +5,6 @@ import { MarkdownTransformer } from '@atlaskit/editor-markdown-transformer';
5
5
  import { Fragment, Slice } from '@atlaskit/editor-prosemirror/model';
6
6
  import { Selection } from '@atlaskit/editor-prosemirror/state';
7
7
  import { ReplaceStep } from '@atlaskit/editor-prosemirror/transform';
8
- import { fg } from '@atlaskit/platform-feature-flags';
9
8
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
10
9
  import { escapeLinks } from './index';
11
10
 
@@ -147,7 +146,7 @@ function richTextSliceTransactionWithSelectionAdjust(_ref2) {
147
146
 
148
147
  /**
149
148
  * Parse markdown text into a slice for paste replacement, using markdown-plus
150
- * only when both markdown-mode experiment and paste parser gate are enabled.
149
+ * only when the paste parser experiment is enabled.
151
150
  */
152
151
  export function getMarkdownSlice(text, schema, selection, markdownToPmConverter) {
153
152
  var targetOpenStartNode = selection.$from.parent;
@@ -164,7 +163,7 @@ export function getMarkdownSlice(text, schema, selection, markdownToPmConverter)
164
163
  }
165
164
  }
166
165
  textInput = textSplitByCodeBlock.join('```');
167
- var doc = markdownToPmConverter && expValEquals('cc-markdown-mode', 'isEnabled', true) && fg('platform_editor_paste_as_md_use_gfm_transformer') ? schema.nodes.doc.createAndFill({}, markdownToPmConverter({
166
+ var doc = markdownToPmConverter && expValEquals('platform_editor_paste_as_md_use_gfm', 'isEnabled', true) ? schema.nodes.doc.createAndFill({}, markdownToPmConverter({
168
167
  markdown: textInput,
169
168
  schema: schema
170
169
  })) : new MarkdownTransformer(schema, md).parse(escapeLinks(textInput));
@@ -9,6 +9,6 @@ export declare const formatRichText: (tr: Transaction, pluginState: PasteOptions
9
9
  export declare const formatPlainText: (tr: Transaction, pluginState: PasteOptionsPluginState) => Transaction;
10
10
  /**
11
11
  * Parse markdown text into a slice for paste replacement, using markdown-plus
12
- * only when both markdown-mode experiment and paste parser gate are enabled.
12
+ * only when the paste parser experiment is enabled.
13
13
  */
14
14
  export declare function getMarkdownSlice(text: string, schema: Schema, selection: Selection, markdownToPmConverter?: MarkdownToPmConverter): Slice | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-paste-options-toolbar",
3
- "version": "13.3.0",
3
+ "version": "13.5.0",
4
4
  "description": "Paste options toolbar for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -23,33 +23,33 @@
23
23
  "dependencies": {
24
24
  "@atlaskit/css": "^1.0.0",
25
25
  "@atlaskit/dropdown-menu": "^17.2.0",
26
- "@atlaskit/editor-markdown-transformer": "^6.0.0",
27
- "@atlaskit/editor-plugin-analytics": "^12.0.0",
28
- "@atlaskit/editor-plugin-paste": "^13.4.0",
29
- "@atlaskit/editor-plugin-ui-control-registry": "^6.0.0",
26
+ "@atlaskit/editor-markdown-transformer": "^6.1.0",
27
+ "@atlaskit/editor-plugin-analytics": "^12.1.0",
28
+ "@atlaskit/editor-plugin-paste": "^13.5.0",
29
+ "@atlaskit/editor-plugin-ui-control-registry": "^6.1.0",
30
30
  "@atlaskit/editor-prosemirror": "^8.0.0",
31
31
  "@atlaskit/editor-shared-styles": "^4.0.0",
32
- "@atlaskit/editor-toolbar": "^2.3.0",
33
- "@atlaskit/editor-ui-control-model": "^2.2.0",
32
+ "@atlaskit/editor-toolbar": "^2.4.0",
33
+ "@atlaskit/editor-ui-control-model": "^2.3.0",
34
34
  "@atlaskit/icon": "^37.2.0",
35
35
  "@atlaskit/platform-feature-flags": "^2.1.0",
36
36
  "@atlaskit/primitives": "^22.2.0",
37
- "@atlaskit/tmp-editor-statsig": "^135.0.0",
37
+ "@atlaskit/tmp-editor-statsig": "^135.10.0",
38
38
  "@atlaskit/tokens": "^16.3.0",
39
39
  "@babel/runtime": "^7.0.0",
40
40
  "@compiled/react": "^1.0.0",
41
41
  "@emotion/react": "^11.7.1"
42
42
  },
43
43
  "peerDependencies": {
44
- "@atlaskit/editor-common": "^116.41.0",
45
- "react": "^18.2.0",
46
- "react-dom": "^18.2.0",
44
+ "@atlaskit/editor-common": "^116.47.0",
45
+ "react": "^18.2.0 || ^19.2.0",
46
+ "react-dom": "^18.2.0 || ^19.2.0",
47
47
  "react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
48
48
  },
49
49
  "devDependencies": {
50
50
  "@testing-library/react": "^16.3.0",
51
- "react": "^18.2.0",
52
- "react-dom": "^18.2.0",
51
+ "react": "^19.2.0",
52
+ "react-dom": "^19.2.0",
53
53
  "react-intl": "^7.0.0",
54
54
  "wait-for-expect": "^1.2.0"
55
55
  },
@@ -65,9 +65,6 @@
65
65
  },
66
66
  "platform_editor_paste_actions_menu_v2_exposure": {
67
67
  "type": "boolean"
68
- },
69
- "platform_editor_paste_as_md_use_gfm_transformer": {
70
- "type": "boolean"
71
68
  }
72
69
  },
73
70
  "techstack": {