@atlaskit/editor-core 217.4.2 → 217.4.4
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 +27 -0
- package/dist/cjs/composable-editor/core-editor.js +1 -1
- package/dist/cjs/editor.js +1 -1
- package/dist/cjs/ui/Addon/ClickAreaBlock/index.js +1 -1
- package/dist/cjs/ui/Addon/Dropdown/index.js +1 -1
- package/dist/cjs/ui/Appearance/Chromeless.js +4 -1
- package/dist/cjs/ui/Appearance/Comment/Comment.js +1 -1
- package/dist/cjs/ui/Appearance/Comment/Toolbar.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/BeforeWrapper.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/CustomToolbarWrapper.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPage.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/FullPageContentArea.js +5 -6
- package/dist/cjs/ui/Appearance/FullPage/FullPageToolbar.js +1 -1
- package/dist/cjs/ui/Appearance/FullPage/MainToolbarWrapper.js +1 -1
- package/dist/cjs/ui/ChromeCollapsed/index.js +1 -1
- package/dist/cjs/ui/ContextPanel/index.js +1 -1
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer.js +10 -2
- package/dist/cjs/ui/EditorContentContainer/styles/editorUGCTokenStyles.js +6 -1
- package/dist/cjs/ui/EditorContentContainer/styles/expandStyles.js +10 -1
- package/dist/cjs/ui/EditorContentContainer/styles/fontSizeStyles.js +23 -0
- package/dist/cjs/ui/PluginSlot/index.js +1 -1
- package/dist/cjs/ui/Toolbar/ToolbarInner.js +1 -1
- package/dist/cjs/ui/Toolbar/ToolbarWithSizeDetector.js +1 -1
- package/dist/cjs/ui/WithFlash/index.js +1 -1
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/composable-editor/core-editor.js +1 -1
- package/dist/es2019/editor.js +1 -1
- package/dist/es2019/ui/Addon/ClickAreaBlock/index.js +1 -1
- package/dist/es2019/ui/Addon/Dropdown/index.js +1 -1
- package/dist/es2019/ui/Appearance/Chromeless.js +4 -1
- package/dist/es2019/ui/Appearance/Comment/Comment.js +1 -1
- package/dist/es2019/ui/Appearance/Comment/Toolbar.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/BeforeWrapper.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/CustomToolbarWrapper.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPage.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/FullPageContentArea.js +5 -8
- package/dist/es2019/ui/Appearance/FullPage/FullPageToolbar.js +1 -1
- package/dist/es2019/ui/Appearance/FullPage/MainToolbarWrapper.js +1 -1
- package/dist/es2019/ui/ChromeCollapsed/index.js +1 -1
- package/dist/es2019/ui/ContextPanel/index.js +1 -1
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer.js +12 -4
- package/dist/es2019/ui/EditorContentContainer/styles/editorUGCTokenStyles.js +5 -0
- package/dist/es2019/ui/EditorContentContainer/styles/expandStyles.js +9 -0
- package/dist/es2019/ui/EditorContentContainer/styles/fontSizeStyles.js +17 -0
- package/dist/es2019/ui/PluginSlot/index.js +1 -1
- package/dist/es2019/ui/Toolbar/ToolbarInner.js +1 -1
- package/dist/es2019/ui/Toolbar/ToolbarWithSizeDetector.js +1 -1
- package/dist/es2019/ui/WithFlash/index.js +1 -1
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/composable-editor/core-editor.js +1 -1
- package/dist/esm/editor.js +1 -1
- package/dist/esm/ui/Addon/ClickAreaBlock/index.js +1 -1
- package/dist/esm/ui/Addon/Dropdown/index.js +1 -1
- package/dist/esm/ui/Appearance/Chromeless.js +4 -1
- package/dist/esm/ui/Appearance/Comment/Comment.js +1 -1
- package/dist/esm/ui/Appearance/Comment/Toolbar.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/BeforeWrapper.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/CustomToolbarWrapper.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/FullPage.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/FullPageContentArea.js +5 -6
- package/dist/esm/ui/Appearance/FullPage/FullPageToolbar.js +1 -1
- package/dist/esm/ui/Appearance/FullPage/MainToolbarWrapper.js +1 -1
- package/dist/esm/ui/ChromeCollapsed/index.js +1 -1
- package/dist/esm/ui/ContextPanel/index.js +1 -1
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer.js +12 -4
- package/dist/esm/ui/EditorContentContainer/styles/editorUGCTokenStyles.js +5 -0
- package/dist/esm/ui/EditorContentContainer/styles/expandStyles.js +9 -0
- package/dist/esm/ui/EditorContentContainer/styles/fontSizeStyles.js +17 -0
- package/dist/esm/ui/PluginSlot/index.js +1 -1
- package/dist/esm/ui/Toolbar/ToolbarInner.js +1 -1
- package/dist/esm/ui/Toolbar/ToolbarWithSizeDetector.js +1 -1
- package/dist/esm/ui/WithFlash/index.js +1 -1
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/ui/EditorContentContainer/styles/editorUGCTokenStyles.d.ts +1 -0
- package/dist/types/ui/EditorContentContainer/styles/expandStyles.d.ts +1 -0
- package/dist/types/ui/EditorContentContainer/styles/fontSizeStyles.d.ts +2 -0
- package/dist/types/ui/WithHelpTrigger/index.d.ts +1 -1
- package/dist/types-ts4.5/ui/EditorContentContainer/styles/editorUGCTokenStyles.d.ts +1 -0
- package/dist/types-ts4.5/ui/EditorContentContainer/styles/expandStyles.d.ts +1 -0
- package/dist/types-ts4.5/ui/EditorContentContainer/styles/fontSizeStyles.d.ts +2 -0
- package/dist/types-ts4.5/ui/WithHelpTrigger/index.d.ts +1 -1
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,32 @@
|
|
|
1
1
|
# @atlaskit/editor-core
|
|
2
2
|
|
|
3
|
+
## 217.4.4
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`244ca4ec80372`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/244ca4ec80372) -
|
|
8
|
+
Fix expand node clipping in chromeless editor by resetting negative margins behind
|
|
9
|
+
platform_editor_chromeless_expand_fix experiment
|
|
10
|
+
- [`6bdae1aef42cd`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/6bdae1aef42cd) -
|
|
11
|
+
Cleaning up Editor Content Area maxwidth style code due to the
|
|
12
|
+
confluence_max_width_content_appearance experiment being rolled out completly since january and
|
|
13
|
+
never cleaned up
|
|
14
|
+
- Updated dependencies
|
|
15
|
+
|
|
16
|
+
## 217.4.3
|
|
17
|
+
|
|
18
|
+
### Patch Changes
|
|
19
|
+
|
|
20
|
+
- [`8b781b3b3f9ca`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/8b781b3b3f9ca) -
|
|
21
|
+
Add setSmallText and setSmallTextWithAnalytics commands, modify setNormalText to remove fontSize
|
|
22
|
+
mark, add FORMAT_SMALL_TEXT analytics enum.
|
|
23
|
+
|
|
24
|
+
Add support to the renderer to render 'small text'.
|
|
25
|
+
|
|
26
|
+
Add 'fontSize' to stage0 default schema.
|
|
27
|
+
|
|
28
|
+
- Updated dependencies
|
|
29
|
+
|
|
3
30
|
## 217.4.2
|
|
4
31
|
|
|
5
32
|
### Patch Changes
|
|
@@ -34,7 +34,7 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
34
34
|
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; } /**
|
|
35
35
|
* @jsxRuntime classic
|
|
36
36
|
* @jsx jsx
|
|
37
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
37
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
38
38
|
// eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
|
|
39
39
|
// Ignored via go/ees005
|
|
40
40
|
// eslint-disable-next-line import/no-named-as-default
|
package/dist/cjs/editor.js
CHANGED
|
@@ -22,7 +22,7 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
|
|
|
22
22
|
/* eslint-disable @atlaskit/editor/no-re-export */ /**
|
|
23
23
|
* @jsxRuntime classic
|
|
24
24
|
* @jsx jsx
|
|
25
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
25
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
26
26
|
var ComposableEditorWrapper = function ComposableEditorWrapper(_ref) {
|
|
27
27
|
var props = _ref.props,
|
|
28
28
|
initialPluginConfiguration = _ref.initialPluginConfiguration;
|
|
@@ -14,7 +14,7 @@ var _clickAreaHelper = require("../click-area-helper");
|
|
|
14
14
|
* @jsx jsx
|
|
15
15
|
*/
|
|
16
16
|
|
|
17
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
17
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
18
18
|
|
|
19
19
|
var clickWrapper = (0, _react2.css)({
|
|
20
20
|
flexGrow: 1,
|
|
@@ -18,7 +18,7 @@ function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0,
|
|
|
18
18
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /**
|
|
19
19
|
* @jsxRuntime classic
|
|
20
20
|
* @jsx jsx
|
|
21
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
21
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
22
22
|
// Ignored via go/ees005
|
|
23
23
|
// eslint-disable-next-line @repo/internal/react/no-class-components
|
|
24
24
|
var DropdownWrapper = exports.default = /*#__PURE__*/function (_React$Component) {
|
|
@@ -24,7 +24,7 @@ function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0,
|
|
|
24
24
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /**
|
|
25
25
|
* @jsxRuntime classic
|
|
26
26
|
* @jsx jsx
|
|
27
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
27
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
28
28
|
var scrollbarStylesNew = (0, _react2.css)({
|
|
29
29
|
msOverflowStyle: '-ms-autohiding-scrollbar',
|
|
30
30
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
@@ -161,6 +161,9 @@ var Editor = exports.default = /*#__PURE__*/function (_React$Component) {
|
|
|
161
161
|
}(_react.default.Component);
|
|
162
162
|
(0, _defineProperty2.default)(Editor, "displayName", 'ChromelessEditorAppearance');
|
|
163
163
|
function RenderWithPluginState(_ref2) {
|
|
164
|
+
'use no memo';
|
|
165
|
+
|
|
166
|
+
// renderChrome should be changed to called as a component not a function
|
|
164
167
|
var renderChrome = _ref2.renderChrome,
|
|
165
168
|
editorAPI = _ref2.editorAPI;
|
|
166
169
|
var maxContentSizeReached = (0, _hooks.useSharedPluginStateWithSelector)(editorAPI, ['maxContentSize'], function (states) {
|
|
@@ -35,7 +35,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
35
35
|
* @jsx jsx
|
|
36
36
|
*/
|
|
37
37
|
|
|
38
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
38
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
39
39
|
|
|
40
40
|
// Ignored via go/ees005
|
|
41
41
|
// eslint-disable-next-line import/no-named-as-default
|
|
@@ -20,7 +20,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
20
20
|
* @jsx jsx
|
|
21
21
|
*/
|
|
22
22
|
|
|
23
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
23
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
24
24
|
|
|
25
25
|
var MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT = 490;
|
|
26
26
|
var akEditorMenuZIndex = 500;
|
|
@@ -10,7 +10,7 @@ var _react = require("@emotion/react");
|
|
|
10
10
|
* @jsx jsx
|
|
11
11
|
*/
|
|
12
12
|
|
|
13
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
13
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
14
14
|
|
|
15
15
|
var beforePrimaryToolbarPluginWrapperStyles = (0, _react.css)({
|
|
16
16
|
display: 'flex',
|
|
@@ -12,7 +12,7 @@ var _react2 = require("@emotion/react");
|
|
|
12
12
|
* @jsx jsx
|
|
13
13
|
*/
|
|
14
14
|
|
|
15
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
15
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
16
16
|
|
|
17
17
|
// Pre-computed static styles for first- and second-child wrappers.
|
|
18
18
|
// These contain no runtime logic and are safe for static-emotion mode.
|
|
@@ -29,7 +29,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
29
29
|
* @jsx jsx
|
|
30
30
|
*/
|
|
31
31
|
|
|
32
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
32
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
33
33
|
|
|
34
34
|
var SSR_TRACE_SEGMENT_NAME = 'reactEditorView/fullPageAppearance';
|
|
35
35
|
var useShowKeyline = function useShowKeyline(contentAreaRef) {
|
|
@@ -15,7 +15,6 @@ var _adfSchema = require("@atlaskit/adf-schema");
|
|
|
15
15
|
var _messages = require("@atlaskit/editor-common/messages");
|
|
16
16
|
var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
|
|
17
17
|
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
18
|
-
var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
|
|
19
18
|
var _expValEqualsNoExposure = require("@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure");
|
|
20
19
|
var _experiments = require("@atlaskit/tmp-editor-statsig/experiments");
|
|
21
20
|
var _ClickAreaBlock = _interopRequireDefault(require("../../Addon/ClickAreaBlock"));
|
|
@@ -29,7 +28,7 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
29
28
|
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; } /**
|
|
30
29
|
* @jsxRuntime classic
|
|
31
30
|
* @jsx jsx
|
|
32
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
31
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
33
32
|
// Ignored via go/ees005
|
|
34
33
|
// eslint-disable-next-line import/no-named-as-default
|
|
35
34
|
var akEditorFullWidthLayoutWidth = 1800;
|
|
@@ -217,6 +216,7 @@ var Content = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
|
217
216
|
var contentAreaRef = (0, _react.useRef)(null);
|
|
218
217
|
var containerRef = (0, _react.useRef)(null);
|
|
219
218
|
var allowScrollGutter = (_props$editorAPI = props.editorAPI) === null || _props$editorAPI === void 0 || (_props$editorAPI = _props$editorAPI.base) === null || _props$editorAPI === void 0 || (_props$editorAPI = _props$editorAPI.sharedState.currentState()) === null || _props$editorAPI === void 0 ? void 0 : _props$editorAPI.allowScrollGutter;
|
|
219
|
+
var contentAreaMaxWidth = getTotalPadding() + (!fullWidthMode ? maxWidthMode ? akEditorUltraWideLayoutWidth : theme.layoutMaxWidth : akEditorFullWidthLayoutWidth);
|
|
220
220
|
(0, _react.useImperativeHandle)(ref, function () {
|
|
221
221
|
return {
|
|
222
222
|
get scrollContainer() {
|
|
@@ -258,9 +258,7 @@ var Content = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
|
258
258
|
// for breakout resizing, there's no need to restrict the width of codeblocks as they're always wrapped in a breakout mark
|
|
259
259
|
(0, _expValEqualsNoExposure.expValEqualsNoExposure)('platform_editor_breakout_resizing', 'isEnabled', true) ? editorContentAreaContainerStyleExcludeCodeBlockNew : editorContentAreaContainerStyleNew, (0, _platformFeatureFlags.fg)('platform_editor_nested_dnd_styles_changes') && editorContentAreaContainerNestedDndStyle, !(0, _platformFeatureFlags.fg)('platform_editor_controls_no_toolbar_space') && (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') && contentAreaReducedHeaderSpace, !(0, _platformFeatureFlags.fg)('platform_editor_controls_no_toolbar_space') && props.isEditorToolbarHidden && (0, _experiments.editorExperiment)('platform_editor_controls', 'variant1') && contentAreaReservedPrimaryToolbarSpace],
|
|
260
260
|
style: {
|
|
261
|
-
'--ak-editor-content-area-max-width':
|
|
262
|
-
"".concat(akEditorUltraWideLayoutWidth + getTotalPadding(), "px") : // @ts-ignore
|
|
263
|
-
"".concat(theme.layoutMaxWidth + getTotalPadding(), "px") : "".concat(akEditorFullWidthLayoutWidth + getTotalPadding(), "px")
|
|
261
|
+
'--ak-editor-content-area-max-width': "".concat(contentAreaMaxWidth, "px")
|
|
264
262
|
}
|
|
265
263
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
|
|
266
264
|
,
|
|
@@ -268,7 +266,8 @@ var Content = /*#__PURE__*/_react.default.forwardRef(function (props, ref) {
|
|
|
268
266
|
"data-editor-editable-content": true,
|
|
269
267
|
role: "region",
|
|
270
268
|
"aria-label": props.intl.formatMessage(_messages.fullPageMessages.editableContentLabel),
|
|
271
|
-
ref: contentAreaRef
|
|
269
|
+
ref: contentAreaRef,
|
|
270
|
+
"data-vc": "editor-content-area-region"
|
|
272
271
|
}, (0, _react2.jsx)("div", {
|
|
273
272
|
css: [editorContentGutterStyles,
|
|
274
273
|
// eslint-disable-next-line @atlaskit/platform/no-preconditioning
|
|
@@ -26,7 +26,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
26
26
|
* @jsx jsx
|
|
27
27
|
*/
|
|
28
28
|
|
|
29
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
29
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
30
30
|
|
|
31
31
|
var EditorToolbar = exports.EditorToolbar = /*#__PURE__*/_react.default.memo(function (props) {
|
|
32
32
|
var _props$primaryToolbar, _useToolbarPortal, _props$customPrimaryT;
|
|
@@ -15,7 +15,7 @@ var _MainToolbar = require("./MainToolbar");
|
|
|
15
15
|
* @jsx jsx
|
|
16
16
|
*/
|
|
17
17
|
|
|
18
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
18
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
19
19
|
|
|
20
20
|
// Base styles that don't depend on feature flags
|
|
21
21
|
var baseToolbarStyles = (0, _react2.css)({
|
|
@@ -22,7 +22,7 @@ function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0,
|
|
|
22
22
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /**
|
|
23
23
|
* @jsxRuntime classic
|
|
24
24
|
* @jsx jsx
|
|
25
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
25
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
26
26
|
// Ignored via go/ees005
|
|
27
27
|
// eslint-disable-next-line @repo/internal/react/no-class-components
|
|
28
28
|
var ChromeCollapsed = /*#__PURE__*/function (_PureComponent) {
|
|
@@ -28,7 +28,7 @@ function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0,
|
|
|
28
28
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /**
|
|
29
29
|
* @jsxRuntime classic
|
|
30
30
|
* @jsx jsx
|
|
31
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
31
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
32
32
|
var ANIM_SPEED_MS = 500;
|
|
33
33
|
var panelHidden = (0, _react2.css)({
|
|
34
34
|
width: 0
|
|
@@ -37,6 +37,7 @@ var _extensionStyles = require("./styles/extensionStyles");
|
|
|
37
37
|
var _findReplaceStyles = require("./styles/findReplaceStyles");
|
|
38
38
|
var _firstBlockNodeStyles = require("./styles/firstBlockNodeStyles");
|
|
39
39
|
var _floatingToolbarStyles = require("./styles/floatingToolbarStyles");
|
|
40
|
+
var _fontSizeStyles = require("./styles/fontSizeStyles");
|
|
40
41
|
var _fullPageEditorStyles = require("./styles/fullPageEditorStyles");
|
|
41
42
|
var _gapCursorStyles = require("./styles/gapCursorStyles");
|
|
42
43
|
var _gridStyles = require("./styles/gridStyles");
|
|
@@ -72,7 +73,7 @@ var _whitespaceStyles = require("./styles/whitespaceStyles");
|
|
|
72
73
|
* @jsx jsx
|
|
73
74
|
*/
|
|
74
75
|
|
|
75
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
76
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
76
77
|
|
|
77
78
|
var isFirefox = typeof navigator !== 'undefined' && navigator.userAgent.toLowerCase().indexOf('firefox') > -1;
|
|
78
79
|
var alignMultipleWrappedImageInLayoutStyles = {
|
|
@@ -122,6 +123,7 @@ var EditorContentContainer = /*#__PURE__*/_react.default.forwardRef(function (pr
|
|
|
122
123
|
colorMode = _useThemeObserver.colorMode;
|
|
123
124
|
var isFullPage = appearance === 'full-page' || appearance === 'full-width' || ((0, _expValEqualsNoExposure.expValEqualsNoExposure)('editor_tinymce_full_width_mode', 'isEnabled', true) || (0, _expValEqualsNoExposure.expValEqualsNoExposure)('confluence_max_width_content_appearance', 'isEnabled', true)) && appearance === 'max';
|
|
124
125
|
var isComment = appearance === 'comment';
|
|
126
|
+
var isChromeless = appearance === 'chromeless';
|
|
125
127
|
var baseFontSize = (0, _getBaseFontSize.getBaseFontSize)(appearance, contentMode);
|
|
126
128
|
var style = (0, _experiments.editorExperiment)('platform_editor_preview_panel_responsiveness', true, {
|
|
127
129
|
exposure: true
|
|
@@ -165,6 +167,8 @@ var EditorContentContainer = /*#__PURE__*/_react.default.forwardRef(function (pr
|
|
|
165
167
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
166
168
|
_indentationStyles.indentationStyles,
|
|
167
169
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
170
|
+
(0, _expValEquals.expValEquals)('platform_editor_small_font_size', 'isEnabled', true) && _fontSizeStyles.fontSizeStyles,
|
|
171
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
168
172
|
_shadowStyles.shadowStyles,
|
|
169
173
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
170
174
|
_inlineNodeViewSharedStyles.InlineNodeViewSharedStyles,
|
|
@@ -198,6 +202,8 @@ var EditorContentContainer = /*#__PURE__*/_react.default.forwardRef(function (pr
|
|
|
198
202
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
199
203
|
_editorUGCTokenStyles.editorUGCTokensRefreshed,
|
|
200
204
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
205
|
+
(0, _expValEquals.expValEquals)('platform_editor_small_font_size', 'isEnabled', true) && _editorUGCTokenStyles.editorUGCSmallText,
|
|
206
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
201
207
|
_blockTypeStyles.blocktypeStyles, (0, _expValEquals.expValEquals)('platform_editor_block_menu', 'isEnabled', true) &&
|
|
202
208
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
203
209
|
_blockTypeStyles.blockquoteSelectedNodeStyles, (0, _expValEquals.expValEquals)('platform_editor_block_menu', 'isEnabled', true) &&
|
|
@@ -298,7 +304,9 @@ var EditorContentContainer = /*#__PURE__*/_react.default.forwardRef(function (pr
|
|
|
298
304
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
299
305
|
_expandStyles.expandStylesMixin_without_fg_platform_editor_nested_dnd_styles_changes,
|
|
300
306
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
301
|
-
_expandStyles.expandStylesMixin_fg_platform_visual_refresh_icons, (0, _expValEquals.expValEquals)('
|
|
307
|
+
_expandStyles.expandStylesMixin_fg_platform_visual_refresh_icons, isChromeless && (0, _expValEquals.expValEquals)('platform_editor_chromeless_expand_fix', 'isEnabled', true) &&
|
|
308
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
309
|
+
_expandStyles.expandStylesMixin_experiment_platform_editor_chromeless_expand_fix, (0, _expValEquals.expValEquals)('platform_editor_find_and_replace_improvements', 'isEnabled', true) ?
|
|
302
310
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
303
311
|
_findReplaceStyles.findReplaceStylesNewWithA11Y :
|
|
304
312
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.editorUGCTokensRefreshed = exports.editorUGCTokensModernized = exports.editorUGCTokensDefault = void 0;
|
|
6
|
+
exports.editorUGCTokensRefreshed = exports.editorUGCTokensModernized = exports.editorUGCTokensDefault = exports.editorUGCSmallText = void 0;
|
|
7
7
|
var _react = require("@emotion/react");
|
|
8
8
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
9
9
|
|
|
@@ -52,4 +52,9 @@ var editorUGCTokensRefreshed = exports.editorUGCTokensRefreshed = (0, _react.css
|
|
|
52
52
|
'--editor-font-ugc-token-heading-h6': 'normal 600 0.785714em/1.45455 "Atlassian Sans", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Ubuntu, "Helvetica Neue", sans-serif',
|
|
53
53
|
'--editor-font-ugc-token-body': 'normal 400 1em/1.714 "Atlassian Sans", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Ubuntu, "Helvetica Neue", sans-serif',
|
|
54
54
|
'--editor-font-ugc-token-weight-heading-bold': '700'
|
|
55
|
+
});
|
|
56
|
+
|
|
57
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
58
|
+
var editorUGCSmallText = exports.editorUGCSmallText = (0, _react.css)({
|
|
59
|
+
'--editor-font-ugc-token-body-small': 'normal 400 0.875em/1.714 "Atlassian Sans", ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Ubuntu, "Helvetica Neue", sans-serif'
|
|
55
60
|
});
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.getDenseExpandTitleStyles = exports.expandStylesMixin_without_fg_platform_editor_nested_dnd_styles_changes = exports.expandStylesMixin_fg_platform_visual_refresh_icons = exports.expandStylesMixin_fg_platform_editor_nested_dnd_styles_changes = exports.expandStyles = void 0;
|
|
6
|
+
exports.getDenseExpandTitleStyles = exports.expandStylesMixin_without_fg_platform_editor_nested_dnd_styles_changes = exports.expandStylesMixin_fg_platform_visual_refresh_icons = exports.expandStylesMixin_fg_platform_editor_nested_dnd_styles_changes = exports.expandStylesMixin_experiment_platform_editor_chromeless_expand_fix = exports.expandStyles = void 0;
|
|
7
7
|
var _react = require("@emotion/react");
|
|
8
8
|
var _editorSharedStyles = require("@atlaskit/editor-shared-styles");
|
|
9
9
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled
|
|
@@ -303,6 +303,15 @@ var expandStylesMixin_fg_platform_editor_nested_dnd_styles_changes = exports.exp
|
|
|
303
303
|
}
|
|
304
304
|
});
|
|
305
305
|
|
|
306
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
307
|
+
var expandStylesMixin_experiment_platform_editor_chromeless_expand_fix = exports.expandStylesMixin_experiment_platform_editor_chromeless_expand_fix = (0, _react.css)({
|
|
308
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
309
|
+
'.ProseMirror > .ak-editor-expand': {
|
|
310
|
+
marginLeft: 0,
|
|
311
|
+
marginRight: 0
|
|
312
|
+
}
|
|
313
|
+
});
|
|
314
|
+
|
|
306
315
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
307
316
|
var expandStylesMixin_without_fg_platform_editor_nested_dnd_styles_changes = exports.expandStylesMixin_without_fg_platform_editor_nested_dnd_styles_changes = (0, _react.css)({
|
|
308
317
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.fontSizeStyles = 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 fontSizeStyles = exports.fontSizeStyles = (0, _react.css)({
|
|
12
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
13
|
+
'.ProseMirror': {
|
|
14
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
15
|
+
'.fabric-editor-font-size': {
|
|
16
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
17
|
+
"&[data-font-size='small']": {
|
|
18
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
19
|
+
font: 'var(--editor-font-ugc-token-body-small)'
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
});
|
|
@@ -17,7 +17,7 @@ var _mountPluginHooks = require("./mount-plugin-hooks");
|
|
|
17
17
|
* @jsx jsx
|
|
18
18
|
*/
|
|
19
19
|
|
|
20
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
20
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
21
21
|
|
|
22
22
|
var pluginsComponentsWrapper = (0, _react2.css)({
|
|
23
23
|
display: 'flex'
|
|
@@ -20,7 +20,7 @@ function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0,
|
|
|
20
20
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /**
|
|
21
21
|
* @jsxRuntime classic
|
|
22
22
|
* @jsx jsx
|
|
23
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
23
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
24
24
|
var toolbarComponentsWrapper = (0, _react2.css)((0, _defineProperty2.default)({
|
|
25
25
|
display: 'flex'
|
|
26
26
|
}, "@media (max-width: ".concat(_editorSharedStyles.akEditorMobileMaxWidth, "px)"), {
|
|
@@ -23,7 +23,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
23
23
|
* @jsx jsx
|
|
24
24
|
*/
|
|
25
25
|
|
|
26
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
26
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
27
27
|
|
|
28
28
|
var toolbar = (0, _react2.css)({
|
|
29
29
|
width: '100%',
|
|
@@ -17,7 +17,7 @@ function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0,
|
|
|
17
17
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); } /**
|
|
18
18
|
* @jsxRuntime classic
|
|
19
19
|
* @jsx jsx
|
|
20
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
20
|
+
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
21
21
|
var pulseBackground = (0, _react2.keyframes)({
|
|
22
22
|
'50%': {
|
|
23
23
|
backgroundColor: "var(--ds-blanket-danger, #EF5C4814)"
|
|
@@ -5,7 +5,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
5
5
|
*/
|
|
6
6
|
import { useCallback, useMemo, useRef, Fragment } from 'react';
|
|
7
7
|
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
9
9
|
import { jsx } from '@emotion/react';
|
|
10
10
|
import isEqual from 'lodash/isEqual';
|
|
11
11
|
// eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
|
package/dist/es2019/editor.js
CHANGED
|
@@ -9,7 +9,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
9
9
|
*/
|
|
10
10
|
import React from 'react';
|
|
11
11
|
|
|
12
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
12
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
13
13
|
import { jsx } from '@emotion/react';
|
|
14
14
|
import { ComposableEditor } from './composable-editor';
|
|
15
15
|
import useUniversalPreset from './presets/useUniversalPreset';
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
6
|
|
|
7
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
7
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
8
8
|
import { css, jsx } from '@emotion/react';
|
|
9
9
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
10
10
|
import { clickAreaClickHandler } from '../click-area-helper';
|
|
@@ -5,7 +5,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
5
5
|
*/
|
|
6
6
|
import React from 'react';
|
|
7
7
|
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
9
9
|
import { jsx } from '@emotion/react';
|
|
10
10
|
import { dropdown } from './styles';
|
|
11
11
|
// Ignored via go/ees005
|
|
@@ -5,7 +5,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
5
5
|
*/
|
|
6
6
|
import React, { Fragment } from 'react';
|
|
7
7
|
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
9
9
|
import { css, jsx } from '@emotion/react';
|
|
10
10
|
import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
|
|
11
11
|
import EditorContentContainer from '../EditorContentContainer/EditorContentContainer';
|
|
@@ -139,6 +139,9 @@ function RenderWithPluginState({
|
|
|
139
139
|
renderChrome,
|
|
140
140
|
editorAPI
|
|
141
141
|
}) {
|
|
142
|
+
'use no memo';
|
|
143
|
+
|
|
144
|
+
// renderChrome should be changed to called as a component not a function
|
|
142
145
|
const maxContentSizeReached = useSharedPluginStateWithSelector(editorAPI, ['maxContentSize'], states => {
|
|
143
146
|
var _states$maxContentSiz;
|
|
144
147
|
return states === null || states === void 0 ? void 0 : (_states$maxContentSiz = states.maxContentSizeState) === null || _states$maxContentSiz === void 0 ? void 0 : _states$maxContentSiz.maxContentSizeReached;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import React, { useCallback, useEffect, useMemo, useState } from 'react';
|
|
6
6
|
|
|
7
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
7
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
8
8
|
import { css, jsx } from '@emotion/react';
|
|
9
9
|
import classnames from 'classnames';
|
|
10
10
|
import { useIntl } from 'react-intl-next';
|
|
@@ -6,7 +6,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
6
6
|
|
|
7
7
|
import React, { useEffect, useState } from 'react';
|
|
8
8
|
|
|
9
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
9
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
10
10
|
import { css, jsx } from '@emotion/react';
|
|
11
11
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
12
12
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
6
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
7
7
|
import { css, jsx } from '@emotion/react';
|
|
8
8
|
const beforePrimaryToolbarPluginWrapperStyles = css({
|
|
9
9
|
display: 'flex',
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
6
|
|
|
7
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
7
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
8
8
|
import { css, jsx } from '@emotion/react';
|
|
9
9
|
// Pre-computed static styles for first- and second-child wrappers.
|
|
10
10
|
// These contain no runtime logic and are safe for static-emotion mode.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import React, { useEffect, useMemo, useRef, useState } from 'react';
|
|
6
6
|
|
|
7
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
7
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
8
8
|
import { jsx } from '@emotion/react';
|
|
9
9
|
import { browser as browserLegacy, getBrowserInfo } from '@atlaskit/editor-common/browser';
|
|
10
10
|
import { useSharedPluginStateWithSelector } from '@atlaskit/editor-common/hooks';
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
import React, { useImperativeHandle, useRef } from 'react';
|
|
7
7
|
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
9
9
|
import { css, jsx, useTheme } from '@emotion/react';
|
|
10
10
|
import classnames from 'classnames';
|
|
11
11
|
import { injectIntl } from 'react-intl-next';
|
|
@@ -13,7 +13,6 @@ import { decisionListSelector, taskListSelector } from '@atlaskit/adf-schema';
|
|
|
13
13
|
import { fullPageMessages as messages } from '@atlaskit/editor-common/messages';
|
|
14
14
|
import { akEditorGutterPaddingDynamic, akEditorGutterPaddingReduced, akEditorFullPageNarrowBreakout } from '@atlaskit/editor-shared-styles';
|
|
15
15
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
16
|
-
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
17
16
|
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
18
17
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
19
18
|
// Ignored via go/ees005
|
|
@@ -214,6 +213,7 @@ const Content = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
|
214
213
|
const contentAreaRef = useRef(null);
|
|
215
214
|
const containerRef = useRef(null);
|
|
216
215
|
const allowScrollGutter = (_props$editorAPI = props.editorAPI) === null || _props$editorAPI === void 0 ? void 0 : (_props$editorAPI$base = _props$editorAPI.base) === null || _props$editorAPI$base === void 0 ? void 0 : (_props$editorAPI$base2 = _props$editorAPI$base.sharedState.currentState()) === null || _props$editorAPI$base2 === void 0 ? void 0 : _props$editorAPI$base2.allowScrollGutter;
|
|
216
|
+
const contentAreaMaxWidth = getTotalPadding() + (!fullWidthMode ? maxWidthMode ? akEditorUltraWideLayoutWidth : theme.layoutMaxWidth : akEditorFullWidthLayoutWidth);
|
|
217
217
|
useImperativeHandle(ref, () => ({
|
|
218
218
|
get scrollContainer() {
|
|
219
219
|
return scrollContainerRef.current;
|
|
@@ -253,11 +253,7 @@ const Content = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
|
253
253
|
// for breakout resizing, there's no need to restrict the width of codeblocks as they're always wrapped in a breakout mark
|
|
254
254
|
expValEqualsNoExposure('platform_editor_breakout_resizing', 'isEnabled', true) ? editorContentAreaContainerStyleExcludeCodeBlockNew : editorContentAreaContainerStyleNew, fg('platform_editor_nested_dnd_styles_changes') && editorContentAreaContainerNestedDndStyle, !fg('platform_editor_controls_no_toolbar_space') && editorExperiment('platform_editor_controls', 'variant1') && contentAreaReducedHeaderSpace, !fg('platform_editor_controls_no_toolbar_space') && props.isEditorToolbarHidden && editorExperiment('platform_editor_controls', 'variant1') && contentAreaReservedPrimaryToolbarSpace],
|
|
255
255
|
style: {
|
|
256
|
-
'--ak-editor-content-area-max-width':
|
|
257
|
-
// @ts-ignore
|
|
258
|
-
`${akEditorUltraWideLayoutWidth + getTotalPadding()}px` :
|
|
259
|
-
// @ts-ignore
|
|
260
|
-
`${theme.layoutMaxWidth + getTotalPadding()}px` : `${akEditorFullWidthLayoutWidth + getTotalPadding()}px`
|
|
256
|
+
'--ak-editor-content-area-max-width': `${contentAreaMaxWidth}px`
|
|
261
257
|
}
|
|
262
258
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
|
|
263
259
|
,
|
|
@@ -265,7 +261,8 @@ const Content = /*#__PURE__*/React.forwardRef((props, ref) => {
|
|
|
265
261
|
"data-editor-editable-content": true,
|
|
266
262
|
role: "region",
|
|
267
263
|
"aria-label": props.intl.formatMessage(messages.editableContentLabel),
|
|
268
|
-
ref: contentAreaRef
|
|
264
|
+
ref: contentAreaRef,
|
|
265
|
+
"data-vc": "editor-content-area-region"
|
|
269
266
|
}, jsx("div", {
|
|
270
267
|
css: [editorContentGutterStyles,
|
|
271
268
|
// eslint-disable-next-line @atlaskit/platform/no-preconditioning
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
|
|
6
6
|
import React, { useEffect, useCallback, useState } from 'react';
|
|
7
7
|
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
9
9
|
import { jsx } from '@emotion/react';
|
|
10
10
|
import { injectIntl } from 'react-intl-next';
|
|
11
11
|
import { ContextPanelConsumer } from '@atlaskit/editor-common/context-panel';
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
6
|
|
|
7
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
7
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
8
8
|
import { css, jsx } from '@emotion/react';
|
|
9
9
|
import { akEditorFloatingDialogZIndex, akEditorSwoopCubicBezier } from '@atlaskit/editor-shared-styles';
|
|
10
10
|
import { MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT } from './MainToolbar';
|
|
@@ -5,7 +5,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
5
5
|
*/
|
|
6
6
|
import React, { PureComponent } from 'react';
|
|
7
7
|
|
|
8
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- Ignored via go/DSP-18766; jsx required at runtime for @jsxRuntime classic
|
|
9
9
|
import { jsx } from '@emotion/react';
|
|
10
10
|
import { injectIntl } from 'react-intl-next';
|
|
11
11
|
import { messages } from './messages';
|