@atlaskit/editor-common 126.4.4 → 127.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (36) hide show
  1. package/CHANGELOG.md +25 -0
  2. package/dist/cjs/messages/rule.js +20 -0
  3. package/dist/cjs/monitoring/error.js +1 -1
  4. package/dist/cjs/quick-insert/get-matching-quick-insert-components.js +1 -1
  5. package/dist/cjs/quick-insert/keys.js +37 -1
  6. package/dist/cjs/quick-insert/rank.js +3 -2
  7. package/dist/cjs/ui/DropList/index.js +1 -1
  8. package/dist/cjs/ui-color/ColorPalette/Color/index.js +3 -1
  9. package/dist/cjs/ui-color/ColorPalette/index.js +3 -1
  10. package/dist/cjs/ui-menu/ColorPickerButton/index.js +4 -2
  11. package/dist/es2019/messages/rule.js +20 -0
  12. package/dist/es2019/monitoring/error.js +1 -1
  13. package/dist/es2019/quick-insert/get-matching-quick-insert-components.js +1 -1
  14. package/dist/es2019/quick-insert/keys.js +36 -0
  15. package/dist/es2019/quick-insert/rank.js +13 -2
  16. package/dist/es2019/ui/DropList/index.js +1 -1
  17. package/dist/es2019/ui-color/ColorPalette/Color/index.js +3 -1
  18. package/dist/es2019/ui-color/ColorPalette/index.js +3 -1
  19. package/dist/es2019/ui-menu/ColorPickerButton/index.js +3 -2
  20. package/dist/esm/messages/rule.js +20 -0
  21. package/dist/esm/monitoring/error.js +1 -1
  22. package/dist/esm/quick-insert/get-matching-quick-insert-components.js +1 -1
  23. package/dist/esm/quick-insert/keys.js +36 -0
  24. package/dist/esm/quick-insert/rank.js +3 -2
  25. package/dist/esm/ui/DropList/index.js +1 -1
  26. package/dist/esm/ui-color/ColorPalette/Color/index.js +3 -1
  27. package/dist/esm/ui-color/ColorPalette/index.js +3 -1
  28. package/dist/esm/ui-menu/ColorPickerButton/index.js +4 -2
  29. package/dist/types/analytics/types/ai-suggestions-events.d.ts +12 -7
  30. package/dist/types/analytics/types/node-events.d.ts +4 -0
  31. package/dist/types/messages/rule.d.ts +20 -0
  32. package/dist/types/quick-insert/keys.d.ts +36 -0
  33. package/dist/types/quick-insert/rank.d.ts +1 -0
  34. package/dist/types/types/floating-toolbar.d.ts +23 -21
  35. package/dist/types/ui-menu/ColorPickerButton/index.d.ts +1 -0
  36. package/package.json +6 -6
package/CHANGELOG.md CHANGED
@@ -1,5 +1,30 @@
1
1
  # @atlaskit/editor-common
2
2
 
3
+ ## 127.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - [`4313c39b533f4`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/4313c39b533f4) -
8
+ Add a typed analytics event for undoing an accepted AI suggestion, track accepted-suggestion undo,
9
+ and correct regeneration analytics. Rename the AI suggestions payload attribute `suggestionAgeMs`
10
+ to `timeSinceGenerationMs`; analytics consumers should migrate to the new field name.
11
+
12
+ ### Minor Changes
13
+
14
+ - [`198417f90be8b`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/198417f90be8b) -
15
+ Centralize Create slash-menu ranks for linking-platform, Confluence extensions, and Loom under
16
+ platform_editor_slash_command.
17
+
18
+ ### Patch Changes
19
+
20
+ - [`9bc88d7233d4c`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/9bc88d7233d4c) -
21
+ Order platform_editor_slash_command search results by category before match score.
22
+ - [`281a2188b8d83`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/281a2188b8d83) -
23
+ [ux] [EDITOR-8348] this change adds a color picker to the divider floating toolbar behind
24
+ `platform_editor_lovability_dividers`. the selected color is applied behind
25
+ `platform_editor_lovability_dividers_attributes`.
26
+ - Updated dependencies
27
+
3
28
  ## 126.4.4
4
29
 
5
30
  ### Patch Changes
