@atlaskit/editor-common 92.1.1 → 93.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 (198) hide show
  1. package/CHANGELOG.md +35 -0
  2. package/afm-cc/tsconfig.json +0 -3
  3. package/afm-jira/tsconfig.json +0 -3
  4. package/afm-post-office/tsconfig.json +0 -3
  5. package/dist/cjs/element-browser/components/CategoryList.js +2 -3
  6. package/dist/cjs/element-browser/components/ElementList/ElementList.js +11 -13
  7. package/dist/cjs/element-browser/components/ElementSearch.js +1 -2
  8. package/dist/cjs/element-browser/constants.js +1 -6
  9. package/dist/cjs/extensibility/Extension/Extension/styles.js +3 -4
  10. package/dist/cjs/extensibility/Extension/InlineExtension/styles.js +1 -2
  11. package/dist/cjs/extensibility/Extension/Lozenge/ExtensionLabel.js +6 -7
  12. package/dist/cjs/extensibility/Extension/styles.js +3 -4
  13. package/dist/cjs/extensibility/MultiBodiedExtension/styles.js +2 -3
  14. package/dist/cjs/icons/shared/SteppedRainbowIconDecoration.js +2 -3
  15. package/dist/cjs/keymaps/index.js +1 -2
  16. package/dist/cjs/link/ConfigureLinkOverlay/StyledButton.js +4 -5
  17. package/dist/cjs/link/ConfigureLinkOverlay/index.js +2 -4
  18. package/dist/cjs/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +1 -2
  19. package/dist/cjs/link/LinkSearch/LinkSearchList.js +1 -2
  20. package/dist/cjs/link/LinkSearch/LinkSearchListItem.js +4 -6
  21. package/dist/cjs/media-inline/constants.js +10 -8
  22. package/dist/cjs/media-inline/styles.js +1 -2
  23. package/dist/cjs/media-inline/views/error-view.js +1 -2
  24. package/dist/cjs/media-inline/views/wrapper.js +3 -4
  25. package/dist/cjs/media-single/CommentBadge.js +1 -2
  26. package/dist/cjs/monitoring/error.js +1 -1
  27. package/dist/cjs/node-width/index.js +5 -10
  28. package/dist/cjs/panel.js +0 -12
  29. package/dist/cjs/react-node-view/index.js +32 -37
  30. package/dist/cjs/styles/shared/annotation.js +11 -14
  31. package/dist/cjs/styles/shared/code-block.js +2 -4
  32. package/dist/cjs/styles/shared/code-mark.js +1 -2
  33. package/dist/cjs/styles/shared/grid.js +2 -3
  34. package/dist/cjs/styles/shared/headings.js +56 -17
  35. package/dist/cjs/styles/shared/panel.js +13 -34
  36. package/dist/cjs/styles/shared/plugins.js +1 -2
  37. package/dist/cjs/styles/shared/resizer.js +1 -2
  38. package/dist/cjs/styles/shared/rule.js +1 -2
  39. package/dist/cjs/styles/shared/shadow.js +2 -3
  40. package/dist/cjs/styles/shared/smartCard.js +2 -3
  41. package/dist/cjs/table/SortingIcon.js +1 -2
  42. package/dist/cjs/ui/BaseTheme/index.js +1 -2
  43. package/dist/cjs/ui/Caption/index.js +2 -3
  44. package/dist/cjs/ui/DropList/index.js +4 -5
  45. package/dist/cjs/ui/Expand/index.js +2 -3
  46. package/dist/cjs/ui/Expand/sharedStyles.js +7 -17
  47. package/dist/cjs/ui/FloatingToolbar/Separator.js +1 -2
  48. package/dist/cjs/ui/FloatingToolbar/styles.js +10 -12
  49. package/dist/cjs/ui/Messages/index.js +8 -6
  50. package/dist/cjs/ui/PanelTextInput/styles.js +4 -5
  51. package/dist/cjs/ui/UnsupportedBlock/index.js +4 -6
  52. package/dist/cjs/ui/UnsupportedInline/index.js +4 -6
  53. package/dist/cjs/ui/WidthProvider/index.js +5 -39
  54. package/dist/cjs/ui-color/ColorPalette/Color/index.js +1 -2
  55. package/dist/cjs/ui-color/ColorPalette/Color/styles.js +3 -4
  56. package/dist/cjs/ui-color/ColorPalette/Palettes/common.js +1 -2
  57. package/dist/cjs/ui-color/ColorPalette/Palettes/panelBackgroundPalette.js +22 -24
  58. package/dist/cjs/ui-color/ColorPalette/index.js +2 -3
  59. package/dist/cjs/ui-color/index.js +0 -13
  60. package/dist/cjs/ui-menu/ColorPickerButton/index.js +3 -4
  61. package/dist/cjs/ui-menu/DropdownMenu/index.js +2 -3
  62. package/dist/es2019/element-browser/components/CategoryList.js +2 -3
  63. package/dist/es2019/element-browser/components/ElementList/ElementList.js +3 -5
  64. package/dist/es2019/element-browser/components/ElementSearch.js +1 -2
  65. package/dist/es2019/element-browser/constants.js +1 -5
  66. package/dist/es2019/extensibility/Extension/Extension/styles.js +3 -4
  67. package/dist/es2019/extensibility/Extension/InlineExtension/styles.js +1 -2
  68. package/dist/es2019/extensibility/Extension/Lozenge/ExtensionLabel.js +6 -7
  69. package/dist/es2019/extensibility/Extension/styles.js +3 -4
  70. package/dist/es2019/extensibility/MultiBodiedExtension/styles.js +2 -3
  71. package/dist/es2019/icons/shared/SteppedRainbowIconDecoration.js +2 -3
  72. package/dist/es2019/keymaps/index.js +1 -2
  73. package/dist/es2019/link/ConfigureLinkOverlay/StyledButton.js +4 -5
  74. package/dist/es2019/link/ConfigureLinkOverlay/index.js +2 -4
  75. package/dist/es2019/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +1 -2
  76. package/dist/es2019/link/LinkSearch/LinkSearchList.js +1 -2
  77. package/dist/es2019/link/LinkSearch/LinkSearchListItem.js +4 -6
  78. package/dist/es2019/media-inline/constants.js +10 -8
  79. package/dist/es2019/media-inline/styles.js +1 -2
  80. package/dist/es2019/media-inline/views/error-view.js +1 -2
  81. package/dist/es2019/media-inline/views/wrapper.js +3 -4
  82. package/dist/es2019/media-single/CommentBadge.js +1 -2
  83. package/dist/es2019/monitoring/error.js +1 -1
  84. package/dist/es2019/node-width/index.js +5 -9
  85. package/dist/es2019/panel.js +1 -1
  86. package/dist/es2019/react-node-view/index.js +32 -37
  87. package/dist/es2019/styles/shared/annotation.js +11 -14
  88. package/dist/es2019/styles/shared/code-block.js +12 -14
  89. package/dist/es2019/styles/shared/code-mark.js +1 -2
  90. package/dist/es2019/styles/shared/grid.js +2 -3
  91. package/dist/es2019/styles/shared/headings.js +35 -8
  92. package/dist/es2019/styles/shared/panel.js +12 -25
  93. package/dist/es2019/styles/shared/plugins.js +1 -2
  94. package/dist/es2019/styles/shared/resizer.js +6 -7
  95. package/dist/es2019/styles/shared/rule.js +1 -2
  96. package/dist/es2019/styles/shared/shadow.js +2 -3
  97. package/dist/es2019/styles/shared/smartCard.js +5 -7
  98. package/dist/es2019/table/SortingIcon.js +2 -3
  99. package/dist/es2019/ui/BaseTheme/index.js +1 -2
  100. package/dist/es2019/ui/Caption/index.js +2 -3
  101. package/dist/es2019/ui/DropList/index.js +4 -5
  102. package/dist/es2019/ui/Expand/index.js +2 -3
  103. package/dist/es2019/ui/Expand/sharedStyles.js +7 -17
  104. package/dist/es2019/ui/FloatingToolbar/Separator.js +1 -2
  105. package/dist/es2019/ui/FloatingToolbar/styles.js +10 -12
  106. package/dist/es2019/ui/Messages/index.js +8 -6
  107. package/dist/es2019/ui/PanelTextInput/styles.js +4 -5
  108. package/dist/es2019/ui/UnsupportedBlock/index.js +4 -6
  109. package/dist/es2019/ui/UnsupportedInline/index.js +4 -6
  110. package/dist/es2019/ui/WidthProvider/index.js +2 -33
  111. package/dist/es2019/ui-color/ColorPalette/Color/index.js +1 -4
  112. package/dist/es2019/ui-color/ColorPalette/Color/styles.js +3 -4
  113. package/dist/es2019/ui-color/ColorPalette/Palettes/common.js +1 -2
  114. package/dist/es2019/ui-color/ColorPalette/Palettes/panelBackgroundPalette.js +21 -24
  115. package/dist/es2019/ui-color/ColorPalette/index.js +2 -3
  116. package/dist/es2019/ui-color/index.js +0 -1
  117. package/dist/es2019/ui-menu/ColorPickerButton/index.js +3 -4
  118. package/dist/es2019/ui-menu/DropdownMenu/index.js +3 -4
  119. package/dist/esm/element-browser/components/CategoryList.js +2 -3
  120. package/dist/esm/element-browser/components/ElementList/ElementList.js +3 -5
  121. package/dist/esm/element-browser/components/ElementSearch.js +1 -2
  122. package/dist/esm/element-browser/constants.js +1 -5
  123. package/dist/esm/extensibility/Extension/Extension/styles.js +3 -4
  124. package/dist/esm/extensibility/Extension/InlineExtension/styles.js +1 -2
  125. package/dist/esm/extensibility/Extension/Lozenge/ExtensionLabel.js +6 -7
  126. package/dist/esm/extensibility/Extension/styles.js +3 -4
  127. package/dist/esm/extensibility/MultiBodiedExtension/styles.js +2 -3
  128. package/dist/esm/icons/shared/SteppedRainbowIconDecoration.js +2 -3
  129. package/dist/esm/keymaps/index.js +1 -2
  130. package/dist/esm/link/ConfigureLinkOverlay/StyledButton.js +4 -5
  131. package/dist/esm/link/ConfigureLinkOverlay/index.js +2 -4
  132. package/dist/esm/link/LinkPicker/HyperlinkAddToolbar/HyperlinkAddToolbar.js +1 -2
  133. package/dist/esm/link/LinkSearch/LinkSearchList.js +1 -2
  134. package/dist/esm/link/LinkSearch/LinkSearchListItem.js +4 -6
  135. package/dist/esm/media-inline/constants.js +10 -8
  136. package/dist/esm/media-inline/styles.js +1 -2
  137. package/dist/esm/media-inline/views/error-view.js +1 -2
  138. package/dist/esm/media-inline/views/wrapper.js +3 -4
  139. package/dist/esm/media-single/CommentBadge.js +1 -2
  140. package/dist/esm/monitoring/error.js +1 -1
  141. package/dist/esm/node-width/index.js +5 -9
  142. package/dist/esm/panel.js +1 -1
  143. package/dist/esm/react-node-view/index.js +32 -37
  144. package/dist/esm/styles/shared/annotation.js +11 -14
  145. package/dist/esm/styles/shared/code-block.js +2 -4
  146. package/dist/esm/styles/shared/code-mark.js +1 -2
  147. package/dist/esm/styles/shared/grid.js +2 -3
  148. package/dist/esm/styles/shared/headings.js +53 -17
  149. package/dist/esm/styles/shared/panel.js +12 -33
  150. package/dist/esm/styles/shared/plugins.js +1 -2
  151. package/dist/esm/styles/shared/resizer.js +1 -2
  152. package/dist/esm/styles/shared/rule.js +1 -2
  153. package/dist/esm/styles/shared/shadow.js +2 -3
  154. package/dist/esm/styles/shared/smartCard.js +2 -4
  155. package/dist/esm/table/SortingIcon.js +1 -2
  156. package/dist/esm/ui/BaseTheme/index.js +1 -2
  157. package/dist/esm/ui/Caption/index.js +2 -3
  158. package/dist/esm/ui/DropList/index.js +4 -5
  159. package/dist/esm/ui/Expand/index.js +2 -3
  160. package/dist/esm/ui/Expand/sharedStyles.js +7 -17
  161. package/dist/esm/ui/FloatingToolbar/Separator.js +1 -2
  162. package/dist/esm/ui/FloatingToolbar/styles.js +10 -12
  163. package/dist/esm/ui/Messages/index.js +8 -6
  164. package/dist/esm/ui/PanelTextInput/styles.js +4 -5
  165. package/dist/esm/ui/UnsupportedBlock/index.js +4 -6
  166. package/dist/esm/ui/UnsupportedInline/index.js +4 -6
  167. package/dist/esm/ui/WidthProvider/index.js +5 -39
  168. package/dist/esm/ui-color/ColorPalette/Color/index.js +1 -2
  169. package/dist/esm/ui-color/ColorPalette/Color/styles.js +3 -4
  170. package/dist/esm/ui-color/ColorPalette/Palettes/common.js +1 -2
  171. package/dist/esm/ui-color/ColorPalette/Palettes/panelBackgroundPalette.js +21 -24
  172. package/dist/esm/ui-color/ColorPalette/index.js +2 -3
  173. package/dist/esm/ui-color/index.js +0 -1
  174. package/dist/esm/ui-menu/ColorPickerButton/index.js +3 -4
  175. package/dist/esm/ui-menu/DropdownMenu/index.js +2 -3
  176. package/dist/types/element-browser/constants.d.ts +3 -3
  177. package/dist/types/media-inline/constants.d.ts +3 -0
  178. package/dist/types/panel.d.ts +1 -1
  179. package/dist/types/styles/shared/panel.d.ts +0 -2
  180. package/dist/types/ui/WidthProvider/index.d.ts +0 -5
  181. package/dist/types/ui-color/index.d.ts +0 -1
  182. package/dist/types-ts4.5/element-browser/constants.d.ts +3 -3
  183. package/dist/types-ts4.5/media-inline/constants.d.ts +3 -0
  184. package/dist/types-ts4.5/panel.d.ts +1 -1
  185. package/dist/types-ts4.5/styles/shared/panel.d.ts +0 -2
  186. package/dist/types-ts4.5/ui/WidthProvider/index.d.ts +0 -5
  187. package/dist/types-ts4.5/ui-color/index.d.ts +0 -1
  188. package/package.json +4 -11
  189. package/dist/cjs/ui/WidthProvider/isSsrButNoBreakoutScriptObserved.js +0 -11
  190. package/dist/cjs/ui-color/ColorPalette/Palettes/statusColorPalette.js +0 -60
  191. package/dist/es2019/ui/WidthProvider/isSsrButNoBreakoutScriptObserved.js +0 -6
  192. package/dist/es2019/ui-color/ColorPalette/Palettes/statusColorPalette.js +0 -54
  193. package/dist/esm/ui/WidthProvider/isSsrButNoBreakoutScriptObserved.js +0 -6
  194. package/dist/esm/ui-color/ColorPalette/Palettes/statusColorPalette.js +0 -54
  195. package/dist/types/ui/WidthProvider/isSsrButNoBreakoutScriptObserved.d.ts +0 -1
  196. package/dist/types/ui-color/ColorPalette/Palettes/statusColorPalette.d.ts +0 -4
  197. package/dist/types-ts4.5/ui/WidthProvider/isSsrButNoBreakoutScriptObserved.d.ts +0 -1
  198. package/dist/types-ts4.5/ui-color/ColorPalette/Palettes/statusColorPalette.d.ts +0 -4
