@atlaskit/editor-toolbar 0.12.0 → 0.12.1

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-toolbar
2
2
 
3
+ ## 0.12.1
4
+
5
+ ### Patch Changes
6
+
7
+ - [`a3254a75cdfb7`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/a3254a75cdfb7) -
8
+ [ED-29448] clean up experiment platform_editor_toolbar_aifc_patch_2
9
+ - Updated dependencies
10
+
3
11
  ## 0.12.0
4
12
 
5
13
  ### Minor Changes
@@ -13,12 +13,10 @@
13
13
  @container editor-area (max-width: 533px){._u47mglyw .show-above-md{display:none}._rut51ule .show-below-md{display:block}}
14
14
  @container editor-area (max-width: 700px){._fj5dglyw .show-above-lg{display:none}._5wt61ule .show-below-lg{display:block}}
15
15
  @container toolbar-container (max-width: 1024px){._19x4glyw._19x4glyw .show-above-xl{display:none}._qck01ule._qck01ule .show-below-xl{display:block}._t3a8glyw .show-above-xl{display:none}._1x5z1ule .show-below-xl{display:block}}
16
- @container toolbar-container (max-width: 210px){._48suglyw .show-above-sm{display:none}._j2p61ule .show-below-sm{display:block}._j094glyw._j094glyw .show-above-sm{display:none}._1mc51ule._1mc51ule .show-below-sm{display:block}}
17
- @container toolbar-container (max-width: 350px){._1vg1glyw .show-above-md{display:none}._1ei51ule .show-below-md{display:block}}
16
+ @container toolbar-container (max-width: 210px){._j094glyw._j094glyw .show-above-sm{display:none}._1mc51ule._1mc51ule .show-below-sm{display:block}}
18
17
  @container toolbar-container (max-width: 408px){._gipeglyw._gipeglyw .show-above-md{display:none}._311r1ule._311r1ule .show-below-md{display:block}}
19
18
  @container toolbar-container (max-width: 410px){._6nrqglyw .show-above-sm{display:none}._1fq21ule .show-below-sm{display:block}}
20
19
  @container toolbar-container (max-width: 476px){._1ireglyw .show-above-md{display:none}._zy2m1ule .show-below-md{display:block}}
21
- @container toolbar-container (max-width: 500px){._pjeuglyw .show-above-lg{display:none}._3bio1ule .show-below-lg{display:block}}
22
20
  @container toolbar-container (max-width: 575px){._11u4glyw._11u4glyw .show-above-lg{display:none}._v1i61ule._v1i61ule .show-below-lg{display:block}}
23
21
  @container toolbar-container (max-width: 768px){._hfbeglyw .show-above-lg{display:none}._gw6d1ule .show-below-lg{display:block}}
24
22
  @media (max-width:700px){._hmx4glyw .show-above-lg{display:none}._1rrm1ule .show-below-lg{display:block}}
@@ -14,12 +14,10 @@ var _runtime = require("@compiled/react/runtime");
14
14
  var _react = _interopRequireDefault(require("react"));
15
15
  var _css = require("@atlaskit/css");
16
16
  var _compiled = require("@atlaskit/primitives/compiled");
17
- var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
18
17
  var styles = {
19
18
  responsiveContainer: "_1bsb1osq _7cca15wb _1f38ptqj _1bx91ule _1ehg1ule _1onx1ule _1xt01ule _zg9wglyw _1a2cglyw _sum2glyw _1vtcglyw",
20
19
  responsiveRules: "_t3a8glyw _1x5z1ule _6nrqglyw _1fq21ule _1ireglyw _zy2m1ule _hfbeglyw _gw6d1ule",
21
20
  responsiveRulesReduced: "_j094glyw _1mc51ule _gipeglyw _311r1ule _11u4glyw _v1i61ule _19x4glyw _qck01ule",
22
- responsiveRulesReducedOld: "_t3a8glyw _1x5z1ule _48suglyw _j2p61ule _1vg1glyw _1ei51ule _pjeuglyw _3bio1ule",
23
21
  responsiveRulesWrapper: "_1bx91ule _1ehg1ule _1onx1ule _1xt01ule _zg9wglyw _1a2cglyw _sum2glyw _1vtcglyw _33p2glyw _1dre1ule _u47mglyw _rut51ule _fj5dglyw _5wt61ule _hmx4glyw _1rrm1ule _ut18glyw _1nwo1ule _19fzglyw _1r831ule"
24
22
  };
