@atlaskit/editor-common 126.0.0 → 126.1.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 +47 -0
- package/collab-defer-collab-send/package.json +10 -0
- package/collab-streaming-step-collapse/package.json +10 -0
- package/dist/cjs/analytics/types/enums.js +0 -3
- package/dist/cjs/collab/defer-collab-send.js +28 -0
- package/dist/cjs/collab/streaming-step-collapse.js +26 -0
- package/dist/cjs/monitoring/error.js +1 -1
- package/dist/cjs/ui/DropList/index.js +1 -1
- package/dist/es2019/analytics/types/enums.js +0 -3
- package/dist/es2019/collab/defer-collab-send.js +22 -0
- package/dist/es2019/collab/streaming-step-collapse.js +20 -0
- package/dist/es2019/monitoring/error.js +1 -1
- package/dist/es2019/ui/DropList/index.js +1 -1
- package/dist/esm/analytics/types/enums.js +0 -3
- package/dist/esm/collab/defer-collab-send.js +22 -0
- package/dist/esm/collab/streaming-step-collapse.js +20 -0
- package/dist/esm/monitoring/error.js +1 -1
- package/dist/esm/ui/DropList/index.js +1 -1
- package/dist/types/analytics/index.d.ts +0 -1
- package/dist/types/analytics/types/enums.d.ts +0 -2
- package/dist/types/analytics/types/events.d.ts +1 -2
- package/dist/types/analytics/types/general-events.d.ts +1 -1
- package/dist/types/collab/defer-collab-send.d.ts +22 -0
- package/dist/types/collab/streaming-step-collapse.d.ts +20 -0
- package/package.json +3 -3
- package/analytics/types/ncs-session-step-events/package.json +0 -10
- package/dist/cjs/analytics/types/ncs-session-step-events.js +0 -5
- package/dist/cjs/ncs-step-metrics/index.js +0 -15
- package/dist/es2019/analytics/types/ncs-session-step-events.js +0 -1
- package/dist/es2019/ncs-step-metrics/index.js +0 -10
- package/dist/esm/analytics/types/ncs-session-step-events.js +0 -1
- package/dist/esm/ncs-step-metrics/index.js +0 -10
- package/dist/types/analytics/types/ncs-session-step-events.d.ts +0 -11
- package/dist/types/ncs-step-metrics/index.d.ts +0 -5
- package/ncs-step-metrics/package.json +0 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,52 @@
|
|
|
1
1
|
# @atlaskit/editor-common
|
|
2
2
|
|
|
3
|
+
## 126.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`5b30c74e8080f`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/5b30c74e8080f) -
|
|
8
|
+
Compose the intermediate steps of an AI streaming response into a single collab step, so a
|
|
9
|
+
streamed edit costs the collab service roughly one step per block instead of one per chunk.
|
|
10
|
+
|
|
11
|
+
Each streaming frame replaces the whole AI region with the cumulative content so far, so the
|
|
12
|
+
frames are individually large and grow as the response does. They are also thrown away at the end
|
|
13
|
+
— `buildCommitTransaction` rebuilds the final document from the response rather than from what was
|
|
14
|
+
streamed — which is what makes composing them safe.
|
|
15
|
+
|
|
16
|
+
`mergeOverlappingSteps` merges two consecutive overlapping steps into the single step they are
|
|
17
|
+
collectively equivalent to, and `collapseStreamingSteps` folds it across the steps in the collab
|
|
18
|
+
unconfirmed queue. Composition is exact in both directions: the forward step is verified against
|
|
19
|
+
the document, and the inverse is composed alongside it because `rebaseSteps` applies inverses to
|
|
20
|
+
the live document whenever a remote step arrives.
|
|
21
|
+
|
|
22
|
+
Composing only helps while the steps are still unsent, because `lockStepOrigins` marks everything
|
|
23
|
+
a flush sends and a locked step can never be merged. `createCollabSendHold` therefore holds the
|
|
24
|
+
send back across transactions — not per transaction, since acks, remote steps and the user's own
|
|
25
|
+
typing all trigger sends that would otherwise lock the queue. Producers drive it with the
|
|
26
|
+
`DEFER_COLLAB_SEND` meta: `true` starts the hold, `false` releases it, anything else leaves it
|
|
27
|
+
untouched. `true` does not extend a hold already in progress, so a continuous stream of held
|
|
28
|
+
frames still reaches the bound.
|
|
29
|
+
|
|
30
|
+
`editor-common` gains two new entrypoints for the metadata keys shared between the producer and
|
|
31
|
+
the collab layer: `./collab-streaming-step-collapse` and `./collab-defer-collab-send`. The changes
|
|
32
|
+
in `editor-plugin-collab-edit` and `editor-plugin-ai` are internal — neither package's exports map
|
|
33
|
+
changes.
|
|
34
|
+
|
|
35
|
+
While the send is held nothing is sent, including the user's own edits, up to the hold's time
|
|
36
|
+
bound. `sendableSteps` returns the queue in version order, so a later step cannot be sent ahead of
|
|
37
|
+
held ones. Peers also do not see in-progress content until a flush, and content in a held queue
|
|
38
|
+
exists only on the client until then.
|
|
39
|
+
|
|
40
|
+
All of this is behind the `platform_editor_ai_collapse_streaming_steps` feature gate. With the
|
|
41
|
+
gate off, streaming frames are not stamped, the send is never held, and the unconfirmed queue is
|
|
42
|
+
left exactly as it is today.
|
|
43
|
+
|
|
44
|
+
### Patch Changes
|
|
45
|
+
|
|
46
|
+
- [`5f61320693517`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/5f61320693517) -
|
|
47
|
+
Clean up experiment `platform_editor_remove_collab_step_metrics`
|
|
48
|
+
- Updated dependencies
|
|
49
|
+
|
|
3
50
|
## 126.0.0
|
|
4
51
|
|
|
5
52
|
### Major Changes
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@atlaskit/editor-common/collab-defer-collab-send",
|
|
3
|
+
"main": "../dist/cjs/collab/defer-collab-send.js",
|
|
4
|
+
"module": "../dist/esm/collab/defer-collab-send.js",
|
|
5
|
+
"module:es2019": "../dist/es2019/collab/defer-collab-send.js",
|
|
6
|
+
"sideEffects": [
|
|
7
|
+
"**/*.compiled.css"
|
|
8
|
+
],
|
|
9
|
+
"types": "../dist/types/collab/defer-collab-send.d.ts"
|
|
10
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@atlaskit/editor-common/collab-streaming-step-collapse",
|
|
3
|
+
"main": "../dist/cjs/collab/streaming-step-collapse.js",
|
|
4
|
+
"module": "../dist/esm/collab/streaming-step-collapse.js",
|
|
5
|
+
"module:es2019": "../dist/es2019/collab/streaming-step-collapse.js",
|
|
6
|
+
"sideEffects": [
|
|
7
|
+
"**/*.compiled.css"
|
|
8
|
+
],
|
|
9
|
+
"types": "../dist/types/collab/streaming-step-collapse.d.ts"
|
|
10
|
+
}
|
|
@@ -197,9 +197,6 @@ var ACTION = exports.ACTION = /*#__PURE__*/function (ACTION) {
|
|
|
197
197
|
ACTION["SELECT_ALL_ESCAPED"] = "selectAllEscaped";
|
|
198
198
|
ACTION["SORT_COLUMN"] = "sortedColumn";
|
|
199
199
|
ACTION["SORT_COLUMN_NOT_ALLOWED"] = "sortColumnNotAllowed";
|
|
200
|
-
// remove this enum when cleaning up platform_editor_remove_collab_step_metrics
|
|
201
|
-
ACTION["NCS_SESSION_STEP_METRICS"] = "ncsSessionStepMetrics";
|
|
202
|
-
ACTION["STEPS_TRACKED"] = "stepsTracked";
|
|
203
200
|
ACTION["ORGANIC_CHANGES_TRACKED"] = "organicChangesTracked";
|
|
204
201
|
ACTION["STEPS_FILTERED"] = "stepsFiltered";
|
|
205
202
|
ACTION["AGENT_EDIT_SHIMMER_NOT_SHOWN"] = "agentEditShimmerNotShown";
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.DEFER_COLLAB_SEND = void 0;
|
|
7
|
+
/**
|
|
8
|
+
* Neutral transaction metadata used by streaming producers to tell the collab layer not to flush
|
|
9
|
+
* the unconfirmed queue for this transaction.
|
|
10
|
+
*
|
|
11
|
+
* The transaction is still applied to the local document immediately; only the network send is
|
|
12
|
+
* held back. The steps stay in the collab plugin's unconfirmed queue, which is where sending is
|
|
13
|
+
* deferred from — `sendableSteps` returns the whole queue, so the next unheld transaction sends
|
|
14
|
+
* everything that accumulated.
|
|
15
|
+
*
|
|
16
|
+
* Holding the send is what gives `collapseStreamingSteps` a window to work in: `send()` stamps
|
|
17
|
+
* `mergeIsLocked` on every origin it flushes, and locked steps can no longer be composed.
|
|
18
|
+
*
|
|
19
|
+
* Producers must bound how long they hold. Held steps are content the collab service has not seen,
|
|
20
|
+
* so they are lost if the tab closes, and a peer editing the same region while steps are held will
|
|
21
|
+
* rebase against a document that is missing them.
|
|
22
|
+
*
|
|
23
|
+
* @example
|
|
24
|
+
* ```ts
|
|
25
|
+
* tr.setMeta(DEFER_COLLAB_SEND, true);
|
|
26
|
+
* ```
|
|
27
|
+
*/
|
|
28
|
+
var DEFER_COLLAB_SEND = exports.DEFER_COLLAB_SEND = 'deferCollabSend';
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.STREAMING_COLLAPSIBLE_STEPS = void 0;
|
|
7
|
+
/**
|
|
8
|
+
* Neutral transaction metadata used by streaming producers (for example editor-plugin-ai's
|
|
9
|
+
* in-editor direct streaming) to tell the collab layer that this transaction's steps are an
|
|
10
|
+
* intermediate frame of a single logical edit.
|
|
11
|
+
*
|
|
12
|
+
* Streaming producers re-render the whole in-progress region on every chunk, which means each
|
|
13
|
+
* frame is a full replace of the region the previous frame inserted. Every frame is applied to the
|
|
14
|
+
* local document immediately (so the user sees the content stream in), but only the *composition*
|
|
15
|
+
* of the frames needs to reach the collab service.
|
|
16
|
+
*
|
|
17
|
+
* Stamping a transaction with this meta does NOT stop its steps from being sent — it only makes
|
|
18
|
+
* them eligible to be composed with adjacent frames while they are still unconfirmed. See
|
|
19
|
+
* `collapseStreamingSteps` in `@atlaskit/editor-plugin-collab-edit`.
|
|
20
|
+
*
|
|
21
|
+
* @example
|
|
22
|
+
* ```ts
|
|
23
|
+
* tr.setMeta(STREAMING_COLLAPSIBLE_STEPS, true);
|
|
24
|
+
* ```
|
|
25
|
+
*/
|
|
26
|
+
var STREAMING_COLLAPSIBLE_STEPS = exports.STREAMING_COLLAPSIBLE_STEPS = 'streamingCollapsibleSteps';
|
|
@@ -27,7 +27,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
|
|
|
27
27
|
var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
|
|
28
28
|
var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
|
|
29
29
|
var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
|
|
30
|
-
var packageVersion = "
|
|
30
|
+
var packageVersion = "126.0.0";
|
|
31
31
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
32
32
|
// Remove URL as it has UGC
|
|
33
33
|
// 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 = "
|
|
27
|
+
var packageVersion = "126.0.0";
|
|
28
28
|
var halfFocusRing = 1;
|
|
29
29
|
var dropOffset = '0, 8';
|
|
30
30
|
var fadeIn = (0, _react2.keyframes)({
|
|
@@ -193,9 +193,6 @@ export let ACTION = /*#__PURE__*/function (ACTION) {
|
|
|
193
193
|
ACTION["SELECT_ALL_ESCAPED"] = "selectAllEscaped";
|
|
194
194
|
ACTION["SORT_COLUMN"] = "sortedColumn";
|
|
195
195
|
ACTION["SORT_COLUMN_NOT_ALLOWED"] = "sortColumnNotAllowed";
|
|
196
|
-
// remove this enum when cleaning up platform_editor_remove_collab_step_metrics
|
|
197
|
-
ACTION["NCS_SESSION_STEP_METRICS"] = "ncsSessionStepMetrics";
|
|
198
|
-
ACTION["STEPS_TRACKED"] = "stepsTracked";
|
|
199
196
|
ACTION["ORGANIC_CHANGES_TRACKED"] = "organicChangesTracked";
|
|
200
197
|
ACTION["STEPS_FILTERED"] = "stepsFiltered";
|
|
201
198
|
ACTION["AGENT_EDIT_SHIMMER_NOT_SHOWN"] = "agentEditShimmerNotShown";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Neutral transaction metadata used by streaming producers to tell the collab layer not to flush
|
|
3
|
+
* the unconfirmed queue for this transaction.
|
|
4
|
+
*
|
|
5
|
+
* The transaction is still applied to the local document immediately; only the network send is
|
|
6
|
+
* held back. The steps stay in the collab plugin's unconfirmed queue, which is where sending is
|
|
7
|
+
* deferred from — `sendableSteps` returns the whole queue, so the next unheld transaction sends
|
|
8
|
+
* everything that accumulated.
|
|
9
|
+
*
|
|
10
|
+
* Holding the send is what gives `collapseStreamingSteps` a window to work in: `send()` stamps
|
|
11
|
+
* `mergeIsLocked` on every origin it flushes, and locked steps can no longer be composed.
|
|
12
|
+
*
|
|
13
|
+
* Producers must bound how long they hold. Held steps are content the collab service has not seen,
|
|
14
|
+
* so they are lost if the tab closes, and a peer editing the same region while steps are held will
|
|
15
|
+
* rebase against a document that is missing them.
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* ```ts
|
|
19
|
+
* tr.setMeta(DEFER_COLLAB_SEND, true);
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export const DEFER_COLLAB_SEND = 'deferCollabSend';
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Neutral transaction metadata used by streaming producers (for example editor-plugin-ai's
|
|
3
|
+
* in-editor direct streaming) to tell the collab layer that this transaction's steps are an
|
|
4
|
+
* intermediate frame of a single logical edit.
|
|
5
|
+
*
|
|
6
|
+
* Streaming producers re-render the whole in-progress region on every chunk, which means each
|
|
7
|
+
* frame is a full replace of the region the previous frame inserted. Every frame is applied to the
|
|
8
|
+
* local document immediately (so the user sees the content stream in), but only the *composition*
|
|
9
|
+
* of the frames needs to reach the collab service.
|
|
10
|
+
*
|
|
11
|
+
* Stamping a transaction with this meta does NOT stop its steps from being sent — it only makes
|
|
12
|
+
* them eligible to be composed with adjacent frames while they are still unconfirmed. See
|
|
13
|
+
* `collapseStreamingSteps` in `@atlaskit/editor-plugin-collab-edit`.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```ts
|
|
17
|
+
* tr.setMeta(STREAMING_COLLAPSIBLE_STEPS, true);
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
export const STREAMING_COLLAPSIBLE_STEPS = 'streamingCollapsibleSteps';
|
|
@@ -13,7 +13,7 @@ const NETWORK_FAILURE_REGEX = /^network failure/i;
|
|
|
13
13
|
const RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
|
|
14
14
|
const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
|
|
15
15
|
const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
|
|
16
|
-
const packageVersion = "
|
|
16
|
+
const packageVersion = "126.0.0";
|
|
17
17
|
const sanitiseSentryEvents = (data, _hint) => {
|
|
18
18
|
// Remove URL as it has UGC
|
|
19
19
|
// Ignored via go/ees007
|
|
@@ -14,7 +14,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
|
14
14
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
15
15
|
import Layer from '../Layer';
|
|
16
16
|
const packageName = "@atlaskit/editor-common";
|
|
17
|
-
const packageVersion = "
|
|
17
|
+
const packageVersion = "126.0.0";
|
|
18
18
|
const halfFocusRing = 1;
|
|
19
19
|
const dropOffset = '0, 8';
|
|
20
20
|
const fadeIn = keyframes({
|
|
@@ -193,9 +193,6 @@ export var ACTION = /*#__PURE__*/function (ACTION) {
|
|
|
193
193
|
ACTION["SELECT_ALL_ESCAPED"] = "selectAllEscaped";
|
|
194
194
|
ACTION["SORT_COLUMN"] = "sortedColumn";
|
|
195
195
|
ACTION["SORT_COLUMN_NOT_ALLOWED"] = "sortColumnNotAllowed";
|
|
196
|
-
// remove this enum when cleaning up platform_editor_remove_collab_step_metrics
|
|
197
|
-
ACTION["NCS_SESSION_STEP_METRICS"] = "ncsSessionStepMetrics";
|
|
198
|
-
ACTION["STEPS_TRACKED"] = "stepsTracked";
|
|
199
196
|
ACTION["ORGANIC_CHANGES_TRACKED"] = "organicChangesTracked";
|
|
200
197
|
ACTION["STEPS_FILTERED"] = "stepsFiltered";
|
|
201
198
|
ACTION["AGENT_EDIT_SHIMMER_NOT_SHOWN"] = "agentEditShimmerNotShown";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Neutral transaction metadata used by streaming producers to tell the collab layer not to flush
|
|
3
|
+
* the unconfirmed queue for this transaction.
|
|
4
|
+
*
|
|
5
|
+
* The transaction is still applied to the local document immediately; only the network send is
|
|
6
|
+
* held back. The steps stay in the collab plugin's unconfirmed queue, which is where sending is
|
|
7
|
+
* deferred from — `sendableSteps` returns the whole queue, so the next unheld transaction sends
|
|
8
|
+
* everything that accumulated.
|
|
9
|
+
*
|
|
10
|
+
* Holding the send is what gives `collapseStreamingSteps` a window to work in: `send()` stamps
|
|
11
|
+
* `mergeIsLocked` on every origin it flushes, and locked steps can no longer be composed.
|
|
12
|
+
*
|
|
13
|
+
* Producers must bound how long they hold. Held steps are content the collab service has not seen,
|
|
14
|
+
* so they are lost if the tab closes, and a peer editing the same region while steps are held will
|
|
15
|
+
* rebase against a document that is missing them.
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* ```ts
|
|
19
|
+
* tr.setMeta(DEFER_COLLAB_SEND, true);
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export var DEFER_COLLAB_SEND = 'deferCollabSend';
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Neutral transaction metadata used by streaming producers (for example editor-plugin-ai's
|
|
3
|
+
* in-editor direct streaming) to tell the collab layer that this transaction's steps are an
|
|
4
|
+
* intermediate frame of a single logical edit.
|
|
5
|
+
*
|
|
6
|
+
* Streaming producers re-render the whole in-progress region on every chunk, which means each
|
|
7
|
+
* frame is a full replace of the region the previous frame inserted. Every frame is applied to the
|
|
8
|
+
* local document immediately (so the user sees the content stream in), but only the *composition*
|
|
9
|
+
* of the frames needs to reach the collab service.
|
|
10
|
+
*
|
|
11
|
+
* Stamping a transaction with this meta does NOT stop its steps from being sent — it only makes
|
|
12
|
+
* them eligible to be composed with adjacent frames while they are still unconfirmed. See
|
|
13
|
+
* `collapseStreamingSteps` in `@atlaskit/editor-plugin-collab-edit`.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```ts
|
|
17
|
+
* tr.setMeta(STREAMING_COLLAPSIBLE_STEPS, true);
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
export var STREAMING_COLLAPSIBLE_STEPS = 'streamingCollapsibleSteps';
|
|
@@ -19,7 +19,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
|
|
|
19
19
|
var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
|
|
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 = "
|
|
22
|
+
var packageVersion = "126.0.0";
|
|
23
23
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
24
24
|
// Remove URL as it has UGC
|
|
25
25
|
// Ignored via go/ees007
|
|
@@ -21,7 +21,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
|
21
21
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
22
22
|
import Layer from '../Layer';
|
|
23
23
|
var packageName = "@atlaskit/editor-common";
|
|
24
|
-
var packageVersion = "
|
|
24
|
+
var packageVersion = "126.0.0";
|
|
25
25
|
var halfFocusRing = 1;
|
|
26
26
|
var dropOffset = '0, 8';
|
|
27
27
|
var fadeIn = keyframes({
|
|
@@ -55,7 +55,6 @@ export type { AIUnifiedEventPayload, AIUnifiedCommonAttributes } from './types/a
|
|
|
55
55
|
export type { ActiveSessionEventPayload, ActiveSessionEventAttributes, } from './types/activity-session-events';
|
|
56
56
|
export { type AIInlineSuggestionPayload, AI_SUGGESTION_TRIGGERED_FROM, } from './types/ai-inline-suggestion-events';
|
|
57
57
|
export { type TelepointerClickPayload } from './types/telepointer-events';
|
|
58
|
-
export { type NcsSessionStepEventAEP, type NcsSessionStepMetrics, } from './types/ncs-session-step-events';
|
|
59
58
|
export type { BlockMenuEventPayload } from './types/block-menu-events';
|
|
60
59
|
export type { BreakoutEventPayload, BreakoutSupportedNodes } from './types/breakout-events';
|
|
61
60
|
export type { RendererSyncBlockEventPayload, SyncBlockEventPayload, SyncedBlockSSRErrorAEP, } from './types/sync-block-events';
|
|
@@ -190,8 +190,6 @@ export declare enum ACTION {
|
|
|
190
190
|
SELECT_ALL_ESCAPED = "selectAllEscaped",
|
|
191
191
|
SORT_COLUMN = "sortedColumn",
|
|
192
192
|
SORT_COLUMN_NOT_ALLOWED = "sortColumnNotAllowed",
|
|
193
|
-
NCS_SESSION_STEP_METRICS = "ncsSessionStepMetrics",
|
|
194
|
-
STEPS_TRACKED = "stepsTracked",
|
|
195
193
|
ORGANIC_CHANGES_TRACKED = "organicChangesTracked",
|
|
196
194
|
STEPS_FILTERED = "stepsFiltered",
|
|
197
195
|
AGENT_EDIT_SHIMMER_NOT_SHOWN = "agentEditShimmerNotShown",
|
|
@@ -48,7 +48,6 @@ import type { MediaEventPayload } from './media-events';
|
|
|
48
48
|
import type { MentionEventPayload } from './mention-events';
|
|
49
49
|
import type { MoveContentEventPayload } from './move-content-events';
|
|
50
50
|
import type { NativeEmbedResizeErroredAEP } from './native-embed-events';
|
|
51
|
-
import type { NcsSessionStepEventAEP } from './ncs-session-step-events';
|
|
52
51
|
import type { NestedTableActionsEventPayload } from './nested-table-events';
|
|
53
52
|
import type { NodeEventPayload } from './node-events';
|
|
54
53
|
import type { OfflineEditingEventPayload } from './offline-editing-event';
|
|
@@ -74,7 +73,7 @@ export type SimplifiedNode = {
|
|
|
74
73
|
pos: number;
|
|
75
74
|
type: string;
|
|
76
75
|
};
|
|
77
|
-
export type AnalyticsEventPayload<T = void> = AvatarEventPayload | GeneralEventPayload<T> | FormatEventPayload | SubstituteEventPayload | InsertEventPayload | NodeEventPayload | MoveContentEventPayload | MediaEventPayload | TableEventPayload | PasteEventPayload | PasteActionsMenuEventPayload | QuickInsertInformationEventPayload | CutCopyEventPayload | ErrorEventPayload | TextColorEventPayload | FindReplaceEventPayload | DateEventPayload | SelectionEventPayload | ListEventPayload | ConfigPanelEventPayload | ElementBrowserEventPayload | CreateLinkInlineDialogEventPayload | HighlightActionsEventPayload | UnsupportedContentPayload | ExtensionEventPayload | TransactionEventPayload | TypeAheadPayload | UnlinkToolbarAEP | EditLinkToolbarAEP | PreviewItemClickedAEP | OpenLinkToolbarAEP | OpenSettingsToolbarAEP | CustomPanelEventPayload | FeatureExposureAEP | NewCollabSyncUpErrorAEP | UnsupportedContentTooltipPayload | ReferentialityEventPayload | LoomEventPayload | MBEEventPayload | HighlightEventPayload | DatasourceClickedPayload | ElementEventPayload | VisitedLinkAEP | ViewEventPayload | MediaUploadEventPayload | MentionEventPayload | EngagementPlatformEventPayload | NestedTableActionsEventPayload | ContainerNodeActionsEventPayload | AICommandPaletteEventPayload | AIDefinitionsEventPayload | AIEventPayload | AIStreamingEventPayload | AIProactiveEventPayload | AiAutocompleteEventPayload | AiSuggestionsEventPayload | ContextualTypeaheadEventPayload | AIQuickPromptEventPayload | AIUnifiedEventPayload | BreakoutEventPayload | BlockMenuEventPayload | ActiveSessionEventPayload | AIInlineSuggestionPayload | SelectionExtensionEventPayload | TelepointerClickPayload | SelectionToolbarEventPayload | ExperienceEventPayload | AlignmentEventPayload | UndoRedoAEP | OfflineEditingEventPayload |
|
|
76
|
+
export type AnalyticsEventPayload<T = void> = AvatarEventPayload | GeneralEventPayload<T> | FormatEventPayload | SubstituteEventPayload | InsertEventPayload | NodeEventPayload | MoveContentEventPayload | MediaEventPayload | TableEventPayload | PasteEventPayload | PasteActionsMenuEventPayload | QuickInsertInformationEventPayload | CutCopyEventPayload | ErrorEventPayload | TextColorEventPayload | FindReplaceEventPayload | DateEventPayload | SelectionEventPayload | ListEventPayload | ConfigPanelEventPayload | ElementBrowserEventPayload | CreateLinkInlineDialogEventPayload | HighlightActionsEventPayload | UnsupportedContentPayload | ExtensionEventPayload | TransactionEventPayload | TypeAheadPayload | UnlinkToolbarAEP | EditLinkToolbarAEP | PreviewItemClickedAEP | OpenLinkToolbarAEP | OpenSettingsToolbarAEP | CustomPanelEventPayload | FeatureExposureAEP | NewCollabSyncUpErrorAEP | UnsupportedContentTooltipPayload | ReferentialityEventPayload | LoomEventPayload | MBEEventPayload | HighlightEventPayload | DatasourceClickedPayload | ElementEventPayload | VisitedLinkAEP | ViewEventPayload | MediaUploadEventPayload | MentionEventPayload | EngagementPlatformEventPayload | NestedTableActionsEventPayload | ContainerNodeActionsEventPayload | AICommandPaletteEventPayload | AIDefinitionsEventPayload | AIEventPayload | AIStreamingEventPayload | AIProactiveEventPayload | AiAutocompleteEventPayload | AiSuggestionsEventPayload | ContextualTypeaheadEventPayload | AIQuickPromptEventPayload | AIUnifiedEventPayload | BreakoutEventPayload | BlockMenuEventPayload | ActiveSessionEventPayload | AIInlineSuggestionPayload | SelectionExtensionEventPayload | TelepointerClickPayload | SelectionToolbarEventPayload | ExperienceEventPayload | AlignmentEventPayload | UndoRedoAEP | OfflineEditingEventPayload | AgentEditShimmerNotShownAEP | FloatingToolbarOverflowEventPayload | SyncBlockEventPayload | FloatingToolbarEventPayload;
|
|
78
77
|
type CustomPanelEventPayload = TrackAEP<ACTION.CHANGED_BACKGROUND_COLOR | ACTION.CHANGED_ICON | ACTION.REMOVE_ICON, ACTION_SUBJECT.PANEL, ACTION_SUBJECT_ID.PANEL, {
|
|
79
78
|
newColor: string;
|
|
80
79
|
previousColor: string;
|
|
@@ -249,7 +249,7 @@ type IndentationMarksTransformedAEP = OperationalAEP<ACTION.INDENTATION_MARKS_TR
|
|
|
249
249
|
type NodesMissingContentTransformedAEP = OperationalAEP<ACTION.NODES_MISSING_CONTENT_TRANSFORMED, ACTION_SUBJECT.EDITOR, undefined, undefined>;
|
|
250
250
|
type SingleColumLayoutDetectedAEP = OperationalAEP<ACTION.SINGLE_COL_LAYOUT_DETECTED, ACTION_SUBJECT.EDITOR, undefined, undefined>;
|
|
251
251
|
type InvalidMediaContentTransformedAEP = OperationalAEP<ACTION.INVALID_MEDIA_CONTENT_TRANSFORMED, ACTION_SUBJECT.EDITOR, undefined, undefined>;
|
|
252
|
-
type CollabStepsTrackerPayloadAEP = OperationalAEP<ACTION.
|
|
252
|
+
type CollabStepsTrackerPayloadAEP = OperationalAEP<ACTION.STEPS_FILTERED, ACTION_SUBJECT.COLLAB, undefined, {
|
|
253
253
|
steps: unknown[];
|
|
254
254
|
}>;
|
|
255
255
|
type CollabOrganicChangesTrackerPayloadAEP = OperationalAEP<ACTION.ORGANIC_CHANGES_TRACKED, ACTION_SUBJECT.COLLAB, undefined, {
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Neutral transaction metadata used by streaming producers to tell the collab layer not to flush
|
|
3
|
+
* the unconfirmed queue for this transaction.
|
|
4
|
+
*
|
|
5
|
+
* The transaction is still applied to the local document immediately; only the network send is
|
|
6
|
+
* held back. The steps stay in the collab plugin's unconfirmed queue, which is where sending is
|
|
7
|
+
* deferred from — `sendableSteps` returns the whole queue, so the next unheld transaction sends
|
|
8
|
+
* everything that accumulated.
|
|
9
|
+
*
|
|
10
|
+
* Holding the send is what gives `collapseStreamingSteps` a window to work in: `send()` stamps
|
|
11
|
+
* `mergeIsLocked` on every origin it flushes, and locked steps can no longer be composed.
|
|
12
|
+
*
|
|
13
|
+
* Producers must bound how long they hold. Held steps are content the collab service has not seen,
|
|
14
|
+
* so they are lost if the tab closes, and a peer editing the same region while steps are held will
|
|
15
|
+
* rebase against a document that is missing them.
|
|
16
|
+
*
|
|
17
|
+
* @example
|
|
18
|
+
* ```ts
|
|
19
|
+
* tr.setMeta(DEFER_COLLAB_SEND, true);
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
22
|
+
export declare const DEFER_COLLAB_SEND = "deferCollabSend";
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Neutral transaction metadata used by streaming producers (for example editor-plugin-ai's
|
|
3
|
+
* in-editor direct streaming) to tell the collab layer that this transaction's steps are an
|
|
4
|
+
* intermediate frame of a single logical edit.
|
|
5
|
+
*
|
|
6
|
+
* Streaming producers re-render the whole in-progress region on every chunk, which means each
|
|
7
|
+
* frame is a full replace of the region the previous frame inserted. Every frame is applied to the
|
|
8
|
+
* local document immediately (so the user sees the content stream in), but only the *composition*
|
|
9
|
+
* of the frames needs to reach the collab service.
|
|
10
|
+
*
|
|
11
|
+
* Stamping a transaction with this meta does NOT stop its steps from being sent — it only makes
|
|
12
|
+
* them eligible to be composed with adjacent frames while they are still unconfirmed. See
|
|
13
|
+
* `collapseStreamingSteps` in `@atlaskit/editor-plugin-collab-edit`.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```ts
|
|
17
|
+
* tr.setMeta(STREAMING_COLLAPSIBLE_STEPS, true);
|
|
18
|
+
* ```
|
|
19
|
+
*/
|
|
20
|
+
export declare const STREAMING_COLLAPSIBLE_STEPS = "streamingCollapsibleSteps";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-common",
|
|
3
|
-
"version": "126.
|
|
3
|
+
"version": "126.1.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/"
|
|
@@ -85,8 +85,8 @@
|
|
|
85
85
|
"@atlaskit/task-decision": "^21.11.0",
|
|
86
86
|
"@atlaskit/teams-app-config": "^3.1.0",
|
|
87
87
|
"@atlaskit/textfield": "^10.2.0",
|
|
88
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
89
|
-
"@atlaskit/tokens": "^20.
|
|
88
|
+
"@atlaskit/tmp-editor-statsig": "^210.0.0",
|
|
89
|
+
"@atlaskit/tokens": "^20.1.0",
|
|
90
90
|
"@atlaskit/tooltip": "^24.3.0",
|
|
91
91
|
"@atlaskit/width-detector": "^7.2.0",
|
|
92
92
|
"@babel/runtime": "^7.0.0",
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@atlaskit/editor-common/analytics/types/ncs-session-step-events",
|
|
3
|
-
"main": "../../../dist/cjs/analytics/types/ncs-session-step-events.js",
|
|
4
|
-
"module": "../../../dist/esm/analytics/types/ncs-session-step-events.js",
|
|
5
|
-
"module:es2019": "../../../dist/es2019/analytics/types/ncs-session-step-events.js",
|
|
6
|
-
"sideEffects": [
|
|
7
|
-
"**/*.compiled.css"
|
|
8
|
-
],
|
|
9
|
-
"types": "../../../dist/types/analytics/types/ncs-session-step-events.d.ts"
|
|
10
|
-
}
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.NCS_STORAGE = void 0;
|
|
7
|
-
// Disable no-re-export rule for entry point files
|
|
8
|
-
/* eslint-disable @atlaskit/editor/no-re-export */
|
|
9
|
-
var NCS_STORAGE = exports.NCS_STORAGE = /*#__PURE__*/function (NCS_STORAGE) {
|
|
10
|
-
// remove step metrics keys when cleaning up platform_editor_remove_collab_step_metrics
|
|
11
|
-
NCS_STORAGE["NCS_STORAGE_CLIENT_KEY"] = "ncs-session-step-metrics-storage";
|
|
12
|
-
NCS_STORAGE["NCS_SESSION_STEP_METRICS"] = "ncsSessionStepMetrics";
|
|
13
|
-
NCS_STORAGE["NCS_ACTIVE_SESSIONS"] = "ncsActiveSessions";
|
|
14
|
-
return NCS_STORAGE;
|
|
15
|
-
}({});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
// Disable no-re-export rule for entry point files
|
|
2
|
-
/* eslint-disable @atlaskit/editor/no-re-export */
|
|
3
|
-
|
|
4
|
-
export let NCS_STORAGE = /*#__PURE__*/function (NCS_STORAGE) {
|
|
5
|
-
// remove step metrics keys when cleaning up platform_editor_remove_collab_step_metrics
|
|
6
|
-
NCS_STORAGE["NCS_STORAGE_CLIENT_KEY"] = "ncs-session-step-metrics-storage";
|
|
7
|
-
NCS_STORAGE["NCS_SESSION_STEP_METRICS"] = "ncsSessionStepMetrics";
|
|
8
|
-
NCS_STORAGE["NCS_ACTIVE_SESSIONS"] = "ncsActiveSessions";
|
|
9
|
-
return NCS_STORAGE;
|
|
10
|
-
}({});
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export {};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
// Disable no-re-export rule for entry point files
|
|
2
|
-
/* eslint-disable @atlaskit/editor/no-re-export */
|
|
3
|
-
|
|
4
|
-
export var NCS_STORAGE = /*#__PURE__*/function (NCS_STORAGE) {
|
|
5
|
-
// remove step metrics keys when cleaning up platform_editor_remove_collab_step_metrics
|
|
6
|
-
NCS_STORAGE["NCS_STORAGE_CLIENT_KEY"] = "ncs-session-step-metrics-storage";
|
|
7
|
-
NCS_STORAGE["NCS_SESSION_STEP_METRICS"] = "ncsSessionStepMetrics";
|
|
8
|
-
NCS_STORAGE["NCS_ACTIVE_SESSIONS"] = "ncsActiveSessions";
|
|
9
|
-
return NCS_STORAGE;
|
|
10
|
-
}({});
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { ACTION, ACTION_SUBJECT } from './enums';
|
|
2
|
-
import type { OperationalAEP } from './utils';
|
|
3
|
-
export type NcsSessionStepMetrics = {
|
|
4
|
-
maxStepSize: number;
|
|
5
|
-
ncsSessionId?: string;
|
|
6
|
-
numberOfSteps: number;
|
|
7
|
-
p90StepSize?: number;
|
|
8
|
-
stepSizeSumForP90?: number[];
|
|
9
|
-
totalStepSize: number;
|
|
10
|
-
};
|
|
11
|
-
export type NcsSessionStepEventAEP = OperationalAEP<ACTION.NCS_SESSION_STEP_METRICS, ACTION_SUBJECT.COLLAB, undefined, NcsSessionStepMetrics>;
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@atlaskit/editor-common/ncs-step-metrics",
|
|
3
|
-
"main": "../dist/cjs/ncs-step-metrics/index.js",
|
|
4
|
-
"module": "../dist/esm/ncs-step-metrics/index.js",
|
|
5
|
-
"module:es2019": "../dist/es2019/ncs-step-metrics/index.js",
|
|
6
|
-
"sideEffects": [
|
|
7
|
-
"**/*.compiled.css"
|
|
8
|
-
],
|
|
9
|
-
"types": "../dist/types/ncs-step-metrics/index.d.ts"
|
|
10
|
-
}
|