@@ -1,4 +1,3 @@
1
- import { headingSizes } from '@atlaskit/theme/typography';
2
1
  export const DEFAULT_IMAGE_WIDTH = 250;
3
2
  export const DEFAULT_IMAGE_HEIGHT = 200;
4
3
  export const DEFAULT_INLINE_IMAGE_ASPECT_RATIO = DEFAULT_IMAGE_WIDTH / DEFAULT_IMAGE_HEIGHT;
@@ -12,13 +11,16 @@ export const DEFAULT_INLINE_IMAGE_BORDER_SIZE = 0;
12
11
  *
13
12
  * There is conversation about refactoring media inline nodes to conform to
14
13
  * aligning correctly with the surrounding text.
14
+ *
15
+ * These constants originally came from `headingSizes` from the `theme` package
16
+ * and have been copied here to remove this package.
15
17
  */
16
18
  export const referenceHeights = {
17
- p: headingSizes.h600.lineHeight - 2,
18
- h1: headingSizes.h800.lineHeight + 4,
19
- h2: headingSizes.h700.lineHeight + 3,
20
- h3: headingSizes.h600.lineHeight + 1,
21
- h4: headingSizes.h500.lineHeight + 3,
22
- h5: headingSizes.h400.lineHeight + 4,
23
- h6: headingSizes.h300.lineHeight + 2
19
+ p: 24 - 2,
20
+ h1: 32 + 4,
21
+ h2: 28 + 3,
22
+ h3: 24 + 1,
23
+ h4: 20 + 3,
24
+ h5: 16 + 4,
25
+ h6: 16 + 2
24
26
  };