@@ -6,6 +6,26 @@ Object.defineProperty(exports, "__esModule", {
6
6
  exports.ruleMessages = void 0;
7
7
  var _reactIntl = require("react-intl");
8
8
  var ruleMessages = exports.ruleMessages = (0, _reactIntl.defineMessages)({
9
+ customDividerColor: {
10
+ id: 'editor-common.messages.rule.customDividerColor',
11
+ defaultMessage: 'Custom',
12
+ description: 'Label for a selected divider color that is not in the predefined color palette.'
13
+ },
14
+ boldGrayDividerColor: {
15
+ id: 'editor-common.messages.rule.boldGrayDividerColor',
16
+ defaultMessage: 'Bold gray',
17
+ description: 'Tooltip label for the bold gray divider color swatch.'
18
+ },
19
+ dividerColors: {
20
+ id: 'fabric.editor.rule.dividerColors',
21
+ defaultMessage: 'Divider colors',
22
+ description: 'Label for the color picker in the floating toolbar of a selected divider.'
23
+ },
24
+ defaultDividerColor: {
25
+ id: 'editor-common.messages.rule.defaultDividerColor',
26
+ defaultMessage: 'Default',
27
+ description: 'Tooltip label for the default divider color swatch.'
28
+ },
9
29
  dividerOptions: {
10
30
  id: 'fabric.editor.rule.dividerOptions',
11
31
  defaultMessage: 'Divider options',
@@ -27,7 +27,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
27
27
  var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
28
28
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
29
29
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
30
- var packageVersion = "126.4.3";
30
+ var packageVersion = "126.4.4";
31
31
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
32
32
  // Remove URL as it has UGC
33
33
  // Ignored via go/ees007
@@ -18,7 +18,7 @@ var getRank = function getRank(component, parentKey) {
18
18
  })) === null || _component$parents === void 0 ? void 0 : _component$parents.rank) !== null && _component$parents$fi !== void 0 ? _component$parents$fi : Number.MAX_SAFE_INTEGER;
19
19
  };
20
20
  var compareMatchedItems = function compareMatchedItems(a, b) {
21
- return a.score - b.score || a.sectionRank - b.sectionRank || a.itemRank - b.itemRank || a.identity.localeCompare(b.identity);
21
+ return a.sectionRank - b.sectionRank || a.score - b.score || a.itemRank - b.itemRank || a.identity.localeCompare(b.identity);
22
22
  };
23
23
 
24
24
  /**
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.getBlockTemplateMenuItem = exports.WARNING_PANEL_MENU_ITEM = exports.VIEW_ALL_ELEMENTS_MENU_ITEM = exports.UNORDERED_LIST_MENU_ITEM = exports.TWO_COLUMNS_LAYOUT_MENU_ITEM = exports.THREE_COLUMNS_LAYOUT_MENU_ITEM = exports.TEXT_FORMATTING_SECTION = exports.TABLE_MENU_ITEM = exports.SYNCED_BLOCK_MENU_ITEM = exports.SUCCESS_PANEL_MENU_ITEM = exports.STRUCTURE_SECTION = exports.STATUS_MENU_ITEM = exports.RULE_MENU_ITEM = exports.ROVO_SECTION = exports.RECOMMENDED_SECTION = exports.PLACEHOLDER_TEXT_MENU_ITEM = exports.OTHER_SECTION = exports.ORDERED_LIST_MENU_ITEM = exports.NOTE_PANEL_MENU_ITEM = exports.MENU = exports.MENTION_MENU_ITEM = exports.MEDIA_SECTION = exports.MEDIA_INSERT_MENU_ITEM = exports.LOOM_MENU_ITEM = exports.JIRA_WORK_ITEMS_MENU_ITEM = exports.INFO_PANEL_MENU_ITEM = exports.HYPERLINK_MENU_ITEM = exports.HELP_DIALOG_MENU_ITEM = exports.HEADING_6_MENU_ITEM = exports.HEADING_5_MENU_ITEM = exports.HEADING_4_MENU_ITEM = exports.HEADING_3_MENU_ITEM = exports.HEADING_2_MENU_ITEM = exports.HEADING_1_MENU_ITEM = exports.FOUR_COLUMNS_LAYOUT_MENU_ITEM = exports.FIVE_COLUMNS_LAYOUT_MENU_ITEM = exports.EXPAND_MENU_ITEM = exports.ERROR_PANEL_MENU_ITEM = exports.EMOJI_MENU_ITEM = exports.EMBED_SECTION = exports.DECISION_MENU_ITEM = exports.DATE_MENU_ITEM = exports.DATA_AND_CHARTS_SECTION = exports.CUSTOM_PANEL_MENU_ITEM = exports.CREATE_SECTION = exports.CONFLUENCE_LIST_MENU_ITEM = exports.CODE_BLOCK_MENU_ITEM = exports.BLOCK_TEMPLATES_SECTION = exports.BLOCKQUOTE_MENU_ITEM = exports.ASSETS_MENU_ITEM = exports.ASK_ROVO_MENU_ITEM = exports.AI_IMAGE_GENERATION_MENU_ITEM = exports.ACTION_MENU_ITEM = void 0;
6
+ exports.getBlockTemplateMenuItem = exports.WHITEBOARD_MENU_ITEM = exports.WARNING_PANEL_MENU_ITEM = exports.VIEW_ALL_ELEMENTS_MENU_ITEM = exports.UNORDERED_LIST_MENU_ITEM = exports.TWO_COLUMNS_LAYOUT_MENU_ITEM = exports.THREE_COLUMNS_LAYOUT_MENU_ITEM = exports.TEXT_FORMATTING_SECTION = exports.TABLE_MENU_ITEM = exports.SYNCED_BLOCK_MENU_ITEM = exports.SUCCESS_PANEL_MENU_ITEM = exports.STRUCTURE_SECTION = exports.STATUS_MENU_ITEM = exports.RULE_MENU_ITEM = exports.ROVO_SECTION = exports.ROADMAP_MENU_ITEM = exports.RETROSPECTIVE_MENU_ITEM = exports.RECOMMENDED_SECTION = exports.PLACEHOLDER_TEXT_MENU_ITEM = exports.OTHER_SECTION = exports.ORDERED_LIST_MENU_ITEM = exports.NOTE_PANEL_MENU_ITEM = exports.MENU = exports.MENTION_MENU_ITEM = exports.MEDIA_SECTION = exports.MEDIA_INSERT_MENU_ITEM = exports.LOOM_MENU_ITEM = exports.JIRA_WORK_ITEMS_MENU_ITEM = exports.JIRA_ISSUE_MENU_ITEM = exports.INFO_PANEL_MENU_ITEM = exports.HYPERLINK_MENU_ITEM = exports.HELP_DIALOG_MENU_ITEM = exports.HEADING_6_MENU_ITEM = exports.HEADING_5_MENU_ITEM = exports.HEADING_4_MENU_ITEM = exports.HEADING_3_MENU_ITEM = exports.HEADING_2_MENU_ITEM = exports.HEADING_1_MENU_ITEM = exports.FOUR_COLUMNS_LAYOUT_MENU_ITEM = exports.FLOWCHART_MENU_ITEM = exports.FIVE_COLUMNS_LAYOUT_MENU_ITEM = exports.EXPAND_MENU_ITEM = exports.ERROR_PANEL_MENU_ITEM = exports.EMOJI_MENU_ITEM = exports.EMBED_SECTION = exports.DIAGRAM_MENU_ITEM = exports.DECISION_MENU_ITEM = exports.DATE_MENU_ITEM = exports.DATA_AND_CHARTS_SECTION = exports.DATABASE_MENU_ITEM = exports.CUSTOM_PANEL_MENU_ITEM = exports.CREATE_SECTION = exports.CONFLUENCE_PAGE_MENU_ITEM = exports.CONFLUENCE_LIST_MENU_ITEM = exports.CODE_BLOCK_MENU_ITEM = exports.BRAINSTORMING_MENU_ITEM = exports.BLOCK_TEMPLATES_SECTION = exports.BLOCKQUOTE_MENU_ITEM = exports.ASSETS_MENU_ITEM = exports.ASK_ROVO_MENU_ITEM = exports.AI_IMAGE_GENERATION_MENU_ITEM = exports.ACTION_MENU_ITEM = void 0;
7
7
  /* eslint-disable @atlaskit/volt-strict-mode/no-multiple-exports */
8
8
 
9
9
  var MENU = exports.MENU = {
@@ -138,6 +138,42 @@ var LOOM_MENU_ITEM = exports.LOOM_MENU_ITEM = {
138
138
  key: 'quick-insert-loom-menu-item',
139
139
  type: 'menu-item'
140
140
  };
141
+ var JIRA_ISSUE_MENU_ITEM = exports.JIRA_ISSUE_MENU_ITEM = {
142
+ key: 'com.atlassian.linking-platform.create:linking-platform-create-jira-issue',
143
+ type: 'menu-item'
144
+ };
145
+ var CONFLUENCE_PAGE_MENU_ITEM = exports.CONFLUENCE_PAGE_MENU_ITEM = {
146
+ key: 'com.atlassian.linking-platform.create:linking-platform-create-confluence-page',
147
+ type: 'menu-item'
148
+ };
149
+ var WHITEBOARD_MENU_ITEM = exports.WHITEBOARD_MENU_ITEM = {
150
+ key: 'whiteboard-extension:create-whiteboard',
151
+ type: 'menu-item'
152
+ };
153
+ var DIAGRAM_MENU_ITEM = exports.DIAGRAM_MENU_ITEM = {
154
+ key: 'whiteboard-extension:create-diagram',
155
+ type: 'menu-item'
156
+ };
157
+ var FLOWCHART_MENU_ITEM = exports.FLOWCHART_MENU_ITEM = {
158
+ key: 'whiteboard-extension:create-flowchart',
159
+ type: 'menu-item'
160
+ };
161
+ var BRAINSTORMING_MENU_ITEM = exports.BRAINSTORMING_MENU_ITEM = {
162
+ key: 'whiteboard-extension:create-brainstorming',
163
+ type: 'menu-item'
164
+ };
165
+ var RETROSPECTIVE_MENU_ITEM = exports.RETROSPECTIVE_MENU_ITEM = {
166
+ key: 'whiteboard-extension:create-retrospective',
167
+ type: 'menu-item'
168
+ };
169
+ var ROADMAP_MENU_ITEM = exports.ROADMAP_MENU_ITEM = {
170
+ key: 'whiteboard-extension:create-roadmap',
171
+ type: 'menu-item'
172
+ };
173
+ var DATABASE_MENU_ITEM = exports.DATABASE_MENU_ITEM = {
174
+ key: 'database-extension:create-database',
175
+ type: 'menu-item'
176
+ };
141
177
  var MENTION_MENU_ITEM = exports.MENTION_MENU_ITEM = {
142
178
  key: 'quick-insert-mention-menu-item',
143
179
  type: 'menu-item'
@@ -4,14 +4,15 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
4
4
  Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
- exports.TEXT_FORMATTING_SECTION_RANK = exports.STRUCTURE_SECTION_RANK = exports.ROVO_SECTION_RANK = exports.QUICK_INSERT_MENU_RANK = exports.OTHER_SECTION_RANK = exports.MEDIA_SECTION_RANK = exports.EXTENSION_ITEM_RANK = exports.DATA_AND_CHARTS_SECTION_RANK = exports.CATEGORY_VIEW_MORE_RANK = void 0;
7
+ exports.TEXT_FORMATTING_SECTION_RANK = exports.STRUCTURE_SECTION_RANK = exports.ROVO_SECTION_RANK = exports.QUICK_INSERT_MENU_RANK = exports.OTHER_SECTION_RANK = exports.MEDIA_SECTION_RANK = exports.EXTENSION_ITEM_RANK = exports.DATA_AND_CHARTS_SECTION_RANK = exports.CREATE_SECTION_RANK = exports.CATEGORY_VIEW_MORE_RANK = void 0;
8
8
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
9
9
  var _keys = require("./keys");
10
10
  var _STRUCTURE_SECTION_RA;
11
11
  /* eslint-disable @atlaskit/volt-strict-mode/no-multiple-exports */
12
12
  var QUICK_INSERT_MENU_RANK = exports.QUICK_INSERT_MENU_RANK = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, _keys.RECOMMENDED_SECTION.key, 0), _keys.STRUCTURE_SECTION.key, 1), _keys.MEDIA_SECTION.key, 2), _keys.CREATE_SECTION.key, 3), _keys.EMBED_SECTION.key, 4), _keys.TEXT_FORMATTING_SECTION.key, 5), _keys.ROVO_SECTION.key, 6), _keys.DATA_AND_CHARTS_SECTION.key, 7), _keys.BLOCK_TEMPLATES_SECTION.key, 8), _keys.OTHER_SECTION.key, 9);
13
13
  var STRUCTURE_SECTION_RANK = exports.STRUCTURE_SECTION_RANK = (_STRUCTURE_SECTION_RA = {}, (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_STRUCTURE_SECTION_RA, _keys.ACTION_MENU_ITEM.key, 100), _keys.TABLE_MENU_ITEM.key, 200), _keys.STATUS_MENU_ITEM.key, 300), _keys.DATE_MENU_ITEM.key, 400), _keys.MENTION_MENU_ITEM.key, 500), _keys.EXPAND_MENU_ITEM.key, 700), _keys.CODE_BLOCK_MENU_ITEM.key, 800), _keys.INFO_PANEL_MENU_ITEM.key, 900), _keys.NOTE_PANEL_MENU_ITEM.key, 1000), _keys.SUCCESS_PANEL_MENU_ITEM.key, 1100), (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)(_STRUCTURE_SECTION_RA, _keys.WARNING_PANEL_MENU_ITEM.key, 1200), _keys.ERROR_PANEL_MENU_ITEM.key, 1300), _keys.CUSTOM_PANEL_MENU_ITEM.key, 1400), _keys.TWO_COLUMNS_LAYOUT_MENU_ITEM.key, 1500), _keys.THREE_COLUMNS_LAYOUT_MENU_ITEM.key, 1600), _keys.FOUR_COLUMNS_LAYOUT_MENU_ITEM.key, 1700), _keys.FIVE_COLUMNS_LAYOUT_MENU_ITEM.key, 1800), _keys.SYNCED_BLOCK_MENU_ITEM.key, 2300), _keys.RULE_MENU_ITEM.key, 2400), _keys.DECISION_MENU_ITEM.key, 2800));
14
- var MEDIA_SECTION_RANK = exports.MEDIA_SECTION_RANK = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, _keys.MEDIA_INSERT_MENU_ITEM.key, 100), _keys.HYPERLINK_MENU_ITEM.key, 200), _keys.EMOJI_MENU_ITEM.key, 300), _keys.LOOM_MENU_ITEM.key, 400), _keys.AI_IMAGE_GENERATION_MENU_ITEM.key, 1600);
14
+ var MEDIA_SECTION_RANK = exports.MEDIA_SECTION_RANK = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, _keys.MEDIA_INSERT_MENU_ITEM.key, 100), _keys.HYPERLINK_MENU_ITEM.key, 200), _keys.EMOJI_MENU_ITEM.key, 300), _keys.AI_IMAGE_GENERATION_MENU_ITEM.key, 1600);
15
+ var CREATE_SECTION_RANK = exports.CREATE_SECTION_RANK = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, _keys.JIRA_ISSUE_MENU_ITEM.key, 100), _keys.CONFLUENCE_PAGE_MENU_ITEM.key, 200), _keys.WHITEBOARD_MENU_ITEM.key, 500), _keys.DIAGRAM_MENU_ITEM.key, 600), _keys.FLOWCHART_MENU_ITEM.key, 700), _keys.BRAINSTORMING_MENU_ITEM.key, 800), _keys.RETROSPECTIVE_MENU_ITEM.key, 900), _keys.ROADMAP_MENU_ITEM.key, 1000), _keys.DATABASE_MENU_ITEM.key, 1100), _keys.LOOM_MENU_ITEM.key, 1200);
15
16
  var TEXT_FORMATTING_SECTION_RANK = exports.TEXT_FORMATTING_SECTION_RANK = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, _keys.UNORDERED_LIST_MENU_ITEM.key, 100), _keys.ORDERED_LIST_MENU_ITEM.key, 200), _keys.HEADING_1_MENU_ITEM.key, 300), _keys.HEADING_2_MENU_ITEM.key, 400), _keys.HEADING_3_MENU_ITEM.key, 500), _keys.HEADING_4_MENU_ITEM.key, 600), _keys.HEADING_5_MENU_ITEM.key, 700), _keys.HEADING_6_MENU_ITEM.key, 800), _keys.BLOCKQUOTE_MENU_ITEM.key, 900), _keys.PLACEHOLDER_TEXT_MENU_ITEM.key, 1000);
