@atlaskit/editor-common 114.50.3 → 114.51.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 +22 -0
- package/dist/cjs/messages/syncBlock.js +6 -1
- package/dist/cjs/monitoring/error.js +1 -1
- package/dist/cjs/toolbar/EditorToolbarUIProvider.js +2 -0
- package/dist/cjs/types/markdown-mode-plugin-stub.js +5 -0
- package/dist/cjs/ui/DropList/index.js +1 -1
- package/dist/cjs/utils/processRawValue.js +1 -0
- package/dist/es2019/messages/syncBlock.js +6 -1
- package/dist/es2019/monitoring/error.js +1 -1
- package/dist/es2019/toolbar/EditorToolbarUIProvider.js +2 -0
- package/dist/es2019/types/markdown-mode-plugin-stub.js +1 -0
- package/dist/es2019/ui/DropList/index.js +1 -1
- package/dist/es2019/utils/processRawValue.js +1 -0
- package/dist/esm/messages/syncBlock.js +6 -1
- package/dist/esm/monitoring/error.js +1 -1
- package/dist/esm/toolbar/EditorToolbarUIProvider.js +2 -0
- package/dist/esm/types/markdown-mode-plugin-stub.js +1 -0
- package/dist/esm/ui/DropList/index.js +1 -1
- package/dist/esm/utils/processRawValue.js +1 -0
- package/dist/types/messages/syncBlock.d.ts +10 -5
- package/dist/types/toolbar/EditorToolbarUIProvider.d.ts +2 -1
- package/dist/types/types/index.d.ts +1 -0
- package/dist/types/types/markdown-mode-plugin-stub.d.ts +61 -0
- package/dist/types-ts4.5/messages/syncBlock.d.ts +10 -5
- package/dist/types-ts4.5/toolbar/EditorToolbarUIProvider.d.ts +2 -1
- package/dist/types-ts4.5/types/index.d.ts +1 -0
- package/dist/types-ts4.5/types/markdown-mode-plugin-stub.d.ts +61 -0
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,27 @@
|
|
|
1
1
|
# @atlaskit/editor-common
|
|
2
2
|
|
|
3
|
+
## 114.51.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`c4ae9a3284485`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/c4ae9a3284485) -
|
|
8
|
+
Add extra space after 'Last edited:' and bold 'Synced from' heading in synced block tooltip
|
|
9
|
+
- [`4f322a101cf47`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4f322a101cf47) -
|
|
10
|
+
Adds a disabledWithoutInteractionLogic prop to the toolbar to selectively enable some buttons
|
|
11
|
+
before editor interaction
|
|
12
|
+
- Updated dependencies
|
|
13
|
+
|
|
14
|
+
## 114.51.0
|
|
15
|
+
|
|
16
|
+
### Minor Changes
|
|
17
|
+
|
|
18
|
+
- [`2c2360f6ef073`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/2c2360f6ef073) -
|
|
19
|
+
Move \_MarkdownModePluginStub to @atlaskit/editor-common
|
|
20
|
+
|
|
21
|
+
### Patch Changes
|
|
22
|
+
|
|
23
|
+
- Updated dependencies
|
|
24
|
+
|
|
3
25
|
## 114.50.3
|
|
4
26
|
|
|
5
27
|
### Patch Changes
|
|
@@ -93,9 +93,14 @@ var syncBlockMessages = exports.syncBlockMessages = (0, _reactIntl.defineMessage
|
|
|
93
93
|
},
|
|
94
94
|
referenceSyncBlockLastEdited: {
|
|
95
95
|
id: 'fabric.editor.referenceSyncBlockLastEdited',
|
|
96
|
-
defaultMessage: 'Last edited:
|
|
96
|
+
defaultMessage: 'Last edited:',
|
|
97
97
|
description: 'Tooltip that shows the last edited time of the synced block'
|
|
98
98
|
},
|
|
99
|
+
referenceSyncBlockSyncedFrom: {
|
|
100
|
+
id: 'fabric.editor.referenceSyncBlockSyncedFrom',
|
|
101
|
+
defaultMessage: 'Synced from:',
|
|
102
|
+
description: 'Bold heading label in the tooltip showing the source page of the synced block'
|
|
103
|
+
},
|
|
99
104
|
taskInDestinationSyncedBlockTooltip: {
|
|
100
105
|
id: 'fabric.editor.taskInDestinationSyncedBlockTooltip',
|
|
101
106
|
defaultMessage: 'This content is synced. Edit it at the source.',
|
|
@@ -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 _t2 in e) "default" !== _t2 && {}.hasOwnProperty.call(e, _t2) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t2)) && (i.get || i.set) ? o(f, _t2, i) : f[_t2] = e[_t2]); 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.
|
|
22
|
+
var packageVersion = "114.51.0";
|
|
23
23
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
24
24
|
// Remove URL as it has UGC
|
|
25
25
|
// Ignored via go/ees007
|
|
@@ -12,6 +12,7 @@ var EditorToolbarUIProvider = exports.EditorToolbarUIProvider = function EditorT
|
|
|
12
12
|
var children = _ref.children,
|
|
13
13
|
api = _ref.api,
|
|
14
14
|
isDisabled = _ref.isDisabled,
|
|
15
|
+
disabledWithoutInteractionLogic = _ref.disabledWithoutInteractionLogic,
|
|
15
16
|
popupsMountPoint = _ref.popupsMountPoint,
|
|
16
17
|
popupsBoundariesElement = _ref.popupsBoundariesElement,
|
|
17
18
|
popupsScrollableElement = _ref.popupsScrollableElement,
|
|
@@ -42,6 +43,7 @@ var EditorToolbarUIProvider = exports.EditorToolbarUIProvider = function EditorT
|
|
|
42
43
|
onDropdownOpenChanged: onDropdownOpenChanged,
|
|
43
44
|
preventDefaultOnMouseDown: true,
|
|
44
45
|
isDisabled: isDisabled,
|
|
46
|
+
disabledWithoutInteractionLogic: disabledWithoutInteractionLogic,
|
|
45
47
|
popupsMountPoint: popupsMountPoint,
|
|
46
48
|
popupsBoundariesElement: popupsBoundariesElement,
|
|
47
49
|
popupsScrollableElement: popupsScrollableElement,
|
|
@@ -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.
|
|
27
|
+
var packageVersion = "114.51.0";
|
|
28
28
|
var halfFocusRing = 1;
|
|
29
29
|
var dropOffset = '0, 8';
|
|
30
30
|
var fadeIn = (0, _react2.keyframes)({
|
|
@@ -257,6 +257,7 @@ function processRawValue(schema, value, providerFactory, sanitizePrivateContent,
|
|
|
257
257
|
transformedAdf = _transformContainerNo.transformedAdf;
|
|
258
258
|
isTransformed = _transformContainerNo.isTransformed;
|
|
259
259
|
if (isTransformed) {
|
|
260
|
+
// TODO: EDITOR-7175 - Add analytics
|
|
260
261
|
entity = transformedAdf;
|
|
261
262
|
}
|
|
262
263
|
}
|
|
@@ -87,9 +87,14 @@ export const syncBlockMessages = defineMessages({
|
|
|
87
87
|
},
|
|
88
88
|
referenceSyncBlockLastEdited: {
|
|
89
89
|
id: 'fabric.editor.referenceSyncBlockLastEdited',
|
|
90
|
-
defaultMessage: 'Last edited:
|
|
90
|
+
defaultMessage: 'Last edited:',
|
|
91
91
|
description: 'Tooltip that shows the last edited time of the synced block'
|
|
92
92
|
},
|
|
93
|
+
referenceSyncBlockSyncedFrom: {
|
|
94
|
+
id: 'fabric.editor.referenceSyncBlockSyncedFrom',
|
|
95
|
+
defaultMessage: 'Synced from:',
|
|
96
|
+
description: 'Bold heading label in the tooltip showing the source page of the synced block'
|
|
97
|
+
},
|
|
93
98
|
taskInDestinationSyncedBlockTooltip: {
|
|
94
99
|
id: 'fabric.editor.taskInDestinationSyncedBlockTooltip',
|
|
95
100
|
defaultMessage: 'This content is synced. Edit it at the source.',
|
|
@@ -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.
|
|
7
|
+
const packageVersion = "114.51.0";
|
|
8
8
|
const sanitiseSentryEvents = (data, _hint) => {
|
|
9
9
|
// Remove URL as it has UGC
|
|
10
10
|
// Ignored via go/ees007
|
|
@@ -4,6 +4,7 @@ export const EditorToolbarUIProvider = ({
|
|
|
4
4
|
children,
|
|
5
5
|
api,
|
|
6
6
|
isDisabled,
|
|
7
|
+
disabledWithoutInteractionLogic,
|
|
7
8
|
popupsMountPoint,
|
|
8
9
|
popupsBoundariesElement,
|
|
9
10
|
popupsScrollableElement,
|
|
@@ -34,6 +35,7 @@ export const EditorToolbarUIProvider = ({
|
|
|
34
35
|
onDropdownOpenChanged: onDropdownOpenChanged,
|
|
35
36
|
preventDefaultOnMouseDown: true,
|
|
36
37
|
isDisabled: isDisabled,
|
|
38
|
+
disabledWithoutInteractionLogic: disabledWithoutInteractionLogic,
|
|
37
39
|
popupsMountPoint: popupsMountPoint,
|
|
38
40
|
popupsBoundariesElement: popupsBoundariesElement,
|
|
39
41
|
popupsScrollableElement: popupsScrollableElement,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -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.
|
|
17
|
+
const packageVersion = "114.51.0";
|
|
18
18
|
const halfFocusRing = 1;
|
|
19
19
|
const dropOffset = '0, 8';
|
|
20
20
|
const fadeIn = keyframes({
|
|
@@ -258,6 +258,7 @@ export function processRawValue(schema, value, providerFactory, sanitizePrivateC
|
|
|
258
258
|
isTransformed
|
|
259
259
|
} = transformContainerNodes(entity, schema));
|
|
260
260
|
if (isTransformed) {
|
|
261
|
+
// TODO: EDITOR-7175 - Add analytics
|
|
261
262
|
entity = transformedAdf;
|
|
262
263
|
}
|
|
263
264
|
}
|
|
@@ -87,9 +87,14 @@ export var syncBlockMessages = defineMessages({
|
|
|
87
87
|
},
|
|
88
88
|
referenceSyncBlockLastEdited: {
|
|
89
89
|
id: 'fabric.editor.referenceSyncBlockLastEdited',
|
|
90
|
-
defaultMessage: 'Last edited:
|
|
90
|
+
defaultMessage: 'Last edited:',
|
|
91
91
|
description: 'Tooltip that shows the last edited time of the synced block'
|
|
92
92
|
},
|
|
93
|
+
referenceSyncBlockSyncedFrom: {
|
|
94
|
+
id: 'fabric.editor.referenceSyncBlockSyncedFrom',
|
|
95
|
+
defaultMessage: 'Synced from:',
|
|
96
|
+
description: 'Bold heading label in the tooltip showing the source page of the synced block'
|
|
97
|
+
},
|
|
93
98
|
taskInDestinationSyncedBlockTooltip: {
|
|
94
99
|
id: 'fabric.editor.taskInDestinationSyncedBlockTooltip',
|
|
95
100
|
defaultMessage: 'This content is synced. Edit it at the source.',
|
|
@@ -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.
|
|
13
|
+
var packageVersion = "114.51.0";
|
|
14
14
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
15
15
|
// Remove URL as it has UGC
|
|
16
16
|
// Ignored via go/ees007
|
|
@@ -4,6 +4,7 @@ export var EditorToolbarUIProvider = function EditorToolbarUIProvider(_ref) {
|
|
|
4
4
|
var children = _ref.children,
|
|
5
5
|
api = _ref.api,
|
|
6
6
|
isDisabled = _ref.isDisabled,
|
|
7
|
+
disabledWithoutInteractionLogic = _ref.disabledWithoutInteractionLogic,
|
|
7
8
|
popupsMountPoint = _ref.popupsMountPoint,
|
|
8
9
|
popupsBoundariesElement = _ref.popupsBoundariesElement,
|
|
9
10
|
popupsScrollableElement = _ref.popupsScrollableElement,
|
|
@@ -34,6 +35,7 @@ export var EditorToolbarUIProvider = function EditorToolbarUIProvider(_ref) {
|
|
|
34
35
|
onDropdownOpenChanged: onDropdownOpenChanged,
|
|
35
36
|
preventDefaultOnMouseDown: true,
|
|
36
37
|
isDisabled: isDisabled,
|
|
38
|
+
disabledWithoutInteractionLogic: disabledWithoutInteractionLogic,
|
|
37
39
|
popupsMountPoint: popupsMountPoint,
|
|
38
40
|
popupsBoundariesElement: popupsBoundariesElement,
|
|
39
41
|
popupsScrollableElement: popupsScrollableElement,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -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.
|
|
24
|
+
var packageVersion = "114.51.0";
|
|
25
25
|
var halfFocusRing = 1;
|
|
26
26
|
var dropOffset = '0, 8';
|
|
27
27
|
var fadeIn = keyframes({
|
|
@@ -249,6 +249,7 @@ export function processRawValue(schema, value, providerFactory, sanitizePrivateC
|
|
|
249
249
|
transformedAdf = _transformContainerNo.transformedAdf;
|
|
250
250
|
isTransformed = _transformContainerNo.isTransformed;
|
|
251
251
|
if (isTransformed) {
|
|
252
|
+
// TODO: EDITOR-7175 - Add analytics
|
|
252
253
|
entity = transformedAdf;
|
|
253
254
|
}
|
|
254
255
|
}
|
|
@@ -59,11 +59,6 @@ export declare const syncBlockMessages: {
|
|
|
59
59
|
description: string;
|
|
60
60
|
id: string;
|
|
61
61
|
};
|
|
62
|
-
syncBlockLabel: {
|
|
63
|
-
defaultMessage: string;
|
|
64
|
-
description: string;
|
|
65
|
-
id: string;
|
|
66
|
-
};
|
|
67
62
|
defaultSyncBlockTooltip: {
|
|
68
63
|
defaultMessage: string;
|
|
69
64
|
description: string;
|
|
@@ -249,6 +244,11 @@ export declare const syncBlockMessages: {
|
|
|
249
244
|
description: string;
|
|
250
245
|
id: string;
|
|
251
246
|
};
|
|
247
|
+
referenceSyncBlockSyncedFrom: {
|
|
248
|
+
defaultMessage: string;
|
|
249
|
+
description: string;
|
|
250
|
+
id: string;
|
|
251
|
+
};
|
|
252
252
|
referenceSyncBlockTooltip: {
|
|
253
253
|
defaultMessage: string;
|
|
254
254
|
description: string;
|
|
@@ -304,6 +304,11 @@ export declare const syncBlockMessages: {
|
|
|
304
304
|
description: string;
|
|
305
305
|
id: string;
|
|
306
306
|
};
|
|
307
|
+
syncBlockLabel: {
|
|
308
|
+
defaultMessage: string;
|
|
309
|
+
description: string;
|
|
310
|
+
id: string;
|
|
311
|
+
};
|
|
307
312
|
syncedBlockLabel: {
|
|
308
313
|
defaultMessage: string;
|
|
309
314
|
description: string;
|
|
@@ -4,7 +4,8 @@ import type { ExtractInjectionAPI, NextEditorPlugin } from '../types';
|
|
|
4
4
|
type Props = Pick<ToolbarUIContextType, 'popupsMountPoint' | 'popupsBoundariesElement' | 'popupsScrollableElement' | 'fireAnalyticsEvent' | 'keyboardNavigation'> & {
|
|
5
5
|
api: ExtractInjectionAPI<NextEditorPlugin<any, any>> | undefined;
|
|
6
6
|
children: React.ReactNode;
|
|
7
|
+
disabledWithoutInteractionLogic?: boolean;
|
|
7
8
|
isDisabled?: boolean;
|
|
8
9
|
};
|
|
9
|
-
export declare const EditorToolbarUIProvider: ({ children, api, isDisabled, popupsMountPoint, popupsBoundariesElement, popupsScrollableElement, fireAnalyticsEvent, keyboardNavigation, }: Props) => React.JSX.Element;
|
|
10
|
+
export declare const EditorToolbarUIProvider: ({ children, api, isDisabled, disabledWithoutInteractionLogic, popupsMountPoint, popupsBoundariesElement, popupsScrollableElement, fireAnalyticsEvent, keyboardNavigation, }: Props) => React.JSX.Element;
|
|
10
11
|
export {};
|
|
@@ -13,6 +13,7 @@ export type { FeatureFlags, FeatureFlagKey, GetEditorFeatureFlags } from './feat
|
|
|
13
13
|
export type { Browsers, Range, DisableSpellcheckByBrowser } from './supported-browsers';
|
|
14
14
|
export type { EditorContainerWidth, GetEditorContainerWidth } from './editor-container-width';
|
|
15
15
|
export type { EmptyStateHandler, EmptyStateHandlerParams } from './empty-state-handler';
|
|
16
|
+
export type { _MarkdownModePluginStub } from './markdown-mode-plugin-stub';
|
|
16
17
|
export type { RenderOptionsPropsT, DropdownOptionT, DropdownOptions, ExtensionDropdownOptions, SelectOption, ButtonAppearance, Icon, RenderOptionsProps, AlignType, ConfirmDialogChildInfo, ConfirmDialogOptions, ConfirmationDialogProps, FloatingToolbarButton, FloatingToolbarCopyButton, FloatingToolbarInput, FloatingToolbarCustom, FloatingToolbarCustomRenderContext, FloatingToolbarListPicker, FloatingToolbarColorPicker, FloatingToolbarEmojiPicker, FloatingToolbarDatePicker, FloatingToolbarSelect, FloatingToolbarSeparator, FloatingToolbarDropdown, FloatingToolbarFallbackItem, FloatingToolbarItem, FloatingToolbarConfig, FloatingToolbarHandler, typeOption, FloatingToolbarOverflowDropdown, FloatingToolbarOverflowDropdownOptions, OverflowDropdownHeading, OverflowDropdownOption, } from './floating-toolbar';
|
|
17
18
|
export type { MarkOptions, NodeOptions } from './copy-button';
|
|
18
19
|
export type { ContextPanelHandler } from './context-panel';
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import type { NextEditorPlugin } from './index';
|
|
2
|
+
/**
|
|
3
|
+
* Duck-typed mirror of `@atlassian/editor-plugin-markdown-mode`'s
|
|
4
|
+
* `MarkdownModePlugin`, covering all actions and `sharedState` fields
|
|
5
|
+
* declared by that plugin.
|
|
6
|
+
*
|
|
7
|
+
* We avoid importing the real type because `@atlaskit/editor-plugin-text-formatting`
|
|
8
|
+
* publishes to public npm while `@atlassian/editor-plugin-markdown-mode` only
|
|
9
|
+
* publishes to Atlassian's internal registry — re-exporting the cross-namespace
|
|
10
|
+
* type in this package's `.d.ts` would leave the type unresolvable for external
|
|
11
|
+
* consumers. TS structural typing means the real plugin (when loaded by the host)
|
|
12
|
+
* satisfies this stub, so runtime calls are still type-correct.
|
|
13
|
+
*
|
|
14
|
+
* Maintenance: this stub is NOT compile-time checked against the source-of-truth
|
|
15
|
+
* `MarkdownModePlugin` type. If markdown-mode renames, removes, or changes the
|
|
16
|
+
* signature of any of the actions/shared-state fields listed below, the mismatch
|
|
17
|
+
* surfaces only at runtime (stale toolbar state, no-op clicks). Keep the action
|
|
18
|
+
* signatures and `sharedState` fields here in sync with
|
|
19
|
+
* `@atlassian/editor-plugin-markdown-mode/src/markdownModePluginType.ts`.
|
|
20
|
+
*/
|
|
21
|
+
export type _MarkdownModePluginStub = NextEditorPlugin<'markdownMode', {
|
|
22
|
+
actions: {
|
|
23
|
+
dispatchSourceCommand: (cmd: unknown) => boolean;
|
|
24
|
+
registerSourceCommandDispatch: (dispatcher: ((cmd: unknown) => boolean) | null) => void;
|
|
25
|
+
setSourceBlockFormatState: (state: unknown) => void;
|
|
26
|
+
setSourceFormatState: (state: unknown) => void;
|
|
27
|
+
setSourceInlineFormatState: (state: unknown) => void;
|
|
28
|
+
setSourceListFormatState: (state: unknown) => void;
|
|
29
|
+
setView: (view: 'syntax' | 'split-view' | 'preview') => void;
|
|
30
|
+
toggleSourceBlockquote: () => boolean;
|
|
31
|
+
toggleSourceBold: () => boolean;
|
|
32
|
+
toggleSourceBulletList: () => boolean;
|
|
33
|
+
toggleSourceHeading: (level: 1 | 2 | 3 | 4 | 5 | 6) => boolean;
|
|
34
|
+
toggleSourceInlineCode: () => boolean;
|
|
35
|
+
toggleSourceItalic: () => boolean;
|
|
36
|
+
toggleSourceOrderedList: () => boolean;
|
|
37
|
+
toggleSourceStrike: () => boolean;
|
|
38
|
+
toggleSourceTaskList: () => boolean;
|
|
39
|
+
};
|
|
40
|
+
sharedState: {
|
|
41
|
+
isMarkdownMode: boolean;
|
|
42
|
+
sourceBlockFormatState: {
|
|
43
|
+
headingLevel: number | null;
|
|
44
|
+
inBlockquote: boolean;
|
|
45
|
+
inCodeBlock: boolean;
|
|
46
|
+
} | null;
|
|
47
|
+
sourceInlineFormatState: {
|
|
48
|
+
boldActive: boolean;
|
|
49
|
+
codeActive: boolean;
|
|
50
|
+
inlineFormattingAvailable: boolean;
|
|
51
|
+
italicActive: boolean;
|
|
52
|
+
strikeActive: boolean;
|
|
53
|
+
} | null;
|
|
54
|
+
sourceListFormatState: {
|
|
55
|
+
inBulletList: boolean;
|
|
56
|
+
inOrderedList: boolean;
|
|
57
|
+
inTaskList: boolean;
|
|
58
|
+
} | null;
|
|
59
|
+
view: 'syntax' | 'split-view' | 'preview';
|
|
60
|
+
} | undefined;
|
|
61
|
+
}>;
|
|
@@ -59,11 +59,6 @@ export declare const syncBlockMessages: {
|
|
|
59
59
|
description: string;
|
|
60
60
|
id: string;
|
|
61
61
|
};
|
|
62
|
-
syncBlockLabel: {
|
|
63
|
-
defaultMessage: string;
|
|
64
|
-
description: string;
|
|
65
|
-
id: string;
|
|
66
|
-
};
|
|
67
62
|
defaultSyncBlockTooltip: {
|
|
68
63
|
defaultMessage: string;
|
|
69
64
|
description: string;
|
|
@@ -249,6 +244,11 @@ export declare const syncBlockMessages: {
|
|
|
249
244
|
description: string;
|
|
250
245
|
id: string;
|
|
251
246
|
};
|
|
247
|
+
referenceSyncBlockSyncedFrom: {
|
|
248
|
+
defaultMessage: string;
|
|
249
|
+
description: string;
|
|
250
|
+
id: string;
|
|
251
|
+
};
|
|
252
252
|
referenceSyncBlockTooltip: {
|
|
253
253
|
defaultMessage: string;
|
|
254
254
|
description: string;
|
|
@@ -304,6 +304,11 @@ export declare const syncBlockMessages: {
|
|
|
304
304
|
description: string;
|
|
305
305
|
id: string;
|
|
306
306
|
};
|
|
307
|
+
syncBlockLabel: {
|
|
308
|
+
defaultMessage: string;
|
|
309
|
+
description: string;
|
|
310
|
+
id: string;
|
|
311
|
+
};
|
|
307
312
|
syncedBlockLabel: {
|
|
308
313
|
defaultMessage: string;
|
|
309
314
|
description: string;
|
|
@@ -4,7 +4,8 @@ import type { ExtractInjectionAPI, NextEditorPlugin } from '../types';
|
|
|
4
4
|
type Props = Pick<ToolbarUIContextType, 'popupsMountPoint' | 'popupsBoundariesElement' | 'popupsScrollableElement' | 'fireAnalyticsEvent' | 'keyboardNavigation'> & {
|
|
5
5
|
api: ExtractInjectionAPI<NextEditorPlugin<any, any>> | undefined;
|
|
6
6
|
children: React.ReactNode;
|
|
7
|
+
disabledWithoutInteractionLogic?: boolean;
|
|
7
8
|
isDisabled?: boolean;
|
|
8
9
|
};
|
|
9
|
-
export declare const EditorToolbarUIProvider: ({ children, api, isDisabled, popupsMountPoint, popupsBoundariesElement, popupsScrollableElement, fireAnalyticsEvent, keyboardNavigation, }: Props) => React.JSX.Element;
|
|
10
|
+
export declare const EditorToolbarUIProvider: ({ children, api, isDisabled, disabledWithoutInteractionLogic, popupsMountPoint, popupsBoundariesElement, popupsScrollableElement, fireAnalyticsEvent, keyboardNavigation, }: Props) => React.JSX.Element;
|
|
10
11
|
export {};
|
|
@@ -13,6 +13,7 @@ export type { FeatureFlags, FeatureFlagKey, GetEditorFeatureFlags } from './feat
|
|
|
13
13
|
export type { Browsers, Range, DisableSpellcheckByBrowser } from './supported-browsers';
|
|
14
14
|
export type { EditorContainerWidth, GetEditorContainerWidth } from './editor-container-width';
|
|
15
15
|
export type { EmptyStateHandler, EmptyStateHandlerParams } from './empty-state-handler';
|
|
16
|
+
export type { _MarkdownModePluginStub } from './markdown-mode-plugin-stub';
|
|
16
17
|
export type { RenderOptionsPropsT, DropdownOptionT, DropdownOptions, ExtensionDropdownOptions, SelectOption, ButtonAppearance, Icon, RenderOptionsProps, AlignType, ConfirmDialogChildInfo, ConfirmDialogOptions, ConfirmationDialogProps, FloatingToolbarButton, FloatingToolbarCopyButton, FloatingToolbarInput, FloatingToolbarCustom, FloatingToolbarCustomRenderContext, FloatingToolbarListPicker, FloatingToolbarColorPicker, FloatingToolbarEmojiPicker, FloatingToolbarDatePicker, FloatingToolbarSelect, FloatingToolbarSeparator, FloatingToolbarDropdown, FloatingToolbarFallbackItem, FloatingToolbarItem, FloatingToolbarConfig, FloatingToolbarHandler, typeOption, FloatingToolbarOverflowDropdown, FloatingToolbarOverflowDropdownOptions, OverflowDropdownHeading, OverflowDropdownOption, } from './floating-toolbar';
|
|
17
18
|
export type { MarkOptions, NodeOptions } from './copy-button';
|
|
18
19
|
export type { ContextPanelHandler } from './context-panel';
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import type { NextEditorPlugin } from './index';
|
|
2
|
+
/**
|
|
3
|
+
* Duck-typed mirror of `@atlassian/editor-plugin-markdown-mode`'s
|
|
4
|
+
* `MarkdownModePlugin`, covering all actions and `sharedState` fields
|
|
5
|
+
* declared by that plugin.
|
|
6
|
+
*
|
|
7
|
+
* We avoid importing the real type because `@atlaskit/editor-plugin-text-formatting`
|
|
8
|
+
* publishes to public npm while `@atlassian/editor-plugin-markdown-mode` only
|
|
9
|
+
* publishes to Atlassian's internal registry — re-exporting the cross-namespace
|
|
10
|
+
* type in this package's `.d.ts` would leave the type unresolvable for external
|
|
11
|
+
* consumers. TS structural typing means the real plugin (when loaded by the host)
|
|
12
|
+
* satisfies this stub, so runtime calls are still type-correct.
|
|
13
|
+
*
|
|
14
|
+
* Maintenance: this stub is NOT compile-time checked against the source-of-truth
|
|
15
|
+
* `MarkdownModePlugin` type. If markdown-mode renames, removes, or changes the
|
|
16
|
+
* signature of any of the actions/shared-state fields listed below, the mismatch
|
|
17
|
+
* surfaces only at runtime (stale toolbar state, no-op clicks). Keep the action
|
|
18
|
+
* signatures and `sharedState` fields here in sync with
|
|
19
|
+
* `@atlassian/editor-plugin-markdown-mode/src/markdownModePluginType.ts`.
|
|
20
|
+
*/
|
|
21
|
+
export type _MarkdownModePluginStub = NextEditorPlugin<'markdownMode', {
|
|
22
|
+
actions: {
|
|
23
|
+
dispatchSourceCommand: (cmd: unknown) => boolean;
|
|
24
|
+
registerSourceCommandDispatch: (dispatcher: ((cmd: unknown) => boolean) | null) => void;
|
|
25
|
+
setSourceBlockFormatState: (state: unknown) => void;
|
|
26
|
+
setSourceFormatState: (state: unknown) => void;
|
|
27
|
+
setSourceInlineFormatState: (state: unknown) => void;
|
|
28
|
+
setSourceListFormatState: (state: unknown) => void;
|
|
29
|
+
setView: (view: 'syntax' | 'split-view' | 'preview') => void;
|
|
30
|
+
toggleSourceBlockquote: () => boolean;
|
|
31
|
+
toggleSourceBold: () => boolean;
|
|
32
|
+
toggleSourceBulletList: () => boolean;
|
|
33
|
+
toggleSourceHeading: (level: 1 | 2 | 3 | 4 | 5 | 6) => boolean;
|
|
34
|
+
toggleSourceInlineCode: () => boolean;
|
|
35
|
+
toggleSourceItalic: () => boolean;
|
|
36
|
+
toggleSourceOrderedList: () => boolean;
|
|
37
|
+
toggleSourceStrike: () => boolean;
|
|
38
|
+
toggleSourceTaskList: () => boolean;
|
|
39
|
+
};
|
|
40
|
+
sharedState: {
|
|
41
|
+
isMarkdownMode: boolean;
|
|
42
|
+
sourceBlockFormatState: {
|
|
43
|
+
headingLevel: number | null;
|
|
44
|
+
inBlockquote: boolean;
|
|
45
|
+
inCodeBlock: boolean;
|
|
46
|
+
} | null;
|
|
47
|
+
sourceInlineFormatState: {
|
|
48
|
+
boldActive: boolean;
|
|
49
|
+
codeActive: boolean;
|
|
50
|
+
inlineFormattingAvailable: boolean;
|
|
51
|
+
italicActive: boolean;
|
|
52
|
+
strikeActive: boolean;
|
|
53
|
+
} | null;
|
|
54
|
+
sourceListFormatState: {
|
|
55
|
+
inBulletList: boolean;
|
|
56
|
+
inOrderedList: boolean;
|
|
57
|
+
inTaskList: boolean;
|
|
58
|
+
} | null;
|
|
59
|
+
view: 'syntax' | 'split-view' | 'preview';
|
|
60
|
+
} | undefined;
|
|
61
|
+
}>;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-common",
|
|
3
|
-
"version": "114.
|
|
3
|
+
"version": "114.51.1",
|
|
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/"
|
|
@@ -49,15 +49,15 @@
|
|
|
49
49
|
"@atlaskit/codemod-utils": "^4.3.0",
|
|
50
50
|
"@atlaskit/css": "^0.19.0",
|
|
51
51
|
"@atlaskit/custom-steps": "^0.17.0",
|
|
52
|
-
"@atlaskit/dropdown-menu": "^16.
|
|
52
|
+
"@atlaskit/dropdown-menu": "^16.10.0",
|
|
53
53
|
"@atlaskit/editor-json-transformer": "^8.33.0",
|
|
54
54
|
"@atlaskit/editor-palette": "^2.2.0",
|
|
55
55
|
"@atlaskit/editor-prosemirror": "^7.3.0",
|
|
56
56
|
"@atlaskit/editor-shared-styles": "^3.11.0",
|
|
57
57
|
"@atlaskit/editor-tables": "^2.10.0",
|
|
58
|
-
"@atlaskit/editor-toolbar": "^1.
|
|
58
|
+
"@atlaskit/editor-toolbar": "^1.9.0",
|
|
59
59
|
"@atlaskit/editor-toolbar-model": "^0.5.0",
|
|
60
|
-
"@atlaskit/emoji": "^70.
|
|
60
|
+
"@atlaskit/emoji": "^70.14.0",
|
|
61
61
|
"@atlaskit/icon": "^35.3.0",
|
|
62
62
|
"@atlaskit/link": "^3.4.0",
|
|
63
63
|
"@atlaskit/link-datasource": "^5.5.0",
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"@atlaskit/prosemirror-history": "^0.2.0",
|
|
82
82
|
"@atlaskit/react-ufo": "^6.4.0",
|
|
83
83
|
"@atlaskit/section-message": "^8.13.0",
|
|
84
|
-
"@atlaskit/smart-card": "^44.
|
|
84
|
+
"@atlaskit/smart-card": "^44.18.0",
|
|
85
85
|
"@atlaskit/smart-user-picker": "^10.2.0",
|
|
86
86
|
"@atlaskit/spinner": "^19.1.0",
|
|
87
87
|
"@atlaskit/task-decision": "^20.1.0",
|