@atlaskit/editor-common 133.3.0 → 133.4.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 +9 -0
- package/dist/cjs/monitoring/error.js +1 -1
- package/dist/cjs/ui/DropList/index.js +1 -1
- package/dist/es2019/monitoring/error.js +1 -1
- package/dist/es2019/ui/DropList/index.js +1 -1
- package/dist/esm/monitoring/error.js +1 -1
- package/dist/esm/ui/DropList/index.js +1 -1
- package/dist/types/card/types.d.ts +15 -0
- package/dist/types/types/floating-toolbar.d.ts +7 -2
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @atlaskit/editor-common
|
|
2
2
|
|
|
3
|
+
## 133.4.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`f268dee2526f7`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/f268dee2526f7) -
|
|
8
|
+
Migrate Smart Card registration and removal from transactions to editor actions behind
|
|
9
|
+
`platform_editor_reduce_forced_layout_2`. Remove unused card overlay registration behind
|
|
10
|
+
`platform_editor_reduce_forced_layout_2`.
|
|
11
|
+
|
|
3
12
|
## 133.3.0
|
|
4
13
|
|
|
5
14
|
### Minor Changes
|
|
@@ -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 = "133.
|
|
30
|
+
var packageVersion = "133.4.0";
|
|
31
31
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
32
32
|
// Remove URL as it has UGC
|
|
33
33
|
// Ignored via go/ees007
|
|
@@ -23,7 +23,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
23
23
|
* @jsx jsx
|
|
24
24
|
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
25
25
|
var packageName = "@atlaskit/editor-common";
|
|
26
|
-
var packageVersion = "133.
|
|
26
|
+
var packageVersion = "133.4.0";
|
|
27
27
|
var halfFocusRing = 1;
|
|
28
28
|
var dropOffset = '0, 8';
|
|
29
29
|
// Ignored via go/ees005
|
|
@@ -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 = "133.
|
|
16
|
+
const packageVersion = "133.4.0";
|
|
17
17
|
const sanitiseSentryEvents = (data, _hint) => {
|
|
18
18
|
// Remove URL as it has UGC
|
|
19
19
|
// Ignored via go/ees007
|
|
@@ -13,7 +13,7 @@ import withAnalyticsContext from '@atlaskit/analytics-next/withAnalyticsContext'
|
|
|
13
13
|
import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
14
14
|
import Layer from '../Layer';
|
|
15
15
|
const packageName = "@atlaskit/editor-common";
|
|
16
|
-
const packageVersion = "133.
|
|
16
|
+
const packageVersion = "133.4.0";
|
|
17
17
|
const halfFocusRing = 1;
|
|
18
18
|
const dropOffset = '0, 8';
|
|
19
19
|
// Ignored via go/ees005
|
|
@@ -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 = "133.
|
|
22
|
+
var packageVersion = "133.4.0";
|
|
23
23
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
24
24
|
// Remove URL as it has UGC
|
|
25
25
|
// Ignored via go/ees007
|
|
@@ -20,7 +20,7 @@ import withAnalyticsContext from '@atlaskit/analytics-next/withAnalyticsContext'
|
|
|
20
20
|
import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
21
21
|
import Layer from '../Layer';
|
|
22
22
|
var packageName = "@atlaskit/editor-common";
|
|
23
|
-
var packageVersion = "133.
|
|
23
|
+
var packageVersion = "133.4.0";
|
|
24
24
|
var halfFocusRing = 1;
|
|
25
25
|
var dropOffset = '0, 8';
|
|
26
26
|
// Ignored via go/ees005
|
|
@@ -79,7 +79,19 @@ export interface EmbedCardTransformers {
|
|
|
79
79
|
createEmbedCardTransformCommand: CreateEmbedCardTransformCommand;
|
|
80
80
|
embedCardNodeTransformer: EmbedCardNodeTransformer;
|
|
81
81
|
}
|
|
82
|
+
/** Resolved card metadata and its live node-view position getter. */
|
|
83
|
+
export type CardRegistration = {
|
|
84
|
+
/** Read the node view's current position after document edits. */
|
|
85
|
+
getPos: () => number | undefined;
|
|
86
|
+
id: string;
|
|
87
|
+
title?: string;
|
|
88
|
+
url?: string;
|
|
89
|
+
};
|
|
90
|
+
/** Immutable registrations keyed by card ID. */
|
|
91
|
+
export type CardRegistrations = Readonly<Record<string, Readonly<CardRegistration>>>;
|
|
82
92
|
export type CardPluginActions = {
|
|
93
|
+
/** Returns current registrations keyed by card ID. */
|
|
94
|
+
getCardRegistrations: () => CardRegistrations;
|
|
83
95
|
getEndingToolbarItems: GetEndingToolbarItems;
|
|
84
96
|
getStartingToolbarItems: GetStartingToolbarItems;
|
|
85
97
|
hideLinkToolbar: HideLinkToolbarAction;
|
|
@@ -94,7 +106,9 @@ export type CardPluginActions = {
|
|
|
94
106
|
* `queueCardsFromChangedTr` when unavailable.
|
|
95
107
|
*/
|
|
96
108
|
queueCardsFromRange?: QueueCardsFromRangeAction;
|
|
109
|
+
registerCard: (info: CardRegistration) => void;
|
|
97
110
|
registerEmbedCardTransformer: (transformers: EmbedCardTransformers) => void;
|
|
111
|
+
removeRegisteredCard: (id: string) => void;
|
|
98
112
|
/**
|
|
99
113
|
* Resolves a URL via the Object Resolver Service and returns the canonical
|
|
100
114
|
* expanded URL. Useful for expanding Confluence short-link URLs
|
|
@@ -105,4 +119,5 @@ export type CardPluginActions = {
|
|
|
105
119
|
*/
|
|
106
120
|
resolveShortLinkUrl: (url: string) => Promise<string | undefined>;
|
|
107
121
|
setProvider: (provider: Promise<CardProvider>) => Promise<boolean>;
|
|
122
|
+
subscribeToCardRegistry: (listener: () => void) => () => void;
|
|
108
123
|
};
|
|
@@ -142,6 +142,8 @@ export type FloatingToolbarButton<T extends object> = {
|
|
|
142
142
|
confirmDialog?: ConfirmDialogOptions | (() => ConfirmDialogOptions);
|
|
143
143
|
disabled?: boolean;
|
|
144
144
|
focusEditoronEnter?: boolean;
|
|
145
|
+
/** Keep the tooltip open when the button is pressed. Set it when a press changes the tooltip content. */
|
|
146
|
+
hasNewContentOnTriggerClick?: boolean;
|
|
145
147
|
hidden?: boolean;
|
|
146
148
|
hideTooltipOnClick?: boolean;
|
|
147
149
|
href?: string;
|
|
@@ -164,8 +166,6 @@ export type FloatingToolbarButton<T extends object> = {
|
|
|
164
166
|
/** If true, the component will have pulse onboarding effect around it. */
|
|
165
167
|
pulse?: boolean;
|
|
166
168
|
selected?: boolean;
|
|
167
|
-
/** Keep the tooltip open when the button is pressed. Set it when a press changes the tooltip content. */
|
|
168
|
-
hasNewContentOnTriggerClick?: boolean;
|
|
169
169
|
showTitle?: boolean;
|
|
170
170
|
supportsViewMode?: boolean;
|
|
171
171
|
tabIndex?: number | null | undefined;
|
|
@@ -340,6 +340,11 @@ export interface FloatingToolbarConfig {
|
|
|
340
340
|
* behind it. Defaults to `'default'` (the wrapper's surface, as today).
|
|
341
341
|
*/
|
|
342
342
|
containerSurface?: 'default' | 'none';
|
|
343
|
+
/** Refresh items when data outside EditorState changes. Snapshots must be stable between updates. */
|
|
344
|
+
externalStore?: {
|
|
345
|
+
getSnapshot: () => unknown;
|
|
346
|
+
subscribe: (listener: () => void) => () => void;
|
|
347
|
+
};
|
|
343
348
|
/**
|
|
344
349
|
* Enable Popup component's focus trap
|
|
345
350
|
*/
|
package/package.json
CHANGED