@@ -1,6 +1,5 @@
1
1
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
2
2
  import { css } from '@emotion/react';
3
- import { B300 } from '@atlaskit/theme/colors';
4
3
  import { DEFAULT_INLINE_IMAGE_ASPECT_RATIO, DEFAULT_INLINE_IMAGE_BORDER_SIZE, referenceHeights } from './constants';
5
4
  export const INLINE_IMAGE_WRAPPER_CLASS_NAME = 'media-inline-image-wrapper';
6
5
  export const INLINE_IMAGE_ASPECT_RATIO_CSS_VAR_KEY = '--editor-media-inline-image-aspect-ratio';
@@ -76,7 +75,7 @@ export const wrapperStyle = css({
76
75
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
77
76
  export const selectedStyle = css({
78
77
  cursor: 'pointer',
79
- boxShadow: `0 0 0 1px ${`var(--ds-border-selected, ${B300})`}`,
78
+ boxShadow: `0 0 0 1px ${"var(--ds-border-selected, #0C66E4)"}`,
80
79
  outline: 'none'
81
80
  });
82
81
 
@@ -6,7 +6,6 @@
6
6
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
7
7
  import { jsx } from '@emotion/react';
8
8
  import WarningIcon from '@atlaskit/icon/glyph/warning';
9
- import { R300 } from '@atlaskit/theme/colors';
10
9
  import Tooltip from '@atlaskit/tooltip';
11
10
  import { ICON_SIZE_THRESOLD } from './constants';
12
11
  import { Frame } from './frame';
@@ -27,6 +26,6 @@ export const InlineImageCardErrorView = ({
27
26
  }, jsx(IconWrapper, null, icon || jsx(WarningIcon, {
28
27
  label: "error",
29
28
  size: height > ICON_SIZE_THRESOLD ? 'medium' : 'small',
30
- primaryColor: `var(--ds-icon-danger, ${R300})`
29
+ primaryColor: "var(--ds-icon-danger, #C9372C)"
31
30
  }))));
32
31
  };