16
17
  var ROVO_SECTION_RANK = exports.ROVO_SECTION_RANK = (0, _defineProperty2.default)({}, _keys.ASK_ROVO_MENU_ITEM.key, 100);
17
18
  var DATA_AND_CHARTS_SECTION_RANK = exports.DATA_AND_CHARTS_SECTION_RANK = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, _keys.JIRA_WORK_ITEMS_MENU_ITEM.key, 300), _keys.CONFLUENCE_LIST_MENU_ITEM.key, 400), _keys.ASSETS_MENU_ITEM.key, 500);
@@ -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 = "126.4.3";
27
+ var packageVersion = "126.4.4";
28
28
  var halfFocusRing = 1;
29
29
  var dropOffset = '0, 8';
30
30
  var fadeIn = (0, _react2.keyframes)({
@@ -24,6 +24,7 @@ var Color = function Color(props) {
24
24
  label = props.label,
25
25
  isSelected = props.isSelected,
26
26
  borderColor = props.borderColor,
27
+ checkMarkColor = props.checkMarkColor,
27
28
  hexToPaletteColor = props.hexToPaletteColor,
28
29
  decorator = props.decorator;
29
30
  var colorStyle = hexToPaletteColor ? hexToPaletteColor(value) : value;
@@ -72,7 +73,8 @@ var Color = function Color(props) {
72
73
  },
73
74
  autoFocus: autoFocus
74
75
  }, !decorator && isSelected && (0, _react2.jsx)(_checkMark.default, {
75
- label: ""
76
+ label: "",
77
+ color: checkMarkColor
76
78
  }), decorator)));
77
79
  };
78
80
  var _default = exports.default = Color;
@@ -9,6 +9,7 @@ var _react = _interopRequireDefault(require("react"));
9
9
  var _react2 = require("@emotion/react");
10
10
  var _chromatism = _interopRequireDefault(require("chromatism"));
11
11
  var _reactIntl = require("react-intl");
12
+ var _isExperimentEnabled = require("@atlaskit/platform-feature-experiments/is-experiment-enabled");
12
13
  var _useThemeObserver2 = require("@atlaskit/tokens/use-theme-observer");
13
14
  var _Color = _interopRequireDefault(require("./Color"));
14
15
  var _getColorMessage = _interopRequireDefault(require("./Palettes/getColorMessage"));
@@ -63,6 +64,7 @@ var ColorPalette = function ColorPalette(props) {
63
64
  var _useThemeObserver = (0, _useThemeObserver2.useThemeObserver)(),
64
65
  tokenTheme = _useThemeObserver.colorMode;
65
66
  var useIconToken = !!hexToPaletteColor;
67
+ var isDividerExperimentEnabled = (0, _isExperimentEnabled.isExperimentEnabled)('platform_editor_lovability_dividers');
66
68
  var colorsPerRow = _react.default.useMemo(function () {
67
69
  return (0, _utils.getColorsPerRowFromPalette)(palette, cols);
68
70
  }, [palette, cols]);
@@ -98,7 +100,7 @@ var ColorPalette = function ColorPalette(props) {
98
100
  onClick: onClick,
99
101
  onKeyDown: onKeyDown,
100
102
  isSelected: value === selectedColor,
101
- checkMarkColor: getCheckMarkColor(value, useIconToken),
103
+ checkMarkColor: isDividerExperimentEnabled ? getCheckMarkColor(value, useIconToken) : undefined,
102
104
  hexToPaletteColor: hexToPaletteColor,
103
105
  decorator: decorator
104
106
  });
