@atlaskit/editor-common 84.0.1 → 84.0.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,14 @@
1
1
  # @atlaskit/editor-common
2
2
 
3
+ ## 84.0.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [#116502](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/116502)
8
+ [`1933f2ba43919`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/1933f2ba43919) -
9
+ [EDF-950] Deprecating AtlassianIntelligenceToolbarButton within generative-ai-modal, it now lives
10
+ within editor-plugin-ai, removed duplicated code from editor-common, and use the export instead
11
+
3
12
  ## 84.0.1
4
13
 
5
14
  ### Patch Changes
@@ -22,5 +22,6 @@ var TOOLBAR_ACTION_SUBJECT_ID = exports.TOOLBAR_ACTION_SUBJECT_ID = /*#__PURE__*
22
22
  TOOLBAR_ACTION_SUBJECT_ID["INDENT"] = "indent";
23
23
  TOOLBAR_ACTION_SUBJECT_ID["OUTDENT"] = "outdent";
24
24
  TOOLBAR_ACTION_SUBJECT_ID["RECORD_VIDEO"] = "recordVideo";
25
+ TOOLBAR_ACTION_SUBJECT_ID["AI"] = "atlassian-intelligence";
25
26
  return TOOLBAR_ACTION_SUBJECT_ID;
26
27
  }({});
@@ -17,7 +17,7 @@ function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return
17
17
  function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
18
18
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
19
19
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
20
- var packageVersion = "84.0.1";
20
+ var packageVersion = "84.0.2";
21
21
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
22
22
  // Remove URL as it has UGC
23
23
  // TODO: Sanitise the URL instead of just removing it
@@ -18,7 +18,6 @@ var buttonGroupStyle = exports.buttonGroupStyle = (0, _react.css)({
18
18
  }
19
19
  });
20
20
 
21
- // This style is copied to packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/styles.tsx
22
21
  // If you make change here, change in above file as well.
23
22
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
24
23
  var separatorStyles = exports.separatorStyles = (0, _react.css)({
@@ -30,7 +29,6 @@ var separatorStyles = exports.separatorStyles = (0, _react.css)({
30
29
  userSelect: 'none'
31
30
  });
32
31
 
33
- // This style is copied to packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/styles.tsx
34
32
  // If you make change here, change in above file as well.
35
33
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
36
34
  var wrapperStyle = exports.wrapperStyle = (0, _react.css)({
@@ -20,7 +20,7 @@ var _Layer = _interopRequireDefault(require("../Layer"));
20
20
  function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
21
21
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /** @jsx jsx */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
22
22
  var packageName = "@atlaskit/editor-common";
23
- var packageVersion = "84.0.1";
23
+ var packageVersion = "84.0.2";
24
24
  var halfFocusRing = 1;
25
25
  var dropOffset = '0, 8';
26
26
  var DropList = /*#__PURE__*/function (_Component) {
@@ -16,8 +16,7 @@ var _styles = _interopRequireDefault(require("./styles"));
16
16
  function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
17
17
  function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && Object.prototype.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
18
18
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
19
- 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; } // This file is copied to `packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/ToolbarButton/index.tsx`
20
- // If you make any change here, copy it to above file as well
19
+ 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; } // If you make any change here, copy it to above file as well
21
20
  // and notify about the change in #team-fc-editor-ai-dev channel.
22
21
  /** @jsx jsx */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
23
22
  var TOOLBAR_BUTTON = exports.TOOLBAR_BUTTON = _analytics.TOOLBAR_ACTION_SUBJECT_ID;
@@ -8,7 +8,6 @@ exports.default = void 0;
8
8
  var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
9
9
  var _react = _interopRequireDefault(require("react"));
10
10
  var _standardButton = _interopRequireDefault(require("@atlaskit/button/standard-button"));
11
- // This file is copied to `packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/ToolbarButton/styles.tsx`
12
11
  // If you make any change here, copy it to above file as well
13
12
  // and notify about the change in #team-fc-editor-ai-dev channel.
14
13
  var _default = exports.default = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
