@atlaskit/editor-plugin-copy-button 8.0.9 → 8.0.11

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,19 @@
1
1
  # @atlaskit/editor-plugin-copy-button
2
2
 
3
+ ## 8.0.11
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 8.0.10
10
+
11
+ ### Patch Changes
12
+
13
+ - [`9ed32aea2c1d3`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/9ed32aea2c1d3) -
14
+ Replace feature experiment util with cross platform alternative for platform_editor_block_menu
15
+ - Updated dependencies
16
+
3
17
  ## 8.0.9
4
18
 
5
19
  ### Patch Changes
@@ -14,7 +14,7 @@ var _clipboard = require("@atlaskit/editor-common/clipboard");
14
14
  var _copyButton = require("@atlaskit/editor-common/copy-button");
15
15
  var _state = require("@atlaskit/editor-prosemirror/state");
16
16
  var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
17
- var _expValEqualsNoExposure = require("@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure");
17
+ var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
18
18
  var _pluginKey = require("./plugin-key");
19
19
  function createToolbarCopyCommandForMark(markType, editorAnalyticsApi) {
20
20
  function command(state, dispatch) {
@@ -122,7 +122,7 @@ var createToolbarCopyCommandForNode = exports.createToolbarCopyCommandForNode =
122
122
  // dispatch is provided -- as otherwise the consumer is only testing to see if
123
123
  // the action is availble.
124
124
  var domNode = (0, _copyButton.toDOM)(contentNodeWithPos.node, schema);
125
- if ((0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_block_menu', 'isEnabled', true)) {
125
+ if ((0, _experiments.editorExperiment)('platform_editor_block_menu', true)) {
126
126
  (0, _copyButton.copyDomNode)(domNode, contentNodeWithPos.node.type, tr.selection);
127
127
  } else {
128
128
  if (domNode) {
@@ -4,7 +4,7 @@ import { copyHTMLToClipboard, copyHTMLToClipboardPolyfill, getAnalyticsPayload }
4
4
  import { copyDomNode, getSelectedNodeOrNodeParentByNodeType, toDOM } from '@atlaskit/editor-common/copy-button';
5
5
  import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
6
6
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
7
- import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
7
+ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
8
8
  import { copyButtonPluginKey } from './plugin-key';
9
9
  export function createToolbarCopyCommandForMark(markType, editorAnalyticsApi) {
10
10
  function command(state, dispatch) {
@@ -113,7 +113,7 @@ export const createToolbarCopyCommandForNode = (nodeType, editorAnalyticsApi, ap
113
113
  // dispatch is provided -- as otherwise the consumer is only testing to see if
114
114
  // the action is availble.
115
115
  const domNode = toDOM(contentNodeWithPos.node, schema);
116
- if (expValEqualsNoExposure('platform_editor_block_menu', 'isEnabled', true)) {
116
+ if (editorExperiment('platform_editor_block_menu', true)) {
117
117
  copyDomNode(domNode, contentNodeWithPos.node.type, tr.selection);
118
118
  } else {
119
119
  if (domNode) {
@@ -4,7 +4,7 @@ import { copyHTMLToClipboard, copyHTMLToClipboardPolyfill, getAnalyticsPayload }
4
4
  import { copyDomNode, getSelectedNodeOrNodeParentByNodeType, toDOM } from '@atlaskit/editor-common/copy-button';
5
5
  import { NodeSelection } from '@atlaskit/editor-prosemirror/state';
6
6
  import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
7
- import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
7
+ import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
8
8
  import { copyButtonPluginKey } from './plugin-key';
9
9
  export function createToolbarCopyCommandForMark(markType, editorAnalyticsApi) {
10
10
  function command(state, dispatch) {
@@ -112,7 +112,7 @@ export var createToolbarCopyCommandForNode = function createToolbarCopyCommandFo
112
112
  // dispatch is provided -- as otherwise the consumer is only testing to see if
113
113
  // the action is availble.
114
114
  var domNode = toDOM(contentNodeWithPos.node, schema);
115
- if (expValEqualsNoExposure('platform_editor_block_menu', 'isEnabled', true)) {
115
+ if (editorExperiment('platform_editor_block_menu', true)) {
116
116
  copyDomNode(domNode, contentNodeWithPos.node.type, tr.selection);
117
117
  } else {
118
118
  if (domNode) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-copy-button",
3
- "version": "8.0.9",
3
+ "version": "8.0.11",
4
4
  "description": "editor-plugin-copy-button for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -32,7 +32,7 @@
32
32
  "@atlaskit/editor-plugin-decorations": "^8.0.0",
33
33
  "@atlaskit/editor-prosemirror": "^7.3.0",
34
34
  "@atlaskit/icon": "^33.0.0",
35
- "@atlaskit/tmp-editor-statsig": "^43.0.0",
35
+ "@atlaskit/tmp-editor-statsig": "^44.0.0",
36
36
  "@babel/runtime": "^7.0.0"
37
37
  },
38
38
  "peerDependencies": {