@atlaskit/editor-plugin-text-formatting 1.16.2 → 1.16.3
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/plugin.js +2 -1
- package/dist/cjs/ui/FloatingToolbarComponent.js +2 -1
- package/dist/cjs/ui/Toolbar/bold-button.js +5 -2
- package/dist/cjs/ui/Toolbar/constants.js +2 -0
- package/dist/cjs/ui/Toolbar/dropdown-menu.js +4 -2
- package/dist/cjs/ui/Toolbar/index.js +2 -1
- package/dist/es2019/plugin.js +2 -1
- package/dist/es2019/ui/FloatingToolbarComponent.js +2 -1
- package/dist/es2019/ui/Toolbar/bold-button.js +5 -2
- package/dist/es2019/ui/Toolbar/constants.js +2 -0
- package/dist/es2019/ui/Toolbar/dropdown-menu.js +4 -2
- package/dist/es2019/ui/Toolbar/index.js +2 -1
- package/dist/esm/plugin.js +2 -1
- package/dist/esm/ui/FloatingToolbarComponent.js +2 -1
- package/dist/esm/ui/Toolbar/bold-button.js +5 -2
- package/dist/esm/ui/Toolbar/constants.js +2 -0
- package/dist/esm/ui/Toolbar/dropdown-menu.js +4 -2
- package/dist/esm/ui/Toolbar/index.js +2 -1
- package/dist/types/ui/Toolbar/bold-button.d.ts +3 -1
- package/dist/types/ui/Toolbar/dropdown-menu.d.ts +3 -2
- package/dist/types-ts4.5/ui/Toolbar/bold-button.d.ts +3 -1
- package/dist/types-ts4.5/ui/Toolbar/dropdown-menu.d.ts +3 -2
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-text-formatting
|
|
2
2
|
|
|
3
|
+
## 1.16.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#172933](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/172933)
|
|
8
|
+
[`8323af2381d00`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8323af2381d00) -
|
|
9
|
+
[ux] Arranges items in the Selection toolbar under the Contextual toolbar experiment flag
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
3
12
|
## 1.16.2
|
|
4
13
|
|
|
5
14
|
### Patch Changes
|
package/dist/cjs/plugin.js
CHANGED
|
@@ -65,7 +65,8 @@ var FloatingToolbarTextFormat = function FloatingToolbarTextFormat(_ref) {
|
|
|
65
65
|
moreButtonLabel: FloatingToolbarSettings.moreButtonLabel,
|
|
66
66
|
hasFormattingActive: FloatingToolbarSettings.hasMoreButton,
|
|
67
67
|
hasMoreButton: FloatingToolbarSettings.hasMoreButton,
|
|
68
|
-
intl: intl
|
|
68
|
+
intl: intl,
|
|
69
|
+
toolbarType: FloatingToolbarSettings.toolbarType
|
|
69
70
|
});
|
|
70
71
|
};
|
|
71
72
|
var FloatingToolbarTextFormalWithIntl = exports.FloatingToolbarTextFormalWithIntl = (0, _reactIntlNext.injectIntl)(FloatingToolbarTextFormat);
|
|
@@ -12,6 +12,7 @@ var _uiMenu = require("@atlaskit/editor-common/ui-menu");
|
|
|
12
12
|
var _textBoldEditorBold = _interopRequireDefault(require("@atlaskit/icon/core/migration/text-bold--editor-bold"));
|
|
13
13
|
var _chevronDown = _interopRequireDefault(require("@atlaskit/icon/utility/migration/chevron-down"));
|
|
14
14
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
15
|
+
var _types = require("./types");
|
|
15
16
|
/**
|
|
16
17
|
* @jsxRuntime classic
|
|
17
18
|
* @jsx jsx
|
|
@@ -26,10 +27,12 @@ var BoldToolbarButton = exports.BoldToolbarButton = function BoldToolbarButton(_
|
|
|
26
27
|
isSelected = _ref.isSelected,
|
|
27
28
|
ariaExpanded = _ref['aria-expanded'],
|
|
28
29
|
onClick = _ref.onClick,
|
|
29
|
-
onKeyDown = _ref.onKeyDown
|
|
30
|
+
onKeyDown = _ref.onKeyDown,
|
|
31
|
+
toolbarType = _ref.toolbarType;
|
|
32
|
+
var reducedSpacing = toolbarType === _types.ToolbarType.FLOATING ? 'compact' : 'none';
|
|
30
33
|
return (0, _react2.jsx)(_uiMenu.ToolbarButton, {
|
|
31
34
|
testId: 'ak-editor-selection-toolbar-format-text-button',
|
|
32
|
-
spacing: isReducedSpacing ?
|
|
35
|
+
spacing: isReducedSpacing ? reducedSpacing : 'default',
|
|
33
36
|
disabled: isDisabled,
|
|
34
37
|
selected: isSelected,
|
|
35
38
|
"aria-label": label,
|
|
@@ -12,12 +12,14 @@ var _ResponsiveCustomButt, _ResponsiveCustomMenu, _ResponsiveCustomButt2, _Respo
|
|
|
12
12
|
var DefaultButtonsToolbar = exports.DefaultButtonsToolbar = [_types2.IconTypes.strong, _types2.IconTypes.em];
|
|
13
13
|
var DefaultButtonsMenu = exports.DefaultButtonsMenu = [_types2.IconTypes.underline, _types2.IconTypes.strike, _types2.IconTypes.code, _types2.IconTypes.subscript, _types2.IconTypes.superscript];
|
|
14
14
|
|
|
15
|
+
// eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required -- Ignored via go/ED-25883
|
|
15
16
|
/** @deprecated
|
|
16
17
|
* To be removed as part of ED-25129 in favour of ResponsiveCustomButtonToolbarNext along with references
|
|
17
18
|
* to platform_editor_toolbar_responsive_fixes feature gate
|
|
18
19
|
*/
|
|
19
20
|
var ResponsiveCustomButtonToolbar = exports.ResponsiveCustomButtonToolbar = (_ResponsiveCustomButt = {}, (0, _defineProperty2.default)(_ResponsiveCustomButt, _types.ToolbarSize.XXL, DefaultButtonsToolbar), (0, _defineProperty2.default)(_ResponsiveCustomButt, _types.ToolbarSize.XL, DefaultButtonsToolbar), (0, _defineProperty2.default)(_ResponsiveCustomButt, _types.ToolbarSize.L, DefaultButtonsToolbar), (0, _defineProperty2.default)(_ResponsiveCustomButt, _types.ToolbarSize.M, []), (0, _defineProperty2.default)(_ResponsiveCustomButt, _types.ToolbarSize.S, []), (0, _defineProperty2.default)(_ResponsiveCustomButt, _types.ToolbarSize.XXXS, []), _ResponsiveCustomButt);
|
|
20
21
|
|
|
22
|
+
// eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required -- Ignored via go/ED-25883
|
|
21
23
|
/** @deprecated
|
|
22
24
|
* To be removed as part of ED-25129 in favour of ResponsiveCustomButtonToolbarNext along with references
|
|
23
25
|
* to platform_editor_toolbar_responsive_fixes feature gate
|
|
@@ -26,7 +26,8 @@ var FormattingTextDropdownMenu = exports.FormattingTextDropdownMenu = /*#__PURE_
|
|
|
26
26
|
popupsMountPoint = _ref.popupsMountPoint,
|
|
27
27
|
popupsScrollableElement = _ref.popupsScrollableElement,
|
|
28
28
|
hasMoreButton = _ref.hasMoreButton,
|
|
29
|
-
intl = _ref.intl
|
|
29
|
+
intl = _ref.intl,
|
|
30
|
+
toolbarType = _ref.toolbarType;
|
|
30
31
|
var _useMenuState = (0, _menuState.useMenuState)(),
|
|
31
32
|
_useMenuState2 = (0, _slicedToArray2.default)(_useMenuState, 3),
|
|
32
33
|
isMenuOpen = _useMenuState2[0],
|
|
@@ -104,6 +105,7 @@ var FormattingTextDropdownMenu = exports.FormattingTextDropdownMenu = /*#__PURE_
|
|
|
104
105
|
toggleMenu();
|
|
105
106
|
setIsOpenedByKeyboard(true);
|
|
106
107
|
}
|
|
107
|
-
}
|
|
108
|
+
},
|
|
109
|
+
toolbarType: toolbarType
|
|
108
110
|
}));
|
|
109
111
|
});
|
|
@@ -168,7 +168,8 @@ var ToolbarFormatting = function ToolbarFormatting(_ref) {
|
|
|
168
168
|
hasFormattingActive: hasFormattingActive,
|
|
169
169
|
hasMoreButton: true,
|
|
170
170
|
items: items,
|
|
171
|
-
intl: intl
|
|
171
|
+
intl: intl,
|
|
172
|
+
toolbarType: toolbarType
|
|
172
173
|
}))), !(api !== null && api !== void 0 && api.primaryToolbar) && /* eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage */
|
|
173
174
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
|
|
174
175
|
(0, _react2.jsx)("span", {
|
package/dist/es2019/plugin.js
CHANGED
|
@@ -58,7 +58,8 @@ const FloatingToolbarTextFormat = ({
|
|
|
58
58
|
moreButtonLabel: FloatingToolbarSettings.moreButtonLabel,
|
|
59
59
|
hasFormattingActive: FloatingToolbarSettings.hasMoreButton,
|
|
60
60
|
hasMoreButton: FloatingToolbarSettings.hasMoreButton,
|
|
61
|
-
intl: intl
|
|
61
|
+
intl: intl,
|
|
62
|
+
toolbarType: FloatingToolbarSettings.toolbarType
|
|
62
63
|
});
|
|
63
64
|
};
|
|
64
65
|
export const FloatingToolbarTextFormalWithIntl = injectIntl(FloatingToolbarTextFormat);
|
|
@@ -11,6 +11,7 @@ import { ToolbarButton } from '@atlaskit/editor-common/ui-menu';
|
|
|
11
11
|
import BoldIcon from '@atlaskit/icon/core/migration/text-bold--editor-bold';
|
|
12
12
|
import ChevronDownIcon from '@atlaskit/icon/utility/migration/chevron-down';
|
|
13
13
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
14
|
+
import { ToolbarType } from './types';
|
|
14
15
|
export const BoldToolbarButton = ({
|
|
15
16
|
label,
|
|
16
17
|
isReducedSpacing,
|
|
@@ -18,11 +19,13 @@ export const BoldToolbarButton = ({
|
|
|
18
19
|
isSelected,
|
|
19
20
|
'aria-expanded': ariaExpanded,
|
|
20
21
|
onClick,
|
|
21
|
-
onKeyDown
|
|
22
|
+
onKeyDown,
|
|
23
|
+
toolbarType
|
|
22
24
|
}) => {
|
|
25
|
+
const reducedSpacing = toolbarType === ToolbarType.FLOATING ? 'compact' : 'none';
|
|
23
26
|
return jsx(ToolbarButton, {
|
|
24
27
|
testId: 'ak-editor-selection-toolbar-format-text-button',
|
|
25
|
-
spacing: isReducedSpacing ?
|
|
28
|
+
spacing: isReducedSpacing ? reducedSpacing : 'default',
|
|
26
29
|
disabled: isDisabled,
|
|
27
30
|
selected: isSelected,
|
|
28
31
|
"aria-label": label,
|
|
@@ -3,6 +3,7 @@ import { IconTypes } from './types';
|
|
|
3
3
|
export const DefaultButtonsToolbar = [IconTypes.strong, IconTypes.em];
|
|
4
4
|
export const DefaultButtonsMenu = [IconTypes.underline, IconTypes.strike, IconTypes.code, IconTypes.subscript, IconTypes.superscript];
|
|
5
5
|
|
|
6
|
+
// eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required -- Ignored via go/ED-25883
|
|
6
7
|
/** @deprecated
|
|
7
8
|
* To be removed as part of ED-25129 in favour of ResponsiveCustomButtonToolbarNext along with references
|
|
8
9
|
* to platform_editor_toolbar_responsive_fixes feature gate
|
|
@@ -16,6 +17,7 @@ export const ResponsiveCustomButtonToolbar = {
|
|
|
16
17
|
[ToolbarSize.XXXS]: []
|
|
17
18
|
};
|
|
18
19
|
|
|
20
|
+
// eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required -- Ignored via go/ED-25883
|
|
19
21
|
/** @deprecated
|
|
20
22
|
* To be removed as part of ED-25129 in favour of ResponsiveCustomButtonToolbarNext along with references
|
|
21
23
|
* to platform_editor_toolbar_responsive_fixes feature gate
|
|
@@ -15,7 +15,8 @@ export const FormattingTextDropdownMenu = /*#__PURE__*/React.memo(({
|
|
|
15
15
|
popupsMountPoint,
|
|
16
16
|
popupsScrollableElement,
|
|
17
17
|
hasMoreButton,
|
|
18
|
-
intl
|
|
18
|
+
intl,
|
|
19
|
+
toolbarType
|
|
19
20
|
}) => {
|
|
20
21
|
const [isMenuOpen, toggleMenu, closeMenu] = useMenuState();
|
|
21
22
|
const [isOpenedByKeyboard, setIsOpenedByKeyboard] = useState(false);
|
|
@@ -85,6 +86,7 @@ export const FormattingTextDropdownMenu = /*#__PURE__*/React.memo(({
|
|
|
85
86
|
toggleMenu();
|
|
86
87
|
setIsOpenedByKeyboard(true);
|
|
87
88
|
}
|
|
88
|
-
}
|
|
89
|
+
},
|
|
90
|
+
toolbarType: toolbarType
|
|
89
91
|
}));
|
|
90
92
|
});
|
|
@@ -155,7 +155,8 @@ const ToolbarFormatting = ({
|
|
|
155
155
|
hasFormattingActive: hasFormattingActive,
|
|
156
156
|
hasMoreButton: true,
|
|
157
157
|
items: items,
|
|
158
|
-
intl: intl
|
|
158
|
+
intl: intl,
|
|
159
|
+
toolbarType: toolbarType
|
|
159
160
|
}))), !(api !== null && api !== void 0 && api.primaryToolbar) && /* eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage */
|
|
160
161
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
|
|
161
162
|
jsx("span", {
|
package/dist/esm/plugin.js
CHANGED
|
@@ -57,7 +57,8 @@ var FloatingToolbarTextFormat = function FloatingToolbarTextFormat(_ref) {
|
|
|
57
57
|
moreButtonLabel: FloatingToolbarSettings.moreButtonLabel,
|
|
58
58
|
hasFormattingActive: FloatingToolbarSettings.hasMoreButton,
|
|
59
59
|
hasMoreButton: FloatingToolbarSettings.hasMoreButton,
|
|
60
|
-
intl: intl
|
|
60
|
+
intl: intl,
|
|
61
|
+
toolbarType: FloatingToolbarSettings.toolbarType
|
|
61
62
|
});
|
|
62
63
|
};
|
|
63
64
|
export var FloatingToolbarTextFormalWithIntl = injectIntl(FloatingToolbarTextFormat);
|
|
@@ -11,6 +11,7 @@ import { ToolbarButton } from '@atlaskit/editor-common/ui-menu';
|
|
|
11
11
|
import BoldIcon from '@atlaskit/icon/core/migration/text-bold--editor-bold';
|
|
12
12
|
import ChevronDownIcon from '@atlaskit/icon/utility/migration/chevron-down';
|
|
13
13
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
14
|
+
import { ToolbarType } from './types';
|
|
14
15
|
export var BoldToolbarButton = function BoldToolbarButton(_ref) {
|
|
15
16
|
var label = _ref.label,
|
|
16
17
|
isReducedSpacing = _ref.isReducedSpacing,
|
|
@@ -18,10 +19,12 @@ export var BoldToolbarButton = function BoldToolbarButton(_ref) {
|
|
|
18
19
|
isSelected = _ref.isSelected,
|
|
19
20
|
ariaExpanded = _ref['aria-expanded'],
|
|
20
21
|
onClick = _ref.onClick,
|
|
21
|
-
onKeyDown = _ref.onKeyDown
|
|
22
|
+
onKeyDown = _ref.onKeyDown,
|
|
23
|
+
toolbarType = _ref.toolbarType;
|
|
24
|
+
var reducedSpacing = toolbarType === ToolbarType.FLOATING ? 'compact' : 'none';
|
|
22
25
|
return jsx(ToolbarButton, {
|
|
23
26
|
testId: 'ak-editor-selection-toolbar-format-text-button',
|
|
24
|
-
spacing: isReducedSpacing ?
|
|
27
|
+
spacing: isReducedSpacing ? reducedSpacing : 'default',
|
|
25
28
|
disabled: isDisabled,
|
|
26
29
|
selected: isSelected,
|
|
27
30
|
"aria-label": label,
|
|
@@ -5,12 +5,14 @@ import { IconTypes } from './types';
|
|
|
5
5
|
export var DefaultButtonsToolbar = [IconTypes.strong, IconTypes.em];
|
|
6
6
|
export var DefaultButtonsMenu = [IconTypes.underline, IconTypes.strike, IconTypes.code, IconTypes.subscript, IconTypes.superscript];
|
|
7
7
|
|
|
8
|
+
// eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required -- Ignored via go/ED-25883
|
|
8
9
|
/** @deprecated
|
|
9
10
|
* To be removed as part of ED-25129 in favour of ResponsiveCustomButtonToolbarNext along with references
|
|
10
11
|
* to platform_editor_toolbar_responsive_fixes feature gate
|
|
11
12
|
*/
|
|
12
13
|
export var ResponsiveCustomButtonToolbar = (_ResponsiveCustomButt = {}, _defineProperty(_ResponsiveCustomButt, ToolbarSize.XXL, DefaultButtonsToolbar), _defineProperty(_ResponsiveCustomButt, ToolbarSize.XL, DefaultButtonsToolbar), _defineProperty(_ResponsiveCustomButt, ToolbarSize.L, DefaultButtonsToolbar), _defineProperty(_ResponsiveCustomButt, ToolbarSize.M, []), _defineProperty(_ResponsiveCustomButt, ToolbarSize.S, []), _defineProperty(_ResponsiveCustomButt, ToolbarSize.XXXS, []), _ResponsiveCustomButt);
|
|
13
14
|
|
|
15
|
+
// eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required -- Ignored via go/ED-25883
|
|
14
16
|
/** @deprecated
|
|
15
17
|
* To be removed as part of ED-25129 in favour of ResponsiveCustomButtonToolbarNext along with references
|
|
16
18
|
* to platform_editor_toolbar_responsive_fixes feature gate
|
|
@@ -16,7 +16,8 @@ export var FormattingTextDropdownMenu = /*#__PURE__*/React.memo(function (_ref)
|
|
|
16
16
|
popupsMountPoint = _ref.popupsMountPoint,
|
|
17
17
|
popupsScrollableElement = _ref.popupsScrollableElement,
|
|
18
18
|
hasMoreButton = _ref.hasMoreButton,
|
|
19
|
-
intl = _ref.intl
|
|
19
|
+
intl = _ref.intl,
|
|
20
|
+
toolbarType = _ref.toolbarType;
|
|
20
21
|
var _useMenuState = useMenuState(),
|
|
21
22
|
_useMenuState2 = _slicedToArray(_useMenuState, 3),
|
|
22
23
|
isMenuOpen = _useMenuState2[0],
|
|
@@ -94,6 +95,7 @@ export var FormattingTextDropdownMenu = /*#__PURE__*/React.memo(function (_ref)
|
|
|
94
95
|
toggleMenu();
|
|
95
96
|
setIsOpenedByKeyboard(true);
|
|
96
97
|
}
|
|
97
|
-
}
|
|
98
|
+
},
|
|
99
|
+
toolbarType: toolbarType
|
|
98
100
|
}));
|
|
99
101
|
});
|
|
@@ -160,7 +160,8 @@ var ToolbarFormatting = function ToolbarFormatting(_ref) {
|
|
|
160
160
|
hasFormattingActive: hasFormattingActive,
|
|
161
161
|
hasMoreButton: true,
|
|
162
162
|
items: items,
|
|
163
|
-
intl: intl
|
|
163
|
+
intl: intl,
|
|
164
|
+
toolbarType: toolbarType
|
|
164
165
|
}))), !(api !== null && api !== void 0 && api.primaryToolbar) && /* eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage */
|
|
165
166
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/design-system/consistent-css-prop-usage -- Ignored via go/DSP-18766
|
|
166
167
|
jsx("span", {
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
6
|
import { jsx } from '@emotion/react';
|
|
7
|
+
import { ToolbarType } from './types';
|
|
7
8
|
type BoldButtonProps = {
|
|
8
9
|
label: string;
|
|
9
10
|
isReducedSpacing: boolean;
|
|
@@ -12,6 +13,7 @@ type BoldButtonProps = {
|
|
|
12
13
|
'aria-expanded': React.AriaAttributes['aria-expanded'];
|
|
13
14
|
onClick?: (event: React.MouseEvent<HTMLElement>) => void;
|
|
14
15
|
onKeyDown?: (event: React.KeyboardEvent) => void;
|
|
16
|
+
toolbarType: ToolbarType;
|
|
15
17
|
};
|
|
16
|
-
export declare const BoldToolbarButton: ({ label, isReducedSpacing, isDisabled, isSelected, "aria-expanded": ariaExpanded, onClick, onKeyDown, }: BoldButtonProps) => jsx.JSX.Element;
|
|
18
|
+
export declare const BoldToolbarButton: ({ label, isReducedSpacing, isDisabled, isSelected, "aria-expanded": ariaExpanded, onClick, onKeyDown, toolbarType, }: BoldButtonProps) => jsx.JSX.Element;
|
|
17
19
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { WrappedComponentProps } from 'react-intl-next';
|
|
3
3
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
|
-
import type
|
|
4
|
+
import { type MenuIconItem, ToolbarType } from './types';
|
|
5
5
|
type DropdownMenuProps = {
|
|
6
6
|
editorView: EditorView;
|
|
7
7
|
isReducedSpacing: boolean;
|
|
@@ -12,6 +12,7 @@ type DropdownMenuProps = {
|
|
|
12
12
|
popupsMountPoint?: HTMLElement;
|
|
13
13
|
popupsScrollableElement?: HTMLElement;
|
|
14
14
|
hasMoreButton: boolean;
|
|
15
|
+
toolbarType: ToolbarType;
|
|
15
16
|
} & WrappedComponentProps;
|
|
16
|
-
export declare const FormattingTextDropdownMenu: React.MemoExoticComponent<({ editorView, moreButtonLabel, isReducedSpacing, items, hasFormattingActive, popupsBoundariesElement, popupsMountPoint, popupsScrollableElement, hasMoreButton, intl, }: DropdownMenuProps) => JSX.Element>;
|
|
17
|
+
export declare const FormattingTextDropdownMenu: React.MemoExoticComponent<({ editorView, moreButtonLabel, isReducedSpacing, items, hasFormattingActive, popupsBoundariesElement, popupsMountPoint, popupsScrollableElement, hasMoreButton, intl, toolbarType, }: DropdownMenuProps) => JSX.Element>;
|
|
17
18
|
export {};
|
|
@@ -4,6 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
6
|
import { jsx } from '@emotion/react';
|
|
7
|
+
import { ToolbarType } from './types';
|
|
7
8
|
type BoldButtonProps = {
|
|
8
9
|
label: string;
|
|
9
10
|
isReducedSpacing: boolean;
|
|
@@ -12,6 +13,7 @@ type BoldButtonProps = {
|
|
|
12
13
|
'aria-expanded': React.AriaAttributes['aria-expanded'];
|
|
13
14
|
onClick?: (event: React.MouseEvent<HTMLElement>) => void;
|
|
14
15
|
onKeyDown?: (event: React.KeyboardEvent) => void;
|
|
16
|
+
toolbarType: ToolbarType;
|
|
15
17
|
};
|
|
16
|
-
export declare const BoldToolbarButton: ({ label, isReducedSpacing, isDisabled, isSelected, "aria-expanded": ariaExpanded, onClick, onKeyDown, }: BoldButtonProps) => jsx.JSX.Element;
|
|
18
|
+
export declare const BoldToolbarButton: ({ label, isReducedSpacing, isDisabled, isSelected, "aria-expanded": ariaExpanded, onClick, onKeyDown, toolbarType, }: BoldButtonProps) => jsx.JSX.Element;
|
|
17
19
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import type { WrappedComponentProps } from 'react-intl-next';
|
|
3
3
|
import type { EditorView } from '@atlaskit/editor-prosemirror/view';
|
|
4
|
-
import type
|
|
4
|
+
import { type MenuIconItem, ToolbarType } from './types';
|
|
5
5
|
type DropdownMenuProps = {
|
|
6
6
|
editorView: EditorView;
|
|
7
7
|
isReducedSpacing: boolean;
|
|
@@ -12,6 +12,7 @@ type DropdownMenuProps = {
|
|
|
12
12
|
popupsMountPoint?: HTMLElement;
|
|
13
13
|
popupsScrollableElement?: HTMLElement;
|
|
14
14
|
hasMoreButton: boolean;
|
|
15
|
+
toolbarType: ToolbarType;
|
|
15
16
|
} & WrappedComponentProps;
|
|
16
|
-
export declare const FormattingTextDropdownMenu: React.MemoExoticComponent<({ editorView, moreButtonLabel, isReducedSpacing, items, hasFormattingActive, popupsBoundariesElement, popupsMountPoint, popupsScrollableElement, hasMoreButton, intl, }: DropdownMenuProps) => JSX.Element>;
|
|
17
|
+
export declare const FormattingTextDropdownMenu: React.MemoExoticComponent<({ editorView, moreButtonLabel, isReducedSpacing, items, hasFormattingActive, popupsBoundariesElement, popupsMountPoint, popupsScrollableElement, hasMoreButton, intl, toolbarType, }: DropdownMenuProps) => JSX.Element>;
|
|
17
18
|
export {};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-plugin-text-formatting",
|
|
3
|
-
"version": "1.16.
|
|
3
|
+
"version": "1.16.3",
|
|
4
4
|
"description": "Text-formatting plugin for @atlaskit/editor-core",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -32,7 +32,7 @@
|
|
|
32
32
|
},
|
|
33
33
|
"dependencies": {
|
|
34
34
|
"@atlaskit/adf-schema": "^46.1.0",
|
|
35
|
-
"@atlaskit/editor-common": "^96.
|
|
35
|
+
"@atlaskit/editor-common": "^96.1.0",
|
|
36
36
|
"@atlaskit/editor-plugin-analytics": "^1.10.0",
|
|
37
37
|
"@atlaskit/editor-plugin-primary-toolbar": "^2.0.0",
|
|
38
38
|
"@atlaskit/editor-prosemirror": "6.2.1",
|