@@ -16,5 +16,6 @@ export let TOOLBAR_ACTION_SUBJECT_ID = /*#__PURE__*/function (TOOLBAR_ACTION_SUB
16
16
  TOOLBAR_ACTION_SUBJECT_ID["INDENT"] = "indent";
17
17
  TOOLBAR_ACTION_SUBJECT_ID["OUTDENT"] = "outdent";
18
18
  TOOLBAR_ACTION_SUBJECT_ID["RECORD_VIDEO"] = "recordVideo";
19
+ TOOLBAR_ACTION_SUBJECT_ID["AI"] = "atlassian-intelligence";
19
20
  return TOOLBAR_ACTION_SUBJECT_ID;
20
21
  }({});
@@ -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 = "84.0.1";
4
+ const packageVersion = "84.0.2";
5
5
  const sanitiseSentryEvents = (data, _hint) => {
6
6
  // Remove URL as it has UGC
7
7
  // TODO: Sanitise the URL instead of just removing it
@@ -11,7 +11,6 @@ export const buttonGroupStyle = css({
11
11
  }
12
12
  });
13
13
 
14
- // This style is copied to packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/styles.tsx
15
14
  // If you make change here, change in above file as well.
16
15
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
17
16
  export const separatorStyles = css({
@@ -23,7 +22,6 @@ export const separatorStyles = css({
23
22
  userSelect: 'none'
24
23
  });
25
24
 
26
- // This style is copied to packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/styles.tsx
27
25
  // If you make change here, change in above file as well.
28
26
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
29
27
  export const wrapperStyle = css({
@@ -9,7 +9,7 @@ import { createAndFireEvent, withAnalyticsContext, withAnalyticsEvents } from '@
9
9
  import { N0, N50A, N60A, N900 } from '@atlaskit/theme/colors';
10
10
  import Layer from '../Layer';
11
11
  const packageName = "@atlaskit/editor-common";
12
- const packageVersion = "84.0.1";
12
+ const packageVersion = "84.0.2";
13
13
  const halfFocusRing = 1;
14
14
  const dropOffset = '0, 8';
15
15
  class DropList extends Component {
@@ -1,4 +1,3 @@
1
- // This file is copied to `packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/ToolbarButton/index.tsx`
2
1
  // If you make any change here, copy it to above file as well
3
2
  // and notify about the change in #team-fc-editor-ai-dev channel.
4
3
  /** @jsx jsx */
@@ -1,5 +1,4 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
- // This file is copied to `packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/ToolbarButton/styles.tsx`
3
2
  // If you make any change here, copy it to above file as well
4
3
  // and notify about the change in #team-fc-editor-ai-dev channel.
5
4
  import React from 'react';
@@ -16,5 +16,6 @@ export var TOOLBAR_ACTION_SUBJECT_ID = /*#__PURE__*/function (TOOLBAR_ACTION_SUB
16
16
  TOOLBAR_ACTION_SUBJECT_ID["INDENT"] = "indent";
17
17
  TOOLBAR_ACTION_SUBJECT_ID["OUTDENT"] = "outdent";
18
18
  TOOLBAR_ACTION_SUBJECT_ID["RECORD_VIDEO"] = "recordVideo";
19
+ TOOLBAR_ACTION_SUBJECT_ID["AI"] = "atlassian-intelligence";
19
20
  return TOOLBAR_ACTION_SUBJECT_ID;
20
21
  }({});
@@ -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 = "84.0.1";
10
+ var packageVersion = "84.0.2";
11
11
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
12
12
  // Remove URL as it has UGC
13
13
  // TODO: Sanitise the URL instead of just removing it
@@ -11,7 +11,6 @@ export var buttonGroupStyle = css({
11
11
  }
12
12
  });
13
13
 
14
- // This style is copied to packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/styles.tsx
15
14
  // If you make change here, change in above file as well.
16
15
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
17
16
  export var separatorStyles = css({
@@ -23,7 +22,6 @@ export var separatorStyles = css({
23
22
  userSelect: 'none'
24
23
  });
25
24
 
26
- // This style is copied to packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/styles.tsx
27
25
  // If you make change here, change in above file as well.
28
26
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
29
27
  export var wrapperStyle = css({
@@ -17,7 +17,7 @@ import { createAndFireEvent, withAnalyticsContext, withAnalyticsEvents } from '@
17
17
  import { N0, N50A, N60A, N900 } from '@atlaskit/theme/colors';
18
18
  import Layer from '../Layer';
19
19
  var packageName = "@atlaskit/editor-common";
20
- var packageVersion = "84.0.1";
20
+ var packageVersion = "84.0.2";
21
21
  var halfFocusRing = 1;
22
22
  var dropOffset = '0, 8';
23
23
  var DropList = /*#__PURE__*/function (_Component) {
@@ -1,7 +1,6 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
3
3
  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) { _defineProperty(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; }
4
- // This file is copied to `packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/ToolbarButton/index.tsx`
5
4
  // If you make any change here, copy it to above file as well
6
5
  // and notify about the change in #team-fc-editor-ai-dev channel.
7
6
  /** @jsx jsx */
@@ -1,5 +1,4 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
- // This file is copied to `packages/editor/editor-plugin-ai/src/ui/components/AtlassianIntelligenceToolbarButton/ToolbarButton/styles.tsx`
3
2
  // If you make any change here, copy it to above file as well
4
3
  // and notify about the change in #team-fc-editor-ai-dev channel.
5
4
  import React from 'react';
@@ -17,7 +17,8 @@ export declare enum TOOLBAR_ACTION_SUBJECT_ID {
17
17
  REDO = "redo",
18
18
  INDENT = "indent",
19
19
  OUTDENT = "outdent",
20
- RECORD_VIDEO = "recordVideo"
20
+ RECORD_VIDEO = "recordVideo",
21
+ AI = "atlassian-intelligence"
21
22
  }
22
23
  type ToolbarButtonClickedAEP = UIAEP<ACTION.CLICKED, ACTION_SUBJECT.TOOLBAR_BUTTON, undefined, {}, undefined>;
23
24
  export type ToolbarEventPayload = ToolbarButtonClickedAEP;
@@ -17,7 +17,8 @@ export declare enum TOOLBAR_ACTION_SUBJECT_ID {
17
17
  REDO = "redo",
18
18
  INDENT = "indent",
19
19
  OUTDENT = "outdent",
20
- RECORD_VIDEO = "recordVideo"
20
+ RECORD_VIDEO = "recordVideo",
21
+ AI = "atlassian-intelligence"
21
22
  }
22
23
  type ToolbarButtonClickedAEP = UIAEP<ACTION.CLICKED, ACTION_SUBJECT.TOOLBAR_BUTTON, undefined, {}, undefined>;
23
24
  export type ToolbarEventPayload = ToolbarButtonClickedAEP;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-common",
3
- "version": "84.0.1",
3
+ "version": "84.0.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/"
@@ -126,7 +126,7 @@
126
126
  "@atlaskit/media-ui": "^25.10.0",
127
127
  "@atlaskit/media-viewer": "48.6.10",
128
128
  "@atlaskit/mention": "^23.2.0",
129
- "@atlaskit/menu": "^2.6.0",
129
+ "@atlaskit/menu": "^2.7.0",
130
130
  "@atlaskit/platform-feature-flags": "^0.3.0",
131
131
  "@atlaskit/primitives": "^10.0.0",
132
132
  "@atlaskit/profilecard": "^19.15.0",
@@ -179,7 +179,7 @@
179
179
  "@atlaskit/util-data-test": "^17.9.0",
180
180
  "@atlaskit/visual-regression": "*",
181
181
  "@atlassian/feature-flags-test-utils": "*",
182
- "@testing-library/dom": "^8.17.1",
182
+ "@testing-library/dom": "^10.1.0",
183
183
  "@testing-library/jest-dom": "^6.4.5",
184
184
  "@testing-library/react": "^12.1.5",
185
185
  "@testing-library/react-hooks": "^8.0.1",