@atlaskit/editor-plugin-toolbar-lists-indentation 4.2.0 → 4.2.2

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.
Files changed (33) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/dist/cjs/ui/toolbar-components/ListsIndentationHeroButton.js +0 -2
  3. package/dist/cjs/ui/toolbar-components/ListsIndentationMenu.js +0 -2
  4. package/dist/cjs/ui/toolbar-components.js +2 -6
  5. package/dist/es2019/ui/toolbar-components/BulletedListMenuItem.js +1 -1
  6. package/dist/es2019/ui/toolbar-components/IndentMenuItem.js +2 -2
  7. package/dist/es2019/ui/toolbar-components/ListsIndentationHeroButton.js +0 -2
  8. package/dist/es2019/ui/toolbar-components/ListsIndentationMenu.js +0 -2
  9. package/dist/es2019/ui/toolbar-components/NumberedListMenuItem.js +1 -1
  10. package/dist/es2019/ui/toolbar-components/OutdentMenuItem.js +2 -2
  11. package/dist/es2019/ui/toolbar-components.js +9 -13
  12. package/dist/es2019/ui/utils/hooks.js +2 -2
  13. package/dist/esm/ui/toolbar-components/BulletedListMenuItem.js +1 -1
  14. package/dist/esm/ui/toolbar-components/IndentMenuItem.js +2 -2
  15. package/dist/esm/ui/toolbar-components/ListsIndentationHeroButton.js +0 -2
  16. package/dist/esm/ui/toolbar-components/ListsIndentationMenu.js +0 -2
  17. package/dist/esm/ui/toolbar-components/NumberedListMenuItem.js +1 -1
  18. package/dist/esm/ui/toolbar-components/OutdentMenuItem.js +2 -2
  19. package/dist/esm/ui/toolbar-components.js +10 -14
  20. package/dist/esm/ui/utils/hooks.js +2 -2
  21. package/dist/types/ui/toolbar-components/IndentMenuItem.d.ts +3 -3
  22. package/dist/types/ui/toolbar-components/ListsIndentationHeroButton.d.ts +1 -3
  23. package/dist/types/ui/toolbar-components/ListsIndentationMenu.d.ts +1 -3
  24. package/dist/types/ui/toolbar-components/OutdentMenuItem.d.ts +3 -3
  25. package/dist/types/ui/toolbar-components.d.ts +4 -4
  26. package/dist/types/ui/utils/hooks.d.ts +4 -4
  27. package/dist/types-ts4.5/ui/toolbar-components/IndentMenuItem.d.ts +3 -3
  28. package/dist/types-ts4.5/ui/toolbar-components/ListsIndentationHeroButton.d.ts +1 -3
  29. package/dist/types-ts4.5/ui/toolbar-components/ListsIndentationMenu.d.ts +1 -3
  30. package/dist/types-ts4.5/ui/toolbar-components/OutdentMenuItem.d.ts +3 -3
  31. package/dist/types-ts4.5/ui/toolbar-components.d.ts +4 -4
  32. package/dist/types-ts4.5/ui/utils/hooks.d.ts +4 -4
  33. package/package.json +5 -5
package/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # @atlaskit/editor-plugin-toolbar-lists-indentation
2
2
 
3
+ ## 4.2.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [`3145f278b1f7a`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/3145f278b1f7a) -
8
+ [ux] [ED-28473] minor UI updates for editor-toolbar
9
+
10
+ - Use ADS ButtonGroup for ToolbarButtonGroup
11
+ - Remove groupLocation prop and use CSS instead
12
+ - Use DropdownItemGroup for ToolbarDropdownItemSection and expand props for section separator and
13
+ title
14
+ - Support ReactNode as content for ToolbarTooltip and add missing shortcuts in tooltips
15
+ - Center Icons for split buttons and make chevron icon 24px wide
16
+ - Align dropdown menu UI with current editor design
17
+
18
+ - Updated dependencies
19
+
20
+ ## 4.2.1
21
+
22
+ ### Patch Changes
23
+
24
+ - Updated dependencies
25
+
3
26
  ## 4.2.0
4
27
 
5
28
  ### Minor Changes
@@ -14,7 +14,6 @@ var _toolbar = require("@atlaskit/editor-common/toolbar");
14
14
  var _editorToolbar = require("@atlaskit/editor-toolbar");
15
15
  var ListsIndentationHeroButton = exports.ListsIndentationHeroButton = function ListsIndentationHeroButton(_ref) {
16
16
  var api = _ref.api,
17
- groupLocation = _ref.groupLocation,
18
17
  parents = _ref.parents;
19
18
  var _useIntl = (0, _reactIntlNext.useIntl)(),
20
19
  formatMessage = _useIntl.formatMessage;
@@ -46,7 +45,6 @@ var ListsIndentationHeroButton = exports.ListsIndentationHeroButton = function L
46
45
  }) : /*#__PURE__*/_react.default.createElement(_editorToolbar.ListBulletedIcon, {
47
46
  label: formatMessage(_messages.listMessages.bulletedList)
48
47
  }),