@@ -1,6 +1,5 @@
1
1
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
2
2
  import { css } from '@emotion/react';
3
- import { N30A, N40A, N900 } from '@atlaskit/theme/colors';
4
3
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
5
4
  export const wrapperStyle = css({
6
5
  display: 'inline-flex',
@@ -10,11 +9,11 @@ export const wrapperStyle = css({
10
9
  justifyContent: 'center',
11
10
  boxDecorationBreak: 'clone',
12
11
  borderRadius: `${"var(--ds-border-radius, 3px)"}`,
13
- color: `${`var(--ds-text, ${N900})`}`,
14
- backgroundColor: `${`var(--ds-background-neutral, ${N30A})`}`,
12
+ color: `${"var(--ds-text, #172B4D)"}`,
13
+ backgroundColor: `${"var(--ds-background-neutral, #091E420F)"}`,
15
14
  transition: '0.1s all ease-in-out',
16
15
  cursor: 'pointer',
17
16
  '&:hover': {
18
- backgroundColor: `${`var(--ds-background-neutral-hovered, ${N40A})`}`
17
+ backgroundColor: `${"var(--ds-background-neutral-hovered, #091E4224)"}`
19
18
  }
20
19
  });
@@ -10,7 +10,6 @@ import debounce from 'lodash/debounce';
10
10
  import CustomThemeButton from '@atlaskit/button/custom-theme-button';
11
11
  import { akEditorUnitZIndex } from '@atlaskit/editor-shared-styles';
12
12
  import CommentIcon from '@atlaskit/icon/glyph/comment';
13
- import { layers } from '@atlaskit/theme/constants';
14
13
  import Tooltip from '@atlaskit/tooltip';
15
14
  import { commentMessages as messages } from '../media';
16
15
  const commentBadgeWrapper = css({
@@ -25,7 +24,7 @@ const commentBadgeWrapper = css({
25
24
  const commentBadgeEditorOverrides = badgeOffsetRight => css({
26
25
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
27
26
  right: badgeOffsetRight,
28
- zIndex: layers.card()
27
+ zIndex: 100
29
28
  });
30
29
  export const getBadgeSize = (width, height) => {
31
30
  // width is the original width of image, not resized or currently rendered to user. Defaulting to medium for now
@@ -1,7 +1,7 @@
1
1
  import { isFedRamp } from './environment';
2
2
  const SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
3
3
  const packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
4
- const packageVersion = "92.1.1";
4
+ const packageVersion = "93.0.0";
5
5
  const sanitiseSentryEvents = (data, _hint) => {
6
6
  // Remove URL as it has UGC
7
7
  // TODO: Sanitise the URL instead of just removing it
@@ -1,10 +1,9 @@
1
1
  import { findParentNodeOfTypeClosestToPos } from '@atlaskit/editor-prosemirror/utils';
2
2
  import { akEditorDefaultLayoutWidth, akEditorFullWidthLayoutWidth, akEditorWideLayoutWidth, akLayoutGutterOffset, gridMediumMaxWidth } from '@atlaskit/editor-shared-styles';
3
- // eslint-disable-next-line @atlaskit/design-system/no-deprecated-imports
4
- import { gridSize } from '@atlaskit/theme/constants';
5
3
  import { BODIED_EXT_PADDING } from '../styles/shared/extension';
6
4
  import { LAYOUT_COLUMN_PADDING, LAYOUT_SECTION_MARGIN } from '../styles/shared/layout';
7
5
  import { absoluteBreakoutWidth } from '../utils/breakout';
6
+ const GRID_SIZE = 8;
8
7
  export const layoutToWidth = {
9
8
  default: akEditorDefaultLayoutWidth,
10
9
  wide: akEditorWideLayoutWidth,
@@ -71,18 +70,15 @@ export const getParentNodeWidth = (pos, state, containerWidth, isFullWidthModeEn
71
70
  case schema.nodes.extensionFrame:
72
71
  parentWidth -= BODIED_EXT_PADDING * 2;
73
72
  break;
74
-
75
- // TODO: Migrate away from gridSize
76
- // Recommendation: Replace gridSize with 8
77
73
  case schema.nodes.expand:
78
74
  // padding
79
- parentWidth -= gridSize() * 2;
75
+ parentWidth -= GRID_SIZE * 2;
80
76
  // gutter offset
81
- parentWidth += gridSize() * 1.5 * 2;
77
+ parentWidth += GRID_SIZE * 1.5 * 2;
82
78
  // padding right
83
- parentWidth -= gridSize();
79
+ parentWidth -= GRID_SIZE;
84
80
  // padding left
85
- parentWidth -= gridSize() * 4 - gridSize() / 2;
81
+ parentWidth -= GRID_SIZE * 4 - GRID_SIZE / 2;
86
82
  break;
87
83
  }
88
84
  parentWidth -= 2; // border
@@ -1 +1 @@
1
- export { getPanelTypeBackground, getPanelTypeBackgroundNoTokens, darkPanelColors, getPanelDarkColor, panelSharedStyles, panelSharedStylesWithoutPrefix, PanelSharedCssClassName, PanelSharedSelectors, getPanelBackgroundDarkModeColors } from './styles/shared/panel';
1
+ export { getPanelTypeBackground, getPanelTypeBackgroundNoTokens, darkPanelColors, panelSharedStyles, panelSharedStylesWithoutPrefix, PanelSharedCssClassName, PanelSharedSelectors } from './styles/shared/panel';
@@ -1,7 +1,6 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
3
3
  import React from 'react';
4
- import { fg } from '@atlaskit/platform-feature-flags';
5
4
  import { ACTION_SUBJECT, ACTION_SUBJECT_ID } from '../analytics';
6
5
  import { createDispatch } from '../event-dispatcher';
7
6
  import { ErrorBoundary } from '../ui/ErrorBoundary';
@@ -113,48 +112,44 @@ export default class ReactNodeView {
113
112
 
114
113
  // move the contentDOM node inside the inner reference after rendering
115
114
  if (node && contentDOM && !node.contains(contentDOM)) {
116
- if (fg('platform_editor_react_18_prosemirror_sel_resync')) {
117
- var _this$view$state$sele;
118
- // @ts-ignore - ignoreMutation may not be declared
119
- oldIgnoreMutation = this.ignoreMutation; // store ref to previous ignoreMutation
115
+ var _this$view$state$sele;
116
+ // @ts-ignore - ignoreMutation may not be declared
117
+ oldIgnoreMutation = this.ignoreMutation; // store ref to previous ignoreMutation
120
118
 
121
- // ignore all mutations caused by ProseMirror's MutationObserver triggering
122
- // after DOM change, except selection changes
123
- // @ts-ignore ProseMirror adds selection type to MutationRecord
124
- this.ignoreMutation = m => {
125
- const isSelectionMutation = m.type === 'selection';
126
- if (!isSelectionMutation) {
127
- mutationsIgnored = true;
128
- }
129
- return !isSelectionMutation;
130
- };
131
-
132
- // capture document selection state before React DOM changes triggers ProseMirror selection change transaction
133
- if (this.view.state.selection.visible) {
134
- selectionBookmark = this.view.state.selection.getBookmark();
119
+ // ignore all mutations caused by ProseMirror's MutationObserver triggering
120
+ // after DOM change, except selection changes
121
+ // @ts-ignore ProseMirror adds selection type to MutationRecord
122
+ this.ignoreMutation = m => {
123
+ const isSelectionMutation = m.type === 'selection';
124
+ if (!isSelectionMutation) {
125
+ mutationsIgnored = true;
135
126
  }
127
+ return !isSelectionMutation;
128
+ };
136
129
 
137
- // ... and capture parent offset before DOM change
138
- if (((_this$view$state$sele = this.view.state.selection) === null || _this$view$state$sele === void 0 ? void 0 : _this$view$state$sele.ranges.length) > 0) {
139
- var _this$view$state$sele2, _this$view$state$sele3, _this$view$state$sele4;
140
- parentOffset = (_this$view$state$sele2 = (_this$view$state$sele3 = this.view.state.selection) === null || _this$view$state$sele3 === void 0 ? void 0 : (_this$view$state$sele4 = _this$view$state$sele3.ranges[0].$from) === null || _this$view$state$sele4 === void 0 ? void 0 : _this$view$state$sele4.parentOffset) !== null && _this$view$state$sele2 !== void 0 ? _this$view$state$sele2 : 0;
141
- }
130
+ // capture document selection state before React DOM changes triggers ProseMirror selection change transaction
131
+ if (this.view.state.selection.visible) {
132
+ selectionBookmark = this.view.state.selection.getBookmark();
142
133
  }
143
- node.appendChild(contentDOM);
144
- if (fg('platform_editor_react_18_prosemirror_sel_resync')) {
145
- requestAnimationFrame(() => {
146
- // Reset ignoreMutation after frame ....
147
- // @ts-ignore - this may not have been declared by implementing class
148
- this.ignoreMutation = oldIgnoreMutation;
149
134
 
150
- // only trigger selection re-sync if the selection is not at the start of the
151
- // node, and DOM mutations were ignored
152
- if (selectionBookmark && mutationsIgnored && parentOffset > 0) {
153
- // ... and dispatch expected selection state
154
- this.view.dispatch(this.view.state.tr.setSelection(selectionBookmark.resolve(this.view.state.tr.doc)));
155
- }
156
- });
135
+ // ... and capture parent offset before DOM change
136
+ if (((_this$view$state$sele = this.view.state.selection) === null || _this$view$state$sele === void 0 ? void 0 : _this$view$state$sele.ranges.length) > 0) {
137
+ var _this$view$state$sele2, _this$view$state$sele3, _this$view$state$sele4;
138
+ parentOffset = (_this$view$state$sele2 = (_this$view$state$sele3 = this.view.state.selection) === null || _this$view$state$sele3 === void 0 ? void 0 : (_this$view$state$sele4 = _this$view$state$sele3.ranges[0].$from) === null || _this$view$state$sele4 === void 0 ? void 0 : _this$view$state$sele4.parentOffset) !== null && _this$view$state$sele2 !== void 0 ? _this$view$state$sele2 : 0;
157
139
  }
140
+ node.appendChild(contentDOM);
141
+ requestAnimationFrame(() => {
142
+ // Reset ignoreMutation after frame ....
143
+ // @ts-ignore - this may not have been declared by implementing class
144
+ this.ignoreMutation = oldIgnoreMutation;
145
+
146
+ // only trigger selection re-sync if the selection is not at the start of the
147
+ // node, and DOM mutations were ignored
148
+ if (selectionBookmark && mutationsIgnored && parentOffset > 0) {
149
+ // ... and dispatch expected selection state
150
+ this.view.dispatch(this.view.state.tr.setSelection(selectionBookmark.resolve(this.view.state.tr.doc)));
151
+ }
152
+ });
158
153
  }
159
154
  }
160
155
  render(props, forwardRef) {
@@ -1,7 +1,6 @@
1
1
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
2
2
  import { css } from '@emotion/react';
3
3
  import { fg } from '@atlaskit/platform-feature-flags';
4
- import { N60A, Y300, Y75 } from '@atlaskit/theme/colors';
5
4
  export const annotationPrefix = 'ak-editor-annotation';
6
5
  export const AnnotationSharedClassNames = {
7
6
  focus: `${annotationPrefix}-focus`,
@@ -14,8 +13,6 @@ export const BlockAnnotationSharedClassNames = {
14
13
  blur: `${blockAnnotationPrefix}-blur`,
15
14
  draft: `${blockAnnotationPrefix}-draft`
16
15
  };
17
- const Yellow100 = 'rgb(255, 247, 214)';
18
- const Y200a = 'rgba(255, 196, 0, 0.82)';
19
16
  export const AnnotationSharedCSSByState = () => {
20
17
  if (fg('editor_inline_comments_on_inline_nodes')) {
21
18
  // NOTE: These styles are shared between renderer and editor. Sometimes they
@@ -33,20 +30,20 @@ export const AnnotationSharedCSSByState = () => {
33
30
  } : {
34
31
  paddingTop: '4px',
35
32
  border: 'none',
36
- boxShadow: `0 2px 0 0 ${`var(--ds-border-accent-yellow, ${Y200a})`}`
33
+ boxShadow: `0 2px 0 0 ${"var(--ds-border-accent-yellow, #B38600)"}`
37
34
  },
38
35
  '&:has(.date-lozenger-container)': {
39
36
  paddingTop: '2px'
40
37
  }
41
38
  },
42
39
  focus: css({
43
- background: `var(--ds-background-accent-yellow-subtler, ${Y75})`,
44
- borderBottomColor: `var(--ds-border-accent-yellow, ${Y300})`,
45
- boxShadow: `var(--ds-shadow-overlay, ${`1px 2px 3px ${N60A}, -1px 2px 3px ${N60A}`})`
40
+ background: "var(--ds-background-accent-yellow-subtler, #F8E6A0)",
41
+ borderBottomColor: "var(--ds-border-accent-yellow, #B38600)",
42
+ boxShadow: "var(--ds-shadow-overlay, 0px 8px 12px #091E4226, 0px 0px 1px #091E424f)"
46
43
  }),
47
44
  blur: css({
48
- background: `var(--ds-background-accent-yellow-subtlest, ${Yellow100})`,
49
- borderBottomColor: `var(--ds-border-accent-yellow, ${Y200a})`
45
+ background: "var(--ds-background-accent-yellow-subtlest, #FFF7D6)",
46
+ borderBottomColor: "var(--ds-border-accent-yellow, #B38600)"
50
47
  })
51
48
  };
52
49
  } else {
@@ -54,15 +51,15 @@ export const AnnotationSharedCSSByState = () => {
54
51
  focus: css({
55
52
  // Background is not coming through in confluence, suspecting to be caused by some specific combination of
56
53
  // emotion and token look up
57
- background: `var(--ds-background-accent-yellow-subtler, ${Y75})`,
58
- borderBottom: `2px solid ${`var(--ds-border-accent-yellow, ${Y300})`}`,
54
+ background: "var(--ds-background-accent-yellow-subtler, #F8E6A0)",
55
+ borderBottom: `2px solid ${"var(--ds-border-accent-yellow, #B38600)"}`,
59
56
  // TODO: https://product-fabric.atlassian.net/browse/DSP-4147
60
- boxShadow: `var(--ds-shadow-overlay, ${`1px 2px 3px ${N60A}, -1px 2px 3px ${N60A}`})`,
57
+ boxShadow: "var(--ds-shadow-overlay, 0px 8px 12px #091E4226, 0px 0px 1px #091E424f)",
61
58
  cursor: 'pointer'
62
59
  }),
63
60
  blur: css({
64
- background: `var(--ds-background-accent-yellow-subtlest, ${Yellow100})`,
65
- borderBottom: `2px solid ${`var(--ds-border-accent-yellow, ${Y200a})`}`,
61
+ background: "var(--ds-background-accent-yellow-subtlest, #FFF7D6)",
62
+ borderBottom: `2px solid ${"var(--ds-border-accent-yellow, #B38600)"}`,
66
63
  cursor: 'pointer'
67
64
  })
68
65
  };
@@ -2,8 +2,6 @@
2
2
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
3
3
  import { css } from '@emotion/react';
4
4
  import { akEditorCodeFontFamily, akEditorLineHeight, akEditorTableCellMinWidth, blockNodesVerticalMargin, overflowShadow, relativeFontSizeToBase16 } from '@atlaskit/editor-shared-styles';
5
- import { N20, N30, N400, N800 } from '@atlaskit/theme/colors';
6
- import { fontSize } from '@atlaskit/theme/constants';
7
5
  export const CodeBlockSharedCssClassName = {
8
6
  CODEBLOCK_CONTAINER: 'code-block',
9
7
  CODEBLOCK_START: 'code-block--start',
@@ -46,7 +44,7 @@ export const codeBlockSharedStyles = () => css`
46
44
 
47
45
  .${CodeBlockSharedCssClassName.CODEBLOCK_CONTAINER} {
48
46
  position: relative;
49
- background-color: ${"var(--ds-surface-raised, transparent)"};
47
+ background-color: ${"var(--ds-surface-raised, #FFFFFF)"};
50
48
  border-radius: ${"var(--ds-border-radius, 3px)"};
51
49
  margin: ${blockNodesVerticalMargin} 0 0 0;
52
50
  font-family: ${akEditorCodeFontFamily};
@@ -76,7 +74,7 @@ export const codeBlockSharedStyles = () => css`
76
74
  }
77
75
 
78
76
  .${CodeBlockSharedCssClassName.CODEBLOCK_CONTENT_WRAPPER} {
79
- background-color: ${`var(--ds-background-neutral, ${N20})`};
77
+ background-color: ${"var(--ds-background-neutral, #091E420F)"};
80
78
  display: flex;
81
79
  border-radius: ${"var(--ds-border-radius, 3px)"};
82
80
  width: 100%;
@@ -120,7 +118,7 @@ export const codeBlockSharedStyles = () => css`
120
118
  .${CodeBlockSharedCssClassName.CODEBLOCK_LINE_NUMBER_GUTTER} {
121
119
  flex-shrink: 0;
122
120
  text-align: right;
123
- background-color: ${`var(--ds-background-neutral, ${N30})`};
121
+ background-color: ${"var(--ds-background-neutral, #091E420F)"};
124
122
  padding: ${"var(--ds-space-100, 8px)"};
125
123
  position: relative;
126
124
 
@@ -133,20 +131,20 @@ export const codeBlockSharedStyles = () => css`
133
131
  display: inline-block;
134
132
  content: counter(line);
135
133
  counter-increment: line;
136
- color: ${`var(--ds-text-subtlest, ${N400})`};
137
- font-size: ${relativeFontSizeToBase16(fontSize())};
134
+ color: ${"var(--ds-text-subtlest, #626F86)"};
135
+ font-size: ${relativeFontSizeToBase16(14)};
138
136
  line-height: 1.5rem;
139
137
  }
140
138
  }
141
139
  }
142
140
 
143
141
  .${CodeBlockSharedCssClassName.CODEBLOCK_LINE_NUMBER_GUTTER_FG} {
144
- background-color: ${`var(--ds-background-neutral, ${N30})`};
142
+ background-color: ${"var(--ds-background-neutral, #091E420F)"};
145
143
  position: relative;
146
144
  width: var(--lineNumberGutterWidth, 2rem);
147
145
  padding: 0px ${"var(--ds-space-100, 8px)"};
148
146
  flex-shrink: 0;
149
- font-size: ${relativeFontSizeToBase16(fontSize())};
147
+ font-size: ${relativeFontSizeToBase16(14)};
150
148
  box-sizing: content-box;
151
149
  }
152
150
 
@@ -158,11 +156,11 @@ export const codeBlockSharedStyles = () => css`
158
156
  flex-grow: 1;
159
157
  tab-size: 4;
160
158
  cursor: text;
161
- color: ${`var(--ds-text, ${N800})`};
159
+ color: ${"var(--ds-text, #172B4D)"};
162
160
  border-radius: ${"var(--ds-border-radius, 3px)"};
163
161
  margin: ${"var(--ds-space-100, 8px)"};
164
162
  white-space: pre;
165
- font-size: ${relativeFontSizeToBase16(fontSize())};
163
+ font-size: ${relativeFontSizeToBase16(14)};
166
164
  line-height: 1.5rem;
167
165
  }
168
166
  }
@@ -171,10 +169,10 @@ export const codeBlockSharedStyles = () => css`
171
169
  code {
172
170
  tab-size: 4;
173
171
  cursor: text;
174
- color: ${`var(--ds-text, ${N800})`};
172
+ color: ${"var(--ds-text, #172B4D)"};
175
173
  border-radius: ${"var(--ds-border-radius, 3px)"};
176
174
  margin: ${"var(--ds-space-100, 8px)"};
177
- font-size: ${relativeFontSizeToBase16(fontSize())};
175
+ font-size: ${relativeFontSizeToBase16(14)};
178
176
  line-height: 1.5rem;
179
177
  }
180
178
  }
@@ -185,7 +183,7 @@ export const codeBlockSharedStyles = () => css`
185
183
  width: var(--lineNumberGutterWidth, 2rem);
186
184
  left: 0;
187
185
  position: absolute;
188
- font-size: ${relativeFontSizeToBase16(fontSize())};
186
+ font-size: ${relativeFontSizeToBase16(14)};
189
187
  padding: 0px ${"var(--ds-space-100, 8px)"};
190
188
  line-height: 1.5rem;
191
189
  text-align: right;
@@ -1,12 +1,11 @@
1
1
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
2
2
  import { css } from '@emotion/react';
3
3
  import { getCodeStyles } from '@atlaskit/code/inline';
4
- import { N30A } from '@atlaskit/theme/colors';
5
4
  export const codeMarkSharedStyles = () => {
6
5
  return css({
7
6
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
8
7
  '.code': {
9
- '--ds--code--bg-color': `var(--ds-background-neutral, ${N30A})`,
8
+ '--ds--code--bg-color': "var(--ds-background-neutral, #091E420F)",
10
9
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
11
10
  ...getCodeStyles()
12
11
  }
@@ -1,7 +1,6 @@
1
1
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
2
2
  import { css } from '@emotion/react';
3
3
  import { akEditorGridLineZIndex } from '@atlaskit/editor-shared-styles';
4
- import { B200, N30A } from '@atlaskit/theme/colors';
5
4
  export const GRID_GUTTER = 12;
6
5
 
7
6
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
@@ -24,7 +23,7 @@ export const gridStyles = css({
24
23
  },
25
24
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
26
25
  '.gridLine': {
27
- borderLeft: `1px solid ${`var(--ds-border, ${N30A})`}`,
26
+ borderLeft: `1px solid ${"var(--ds-border, #091E4224)"}`,
28
27
  display: 'inline-block',
29
28
  boxSizing: 'border-box',
30
29
  height: '100%',
@@ -35,6 +34,6 @@ export const gridStyles = css({
35
34
  },
36
35
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
37
36
  '.highlight': {
38
- borderLeft: `1px solid ${`var(--ds-border-focused, ${B200})`}`
37
+ borderLeft: `1px solid ${"var(--ds-border-focused, #388BFF)"}`
39
38
  }
40
39
  });
@@ -1,49 +1,76 @@
1
1
  /* eslint-disable @atlaskit/design-system/use-tokens-space */
2
+ /* eslint-disable @atlaskit/design-system/use-tokens-typography */
2
3
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
3
4
  import { css } from '@emotion/react';
4
- import { h100, h300, h400, h500, h600, h700 } from '@atlaskit/theme/typography';
5
-
6
5
  // @see typography spreadsheet: https://docs.google.com/spreadsheets/d/1iYusRGCT4PoPfvxbJ8NrgjtfFgXLm5lpDWXzjua1W2E/edit#gid=93913128
7
6
  // text sizing prototype: http://proto/fabricrender/
8
7
  export const headingsSharedStyles = () => css({
9
8
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
10
9
  '& h1': {
11
10
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
12
- ...h700(),
11
+ fontSize: `${24 / 14}em`,
12
+ fontStyle: 'inherit',
13
+ lineHeight: 28 / 24,
14
+ color: "var(--ds-text, #172B4D)",
15
+ fontWeight: "var(--ds-font-weight-medium, 500)",
16
+ letterSpacing: `-0.01em`,
13
17
  marginBottom: 0,
14
18
  marginTop: '1.667em'
15
19
  },
16
20
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
17
21
  '& h2': {
18
22
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
19
- ...h600(),
23
+ fontSize: `${20 / 14}em`,
24
+ fontStyle: 'inherit',
25
+ lineHeight: 24 / 20,
26
+ color: "var(--ds-text, #172B4D)",
27
+ fontWeight: "var(--ds-font-weight-medium, 500)",
28
+ letterSpacing: `-0.008em`,
20
29
  marginTop: '1.8em',
21
30
  marginBottom: 0
22
31
  },
23
32
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
24
33
  '& h3': {
25
34
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
26
- ...h500(),
35
+ fontSize: `${16 / 14}em`,
36
+ fontStyle: 'inherit',
37
+ lineHeight: 20 / 16,
38
+ color: "var(--ds-text, #172B4D)",
39
+ fontWeight: "var(--ds-font-weight-semibold, 600)",
40
+ letterSpacing: `-0.006em`,
27
41
  marginTop: '2em',
28
42
  marginBottom: 0
29
43
  },
30
44
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
31
45
  '& h4': {
32
46
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
33
- ...h400(),
47
+ fontSize: `${14 / 14}em`,
48
+ fontStyle: 'inherit',
49
+ lineHeight: 16 / 14,
50
+ color: "var(--ds-text, #172B4D)",
51
+ fontWeight: "var(--ds-font-weight-semibold, 600)",
52
+ letterSpacing: `-0.003em`,
34
53
  marginTop: '1.357em'
35
54
  },
36
55
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
37
56
  '& h5': {
38
57
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
39
- ...h300(),
58
+ fontSize: `${12 / 14}em`,
59
+ fontStyle: 'inherit',
60
+ lineHeight: 16 / 12,
61
+ color: "var(--ds-text, #172B4D)",
62
+ fontWeight: "var(--ds-font-weight-semibold, 600)",
40
63
  marginTop: '1.667em',
41
64
  textTransform: 'none'
42
65
  },
43
66
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
44
67
  '& h6': {
45
68
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
46
- ...h100(),
69
+ fontSize: `${11 / 14}em`,
70
+ fontStyle: 'inherit',
71
+ lineHeight: 16 / 11,
72
+ color: "var(--ds-text-subtlest, #626F86)",
73
+ fontWeight: "var(--ds-font-weight-bold, 700)",
47
74
  marginTop: '1.455em',
48
75
  textTransform: 'none'
49
76
  }
@@ -6,15 +6,14 @@ import { hexToEditorBackgroundPaletteColor } from '@atlaskit/editor-palette';
6
6
  import { akEditorTableCellMinWidth, blockNodesVerticalMargin } from '@atlaskit/editor-shared-styles';
7
7
  import { akEditorCustomIconSize } from '@atlaskit/editor-shared-styles/consts';
8
8
  import { emojiImage, emojiSprite } from '@atlaskit/emoji';
9
- import { B100, B400, B50, B75, G200, G400, G50, G75, N0, N20, N60, P100, P400, P50, P75, R100, R400, R50, R75, T100, T50, T75, Y200, Y400, Y50, Y75 } from '@atlaskit/theme/colors';
10
9
  import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
11
10
  const lightPanelColors = {
12
- info: B50,
13
- note: P50,
14
- tip: G50,
15
- success: G50,
16
- warning: Y50,
17
- error: R50
11
+ info: '#DEEBFF',
12
+ note: '#EAE6FF',
13
+ tip: '#E3FCEF',
14
+ success: '#E3FCEF',
15
+ warning: '#FFFAE6',
16
+ error: '#FFEBE6'
18
17
  };
19
18
  export const darkPanelColors = {
20
19
  // standard panels
@@ -79,30 +78,18 @@ export const darkPanelColors = {
79
78
  TextColor: '#D9DDE3'
80
79
  };
81
80
  const lightIconColor = {
82
- info: `var(--ds-icon-information, ${B400})`,
83
- note: `var(--ds-icon-discovery, ${P400})`,
84
- tip: `var(--ds-icon-success, ${G400})`,
85
- success: `var(--ds-icon-success, ${G400})`,
86
- warning: `var(--ds-icon-warning, ${Y400})`,
87
- error: `var(--ds-icon-danger, ${R400})`
81
+ info: "var(--ds-icon-information, #1D7AFC)",
82
+ note: "var(--ds-icon-discovery, #8270DB)",
83
+ tip: "var(--ds-icon-success, #22A06B)",
84
+ success: "var(--ds-icon-success, #22A06B)",
85
+ warning: "var(--ds-icon-warning, #E56910)",
86
+ error: "var(--ds-icon-danger, #C9372C)"
88
87
  };
89
88
 
90
89
  // New custom icons are a little smaller than predefined icons.
91
90
  // To fix alignment issues with custom icons, vertical alignment is updated.
92
91
  const panelEmojiSpriteVerticalAlignment = -(8 * 3 - akEditorCustomIconSize) / 2;
93
92
  const panelEmojiImageVerticalAlignment = panelEmojiSpriteVerticalAlignment - 1;
94
-
95
- // TODO: https://product-fabric.atlassian.net/browse/DSP-4066
96
- const panelDarkModeColors = [[B50, darkPanelColors.B1200S], [B75, darkPanelColors.B900], [B100, darkPanelColors.B800S], [N0, darkPanelColors.LightGray], [N20, darkPanelColors.Gray], [N60, darkPanelColors.DarkGray], [T50, darkPanelColors.T1200S], [T75, darkPanelColors.T900], [T100, darkPanelColors.T900S], [G50, darkPanelColors.G1200S], [G75, darkPanelColors.G900], [G200, darkPanelColors.G900S], [Y50, darkPanelColors.Y1200S], [Y75, darkPanelColors.Y900], [Y200, darkPanelColors.Y800S], [R50, darkPanelColors.R1200S], [R75, darkPanelColors.R900], [R100, darkPanelColors.R800S], [P50, darkPanelColors.P1200S], [P75, darkPanelColors.P900], [P100, darkPanelColors.P800S]];
97
-
98
- // used for custom panels
99
- export const getPanelDarkColor = panelColor => {
100
- const colorObject = panelDarkModeColors.find(color => color[0] === panelColor || color[1] === panelColor);
101
- return colorObject ? colorObject[1] : darkPanelColors.B1200S;
102
- };
103
-
104
- // used for custom panels
105
- export const getPanelBackgroundDarkModeColors = panelDarkModeColors.map(([colorName, colorValue]) => getPanelDarkModeCSS(colorName, colorValue)).join('\n');
106
93
  export function getPanelDarkModeCSS(colorName, colorValue) {
107
94
  return `
108
95
  &[data-panel-color="${colorName}"] {
@@ -1,6 +1,5 @@
1
1
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
2
2
  import { css } from '@emotion/react';
3
- import { N30 } from '@atlaskit/theme/colors';
4
3
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
5
4
  export const buttonGroupStyle = css({
6
5
  display: 'inline-flex',
@@ -14,7 +13,7 @@ export const buttonGroupStyle = css({
14
13
  // If you make change here, change in above file as well.
15
14
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
16
15
  export const separatorStyles = css({
17
- background: `var(--ds-border, ${N30})`,
16
+ background: "var(--ds-border, #091E4224)",
18
17
  width: '1px',
19
18
  height: '24px',
20
19
  display: 'inline-block',