@atlaskit/editor-plugin-floating-toolbar 10.0.0 → 10.0.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 +6 -0
- package/dist/cjs/pm-plugins/toolbar-data/plugin-factory.js +4 -4
- package/dist/cjs/ui/ConfirmationModal.js +2 -0
- package/dist/cjs/ui/Dropdown.js +1 -1
- package/dist/cjs/ui/DropdownMenu.js +2 -1
- package/dist/cjs/ui/Input.js +1 -1
- package/dist/cjs/ui/ScrollButtons.js +1 -1
- package/dist/cjs/ui/Toolbar.js +5 -2
- package/dist/es2019/pm-plugins/toolbar-data/plugin-factory.js +4 -5
- package/dist/es2019/ui/ConfirmationModal.js +2 -0
- package/dist/es2019/ui/Dropdown.js +1 -1
- package/dist/es2019/ui/DropdownMenu.js +2 -1
- package/dist/es2019/ui/Input.js +1 -1
- package/dist/es2019/ui/ScrollButtons.js +1 -1
- package/dist/es2019/ui/Toolbar.js +6 -1
- package/dist/esm/pm-plugins/toolbar-data/plugin-factory.js +4 -5
- package/dist/esm/ui/ConfirmationModal.js +2 -0
- package/dist/esm/ui/Dropdown.js +1 -1
- package/dist/esm/ui/DropdownMenu.js +2 -1
- package/dist/esm/ui/Input.js +1 -1
- package/dist/esm/ui/ScrollButtons.js +1 -1
- package/dist/esm/ui/Toolbar.js +5 -2
- package/dist/types/pm-plugins/force-focus/index.d.ts +1 -1
- package/dist/types/pm-plugins/toolbar-data/plugin-factory.d.ts +8 -1
- package/dist/types/pm-plugins/toolbar-data/plugin.d.ts +2 -1
- package/dist/types/ui/ConfirmationModal.d.ts +2 -2
- package/dist/types/ui/DropdownMenu.d.ts +9 -4
- package/dist/types/ui/Toolbar.d.ts +3 -3
- package/dist/types-ts4.5/pm-plugins/force-focus/index.d.ts +1 -1
- package/dist/types-ts4.5/pm-plugins/toolbar-data/plugin-factory.d.ts +8 -1
- package/dist/types-ts4.5/pm-plugins/toolbar-data/plugin.d.ts +2 -1
- package/dist/types-ts4.5/ui/ConfirmationModal.d.ts +2 -2
- package/dist/types-ts4.5/ui/DropdownMenu.d.ts +9 -4
- package/dist/types-ts4.5/ui/Toolbar.d.ts +3 -3
- package/package.json +3 -3
package/CHANGELOG.md
CHANGED
|
@@ -7,7 +7,7 @@ exports.getPluginState = exports.createPluginState = exports.createCommand = voi
|
|
|
7
7
|
var _utils = require("@atlaskit/editor-common/utils");
|
|
8
8
|
var _pluginKey = require("./plugin-key");
|
|
9
9
|
var _reducer = require("./reducer");
|
|
10
|
-
var
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
10
|
+
var dest = (0, _utils.pluginFactory)(_pluginKey.pluginKey, _reducer.reducer);
|
|
11
|
+
var createPluginState = exports.createPluginState = dest.createPluginState;
|
|
12
|
+
var createCommand = exports.createCommand = dest.createCommand;
|
|
13
|
+
var getPluginState = exports.getPluginState = dest.getPluginState;
|
|
@@ -24,4 +24,6 @@ var ConfirmationModalImpl = function ConfirmationModalImpl(props) {
|
|
|
24
24
|
};
|
|
25
25
|
return options ? /*#__PURE__*/_react.default.createElement(_modalDialog.ModalTransition, null, renderModel(options === null || options === void 0 ? void 0 : options.isReferentialityDialog)) : null;
|
|
26
26
|
};
|
|
27
|
+
|
|
28
|
+
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
27
29
|
var ConfirmationModal = exports.ConfirmationModal = (0, _reactIntlNext.injectIntl)(ConfirmationModalImpl);
|
package/dist/cjs/ui/Dropdown.js
CHANGED
|
@@ -27,7 +27,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
27
27
|
* @jsxRuntime classic
|
|
28
28
|
* @jsx jsx
|
|
29
29
|
* @jsxFrag
|
|
30
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
30
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
|
|
31
31
|
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
32
32
|
var dropdownExpandContainer = (0, _react2.css)({
|
|
33
33
|
margin: "0px ".concat("var(--ds-space-negative-050, -4px)")
|
|
@@ -123,4 +123,5 @@ var Dropdown = /*#__PURE__*/(0, _react.memo)(function (props) {
|
|
|
123
123
|
});
|
|
124
124
|
}));
|
|
125
125
|
});
|
|
126
|
-
var
|
|
126
|
+
var _default_1 = (0, _reactIntlNext.injectIntl)(Dropdown);
|
|
127
|
+
var _default = exports.default = _default_1;
|
package/dist/cjs/ui/Input.js
CHANGED
|
@@ -16,7 +16,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
16
16
|
* @jsx jsx
|
|
17
17
|
*/
|
|
18
18
|
|
|
19
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
19
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
|
|
20
20
|
|
|
21
21
|
var Input = exports.Input = function Input(props) {
|
|
22
22
|
var defaultValue = props.defaultValue,
|
|
@@ -21,7 +21,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
21
21
|
* @jsx jsx
|
|
22
22
|
*/
|
|
23
23
|
|
|
24
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
24
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
|
|
25
25
|
|
|
26
26
|
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
27
27
|
var toolbarScrollButtons = (0, _react2.css)({
|
package/dist/cjs/ui/Toolbar.js
CHANGED
|
@@ -572,7 +572,9 @@ var Toolbar = /*#__PURE__*/function (_Component) {
|
|
|
572
572
|
// focus the editorview.
|
|
573
573
|
// Event can't be stopped as they are not childnodes of floating toolbar
|
|
574
574
|
|
|
575
|
+
// eslint-disable-next-line @atlaskit/platform/no-direct-document-usage
|
|
575
576
|
var isDropdownOpen = !!document.querySelector('[data-role="droplistContent"]');
|
|
577
|
+
// eslint-disable-next-line @atlaskit/platform/no-direct-document-usage
|
|
576
578
|
var isSelectMenuOpen = !!document.querySelector('.floating-toolbar-select__menu');
|
|
577
579
|
if (isDropdownOpen || isSelectMenuOpen) {
|
|
578
580
|
return;
|
|
@@ -757,5 +759,6 @@ var Toolbar = /*#__PURE__*/function (_Component) {
|
|
|
757
759
|
})));
|
|
758
760
|
}
|
|
759
761
|
}]);
|
|
760
|
-
}(_react.Component);
|
|
761
|
-
var
|
|
762
|
+
}(_react.Component); // eslint-disable-next-line @typescript-eslint/ban-types
|
|
763
|
+
var _default_1 = (0, _reactIntlNext.injectIntl)(Toolbar);
|
|
764
|
+
var _default = exports.default = _default_1;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { pluginFactory } from '@atlaskit/editor-common/utils';
|
|
2
2
|
import { pluginKey } from './plugin-key';
|
|
3
3
|
import { reducer } from './reducer';
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
} = pluginFactory(pluginKey, reducer);
|
|
4
|
+
const dest = pluginFactory(pluginKey, reducer);
|
|
5
|
+
export const createPluginState = dest.createPluginState;
|
|
6
|
+
export const createCommand = dest.createCommand;
|
|
7
|
+
export const getPluginState = dest.getPluginState;
|
|
@@ -15,4 +15,6 @@ const ConfirmationModalImpl = props => {
|
|
|
15
15
|
isReferentialityDialog ? /*#__PURE__*/React.createElement(CheckboxModal, props) : /*#__PURE__*/React.createElement(SimpleModal, props);
|
|
16
16
|
return options ? /*#__PURE__*/React.createElement(ModalTransition, null, renderModel(options === null || options === void 0 ? void 0 : options.isReferentialityDialog)) : null;
|
|
17
17
|
};
|
|
18
|
+
|
|
19
|
+
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
18
20
|
export const ConfirmationModal = injectIntl(ConfirmationModalImpl);
|
|
@@ -7,7 +7,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
7
7
|
|
|
8
8
|
import React, { Component } from 'react';
|
|
9
9
|
|
|
10
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
10
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
|
|
11
11
|
import { css, jsx } from '@emotion/react';
|
|
12
12
|
import { FloatingToolbarButton as Button } from '@atlaskit/editor-common/ui';
|
|
13
13
|
import { ArrowKeyNavigationType, DropdownContainer as UiDropdown } from '@atlaskit/editor-common/ui-menu';
|
package/dist/es2019/ui/Input.js
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import React, { useState } from 'react';
|
|
6
6
|
|
|
7
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
7
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
|
|
8
8
|
import { jsx } from '@emotion/react';
|
|
9
9
|
import { panelTextInput } from '@atlaskit/editor-common/ui';
|
|
10
10
|
export const Input = props => {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import React, { useEffect, useRef, useState } from 'react';
|
|
6
6
|
|
|
7
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
7
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
|
|
8
8
|
import { css, jsx } from '@emotion/react';
|
|
9
9
|
import rafSchedule from 'raf-schd';
|
|
10
10
|
import { messages } from '@atlaskit/editor-common/floating-toolbar';
|
|
@@ -532,7 +532,9 @@ class Toolbar extends Component {
|
|
|
532
532
|
// focus the editorview.
|
|
533
533
|
// Event can't be stopped as they are not childnodes of floating toolbar
|
|
534
534
|
|
|
535
|
+
// eslint-disable-next-line @atlaskit/platform/no-direct-document-usage
|
|
535
536
|
const isDropdownOpen = !!document.querySelector('[data-role="droplistContent"]');
|
|
537
|
+
// eslint-disable-next-line @atlaskit/platform/no-direct-document-usage
|
|
536
538
|
const isSelectMenuOpen = !!document.querySelector('.floating-toolbar-select__menu');
|
|
537
539
|
if (isDropdownOpen || isSelectMenuOpen) {
|
|
538
540
|
return;
|
|
@@ -706,4 +708,7 @@ class Toolbar extends Component {
|
|
|
706
708
|
})));
|
|
707
709
|
}
|
|
708
710
|
}
|
|
709
|
-
|
|
711
|
+
|
|
712
|
+
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
713
|
+
const _default_1 = injectIntl(Toolbar);
|
|
714
|
+
export default _default_1;
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
import { pluginFactory } from '@atlaskit/editor-common/utils';
|
|
2
2
|
import { pluginKey } from './plugin-key';
|
|
3
3
|
import { reducer } from './reducer';
|
|
4
|
-
var
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
export { createPluginState, createCommand, getPluginState };
|
|
4
|
+
var dest = pluginFactory(pluginKey, reducer);
|
|
5
|
+
export var createPluginState = dest.createPluginState;
|
|
6
|
+
export var createCommand = dest.createCommand;
|
|
7
|
+
export var getPluginState = dest.getPluginState;
|
|
@@ -17,4 +17,6 @@ var ConfirmationModalImpl = function ConfirmationModalImpl(props) {
|
|
|
17
17
|
};
|
|
18
18
|
return options ? /*#__PURE__*/React.createElement(ModalTransition, null, renderModel(options === null || options === void 0 ? void 0 : options.isReferentialityDialog)) : null;
|
|
19
19
|
};
|
|
20
|
+
|
|
21
|
+
// eslint-disable-next-line @typescript-eslint/ban-types
|
|
20
22
|
export var ConfirmationModal = injectIntl(ConfirmationModalImpl);
|
package/dist/esm/ui/Dropdown.js
CHANGED
|
@@ -16,7 +16,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
16
16
|
|
|
17
17
|
import React, { Component } from 'react';
|
|
18
18
|
|
|
19
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
19
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
|
|
20
20
|
import { css, jsx } from '@emotion/react';
|
|
21
21
|
import { FloatingToolbarButton as Button } from '@atlaskit/editor-common/ui';
|
|
22
22
|
import { ArrowKeyNavigationType, DropdownContainer as UiDropdown } from '@atlaskit/editor-common/ui-menu';
|
package/dist/esm/ui/Input.js
CHANGED
|
@@ -5,7 +5,7 @@ import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
|
5
5
|
*/
|
|
6
6
|
import React, { useState } from 'react';
|
|
7
7
|
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
|
|
9
9
|
import { jsx } from '@emotion/react';
|
|
10
10
|
import { panelTextInput } from '@atlaskit/editor-common/ui';
|
|
11
11
|
export var Input = function Input(props) {
|
|
@@ -5,7 +5,7 @@ import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
|
5
5
|
*/
|
|
6
6
|
import React, { useEffect, useRef, useState } from 'react';
|
|
7
7
|
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports
|
|
9
9
|
import { css, jsx } from '@emotion/react';
|
|
10
10
|
import rafSchedule from 'raf-schd';
|
|
11
11
|
import { messages } from '@atlaskit/editor-common/floating-toolbar';
|
package/dist/esm/ui/Toolbar.js
CHANGED
|
@@ -566,7 +566,9 @@ var Toolbar = /*#__PURE__*/function (_Component) {
|
|
|
566
566
|
// focus the editorview.
|
|
567
567
|
// Event can't be stopped as they are not childnodes of floating toolbar
|
|
568
568
|
|
|
569
|
+
// eslint-disable-next-line @atlaskit/platform/no-direct-document-usage
|
|
569
570
|
var isDropdownOpen = !!document.querySelector('[data-role="droplistContent"]');
|
|
571
|
+
// eslint-disable-next-line @atlaskit/platform/no-direct-document-usage
|
|
570
572
|
var isSelectMenuOpen = !!document.querySelector('.floating-toolbar-select__menu');
|
|
571
573
|
if (isDropdownOpen || isSelectMenuOpen) {
|
|
572
574
|
return;
|
|
@@ -751,5 +753,6 @@ var Toolbar = /*#__PURE__*/function (_Component) {
|
|
|
751
753
|
})));
|
|
752
754
|
}
|
|
753
755
|
}]);
|
|
754
|
-
}(Component);
|
|
755
|
-
|
|
756
|
+
}(Component); // eslint-disable-next-line @typescript-eslint/ban-types
|
|
757
|
+
var _default_1 = injectIntl(Toolbar);
|
|
758
|
+
export default _default_1;
|
|
@@ -2,7 +2,7 @@ import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
|
2
2
|
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
3
|
import { PluginKey } from '@atlaskit/editor-prosemirror/state';
|
|
4
4
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
5
|
-
export declare const forceFocusStateKey: PluginKey
|
|
5
|
+
export declare const forceFocusStateKey: PluginKey;
|
|
6
6
|
/**
|
|
7
7
|
* Used in cases where a floating toolbar button opens a submenu which destroys
|
|
8
8
|
* the button, but the user has pressed ESC to close the submenu and focus needs
|
|
@@ -1 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
import type { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
2
|
+
import type { Command } from '@atlaskit/editor-common/types';
|
|
3
|
+
import type { EditorState, SafeStateField, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
4
|
+
import type { FloatingToolbarPluginData } from '../../floatingToolbarPluginType';
|
|
5
|
+
import type { FloatingToolbarPluginAction } from './types';
|
|
6
|
+
export declare const createPluginState: (dispatch: Dispatch, initialState: FloatingToolbarPluginData | ((state: EditorState) => FloatingToolbarPluginData)) => SafeStateField<FloatingToolbarPluginData>;
|
|
7
|
+
export declare const createCommand: <A = FloatingToolbarPluginAction>(action: A | ((state: Readonly<EditorState>) => false | A), transform?: (tr: Transaction, state: EditorState) => Transaction) => Command;
|
|
8
|
+
export declare const getPluginState: (state: EditorState) => FloatingToolbarPluginData;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import type { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
2
2
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
3
|
-
|
|
3
|
+
import type { FloatingToolbarPluginData } from '../../floatingToolbarPluginType';
|
|
4
|
+
export declare const createPlugin: (dispatch: Dispatch) => SafePlugin<FloatingToolbarPluginData>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { WrappedComponentProps } from 'react-intl-next';
|
|
2
|
+
import type { WithIntlProps, WrappedComponentProps } from 'react-intl-next';
|
|
3
3
|
import type { ConfirmationDialogProps } from '@atlaskit/editor-common/types';
|
|
4
|
-
export declare const ConfirmationModal: React.FC<
|
|
4
|
+
export declare const ConfirmationModal: React.FC<WithIntlProps<ConfirmationDialogProps & WrappedComponentProps>> & {
|
|
5
5
|
WrappedComponent: React.ComponentType<ConfirmationDialogProps & WrappedComponentProps>;
|
|
6
6
|
};
|
|
@@ -1,4 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
4
|
+
*/
|
|
5
|
+
import { type ComponentType, type FC } from 'react';
|
|
6
|
+
import type { WithIntlProps, WrappedComponentProps } from 'react-intl-next';
|
|
2
7
|
import type { ExtensionAPI, ExtensionProvider } from '@atlaskit/editor-common/extensions';
|
|
3
8
|
import type { DropdownOptionT, FloatingToolbarOverflowDropdownOptions } from '@atlaskit/editor-common/types';
|
|
4
9
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
@@ -28,7 +33,7 @@ export interface DropdownButtonItemProps extends ButtonItemProps {
|
|
|
28
33
|
onMouseOut?: (event: React.MouseEvent | React.KeyboardEvent) => void;
|
|
29
34
|
onMouseOver?: (event: React.MouseEvent | React.KeyboardEvent) => void;
|
|
30
35
|
}
|
|
31
|
-
declare const
|
|
32
|
-
WrappedComponent:
|
|
36
|
+
declare const _default_1: FC<WithIntlProps<Props & WrappedComponentProps>> & {
|
|
37
|
+
WrappedComponent: ComponentType<Props & WrappedComponentProps>;
|
|
33
38
|
};
|
|
34
|
-
export default
|
|
39
|
+
export default _default_1;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
|
-
import type { WrappedComponentProps } from 'react-intl-next';
|
|
6
|
+
import type { WithIntlProps, WrappedComponentProps } from 'react-intl-next';
|
|
7
7
|
import type { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
8
8
|
import type { ExtensionProvider } from '@atlaskit/editor-common/extensions';
|
|
9
9
|
import type { Item } from '@atlaskit/editor-common/floating-toolbar';
|
|
@@ -38,7 +38,7 @@ export interface State {
|
|
|
38
38
|
mounted: boolean;
|
|
39
39
|
scrollDisabled: boolean;
|
|
40
40
|
}
|
|
41
|
-
declare const
|
|
41
|
+
declare const _default_1: React.FC<WithIntlProps<Props & WrappedComponentProps>> & {
|
|
42
42
|
WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
|
|
43
43
|
};
|
|
44
|
-
export default
|
|
44
|
+
export default _default_1;
|
|
@@ -2,7 +2,7 @@ import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
|
2
2
|
import type { Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
3
3
|
import { PluginKey } from '@atlaskit/editor-prosemirror/state';
|
|
4
4
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
5
|
-
export declare const forceFocusStateKey: PluginKey
|
|
5
|
+
export declare const forceFocusStateKey: PluginKey;
|
|
6
6
|
/**
|
|
7
7
|
* Used in cases where a floating toolbar button opens a submenu which destroys
|
|
8
8
|
* the button, but the user has pressed ESC to close the submenu and focus needs
|
|
@@ -1 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
import type { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
2
|
+
import type { Command } from '@atlaskit/editor-common/types';
|
|
3
|
+
import type { EditorState, SafeStateField, Transaction } from '@atlaskit/editor-prosemirror/state';
|
|
4
|
+
import type { FloatingToolbarPluginData } from '../../floatingToolbarPluginType';
|
|
5
|
+
import type { FloatingToolbarPluginAction } from './types';
|
|
6
|
+
export declare const createPluginState: (dispatch: Dispatch, initialState: FloatingToolbarPluginData | ((state: EditorState) => FloatingToolbarPluginData)) => SafeStateField<FloatingToolbarPluginData>;
|
|
7
|
+
export declare const createCommand: <A = FloatingToolbarPluginAction>(action: A | ((state: Readonly<EditorState>) => false | A), transform?: (tr: Transaction, state: EditorState) => Transaction) => Command;
|
|
8
|
+
export declare const getPluginState: (state: EditorState) => FloatingToolbarPluginData;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import type { Dispatch } from '@atlaskit/editor-common/event-dispatcher';
|
|
2
2
|
import { SafePlugin } from '@atlaskit/editor-common/safe-plugin';
|
|
3
|
-
|
|
3
|
+
import type { FloatingToolbarPluginData } from '../../floatingToolbarPluginType';
|
|
4
|
+
export declare const createPlugin: (dispatch: Dispatch) => SafePlugin<FloatingToolbarPluginData>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { WrappedComponentProps } from 'react-intl-next';
|
|
2
|
+
import type { WithIntlProps, WrappedComponentProps } from 'react-intl-next';
|
|
3
3
|
import type { ConfirmationDialogProps } from '@atlaskit/editor-common/types';
|
|
4
|
-
export declare const ConfirmationModal: React.FC<
|
|
4
|
+
export declare const ConfirmationModal: React.FC<WithIntlProps<ConfirmationDialogProps & WrappedComponentProps>> & {
|
|
5
5
|
WrappedComponent: React.ComponentType<ConfirmationDialogProps & WrappedComponentProps>;
|
|
6
6
|
};
|
|
@@ -1,4 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
4
|
+
*/
|
|
5
|
+
import { type ComponentType, type FC } from 'react';
|
|
6
|
+
import type { WithIntlProps, WrappedComponentProps } from 'react-intl-next';
|
|
2
7
|
import type { ExtensionAPI, ExtensionProvider } from '@atlaskit/editor-common/extensions';
|
|
3
8
|
import type { DropdownOptionT, FloatingToolbarOverflowDropdownOptions } from '@atlaskit/editor-common/types';
|
|
4
9
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
@@ -28,7 +33,7 @@ export interface DropdownButtonItemProps extends ButtonItemProps {
|
|
|
28
33
|
onMouseOut?: (event: React.MouseEvent | React.KeyboardEvent) => void;
|
|
29
34
|
onMouseOver?: (event: React.MouseEvent | React.KeyboardEvent) => void;
|
|
30
35
|
}
|
|
31
|
-
declare const
|
|
32
|
-
WrappedComponent:
|
|
36
|
+
declare const _default_1: FC<WithIntlProps<Props & WrappedComponentProps>> & {
|
|
37
|
+
WrappedComponent: ComponentType<Props & WrappedComponentProps>;
|
|
33
38
|
};
|
|
34
|
-
export default
|
|
39
|
+
export default _default_1;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
|
-
import type { WrappedComponentProps } from 'react-intl-next';
|
|
6
|
+
import type { WithIntlProps, WrappedComponentProps } from 'react-intl-next';
|
|
7
7
|
import type { DispatchAnalyticsEvent } from '@atlaskit/editor-common/analytics';
|
|
8
8
|
import type { ExtensionProvider } from '@atlaskit/editor-common/extensions';
|
|
9
9
|
import type { Item } from '@atlaskit/editor-common/floating-toolbar';
|
|
@@ -38,7 +38,7 @@ export interface State {
|
|
|
38
38
|
mounted: boolean;
|
|
39
39
|
scrollDisabled: boolean;
|
|
40
40
|
}
|
|
41
|
-
declare const
|
|
41
|
+
declare const _default_1: React.FC<WithIntlProps<Props & WrappedComponentProps>> & {
|
|
42
42
|
WrappedComponent: React.ComponentType<Props & WrappedComponentProps>;
|
|
43
43
|
};
|
|
44
|
-
export default
|
|
44
|
+
export default _default_1;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-floating-toolbar",
|
|
3
|
-
"version": "10.0.
|
|
3
|
+
"version": "10.0.1",
|
|
4
4
|
"description": "Floating toolbar plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -42,9 +42,9 @@
|
|
|
42
42
|
"@atlaskit/modal-dialog": "^14.11.0",
|
|
43
43
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
44
44
|
"@atlaskit/primitives": "^18.0.0",
|
|
45
|
-
"@atlaskit/select": "^21.
|
|
45
|
+
"@atlaskit/select": "^21.8.0",
|
|
46
46
|
"@atlaskit/theme": "^22.0.0",
|
|
47
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
47
|
+
"@atlaskit/tmp-editor-statsig": "^36.0.0",
|
|
48
48
|
"@atlaskit/tokens": "^11.1.0",
|
|
49
49
|
"@atlaskit/tooltip": "^20.14.0",
|
|
50
50
|
"@babel/runtime": "^7.0.0",
|