@atlaskit/editor-common 114.12.3 → 114.13.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,24 @@
1
1
  # @atlaskit/editor-common
2
2
 
3
+ ## 114.13.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [`e6053f4348753`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/e6053f4348753) -
8
+ Fix cc-markdown-mode duplication and stuck-loading issues on rich/markdown convert. Cache the
9
+ latest init payload on the native collab provider and expose it via an optional getInitPayload()
10
+ getter so editor-plugin-collab-edit can seed collabInitialised=true on a rebind (e.g. preset
11
+ rebuild) without re-running handleInit. Gate a synthetic-BE-step filter in
12
+ documentService.processSteps that neutralises NCS reconcile-generated steps tagged with the user's
13
+ userId but no clientId (prevents HelloHello duplication after a markdown-mode flip). Defensively
14
+ hide the WYSIWYG editor DOM in MarkdownModeContentComponent when the source view is active so the
15
+ floating toolbar/cursor doesn't leak through. All behaviour changes are behind the
16
+ cc-markdown-mode experiment.
17
+
18
+ ### Patch Changes
19
+
20
+ - Updated dependencies
21
+
3
22
  ## 114.12.3
4
23
 
5
24
  ### Patch Changes
@@ -19,7 +19,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
19
19
  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); }
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 = "114.12.2";
22
+ var packageVersion = "0.0.0-development";
23
23
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
24
24
  // Remove URL as it has UGC
25
25
  // 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 = "114.12.2";
27
+ var packageVersion = "0.0.0-development";
28
28
  var halfFocusRing = 1;
29
29
  var dropOffset = '0, 8';
30
30
  var fadeIn = (0, _react2.keyframes)({
@@ -4,7 +4,7 @@ import { isFedRamp } from './environment';
4
4
  import { normaliseSentryBreadcrumbs, SERIALIZABLE_ATTRIBUTES } from './normalise-sentry-breadcrumbs';
5
5
  const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
6
6
  const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
7
- const packageVersion = "114.12.2";
7
+ const packageVersion = "0.0.0-development";
8
8
  const sanitiseSentryEvents = (data, _hint) => {
9
9
  // Remove URL as it has UGC
10
10
  // Ignored via go/ees007
@@ -14,7 +14,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
14
14
  import { fg } from '@atlaskit/platform-feature-flags';
15
15
  import Layer from '../Layer';
16
16
  const packageName = "@atlaskit/editor-common";
17
- const packageVersion = "114.12.2";
17
+ const packageVersion = "0.0.0-development";
18
18
  const halfFocusRing = 1;
19
19
  const dropOffset = '0, 8';
20
20
  const fadeIn = keyframes({
@@ -10,7 +10,7 @@ import { isFedRamp } from './environment';
10
10
  import { normaliseSentryBreadcrumbs, SERIALIZABLE_ATTRIBUTES } from './normalise-sentry-breadcrumbs';
11
11
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
12
12
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
13
- var packageVersion = "114.12.2";
13
+ var packageVersion = "0.0.0-development";
14
14
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
15
15
  // Remove URL as it has UGC
16
16
  // Ignored via go/ees007
@@ -21,7 +21,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
21
21
  import { fg } from '@atlaskit/platform-feature-flags';
22
22
  import Layer from '../Layer';
23
23
  var packageName = "@atlaskit/editor-common";
24
- var packageVersion = "114.12.2";
24
+ var packageVersion = "0.0.0-development";
25
25
  var halfFocusRing = 1;
26
26
  var dropOffset = '0, 8';
27
27
  var fadeIn = keyframes({
@@ -448,6 +448,21 @@ export interface CollabEvents {
448
448
  export type SyncUpErrorFunction = (attributes: NewCollabSyncUpErrorAttributes) => void;
449
449
  export interface CollabEditProvider<Events extends CollabEvents = CollabEvents> {
450
450
  getFinalAcknowledgedState: (reason: GetResolvedEditorStateReason) => Promise<ResolvedEditorState>;
451
+ /**
452
+ * Returns the cached `init` payload if the provider has already initialised the
453
+ * document with NCS, otherwise `undefined`.
454
+ *
455
+ * Used by the collab plugin to seed a freshly-attached plugin view (e.g. after
456
+ * an editor preset reconfigure or a full EditorView recreation) with the same
457
+ * `init` data the original subscribers received. Without this, late subscribers
458
+ * never receive `init` (it is fired once at session start) and the editor
459
+ * gets stuck in the `!isReady` state, silently dropping doc-changing
460
+ * transactions via `filterTransaction`.
461
+ *
462
+ * Optional for backwards compatibility with custom provider implementations
463
+ * (e.g. test mocks). When undefined, the rebind path is skipped.
464
+ */
465
+ getInitPayload?: () => CollabEventInitData | undefined;
451
466
  getIsNamespaceLocked: () => boolean;
452
467
  initialize: (getState: () => any, createStep: (json: object) => Step) => this;
453
468
  off: (evt: keyof Events, handler: (...args: any) => void) => this;
@@ -448,6 +448,21 @@ export interface CollabEvents {
448
448
  export type SyncUpErrorFunction = (attributes: NewCollabSyncUpErrorAttributes) => void;
449
449
  export interface CollabEditProvider<Events extends CollabEvents = CollabEvents> {
450
450
  getFinalAcknowledgedState: (reason: GetResolvedEditorStateReason) => Promise<ResolvedEditorState>;
451
+ /**
452
+ * Returns the cached `init` payload if the provider has already initialised the
453
+ * document with NCS, otherwise `undefined`.
454
+ *
455
+ * Used by the collab plugin to seed a freshly-attached plugin view (e.g. after
456
+ * an editor preset reconfigure or a full EditorView recreation) with the same
457
+ * `init` data the original subscribers received. Without this, late subscribers
458
+ * never receive `init` (it is fired once at session start) and the editor
459
+ * gets stuck in the `!isReady` state, silently dropping doc-changing
460
+ * transactions via `filterTransaction`.
461
+ *
462
+ * Optional for backwards compatibility with custom provider implementations
463
+ * (e.g. test mocks). When undefined, the rebind path is skipped.
464
+ */
465
+ getInitPayload?: () => CollabEventInitData | undefined;
451
466
  getIsNamespaceLocked: () => boolean;
452
467
  initialize: (getState: () => any, createStep: (json: object) => Step) => this;
453
468
  off: (evt: keyof Events, handler: (...args: any) => void) => this;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-common",
3
- "version": "114.12.3",
3
+ "version": "114.13.0",
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/"