25
23
  /**
@@ -69,7 +67,7 @@ var ResponsiveContainer = exports.ResponsiveContainer = function ResponsiveConta
69
67
  var children = _ref.children,
70
68
  reducedBreakpoints = _ref.reducedBreakpoints;
71
69
  return /*#__PURE__*/_react.default.createElement(_compiled.Box, {
72
- xcss: (0, _css.cx)(styles.responsiveContainer, reducedBreakpoints ? (0, _experiments.editorExperiment)('platform_editor_toolbar_aifc_patch_2', true) ? styles.responsiveRulesReduced : styles.responsiveRulesReducedOld : styles.responsiveRules)
70
+ xcss: (0, _css.cx)(styles.responsiveContainer, reducedBreakpoints ? styles.responsiveRulesReduced : styles.responsiveRules)
73
71
  }, children);
74
72
  };
75
73
 
@@ -11,7 +11,6 @@ var _react = _interopRequireWildcard(require("react"));
11
11
  var React = _react;
12
12
  var _runtime = require("@compiled/react/runtime");
13
13
  var _compiled = require("@atlaskit/primitives/compiled");
14
- var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
15
14
  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); }
16
15
  var styles = {
17
16
  container: "_1e0c1txw",
@@ -26,20 +25,12 @@ var ToolbarButtonGroup = exports.ToolbarButtonGroup = function ToolbarButtonGrou
26
25
  var FirstChild = items.at(0);
27
26
  var LastChild = items.at(-1);
28
27
  var middleChildren = items.slice(1, -1);
29
- var isToolbarPatch2Enabled = (0, _expValEquals.expValEquals)('platform_editor_toolbar_aifc_patch_2', 'isEnabled', true);
30
- return isToolbarPatch2Enabled ? /*#__PURE__*/React.createElement(_compiled.Box, {
28
+ return /*#__PURE__*/React.createElement(_compiled.Box, {
31
29
  xcss: styles.container,
32
30
  "data-toolbar-component": "button-group"
33
31
  }, items.length <= 1 ? children : /*#__PURE__*/React.createElement(_react.Fragment, null, /*#__PURE__*/React.createElement("div", {
34
32
  className: (0, _runtime.ax)([styles.firstChildNew])
35
33
  }, FirstChild), middleChildren, /*#__PURE__*/React.createElement("div", {
36
34
  className: (0, _runtime.ax)([styles.lastChildNew])
37
- }, LastChild))) : /*#__PURE__*/React.createElement(_compiled.Box, {
38
- xcss: styles.container,
39
- "data-toolbar-component": "button-group"
40
- }, items.length <= 1 ? children : /*#__PURE__*/React.createElement(_react.Fragment, null, /*#__PURE__*/React.createElement("div", {
41
- className: (0, _runtime.ax)([styles.firstChild])
42
- }, FirstChild), middleChildren, /*#__PURE__*/React.createElement("div", {
43
- className: (0, _runtime.ax)([styles.lastChild])
44
35
  }, LastChild)));
45
36
  };
@@ -13,12 +13,10 @@
13
13
  @container editor-area (max-width: 533px){._u47mglyw .show-above-md{display:none}._rut51ule .show-below-md{display:block}}
14
14
  @container editor-area (max-width: 700px){._fj5dglyw .show-above-lg{display:none}._5wt61ule .show-below-lg{display:block}}
15
15
  @container toolbar-container (max-width: 1024px){._19x4glyw._19x4glyw .show-above-xl{display:none}._qck01ule._qck01ule .show-below-xl{display:block}._t3a8glyw .show-above-xl{display:none}._1x5z1ule .show-below-xl{display:block}}
16
- @container toolbar-container (max-width: 210px){._48suglyw .show-above-sm{display:none}._j2p61ule .show-below-sm{display:block}._j094glyw._j094glyw .show-above-sm{display:none}._1mc51ule._1mc51ule .show-below-sm{display:block}}
17
- @container toolbar-container (max-width: 350px){._1vg1glyw .show-above-md{display:none}._1ei51ule .show-below-md{display:block}}
16
+ @container toolbar-container (max-width: 210px){._j094glyw._j094glyw .show-above-sm{display:none}._1mc51ule._1mc51ule .show-below-sm{display:block}}
18
17
  @container toolbar-container (max-width: 408px){._gipeglyw._gipeglyw .show-above-md{display:none}._311r1ule._311r1ule .show-below-md{display:block}}
19
18
  @container toolbar-container (max-width: 410px){._6nrqglyw .show-above-sm{display:none}._1fq21ule .show-below-sm{display:block}}
20
19
  @container toolbar-container (max-width: 476px){._1ireglyw .show-above-md{display:none}._zy2m1ule .show-below-md{display:block}}
21
- @container toolbar-container (max-width: 500px){._pjeuglyw .show-above-lg{display:none}._3bio1ule .show-below-lg{display:block}}
22
20
  @container toolbar-container (max-width: 575px){._11u4glyw._11u4glyw .show-above-lg{display:none}._v1i61ule._v1i61ule .show-below-lg{display:block}}
23
21
  @container toolbar-container (max-width: 768px){._hfbeglyw .show-above-lg{display:none}._gw6d1ule .show-below-lg{display:block}}
24
22
  @media (max-width:700px){._hmx4glyw .show-above-lg{display:none}._1rrm1ule .show-below-lg{display:block}}
@@ -7,12 +7,10 @@ import { ax, ix } from "@compiled/react/runtime";
7
7
  import React from 'react';
8
8
  import { cx } from '@atlaskit/css';
9
9
  import { Box } from '@atlaskit/primitives/compiled';
10
- import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
11
10
  const styles = {
12
11
  responsiveContainer: "_1bsb1osq _7cca15wb _1f38ptqj _1bx91ule _1ehg1ule _1onx1ule _1xt01ule _zg9wglyw _1a2cglyw _sum2glyw _1vtcglyw",
13
12
  responsiveRules: "_t3a8glyw _1x5z1ule _6nrqglyw _1fq21ule _1ireglyw _zy2m1ule _hfbeglyw _gw6d1ule",
14
13
  responsiveRulesReduced: "_j094glyw _1mc51ule _gipeglyw _311r1ule _11u4glyw _v1i61ule _19x4glyw _qck01ule",
15
- responsiveRulesReducedOld: "_t3a8glyw _1x5z1ule _48suglyw _j2p61ule _1vg1glyw _1ei51ule _pjeuglyw _3bio1ule",
16
14
  responsiveRulesWrapper: "_1bx91ule _1ehg1ule _1onx1ule _1xt01ule _zg9wglyw _1a2cglyw _sum2glyw _1vtcglyw _33p2glyw _1dre1ule _u47mglyw _rut51ule _fj5dglyw _5wt61ule _hmx4glyw _1rrm1ule _ut18glyw _1nwo1ule _19fzglyw _1r831ule"
17
15
  };
18
16
  /**
@@ -63,7 +61,7 @@ export const ResponsiveContainer = ({
63
61
  reducedBreakpoints
64
62
  }) => {
65
63
  return /*#__PURE__*/React.createElement(Box, {
66
- xcss: cx(styles.responsiveContainer, reducedBreakpoints ? editorExperiment('platform_editor_toolbar_aifc_patch_2', true) ? styles.responsiveRulesReduced : styles.responsiveRulesReducedOld : styles.responsiveRules)
64
+ xcss: cx(styles.responsiveContainer, reducedBreakpoints ? styles.responsiveRulesReduced : styles.responsiveRules)
67
65
  }, children);
68
66
  };
69
67
 
@@ -4,7 +4,6 @@ import * as React from 'react';
4
4
  import { ax, ix } from "@compiled/react/runtime";
5
5
  import { Children, Fragment } from 'react';
6
6
  import { Box } from '@atlaskit/primitives/compiled';
7
- import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
8
7
  const styles = {
9
8
  container: "_1e0c1txw",
10
9
  firstChild: "_fb2512x7 _t1diidpf _u6eridpf",
@@ -19,20 +18,12 @@ export const ToolbarButtonGroup = ({
19
18
  const FirstChild = items.at(0);
20
19
  const LastChild = items.at(-1);
21
20
  const middleChildren = items.slice(1, -1);
22
- const isToolbarPatch2Enabled = expValEquals('platform_editor_toolbar_aifc_patch_2', 'isEnabled', true);
23
- return isToolbarPatch2Enabled ? /*#__PURE__*/React.createElement(Box, {
21
+ return /*#__PURE__*/React.createElement(Box, {
24
22
  xcss: styles.container,
25
23
  "data-toolbar-component": "button-group"
26
24
  }, items.length <= 1 ? children : /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
27
25
  className: ax([styles.firstChildNew])
28
26
  }, FirstChild), middleChildren, /*#__PURE__*/React.createElement("div", {
29
27
  className: ax([styles.lastChildNew])
30
- }, LastChild))) : /*#__PURE__*/React.createElement(Box, {
31
- xcss: styles.container,
32
- "data-toolbar-component": "button-group"
33
- }, items.length <= 1 ? children : /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
34
- className: ax([styles.firstChild])
35
- }, FirstChild), middleChildren, /*#__PURE__*/React.createElement("div", {
36
- className: ax([styles.lastChild])
37
28
  }, LastChild)));
