@atlaskit/editor-core 219.9.15 → 219.9.17
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 +17 -0
- package/dist/cjs/composable-editor/core-editor.js +7 -10
- package/dist/cjs/composable-editor/editor-internal-compiled.compiled.css +3 -0
- package/dist/cjs/composable-editor/editor-internal-compiled.js +27 -0
- package/dist/cjs/composable-editor/editor-internal-emotion.js +31 -0
- package/dist/cjs/composable-editor/editor-internal.js +17 -20
- package/dist/cjs/ui/Appearance/FullPage/FullPageToolbar.js +2 -15
- package/dist/cjs/ui/Appearance/FullPage/MainToolbar-compiled.js +46 -0
- package/dist/cjs/ui/Appearance/FullPage/{FullPageToolbar-emotion.js → MainToolbar-emotion.js} +25 -24
- package/dist/cjs/ui/Appearance/FullPage/MainToolbar.js +14 -68
- package/dist/cjs/ui/Appearance/FullPage/MainToolbarWrapper-compiled.compiled.css +14 -0
- package/dist/cjs/ui/Appearance/FullPage/MainToolbarWrapper-compiled.js +35 -0
- package/dist/cjs/ui/Appearance/FullPage/MainToolbarWrapper-emotion.js +70 -0
- package/dist/cjs/ui/Appearance/FullPage/MainToolbarWrapper.js +7 -61
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer-compiled.compiled.css +6 -0
- package/dist/cjs/ui/EditorContentContainer/EditorContentContainer-compiled.js +1 -1
- package/dist/cjs/ui/EditorContentContainer/styles/layout.js +5 -7
- package/dist/cjs/version-wrapper.js +1 -1
- package/dist/es2019/composable-editor/core-editor.js +4 -11
- package/dist/es2019/composable-editor/editor-internal-compiled.compiled.css +3 -0
- package/dist/es2019/composable-editor/editor-internal-compiled.js +18 -0
- package/dist/es2019/composable-editor/editor-internal-emotion.js +23 -0
- package/dist/es2019/composable-editor/editor-internal.js +12 -21
- package/dist/es2019/ui/Appearance/FullPage/FullPageToolbar.js +1 -8
- package/dist/es2019/ui/Appearance/FullPage/{FullPageToolbar-compiled.js → MainToolbar-compiled.js} +19 -16
- package/dist/es2019/ui/Appearance/FullPage/{FullPageToolbar-emotion.js → MainToolbar-emotion.js} +20 -19
- package/dist/es2019/ui/Appearance/FullPage/MainToolbar.js +7 -70
- package/dist/es2019/ui/Appearance/FullPage/MainToolbarWrapper-compiled.compiled.css +14 -0
- package/dist/es2019/ui/Appearance/FullPage/MainToolbarWrapper-compiled.js +30 -0
- package/dist/es2019/ui/Appearance/FullPage/MainToolbarWrapper-emotion.js +65 -0
- package/dist/es2019/ui/Appearance/FullPage/MainToolbarWrapper.js +5 -63
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer-compiled.compiled.css +6 -0
- package/dist/es2019/ui/EditorContentContainer/EditorContentContainer-compiled.js +1 -1
- package/dist/es2019/ui/EditorContentContainer/styles/layout.js +5 -7
- package/dist/es2019/version-wrapper.js +1 -1
- package/dist/esm/composable-editor/core-editor.js +4 -11
- package/dist/esm/composable-editor/editor-internal-compiled.compiled.css +3 -0
- package/dist/esm/composable-editor/editor-internal-compiled.js +19 -0
- package/dist/esm/composable-editor/editor-internal-emotion.js +24 -0
- package/dist/esm/composable-editor/editor-internal.js +14 -21
- package/dist/esm/ui/Appearance/FullPage/FullPageToolbar.js +1 -14
- package/dist/esm/ui/Appearance/FullPage/{FullPageToolbar-compiled.js → MainToolbar-compiled.js} +19 -16
- package/dist/esm/ui/Appearance/FullPage/{FullPageToolbar-emotion.js → MainToolbar-emotion.js} +21 -20
- package/dist/esm/ui/Appearance/FullPage/MainToolbar.js +13 -65
- package/dist/esm/ui/Appearance/FullPage/MainToolbarWrapper-compiled.compiled.css +14 -0
- package/dist/esm/ui/Appearance/FullPage/MainToolbarWrapper-compiled.js +29 -0
- package/dist/esm/ui/Appearance/FullPage/MainToolbarWrapper-emotion.js +62 -0
- package/dist/esm/ui/Appearance/FullPage/MainToolbarWrapper.js +7 -60
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer-compiled.compiled.css +6 -0
- package/dist/esm/ui/EditorContentContainer/EditorContentContainer-compiled.js +1 -1
- package/dist/esm/ui/EditorContentContainer/styles/layout.js +5 -7
- package/dist/esm/version-wrapper.js +1 -1
- package/dist/types/composable-editor/core-editor.d.ts +2 -2
- package/dist/types/composable-editor/editor-internal-compiled.d.ts +14 -0
- package/dist/types/composable-editor/editor-internal-emotion.d.ts +14 -0
- package/dist/types/composable-editor/editor-internal.d.ts +1 -0
- package/dist/types/ui/Appearance/FullPage/{FullPageToolbar-compiled.d.ts → MainToolbar-compiled.d.ts} +10 -9
- package/dist/{types-ts4.5/ui/Appearance/FullPage/FullPageToolbar-emotion.d.ts → types/ui/Appearance/FullPage/MainToolbar-emotion.d.ts} +10 -9
- package/dist/types/ui/Appearance/FullPage/MainToolbar.d.ts +10 -6
- package/dist/types/ui/Appearance/FullPage/MainToolbarWrapper-compiled.d.ts +19 -0
- package/dist/types/ui/Appearance/FullPage/MainToolbarWrapper-emotion.d.ts +19 -0
- package/dist/types/ui/Appearance/FullPage/MainToolbarWrapper.d.ts +3 -14
- package/dist/types-ts4.5/composable-editor/core-editor.d.ts +2 -2
- package/dist/types-ts4.5/composable-editor/editor-internal-compiled.d.ts +14 -0
- package/dist/types-ts4.5/composable-editor/editor-internal-emotion.d.ts +14 -0
- package/dist/types-ts4.5/composable-editor/editor-internal.d.ts +1 -0
- package/dist/types-ts4.5/ui/Appearance/FullPage/{FullPageToolbar-compiled.d.ts → MainToolbar-compiled.d.ts} +10 -9
- package/dist/{types/ui/Appearance/FullPage/FullPageToolbar-emotion.d.ts → types-ts4.5/ui/Appearance/FullPage/MainToolbar-emotion.d.ts} +10 -9
- package/dist/types-ts4.5/ui/Appearance/FullPage/MainToolbar.d.ts +10 -6
- package/dist/types-ts4.5/ui/Appearance/FullPage/MainToolbarWrapper-compiled.d.ts +19 -0
- package/dist/types-ts4.5/ui/Appearance/FullPage/MainToolbarWrapper-emotion.d.ts +19 -0
- package/dist/types-ts4.5/ui/Appearance/FullPage/MainToolbarWrapper.d.ts +3 -14
- package/package.json +3 -3
- package/dist/cjs/ui/Appearance/FullPage/FullPageToolbar-compiled.js +0 -45
- /package/dist/cjs/ui/Appearance/FullPage/{FullPageToolbar-compiled.compiled.css → MainToolbar-compiled.compiled.css} +0 -0
- /package/dist/es2019/ui/Appearance/FullPage/{FullPageToolbar-compiled.compiled.css → MainToolbar-compiled.compiled.css} +0 -0
- /package/dist/esm/ui/Appearance/FullPage/{FullPageToolbar-compiled.compiled.css → MainToolbar-compiled.compiled.css} +0 -0
|
@@ -1,67 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
-
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
4
3
|
Object.defineProperty(exports, "__esModule", {
|
|
5
4
|
value: true
|
|
6
5
|
});
|
|
7
6
|
exports.MainToolbarWrapper = void 0;
|
|
8
|
-
var
|
|
9
|
-
var
|
|
10
|
-
var
|
|
11
|
-
var
|
|
12
|
-
var
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
* @jsx jsx
|
|
16
|
-
*/
|
|
17
|
-
|
|
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
|
-
|
|
20
|
-
// Base styles that don't depend on feature flags
|
|
21
|
-
var baseToolbarStyles = (0, _react2.css)({
|
|
22
|
-
position: 'relative',
|
|
23
|
-
alignItems: 'center',
|
|
24
|
-
boxShadow: 'none',
|
|
25
|
-
borderBottom: "var(--ds-border-width, 1px)".concat(" solid ", "var(--ds-border, #0B120E24)"),
|
|
26
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values
|
|
27
|
-
transition: "box-shadow 200ms ".concat(_editorSharedStyles.akEditorSwoopCubicBezier),
|
|
28
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values
|
|
29
|
-
zIndex: _editorSharedStyles.akEditorFloatingDialogZIndex,
|
|
30
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values
|
|
31
|
-
display: 'flex',
|
|
32
|
-
height: 'var(--ak-editor-fullpage-toolbar-height)',
|
|
33
|
-
flexShrink: 0,
|
|
34
|
-
backgroundColor: "var(--ds-surface, #FFFFFF)",
|
|
35
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
36
|
-
'& object': {
|
|
37
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-important-styles
|
|
38
|
-
height: '0 !important'
|
|
39
|
-
}
|
|
40
|
-
});
|
|
41
|
-
var flexibleIconSize = (0, _react2.css)({
|
|
42
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
43
|
-
'& span svg': {
|
|
44
|
-
maxWidth: '100%'
|
|
45
|
-
}
|
|
46
|
-
});
|
|
47
|
-
// box-shadow is overriden by the mainToolbar
|
|
48
|
-
var mainToolbarWithKeyline = (0, _react2.css)({
|
|
49
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
50
|
-
boxShadow: "var(--ds-shadow-overflow, 0px 0px 8px #1E1F2128, 0px 0px 1px #1E1F211e)"
|
|
51
|
-
});
|
|
52
|
-
var mainToolbarTwoLineStyle = (0, _react2.css)((0, _defineProperty2.default)({}, "@media (max-width: ".concat(_MainToolbar.MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT, "px)"), {
|
|
53
|
-
flexWrap: 'wrap',
|
|
54
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
55
|
-
height: "calc(var(--ak-editor-fullpage-toolbar-height) * 2)"
|
|
56
|
-
}));
|
|
57
|
-
var MainToolbarWrapper = exports.MainToolbarWrapper = function MainToolbarWrapper(_ref) {
|
|
58
|
-
var showKeyline = _ref.showKeyline,
|
|
59
|
-
twoLineEditorToolbar = _ref.twoLineEditorToolbar,
|
|
60
|
-
children = _ref.children,
|
|
61
|
-
testId = _ref['data-testid'];
|
|
62
|
-
return (0, _react2.jsx)("div", {
|
|
63
|
-
// eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage
|
|
64
|
-
css: [baseToolbarStyles, flexibleIconSize, showKeyline && mainToolbarWithKeyline, twoLineEditorToolbar && mainToolbarTwoLineStyle],
|
|
65
|
-
"data-testid": testId
|
|
66
|
-
}, children);
|
|
67
|
-
};
|
|
7
|
+
var _platformFeatureFlagsReact = require("@atlaskit/platform-feature-flags-react");
|
|
8
|
+
var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
|
|
9
|
+
var _MainToolbarWrapperCompiled = require("./MainToolbarWrapper-compiled");
|
|
10
|
+
var _MainToolbarWrapperEmotion = require("./MainToolbarWrapper-emotion");
|
|
11
|
+
var MainToolbarWrapper = exports.MainToolbarWrapper = (0, _platformFeatureFlagsReact.componentWithCondition)(function () {
|
|
12
|
+
return (0, _expValEquals.expValEquals)('platform_editor_core_non_ecc_static_css', 'isEnabled', true);
|
|
13
|
+
}, _MainToolbarWrapperCompiled.MainToolbarWrapperCompiled, _MainToolbarWrapperEmotion.MainToolbarWrapperEmotion);
|
|
@@ -606,6 +606,7 @@
|
|
|
606
606
|
._15pyjp4b .pm-table-wrapper>table>tbody>tr>th{vertical-align:top}
|
|
607
607
|
._15q4m0zr .ProseMirror [layout^=wrap-]+[layout^=wrap-]+div[class^=fabric-editor-align]{clear:both!important}
|
|
608
608
|
._15r21s89 .search-match-block.search-match-block-selected .loader-wrapper>a{box-shadow:0 0 0 4px var(--ds-background-accent-magenta-subtlest-pressed,#fcb6e1),0 0 0 5px var(--ds-background-accent-magenta-bolder-hovered,#943d73)}
|
|
609
|
+
._15sh1bp4 .ProseMirror [data-layout-section] [data-layout-column][data-valign=bottom]>[data-layout-content]{flex-direction:column}
|
|
609
610
|
._15t1i7a9 .pm-table-sticky-wrapper>table>tbody>tr>td{font-weight:var(--ds-font-weight-regular,400)}
|
|
610
611
|
._15uri7a9 .ak-editor-expand__title-input{font-weight:var(--ds-font-weight-regular,400)}
|
|
611
612
|
._15ve1gly .ProseMirror .danger .code-block .line-number-gutter{background-color:var(--ds-background-danger,#ffeceb)}
|
|
@@ -627,6 +628,7 @@
|
|
|
627
628
|
._16am1j28 .ProseMirror [data-layout-section].ak-editor-selected-node:not(.danger) [data-layout-column] ::-moz-selection{background-color:transparent}
|
|
628
629
|
._16atr4us .ak-editor-selected-node:not(.search-match-block)>.editor-mention-primitive.mention-self{box-shadow:0 0 0 1px var(--ds-border-selected,#1868db)}
|
|
629
630
|
._16d4idpf .ProseMirror .fabric-editor-indentation-mark:first-of-type:first-child h4:first-child:not(style){margin-top:0}
|
|
631
|
+
._16df1txw .ProseMirror [data-layout-section] [data-layout-column][data-valign=middle]>[data-layout-content]{display:flex}
|
|
630
632
|
._16e11mi1 .fabric-editor-breakout-mark:has([data-prosemirror-node-name=expand])>.pm-breakout-resize-handle-container--left{left:-25px}
|
|
631
633
|
._16fuidpf .ProseMirror .fabric-editor-indentation-mark:first-of-type:first-child p style:first-child+*{margin-top:0}
|
|
632
634
|
._16fx73ad .ProseMirror [data-layout-section]{cursor:default}
|
|
@@ -1835,6 +1837,7 @@
|
|
|
1835
1837
|
._1ybf1nka .search-match-block [data-smart-link-container=true]{box-shadow:inset 0 0 0 1px var(--ds-border-accent-magenta,#cd519d),inset 0 0 0 5px var(--ds-background-accent-magenta-subtler,#fdd0ec)}
|
|
1836
1838
|
._1ybwjocv .search-match-text.selected-search-match{background-color:var(--ds-background-accent-magenta-subtlest-pressed,#fcb6e1)!important}
|
|
1837
1839
|
._1yd8i8nm .pm-table-wrapper>table th:not(.danger) .code-block:not(.danger) .line-number-gutter{background-color:var(--ds-background-neutral,#0515240f)}
|
|
1840
|
+
._1ydd1bp4 .ProseMirror [data-layout-section] [data-layout-column][data-valign=middle]>[data-layout-content]{flex-direction:column}
|
|
1838
1841
|
._1ydjglyw .ProseMirror .ak-editor-panel .ak-editor-panel__icon{-webkit-user-select:none}
|
|
1839
1842
|
._1ydu1up9 .search-match-block .loader-wrapper>a{box-shadow:0 0 0 4px var(--ds-background-accent-magenta-subtler,#fdd0ec),0 0 0 5px var(--ds-border-accent-magenta,#cd519d)}
|
|
1840
1843
|
._1yg7azsu .ak-editor-selected-node>.editor-mention-primitive.mention-self{color:var(--ds-text-subtle,#505258)}
|
|
@@ -2265,6 +2268,7 @@
|
|
|
2265
2268
|
._as951j5o .ProseMirror h2 strong{font-weight:var(--editor-font-ugc-token-weight-heading-bold)}
|
|
2266
2269
|
._at5bidpf .ProseMirror .code-block{margin-right:0}
|
|
2267
2270
|
._atbw16ux .ProseMirror [data-layout-section].ak-editor-selected-node:not(.danger) [data-layout-column]:after{content:"\00a0"}
|
|
2271
|
+
._av0z1h6o .ProseMirror [data-layout-section] [data-layout-column][data-valign=middle]>[data-layout-content]{justify-content:center}
|
|
2268
2272
|
._awp7f705 [layout=wrap-left]+.ProseMirror-gapcursor+span+[layout=wrap-right]:after{content:" "}
|
|
2269
2273
|
._ay2w187o{--local-background-disabled:var(--ds-background-disabled,#0515240f)}
|
|
2270
2274
|
._ay4r7mnp .ak-editor-expand__content .expand-content-wrapper{clip:rect(1px,1px,1px,1px)}
|
|
@@ -2752,6 +2756,7 @@
|
|
|
2752
2756
|
._ksblidpf .fabric-editor-alignment:first-of-type:first-child p:first-child:not(style){margin-top:0}
|
|
2753
2757
|
._ksg217vv .ProseMirror h1>.media-inline-image-wrapper{transform:translateY(-3px)}
|
|
2754
2758
|
._ktc91e5h .pm-table-sticky-wrapper>table th{text-align:left}
|
|
2759
|
+
._ktyiesu3 .ProseMirror [data-layout-section] [data-layout-column][data-valign=bottom]>[data-layout-content]{justify-content:flex-end}
|
|
2755
2760
|
._kw4vglyw .ProseMirror .ak-editor-panel .ak-editor-panel__icon{ms-user-select:none}
|
|
2756
2761
|
._kxdfidpf .ProseMirror .ak-editor-selected-node .emoji-common-emoji-image:before{left:0}
|
|
2757
2762
|
._ky807vkz [data-prosemirror-node-name=decisionItem]>[data-decision-wrapper]>[data-component=icon]{width:1pc}
|
|
@@ -3304,6 +3309,7 @@
|
|
|
3304
3309
|
._wg06idpf [data-prosemirror-node-name=date] .date-lozenger-container span{margin-top:0}
|
|
3305
3310
|
._wgjz10yn .ProseMirror h3>:is(a,span[data-mark-type=border]) .media-inline-image-wrapper{height:25px}
|
|
3306
3311
|
._wgub1j28 .ProseMirror span.pm-placeholder.ak-editor-selected-node ::selection{background-color:transparent}
|
|
3312
|
+
._whzv1txw .ProseMirror [data-layout-section] [data-layout-column][data-valign=bottom]>[data-layout-content]{display:flex}
|
|
3307
3313
|
._wi0pglyw .ak-editor-sync-block__label{box-shadow:none}
|
|
3308
3314
|
._wi4l1j28 .dateView-content-wrap.ak-editor-selected-node .date-lozenger-container>span ::-moz-selection{background-color:transparent}
|
|
3309
3315
|
._wiz6tlke .embedCardView-content-wrap .loader-wrapper>div{cursor:pointer}
|
|
@@ -209,7 +209,7 @@ var editorContentStyles = {
|
|
|
209
209
|
hyperLinkFloatingToolbarStyles: "_14olidpf _1499idpf _w11vidpf _162zidpf",
|
|
210
210
|
indentationStyles: "_10pe1ul9 _ygai1wqb _1czel1r9 _126j68cl _cnga1w81 _14uamgvx",
|
|
211
211
|
InlineNodeViewSharedStyles: "_omad1nu9 _64cs1rj4 _fukv1q9c _1rhx1jtm _1bbqglyw _1v741j28 _17xw1j28 _kdjsglyw _6q1jryon",
|
|
212
|
-
layoutBaseStyles: "_o2as1f61 _3t6qixl8 _19z7kb7n _e6qzkb7n _c9uhf1ug _19eyia51 _1r5q12b0 _cx2xutpp _2wy7h2mm _14hwidpf _1ed8usvi _navqidpf _84fsidpf _gt3aidpf _13jnidpf _1iuzidpf _15nuidpf _4fc0idpf _cs4didpf _1iwn1osq _10q81kdv _i6821hrf _16fxtlke _ez6hglyw _17igidpf _1ayiyh40 _x1d2idpf _9m42yh40",
|
|
212
|
+
layoutBaseStyles: "_o2as1f61 _3t6qixl8 _19z7kb7n _e6qzkb7n _c9uhf1ug _19eyia51 _1r5q12b0 _cx2xutpp _2wy7h2mm _14hwidpf _1ed8usvi _navqidpf _84fsidpf _gt3aidpf _13jnidpf _1iuzidpf _15nuidpf _4fc0idpf _cs4didpf _1iwn1osq _10q81kdv _i6821hrf _whzv1txw _16df1txw _15sh1bp4 _1ydd1bp4 _av0z1h6o _ktyiesu3 _16fxtlke _ez6hglyw _17igidpf _1ayiyh40 _x1d2idpf _9m42yh40",
|
|
213
213
|
layoutBaseStylesAdvanced: "_19eyidpf",
|
|
214
214
|
layoutBaseStylesFixesUnderNestedDnDFG: "_o2as17in _1v5d1crf _5jfcgktf _3mtd1crf _c82wgktf",
|
|
215
215
|
layoutBaseStylesFixesUnderNestedDnDFGExcludingBodiedSync: "_o2as17in _157i1f61 _1v5d1crf _5jfcgktf _3mtd1crf _c82wgktf",
|
|
@@ -506,22 +506,20 @@ var layoutBaseStyles = exports.layoutBaseStyles = (0, _react.css)({
|
|
|
506
506
|
clear: 'both'
|
|
507
507
|
}
|
|
508
508
|
},
|
|
509
|
+
// Keep the editable content wrapper stretched so blank column space remains a text hit area.
|
|
510
|
+
// Apply vertical alignment to the wrapper contents rather than shrinking the wrapper itself.
|
|
509
511
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
510
|
-
'&[data-valign="middle"], &[data-valign="bottom"]': {
|
|
512
|
+
'&[data-valign="middle"] > [data-layout-content], &[data-valign="bottom"] > [data-layout-content]': {
|
|
511
513
|
display: 'flex',
|
|
512
514
|
flexDirection: 'column'
|
|
513
515
|
},
|
|
514
516
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
515
|
-
'&[data-valign="middle"]': {
|
|
517
|
+
'&[data-valign="middle"] > [data-layout-content]': {
|
|
516
518
|
justifyContent: 'center'
|
|
517
519
|
},
|
|
518
520
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
519
|
-
'&[data-valign="bottom"]': {
|
|
521
|
+
'&[data-valign="bottom"] > [data-layout-content]': {
|
|
520
522
|
justifyContent: 'flex-end'
|
|
521
|
-
},
|
|
522
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors
|
|
523
|
-
'&[data-valign="middle"] > [data-layout-content], &[data-valign="bottom"] > [data-layout-content]': {
|
|
524
|
-
height: 'auto'
|
|
525
523
|
}
|
|
526
524
|
}
|
|
527
525
|
}
|
|
@@ -1,12 +1,5 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
|
|
3
|
-
* @jsxRuntime classic
|
|
4
|
-
* @jsx jsx
|
|
5
|
-
*/
|
|
6
|
-
import { useCallback, useMemo, useRef, Fragment } from 'react';
|
|
7
|
-
|
|
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
|
-
import { jsx } from '@emotion/react';
|
|
2
|
+
import React, { useCallback, useMemo, useRef, Fragment } from 'react';
|
|
10
3
|
import isEqual from 'lodash/isEqual';
|
|
11
4
|
// eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
|
|
12
5
|
import uuid from 'uuid/v4';
|
|
@@ -93,7 +86,7 @@ function Editor(passedProps) {
|
|
|
93
86
|
}
|
|
94
87
|
}, [onSaveFromProps]);
|
|
95
88
|
const isFullPageAppearance = Boolean(props.appearance && ['full-page', 'full-width', ...(editorExperiment('platform_synced_block', true) ? ['max'] : [])].includes(props.appearance));
|
|
96
|
-
return
|
|
89
|
+
return /*#__PURE__*/React.createElement(Fragment, null, isFullPageAppearance ? /*#__PURE__*/React.createElement(EditorINPMetrics, null) : null, /*#__PURE__*/React.createElement(EditorInternal, {
|
|
97
90
|
props: props,
|
|
98
91
|
handleAnalyticsEvent: handleAnalyticsEvent,
|
|
99
92
|
createAnalyticsEvent: createAnalyticsEvent,
|
|
@@ -132,11 +125,11 @@ export function CoreEditor(props) {
|
|
|
132
125
|
};
|
|
133
126
|
}, [props.appearance]);
|
|
134
127
|
const memodEditorFeatureFlags = useMemoEditorFeatureFlags(props.featureFlags);
|
|
135
|
-
return
|
|
128
|
+
return /*#__PURE__*/React.createElement(FabricEditorAnalyticsContext
|
|
136
129
|
// @ts-expect-error Type 'string' is not assignable to type '"editorCore" | "renderer"'.
|
|
137
130
|
, {
|
|
138
131
|
data: data
|
|
139
|
-
},
|
|
132
|
+
}, /*#__PURE__*/React.createElement(Editor
|
|
140
133
|
// Ignored via go/ees005
|
|
141
134
|
// eslint-disable-next-line react/jsx-props-no-spreading
|
|
142
135
|
, _extends({}, props, {
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/* editor-internal-compiled.tsx generated by @compiled/babel-plugin v0.39.1 */
|
|
2
|
+
/**
|
|
3
|
+
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
|
+
* Used via `componentWithCondition` in `editor-internal.tsx`.
|
|
5
|
+
*
|
|
6
|
+
* Cleanup: delete this file once the experiment has shipped.
|
|
7
|
+
*/
|
|
8
|
+
import "./editor-internal-compiled.compiled.css";
|
|
9
|
+
import * as React from 'react';
|
|
10
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
11
|
+
const editorContainerCompiledStyles = {
|
|
12
|
+
root: "_kqswh2mm _1bsb1osq _4t3i1osq"
|
|
13
|
+
};
|
|
14
|
+
export const EditorInternalContainerCompiled = ({
|
|
15
|
+
children
|
|
16
|
+
}) => /*#__PURE__*/React.createElement("div", {
|
|
17
|
+
className: ax([editorContainerCompiledStyles.root])
|
|
18
|
+
}, children);
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
4
|
+
*/
|
|
5
|
+
/**
|
|
6
|
+
* Emotion fallback branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
7
|
+
* Used via `componentWithCondition` in `editor-internal.tsx`.
|
|
8
|
+
*
|
|
9
|
+
* Cleanup: delete this file once the experiment has shipped.
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- intentional: emotion fallback for compiled migration
|
|
13
|
+
import { css, jsx } from '@emotion/react';
|
|
14
|
+
const editorContainerEmotionStyles = css({
|
|
15
|
+
position: 'relative',
|
|
16
|
+
width: '100%',
|
|
17
|
+
height: '100%'
|
|
18
|
+
});
|
|
19
|
+
export const EditorInternalContainerEmotion = ({
|
|
20
|
+
children
|
|
21
|
+
}) => jsx("div", {
|
|
22
|
+
css: editorContainerEmotionStyles
|
|
23
|
+
}, children);
|
|
@@ -1,13 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
* @jsxRuntime classic
|
|
3
|
-
* @jsx jsx
|
|
4
|
-
*/
|
|
5
|
-
import { Fragment, memo } from 'react';
|
|
6
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
7
|
-
import { css, jsx } from '@emotion/react';
|
|
1
|
+
import React, { Fragment, memo } from 'react';
|
|
8
2
|
import { ACTION, ACTION_SUBJECT } from '@atlaskit/editor-common/analytics';
|
|
9
3
|
import { usePortalProvider } from '@atlaskit/editor-common/portal';
|
|
10
4
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
5
|
+
import { componentWithCondition } from '@atlaskit/platform-feature-flags-react';
|
|
11
6
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
12
7
|
import ErrorBoundary from '../create-editor/ErrorBoundary';
|
|
13
8
|
import ReactEditorViewNext from '../create-editor/ReactEditorView';
|
|
@@ -16,12 +11,10 @@ import { IntlProviderIfMissingWrapper } from '../ui/IntlProviderIfMissingWrapper
|
|
|
16
11
|
import { createFeatureFlagsFromProps } from '../utils/feature-flags-from-props';
|
|
17
12
|
import { RenderTracking } from '../utils/performance/components/RenderTracking';
|
|
18
13
|
import { BaseThemeWrapper } from './BaseThemeWrapper';
|
|
14
|
+
import { EditorInternalContainerCompiled } from './editor-internal-compiled';
|
|
15
|
+
import { EditorInternalContainerEmotion } from './editor-internal-emotion';
|
|
19
16
|
import { getBaseFontSize } from './utils/getBaseFontSize';
|
|
20
|
-
const
|
|
21
|
-
position: 'relative',
|
|
22
|
-
width: '100%',
|
|
23
|
-
height: '100%'
|
|
24
|
-
});
|
|
17
|
+
const EditorInternalContainerMigration = componentWithCondition(() => expValEquals('platform_editor_core_non_ecc_static_css', 'isEnabled', true), EditorInternalContainerCompiled, EditorInternalContainerEmotion);
|
|
25
18
|
const DEFAULT_VALUE_PROP_TO_IGNORE = ['defaultValue'];
|
|
26
19
|
|
|
27
20
|
/**
|
|
@@ -55,23 +48,21 @@ export const EditorInternal = /*#__PURE__*/memo(({
|
|
|
55
48
|
const [portalProviderAPI, PortalRenderer] = usePortalProvider();
|
|
56
49
|
const [nodeViewPortalProviderAPI, NodeViewPortalRenderer] = usePortalProvider();
|
|
57
50
|
const propsToIgnore = expValEquals('platform_editor_perf_lint_cleanup', 'isEnabled', true) ? DEFAULT_VALUE_PROP_TO_IGNORE : ['defaultValue'];
|
|
58
|
-
return
|
|
51
|
+
return /*#__PURE__*/React.createElement(Fragment, null, renderTrackingEnabled && /*#__PURE__*/React.createElement(RenderTracking, {
|
|
59
52
|
componentProps: props,
|
|
60
53
|
action: ACTION.RE_RENDERED,
|
|
61
54
|
actionSubject: ACTION_SUBJECT.EDITOR,
|
|
62
55
|
handleAnalyticsEvent: handleAnalyticsEvent,
|
|
63
56
|
propsToIgnore: propsToIgnore,
|
|
64
57
|
useShallow: useShallow
|
|
65
|
-
}),
|
|
58
|
+
}), /*#__PURE__*/React.createElement(ErrorBoundary, {
|
|
66
59
|
errorTracking: true,
|
|
67
60
|
createAnalyticsEvent: createAnalyticsEvent,
|
|
68
61
|
contextIdentifierProvider: props.contextIdentifierProvider,
|
|
69
62
|
featureFlags: featureFlags
|
|
70
|
-
},
|
|
71
|
-
css: editorContainerStyles
|
|
72
|
-
}, jsx(EditorContext, {
|
|
63
|
+
}, /*#__PURE__*/React.createElement(EditorInternalContainerMigration, null, /*#__PURE__*/React.createElement(EditorContext, {
|
|
73
64
|
editorActions: editorActions
|
|
74
|
-
},
|
|
65
|
+
}, /*#__PURE__*/React.createElement(IntlProviderIfMissingWrapper, null, /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(ReactEditorViewNext, {
|
|
75
66
|
editorProps: overriddenEditorProps,
|
|
76
67
|
createAnalyticsEvent: createAnalyticsEvent,
|
|
77
68
|
portalProviderAPI: portalProviderAPI,
|
|
@@ -93,9 +84,9 @@ export const EditorInternal = /*#__PURE__*/memo(({
|
|
|
93
84
|
editorAPI
|
|
94
85
|
}) => {
|
|
95
86
|
var _props$featureFlags, _props$featureFlags2;
|
|
96
|
-
return
|
|
87
|
+
return /*#__PURE__*/React.createElement(BaseThemeWrapper, {
|
|
97
88
|
baseFontSize: getBaseFontSize(props.appearance, props.contentMode)
|
|
98
|
-
},
|
|
89
|
+
}, /*#__PURE__*/React.createElement(AppearanceComponent, {
|
|
99
90
|
innerRef: editorRef,
|
|
100
91
|
editorAPI: editorAPI
|
|
101
92
|
// Ignored via go/ees005
|
|
@@ -136,5 +127,5 @@ export const EditorInternal = /*#__PURE__*/memo(({
|
|
|
136
127
|
preset: preset
|
|
137
128
|
}));
|
|
138
129
|
}
|
|
139
|
-
}),
|
|
130
|
+
}), /*#__PURE__*/React.createElement(PortalRenderer, null), /*#__PURE__*/React.createElement(NodeViewPortalRenderer, null)))))));
|
|
140
131
|
});
|
|
@@ -3,20 +3,13 @@ import { injectIntl } from 'react-intl';
|
|
|
3
3
|
import { ContextPanelConsumer } from '@atlaskit/editor-common/context-panel';
|
|
4
4
|
import { fullPageMessages as messages } from '@atlaskit/editor-common/messages';
|
|
5
5
|
import { ToolbarArrowKeyNavigationProvider } from '@atlaskit/editor-common/ui-menu';
|
|
6
|
-
import { componentWithCondition } from '@atlaskit/platform-feature-flags-react';
|
|
7
|
-
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
8
6
|
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
9
7
|
import { ToolbarPortalMountPoint, useToolbarPortal } from '../../Toolbar/ToolbarPortal';
|
|
10
8
|
import { ToolbarWithSizeDetector as Toolbar } from '../../Toolbar/ToolbarWithSizeDetector';
|
|
11
9
|
import { BeforePrimaryToolbarWrapper } from './BeforeWrapper';
|
|
12
10
|
import { MainToolbarForFirstChildWrapper, MainToolbarForSecondChildWrapper } from './CustomToolbarWrapper';
|
|
13
|
-
import {
|
|
14
|
-
import { CustomToolbarWrapperEmotion, MainToolbarIconBeforeEmotion, NonCustomToolbarWrapperEmotion } from './FullPageToolbar-emotion';
|
|
15
|
-
import { MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT } from './MainToolbar';
|
|
11
|
+
import { CustomToolbarWrapperMigration, MainToolbarIconBeforeMigration, MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT, NonCustomToolbarWrapperMigration } from './MainToolbar';
|
|
16
12
|
import { MainToolbarWrapper } from './MainToolbarWrapper';
|
|
17
|
-
const NonCustomToolbarWrapperMigration = componentWithCondition(() => expValEquals('platform_editor_core_non_ecc_static_css', 'isEnabled', true), NonCustomToolbarWrapperCompiled, NonCustomToolbarWrapperEmotion);
|
|
18
|
-
const MainToolbarIconBeforeMigration = componentWithCondition(() => expValEquals('platform_editor_core_non_ecc_static_css', 'isEnabled', true), MainToolbarIconBeforeCompiled, MainToolbarIconBeforeEmotion);
|
|
19
|
-
const CustomToolbarWrapperMigration = componentWithCondition(() => expValEquals('platform_editor_core_non_ecc_static_css', 'isEnabled', true), CustomToolbarWrapperCompiled, CustomToolbarWrapperEmotion);
|
|
20
13
|
export const EditorToolbar = /*#__PURE__*/React.memo(props => {
|
|
21
14
|
var _props$primaryToolbar, _useToolbarPortal, _props$customPrimaryT;
|
|
22
15
|
const [shouldSplitToolbar, setShouldSplitToolbar] = useState(false);
|
package/dist/es2019/ui/Appearance/FullPage/{FullPageToolbar-compiled.js → MainToolbar-compiled.js}
RENAMED
|
@@ -1,34 +1,37 @@
|
|
|
1
|
-
/*
|
|
1
|
+
/* MainToolbar-compiled.tsx generated by @compiled/babel-plugin v0.39.1 */
|
|
2
2
|
/**
|
|
3
3
|
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
|
-
* Used via `componentWithCondition` in `
|
|
4
|
+
* Used via `componentWithCondition` in `MainToolbar.tsx`.
|
|
5
5
|
*
|
|
6
6
|
* Cleanup: delete this file once the experiment has shipped.
|
|
7
7
|
*/
|
|
8
|
-
import "./
|
|
9
|
-
import * as React from 'react';
|
|
8
|
+
import "./MainToolbar-compiled.compiled.css";
|
|
10
9
|
import { ax, ix } from "@compiled/react/runtime";
|
|
11
|
-
|
|
10
|
+
import React from 'react';
|
|
11
|
+
|
|
12
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-imports
|
|
13
|
+
|
|
14
|
+
const nonCustomToolbarWrapperCompiledStyles = {
|
|
12
15
|
root: "_4cvr1h6o _1e0c1txw _16jlkb7n"
|
|
13
16
|
};
|
|
14
|
-
const mainToolbarIconBeforeCompiledStyles = {
|
|
15
|
-
root: "_19pkpxbi _2hwxpxbi _otyrpxbi _18u0pxbi _4t3ixy5q _1bsbxy5q _mlgzkb7n _tuuhkb7n"
|
|
16
|
-
};
|
|
17
|
-
const customToolbarCompiledStyles = {
|
|
18
|
-
root: "_4cvr1h6o _1e0c1txw"
|
|
19
|
-
};
|
|
20
17
|
export const NonCustomToolbarWrapperCompiled = ({
|
|
21
18
|
children
|
|
22
19
|
}) => /*#__PURE__*/React.createElement("div", {
|
|
23
|
-
className: ax([
|
|
20
|
+
className: ax([nonCustomToolbarWrapperCompiledStyles.root])
|
|
24
21
|
}, children);
|
|
25
|
-
|
|
22
|
+
const customToolbarWrapperCompiledStyles = {
|
|
23
|
+
root: "_4cvr1h6o _1e0c1txw"
|
|
24
|
+
};
|
|
25
|
+
export const CustomToolbarWrapperCompiled = ({
|
|
26
26
|
children
|
|
27
27
|
}) => /*#__PURE__*/React.createElement("div", {
|
|
28
|
-
className: ax([
|
|
28
|
+
className: ax([customToolbarWrapperCompiledStyles.root])
|
|
29
29
|
}, children);
|
|
30
|
-
|
|
30
|
+
const mainToolbarIconBeforeCompiledStyles = {
|
|
31
|
+
root: "_19pkpxbi _2hwxpxbi _otyrpxbi _18u0pxbi _4t3ixy5q _1bsbxy5q _mlgzkb7n _tuuhkb7n"
|
|
32
|
+
};
|
|
33
|
+
export const MainToolbarIconBeforeCompiled = ({
|
|
31
34
|
children
|
|
32
35
|
}) => /*#__PURE__*/React.createElement("div", {
|
|
33
|
-
className: ax([
|
|
36
|
+
className: ax([mainToolbarIconBeforeCompiledStyles.root])
|
|
34
37
|
}, children);
|
package/dist/es2019/ui/Appearance/FullPage/{FullPageToolbar-emotion.js → MainToolbar-emotion.js}
RENAMED
|
@@ -4,20 +4,35 @@
|
|
|
4
4
|
*/
|
|
5
5
|
/**
|
|
6
6
|
* Emotion fallback branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
7
|
-
* Used via `componentWithCondition` in `
|
|
7
|
+
* Used via `componentWithCondition` in `MainToolbar.tsx`.
|
|
8
8
|
*
|
|
9
9
|
* Cleanup: delete this file once the experiment has shipped.
|
|
10
10
|
*/
|
|
11
|
+
import React from 'react';
|
|
11
12
|
|
|
12
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- intentional: emotion fallback
|
|
13
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled, @typescript-eslint/consistent-type-imports -- intentional: emotion fallback for compiled migration
|
|
13
14
|
import { css, jsx } from '@emotion/react';
|
|
14
15
|
import { akEditorMobileMaxWidth } from '@atlaskit/editor-shared-styles';
|
|
15
|
-
const
|
|
16
|
+
const nonCustomToolbarWrapperEmotionStyles = css({
|
|
16
17
|
alignItems: 'center',
|
|
17
18
|
display: 'flex',
|
|
18
19
|
flexGrow: 1
|
|
19
20
|
});
|
|
20
|
-
const
|
|
21
|
+
export const NonCustomToolbarWrapperEmotion = ({
|
|
22
|
+
children
|
|
23
|
+
}) => jsx("div", {
|
|
24
|
+
css: nonCustomToolbarWrapperEmotionStyles
|
|
25
|
+
}, children);
|
|
26
|
+
const customToolbarWrapperEmotionStyles = css({
|
|
27
|
+
alignItems: 'center',
|
|
28
|
+
display: 'flex'
|
|
29
|
+
});
|
|
30
|
+
export const CustomToolbarWrapperEmotion = ({
|
|
31
|
+
children
|
|
32
|
+
}) => jsx("div", {
|
|
33
|
+
css: customToolbarWrapperEmotionStyles
|
|
34
|
+
}, children);
|
|
35
|
+
const mainToolbarIconBeforeEmotionStyles = css({
|
|
21
36
|
margin: "var(--ds-space-200, 16px)",
|
|
22
37
|
height: "var(--ds-space-400, 32px)",
|
|
23
38
|
width: "var(--ds-space-400, 32px)",
|
|
@@ -27,22 +42,8 @@ const mainToolbarIconBeforeStyle = css({
|
|
|
27
42
|
gridRow: 1
|
|
28
43
|
}
|
|
29
44
|
});
|
|
30
|
-
const customToolbarWrapperStyle = css({
|
|
31
|
-
alignItems: 'center',
|
|
32
|
-
display: 'flex'
|
|
33
|
-
});
|
|
34
|
-
export const NonCustomToolbarWrapperEmotion = ({
|
|
35
|
-
children
|
|
36
|
-
}) => jsx("div", {
|
|
37
|
-
css: nonCustomToolbarWrapperStyle
|
|
38
|
-
}, children);
|
|
39
45
|
export const MainToolbarIconBeforeEmotion = ({
|
|
40
46
|
children
|
|
41
47
|
}) => jsx("div", {
|
|
42
|
-
css:
|
|
43
|
-
}, children);
|
|
44
|
-
export const CustomToolbarWrapperEmotion = ({
|
|
45
|
-
children
|
|
46
|
-
}) => jsx("div", {
|
|
47
|
-
css: customToolbarWrapperStyle
|
|
48
|
+
css: mainToolbarIconBeforeEmotionStyles
|
|
48
49
|
}, children);
|
|
@@ -1,71 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
1
|
+
import { componentWithCondition } from '@atlaskit/platform-feature-flags-react';
|
|
2
|
+
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
3
|
+
import { CustomToolbarWrapperCompiled, MainToolbarIconBeforeCompiled, NonCustomToolbarWrapperCompiled } from './MainToolbar-compiled';
|
|
4
|
+
import { CustomToolbarWrapperEmotion, MainToolbarIconBeforeEmotion, NonCustomToolbarWrapperEmotion } from './MainToolbar-emotion';
|
|
4
5
|
export const MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT = 868;
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
export const
|
|
8
|
-
margin: "var(--ds-space-200, 16px)",
|
|
9
|
-
height: "var(--ds-space-400, 32px)",
|
|
10
|
-
width: "var(--ds-space-400, 32px)",
|
|
11
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
|
|
12
|
-
[`@media (max-width: ${akEditorMobileMaxWidth}px)`]: {
|
|
13
|
-
gridColumn: 1,
|
|
14
|
-
gridRow: 1
|
|
15
|
-
}
|
|
16
|
-
});
|
|
17
|
-
const mainToolbarFirstChild = css({
|
|
18
|
-
display: 'flex',
|
|
19
|
-
flexGrow: 1,
|
|
20
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
|
|
21
|
-
[`@media (max-width: ${akEditorMobileMaxWidth}px)`]: {
|
|
22
|
-
gridColumn: 1,
|
|
23
|
-
gridRow: 1
|
|
24
|
-
}
|
|
25
|
-
});
|
|
26
|
-
const mainToolbarFirstChildTowLine = () => {
|
|
27
|
-
const editorToolbarHeight = FULL_PAGE_EDITOR_TOOLBAR_HEIGHT();
|
|
28
|
-
return css({
|
|
29
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
30
|
-
[`@media (max-width: ${MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT}px)`]: {
|
|
31
|
-
flex: '1 1 100%',
|
|
32
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
33
|
-
height: editorToolbarHeight,
|
|
34
|
-
justifyContent: 'flex-end',
|
|
35
|
-
minWidth: 'fit-content'
|
|
36
|
-
}
|
|
37
|
-
});
|
|
38
|
-
};
|
|
39
|
-
export const mainToolbarFirstChildStyle = twoLineEditorToolbar => [mainToolbarFirstChild, twoLineEditorToolbar && mainToolbarFirstChildTowLine];
|
|
40
|
-
const mainToolbarSecondChild = css({
|
|
41
|
-
minWidth: 'fit-content'
|
|
42
|
-
});
|
|
43
|
-
const mainToolbarSecondChildTwoLine = () => {
|
|
44
|
-
const editorToolbarHeight = FULL_PAGE_EDITOR_TOOLBAR_HEIGHT();
|
|
45
|
-
return css({
|
|
46
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
47
|
-
[`@media (max-width: ${MAXIMUM_TWO_LINE_TOOLBAR_BREAKPOINT}px)`]: {
|
|
48
|
-
display: 'flex',
|
|
49
|
-
flexGrow: 1,
|
|
50
|
-
flex: '1 1 100%',
|
|
51
|
-
margin: 'auto',
|
|
52
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
|
|
53
|
-
height: editorToolbarHeight,
|
|
54
|
-
minWidth: 0
|
|
55
|
-
}
|
|
56
|
-
});
|
|
57
|
-
};
|
|
58
|
-
export const mainToolbarSecondChildStyle = twoLineEditorToolbar => [mainToolbarSecondChild, twoLineEditorToolbar && mainToolbarSecondChildTwoLine];
|
|
59
|
-
|
|
60
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
61
|
-
export const nonCustomToolbarWrapperStyle = css({
|
|
62
|
-
alignItems: 'center',
|
|
63
|
-
display: 'flex',
|
|
64
|
-
flexGrow: 1
|
|
65
|
-
});
|
|
66
|
-
|
|
67
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
68
|
-
export const customToolbarWrapperStyle = css({
|
|
69
|
-
alignItems: 'center',
|
|
70
|
-
display: 'flex'
|
|
71
|
-
});
|
|
6
|
+
export const NonCustomToolbarWrapperMigration = componentWithCondition(() => expValEquals('platform_editor_core_non_ecc_static_css', 'isEnabled', true), NonCustomToolbarWrapperCompiled, NonCustomToolbarWrapperEmotion);
|
|
7
|
+
export const CustomToolbarWrapperMigration = componentWithCondition(() => expValEquals('platform_editor_core_non_ecc_static_css', 'isEnabled', true), CustomToolbarWrapperCompiled, CustomToolbarWrapperEmotion);
|
|
8
|
+
export const MainToolbarIconBeforeMigration = componentWithCondition(() => expValEquals('platform_editor_core_non_ecc_static_css', 'isEnabled', true), MainToolbarIconBeforeCompiled, MainToolbarIconBeforeEmotion);
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
|
|
2
|
+
._v56419ab{transition:box-shadow .2s cubic-bezier(.15,1,.3,1)}
|
|
3
|
+
._n7zlia51{border-bottom:var(--ds-border-width,1px) solid var(--ds-border,#0b120e24)}._16qs1nax{box-shadow:var(--ds-shadow-overflow,0 0 8px #1e1f2128,0 0 1px #1e1f211e)}
|
|
4
|
+
._16qsglyw{box-shadow:none}
|
|
5
|
+
._1e0c1txw{display:flex}
|
|
6
|
+
._1krdgrf3 object{height:0!important}
|
|
7
|
+
._1o9zidpf{flex-shrink:0}
|
|
8
|
+
._1pby16oo{z-index:510}
|
|
9
|
+
._3pwj1osq span svg{max-width:100%}
|
|
10
|
+
._4cvr1h6o{align-items:center}
|
|
11
|
+
._4t3i17qo{height:var(--ak-editor-fullpage-toolbar-height)}
|
|
12
|
+
._bfhkvuon{background-color:var(--ds-surface,#fff)}
|
|
13
|
+
._kqswh2mm{position:relative}
|
|
14
|
+
@media (max-width:868px){._1s5v1g80{flex-wrap:wrap}._8o38zpre{height:calc(var(--ak-editor-fullpage-toolbar-height)*2)}}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/* MainToolbarWrapper-compiled.tsx generated by @compiled/babel-plugin v0.39.1 */
|
|
2
|
+
/**
|
|
3
|
+
* Compiled branch of the `platform_editor_core_non_ecc_static_css` experiment.
|
|
4
|
+
* Used via `componentWithCondition` in `MainToolbarWrapper.tsx`.
|
|
5
|
+
*
|
|
6
|
+
* Cleanup: delete this file once the experiment has shipped.
|
|
7
|
+
*/
|
|
8
|
+
import "./MainToolbarWrapper-compiled.compiled.css";
|
|
9
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
10
|
+
import React from 'react';
|
|
11
|
+
|
|
12
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-imports
|
|
13
|
+
|
|
14
|
+
const styles = {
|
|
15
|
+
base: "_v56419ab _n7zlia51 _kqswh2mm _4cvr1h6o _16qsglyw _1pby16oo _1e0c1txw _4t3i17qo _1o9zidpf _bfhkvuon _1krdgrf3",
|
|
16
|
+
flexibleIconSize: "_3pwj1osq",
|
|
17
|
+
keyline: "_16qs1nax",
|
|
18
|
+
twoLine: "_1s5v1g80 _8o38zpre"
|
|
19
|
+
};
|
|
20
|
+
export const MainToolbarWrapperCompiled = ({
|
|
21
|
+
showKeyline,
|
|
22
|
+
twoLineEditorToolbar,
|
|
23
|
+
children,
|
|
24
|
+
'data-testid': testId
|
|
25
|
+
}) => {
|
|
26
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
27
|
+
"data-testid": testId,
|
|
28
|
+
className: ax([styles.base, styles.flexibleIconSize, showKeyline && styles.keyline, twoLineEditorToolbar && styles.twoLine])
|
|
29
|
+
}, children);
|
|
30
|
+
};
|