@@ -159,7 +159,9 @@ var ColorPickerButton = function ColorPickerButton(props) {
159
159
  createAnalyticsEvent = props.createAnalyticsEvent,
160
160
  colorPalette = props.colorPalette,
161
161
  placement = props.placement,
162
- skipFocusButtonAfterPick = props.skipFocusButtonAfterPick;
162
+ skipFocusButtonAfterPick = props.skipFocusButtonAfterPick,
163
+ _props$hideExpandIcon = props.hideExpandIcon,
164
+ hideExpandIcon = _props$hideExpandIcon === void 0 ? false : _props$hideExpandIcon;
163
165
  var onColorSelected = _react.default.useCallback(function (color, label) {
164
166
  setIsOpenedByKeyboard(false);
165
167
  setIsPopupOpen(false);
@@ -282,7 +284,7 @@ var ColorPickerButton = function ColorPickerButton(props) {
282
284
  }, (0, _react2.jsx)("span", {
283
285
  // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
284
286
  css: buttonStyleVisualRefresh
285
- }), (0, _react2.jsx)(_primitives.Box, {
287
+ }), !hideExpandIcon && (0, _react2.jsx)(_primitives.Box, {
286
288
  xcss: colorPickerExpandContainerVisualRefresh
287
289
  }, (0, _react2.jsx)(_chevronDown.default, {
288
290
  color: "currentColor",
@@ -1,5 +1,25 @@
1
1
  import { defineMessages } from 'react-intl';
2
2
  export const ruleMessages = defineMessages({
3
+ customDividerColor: {
4
+ id: 'editor-common.messages.rule.customDividerColor',
5
+ defaultMessage: 'Custom',
6
+ description: 'Label for a selected divider color that is not in the predefined color palette.'
7
+ },
8
+ boldGrayDividerColor: {
9
+ id: 'editor-common.messages.rule.boldGrayDividerColor',
10
+ defaultMessage: 'Bold gray',
11
+ description: 'Tooltip label for the bold gray divider color swatch.'
12
+ },
13
+ dividerColors: {
14
+ id: 'fabric.editor.rule.dividerColors',
15
+ defaultMessage: 'Divider colors',
16
+ description: 'Label for the color picker in the floating toolbar of a selected divider.'
17
+ },
18
+ defaultDividerColor: {
19
+ id: 'editor-common.messages.rule.defaultDividerColor',
20
+ defaultMessage: 'Default',
21
+ description: 'Tooltip label for the default divider color swatch.'
22
+ },
3
23
  dividerOptions: {
4
24
  id: 'fabric.editor.rule.dividerOptions',
5
25
  defaultMessage: 'Divider options',
@@ -13,7 +13,7 @@ const NETWORK_FAILURE_REGEX = /^network failure/i;
13
13
  const RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
14
14
  const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
15
15
  const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
16
- const packageVersion = "126.4.3";
16
+ const packageVersion = "126.4.4";
17
17
  const sanitiseSentryEvents = (data, _hint) => {
18
18
  // Remove URL as it has UGC
19
19
  // Ignored via go/ees007
@@ -6,7 +6,7 @@ const getRank = (component, parentKey) => {
6
6
  var _component$parents$fi, _component$parents, _component$parents$fi2;
7
7
  return (_component$parents$fi = (_component$parents = component.parents) === null || _component$parents === void 0 ? void 0 : (_component$parents$fi2 = _component$parents.find(parent => parent.key === parentKey)) === null || _component$parents$fi2 === void 0 ? void 0 : _component$parents$fi2.rank) !== null && _component$parents$fi !== void 0 ? _component$parents$fi : Number.MAX_SAFE_INTEGER;
8
8
  };
9
- const compareMatchedItems = (a, b) => a.score - b.score || a.sectionRank - b.sectionRank || a.itemRank - b.itemRank || a.identity.localeCompare(b.identity);
9
+ const compareMatchedItems = (a, b) => a.sectionRank - b.sectionRank || a.score - b.score || a.itemRank - b.itemRank || a.identity.localeCompare(b.identity);
10
10
 
11
11
  /**
12
12
  * Resolves registered menu items for a non-empty query. This intentionally has
@@ -132,6 +132,42 @@ export const LOOM_MENU_ITEM = {
132
132
  key: 'quick-insert-loom-menu-item',
133
133
  type: 'menu-item'
134
134
  };
135
+ export const JIRA_ISSUE_MENU_ITEM = {
136
+ key: 'com.atlassian.linking-platform.create:linking-platform-create-jira-issue',
137
+ type: 'menu-item'
138
+ };
139
+ export const CONFLUENCE_PAGE_MENU_ITEM = {
140
+ key: 'com.atlassian.linking-platform.create:linking-platform-create-confluence-page',
141
+ type: 'menu-item'
142
+ };
143
+ export const WHITEBOARD_MENU_ITEM = {
144
+ key: 'whiteboard-extension:create-whiteboard',
145
+ type: 'menu-item'
146
+ };
147
+ export const DIAGRAM_MENU_ITEM = {
148
+ key: 'whiteboard-extension:create-diagram',
149
+ type: 'menu-item'
150
+ };
151
+ export const FLOWCHART_MENU_ITEM = {
152
+ key: 'whiteboard-extension:create-flowchart',
153
+ type: 'menu-item'
154
+ };
155
+ export const BRAINSTORMING_MENU_ITEM = {
156
+ key: 'whiteboard-extension:create-brainstorming',
157
+ type: 'menu-item'
158
+ };
159
+ export const RETROSPECTIVE_MENU_ITEM = {
160
+ key: 'whiteboard-extension:create-retrospective',
161
+ type: 'menu-item'
162
+ };
163
+ export const ROADMAP_MENU_ITEM = {
164
+ key: 'whiteboard-extension:create-roadmap',
165
+ type: 'menu-item'
166
+ };
167
+ export const DATABASE_MENU_ITEM = {
168
+ key: 'database-extension:create-database',
169
+ type: 'menu-item'
170
+ };
135
171
  export const MENTION_MENU_ITEM = {
136
172
  key: 'quick-insert-mention-menu-item',
137
173
  type: 'menu-item'
@@ -1,6 +1,6 @@
1
1
  /* eslint-disable @atlaskit/volt-strict-mode/no-multiple-exports */
2
2
 
3
- import { ACTION_MENU_ITEM, AI_IMAGE_GENERATION_MENU_ITEM, ASK_ROVO_MENU_ITEM, ASSETS_MENU_ITEM, BLOCKQUOTE_MENU_ITEM, BLOCK_TEMPLATES_SECTION, CODE_BLOCK_MENU_ITEM, CONFLUENCE_LIST_MENU_ITEM, CREATE_SECTION, CUSTOM_PANEL_MENU_ITEM, DATE_MENU_ITEM, DATA_AND_CHARTS_SECTION, DECISION_MENU_ITEM, EMBED_SECTION, EMOJI_MENU_ITEM, ERROR_PANEL_MENU_ITEM, EXPAND_MENU_ITEM, FIVE_COLUMNS_LAYOUT_MENU_ITEM, FOUR_COLUMNS_LAYOUT_MENU_ITEM, HEADING_1_MENU_ITEM, HEADING_2_MENU_ITEM, HEADING_3_MENU_ITEM, HEADING_4_MENU_ITEM, HEADING_5_MENU_ITEM, HEADING_6_MENU_ITEM, HELP_DIALOG_MENU_ITEM, HYPERLINK_MENU_ITEM, INFO_PANEL_MENU_ITEM, JIRA_WORK_ITEMS_MENU_ITEM, LOOM_MENU_ITEM, MEDIA_INSERT_MENU_ITEM, MEDIA_SECTION, MENTION_MENU_ITEM, NOTE_PANEL_MENU_ITEM, ORDERED_LIST_MENU_ITEM, OTHER_SECTION, PLACEHOLDER_TEXT_MENU_ITEM, RECOMMENDED_SECTION, ROVO_SECTION, RULE_MENU_ITEM, STATUS_MENU_ITEM, STRUCTURE_SECTION, SUCCESS_PANEL_MENU_ITEM, SYNCED_BLOCK_MENU_ITEM, TABLE_MENU_ITEM, TEXT_FORMATTING_SECTION, THREE_COLUMNS_LAYOUT_MENU_ITEM, TWO_COLUMNS_LAYOUT_MENU_ITEM, UNORDERED_LIST_MENU_ITEM, WARNING_PANEL_MENU_ITEM } from './keys';
3
+ import { ACTION_MENU_ITEM, AI_IMAGE_GENERATION_MENU_ITEM, ASK_ROVO_MENU_ITEM, ASSETS_MENU_ITEM, BRAINSTORMING_MENU_ITEM, BLOCKQUOTE_MENU_ITEM, BLOCK_TEMPLATES_SECTION, CODE_BLOCK_MENU_ITEM, CONFLUENCE_LIST_MENU_ITEM, CONFLUENCE_PAGE_MENU_ITEM, CREATE_SECTION, CUSTOM_PANEL_MENU_ITEM, DATABASE_MENU_ITEM, DATE_MENU_ITEM, DATA_AND_CHARTS_SECTION, DECISION_MENU_ITEM, DIAGRAM_MENU_ITEM, EMBED_SECTION, EMOJI_MENU_ITEM, ERROR_PANEL_MENU_ITEM, EXPAND_MENU_ITEM, FIVE_COLUMNS_LAYOUT_MENU_ITEM, FLOWCHART_MENU_ITEM, FOUR_COLUMNS_LAYOUT_MENU_ITEM, HEADING_1_MENU_ITEM, HEADING_2_MENU_ITEM, HEADING_3_MENU_ITEM, HEADING_4_MENU_ITEM, HEADING_5_MENU_ITEM, HEADING_6_MENU_ITEM, HELP_DIALOG_MENU_ITEM, HYPERLINK_MENU_ITEM, INFO_PANEL_MENU_ITEM, JIRA_ISSUE_MENU_ITEM, JIRA_WORK_ITEMS_MENU_ITEM, LOOM_MENU_ITEM, MEDIA_INSERT_MENU_ITEM, MEDIA_SECTION, MENTION_MENU_ITEM, NOTE_PANEL_MENU_ITEM, ORDERED_LIST_MENU_ITEM, OTHER_SECTION, PLACEHOLDER_TEXT_MENU_ITEM, RECOMMENDED_SECTION, ROADMAP_MENU_ITEM, RETROSPECTIVE_MENU_ITEM, ROVO_SECTION, RULE_MENU_ITEM, STATUS_MENU_ITEM, STRUCTURE_SECTION, SUCCESS_PANEL_MENU_ITEM, SYNCED_BLOCK_MENU_ITEM, TABLE_MENU_ITEM, TEXT_FORMATTING_SECTION, THREE_COLUMNS_LAYOUT_MENU_ITEM, TWO_COLUMNS_LAYOUT_MENU_ITEM, UNORDERED_LIST_MENU_ITEM, WARNING_PANEL_MENU_ITEM, WHITEBOARD_MENU_ITEM } from './keys';
4
4
  export const QUICK_INSERT_MENU_RANK = {
5
5
  [RECOMMENDED_SECTION.key]: 0,
6
6
  [STRUCTURE_SECTION.key]: 1,
@@ -39,9 +39,20 @@ export const MEDIA_SECTION_RANK = {
39
39
  [MEDIA_INSERT_MENU_ITEM.key]: 100,
40
40
  [HYPERLINK_MENU_ITEM.key]: 200,
41
41
  [EMOJI_MENU_ITEM.key]: 300,
42
- [LOOM_MENU_ITEM.key]: 400,
43
42
  [AI_IMAGE_GENERATION_MENU_ITEM.key]: 1600
44
43
  };
44
+ export const CREATE_SECTION_RANK = {
45
+ [JIRA_ISSUE_MENU_ITEM.key]: 100,
46
+ [CONFLUENCE_PAGE_MENU_ITEM.key]: 200,
47
+ [WHITEBOARD_MENU_ITEM.key]: 500,
48
+ [DIAGRAM_MENU_ITEM.key]: 600,
49
+ [FLOWCHART_MENU_ITEM.key]: 700,
50
+ [BRAINSTORMING_MENU_ITEM.key]: 800,
51
+ [RETROSPECTIVE_MENU_ITEM.key]: 900,
52
+ [ROADMAP_MENU_ITEM.key]: 1000,
53
+ [DATABASE_MENU_ITEM.key]: 1100,
54
+ [LOOM_MENU_ITEM.key]: 1200
55
+ };
45
56
  export const TEXT_FORMATTING_SECTION_RANK = {
46
57
  [UNORDERED_LIST_MENU_ITEM.key]: 100,
47
58
  [ORDERED_LIST_MENU_ITEM.key]: 200,
@@ -14,7 +14,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
14
14
  import { fg } from '@atlaskit/platform-feature-flags/fg';
15
15
  import Layer from '../Layer';
16
16
  const packageName = "@atlaskit/editor-common";
17
- const packageVersion = "126.4.3";
17
+ const packageVersion = "126.4.4";
18
18
  const halfFocusRing = 1;
19
19
  const dropOffset = '0, 8';
20
20
  const fadeIn = keyframes({
@@ -16,6 +16,7 @@ const Color = props => {
16
16
  label,
17
17
  isSelected,
18
18
  borderColor,
19
+ checkMarkColor,
19
20
  /**
20
21
  * When hexToPaletteColor prop is set,
21
22
  * it will be used to get background color style based on
@@ -74,7 +75,8 @@ const Color = props => {
74
75
  },
75
76
  autoFocus: autoFocus
76
77
  }, !decorator && isSelected && jsx(EditorDoneIcon, {
77
- label: ""
78
+ label: "",
79
+ color: checkMarkColor
78
80
  }), decorator)));
79
81
  };
80
82
  export default Color;
@@ -8,6 +8,7 @@ import React from 'react';
8
8
  import { jsx } from '@emotion/react';
9
9
  import chromatism from 'chromatism';
10
10
  import { injectIntl } from 'react-intl';
11
+ import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
11
12
  import { useThemeObserver } from '@atlaskit/tokens/use-theme-observer';
12
13
  import Color from './Color';
13
14
  import getColorMessage from './Palettes/getColorMessage';
@@ -59,6 +60,7 @@ const ColorPalette = props => {
59
60
  colorMode: tokenTheme
60
61
  } = useThemeObserver();
61
62
  const useIconToken = !!hexToPaletteColor;
63
+ const isDividerExperimentEnabled = isExperimentEnabled('platform_editor_lovability_dividers');
62
64
  const colorsPerRow = React.useMemo(() => {
63
65
  return getColorsPerRowFromPalette(palette, cols);
64
66
  }, [palette, cols]);
@@ -94,7 +96,7 @@ const ColorPalette = props => {
94
96
  onClick: onClick,
95
97
  onKeyDown: onKeyDown,
96
98
  isSelected: value === selectedColor,
97
- checkMarkColor: getCheckMarkColor(value, useIconToken),
99
+ checkMarkColor: isDividerExperimentEnabled ? getCheckMarkColor(value, useIconToken) : undefined,
98
100
  hexToPaletteColor: hexToPaletteColor,
99
101
  decorator: decorator
100
102
  });
@@ -133,7 +133,8 @@ const ColorPickerButton = props => {
133
133
  createAnalyticsEvent,
134
134
  colorPalette,
135
135
  placement,
136
- skipFocusButtonAfterPick
136
+ skipFocusButtonAfterPick,
137
+ hideExpandIcon = false
137
138
  } = props;
138
139
  const onColorSelected = React.useCallback((color, label) => {
139
140
  setIsOpenedByKeyboard(false);
@@ -256,7 +257,7 @@ const ColorPickerButton = props => {
256
257
  }, jsx("span", {
257
258
  // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
258
259
  css: buttonStyleVisualRefresh
259
- }), jsx(Box, {
260
+ }), !hideExpandIcon && jsx(Box, {
260
261
  xcss: colorPickerExpandContainerVisualRefresh
261
262
  }, jsx(ChevronDownIcon, {
262
263
  color: "currentColor",
@@ -1,5 +1,25 @@
1
1
  import { defineMessages } from 'react-intl';
2
2
  export var ruleMessages = defineMessages({
3
+ customDividerColor: {
4
+ id: 'editor-common.messages.rule.customDividerColor',
5
+ defaultMessage: 'Custom',
6
+ description: 'Label for a selected divider color that is not in the predefined color palette.'
7
+ },
8
+ boldGrayDividerColor: {
9
+ id: 'editor-common.messages.rule.boldGrayDividerColor',
10
+ defaultMessage: 'Bold gray',
11
+ description: 'Tooltip label for the bold gray divider color swatch.'
12
+ },
13
+ dividerColors: {
14
+ id: 'fabric.editor.rule.dividerColors',
15
+ defaultMessage: 'Divider colors',
16
+ description: 'Label for the color picker in the floating toolbar of a selected divider.'
17
+ },
18
+ defaultDividerColor: {
19
+ id: 'editor-common.messages.rule.defaultDividerColor',
20
+ defaultMessage: 'Default',
21
+ description: 'Tooltip label for the default divider color swatch.'
22
+ },
3
23
  dividerOptions: {
4
24
  id: 'fabric.editor.rule.dividerOptions',
5
25
  defaultMessage: 'Divider options',
@@ -19,7 +19,7 @@ var NETWORK_FAILURE_REGEX = /^network failure/i;
19
19
  var RESIZE_OBSERVER_LOOP_REGEX = /ResizeObserver loop completed with undelivered notifications/;
20
20
  var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
21
21
  var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
22
- var packageVersion = "126.4.3";
22
+ var packageVersion = "126.4.4";
23
23
  var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
24
24
  // Remove URL as it has UGC
25
25
  // Ignored via go/ees007
@@ -12,7 +12,7 @@ var getRank = function getRank(component, parentKey) {
12
12
  })) === null || _component$parents === void 0 ? void 0 : _component$parents.rank) !== null && _component$parents$fi !== void 0 ? _component$parents$fi : Number.MAX_SAFE_INTEGER;
13
13
  };
14
14
  var compareMatchedItems = function compareMatchedItems(a, b) {
15
- return a.score - b.score || a.sectionRank - b.sectionRank || a.itemRank - b.itemRank || a.identity.localeCompare(b.identity);
15
+ return a.sectionRank - b.sectionRank || a.score - b.score || a.itemRank - b.itemRank || a.identity.localeCompare(b.identity);
16
16
  };
17
17
 
18
18
  /**
@@ -132,6 +132,42 @@ export var LOOM_MENU_ITEM = {
132
132
  key: 'quick-insert-loom-menu-item',
133
133
  type: 'menu-item'
134
134
  };
135
+ export var JIRA_ISSUE_MENU_ITEM = {
136
+ key: 'com.atlassian.linking-platform.create:linking-platform-create-jira-issue',
137
+ type: 'menu-item'
138
+ };
139
+ export var CONFLUENCE_PAGE_MENU_ITEM = {
140
+ key: 'com.atlassian.linking-platform.create:linking-platform-create-confluence-page',
141
+ type: 'menu-item'
142
+ };
143
+ export var WHITEBOARD_MENU_ITEM = {
144
+ key: 'whiteboard-extension:create-whiteboard',
145
+ type: 'menu-item'
146
+ };
147
+ export var DIAGRAM_MENU_ITEM = {
148
+ key: 'whiteboard-extension:create-diagram',
149
+ type: 'menu-item'
150
+ };
151
+ export var FLOWCHART_MENU_ITEM = {
152
+ key: 'whiteboard-extension:create-flowchart',
153
+ type: 'menu-item'
154
+ };
155
+ export var BRAINSTORMING_MENU_ITEM = {
156
+ key: 'whiteboard-extension:create-brainstorming',
157
+ type: 'menu-item'
158
+ };
159
+ export var RETROSPECTIVE_MENU_ITEM = {
160
+ key: 'whiteboard-extension:create-retrospective',
161
+ type: 'menu-item'
162
+ };
163
+ export var ROADMAP_MENU_ITEM = {
164
+ key: 'whiteboard-extension:create-roadmap',
165
+ type: 'menu-item'
166
+ };
167
+ export var DATABASE_MENU_ITEM = {
168
+ key: 'database-extension:create-database',
169
+ type: 'menu-item'
170
+ };
135
171
  export var MENTION_MENU_ITEM = {
136
172
  key: 'quick-insert-mention-menu-item',
137
173
  type: 'menu-item'
@@ -2,10 +2,11 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  var _STRUCTURE_SECTION_RA;
3
3
  /* eslint-disable @atlaskit/volt-strict-mode/no-multiple-exports */
4
4
 
5
- import { ACTION_MENU_ITEM, AI_IMAGE_GENERATION_MENU_ITEM, ASK_ROVO_MENU_ITEM, ASSETS_MENU_ITEM, BLOCKQUOTE_MENU_ITEM, BLOCK_TEMPLATES_SECTION, CODE_BLOCK_MENU_ITEM, CONFLUENCE_LIST_MENU_ITEM, CREATE_SECTION, CUSTOM_PANEL_MENU_ITEM, DATE_MENU_ITEM, DATA_AND_CHARTS_SECTION, DECISION_MENU_ITEM, EMBED_SECTION, EMOJI_MENU_ITEM, ERROR_PANEL_MENU_ITEM, EXPAND_MENU_ITEM, FIVE_COLUMNS_LAYOUT_MENU_ITEM, FOUR_COLUMNS_LAYOUT_MENU_ITEM, HEADING_1_MENU_ITEM, HEADING_2_MENU_ITEM, HEADING_3_MENU_ITEM, HEADING_4_MENU_ITEM, HEADING_5_MENU_ITEM, HEADING_6_MENU_ITEM, HELP_DIALOG_MENU_ITEM, HYPERLINK_MENU_ITEM, INFO_PANEL_MENU_ITEM, JIRA_WORK_ITEMS_MENU_ITEM, LOOM_MENU_ITEM, MEDIA_INSERT_MENU_ITEM, MEDIA_SECTION, MENTION_MENU_ITEM, NOTE_PANEL_MENU_ITEM, ORDERED_LIST_MENU_ITEM, OTHER_SECTION, PLACEHOLDER_TEXT_MENU_ITEM, RECOMMENDED_SECTION, ROVO_SECTION, RULE_MENU_ITEM, STATUS_MENU_ITEM, STRUCTURE_SECTION, SUCCESS_PANEL_MENU_ITEM, SYNCED_BLOCK_MENU_ITEM, TABLE_MENU_ITEM, TEXT_FORMATTING_SECTION, THREE_COLUMNS_LAYOUT_MENU_ITEM, TWO_COLUMNS_LAYOUT_MENU_ITEM, UNORDERED_LIST_MENU_ITEM, WARNING_PANEL_MENU_ITEM } from './keys';
5
+ import { ACTION_MENU_ITEM, AI_IMAGE_GENERATION_MENU_ITEM, ASK_ROVO_MENU_ITEM, ASSETS_MENU_ITEM, BRAINSTORMING_MENU_ITEM, BLOCKQUOTE_MENU_ITEM, BLOCK_TEMPLATES_SECTION, CODE_BLOCK_MENU_ITEM, CONFLUENCE_LIST_MENU_ITEM, CONFLUENCE_PAGE_MENU_ITEM, CREATE_SECTION, CUSTOM_PANEL_MENU_ITEM, DATABASE_MENU_ITEM, DATE_MENU_ITEM, DATA_AND_CHARTS_SECTION, DECISION_MENU_ITEM, DIAGRAM_MENU_ITEM, EMBED_SECTION, EMOJI_MENU_ITEM, ERROR_PANEL_MENU_ITEM, EXPAND_MENU_ITEM, FIVE_COLUMNS_LAYOUT_MENU_ITEM, FLOWCHART_MENU_ITEM, FOUR_COLUMNS_LAYOUT_MENU_ITEM, HEADING_1_MENU_ITEM, HEADING_2_MENU_ITEM, HEADING_3_MENU_ITEM, HEADING_4_MENU_ITEM, HEADING_5_MENU_ITEM, HEADING_6_MENU_ITEM, HELP_DIALOG_MENU_ITEM, HYPERLINK_MENU_ITEM, INFO_PANEL_MENU_ITEM, JIRA_ISSUE_MENU_ITEM, JIRA_WORK_ITEMS_MENU_ITEM, LOOM_MENU_ITEM, MEDIA_INSERT_MENU_ITEM, MEDIA_SECTION, MENTION_MENU_ITEM, NOTE_PANEL_MENU_ITEM, ORDERED_LIST_MENU_ITEM, OTHER_SECTION, PLACEHOLDER_TEXT_MENU_ITEM, RECOMMENDED_SECTION, ROADMAP_MENU_ITEM, RETROSPECTIVE_MENU_ITEM, ROVO_SECTION, RULE_MENU_ITEM, STATUS_MENU_ITEM, STRUCTURE_SECTION, SUCCESS_PANEL_MENU_ITEM, SYNCED_BLOCK_MENU_ITEM, TABLE_MENU_ITEM, TEXT_FORMATTING_SECTION, THREE_COLUMNS_LAYOUT_MENU_ITEM, TWO_COLUMNS_LAYOUT_MENU_ITEM, UNORDERED_LIST_MENU_ITEM, WARNING_PANEL_MENU_ITEM, WHITEBOARD_MENU_ITEM } from './keys';
6
6
  export var QUICK_INSERT_MENU_RANK = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, RECOMMENDED_SECTION.key, 0), STRUCTURE_SECTION.key, 1), MEDIA_SECTION.key, 2), CREATE_SECTION.key, 3), EMBED_SECTION.key, 4), TEXT_FORMATTING_SECTION.key, 5), ROVO_SECTION.key, 6), DATA_AND_CHARTS_SECTION.key, 7), BLOCK_TEMPLATES_SECTION.key, 8), OTHER_SECTION.key, 9);
7
7
  export var STRUCTURE_SECTION_RANK = (_STRUCTURE_SECTION_RA = {}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_STRUCTURE_SECTION_RA, ACTION_MENU_ITEM.key, 100), TABLE_MENU_ITEM.key, 200), STATUS_MENU_ITEM.key, 300), DATE_MENU_ITEM.key, 400), MENTION_MENU_ITEM.key, 500), EXPAND_MENU_ITEM.key, 700), CODE_BLOCK_MENU_ITEM.key, 800), INFO_PANEL_MENU_ITEM.key, 900), NOTE_PANEL_MENU_ITEM.key, 1000), SUCCESS_PANEL_MENU_ITEM.key, 1100), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_STRUCTURE_SECTION_RA, WARNING_PANEL_MENU_ITEM.key, 1200), ERROR_PANEL_MENU_ITEM.key, 1300), CUSTOM_PANEL_MENU_ITEM.key, 1400), TWO_COLUMNS_LAYOUT_MENU_ITEM.key, 1500), THREE_COLUMNS_LAYOUT_MENU_ITEM.key, 1600), FOUR_COLUMNS_LAYOUT_MENU_ITEM.key, 1700), FIVE_COLUMNS_LAYOUT_MENU_ITEM.key, 1800), SYNCED_BLOCK_MENU_ITEM.key, 2300), RULE_MENU_ITEM.key, 2400), DECISION_MENU_ITEM.key, 2800));
