@atlaskit/editor-core 214.2.4 → 215.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +29 -0
- package/dist/cjs/create-editor/ReactEditorView.js +53 -57
- package/dist/cjs/index.js +0 -7
- package/dist/cjs/ui/Appearance/FullPage/FullPageToolbarNext.js +2 -1
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer.js +38 -2
- package/dist/cjs/ui/EditorContentContainer/styles/tableStyles.js +10 -2
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/create-editor/ReactEditorView.js +36 -40
- package/dist/es2019/index.js +0 -8
- package/dist/es2019/ui/Appearance/FullPage/FullPageToolbarNext.js +3 -2
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer.js +40 -3
- package/dist/es2019/ui/EditorContentContainer/styles/tableStyles.js +9 -1
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/create-editor/ReactEditorView.js +53 -57
- package/dist/esm/index.js +0 -8
- package/dist/esm/ui/Appearance/FullPage/FullPageToolbarNext.js +3 -2
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer.js +39 -3
- package/dist/esm/ui/EditorContentContainer/styles/tableStyles.js +9 -1
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/index.d.ts +0 -7
- package/dist/types/ui/EditorContentContainer/styles/tableStyles.d.ts +1 -0
- package/dist/types-ts4.5/index.d.ts +0 -7
- package/dist/types-ts4.5/ui/EditorContentContainer/styles/tableStyles.d.ts +1 -0
- package/package.json +13 -11
- package/create-editor-content-style/package.json +0 -17
- package/dist/cjs/nodeviews/getInlineNodeViewProducer.styles.js +0 -43
- package/dist/cjs/ui/ContentStyles/ai-panels.js +0 -91
- package/dist/cjs/ui/ContentStyles/code-bidi-warning.js +0 -75
- package/dist/cjs/ui/ContentStyles/code-block.js +0 -28
- package/dist/cjs/ui/ContentStyles/date.js +0 -43
- package/dist/cjs/ui/ContentStyles/expand.js +0 -37
- package/dist/cjs/ui/ContentStyles/extension.js +0 -21
- package/dist/cjs/ui/ContentStyles/index.js +0 -220
- package/dist/cjs/ui/ContentStyles/layout.js +0 -80
- package/dist/cjs/ui/ContentStyles/media.js +0 -27
- package/dist/cjs/ui/ContentStyles/panel.js +0 -17
- package/dist/cjs/ui/ContentStyles/status.js +0 -158
- package/dist/cjs/ui/ContentStyles/tasks-and-decisions.js +0 -556
- package/dist/es2019/nodeviews/getInlineNodeViewProducer.styles.js +0 -47
- package/dist/es2019/ui/ContentStyles/ai-panels.js +0 -168
- package/dist/es2019/ui/ContentStyles/code-bidi-warning.js +0 -68
- package/dist/es2019/ui/ContentStyles/code-block.js +0 -90
- package/dist/es2019/ui/ContentStyles/date.js +0 -57
- package/dist/es2019/ui/ContentStyles/expand.js +0 -142
- package/dist/es2019/ui/ContentStyles/extension.js +0 -236
- package/dist/es2019/ui/ContentStyles/index.js +0 -580
- package/dist/es2019/ui/ContentStyles/layout.js +0 -388
- package/dist/es2019/ui/ContentStyles/media.js +0 -207
- package/dist/es2019/ui/ContentStyles/panel.js +0 -66
- package/dist/es2019/ui/ContentStyles/status.js +0 -197
- package/dist/es2019/ui/ContentStyles/tasks-and-decisions.js +0 -551
- package/dist/esm/nodeviews/getInlineNodeViewProducer.styles.js +0 -36
- package/dist/esm/ui/ContentStyles/ai-panels.js +0 -87
- package/dist/esm/ui/ContentStyles/code-bidi-warning.js +0 -68
- package/dist/esm/ui/ContentStyles/code-block.js +0 -21
- package/dist/esm/ui/ContentStyles/date.js +0 -37
- package/dist/esm/ui/ContentStyles/expand.js +0 -31
- package/dist/esm/ui/ContentStyles/extension.js +0 -15
- package/dist/esm/ui/ContentStyles/index.js +0 -214
- package/dist/esm/ui/ContentStyles/layout.js +0 -74
- package/dist/esm/ui/ContentStyles/media.js +0 -21
- package/dist/esm/ui/ContentStyles/panel.js +0 -11
- package/dist/esm/ui/ContentStyles/status.js +0 -152
- package/dist/esm/ui/ContentStyles/tasks-and-decisions.js +0 -548
- package/dist/types/nodeviews/getInlineNodeViewProducer.styles.d.ts +0 -2
- package/dist/types/ui/ContentStyles/ai-panels.d.ts +0 -8
- package/dist/types/ui/ContentStyles/code-bidi-warning.d.ts +0 -2
- package/dist/types/ui/ContentStyles/code-block.d.ts +0 -2
- package/dist/types/ui/ContentStyles/date.d.ts +0 -3
- package/dist/types/ui/ContentStyles/expand.d.ts +0 -2
- package/dist/types/ui/ContentStyles/extension.d.ts +0 -2
- package/dist/types/ui/ContentStyles/index.d.ts +0 -23
- package/dist/types/ui/ContentStyles/layout.d.ts +0 -8
- package/dist/types/ui/ContentStyles/media.d.ts +0 -2
- package/dist/types/ui/ContentStyles/panel.d.ts +0 -2
- package/dist/types/ui/ContentStyles/status.d.ts +0 -3
- package/dist/types/ui/ContentStyles/tasks-and-decisions.d.ts +0 -6
- package/dist/types-ts4.5/nodeviews/getInlineNodeViewProducer.styles.d.ts +0 -2
- package/dist/types-ts4.5/ui/ContentStyles/ai-panels.d.ts +0 -8
- package/dist/types-ts4.5/ui/ContentStyles/code-bidi-warning.d.ts +0 -2
- package/dist/types-ts4.5/ui/ContentStyles/code-block.d.ts +0 -2
- package/dist/types-ts4.5/ui/ContentStyles/date.d.ts +0 -3
- package/dist/types-ts4.5/ui/ContentStyles/expand.d.ts +0 -2
- package/dist/types-ts4.5/ui/ContentStyles/extension.d.ts +0 -2
- package/dist/types-ts4.5/ui/ContentStyles/index.d.ts +0 -23
- package/dist/types-ts4.5/ui/ContentStyles/layout.d.ts +0 -8
- package/dist/types-ts4.5/ui/ContentStyles/media.d.ts +0 -2
- package/dist/types-ts4.5/ui/ContentStyles/panel.d.ts +0 -2
- package/dist/types-ts4.5/ui/ContentStyles/status.d.ts +0 -3
- package/dist/types-ts4.5/ui/ContentStyles/tasks-and-decisions.d.ts +0 -6
|
@@ -493,71 +493,67 @@ export function ReactEditorView(props) {
|
|
|
493
493
|
var possibleListeners = React.useRef([]);
|
|
494
494
|
React.useEffect(function () {
|
|
495
495
|
return function () {
|
|
496
|
-
if (
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
(_scrollElement$curren = scrollElement.current) === null || _scrollElement$curren === void 0 || _scrollElement$curren.removeEventListener.apply(_scrollElement$curren, _toConsumableArray(possibleListener));
|
|
507
|
-
}
|
|
508
|
-
} catch (err) {
|
|
509
|
-
_iterator.e(err);
|
|
510
|
-
} finally {
|
|
511
|
-
_iterator.f();
|
|
496
|
+
if (scrollElement.current) {
|
|
497
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
498
|
+
var _iterator = _createForOfIteratorHelper(possibleListeners.current),
|
|
499
|
+
_step;
|
|
500
|
+
try {
|
|
501
|
+
for (_iterator.s(); !(_step = _iterator.n()).done;) {
|
|
502
|
+
var _scrollElement$curren;
|
|
503
|
+
var possibleListener = _step.value;
|
|
504
|
+
// eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
|
|
505
|
+
(_scrollElement$curren = scrollElement.current) === null || _scrollElement$curren === void 0 || _scrollElement$curren.removeEventListener.apply(_scrollElement$curren, _toConsumableArray(possibleListener));
|
|
512
506
|
}
|
|
507
|
+
} catch (err) {
|
|
508
|
+
_iterator.e(err);
|
|
509
|
+
} finally {
|
|
510
|
+
_iterator.f();
|
|
513
511
|
}
|
|
514
|
-
scrollElement.current = null;
|
|
515
512
|
}
|
|
513
|
+
scrollElement.current = null;
|
|
516
514
|
};
|
|
517
515
|
}, []);
|
|
518
516
|
var handleEditorViewRef = useCallback(function (node) {
|
|
519
|
-
if (
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
(_scrollElement$curren2 = scrollElement.current) === null || _scrollElement$curren2 === void 0 || _scrollElement$curren2.removeEventListener.apply(_scrollElement$curren2, _toConsumableArray(possibleListener));
|
|
532
|
-
}
|
|
533
|
-
} catch (err) {
|
|
534
|
-
_iterator2.e(err);
|
|
535
|
-
} finally {
|
|
536
|
-
_iterator2.f();
|
|
517
|
+
if (node) {
|
|
518
|
+
scrollElement.current = document.querySelector('[data-editor-scroll-container]');
|
|
519
|
+
var cleanupListeners = function cleanupListeners() {
|
|
520
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
521
|
+
var _iterator2 = _createForOfIteratorHelper(possibleListeners.current),
|
|
522
|
+
_step2;
|
|
523
|
+
try {
|
|
524
|
+
for (_iterator2.s(); !(_step2 = _iterator2.n()).done;) {
|
|
525
|
+
var _scrollElement$curren2;
|
|
526
|
+
var possibleListener = _step2.value;
|
|
527
|
+
// eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
|
|
528
|
+
(_scrollElement$curren2 = scrollElement.current) === null || _scrollElement$curren2 === void 0 || _scrollElement$curren2.removeEventListener.apply(_scrollElement$curren2, _toConsumableArray(possibleListener));
|
|
537
529
|
}
|
|
538
|
-
}
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
if (activeInteraction && ['edit-page', 'live-edit'].includes(activeInteraction.ufoName)) {
|
|
543
|
-
abortAll('new_interaction', "wheel-on-editor-element");
|
|
544
|
-
}
|
|
545
|
-
cleanupListeners();
|
|
546
|
-
};
|
|
547
|
-
// eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
|
|
548
|
-
scrollElement.current.addEventListener('wheel', wheelAbortHandler);
|
|
549
|
-
possibleListeners.current.push(['wheel', wheelAbortHandler]);
|
|
550
|
-
var scrollAbortHandler = function scrollAbortHandler() {
|
|
551
|
-
var activeInteraction = getActiveInteraction();
|
|
552
|
-
if (activeInteraction && ['edit-page', 'live-edit'].includes(activeInteraction.ufoName)) {
|
|
553
|
-
abortAll('new_interaction', "scroll-on-editor-element");
|
|
554
|
-
}
|
|
555
|
-
cleanupListeners();
|
|
556
|
-
};
|
|
557
|
-
// eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
|
|
558
|
-
scrollElement.current.addEventListener('scroll', scrollAbortHandler);
|
|
559
|
-
possibleListeners.current.push(['scroll', scrollAbortHandler]);
|
|
530
|
+
} catch (err) {
|
|
531
|
+
_iterator2.e(err);
|
|
532
|
+
} finally {
|
|
533
|
+
_iterator2.f();
|
|
560
534
|
}
|
|
535
|
+
};
|
|
536
|
+
if (scrollElement.current) {
|
|
537
|
+
var wheelAbortHandler = function wheelAbortHandler() {
|
|
538
|
+
var activeInteraction = getActiveInteraction();
|
|
539
|
+
if (activeInteraction && ['edit-page', 'live-edit'].includes(activeInteraction.ufoName)) {
|
|
540
|
+
abortAll('new_interaction', "wheel-on-editor-element");
|
|
541
|
+
}
|
|
542
|
+
cleanupListeners();
|
|
543
|
+
};
|
|
544
|
+
// eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
|
|
545
|
+
scrollElement.current.addEventListener('wheel', wheelAbortHandler);
|
|
546
|
+
possibleListeners.current.push(['wheel', wheelAbortHandler]);
|
|
547
|
+
var scrollAbortHandler = function scrollAbortHandler() {
|
|
548
|
+
var activeInteraction = getActiveInteraction();
|
|
549
|
+
if (activeInteraction && ['edit-page', 'live-edit'].includes(activeInteraction.ufoName)) {
|
|
550
|
+
abortAll('new_interaction', "scroll-on-editor-element");
|
|
551
|
+
}
|
|
552
|
+
cleanupListeners();
|
|
553
|
+
};
|
|
554
|
+
// eslint-disable-next-line @repo/internal/dom-events/no-unsafe-event-listeners
|
|
555
|
+
scrollElement.current.addEventListener('scroll', scrollAbortHandler);
|
|
556
|
+
possibleListeners.current.push(['scroll', scrollAbortHandler]);
|
|
561
557
|
}
|
|
562
558
|
}
|
|
563
559
|
if (!viewRef.current && node) {
|
package/dist/esm/index.js
CHANGED
|
@@ -36,13 +36,5 @@ export { getNodesCount } from './utils/getNodesCount';
|
|
|
36
36
|
export { default as measurements } from './utils/performance/measure-enum';
|
|
37
37
|
export { createFeatureFlagsFromProps } from './utils/feature-flags-from-props';
|
|
38
38
|
export { default as EditorActions } from './actions';
|
|
39
|
-
export {
|
|
40
|
-
// eslint-disable-next-line @repo/internal/deprecations/deprecation-ticket-required
|
|
41
|
-
/**
|
|
42
|
-
* @deprecated
|
|
43
|
-
* DO NOT USE THIS WILL BE REMOVED SOON.
|
|
44
|
-
* use this instead: packages/editor/editor-core/src/ui/EditorContentContainer.tsx
|
|
45
|
-
*/
|
|
46
|
-
createEditorContentStyle } from './ui/ContentStyles';
|
|
47
39
|
export { getDefaultPresetOptionsFromEditorProps } from './create-editor/create-plugins-list';
|
|
48
40
|
export { ReactEditorView } from './create-editor/ReactEditorView';
|
|
@@ -6,10 +6,11 @@ import { useIntl } from 'react-intl-next';
|
|
|
6
6
|
import { ContextPanelConsumer } from '@atlaskit/editor-common/context-panel';
|
|
7
7
|
import { TOOLBARS } from '@atlaskit/editor-common/toolbar';
|
|
8
8
|
import { ToolbarArrowKeyNavigationProvider } from '@atlaskit/editor-common/ui-menu';
|
|
9
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
9
10
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
10
11
|
import { isToolbar } from '../../../utils/toolbar';
|
|
11
12
|
import { ToolbarNext } from '../../Toolbar/Toolbar';
|
|
12
|
-
import { useToolbarPortal } from '../../Toolbar/ToolbarPortal';
|
|
13
|
+
import { ToolbarPortalMountPoint, useToolbarPortal } from '../../Toolbar/ToolbarPortal';
|
|
13
14
|
var styles = {
|
|
14
15
|
mainToolbarIconBefore: "_19pkpxbi _2hwxpxbi _otyrpxbi",
|
|
15
16
|
mainToolbarIconBeforeNew: "_4cvr1h6o _1e0c1txw",
|
|
@@ -106,7 +107,7 @@ export var FullPageToolbarNext = function FullPageToolbarNext(_ref4) {
|
|
|
106
107
|
}, !!customPrimaryToolbarComponents && 'before' in customPrimaryToolbarComponents && /*#__PURE__*/React.createElement("div", {
|
|
107
108
|
"data-testid": 'before-primary-toolbar-components-plugin',
|
|
108
109
|
className: ax([styles.beforePrimaryToolbarComponents])
|
|
109
|
-
}, customPrimaryToolbarComponents.before), !!customPrimaryToolbarComponents && 'after' in customPrimaryToolbarComponents ? customPrimaryToolbarComponents.after : customPrimaryToolbarComponents))) : toolbarDockingPosition !== 'none' && components && isToolbar(toolbar) && (!expValEquals('platform_editor_toolbar_aifc_patch_3', 'isEnabled', true) || editorView) && /*#__PURE__*/React.createElement(ToolbarNext, {
|
|
110
|
+
}, customPrimaryToolbarComponents.before), !!customPrimaryToolbarComponents && 'after' in customPrimaryToolbarComponents ? customPrimaryToolbarComponents.after : customPrimaryToolbarComponents)), fg('platform_editor_toolbar_aifc_patch_7') && /*#__PURE__*/React.createElement(ToolbarPortalMountPoint, null)) : toolbarDockingPosition !== 'none' && components && isToolbar(toolbar) && (!expValEquals('platform_editor_toolbar_aifc_patch_3', 'isEnabled', true) || editorView) && /*#__PURE__*/React.createElement(ToolbarNext, {
|
|
110
111
|
toolbar: toolbar,
|
|
111
112
|
components: components,
|
|
112
113
|
editorView: editorView,
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
2
|
/* eslint-disable @atlaskit/platform/ensure-feature-flag-prefix */
|
|
2
3
|
/* eslint-disable @atlaskit/design-system/consistent-css-prop-usage */
|
|
3
4
|
/**
|
|
@@ -9,6 +10,7 @@ import React from 'react';
|
|
|
9
10
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
10
11
|
import { jsx, useTheme } from '@emotion/react';
|
|
11
12
|
import { browser as browserLegacy, getBrowserInfo } from '@atlaskit/editor-common/browser';
|
|
13
|
+
import { richMediaClassName } from '@atlaskit/editor-common/styles';
|
|
12
14
|
import { akEditorGutterPaddingDynamic, editorFontSize } from '@atlaskit/editor-shared-styles';
|
|
13
15
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
14
16
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
@@ -58,7 +60,7 @@ import { shadowStyles } from './styles/shadowStyles';
|
|
|
58
60
|
import { editorControlsSmartCardStyles, linkingVisualRefreshV1Styles, smartCardStyles, smartCardStylesWithSearchMatch, smartCardStylesWithSearchMatchAndBlockMenuDangerStyles, smartCardStylesWithSearchMatchAndPreviewPanelResponsiveness, smartLinksInLivePagesStyles } from './styles/smartCardStyles';
|
|
59
61
|
import { statusDangerStyles, statusStyles, statusStylesMixin_fg_platform_component_visual_refresh, statusStylesMixin_fg_platform_component_visual_refresh_with_search_match, statusStylesMixin_without_fg_platform_component_visual_refresh, statusStylesMixin_without_fg_platform_component_visual_refresh_with_search_match } from './styles/statusStyles';
|
|
60
62
|
import { syncBlockStyles } from './styles/syncBlockStyles';
|
|
61
|
-
import { tableCommentEditorStyles, tableContainerStyles, tableLayoutFixes } from './styles/tableStyles';
|
|
63
|
+
import { tableCommentEditorStyles, tableContainerOverflowY, tableContainerStyles, tableLayoutFixes } from './styles/tableStyles';
|
|
62
64
|
import { decisionStyles, tasksAndDecisionsStyles, decisionIconWithVisualRefresh, decisionIconWithoutVisualRefresh, taskItemStyles, taskItemStylesWithBlockTaskItem, decisionDangerStyles } from './styles/tasksAndDecisionsStyles';
|
|
63
65
|
import { telepointerColorAndCommonStyle, telepointerStyle } from './styles/telepointerStyles';
|
|
64
66
|
import { textColorStyles } from './styles/textColorStyles';
|
|
@@ -66,6 +68,34 @@ import { textHighlightStyle } from './styles/textHighlightStyles';
|
|
|
66
68
|
import { unsupportedStyles } from './styles/unsupportedStyles';
|
|
67
69
|
import { whitespaceStyles } from './styles/whitespaceStyles';
|
|
68
70
|
var isFirefox = typeof navigator !== 'undefined' && navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
|
|
71
|
+
var alignMultipleWrappedImageInLayoutStyles = {
|
|
72
|
+
'.ProseMirror [data-layout-section] [data-layout-column] > div': {
|
|
73
|
+
// apply marginTop to wrapped mediaSingle that has preceding wrapped mediaSingle (even when there's gap cursor in between them)
|
|
74
|
+
// Given the first wrapped mediaSingle in layout has 0 marginTop, this is needed to make sure fellow wrapped mediaSingle align with it horizontally
|
|
75
|
+
'.mediaSingleView-content-wrap[layout^=wrap] + .mediaSingleView-content-wrap[layout^=wrap], .mediaSingleView-content-wrap[layout^=wrap] + .ProseMirror-gapcursor + .mediaSingleView-content-wrap[layout^=wrap]': {
|
|
76
|
+
'.rich-media-item': {
|
|
77
|
+
marginTop: 0
|
|
78
|
+
}
|
|
79
|
+
},
|
|
80
|
+
// Due to the above rule, wrapped mediaSingle (not the first node in layout) that are followed by wrapped mediaSingle should also have 0 marginTop
|
|
81
|
+
// so it's aligned with the following wrapped mediaSingle
|
|
82
|
+
'.mediaSingleView-content-wrap[layout^=wrap]:has( + .mediaSingleView-content-wrap[layout^=wrap])': {
|
|
83
|
+
'.rich-media-item': {
|
|
84
|
+
marginTop: 0
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
}
|
|
88
|
+
};
|
|
89
|
+
var firstWrappedMediaStyles = {
|
|
90
|
+
'.ProseMirror': {
|
|
91
|
+
// Remove gap between first wrapped mediaSingle and its fellow wrapped mediaSingle
|
|
92
|
+
"& [layout^='wrap-']:has(+ [layout^='wrap-']), & [layout^='wrap-']:has(+ .ProseMirror-gapcursor + [layout^='wrap-'])": _defineProperty({}, "& .".concat(richMediaClassName), {
|
|
93
|
+
marginLeft: 0,
|
|
94
|
+
marginRight: 0
|
|
95
|
+
})
|
|
96
|
+
}
|
|
97
|
+
};
|
|
98
|
+
|
|
69
99
|
/**
|
|
70
100
|
* EditorContentStyles is a wrapper component that applies styles to its children
|
|
71
101
|
* based on the provided feature flags, view mode, and other props.
|
|
@@ -175,6 +205,8 @@ var EditorContentContainer = /*#__PURE__*/React.forwardRef(function (props, ref)
|
|
|
175
205
|
ruleStyles,
|
|
176
206
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
177
207
|
mediaStyles,
|
|
208
|
+
// merge firstWrappedMediaStyles with mediaStyles when clean up platform_editor_fix_media_in_renderer
|
|
209
|
+
fg('platform_editor_fix_media_in_renderer') && firstWrappedMediaStyles,
|
|
178
210
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
179
211
|
telepointerStyle, /* This needs to be after telepointer styles as some overlapping rules have equal specificity, and so the order is significant */
|
|
180
212
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
@@ -256,7 +288,9 @@ var EditorContentContainer = /*#__PURE__*/React.forwardRef(function (props, ref)
|
|
|
256
288
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
257
289
|
resizerStyles,
|
|
258
290
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
259
|
-
layoutBaseStyles,
|
|
291
|
+
layoutBaseStyles,
|
|
292
|
+
// merge alignMultipleWrappedImageInLayoutStyles with layoutBaseStyles when clean up platform_editor_fix_media_in_renderer
|
|
293
|
+
fg('platform_editor_fix_media_in_renderer') && alignMultipleWrappedImageInLayoutStyles, expValEqualsNoExposure('platform_synced_block', 'isEnabled', true) &&
|
|
260
294
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
261
295
|
syncBlockStyles,
|
|
262
296
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
@@ -358,10 +392,12 @@ var EditorContentContainer = /*#__PURE__*/React.forwardRef(function (props, ref)
|
|
|
358
392
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
359
393
|
mediaAlignmentStyles,
|
|
360
394
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
361
|
-
tableLayoutFixes,
|
|
395
|
+
tableLayoutFixes,
|
|
362
396
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
363
397
|
tableContainerStyles,
|
|
364
398
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
399
|
+
!fg('platform_editor_table_container_y_overflow_fix') && tableContainerOverflowY,
|
|
400
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
365
401
|
hyperLinkFloatingToolbarStyles,
|
|
366
402
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
367
403
|
!fg('platform-visual-refresh-icons') && linkLegacyIconStylesFix,
|
|
@@ -34,7 +34,6 @@ export var tableContainerStyles = css({
|
|
|
34
34
|
'.ProseMirror .pm-table-wrapper': {
|
|
35
35
|
maxWidth: '100%',
|
|
36
36
|
overflowX: 'auto',
|
|
37
|
-
overflowY: 'visible',
|
|
38
37
|
// Ensure the wrapper doesn't grow beyond its container
|
|
39
38
|
width: '100%',
|
|
40
39
|
boxSizing: 'border-box'
|
|
@@ -48,4 +47,13 @@ export var tableContainerStyles = css({
|
|
|
48
47
|
// Ensure tables can be scrolled horizontally if needed
|
|
49
48
|
minWidth: 'auto'
|
|
50
49
|
}
|
|
50
|
+
});
|
|
51
|
+
|
|
52
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
53
|
+
export var tableContainerOverflowY = css({
|
|
54
|
+
/* Fix for HOT-119925: Ensure table containers have proper width constraints and overflow handling */
|
|
55
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
56
|
+
'.ProseMirror .pm-table-wrapper': {
|
|
57
|
+
overflowY: 'visible'
|
|
58
|
+
}
|
|
51
59
|
});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
export var name = "@atlaskit/editor-core";
|
|
2
|
-
export var version = "
|
|
2
|
+
export var version = "215.0.0";
|
package/dist/types/index.d.ts
CHANGED
|
@@ -28,12 +28,5 @@ export { default as measurements } from './utils/performance/measure-enum';
|
|
|
28
28
|
export { createFeatureFlagsFromProps } from './utils/feature-flags-from-props';
|
|
29
29
|
export type { Command, EditorProps, EditorInstance, CommandDispatch } from './types';
|
|
30
30
|
export { default as EditorActions } from './actions';
|
|
31
|
-
export {
|
|
32
|
-
/**
|
|
33
|
-
* @deprecated
|
|
34
|
-
* DO NOT USE THIS WILL BE REMOVED SOON.
|
|
35
|
-
* use this instead: packages/editor/editor-core/src/ui/EditorContentContainer.tsx
|
|
36
|
-
*/
|
|
37
|
-
createEditorContentStyle, } from './ui/ContentStyles';
|
|
38
31
|
export { getDefaultPresetOptionsFromEditorProps } from './create-editor/create-plugins-list';
|
|
39
32
|
export { ReactEditorView } from './create-editor/ReactEditorView';
|
|
@@ -3,3 +3,4 @@ export declare const tableLayoutFixes: SerializedStyles;
|
|
|
3
3
|
export declare const tableCommentEditorMarginOverride: SerializedStyles;
|
|
4
4
|
export declare const tableCommentEditorStyles: SerializedStyles;
|
|
5
5
|
export declare const tableContainerStyles: SerializedStyles;
|
|
6
|
+
export declare const tableContainerOverflowY: SerializedStyles;
|
|
@@ -28,12 +28,5 @@ export { default as measurements } from './utils/performance/measure-enum';
|
|
|
28
28
|
export { createFeatureFlagsFromProps } from './utils/feature-flags-from-props';
|
|
29
29
|
export type { Command, EditorProps, EditorInstance, CommandDispatch } from './types';
|
|
30
30
|
export { default as EditorActions } from './actions';
|
|
31
|
-
export {
|
|
32
|
-
/**
|
|
33
|
-
* @deprecated
|
|
34
|
-
* DO NOT USE THIS WILL BE REMOVED SOON.
|
|
35
|
-
* use this instead: packages/editor/editor-core/src/ui/EditorContentContainer.tsx
|
|
36
|
-
*/
|
|
37
|
-
createEditorContentStyle, } from './ui/ContentStyles';
|
|
38
31
|
export { getDefaultPresetOptionsFromEditorProps } from './create-editor/create-plugins-list';
|
|
39
32
|
export { ReactEditorView } from './create-editor/ReactEditorView';
|
|
@@ -3,3 +3,4 @@ export declare const tableLayoutFixes: SerializedStyles;
|
|
|
3
3
|
export declare const tableCommentEditorMarginOverride: SerializedStyles;
|
|
4
4
|
export declare const tableCommentEditorStyles: SerializedStyles;
|
|
5
5
|
export declare const tableContainerStyles: SerializedStyles;
|
|
6
|
+
export declare const tableContainerOverflowY: SerializedStyles;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/editor-core",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "215.0.1",
|
|
4
4
|
"description": "A package contains Atlassian editor core functionality",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -50,7 +50,7 @@
|
|
|
50
50
|
"@atlaskit/editor-performance-metrics": "^2.1.0",
|
|
51
51
|
"@atlaskit/editor-plugin-quick-insert": "^6.0.0",
|
|
52
52
|
"@atlaskit/editor-plugin-user-preferences": "^4.0.0",
|
|
53
|
-
"@atlaskit/editor-plugins": "^
|
|
53
|
+
"@atlaskit/editor-plugins": "^11.0.0",
|
|
54
54
|
"@atlaskit/editor-prosemirror": "7.0.0",
|
|
55
55
|
"@atlaskit/editor-shared-styles": "^3.6.0",
|
|
56
56
|
"@atlaskit/editor-toolbar": "^0.14.0",
|
|
@@ -97,7 +97,7 @@
|
|
|
97
97
|
"@atlaskit/editor-plugin-annotation": "^6.1.0",
|
|
98
98
|
"@atlaskit/editor-plugin-card": "^11.2.0",
|
|
99
99
|
"@atlaskit/editor-plugin-list": "^8.0.0",
|
|
100
|
-
"@atlaskit/editor-plugin-paste": "^7.
|
|
100
|
+
"@atlaskit/editor-plugin-paste": "^7.2.0",
|
|
101
101
|
"@atlaskit/link-provider": "^4.0.0",
|
|
102
102
|
"@atlaskit/logo": "^19.9.0",
|
|
103
103
|
"@atlaskit/media-core": "^37.0.0",
|
|
@@ -107,7 +107,7 @@
|
|
|
107
107
|
"@atlaskit/primitives": "^14.15.0",
|
|
108
108
|
"@atlaskit/renderer": "^124.1.0",
|
|
109
109
|
"@atlaskit/section-message": "^8.7.0",
|
|
110
|
-
"@atlaskit/smart-card": "^43.
|
|
110
|
+
"@atlaskit/smart-card": "^43.1.0",
|
|
111
111
|
"@atlaskit/synchrony-test-helpers": "workspace:^",
|
|
112
112
|
"@atlaskit/toggle": "^15.1.0",
|
|
113
113
|
"@atlaskit/util-data-test": "^18.3.0",
|
|
@@ -150,16 +150,9 @@
|
|
|
150
150
|
}
|
|
151
151
|
},
|
|
152
152
|
"platform-feature-flags": {
|
|
153
|
-
"cc_editor_abort_ufo_load_on_editor_scroll": {
|
|
154
|
-
"type": "boolean"
|
|
155
|
-
},
|
|
156
153
|
"confluence_floating_toolbar_animation": {
|
|
157
154
|
"type": "boolean"
|
|
158
155
|
},
|
|
159
|
-
"annotations_defensive_node_name_calculations": {
|
|
160
|
-
"type": "boolean",
|
|
161
|
-
"referenceOnly": "true"
|
|
162
|
-
},
|
|
163
156
|
"linking_platform_datasource_assets_objects": {
|
|
164
157
|
"type": "boolean",
|
|
165
158
|
"referenceOnly": "true"
|
|
@@ -261,6 +254,9 @@
|
|
|
261
254
|
"type": "boolean",
|
|
262
255
|
"referenceOnly": true
|
|
263
256
|
},
|
|
257
|
+
"platform_editor_fix_media_in_renderer": {
|
|
258
|
+
"type": "boolean"
|
|
259
|
+
},
|
|
264
260
|
"platform_editor_react_18_autofocus_fix": {
|
|
265
261
|
"type": "boolean"
|
|
266
262
|
},
|
|
@@ -475,6 +471,12 @@
|
|
|
475
471
|
},
|
|
476
472
|
"platform_editor_text_highlight_padding": {
|
|
477
473
|
"type": "boolean"
|
|
474
|
+
},
|
|
475
|
+
"platform_editor_toolbar_aifc_patch_7": {
|
|
476
|
+
"type": "boolean"
|
|
477
|
+
},
|
|
478
|
+
"platform_editor_table_container_y_overflow_fix": {
|
|
479
|
+
"type": "boolean"
|
|
478
480
|
}
|
|
479
481
|
},
|
|
480
482
|
"stricter": {
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"name": "@atlaskit/editor-core/create-editor-content-style",
|
|
3
|
-
"main": "../dist/cjs/ui/ContentStyles/index.js",
|
|
4
|
-
"module": "../dist/esm/ui/ContentStyles/index.js",
|
|
5
|
-
"module:es2019": "../dist/es2019/ui/ContentStyles/index.js",
|
|
6
|
-
"sideEffects": [
|
|
7
|
-
"*.compiled.css"
|
|
8
|
-
],
|
|
9
|
-
"types": "../dist/types/ui/ContentStyles/index.d.ts",
|
|
10
|
-
"typesVersions": {
|
|
11
|
-
">=4.5 <5.9": {
|
|
12
|
-
"*": [
|
|
13
|
-
"../dist/types-ts4.5/ui/ContentStyles/index.d.ts"
|
|
14
|
-
]
|
|
15
|
-
}
|
|
16
|
-
}
|
|
17
|
-
}
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
Object.defineProperty(exports, "__esModule", {
|
|
5
|
-
value: true
|
|
6
|
-
});
|
|
7
|
-
exports.InlineNodeViewSharedStyles = void 0;
|
|
8
|
-
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
9
|
-
var _react = require("@emotion/react");
|
|
10
|
-
var _reactNodeView = require("@atlaskit/editor-common/react-node-view");
|
|
11
|
-
var _whitespace = require("@atlaskit/editor-common/whitespace");
|
|
12
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
13
|
-
|
|
14
|
-
// For reasoning behind styles, see comments in:
|
|
15
|
-
// ./getInlineNodeViewProducer -> portalChildren()
|
|
16
|
-
|
|
17
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
18
|
-
var InlineNodeViewSharedStyles = exports.InlineNodeViewSharedStyles = (0, _react.css)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, ".".concat(_reactNodeView.inlineNodeViewClassname), {
|
|
19
|
-
display: 'inline',
|
|
20
|
-
userSelect: 'all',
|
|
21
|
-
whiteSpace: 'nowrap',
|
|
22
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
|
|
23
|
-
'& > *:not(.zeroWidthSpaceContainer)': {
|
|
24
|
-
whiteSpace: 'pre-wrap'
|
|
25
|
-
},
|
|
26
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
|
|
27
|
-
'& > .assistive': {
|
|
28
|
-
userSelect: 'none'
|
|
29
|
-
}
|
|
30
|
-
}), '&.ua-safari', (0, _defineProperty2.default)({}, ".".concat(_reactNodeView.inlineNodeViewClassname), {
|
|
31
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
|
|
32
|
-
'::selection, *::selection': {
|
|
33
|
-
background: 'transparent'
|
|
34
|
-
}
|
|
35
|
-
})), "&.ua-chrome .".concat(_reactNodeView.inlineNodeViewClassname, " > span"), {
|
|
36
|
-
userSelect: 'none'
|
|
37
|
-
}), ".".concat(_reactNodeView.inlineNodeViewClassname, "AddZeroWidthSpace"), {
|
|
38
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors -- Ignored via go/DSP-18766
|
|
39
|
-
'::after': {
|
|
40
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
41
|
-
content: "'".concat(_whitespace.ZERO_WIDTH_SPACE, "'")
|
|
42
|
-
}
|
|
43
|
-
}));
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
|
-
Object.defineProperty(exports, "__esModule", {
|
|
5
|
-
value: true
|
|
6
|
-
});
|
|
7
|
-
exports.aiPanelStyles = void 0;
|
|
8
|
-
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
|
9
|
-
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
10
|
-
var _react = require("@emotion/react");
|
|
11
|
-
var _templateObject;
|
|
12
|
-
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
13
|
-
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } /**
|
|
14
|
-
* TODO ED-26957 - remove legacy styles when static emotion refactor is complete
|
|
15
|
-
* We are moving this to new location under FF: platform_editor_core_static_emotion
|
|
16
|
-
* New location: packages/editor/editor-core/src/ui/EditorContentContainer.tsx
|
|
17
|
-
* If you are making updates to this file, please updates in new location as well.
|
|
18
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
19
|
-
var isFirefox = typeof navigator !== 'undefined' && navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
|
|
20
|
-
var rotationAnimation = (0, _react.keyframes)({
|
|
21
|
-
'0%': _objectSpread({
|
|
22
|
-
'--panel-gradient-angle': '0deg'
|
|
23
|
-
}, isFirefox ? {
|
|
24
|
-
backgroundPosition: '100%'
|
|
25
|
-
} : {}),
|
|
26
|
-
'100%': _objectSpread({
|
|
27
|
-
'--panel-gradient-angle': '360deg'
|
|
28
|
-
}, isFirefox ? {
|
|
29
|
-
backgroundPosition: '-100%'
|
|
30
|
-
} : {})
|
|
31
|
-
});
|
|
32
|
-
var aiPrismColor = (0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)((0, _defineProperty2.default)({}, 'prism.border.step.1', {
|
|
33
|
-
light: '#0065FF',
|
|
34
|
-
dark: '#0065FF80'
|
|
35
|
-
}), 'prism.border.step.2', {
|
|
36
|
-
light: '#0469FF',
|
|
37
|
-
dark: '#0469FF80'
|
|
38
|
-
}), 'prism.border.step.3', {
|
|
39
|
-
light: '#BF63F3',
|
|
40
|
-
dark: '#BF63F380'
|
|
41
|
-
}), 'prism.border.step.4', {
|
|
42
|
-
light: '#FFA900',
|
|
43
|
-
dark: '#FFA90080'
|
|
44
|
-
});
|
|
45
|
-
var prismBorderAnimationStyles = (0, _react.css)({
|
|
46
|
-
'&::before, &::after': _objectSpread(_objectSpread({
|
|
47
|
-
animationName: rotationAnimation,
|
|
48
|
-
animationDuration: '2s',
|
|
49
|
-
animationTimingFunction: 'linear',
|
|
50
|
-
animationIterationCount: 'infinite'
|
|
51
|
-
}, isFirefox ? {
|
|
52
|
-
animationDirection: 'normal',
|
|
53
|
-
animationDuration: '1s'
|
|
54
|
-
} : {}), {}, {
|
|
55
|
-
'@media (prefers-reduced-motion)': {
|
|
56
|
-
animation: 'none'
|
|
57
|
-
}
|
|
58
|
-
})
|
|
59
|
-
});
|
|
60
|
-
var prismBorderStyles = function prismBorderStyles(colorMode, hover) {
|
|
61
|
-
return (0, _react.css)(_objectSpread({
|
|
62
|
-
content: "''",
|
|
63
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
64
|
-
position: 'absolute',
|
|
65
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
66
|
-
zIndex: -1,
|
|
67
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
68
|
-
width: "calc(100% + 2px)",
|
|
69
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
70
|
-
height: "calc(100% + 2px)",
|
|
71
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
72
|
-
top: "-1px",
|
|
73
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
74
|
-
left: "-1px",
|
|
75
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
76
|
-
borderRadius: "calc(".concat("var(--ds-radius-small, 3px)", " + 1px)"),
|
|
77
|
-
transform: 'translate3d(0, 0, 0)'
|
|
78
|
-
}, hover ? {
|
|
79
|
-
background: "var(--ds-border-input, #8590A2)"
|
|
80
|
-
} : isFirefox ? {
|
|
81
|
-
background: "linear-gradient(90deg,\n\t\t\t\t\t\t\t\t".concat(aiPrismColor['prism.border.step.1'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 0%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.2'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 12%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.3'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 24%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.4'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 48%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.3'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 64%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.2'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 80%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.1'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 100%\n\t\t\t\t\t\t\t)"),
|
|
82
|
-
backgroundSize: '200%'
|
|
83
|
-
} : {
|
|
84
|
-
background: "conic-gradient(\n\t\t\t\t\t\t\t\tfrom var(--panel-gradient-angle, 270deg),\n\t\t\t\t\t\t\t\t".concat(aiPrismColor['prism.border.step.1'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 0%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.2'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 20%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.3'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 50%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.4'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 56%,\n\t\t\t\t\t\t\t\t").concat(aiPrismColor['prism.border.step.1'][colorMode !== null && colorMode !== void 0 ? colorMode : 'light'], " 100%\n\t\t\t\t\t\t\t)")
|
|
85
|
-
}));
|
|
86
|
-
};
|
|
87
|
-
var aiPanelStyles = exports.aiPanelStyles = function aiPanelStyles(colorMode
|
|
88
|
-
// eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression
|
|
89
|
-
) {
|
|
90
|
-
return (0, _react.css)(_templateObject || (_templateObject = (0, _taggedTemplateLiteral2.default)(["\n\t@property --panel-gradient-angle {\n\t\tsyntax: '<angle>';\n\t\tinitial-value: 270deg;\n\t\tinherits: false;\n\t}\n\n\tdiv[extensionType='com.atlassian.ai-blocks'] {\n\t\t/* This hides the label for the extension */\n\t\t.extension-label {\n\t\t\tdisplay: none;\n\t\t}\n\n\t\t/* This styles the ai panel correctly when its just sitting on the page and there\n\t\tis no user interaction */\n\t\t.extension-container {\n\t\t\tposition: relative;\n\t\t\tbox-shadow: none;\n\t\t\toverflow: unset;\n\t\t\tbackground-color: ", " !important;\n\t\t\t&::before,\n\t\t\t&::after {\n\t\t\t\t", "\n\t\t\t}\n\t\t\t&.with-hover-border {\n\t\t\t\t&::before,\n\t\t\t\t&::after {\n\t\t\t\t\t", "\n\t\t\t\t}\n\t\t\t}\n\t\t\t& .with-margin-styles {\n\t\t\t\tbackground-color: ", " !important;\n\t\t\t\tborder-radius: ", ";\n\t\t\t}\n\t\t}\n\t}\n\n\t/* This styles the ai panel correctly when its streaming */\n\tdiv[extensionType='com.atlassian.ai-blocks']:has(.streaming) {\n\t\t.extension-container {\n\t\t\tbox-shadow: none;\n\t\t\toverflow: unset;\n\t\t\t", "\n\t\t\t&::before,\n\t\t\t&::after {\n\t\t\t\t", "\n\t\t\t}\n\t\t}\n\t}\n\n\t/* This styles the ai panel correctly when a user is hovering over the delete button in the floating panel */\n\tdiv[extensionType='com.atlassian.ai-blocks'].danger {\n\t\t.extension-container {\n\t\t\tbox-shadow: 0 0 0 1px ", ";\n\t\t}\n\t}\n\n\t/* This removes the margin from the action list when inside an ai panel */\n\tdiv[extensiontype='com.atlassian.ai-blocks'][extensionkey='ai-action-items-block:aiActionItemsBodiedExtension'] {\n\t\tdiv[data-node-type='actionList'] {\n\t\t\tmargin: 0 !important;\n\t\t}\n\t}\n"])), "var(--ds-surface, #FFFFFF)", prismBorderStyles(colorMode), prismBorderStyles(colorMode, true), "var(--ds-surface, #FFFFFF)", "var(--ds-radius-small, 3px)", prismBorderAnimationStyles, prismBorderStyles(colorMode), "var(--ds-border-danger, #E2483D)");
|
|
91
|
-
};
|
|
@@ -1,75 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.codeBidiWarningStyles = void 0;
|
|
7
|
-
var _react = require("@emotion/react");
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
9
|
-
|
|
10
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
11
|
-
var codeBidiWarningStyles = exports.codeBidiWarningStyles = (0, _react.css)({
|
|
12
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
13
|
-
'[data-prosemirror-node-name="code-bidi-warning"]': {
|
|
14
|
-
display: 'inline-block'
|
|
15
|
-
},
|
|
16
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
17
|
-
'[data-prosemirror-node-name="code-bidi-warning"] [data-bidi-component="code-bidi-warning-decorator"]': {
|
|
18
|
-
paddingInlineStart: "var(--ds-space-050, 4px)",
|
|
19
|
-
paddingInlineEnd: "var(--ds-space-050, 4px)",
|
|
20
|
-
font: "var(--ds-font-body, normal 400 14px/20px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)",
|
|
21
|
-
fontStyle: 'normal',
|
|
22
|
-
fontFamily: "var(--ds-font-family-code, ui-monospace, Menlo, \"Segoe UI Mono\", \"Ubuntu Mono\", monospace)",
|
|
23
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
24
|
-
paddingTop: '0.05rem',
|
|
25
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
26
|
-
paddingBottom: '0.05rem',
|
|
27
|
-
color: "var(--ds-text-warning, #A54800)",
|
|
28
|
-
backgroundColor: "var(--ds-background-warning, #FFF7D6)"
|
|
29
|
-
},
|
|
30
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
31
|
-
'[data-prosemirror-node-name="code-bidi-warning"] [data-bidi-component="code-bidi-warning-decorator"]:hover': {
|
|
32
|
-
color: "var(--ds-text-warning, #A54800)",
|
|
33
|
-
backgroundColor: "var(--ds-background-warning-hovered, #F8E6A0)"
|
|
34
|
-
},
|
|
35
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
36
|
-
'[data-prosemirror-node-name="code-bidi-warning"] [data-bidi-component="code-bidi-warning-tooltip"]': {
|
|
37
|
-
visibility: 'hidden',
|
|
38
|
-
boxSizing: 'border-box',
|
|
39
|
-
width: '15pc',
|
|
40
|
-
backgroundColor: "var(--ds-background-neutral-bold, #44546F)",
|
|
41
|
-
color: "var(--ds-text-inverse, #FFFFFF)",
|
|
42
|
-
overflowWrap: 'break-word',
|
|
43
|
-
cursor: 'default',
|
|
44
|
-
borderRadius: "var(--ds-radius-small, 4px)",
|
|
45
|
-
margin: "var(--ds-space-0, 0px)",
|
|
46
|
-
padding: "var(--ds-space-025, 2px)".concat(" ", "var(--ds-space-075, 6px)"),
|
|
47
|
-
position: 'fixed',
|
|
48
|
-
// The character label will be ~80px and this is positioned from the end of that label
|
|
49
|
-
// We also use this instead of top: 24px to make sure the tooltip maintains its initial position
|
|
50
|
-
// instead of being positioned relative to the viewport.
|
|
51
|
-
// We need to use position: fixed so that the tooltip bypasses the overflow settings of the code block
|
|
52
|
-
// and is always visible.
|
|
53
|
-
// We also offset a little extra here to account for the transition behavior (to replicate ADS fade-in-from-top)
|
|
54
|
-
transform: 'translate(calc(-50% - 40px), calc(24px - 4px))',
|
|
55
|
-
opacity: 0,
|
|
56
|
-
whiteSpace: 'normal',
|
|
57
|
-
font: "var(--ds-font-body-small, normal 400 11px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)",
|
|
58
|
-
zIndex: 9999,
|
|
59
|
-
// Exit animation timings
|
|
60
|
-
// - Mark invisible after 0.475s
|
|
61
|
-
// - After 0.3s, fade out and move up over 0.175s
|
|
62
|
-
transition: 'visibility 0s linear 0.475s, opacity 0.175s cubic-bezier(0.15,1,0.3,1) 0.3s, transform 0.175s cubic-bezier(0.15,1,0.3,1) 0.3s'
|
|
63
|
-
},
|
|
64
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
65
|
-
'[data-prosemirror-node-name="code-bidi-warning"]:hover [data-bidi-component="code-bidi-warning-tooltip"]': {
|
|
66
|
-
visibility: 'visible',
|
|
67
|
-
transform: 'translate(calc(-50% - 40px), calc(24px))',
|
|
68
|
-
opacity: 1,
|
|
69
|
-
// Enter animation timings
|
|
70
|
-
// - Mark visible after 0.3s of hovering
|
|
71
|
-
// - After 0.3s, fade in over 0.175s
|
|
72
|
-
// - After 0.3s, move down over 0.35s
|
|
73
|
-
transition: 'visibility 0s linear 0.3s, opacity 0.175s cubic-bezier(0.15,1,0.3,1) 0.3s, transform 0.35s cubic-bezier(0.15,1,0.3,1) 0.3s'
|
|
74
|
-
}
|
|
75
|
-
});
|