49
- groupLocation: groupLocation,
50
48
  isSelected: bulletListActive || orderedListActive,
51
49
  isDisabled: !orderedListActive && bulletListDisabled,
52
50
  ariaKeyshortcuts: shortcut,
@@ -15,7 +15,6 @@ var _hooks2 = require("../utils/hooks");
15
15
  var ListsIndentationMenu = exports.ListsIndentationMenu = function ListsIndentationMenu(_ref) {
16
16
  var children = _ref.children,
17
17
  api = _ref.api,
18
- groupLocation = _ref.groupLocation,
19
18
  allowHeadingAndParagraphIndentation = _ref.allowHeadingAndParagraphIndentation;
20
19
  var _useIntl = (0, _reactIntlNext.useIntl)(),
21
20
  formatMessage = _useIntl.formatMessage;
@@ -40,7 +39,6 @@ var ListsIndentationMenu = exports.ListsIndentationMenu = function ListsIndentat
40
39
  iconBefore: /*#__PURE__*/_react.default.createElement(_editorToolbar.MoreItemsIcon, {
41
40
  label: formatMessage(_lists.messages.lists)
42
41
  }),
43
- groupLocation: groupLocation,
44
42
  isDisabled: allItemsDisabled,
45
43
  testId: "editor-toolbar__lists-and-indentation-menu"
46
44
  }, children);
@@ -34,11 +34,9 @@ var getToolbarComponents = exports.getToolbarComponents = function getToolbarCom
34
34
  rank: _toolbar.LISTS_INDENTATION_GROUP_RANK[_toolbar.LISTS_INDENTATION_HERO_BUTTON.key]
35
35
  }],
36
36
  component: function component(_ref2) {
37
- var groupLocation = _ref2.groupLocation,
38
- parents = _ref2.parents;
37
+ var parents = _ref2.parents;
39
38
  return /*#__PURE__*/_react.default.createElement(_ListsIndentationHeroButton.ListsIndentationHeroButton, {
40
39
  api: api,
41
- groupLocation: groupLocation,
42
40
  parents: parents
43
41
  });
44
42
  }
@@ -51,11 +49,9 @@ var getToolbarComponents = exports.getToolbarComponents = function getToolbarCom
51
49
  rank: _toolbar.LISTS_INDENTATION_GROUP_RANK[_toolbar.LISTS_INDENTATION_MENU.key]
52
50
  }],
53
51
  component: function component(_ref3) {
54
- var children = _ref3.children,
55
- groupLocation = _ref3.groupLocation;
52
+ var children = _ref3.children;
56
53
  return /*#__PURE__*/_react.default.createElement(_ListsIndentationMenu.ListsIndentationMenu, {
57
54
  api: api,
58
- groupLocation: groupLocation,
59
55
  allowHeadingAndParagraphIndentation: allowHeadingAndParagraphIndentation
60
56
  }, children);
61
57
  }
@@ -3,7 +3,7 @@ import { useIntl } from 'react-intl-next';
3
3
  import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
4
4
  import { toggleBulletList as toggleBulletListKeymap, formatShortcut } from '@atlaskit/editor-common/keymaps';
5
5
  import { listMessages } from '@atlaskit/editor-common/messages';
6
- import { getInputMethodFromParentKeys } from "@atlaskit/editor-common/toolbar";
6
+ import { getInputMethodFromParentKeys } from '@atlaskit/editor-common/toolbar';
7
7
  import { ListBulletedIcon, ToolbarDropdownItem, ToolbarKeyboardShortcutHint } from '@atlaskit/editor-toolbar';