8
- export var MEDIA_SECTION_RANK = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, MEDIA_INSERT_MENU_ITEM.key, 100), HYPERLINK_MENU_ITEM.key, 200), EMOJI_MENU_ITEM.key, 300), LOOM_MENU_ITEM.key, 400), AI_IMAGE_GENERATION_MENU_ITEM.key, 1600);
8
+ export var MEDIA_SECTION_RANK = _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, MEDIA_INSERT_MENU_ITEM.key, 100), HYPERLINK_MENU_ITEM.key, 200), EMOJI_MENU_ITEM.key, 300), AI_IMAGE_GENERATION_MENU_ITEM.key, 1600);
9
+ export var CREATE_SECTION_RANK = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, JIRA_ISSUE_MENU_ITEM.key, 100), CONFLUENCE_PAGE_MENU_ITEM.key, 200), WHITEBOARD_MENU_ITEM.key, 500), DIAGRAM_MENU_ITEM.key, 600), FLOWCHART_MENU_ITEM.key, 700), BRAINSTORMING_MENU_ITEM.key, 800), RETROSPECTIVE_MENU_ITEM.key, 900), ROADMAP_MENU_ITEM.key, 1000), DATABASE_MENU_ITEM.key, 1100), LOOM_MENU_ITEM.key, 1200);
9
10
  export var TEXT_FORMATTING_SECTION_RANK = _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, UNORDERED_LIST_MENU_ITEM.key, 100), ORDERED_LIST_MENU_ITEM.key, 200), HEADING_1_MENU_ITEM.key, 300), HEADING_2_MENU_ITEM.key, 400), HEADING_3_MENU_ITEM.key, 500), HEADING_4_MENU_ITEM.key, 600), HEADING_5_MENU_ITEM.key, 700), HEADING_6_MENU_ITEM.key, 800), BLOCKQUOTE_MENU_ITEM.key, 900), PLACEHOLDER_TEXT_MENU_ITEM.key, 1000);