38
29
  };
@@ -13,12 +13,10 @@
13
13
  @container editor-area (max-width: 533px){._u47mglyw .show-above-md{display:none}._rut51ule .show-below-md{display:block}}
14
14
  @container editor-area (max-width: 700px){._fj5dglyw .show-above-lg{display:none}._5wt61ule .show-below-lg{display:block}}
15
15
  @container toolbar-container (max-width: 1024px){._19x4glyw._19x4glyw .show-above-xl{display:none}._qck01ule._qck01ule .show-below-xl{display:block}._t3a8glyw .show-above-xl{display:none}._1x5z1ule .show-below-xl{display:block}}
16
- @container toolbar-container (max-width: 210px){._48suglyw .show-above-sm{display:none}._j2p61ule .show-below-sm{display:block}._j094glyw._j094glyw .show-above-sm{display:none}._1mc51ule._1mc51ule .show-below-sm{display:block}}
17
- @container toolbar-container (max-width: 350px){._1vg1glyw .show-above-md{display:none}._1ei51ule .show-below-md{display:block}}
16
+ @container toolbar-container (max-width: 210px){._j094glyw._j094glyw .show-above-sm{display:none}._1mc51ule._1mc51ule .show-below-sm{display:block}}
18
17
  @container toolbar-container (max-width: 408px){._gipeglyw._gipeglyw .show-above-md{display:none}._311r1ule._311r1ule .show-below-md{display:block}}