8
8
  export const BulletedListMenuItem = ({
9
9
  api,
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
- import { useIntl } from "react-intl-next";
2
+ import { useIntl } from 'react-intl-next';
3
3
  import { indent as toggleIndentKeymap, formatShortcut } from '@atlaskit/editor-common/keymaps';
4
4
  import { indentationMessages } from '@atlaskit/editor-common/messages';
5
- import { getInputMethodFromParentKeys, useEditorToolbar } from "@atlaskit/editor-common/toolbar";
5
+ import { getInputMethodFromParentKeys, useEditorToolbar } from '@atlaskit/editor-common/toolbar';
6
6
  import { IndentIcon, ToolbarDropdownItem, ToolbarKeyboardShortcutHint } from '@atlaskit/editor-toolbar';
7
7
  import { useIndentationState } from '../utils/hooks';
8
8
  export const IndentMenuItem = ({
@@ -7,7 +7,6 @@ import { getInputMethodFromParentKeys } from '@atlaskit/editor-common/toolbar';
7
7
  import { ListBulletedIcon, ListNumberedIcon, ToolbarButton, ToolbarTooltip } from '@atlaskit/editor-toolbar';
8
8
  export const ListsIndentationHeroButton = ({
9
9
  api,
10
- groupLocation,
11
10
  parents
12
11
  }) => {
13
12
  const {
@@ -42,7 +41,6 @@ export const ListsIndentationHeroButton = ({
42
41
  }) : /*#__PURE__*/React.createElement(ListBulletedIcon, {
43
42
  label: formatMessage(listMessages.bulletedList)
44
43
  }),
45
- groupLocation: groupLocation,
46
44
  isSelected: bulletListActive || orderedListActive,
47
45
  isDisabled: !orderedListActive && bulletListDisabled,
48
46
  ariaKeyshortcuts: shortcut,
@@ -8,7 +8,6 @@ import { useIndentationState } from '../utils/hooks';
8
8
  export const ListsIndentationMenu = ({
9
9
  children,
10
10
  api,
11
- groupLocation,
12
11
  allowHeadingAndParagraphIndentation
13
12
  }) => {
14
13
  const {
@@ -37,7 +36,6 @@ export const ListsIndentationMenu = ({
37
36
  iconBefore: /*#__PURE__*/React.createElement(MoreItemsIcon, {
38
37
  label: formatMessage(messages.lists)
39
38
  }),
40
- groupLocation: groupLocation,
41
39
  isDisabled: allItemsDisabled,
42
40
  testId: "editor-toolbar__lists-and-indentation-menu"
43
41
  }, children);
@@ -3,7 +3,7 @@ import { useIntl } from 'react-intl-next';
3
3
  import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
4
4
  import { toggleOrderedList as toggleOrderedListKeymap, formatShortcut } from '@atlaskit/editor-common/keymaps';
5
5
  import { listMessages } from '@atlaskit/editor-common/messages';
6
- import { getInputMethodFromParentKeys } from "@atlaskit/editor-common/toolbar";
6
+ import { getInputMethodFromParentKeys } from '@atlaskit/editor-common/toolbar';
7
7
  import { ListNumberedIcon, ToolbarDropdownItem, ToolbarKeyboardShortcutHint } from '@atlaskit/editor-toolbar';
8
8
  export const NumberedListMenuItem = ({
9
9
  api,
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
- import { useIntl } from "react-intl-next";
2
+ import { useIntl } from 'react-intl-next';
3
3
  import { outdent as toggleOutdentKeymap, formatShortcut } from '@atlaskit/editor-common/keymaps';
4
4
  import { indentationMessages } from '@atlaskit/editor-common/messages';
5
- import { getInputMethodFromParentKeys, useEditorToolbar } from "@atlaskit/editor-common/toolbar";
5
+ import { getInputMethodFromParentKeys, useEditorToolbar } from '@atlaskit/editor-common/toolbar';
6
6
  import { OutdentIcon, ToolbarDropdownItem, ToolbarKeyboardShortcutHint } from '@atlaskit/editor-toolbar';
7
7
  import { useIndentationState } from '../utils/hooks';
8
8
  export const OutdentMenuItem = ({
@@ -1,11 +1,11 @@
1
- import React from "react";
2
- import { BULLETED_LIST_MENU_ITEM, INDENT_MENU_ITEM, LISTS_INDENTATION_GROUP, LISTS_INDENTATION_HERO_BUTTON, LISTS_INDENTATION_MENU, LISTS_INDENTATION_MENU_SECTION, NUMBERED_LIST_MENU_ITEM, OUTDENT_MENU_ITEM, TEXT_SECTION, TEXT_SECTION_RANK, LISTS_INDENTATION_GROUP_RANK, LISTS_INDENTATION_MENU_RANK, LISTS_INDENTATION_MENU_SECTION_RANK } from "@atlaskit/editor-common/toolbar";
3
- import { BulletedListMenuItem } from "./toolbar-components/BulletedListMenuItem";
4
- import { IndentMenuItem } from "./toolbar-components/IndentMenuItem";
5
- import { ListsIndentationHeroButton } from "./toolbar-components/ListsIndentationHeroButton";
6
- import { ListsIndentationMenu } from "./toolbar-components/ListsIndentationMenu";
7
- import { NumberedListMenuItem } from "./toolbar-components/NumberedListMenuItem";
8
- import { OutdentMenuItem } from "./toolbar-components/OutdentMenuItem";
1
+ import React from 'react';
2
+ import { BULLETED_LIST_MENU_ITEM, INDENT_MENU_ITEM, LISTS_INDENTATION_GROUP, LISTS_INDENTATION_HERO_BUTTON, LISTS_INDENTATION_MENU, LISTS_INDENTATION_MENU_SECTION, NUMBERED_LIST_MENU_ITEM, OUTDENT_MENU_ITEM, TEXT_SECTION, TEXT_SECTION_RANK, LISTS_INDENTATION_GROUP_RANK, LISTS_INDENTATION_MENU_RANK, LISTS_INDENTATION_MENU_SECTION_RANK } from '@atlaskit/editor-common/toolbar';
3
+ import { BulletedListMenuItem } from './toolbar-components/BulletedListMenuItem';
4
+ import { IndentMenuItem } from './toolbar-components/IndentMenuItem';
5
+ import { ListsIndentationHeroButton } from './toolbar-components/ListsIndentationHeroButton';
6
+ import { ListsIndentationMenu } from './toolbar-components/ListsIndentationMenu';
7
+ import { NumberedListMenuItem } from './toolbar-components/NumberedListMenuItem';
8
+ import { OutdentMenuItem } from './toolbar-components/OutdentMenuItem';
9
9
  export const getToolbarComponents = ({
10
10
  api,
11
11
  showIndentationButtons,
@@ -28,11 +28,9 @@ export const getToolbarComponents = ({
28
28
  rank: LISTS_INDENTATION_GROUP_RANK[LISTS_INDENTATION_HERO_BUTTON.key]
29
29
  }],
30
30
  component: ({
31
- groupLocation,
32
31
  parents
33
32
  }) => /*#__PURE__*/React.createElement(ListsIndentationHeroButton, {
34
33
  api: api,
35
- groupLocation: groupLocation,
36
34
  parents: parents
37
35
  })
38
36
  }, {
@@ -44,11 +42,9 @@ export const getToolbarComponents = ({
44
42
  rank: LISTS_INDENTATION_GROUP_RANK[LISTS_INDENTATION_MENU.key]
45
43
  }],
46
44
  component: ({
47
- children,
48
- groupLocation
45
+ children
49
46
  }) => /*#__PURE__*/React.createElement(ListsIndentationMenu, {
50
47
  api: api,
51
- groupLocation: groupLocation,
52
48
  allowHeadingAndParagraphIndentation: allowHeadingAndParagraphIndentation
53
49
  }, children)
54
50
  }, {
@@ -1,5 +1,5 @@
1
- import { useSharedPluginStateWithSelector } from "@atlaskit/editor-common/hooks";
2
- import { getIndentationButtonsState } from "../../pm-plugins/indentation-buttons";
1
+ import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
2
+ import { getIndentationButtonsState } from '../../pm-plugins/indentation-buttons';
3
3
  export const useIndentationState = ({
4
4
  api,
5
5
  allowHeadingAndParagraphIndentation,
@@ -3,7 +3,7 @@ import { useIntl } from 'react-intl-next';
3
3
  import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
4
4
  import { toggleBulletList as toggleBulletListKeymap, formatShortcut } from '@atlaskit/editor-common/keymaps';
5
5
  import { listMessages } from '@atlaskit/editor-common/messages';
6
- import { getInputMethodFromParentKeys } from "@atlaskit/editor-common/toolbar";
6
+ import { getInputMethodFromParentKeys } from '@atlaskit/editor-common/toolbar';
7
7
  import { ListBulletedIcon, ToolbarDropdownItem, ToolbarKeyboardShortcutHint } from '@atlaskit/editor-toolbar';
8
8
  export var BulletedListMenuItem = function BulletedListMenuItem(_ref) {
9
9
  var api = _ref.api,
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
- import { useIntl } from "react-intl-next";
2
+ import { useIntl } from 'react-intl-next';
3
3
  import { indent as toggleIndentKeymap, formatShortcut } from '@atlaskit/editor-common/keymaps';
4
4
  import { indentationMessages } from '@atlaskit/editor-common/messages';
5
- import { getInputMethodFromParentKeys, useEditorToolbar } from "@atlaskit/editor-common/toolbar";
5
+ import { getInputMethodFromParentKeys, useEditorToolbar } from '@atlaskit/editor-common/toolbar';
6
6
  import { IndentIcon, ToolbarDropdownItem, ToolbarKeyboardShortcutHint } from '@atlaskit/editor-toolbar';
7
7
  import { useIndentationState } from '../utils/hooks';
8
8
  export var IndentMenuItem = function IndentMenuItem(_ref) {
@@ -7,7 +7,6 @@ import { getInputMethodFromParentKeys } from '@atlaskit/editor-common/toolbar';
7
7
  import { ListBulletedIcon, ListNumberedIcon, ToolbarButton, ToolbarTooltip } from '@atlaskit/editor-toolbar';
8
8
  export var ListsIndentationHeroButton = function ListsIndentationHeroButton(_ref) {
9
9
  var api = _ref.api,
10
- groupLocation = _ref.groupLocation,
11
10
  parents = _ref.parents;
12
11
  var _useIntl = useIntl(),
13
12
  formatMessage = _useIntl.formatMessage;
@@ -39,7 +38,6 @@ export var ListsIndentationHeroButton = function ListsIndentationHeroButton(_ref
39
38
  }) : /*#__PURE__*/React.createElement(ListBulletedIcon, {
40
39
  label: formatMessage(listMessages.bulletedList)
41
40
  }),
42
- groupLocation: groupLocation,
43
41
  isSelected: bulletListActive || orderedListActive,
44
42
  isDisabled: !orderedListActive && bulletListDisabled,
45
43
  ariaKeyshortcuts: shortcut,
@@ -8,7 +8,6 @@ import { useIndentationState } from '../utils/hooks';
8
8
  export var ListsIndentationMenu = function ListsIndentationMenu(_ref) {
9
9
  var children = _ref.children,
10
10
  api = _ref.api,
11
- groupLocation = _ref.groupLocation,
12
11
  allowHeadingAndParagraphIndentation = _ref.allowHeadingAndParagraphIndentation;
13
12
  var _useIntl = useIntl(),
14
13
  formatMessage = _useIntl.formatMessage;
@@ -33,7 +32,6 @@ export var ListsIndentationMenu = function ListsIndentationMenu(_ref) {
33
32
  iconBefore: /*#__PURE__*/React.createElement(MoreItemsIcon, {
34
33
  label: formatMessage(messages.lists)
35
34
  }),
36
- groupLocation: groupLocation,
37
35
  isDisabled: allItemsDisabled,
38
36
  testId: "editor-toolbar__lists-and-indentation-menu"
39
37
  }, children);
@@ -3,7 +3,7 @@ import { useIntl } from 'react-intl-next';
3
3
  import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
4
4
  import { toggleOrderedList as toggleOrderedListKeymap, formatShortcut } from '@atlaskit/editor-common/keymaps';
5
5
  import { listMessages } from '@atlaskit/editor-common/messages';
6
- import { getInputMethodFromParentKeys } from "@atlaskit/editor-common/toolbar";
6
+ import { getInputMethodFromParentKeys } from '@atlaskit/editor-common/toolbar';
7
7
  import { ListNumberedIcon, ToolbarDropdownItem, ToolbarKeyboardShortcutHint } from '@atlaskit/editor-toolbar';
8
8
  export var NumberedListMenuItem = function NumberedListMenuItem(_ref) {
9
9
  var api = _ref.api,
@@ -1,8 +1,8 @@
1
1
  import React from 'react';
2
- import { useIntl } from "react-intl-next";
2
+ import { useIntl } from 'react-intl-next';
3
3
  import { outdent as toggleOutdentKeymap, formatShortcut } from '@atlaskit/editor-common/keymaps';
4
4
  import { indentationMessages } from '@atlaskit/editor-common/messages';
5
- import { getInputMethodFromParentKeys, useEditorToolbar } from "@atlaskit/editor-common/toolbar";
5
+ import { getInputMethodFromParentKeys, useEditorToolbar } from '@atlaskit/editor-common/toolbar';
6
6
  import { OutdentIcon, ToolbarDropdownItem, ToolbarKeyboardShortcutHint } from '@atlaskit/editor-toolbar';
7
7
  import { useIndentationState } from '../utils/hooks';
8
8
  export var OutdentMenuItem = function OutdentMenuItem(_ref) {
@@ -1,11 +1,11 @@
1
- import React from "react";
2
- import { BULLETED_LIST_MENU_ITEM, INDENT_MENU_ITEM, LISTS_INDENTATION_GROUP, LISTS_INDENTATION_HERO_BUTTON, LISTS_INDENTATION_MENU, LISTS_INDENTATION_MENU_SECTION, NUMBERED_LIST_MENU_ITEM, OUTDENT_MENU_ITEM, TEXT_SECTION, TEXT_SECTION_RANK, LISTS_INDENTATION_GROUP_RANK, LISTS_INDENTATION_MENU_RANK, LISTS_INDENTATION_MENU_SECTION_RANK } from "@atlaskit/editor-common/toolbar";
3
- import { BulletedListMenuItem } from "./toolbar-components/BulletedListMenuItem";
4
- import { IndentMenuItem } from "./toolbar-components/IndentMenuItem";
5
- import { ListsIndentationHeroButton } from "./toolbar-components/ListsIndentationHeroButton";
6
- import { ListsIndentationMenu } from "./toolbar-components/ListsIndentationMenu";
7
- import { NumberedListMenuItem } from "./toolbar-components/NumberedListMenuItem";
8
- import { OutdentMenuItem } from "./toolbar-components/OutdentMenuItem";
1
+ import React from 'react';
2
+ import { BULLETED_LIST_MENU_ITEM, INDENT_MENU_ITEM, LISTS_INDENTATION_GROUP, LISTS_INDENTATION_HERO_BUTTON, LISTS_INDENTATION_MENU, LISTS_INDENTATION_MENU_SECTION, NUMBERED_LIST_MENU_ITEM, OUTDENT_MENU_ITEM, TEXT_SECTION, TEXT_SECTION_RANK, LISTS_INDENTATION_GROUP_RANK, LISTS_INDENTATION_MENU_RANK, LISTS_INDENTATION_MENU_SECTION_RANK } from '@atlaskit/editor-common/toolbar';
3
+ import { BulletedListMenuItem } from './toolbar-components/BulletedListMenuItem';
4
+ import { IndentMenuItem } from './toolbar-components/IndentMenuItem';
5
+ import { ListsIndentationHeroButton } from './toolbar-components/ListsIndentationHeroButton';
6
+ import { ListsIndentationMenu } from './toolbar-components/ListsIndentationMenu';
7
+ import { NumberedListMenuItem } from './toolbar-components/NumberedListMenuItem';
8
+ import { OutdentMenuItem } from './toolbar-components/OutdentMenuItem';
9
9
  export var getToolbarComponents = function getToolbarComponents(_ref) {
10
10
  var api = _ref.api,
11
11
  showIndentationButtons = _ref.showIndentationButtons,
@@ -27,11 +27,9 @@ export var getToolbarComponents = function getToolbarComponents(_ref) {
27
27
  rank: LISTS_INDENTATION_GROUP_RANK[LISTS_INDENTATION_HERO_BUTTON.key]
28
28
  }],
29
29
  component: function component(_ref2) {
30
- var groupLocation = _ref2.groupLocation,
31
- parents = _ref2.parents;
30
+ var parents = _ref2.parents;
32
31
  return /*#__PURE__*/React.createElement(ListsIndentationHeroButton, {
33
32
  api: api,
34
- groupLocation: groupLocation,
35
33
  parents: parents
36
34
  });
37
35
  }
@@ -44,11 +42,9 @@ export var getToolbarComponents = function getToolbarComponents(_ref) {
44
42
  rank: LISTS_INDENTATION_GROUP_RANK[LISTS_INDENTATION_MENU.key]
45
43
  }],
46
44
  component: function component(_ref3) {
47
- var children = _ref3.children,
48
- groupLocation = _ref3.groupLocation;
45
+ var children = _ref3.children;
49
46
  return /*#__PURE__*/React.createElement(ListsIndentationMenu, {
50
47
  api: api,
51
- groupLocation: groupLocation,
52
48
  allowHeadingAndParagraphIndentation: allowHeadingAndParagraphIndentation
53
49
  }, children);
54
50
  }
@@ -1,5 +1,5 @@
1
- import { useSharedPluginStateWithSelector } from "@atlaskit/editor-common/hooks";
2
- import { getIndentationButtonsState } from "../../pm-plugins/indentation-buttons";
1
+ import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
2
+ import { getIndentationButtonsState } from '../../pm-plugins/indentation-buttons';
3
3
  export var useIndentationState = function useIndentationState(_ref) {
4
4
  var api = _ref.api,
5
5
  allowHeadingAndParagraphIndentation = _ref.allowHeadingAndParagraphIndentation,
@@ -1,12 +1,12 @@
1
1
  import React from 'react';
2
- import type { ExtractInjectionAPI } from "@atlaskit/editor-common/types";
2
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
3
  import type { ToolbarComponentTypes } from '@atlaskit/editor-toolbar-model';
4
- import type { ToolbarListsIndentationPlugin } from "../../toolbarListsIndentationPluginType";
4
+ import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
5
5
  type IndentMenuItemType = {
6
6
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
7
7
  allowHeadingAndParagraphIndentation: boolean;
8
8
  showIndentationButtons: boolean;
9
9
  parents: ToolbarComponentTypes;
10
10
  };
11
- export declare const IndentMenuItem: ({ api, showIndentationButtons, allowHeadingAndParagraphIndentation, parents }: IndentMenuItemType) => React.JSX.Element | null;
11
+ export declare const IndentMenuItem: ({ api, showIndentationButtons, allowHeadingAndParagraphIndentation, parents, }: IndentMenuItemType) => React.JSX.Element | null;
12
12
  export {};
@@ -1,12 +1,10 @@
1
1
  import React from 'react';
2
2
  import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
- import type { ToolbarButtonGroupLocation } from '@atlaskit/editor-toolbar';
4
3
  import type { ToolbarComponentTypes } from '@atlaskit/editor-toolbar-model';
5
4
  import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
6
5
  type ListsIndentationHeroButtonProps = {
7
6
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
8
- groupLocation?: ToolbarButtonGroupLocation;
9
7
  parents: ToolbarComponentTypes;
10
8
  };
11
- export declare const ListsIndentationHeroButton: ({ api, groupLocation, parents }: ListsIndentationHeroButtonProps) => React.JSX.Element;
9
+ export declare const ListsIndentationHeroButton: ({ api, parents }: ListsIndentationHeroButtonProps) => React.JSX.Element;
12
10
  export {};
@@ -1,12 +1,10 @@
1
1
  import React from 'react';
2
2
  import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
- import type { ToolbarButtonGroupLocation } from '@atlaskit/editor-toolbar';
4
3
  import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
5
4
  type ListsIndentationMenuProps = {
6
5
  children: React.ReactNode;
7
6
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
8
- groupLocation?: ToolbarButtonGroupLocation;
9
7
  allowHeadingAndParagraphIndentation: boolean;
10
8
  };
11
- export declare const ListsIndentationMenu: ({ children, api, groupLocation, allowHeadingAndParagraphIndentation }: ListsIndentationMenuProps) => React.JSX.Element;
9
+ export declare const ListsIndentationMenu: ({ children, api, allowHeadingAndParagraphIndentation, }: ListsIndentationMenuProps) => React.JSX.Element;
12
10
  export {};
@@ -1,12 +1,12 @@
1
1
  import React from 'react';
2
- import type { ExtractInjectionAPI } from "@atlaskit/editor-common/types";
2
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
3
  import type { ToolbarComponentTypes } from '@atlaskit/editor-toolbar-model';
4
- import type { ToolbarListsIndentationPlugin } from "../../toolbarListsIndentationPluginType";
4
+ import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
5
5
  type OutdentMenuItemType = {
6
6
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
7
7
  allowHeadingAndParagraphIndentation: boolean;
8
8
  showIndentationButtons: boolean;
9
9
  parents: ToolbarComponentTypes;
10
10
  };
11
- export declare const OutdentMenuItem: ({ api, allowHeadingAndParagraphIndentation, showIndentationButtons, parents }: OutdentMenuItemType) => React.JSX.Element | null;
11
+ export declare const OutdentMenuItem: ({ api, allowHeadingAndParagraphIndentation, showIndentationButtons, parents, }: OutdentMenuItemType) => React.JSX.Element | null;
12
12
  export {};
@@ -1,10 +1,10 @@
1
- import type { ExtractInjectionAPI } from "@atlaskit/editor-common/types";
2
- import type { RegisterComponent } from "@atlaskit/editor-toolbar-model";
3
- import type { ToolbarListsIndentationPlugin } from "../toolbarListsIndentationPluginType";
1
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
2
+ import type { RegisterComponent } from '@atlaskit/editor-toolbar-model';
3
+ import type { ToolbarListsIndentationPlugin } from '../toolbarListsIndentationPluginType';
4
4
  type GetToolbarComponentsProps = {
5
5
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
6
6
  showIndentationButtons: boolean;
7
7
  allowHeadingAndParagraphIndentation: boolean;
8
8
  };
9
- export declare const getToolbarComponents: ({ api, showIndentationButtons, allowHeadingAndParagraphIndentation }: GetToolbarComponentsProps) => RegisterComponent[];
9
+ export declare const getToolbarComponents: ({ api, showIndentationButtons, allowHeadingAndParagraphIndentation, }: GetToolbarComponentsProps) => RegisterComponent[];
10
10
  export {};
@@ -1,10 +1,10 @@
1
- import type { EditorState } from "prosemirror-state";
2
- import type { ExtractInjectionAPI } from "@atlaskit/editor-common/types";
3
- import type { ToolbarListsIndentationPlugin } from "../../toolbarListsIndentationPluginType";
1
+ import type { EditorState } from 'prosemirror-state';
2
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
+ import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
4
4
  type UseIndentationStateProps = {
5
5
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
6
6
  allowHeadingAndParagraphIndentation: boolean;
7
7
  state?: EditorState;
8
8
  };
9
- export declare const useIndentationState: ({ api, allowHeadingAndParagraphIndentation, state }: UseIndentationStateProps) => import("../../pm-plugins/indentation-buttons").IndentationButtons | undefined;
9
+ export declare const useIndentationState: ({ api, allowHeadingAndParagraphIndentation, state, }: UseIndentationStateProps) => import("../../pm-plugins/indentation-buttons").IndentationButtons | undefined;
10
10
  export {};
@@ -1,12 +1,12 @@
1
1
  import React from 'react';
2
- import type { ExtractInjectionAPI } from "@atlaskit/editor-common/types";
2
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
3
  import type { ToolbarComponentTypes } from '@atlaskit/editor-toolbar-model';
4
- import type { ToolbarListsIndentationPlugin } from "../../toolbarListsIndentationPluginType";
4
+ import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
5
5
  type IndentMenuItemType = {
6
6
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
7
7
  allowHeadingAndParagraphIndentation: boolean;
8
8
  showIndentationButtons: boolean;
9
9
  parents: ToolbarComponentTypes;
10
10
  };
11
- export declare const IndentMenuItem: ({ api, showIndentationButtons, allowHeadingAndParagraphIndentation, parents }: IndentMenuItemType) => React.JSX.Element | null;
11
+ export declare const IndentMenuItem: ({ api, showIndentationButtons, allowHeadingAndParagraphIndentation, parents, }: IndentMenuItemType) => React.JSX.Element | null;
12
12
  export {};
@@ -1,12 +1,10 @@
1
1
  import React from 'react';
2
2
  import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
- import type { ToolbarButtonGroupLocation } from '@atlaskit/editor-toolbar';
4
3
  import type { ToolbarComponentTypes } from '@atlaskit/editor-toolbar-model';
5
4
  import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
6
5
  type ListsIndentationHeroButtonProps = {
7
6
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
8
- groupLocation?: ToolbarButtonGroupLocation;
9
7
  parents: ToolbarComponentTypes;
10
8
  };
11
- export declare const ListsIndentationHeroButton: ({ api, groupLocation, parents }: ListsIndentationHeroButtonProps) => React.JSX.Element;
9
+ export declare const ListsIndentationHeroButton: ({ api, parents }: ListsIndentationHeroButtonProps) => React.JSX.Element;
12
10
  export {};
@@ -1,12 +1,10 @@
1
1
  import React from 'react';
2
2
  import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
- import type { ToolbarButtonGroupLocation } from '@atlaskit/editor-toolbar';
4
3
  import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
5
4
  type ListsIndentationMenuProps = {
6
5
  children: React.ReactNode;
7
6
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
8
- groupLocation?: ToolbarButtonGroupLocation;
9
7
  allowHeadingAndParagraphIndentation: boolean;
10
8
  };
11
- export declare const ListsIndentationMenu: ({ children, api, groupLocation, allowHeadingAndParagraphIndentation }: ListsIndentationMenuProps) => React.JSX.Element;
9
+ export declare const ListsIndentationMenu: ({ children, api, allowHeadingAndParagraphIndentation, }: ListsIndentationMenuProps) => React.JSX.Element;
12
10
  export {};
@@ -1,12 +1,12 @@
1
1
  import React from 'react';
2
- import type { ExtractInjectionAPI } from "@atlaskit/editor-common/types";
2
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
3
  import type { ToolbarComponentTypes } from '@atlaskit/editor-toolbar-model';
4
- import type { ToolbarListsIndentationPlugin } from "../../toolbarListsIndentationPluginType";
4
+ import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
5
5
  type OutdentMenuItemType = {
6
6
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
7
7
  allowHeadingAndParagraphIndentation: boolean;
8
8
  showIndentationButtons: boolean;
9
9
  parents: ToolbarComponentTypes;
10
10
  };
11
- export declare const OutdentMenuItem: ({ api, allowHeadingAndParagraphIndentation, showIndentationButtons, parents }: OutdentMenuItemType) => React.JSX.Element | null;
11
+ export declare const OutdentMenuItem: ({ api, allowHeadingAndParagraphIndentation, showIndentationButtons, parents, }: OutdentMenuItemType) => React.JSX.Element | null;
12
12
  export {};
@@ -1,10 +1,10 @@
1
- import type { ExtractInjectionAPI } from "@atlaskit/editor-common/types";
2
- import type { RegisterComponent } from "@atlaskit/editor-toolbar-model";
3
- import type { ToolbarListsIndentationPlugin } from "../toolbarListsIndentationPluginType";
1
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
2
+ import type { RegisterComponent } from '@atlaskit/editor-toolbar-model';
3
+ import type { ToolbarListsIndentationPlugin } from '../toolbarListsIndentationPluginType';
4
4
  type GetToolbarComponentsProps = {
5
5
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
6
6
  showIndentationButtons: boolean;
7
7
  allowHeadingAndParagraphIndentation: boolean;
8
8
  };
9
- export declare const getToolbarComponents: ({ api, showIndentationButtons, allowHeadingAndParagraphIndentation }: GetToolbarComponentsProps) => RegisterComponent[];
9
+ export declare const getToolbarComponents: ({ api, showIndentationButtons, allowHeadingAndParagraphIndentation, }: GetToolbarComponentsProps) => RegisterComponent[];
10
10
  export {};
@@ -1,10 +1,10 @@
1
- import type { EditorState } from "prosemirror-state";
2
- import type { ExtractInjectionAPI } from "@atlaskit/editor-common/types";
3
- import type { ToolbarListsIndentationPlugin } from "../../toolbarListsIndentationPluginType";
1
+ import type { EditorState } from 'prosemirror-state';
2
+ import type { ExtractInjectionAPI } from '@atlaskit/editor-common/types';
3
+ import type { ToolbarListsIndentationPlugin } from '../../toolbarListsIndentationPluginType';
4
4
  type UseIndentationStateProps = {
5
5
  api?: ExtractInjectionAPI<ToolbarListsIndentationPlugin>;
6
6
  allowHeadingAndParagraphIndentation: boolean;
7
7
  state?: EditorState;
8
8
  };
9
- export declare const useIndentationState: ({ api, allowHeadingAndParagraphIndentation, state }: UseIndentationStateProps) => import("../../pm-plugins/indentation-buttons").IndentationButtons | undefined;
9
+ export declare const useIndentationState: ({ api, allowHeadingAndParagraphIndentation, state, }: UseIndentationStateProps) => import("../../pm-plugins/indentation-buttons").IndentationButtons | undefined;
10
10
  export {};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-plugin-toolbar-lists-indentation",
3
- "version": "4.2.0",
3
+ "version": "4.2.2",
4
4
  "description": "Toolbar lists and indentation plugin for @atlaskit/editor-core",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "license": "Apache-2.0",
@@ -44,16 +44,16 @@
44
44
  "@atlaskit/editor-plugin-toolbar": "^0.2.0",
45
45
  "@atlaskit/editor-prosemirror": "7.0.0",
46
46
  "@atlaskit/editor-shared-styles": "^3.6.0",
47
- "@atlaskit/editor-toolbar": "^0.2.0",
47
+ "@atlaskit/editor-toolbar": "^0.3.0",
48
48
  "@atlaskit/editor-toolbar-model": "^0.1.0",
49
- "@atlaskit/icon": "^27.11.0",
49
+ "@atlaskit/icon": "^27.12.0",
50
50
  "@atlaskit/platform-feature-flags": "^1.1.0",
51
- "@atlaskit/tmp-editor-statsig": "^9.27.0",
51
+ "@atlaskit/tmp-editor-statsig": "^9.29.0",
52
52
  "@atlaskit/tokens": "^6.0.0",
53
53
  "@babel/runtime": "^7.0.0"
54
54
  },
55
55
  "peerDependencies": {
56
- "@atlaskit/editor-common": "^107.22.0",
56
+ "@atlaskit/editor-common": "^107.24.0",
57
57
  "react": "^18.2.0",
58
58
  "react-dom": "^18.2.0",
59
59
  "react-intl-next": "npm:react-intl@^5.18.1"