10
11
  export var ROVO_SECTION_RANK = _defineProperty({}, ASK_ROVO_MENU_ITEM.key, 100);
11
12
  export var DATA_AND_CHARTS_SECTION_RANK = _defineProperty(_defineProperty(_defineProperty({}, JIRA_WORK_ITEMS_MENU_ITEM.key, 300), CONFLUENCE_LIST_MENU_ITEM.key, 400), ASSETS_MENU_ITEM.key, 500);
@@ -21,7 +21,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
21
21
  import { fg } from '@atlaskit/platform-feature-flags/fg';
22
22
  import Layer from '../Layer';
23
23
  var packageName = "@atlaskit/editor-common";
24
- var packageVersion = "126.4.3";
24
+ var packageVersion = "126.4.4";
25
25
  var halfFocusRing = 1;
26
26
  var dropOffset = '0, 8';
27
27
  var fadeIn = keyframes({
@@ -15,6 +15,7 @@ var Color = function Color(props) {
15
15
  label = props.label,
16
16
  isSelected = props.isSelected,
17
17
  borderColor = props.borderColor,
18
+ checkMarkColor = props.checkMarkColor,
18
19
  hexToPaletteColor = props.hexToPaletteColor,
19
20
  decorator = props.decorator;
20
21
  var colorStyle = hexToPaletteColor ? hexToPaletteColor(value) : value;
@@ -63,7 +64,8 @@ var Color = function Color(props) {
63
64
  },
64
65
  autoFocus: autoFocus
65
66
  }, !decorator && isSelected && jsx(EditorDoneIcon, {
66
- label: ""
67
+ label: "",
68
+ color: checkMarkColor
67
69
  }), decorator)));
68
70
  };
69
71
  export default Color;
@@ -8,6 +8,7 @@ import React from 'react';
8
8
  import { jsx } from '@emotion/react';
9
9
  import chromatism from 'chromatism';
10
10
  import { injectIntl } from 'react-intl';
11
+ import { isExperimentEnabled } from '@atlaskit/platform-feature-experiments/is-experiment-enabled';
11
12
  import { useThemeObserver } from '@atlaskit/tokens/use-theme-observer';
12
13
  import Color from './Color';
13
14
  import getColorMessage from './Palettes/getColorMessage';
@@ -55,6 +56,7 @@ var ColorPalette = function ColorPalette(props) {
55
56
  var _useThemeObserver = useThemeObserver(),
56
57
  tokenTheme = _useThemeObserver.colorMode;
57
58
  var useIconToken = !!hexToPaletteColor;
59
+ var isDividerExperimentEnabled = isExperimentEnabled('platform_editor_lovability_dividers');
58
60
  var colorsPerRow = React.useMemo(function () {
59
61
  return getColorsPerRowFromPalette(palette, cols);
60
62
  }, [palette, cols]);
@@ -90,7 +92,7 @@ var ColorPalette = function ColorPalette(props) {
90
92
  onClick: onClick,
91
93
  onKeyDown: onKeyDown,
92
94
  isSelected: value === selectedColor,
93
- checkMarkColor: getCheckMarkColor(value, useIconToken),
95
+ checkMarkColor: isDividerExperimentEnabled ? getCheckMarkColor(value, useIconToken) : undefined,
94
96
  hexToPaletteColor: hexToPaletteColor,
95
97
  decorator: decorator
96
98
  });