19
18
  @container toolbar-container (max-width: 410px){._6nrqglyw .show-above-sm{display:none}._1fq21ule .show-below-sm{display:block}}
20
19
  @container toolbar-container (max-width: 476px){._1ireglyw .show-above-md{display:none}._zy2m1ule .show-below-md{display:block}}
21
- @container toolbar-container (max-width: 500px){._pjeuglyw .show-above-lg{display:none}._3bio1ule .show-below-lg{display:block}}
22
20
  @container toolbar-container (max-width: 575px){._11u4glyw._11u4glyw .show-above-lg{display:none}._v1i61ule._v1i61ule .show-below-lg{display:block}}
23
21
  @container toolbar-container (max-width: 768px){._hfbeglyw .show-above-lg{display:none}._gw6d1ule .show-below-lg{display:block}}
24
22
  @media (max-width:700px){._hmx4glyw .show-above-lg{display:none}._1rrm1ule .show-below-lg{display:block}}
@@ -7,12 +7,10 @@ import { ax, ix } from "@compiled/react/runtime";
7
7
  import React from 'react';
8
8
  import { cx } from '@atlaskit/css';
9
9
  import { Box } from '@atlaskit/primitives/compiled';
10
- import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
11
10
  var styles = {
12
11
  responsiveContainer: "_1bsb1osq _7cca15wb _1f38ptqj _1bx91ule _1ehg1ule _1onx1ule _1xt01ule _zg9wglyw _1a2cglyw _sum2glyw _1vtcglyw",
13
12
  responsiveRules: "_t3a8glyw _1x5z1ule _6nrqglyw _1fq21ule _1ireglyw _zy2m1ule _hfbeglyw _gw6d1ule",
14
13
  responsiveRulesReduced: "_j094glyw _1mc51ule _gipeglyw _311r1ule _11u4glyw _v1i61ule _19x4glyw _qck01ule",
15
- responsiveRulesReducedOld: "_t3a8glyw _1x5z1ule _48suglyw _j2p61ule _1vg1glyw _1ei51ule _pjeuglyw _3bio1ule",
16
14
  responsiveRulesWrapper: "_1bx91ule _1ehg1ule _1onx1ule _1xt01ule _zg9wglyw _1a2cglyw _sum2glyw _1vtcglyw _33p2glyw _1dre1ule _u47mglyw _rut51ule _fj5dglyw _5wt61ule _hmx4glyw _1rrm1ule _ut18glyw _1nwo1ule _19fzglyw _1r831ule"
17
15
  };
18
16
  /**
@@ -62,7 +60,7 @@ export var ResponsiveContainer = function ResponsiveContainer(_ref) {
62
60
  var children = _ref.children,
63
61
  reducedBreakpoints = _ref.reducedBreakpoints;
64
62
  return /*#__PURE__*/React.createElement(Box, {
65
- xcss: cx(styles.responsiveContainer, reducedBreakpoints ? editorExperiment('platform_editor_toolbar_aifc_patch_2', true) ? styles.responsiveRulesReduced : styles.responsiveRulesReducedOld : styles.responsiveRules)
63
+ xcss: cx(styles.responsiveContainer, reducedBreakpoints ? styles.responsiveRulesReduced : styles.responsiveRules)
66
64
  }, children);
67
65
  };
68
66
 
@@ -4,7 +4,6 @@ import * as React from 'react';
4
4
  import { ax, ix } from "@compiled/react/runtime";
5
5
  import { Children, Fragment } from 'react';
6
6
  import { Box } from '@atlaskit/primitives/compiled';
7
- import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
8
7
  var styles = {
9
8
  container: "_1e0c1txw",
10
9
  firstChild: "_fb2512x7 _t1diidpf _u6eridpf",
@@ -18,20 +17,12 @@ export var ToolbarButtonGroup = function ToolbarButtonGroup(_ref) {
18
17
  var FirstChild = items.at(0);
19
18
  var LastChild = items.at(-1);
20
19
  var middleChildren = items.slice(1, -1);
21
- var isToolbarPatch2Enabled = expValEquals('platform_editor_toolbar_aifc_patch_2', 'isEnabled', true);
22
- return isToolbarPatch2Enabled ? /*#__PURE__*/React.createElement(Box, {
20
+ return /*#__PURE__*/React.createElement(Box, {
23
21
  xcss: styles.container,
24
22
  "data-toolbar-component": "button-group"
25
23
  }, items.length <= 1 ? children : /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
26
24
  className: ax([styles.firstChildNew])
27
25
  }, FirstChild), middleChildren, /*#__PURE__*/React.createElement("div", {
28
26
  className: ax([styles.lastChildNew])
29
- }, LastChild))) : /*#__PURE__*/React.createElement(Box, {
30
- xcss: styles.container,
31
- "data-toolbar-component": "button-group"
32
- }, items.length <= 1 ? children : /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
33
- className: ax([styles.firstChild])
34
- }, FirstChild), middleChildren, /*#__PURE__*/React.createElement("div", {
35
- className: ax([styles.lastChild])
36
27
  }, LastChild)));
37
28
  };
package/package.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "publishConfig": {
4
4
  "registry": "https://registry.npmjs.org/"
5
5
  },
6
- "version": "0.12.0",
6
+ "version": "0.12.1",
7
7
  "description": "Common UI for Toolbars across the platform",
8
8
  "atlassian": {
9
9
  "team": "Editor: Jenga",
@@ -32,7 +32,7 @@
32
32
  "@atlaskit/platform-feature-flags-react": "^0.3.0",
33
33
  "@atlaskit/popup": "^4.4.0",
34
34
  "@atlaskit/primitives": "^14.15.0",
35
- "@atlaskit/tmp-editor-statsig": "^13.1.0",
35
+ "@atlaskit/tmp-editor-statsig": "^13.2.0",
36
36
  "@atlaskit/tokens": "^6.4.0",
37
37
  "@atlaskit/tooltip": "^20.5.0",
38
38
  "@babel/runtime": "^7.0.0",