@@ -149,7 +149,9 @@ var ColorPickerButton = function ColorPickerButton(props) {
149
149
  createAnalyticsEvent = props.createAnalyticsEvent,
150
150
  colorPalette = props.colorPalette,
151
151
  placement = props.placement,
152
- skipFocusButtonAfterPick = props.skipFocusButtonAfterPick;
152
+ skipFocusButtonAfterPick = props.skipFocusButtonAfterPick,
153
+ _props$hideExpandIcon = props.hideExpandIcon,
154
+ hideExpandIcon = _props$hideExpandIcon === void 0 ? false : _props$hideExpandIcon;
153
155
  var onColorSelected = React.useCallback(function (color, label) {
154
156
  setIsOpenedByKeyboard(false);
155
157
  setIsPopupOpen(false);
@@ -272,7 +274,7 @@ var ColorPickerButton = function ColorPickerButton(props) {
272
274
  }, jsx("span", {
273
275
  // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
274
276
  css: buttonStyleVisualRefresh
275
- }), jsx(Box, {
277
+ }), !hideExpandIcon && jsx(Box, {
276
278
  xcss: colorPickerExpandContainerVisualRefresh
277
279
  }, jsx(ChevronDownIcon, {
278
280
  color: "currentColor",
@@ -27,10 +27,10 @@ type SuggestionRemixAttributes = {
27
27
  remixSubtype?: string;
28
28
  remixType?: string;
29
29
  };
30
- type SuggestionAgeAttribute = {
31
- suggestionAgeMs?: number;
30
+ type TimeSinceGenerationAttribute = {
31
+ timeSinceGenerationMs?: number;
32
32
  };
33
- type RegenerationSuggestionDetails = SuggestionRemixAttributes & SuggestionAgeAttribute & {
33
+ type RegenerationSuggestionDetails = SuggestionRemixAttributes & TimeSinceGenerationAttribute & {
34
34
  actionKind: string;
35
35
  outcome?: AiSuggestionsRegenerationOutcome;
36
36
  suggestionId: string;
@@ -79,7 +79,7 @@ type SuggestionsErrorRetryClickedAEP = TrackAEP<ACTION.CLICKED, ACTION_SUBJECT.A
79
79
  type EntryPointExposureAEP = TrackAEP<ACTION.EXPOSED, ACTION_SUBJECT.AI_SUGGESTIONS, undefined, {
80
80
  entryPoint: AiSuggestionsEntryPoint;
81
81
  }, undefined>;
82
- type SuggestionLifecycleAttributes = SuggestionRemixAttributes & SuggestionAgeAttribute & {
82
+ type SuggestionLifecycleAttributes = SuggestionRemixAttributes & TimeSinceGenerationAttribute & {
83
83
  actionKind: string;
84
84
  affectedBlocks: number;
85
85
  agentId?: string;
@@ -93,6 +93,11 @@ type AcceptSuggestionAEP = TrackAEP<ACTION.ACCEPTED, ACTION_SUBJECT.AI_SUGGESTIO
93
93
  charactersRemoved?: number;
94
94
  isDiffHidden: boolean;
95
95
  }, undefined>;
96
+ type UndoAcceptedSuggestionAEP = TrackAEP<ACTION.UNDO_PERFORMED, ACTION_SUBJECT.AI_SUGGESTIONS, undefined, TimeSinceGenerationAttribute & {
97
+ actionKind: string;
98
+ suggestionId: string;
99
+ suggestionType: string;
100
+ }, undefined>;
96
101
  type DiscardedSuggestionAttributes = SuggestionLifecycleAttributes;
97
102
  type CancelSuggestionsAEP = TrackAEP<ACTION.CANCELLED, ACTION_SUBJECT.AI_SUGGESTIONS, undefined, {
98
103
  interactionPoint: AiSuggestionInteractionPoint;
@@ -112,14 +117,14 @@ type ViewSuggestionAEP = TrackAEP<ACTION.VIEWED, ACTION_SUBJECT.AI_SUGGESTIONS,
112
117
  type RightRailViewedAEP = TrackAEP<ACTION.RIGHT_RAIL_VIEWED, ACTION_SUBJECT.AI_SUGGESTIONS, undefined, {
113
118
  entryPoint: AiSuggestionsRightRailEntryPoint;
114
119
  numberOfSuggestions: number;
115
- suggestionDetails: Array<SuggestionRemixAttributes & SuggestionAgeAttribute & {
120
+ suggestionDetails: Array<SuggestionRemixAttributes & TimeSinceGenerationAttribute & {
116
121
  actionKind: string;
117
122
  affectedBlocks: number;
118
123
  suggestionType: string;
119
124
  }>;
120
125
  }, undefined>;
121
126
  type RightRailClosedAEP = TrackAEP<ACTION.RIGHT_RAIL_CLOSED, ACTION_SUBJECT.AI_SUGGESTIONS, undefined, undefined, undefined>;
122
- type ViewSuggestionReasoningAEP = TrackAEP<ACTION.REASONING_VIEWED, ACTION_SUBJECT.AI_SUGGESTIONS, undefined, SuggestionRemixAttributes & SuggestionAgeAttribute & {
127
+ type ViewSuggestionReasoningAEP = TrackAEP<ACTION.REASONING_VIEWED, ACTION_SUBJECT.AI_SUGGESTIONS, undefined, SuggestionRemixAttributes & TimeSinceGenerationAttribute & {
123
128
  actionKind: string;
124
129
  affectedBlocks: number;
125
130
  agentId?: string;
@@ -145,5 +150,5 @@ type SuggestionsGeneratedAEP = TrackAEP<ACTION.GENERATED, ACTION_SUBJECT.AI_SUGG
145
150
  type EmptyStateExposedAEP = TrackAEP<ACTION.EMPTY_STATE_EXPOSED, ACTION_SUBJECT.AI_SUGGESTIONS, undefined, {
146
151
  emptyStateType: AiSuggestionsEmptyStateType;
147
152
  }, undefined>;
148
- export type AiSuggestionsEventPayload = NoDiffSuggestionAEP | ConversationErrorAEP | RegenerateSuggestionsErrorAEP | RegenerateSuggestionsStartedAEP | RegenerateSuggestionsCompletedAEP | EntryPointClickedAEP | SuggestionsErrorRetryClickedAEP | EntryPointExposureAEP | CancelSuggestionsAEP | AcceptSuggestionAEP | DiscardSuggestionAEP | DiscardAllSuggestionsAEP | DismissSuggestionAEP | ViewSuggestionAEP | RightRailViewedAEP | RightRailClosedAEP | ViewSuggestionReasoningAEP | SuggestionsGeneratedAEP | EmptyStateExposedAEP;
153
+ export type AiSuggestionsEventPayload = NoDiffSuggestionAEP | ConversationErrorAEP | RegenerateSuggestionsErrorAEP | RegenerateSuggestionsStartedAEP | RegenerateSuggestionsCompletedAEP | EntryPointClickedAEP | SuggestionsErrorRetryClickedAEP | EntryPointExposureAEP | CancelSuggestionsAEP | AcceptSuggestionAEP | UndoAcceptedSuggestionAEP | DiscardSuggestionAEP | DiscardAllSuggestionsAEP | DismissSuggestionAEP | ViewSuggestionAEP | RightRailViewedAEP | RightRailClosedAEP | ViewSuggestionReasoningAEP | SuggestionsGeneratedAEP | EmptyStateExposedAEP;
149
154
  export {};
@@ -110,6 +110,10 @@ type UpdatedDividerAEP = TrackAEP<ACTION.UPDATED, ACTION_SUBJECT.DIVIDER, undefi
110
110
  inputMethod: INPUT_METHOD.FLOATING_TB;
111
111
  previousWeight: number;
112
112
  weight: number;
113
+ } | {
114
+ color: string | null;
115
+ inputMethod: INPUT_METHOD.FLOATING_TB;
116
+ previousColor: string | null;
113
117
  }, undefined>;
114
118
  type UnsupportedContentAEP = TrackAEP<ACTION.UNSUPPORTED_CONTENT_ENCOUNTERED, ACTION_SUBJECT.DOCUMENT, ACTION_SUBJECT_ID.UNSUPPORTED_BLOCK | ACTION_SUBJECT_ID.UNSUPPORTED_INLINE | ACTION_SUBJECT_ID.UNSUPPORTED_MARK, {
115
119
  unsupportedNode: {
@@ -1,9 +1,29 @@
1
1
  export declare const ruleMessages: {
2
+ boldGrayDividerColor: {
3
+ defaultMessage: string;
4
+ description: string;
5
+ id: string;
6
+ };
7
+ customDividerColor: {
8
+ defaultMessage: string;
9
+ description: string;
10
+ id: string;
11
+ };
2
12
  dashedDivider: {
3
13
  defaultMessage: string;
4
14
  description: string;
5
15
  id: string;
6
16
  };
17
+ defaultDividerColor: {
18
+ defaultMessage: string;
19
+ description: string;
20
+ id: string;
21
+ };
22
+ dividerColors: {
23
+ defaultMessage: string;
24
+ description: string;
25
+ id: string;
26
+ };
7
27
  dividerFloatingControls: {
8
28
  defaultMessage: string;
9
29
  description: string;
@@ -130,6 +130,42 @@ export declare const LOOM_MENU_ITEM: {
130
130
  readonly key: 'quick-insert-loom-menu-item';
131
131
  readonly type: 'menu-item';
132
132
  };
133
+ export declare const JIRA_ISSUE_MENU_ITEM: {
134
+ readonly key: 'com.atlassian.linking-platform.create:linking-platform-create-jira-issue';
135
+ readonly type: 'menu-item';
136
+ };
137
+ export declare const CONFLUENCE_PAGE_MENU_ITEM: {
138
+ readonly key: 'com.atlassian.linking-platform.create:linking-platform-create-confluence-page';
139
+ readonly type: 'menu-item';
140
+ };
141
+ export declare const WHITEBOARD_MENU_ITEM: {
142
+ readonly key: 'whiteboard-extension:create-whiteboard';
143
+ readonly type: 'menu-item';
144
+ };
145
+ export declare const DIAGRAM_MENU_ITEM: {
146
+ readonly key: 'whiteboard-extension:create-diagram';
147
+ readonly type: 'menu-item';
148
+ };
149
+ export declare const FLOWCHART_MENU_ITEM: {
150
+ readonly key: 'whiteboard-extension:create-flowchart';
151
+ readonly type: 'menu-item';
152
+ };
153
+ export declare const BRAINSTORMING_MENU_ITEM: {
154
+ readonly key: 'whiteboard-extension:create-brainstorming';
155
+ readonly type: 'menu-item';
156
+ };
157
+ export declare const RETROSPECTIVE_MENU_ITEM: {
158
+ readonly key: 'whiteboard-extension:create-retrospective';
159
+ readonly type: 'menu-item';
160
+ };
161
+ export declare const ROADMAP_MENU_ITEM: {
162
+ readonly key: 'whiteboard-extension:create-roadmap';
163
+ readonly type: 'menu-item';
164
+ };
165
+ export declare const DATABASE_MENU_ITEM: {
166
+ readonly key: 'database-extension:create-database';
167
+ readonly type: 'menu-item';
168
+ };
133
169
  export declare const MENTION_MENU_ITEM: {
134
170
  readonly key: 'quick-insert-mention-menu-item';
135
171
  readonly type: 'menu-item';
@@ -1,6 +1,7 @@
1
1
  export declare const QUICK_INSERT_MENU_RANK: Readonly<Record<string, number>>;
2
2
  export declare const STRUCTURE_SECTION_RANK: Readonly<Record<string, number>>;
3
3
  export declare const MEDIA_SECTION_RANK: Readonly<Record<string, number>>;
4
+ export declare const CREATE_SECTION_RANK: Readonly<Record<string, number>>;
4
5
  export declare const TEXT_FORMATTING_SECTION_RANK: Readonly<Record<string, number>>;
5
6
  export declare const ROVO_SECTION_RANK: Readonly<Record<string, number>>;
6
7
  export declare const DATA_AND_CHARTS_SECTION_RANK: Readonly<Record<string, number>>;
@@ -8,7 +8,7 @@ import type { TooltipProps } from '@atlaskit/tooltip/types';
8
8
  import type { DispatchAnalyticsEvent } from '../analytics/types/dispatch-analytics-event';
9
9
  import type { DropdownMenuItemProps } from '../floating-toolbar';
10
10
  import type { ProviderFactory } from '../provider-factory';
11
- import type { PaletteColor } from '../ui-color/ColorPalette/Palettes/type';
11
+ import type { PaletteColor, PaletteTooltipMessages } from '../ui-color/ColorPalette/Palettes/type';
12
12
  import type { Command, CommandDispatch } from './command';
13
13
  import type { MarkOptions, NodeOptions } from './copy-button';
14
14
  /**
@@ -18,17 +18,17 @@ export type OverflowDropdownHeading = {
18
18
  title: string;
19
19
  type: 'overflow-dropdown-heading';
20
20
  };
21
- type OverflowDropdownCustom<T extends Object> = {
21
+ type OverflowDropdownCustom<T extends object> = {
22
22
  fallback: Array<FloatingToolbarFallbackItem<T>>;
23
23
  hidden?: boolean;
24
24
  render: (view?: EditorView, dropdownOption?: Omit<DropdownMenuItemProps, 'item'>) => React.ReactNode;
25
25
  type: 'custom';
26
26
  };
27
- export type OverflowDropdownOption<T extends Object> = DropdownOptionT<T> & {
27
+ export type OverflowDropdownOption<T extends object> = DropdownOptionT<T> & {
28
28
  rank?: number;
29
29
  };
30
- export type FloatingToolbarOverflowDropdownOptions<T extends Object> = Array<OverflowDropdownOption<T> | FloatingToolbarSeparator | OverflowDropdownHeading | OverflowDropdownCustom<T>>;
31
- export type FloatingToolbarOverflowDropdown<T extends Object> = {
30
+ export type FloatingToolbarOverflowDropdownOptions<T extends object> = Array<OverflowDropdownOption<T> | FloatingToolbarSeparator | OverflowDropdownHeading | OverflowDropdownCustom<T>>;
31
+ export type FloatingToolbarOverflowDropdown<T extends object> = {
32
32
  alignDropdownWithToolbar?: boolean;
33
33
  disabled?: boolean;
34
34
  dropdownWidth?: number;
@@ -42,11 +42,11 @@ export type FloatingToolbarOverflowDropdown<T extends Object> = {
42
42
  tooltip?: string;
43
43
  type: 'overflow-dropdown';
44
44
  };
45
- export interface RenderOptionsPropsT<T extends Object> {
45
+ export interface RenderOptionsPropsT<T extends object> {
46
46
  dispatchCommand: (command: T) => void;
47
47
  hide: () => void;
48
48
  }
49
- export interface DropdownOptionT<T extends Object> {
49
+ export interface DropdownOptionT<T extends object> {
50
50
  confirmDialog?: ConfirmDialogOptions | (() => ConfirmDialogOptions);
51
51
  description?: string;
52
52
  disabled?: boolean;
@@ -75,12 +75,12 @@ export type typeOption =
75
75
  * @default 'item'
76
76
  */
77
77
  'item' | 'item-checkbox';
78
- export type DropdownOptions<T extends Object> = Array<DropdownOptionT<T>> | {
78
+ export type DropdownOptions<T extends object> = Array<DropdownOptionT<T>> | {
79
79
  height: number;
80
80
  render: (props: RenderOptionsPropsT<T>) => React.ReactElement<any> | null;
81
81
  width: number;
82
82
  };
83
- export interface SelectOption<T extends Object = Object> {
83
+ export interface SelectOption<T extends object = object> {
84
84
  data?: T;
85
85
  disabled?: boolean;
86
86
  hidden?: boolean;
@@ -134,7 +134,7 @@ export type FloatingToolbarCopyButton = {
134
134
  supportsViewMode?: boolean;
135
135
  type: 'copy-button';
136
136
  };
137
- export type FloatingToolbarButton<T extends Object> = {
137
+ export type FloatingToolbarButton<T extends object> = {
138
138
  appearance?: ButtonAppearance;
139
139
  ariaHasPopup?: boolean | 'dialog' | 'menu' | 'listbox' | 'tree' | 'grid' | undefined;
140
140
  ariaLabel?: string;
@@ -173,7 +173,7 @@ export type FloatingToolbarButton<T extends Object> = {
173
173
  tooltipContent?: TooltipProps['content'];
174
174
  type: 'button';
175
175
  };
176
- export type FloatingToolbarInput<T extends Object> = {
176
+ export type FloatingToolbarInput<T extends object> = {
177
177
  defaultValue?: string;
178
178
  description?: string;
179
179
  hidden?: boolean;
@@ -214,7 +214,7 @@ export type FloatingToolbarCustomRenderContext = {
214
214
  */
215
215
  setDisableParentScroll?: (disabled: boolean) => void;
216
216
  };
217
- export type FloatingToolbarCustom<T extends Object> = {
217
+ export type FloatingToolbarCustom<T extends object> = {
218
218
  /**
219
219
  * By default -- the floating toolbar supports navigating between
220
220
  * items using arrow keys (to meet aria guidelines).
@@ -232,7 +232,7 @@ export type FloatingToolbarCustom<T extends Object> = {
232
232
  supportsViewMode?: boolean;
233
233
  type: 'custom';
234
234
  };
235
- type FloatingToolbarSelectBase<T extends Object, V = SelectOption> = {
235
+ type FloatingToolbarSelectBase<T extends object, V = SelectOption> = {
236
236
  defaultValue?: V | null;
237
237
  filterOption?: ((option: V, rawInput: string) => boolean) | null;
238
238
  hidden?: boolean;
@@ -247,23 +247,25 @@ type FloatingToolbarSelectBase<T extends Object, V = SelectOption> = {
247
247
  title?: string;
248
248
  type: 'select';
249
249
  };
250
- export type FloatingToolbarListPicker<T extends Object> = FloatingToolbarSelectBase<T> & {
250
+ export type FloatingToolbarListPicker<T extends object> = FloatingToolbarSelectBase<T> & {
251
251
  selectType: 'list';
252
252
  };
253
- export type FloatingToolbarColorPicker<T extends Object> = FloatingToolbarSelectBase<T, PaletteColor> & {
253
+ export type FloatingToolbarColorPicker<T extends object> = FloatingToolbarSelectBase<T, PaletteColor> & {
254
254
  cols?: number;
255
+ hexToPaletteColor?: (hexColor: string) => string | undefined;
256
+ paletteColorTooltipMessages?: PaletteTooltipMessages;
255
257
  selectType: 'color';
256
258
  };
257
- export type FloatingToolbarEmojiPicker<T extends Object> = FloatingToolbarSelectBase<T, EmojiId> & {
259
+ export type FloatingToolbarEmojiPicker<T extends object> = FloatingToolbarSelectBase<T, EmojiId> & {
258
260
  options: never[];
259
261
  selected?: boolean;
260
262
  selectType: 'emoji';
261
263
  };
262
- export type FloatingToolbarDatePicker<T extends Object> = FloatingToolbarSelectBase<T, number> & {
264
+ export type FloatingToolbarDatePicker<T extends object> = FloatingToolbarSelectBase<T, number> & {
263
265
  options: never[];
264
266
  selectType: 'date';
265
267
  };
266
- export type FloatingToolbarSelect<T extends Object> = FloatingToolbarEmojiPicker<T> | FloatingToolbarColorPicker<T> | FloatingToolbarListPicker<T> | FloatingToolbarDatePicker<T>;
268
+ export type FloatingToolbarSelect<T extends object> = FloatingToolbarEmojiPicker<T> | FloatingToolbarColorPicker<T> | FloatingToolbarListPicker<T> | FloatingToolbarDatePicker<T>;
267
269
  export type FloatingToolbarSeparator = {
268
270
  fullHeight?: boolean;
269
271
  hidden?: boolean;
@@ -271,7 +273,7 @@ export type FloatingToolbarSeparator = {
271
273
  type: 'separator';
272
274
  };
273
275
  export type ExtensionDropdownOptions = () => DropdownOptions<Function>;
274
- export type FloatingToolbarDropdown<T extends Object> = {
276
+ export type FloatingToolbarDropdown<T extends object> = {
275
277
  alignDropdownWithToolbar?: boolean;
276
278
  disabled?: boolean;
277
279
  dropdownWidth?: number;
@@ -311,8 +313,8 @@ type FloatingToolbarExtensionsPlaceholder = {
311
313
  * This type is restricted with the items that can be used for fallback.
312
314
  * Make sure that this type is not a FloatingToolbarCustom type.
313
315
  */
314
- export type FloatingToolbarFallbackItem<T extends Object> = FloatingToolbarButton<T> | FloatingToolbarCopyButton | FloatingToolbarDropdown<T> | FloatingToolbarSelect<T> | FloatingToolbarInput<T> | FloatingToolbarSeparator;
315
- export type FloatingToolbarItem<T extends Object> = FloatingToolbarButton<T> | FloatingToolbarCopyButton | FloatingToolbarDropdown<T> | FloatingToolbarSelect<T> | FloatingToolbarInput<T> | FloatingToolbarCustom<T> | FloatingToolbarSeparator | FloatingToolbarExtensionsPlaceholder | FloatingToolbarOverflowDropdown<T>;
316
+ export type FloatingToolbarFallbackItem<T extends object> = FloatingToolbarButton<T> | FloatingToolbarCopyButton | FloatingToolbarDropdown<T> | FloatingToolbarSelect<T> | FloatingToolbarInput<T> | FloatingToolbarSeparator;
317
+ export type FloatingToolbarItem<T extends object> = FloatingToolbarButton<T> | FloatingToolbarCopyButton | FloatingToolbarDropdown<T> | FloatingToolbarSelect<T> | FloatingToolbarInput<T> | FloatingToolbarCustom<T> | FloatingToolbarSeparator | FloatingToolbarExtensionsPlaceholder | FloatingToolbarOverflowDropdown<T>;
316
318
  export interface FloatingToolbarConfig {
317
319
  /**
318
320
  * @deprecated To suppress visibility of toolbars, set user intent state in userIntentPlugin instead.
@@ -14,6 +14,7 @@ declare const _default_1: React.ForwardRefExoticComponent<Omit<Omit<{
14
14
  cols?: number;
15
15
  currentColor?: string;
16
16
  hexToPaletteColor?: (hexColor: string) => string | undefined;
17
+ hideExpandIcon?: boolean;
17
18
  isAriaExpanded?: boolean;
18
19
  mountPoint?: HTMLElement;
19
20
  onChange?: (color: PaletteColor) => void;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/editor-common",
3
- "version": "126.4.4",
3
+ "version": "127.0.0",
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/"
@@ -54,8 +54,8 @@
54
54
  "@atlaskit/feature-gate-js-client": "^7.0.0",
55
55
  "@atlaskit/icon": "^38.0.0",
56
56
  "@atlaskit/link": "^5.1.0",
57
- "@atlaskit/link-datasource": "^7.0.0",
58
- "@atlaskit/link-picker": "^6.9.0",
57
+ "@atlaskit/link-datasource": "^7.1.0",
58
+ "@atlaskit/link-picker": "^6.10.0",
59
59
  "@atlaskit/logo": "^23.3.0",
60
60
  "@atlaskit/media-card": "^82.1.0",
61
61
  "@atlaskit/media-client": "^39.0.0",
@@ -79,13 +79,13 @@
79
79
  "@atlaskit/react-compiler-gating": "^0.2.0",
80
80
  "@atlaskit/react-ufo": "^8.0.0",
81
81
  "@atlaskit/section-message": "^10.2.0",
82
- "@atlaskit/smart-card": "^46.1.0",
83
- "@atlaskit/smart-user-picker": "^12.0.0",
82
+ "@atlaskit/smart-card": "^46.2.0",
83
+ "@atlaskit/smart-user-picker": "^12.1.0",
84
84
  "@atlaskit/spinner": "^20.4.0",
85
85
  "@atlaskit/task-decision": "^21.11.0",
86
86
  "@atlaskit/teams-app-config": "^3.1.0",
87
87
  "@atlaskit/textfield": "^10.2.0",
88
- "@atlaskit/tmp-editor-statsig": "^218.0.0",
88
+ "@atlaskit/tmp-editor-statsig": "^219.0.0",
89
89
  "@atlaskit/tokens": "^20.1.0",
90
90
  "@atlaskit/tooltip": "^24.3.0",
91
91
  "@atlaskit/width-detector": "^7.2.0",