@atlaskit/renderer 126.4.0 → 126.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/dist/cjs/messages.js +10 -0
- package/dist/cjs/react/nodes/heading-anchor.js +14 -8
- package/dist/cjs/react/nodes/heading.js +134 -9
- package/dist/cjs/ui/Renderer/RendererStyleContainer.js +360 -163
- package/dist/cjs/ui/Renderer/index.js +1 -1
- package/dist/es2019/messages.js +10 -0
- package/dist/es2019/react/nodes/heading-anchor.js +15 -6
- package/dist/es2019/react/nodes/heading.js +135 -9
- package/dist/es2019/ui/Renderer/RendererStyleContainer.js +402 -130
- package/dist/es2019/ui/Renderer/index.js +1 -1
- package/dist/esm/messages.js +10 -0
- package/dist/esm/react/nodes/heading-anchor.js +14 -8
- package/dist/esm/react/nodes/heading.js +132 -9
- package/dist/esm/ui/Renderer/RendererStyleContainer.js +360 -163
- package/dist/esm/ui/Renderer/index.js +1 -1
- package/dist/types/messages.d.ts +10 -0
- package/dist/types/react/nodes/heading.d.ts +14 -2
- package/dist/types-ts4.5/messages.d.ts +10 -0
- package/dist/types-ts4.5/react/nodes/heading.d.ts +14 -2
- package/package.json +2 -2
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
|
-
var
|
|
2
|
+
var _css7;
|
|
3
3
|
/* eslint-disable @atlaskit/ui-styling-standard/no-important-styles, @atlaskit/ui-styling-standard/no-unsafe-selectors */
|
|
4
4
|
/* eslint-disable @atlaskit/ui-styling-standard/no-imported-style-values */
|
|
5
5
|
/* eslint-disable @atlaskit/ui-styling-standard/no-nested-selectors, @atlaskit/ui-styling-standard/no-unsafe-values */
|
|
@@ -47,14 +47,14 @@ var isBackgroundClipBrowserFixNeeded = function isBackgroundClipBrowserFixNeeded
|
|
|
47
47
|
|
|
48
48
|
// styles are copied from ./style.tsx
|
|
49
49
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles, @atlaskit/design-system/no-css-tagged-template-expression, @atlaskit/design-system/consistent-css-prop-usage
|
|
50
|
-
var baseStyles = css((
|
|
50
|
+
var baseStyles = css(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
51
51
|
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
52
52
|
fontSize: 'var(--ak-renderer-base-font-size)',
|
|
53
53
|
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
54
54
|
lineHeight: '1.5rem',
|
|
55
55
|
color: "var(--ds-text, ".concat(N800, ")"),
|
|
56
56
|
'--ak-editor--full-width-layout-width': "".concat(akEditorFullWidthLayoutWidth, "px")
|
|
57
|
-
},
|
|
57
|
+
}, ".".concat(RendererCssClassName.DOCUMENT, "::after"), {
|
|
58
58
|
// we add a clearfix after ak-renderer-document in order to
|
|
59
59
|
// contain internal floats (such as media images that are "wrap-left")
|
|
60
60
|
// to just the renderer (and not spill outside of it)
|
|
@@ -84,48 +84,7 @@ var baseStyles = css((_css = {
|
|
|
84
84
|
})), "h6", _defineProperty({}, "> .mediaInlineView-content-wrap > .".concat(INLINE_IMAGE_WRAPPER_CLASS_NAME, ",\n > :is(a, span[data-mark-type='border']) .mediaInlineView-content-wrap > .").concat(INLINE_IMAGE_WRAPPER_CLASS_NAME, ",\n > .").concat(INLINE_IMAGE_WRAPPER_CLASS_NAME, ",\n > :is(a, span[data-mark-type='border']) .").concat(INLINE_IMAGE_WRAPPER_CLASS_NAME), {
|
|
85
85
|
height: '18px',
|
|
86
86
|
transform: "translateY(-2px)"
|
|
87
|
-
}))),
|
|
88
|
-
position: 'absolute',
|
|
89
|
-
marginLeft: "var(--ds-space-075, 6px)",
|
|
90
|
-
button: {
|
|
91
|
-
paddingLeft: 0,
|
|
92
|
-
paddingRight: 0
|
|
93
|
-
},
|
|
94
|
-
/**
|
|
95
|
-
* Adds the visibility of the button when in focus through keyboard navigation.
|
|
96
|
-
*/
|
|
97
|
-
'button:focus': {
|
|
98
|
-
opacity: 1,
|
|
99
|
-
transform: 'none !important'
|
|
100
|
-
}
|
|
101
|
-
}), "@media (hover: hover) and (pointer: fine)", _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
102
|
-
'> button': {
|
|
103
|
-
opacity: 0,
|
|
104
|
-
transform: "translate(-8px, 0px)",
|
|
105
|
-
transition: "opacity 0.2s ease 0s, transform 0.2s ease 0s"
|
|
106
|
-
}
|
|
107
|
-
}), '&:hover', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName, " > button"), {
|
|
108
|
-
opacity: 1,
|
|
109
|
-
transform: 'none !important'
|
|
110
|
-
})))), '& h1', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
111
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
112
|
-
lineHeight: "".concat(28 / 24, "em")
|
|
113
|
-
})), '& h2', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
114
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
115
|
-
lineHeight: "".concat(24 / 20, "em")
|
|
116
|
-
})), '& h3', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
117
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
118
|
-
lineHeight: "".concat(20 / 16, "em")
|
|
119
|
-
})), '& h4', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
120
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
121
|
-
lineHeight: "".concat(16 / 14, "em")
|
|
122
|
-
})), '& h5', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
123
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
124
|
-
lineHeight: "".concat(16 / 12, "em")
|
|
125
|
-
})), '& h6', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
126
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
127
|
-
lineHeight: "".concat(16 / 11, "em")
|
|
128
|
-
})), "& span.akActionMark", {
|
|
87
|
+
}))), "& span.akActionMark", {
|
|
129
88
|
color: "var(--ds-link, ".concat(B400, ")"),
|
|
130
89
|
textDecoration: 'none',
|
|
131
90
|
cursor: 'pointer',
|
|
@@ -136,9 +95,109 @@ var baseStyles = css((_css = {
|
|
|
136
95
|
'&:active': {
|
|
137
96
|
color: "var(--ds-link-pressed, ".concat(B500, ")")
|
|
138
97
|
}
|
|
139
|
-
}),
|
|
98
|
+
}), '& span[data-placeholder]', {
|
|
140
99
|
color: "var(--ds-text-subtlest, ".concat(N200, ")")
|
|
141
|
-
}))
|
|
100
|
+
}));
|
|
101
|
+
var headingAnchorStylesDuplicateAnchor = css({
|
|
102
|
+
'& h1, & h2, & h3, & h4, & h5, & h6': _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
103
|
+
position: 'absolute',
|
|
104
|
+
marginLeft: "var(--ds-space-075, 6px)",
|
|
105
|
+
button: {
|
|
106
|
+
paddingLeft: 0,
|
|
107
|
+
paddingRight: 0
|
|
108
|
+
},
|
|
109
|
+
/**
|
|
110
|
+
* Adds the visibility of the button when in focus through keyboard navigation.
|
|
111
|
+
*/
|
|
112
|
+
'button:focus': {
|
|
113
|
+
opacity: 1,
|
|
114
|
+
transform: 'none !important'
|
|
115
|
+
}
|
|
116
|
+
}), "@media (hover: hover) and (pointer: fine)", _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
117
|
+
'> button': {
|
|
118
|
+
opacity: 0,
|
|
119
|
+
transform: 'translate(-8px, 0px)',
|
|
120
|
+
transition: 'opacity 0.2s ease 0s, transform 0.2s ease 0s'
|
|
121
|
+
}
|
|
122
|
+
}), '&:hover', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName, " > button"), {
|
|
123
|
+
opacity: 1,
|
|
124
|
+
transform: 'none !important'
|
|
125
|
+
}))),
|
|
126
|
+
'& h1': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
127
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
128
|
+
lineHeight: "".concat(28 / 24, "em")
|
|
129
|
+
}),
|
|
130
|
+
'& h2': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
131
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
132
|
+
lineHeight: "".concat(24 / 20, "em")
|
|
133
|
+
}),
|
|
134
|
+
'& h3': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
135
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
136
|
+
lineHeight: "".concat(20 / 16, "em")
|
|
137
|
+
}),
|
|
138
|
+
'& h4': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
139
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
140
|
+
lineHeight: "".concat(16 / 14, "em")
|
|
141
|
+
}),
|
|
142
|
+
'& h5': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
143
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
144
|
+
lineHeight: "".concat(16 / 12, "em")
|
|
145
|
+
}),
|
|
146
|
+
'& h6': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
147
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
148
|
+
lineHeight: "".concat(16 / 11, "em")
|
|
149
|
+
})
|
|
150
|
+
});
|
|
151
|
+
var headingAnchorStyles = css({
|
|
152
|
+
'& .renderer-heading-wrapper': _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
153
|
+
marginLeft: "var(--ds-space-075, 6px)",
|
|
154
|
+
button: {
|
|
155
|
+
paddingLeft: 0,
|
|
156
|
+
paddingRight: 0
|
|
157
|
+
},
|
|
158
|
+
/**
|
|
159
|
+
* Adds the visibility of the button when in focus through keyboard navigation.
|
|
160
|
+
*/
|
|
161
|
+
'button:focus': {
|
|
162
|
+
opacity: 1,
|
|
163
|
+
transform: 'none !important'
|
|
164
|
+
}
|
|
165
|
+
}), "@media (hover: hover) and (pointer: fine)", _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
166
|
+
'> button': {
|
|
167
|
+
opacity: 0,
|
|
168
|
+
transform: "translate(-8px, 0px)",
|
|
169
|
+
transition: "opacity 0.2s ease 0s, transform 0.2s ease 0s"
|
|
170
|
+
}
|
|
171
|
+
}), '&:hover', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName, " > button"), {
|
|
172
|
+
opacity: 1,
|
|
173
|
+
transform: 'none !important'
|
|
174
|
+
}))),
|
|
175
|
+
// Line-height for heading anchor based on heading level (via data-level attribute on .renderer-heading-wrapper)
|
|
176
|
+
'& .renderer-heading-wrapper[data-level="1"]': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
177
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
178
|
+
lineHeight: "".concat(28 / 24, "em")
|
|
179
|
+
}),
|
|
180
|
+
'& .renderer-heading-wrapper[data-level="2"]': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
181
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
182
|
+
lineHeight: "".concat(24 / 20, "em")
|
|
183
|
+
}),
|
|
184
|
+
'& .renderer-heading-wrapper[data-level="3"]': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
185
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
186
|
+
lineHeight: "".concat(20 / 16, "em")
|
|
187
|
+
}),
|
|
188
|
+
'& .renderer-heading-wrapper[data-level="4"]': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
189
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
190
|
+
lineHeight: "".concat(16 / 14, "em")
|
|
191
|
+
}),
|
|
192
|
+
'& .renderer-heading-wrapper[data-level="5"]': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
193
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
194
|
+
lineHeight: "".concat(16 / 12, "em")
|
|
195
|
+
}),
|
|
196
|
+
'& .renderer-heading-wrapper[data-level="6"]': _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
197
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
198
|
+
lineHeight: "".concat(16 / 11, "em")
|
|
199
|
+
})
|
|
200
|
+
});
|
|
142
201
|
var akEditorBreakpointForSmallDevice = '1266px';
|
|
143
202
|
var responsiveBreakoutWidth = css(_defineProperty({
|
|
144
203
|
'--ak-editor--breakout-container-without-gutter-width': "calc(100cqw - ".concat(akEditorGutterPadding, "px * 2)"),
|
|
@@ -163,7 +222,7 @@ var responsiveBreakoutWidthWithReducedPadding = css(_defineProperty(_definePrope
|
|
|
163
222
|
}), "@media (max-width: ".concat(akEditorFullPageNarrowBreakout, "px)"), {
|
|
164
223
|
'--ak-editor--breakout-container-without-gutter-width': "calc(100cqw - var(--ak-renderer--full-page-gutter) * 2)"
|
|
165
224
|
}));
|
|
166
|
-
var
|
|
225
|
+
var hideHeadingCopyLinkWrapperStylesDuplicateAnchor = css({
|
|
167
226
|
'& h1, & h2, & h3, & h4, & h5, & h6': _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
168
227
|
'&:focus-within': {
|
|
169
228
|
opacity: 1
|
|
@@ -175,6 +234,18 @@ var hideHeadingCopyLinkWrapperStyles = css({
|
|
|
175
234
|
opacity: 1
|
|
176
235
|
})))
|
|
177
236
|
});
|
|
237
|
+
var hideHeadingCopyLinkWrapperStyles = css({
|
|
238
|
+
'& .renderer-heading-wrapper': _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
239
|
+
'&:focus-within': {
|
|
240
|
+
opacity: 1
|
|
241
|
+
}
|
|
242
|
+
}), "@media (hover: hover) and (pointer: fine)", _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
243
|
+
opacity: 0,
|
|
244
|
+
transition: "opacity 0.2s ease 0s"
|
|
245
|
+
}), '&:hover', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
246
|
+
opacity: 1
|
|
247
|
+
})))
|
|
248
|
+
});
|
|
178
249
|
var rendererFullPageStyles = css({
|
|
179
250
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values, @atlaskit/ui-styling-standard/no-unsafe-values
|
|
180
251
|
maxWidth: "".concat(akEditorDefaultLayoutWidth, "px"),
|
|
@@ -241,7 +312,7 @@ var rovoTelepointerStyles = css(_defineProperty({}, "#".concat(TELEPOINTER_ID),
|
|
|
241
312
|
fontFamily: "var(--ds-font-family-body, \"Atlassian Sans\", ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)",
|
|
242
313
|
fontWeight: "var(--ds-font-weight-semibold, 600)",
|
|
243
314
|
color: "var(--ds-text-inverse, white)",
|
|
244
|
-
|
|
315
|
+
backgroundColor: "var(--ds-text, #292A2E)",
|
|
245
316
|
top: 1,
|
|
246
317
|
left: 1,
|
|
247
318
|
borderRadius: "0px ".concat("var(--ds-space-050, 4px)", " ", "var(--ds-space-050, 4px)", " 0px"),
|
|
@@ -306,86 +377,6 @@ var blockquoteSharedStyles = css({
|
|
|
306
377
|
}
|
|
307
378
|
}
|
|
308
379
|
});
|
|
309
|
-
var headingsSharedStyles = css({
|
|
310
|
-
'& h1': {
|
|
311
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
312
|
-
fontSize: "".concat(24 / 14, "em"),
|
|
313
|
-
fontStyle: 'inherit',
|
|
314
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
315
|
-
lineHeight: 28 / 24,
|
|
316
|
-
color: "var(--ds-text, #292A2E)",
|
|
317
|
-
fontWeight: "var(--ds-font-weight-medium, 500)",
|
|
318
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
319
|
-
letterSpacing: "-0.01em",
|
|
320
|
-
marginBottom: 0,
|
|
321
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
322
|
-
marginTop: '1.667em'
|
|
323
|
-
},
|
|
324
|
-
'& h2': {
|
|
325
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
326
|
-
fontSize: "".concat(20 / 14, "em"),
|
|
327
|
-
fontStyle: 'inherit',
|
|
328
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
329
|
-
lineHeight: 24 / 20,
|
|
330
|
-
color: "var(--ds-text, #292A2E)",
|
|
331
|
-
fontWeight: "var(--ds-font-weight-medium, 500)",
|
|
332
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
333
|
-
letterSpacing: "-0.008em",
|
|
334
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
335
|
-
marginTop: '1.8em',
|
|
336
|
-
marginBottom: 0
|
|
337
|
-
},
|
|
338
|
-
'& h3': {
|
|
339
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
340
|
-
fontSize: "".concat(16 / 14, "em"),
|
|
341
|
-
fontStyle: 'inherit',
|
|
342
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
343
|
-
lineHeight: 20 / 16,
|
|
344
|
-
color: "var(--ds-text, #292A2E)",
|
|
345
|
-
fontWeight: "var(--ds-font-weight-semibold, 600)",
|
|
346
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
347
|
-
letterSpacing: "-0.006em",
|
|
348
|
-
marginTop: "var(--ds-space-400, 2em)",
|
|
349
|
-
marginBottom: 0
|
|
350
|
-
},
|
|
351
|
-
'& h4': {
|
|
352
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
353
|
-
fontSize: "".concat(14 / 14, "em"),
|
|
354
|
-
fontStyle: 'inherit',
|
|
355
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
356
|
-
lineHeight: 16 / 14,
|
|
357
|
-
color: "var(--ds-text, #292A2E)",
|
|
358
|
-
fontWeight: "var(--ds-font-weight-semibold, 600)",
|
|
359
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
360
|
-
letterSpacing: "-0.003em",
|
|
361
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
362
|
-
marginTop: '1.357em'
|
|
363
|
-
},
|
|
364
|
-
'& h5': {
|
|
365
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
366
|
-
fontSize: "".concat(12 / 14, "em"),
|
|
367
|
-
fontStyle: 'inherit',
|
|
368
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
369
|
-
lineHeight: 16 / 12,
|
|
370
|
-
color: "var(--ds-text, #292A2E)",
|
|
371
|
-
fontWeight: "var(--ds-font-weight-semibold, 600)",
|
|
372
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
373
|
-
marginTop: '1.667em',
|
|
374
|
-
textTransform: 'none'
|
|
375
|
-
},
|
|
376
|
-
'& h6': {
|
|
377
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
378
|
-
fontSize: "".concat(11 / 14, "em"),
|
|
379
|
-
fontStyle: 'inherit',
|
|
380
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
381
|
-
lineHeight: 16 / 11,
|
|
382
|
-
color: "var(--ds-text-subtlest, #6B6E76)",
|
|
383
|
-
fontWeight: "var(--ds-font-weight-bold, 653)",
|
|
384
|
-
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
385
|
-
marginTop: '1.455em',
|
|
386
|
-
textTransform: 'none'
|
|
387
|
-
}
|
|
388
|
-
});
|
|
389
380
|
var headingsSharedStylesWithEditorUGC = css({
|
|
390
381
|
'& h1': {
|
|
391
382
|
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
@@ -453,7 +444,7 @@ var headingsSharedStylesWithEditorUGC = css({
|
|
|
453
444
|
}
|
|
454
445
|
}
|
|
455
446
|
});
|
|
456
|
-
var
|
|
447
|
+
var headingWithAlignmentStylesDuplicateAnchor = css({
|
|
457
448
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
458
449
|
'.fabric-editor-block-mark.fabric-editor-alignment:not(:first-child)': {
|
|
459
450
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
@@ -496,6 +487,46 @@ var headingWithAlignmentStyles = css({
|
|
|
496
487
|
}
|
|
497
488
|
}
|
|
498
489
|
});
|
|
490
|
+
var headingWithAlignmentStyles = css({
|
|
491
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
492
|
+
'.fabric-editor-block-mark.fabric-editor-alignment:not(:first-child)': {
|
|
493
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
494
|
+
'> .renderer-heading-wrapper:first-child': {
|
|
495
|
+
h1: {
|
|
496
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
497
|
+
marginTop: '1.667em'
|
|
498
|
+
},
|
|
499
|
+
h2: {
|
|
500
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
501
|
+
marginTop: '1.8em'
|
|
502
|
+
},
|
|
503
|
+
h3: {
|
|
504
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
505
|
+
marginTop: '2em'
|
|
506
|
+
},
|
|
507
|
+
h4: {
|
|
508
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
509
|
+
marginTop: '1.357em'
|
|
510
|
+
},
|
|
511
|
+
h5: {
|
|
512
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
513
|
+
marginTop: '1.667em'
|
|
514
|
+
},
|
|
515
|
+
h6: {
|
|
516
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
517
|
+
marginTop: '1.455em'
|
|
518
|
+
}
|
|
519
|
+
}
|
|
520
|
+
},
|
|
521
|
+
// Set marginTop: 0 if alignment block is next to a gap cursor or widget that is first child
|
|
522
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
523
|
+
'.ProseMirror-gapcursor:first-child + .fabric-editor-block-mark.fabric-editor-alignment, .ProseMirror-widget:first-child + .fabric-editor-block-mark.fabric-editor-alignment, .ProseMirror-widget:first-child + .ProseMirror-widget:nth-child(2) + .fabric-editor-block-mark.fabric-editor-alignment': {
|
|
524
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
525
|
+
'> .renderer-heading-wrapper:first-child > :is(h1, h2, h3, h4, h5, h6)': {
|
|
526
|
+
marginTop: '0'
|
|
527
|
+
}
|
|
528
|
+
}
|
|
529
|
+
});
|
|
499
530
|
var ruleSharedStyles = css({
|
|
500
531
|
'& hr': {
|
|
501
532
|
border: 'none',
|
|
@@ -560,16 +591,16 @@ var listsSharedStyles = css((_css7 = {
|
|
|
560
591
|
}
|
|
561
592
|
}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_css7, "".concat(orderedListSelector, ", ").concat(bulletListSelector), {
|
|
562
593
|
/*
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
594
|
+
Ensures list item content adheres to the list's margin instead
|
|
595
|
+
of filling the entire block row. This is important to allow
|
|
596
|
+
clicking interactive elements which are floated next to a list.
|
|
597
|
+
For some history and context on this block, see PRs related to tickets.:
|
|
598
|
+
@see ED-6551 - original issue.
|
|
599
|
+
@see ED-7015 - follow up issue.
|
|
600
|
+
@see ED-7447 - flow-root change.
|
|
601
|
+
used to have display: 'table' in tag template style but not supported in object styles
|
|
602
|
+
removed display: 'table' as 'flow-root' is supported in latest browsers
|
|
603
|
+
@see https://css-tricks.com/display-flow-root/
|
|
573
604
|
*/
|
|
574
605
|
display: 'flow-root'
|
|
575
606
|
}), 'ul, ul ul ul ul', {
|
|
@@ -660,7 +691,7 @@ var indentationSharedStylesWithMarginFix = css({
|
|
|
660
691
|
}
|
|
661
692
|
}
|
|
662
693
|
});
|
|
663
|
-
var
|
|
694
|
+
var blockMarksSharedStylesDuplicateAnchor = css(_defineProperty({}, "*:not(.fabric-editor-block-mark) >,\n \t*:not(.fabric-editor-block-mark) >\n div.fabric-editor-block-mark:first-of-type\n\t:not(.fabric-editor-indentation-mark)\n\t:not(.fabric-editor-alignment),\n \t.fabric-editor-alignment:first-of-type:first-child,\n \t.ProseMirror .fabric-editor-indentation-mark:first-of-type:first-child", {
|
|
664
695
|
'p, h1, h2, h3, h4, h5, h6, .heading-wrapper': {
|
|
665
696
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
666
697
|
':first-child:not(style), style:first-child + *': {
|
|
@@ -668,6 +699,22 @@ var blockMarksSharedStyles = css(_defineProperty({}, "*:not(.fabric-editor-block
|
|
|
668
699
|
}
|
|
669
700
|
}
|
|
670
701
|
}));
|
|
702
|
+
var blockMarksSharedStyles = css(_defineProperty({}, "*:not(.fabric-editor-block-mark) >,\n \t*:not(.fabric-editor-block-mark) >\n div.fabric-editor-block-mark:first-of-type\n\t:not(.fabric-editor-indentation-mark)\n\t:not(.fabric-editor-alignment),\n \t.fabric-editor-alignment:first-of-type:first-child,\n \t.ProseMirror .fabric-editor-indentation-mark:first-of-type:first-child", {
|
|
703
|
+
'p, .heading-wrapper': {
|
|
704
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
705
|
+
':first-child:not(style), style:first-child + *': {
|
|
706
|
+
marginTop: 0
|
|
707
|
+
}
|
|
708
|
+
},
|
|
709
|
+
'.renderer-heading-wrapper': {
|
|
710
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
711
|
+
':first-child:not(style), style:first-child + *': {
|
|
712
|
+
'h1, h2, h3, h4, h5, h6': {
|
|
713
|
+
marginTop: 0
|
|
714
|
+
}
|
|
715
|
+
}
|
|
716
|
+
}
|
|
717
|
+
}));
|
|
671
718
|
var codeMarkSharedStyles = css({
|
|
672
719
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-nested-selectors -- Ignored via go/DSP-18766
|
|
673
720
|
'.code': {
|
|
@@ -828,7 +875,10 @@ var tasksAndDecisionsStyles = css({
|
|
|
828
875
|
}
|
|
829
876
|
},
|
|
830
877
|
'div[data-task-list-local-id]': {
|
|
831
|
-
|
|
878
|
+
marginTop: "var(--ds-space-150, 12px)",
|
|
879
|
+
marginRight: 0,
|
|
880
|
+
marginBottom: 0,
|
|
881
|
+
marginLeft: 0,
|
|
832
882
|
// If task item is not first in the list then set margin top to 4px.
|
|
833
883
|
'div + div': {
|
|
834
884
|
marginTop: "var(--ds-space-050, 4px)"
|
|
@@ -879,6 +929,78 @@ var headerSmartCardStyles = css({
|
|
|
879
929
|
}
|
|
880
930
|
}
|
|
881
931
|
});
|
|
932
|
+
var baseOtherStylesDuplicateAnchor = css(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
933
|
+
'& .UnknownBlock': {
|
|
934
|
+
fontFamily: "var(--ds-font-family-body, \"Atlassian Sans\", ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)",
|
|
935
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
|
|
936
|
+
fontSize: "".concat(14 / 16, "rem"),
|
|
937
|
+
fontWeight: "var(--ds-font-weight-regular, 400)",
|
|
938
|
+
whiteSpace: 'pre-wrap',
|
|
939
|
+
wordWrap: 'break-word'
|
|
940
|
+
},
|
|
941
|
+
'& span.date-node': {
|
|
942
|
+
backgroundColor: "var(--ds-background-neutral, ".concat(N30A, ")"),
|
|
943
|
+
borderRadius: "var(--ds-radius-small, 3px)",
|
|
944
|
+
color: "var(--ds-text, ".concat(N800, ")"),
|
|
945
|
+
paddingTop: "var(--ds-space-025, 2px)",
|
|
946
|
+
paddingRight: "var(--ds-space-050, 4px)",
|
|
947
|
+
paddingBottom: "var(--ds-space-025, 2px)",
|
|
948
|
+
paddingLeft: "var(--ds-space-050, 4px)",
|
|
949
|
+
margin: "0 1px",
|
|
950
|
+
transition: "background 0.3s"
|
|
951
|
+
},
|
|
952
|
+
'& span.date-node-highlighted': {
|
|
953
|
+
backgroundColor: "var(--ds-background-danger, ".concat(R50, ")"),
|
|
954
|
+
color: "var(--ds-text-danger, ".concat(R500, ")")
|
|
955
|
+
},
|
|
956
|
+
'& .renderer-image': {
|
|
957
|
+
maxWidth: '100%',
|
|
958
|
+
display: 'block',
|
|
959
|
+
marginTop: "var(--ds-space-300, 24px)",
|
|
960
|
+
marginRight: 0,
|
|
961
|
+
marginBottom: "var(--ds-space-300, 24px)",
|
|
962
|
+
marginLeft: 0
|
|
963
|
+
}
|
|
964
|
+
}, ".".concat(richMediaClassName, ".rich-media-wrapped + .").concat(richMediaClassName, ":not(.rich-media-wrapped)"), {
|
|
965
|
+
clear: 'both'
|
|
966
|
+
}), "& .code-block,\n\t& blockquote,\n\t& hr,\n\t& > div > div:not(.rich-media-wrapped),\n\t.".concat(richMediaClassName, ".rich-media-wrapped + .rich-media-wrapped + *:not(.rich-media-wrapped),\n\t.").concat(richMediaClassName, ".rich-media-wrapped + div:not(.rich-media-wrapped),\n\t.").concat(richMediaClassName, ".image-align-start,\n\t\t.").concat(richMediaClassName, ".image-center,\n\t\t.").concat(richMediaClassName, ".image-align-end"), {
|
|
967
|
+
clear: 'both'
|
|
968
|
+
}), '& .rich-media-wrapped', {
|
|
969
|
+
'& + .renderer-heading-wrapper': {
|
|
970
|
+
'h1, h2, h3, h4, h5, h6': {
|
|
971
|
+
marginTop: "var(--ds-space-100, 8px)"
|
|
972
|
+
}
|
|
973
|
+
}
|
|
974
|
+
}), 'div[class^="image-wrap-"] + div[class^="image-wrap-"]', {
|
|
975
|
+
marginLeft: 0,
|
|
976
|
+
marginRight: 0
|
|
977
|
+
}), ".".concat(RendererCssClassName.DOCUMENT, " >"), _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, "*:not([data-mark-type='fragment']) .".concat(TableSharedCssClassName.TABLE_CONTAINER), {
|
|
978
|
+
// Temporarily ignoring the below the owning team can add the ticket number for the TODO. Context: https://atlassian.slack.com/archives/CPUEVD9MY/p1741565387326829
|
|
979
|
+
// eslint-disable-next-line @atlaskit/editor/enforce-todo-comment-format
|
|
980
|
+
// TODO - improve inline style logic on table container so important styles aren't required here
|
|
981
|
+
width: '100% !important',
|
|
982
|
+
left: '0 !important'
|
|
983
|
+
}), "[data-mark-type='fragment'] * .".concat(TableSharedCssClassName.TABLE_CONTAINER), {
|
|
984
|
+
// Temporarily ignoring the below the owning team can add the ticket number for the TODO. Context: https://atlassian.slack.com/archives/CPUEVD9MY/p1741565387326829
|
|
985
|
+
// eslint-disable-next-line @atlaskit/editor/enforce-todo-comment-format
|
|
986
|
+
// TODO - improve inline style logic on table container so important styles aren't required here
|
|
987
|
+
width: '100% !important',
|
|
988
|
+
left: '0 !important'
|
|
989
|
+
}), "* .".concat(RendererCssClassName.EXTENSION_OVERFLOW_CONTAINER), {
|
|
990
|
+
overflowX: 'auto'
|
|
991
|
+
}), "& .".concat(RendererCssClassName.EXTENSION, ":first-child"), {
|
|
992
|
+
marginTop: 0
|
|
993
|
+
})), ".".concat(RendererCssClassName.DOCUMENT), _defineProperty(_defineProperty(_defineProperty(_defineProperty({}, ".".concat(RendererCssClassName.EXTENSION), {
|
|
994
|
+
marginTop: "".concat(blockNodesVerticalMargin)
|
|
995
|
+
}), ".".concat(RendererCssClassName.EXTENSION_CENTER_ALIGN), {
|
|
996
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
997
|
+
marginLeft: '50%',
|
|
998
|
+
transform: 'translateX(-50%)'
|
|
999
|
+
}), ".".concat(TableSharedCssClassName.TABLE_NODE_WRAPPER), {
|
|
1000
|
+
overflowX: 'auto'
|
|
1001
|
+
}), ".".concat(shadowObserverClassNames.SHADOW_CONTAINER, " .").concat(TableSharedCssClassName.TABLE_NODE_WRAPPER), {
|
|
1002
|
+
display: 'flex'
|
|
1003
|
+
})));
|
|
882
1004
|
var baseOtherStyles = css(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({
|
|
883
1005
|
'& .UnknownBlock': {
|
|
884
1006
|
fontFamily: "var(--ds-font-family-body, \"Atlassian Sans\", ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)",
|
|
@@ -889,29 +1011,37 @@ var baseOtherStyles = css(_defineProperty(_defineProperty(_defineProperty(_defin
|
|
|
889
1011
|
wordWrap: 'break-word'
|
|
890
1012
|
},
|
|
891
1013
|
'& span.date-node': {
|
|
892
|
-
|
|
1014
|
+
backgroundColor: "var(--ds-background-neutral, ".concat(N30A, ")"),
|
|
893
1015
|
borderRadius: "var(--ds-radius-small, 3px)",
|
|
894
1016
|
color: "var(--ds-text, ".concat(N800, ")"),
|
|
895
|
-
|
|
1017
|
+
paddingTop: "var(--ds-space-025, 2px)",
|
|
1018
|
+
paddingRight: "var(--ds-space-050, 4px)",
|
|
1019
|
+
paddingBottom: "var(--ds-space-025, 2px)",
|
|
1020
|
+
paddingLeft: "var(--ds-space-050, 4px)",
|
|
896
1021
|
margin: "0 1px",
|
|
897
1022
|
transition: "background 0.3s"
|
|
898
1023
|
},
|
|
899
1024
|
'& span.date-node-highlighted': {
|
|
900
|
-
|
|
1025
|
+
backgroundColor: "var(--ds-background-danger, ".concat(R50, ")"),
|
|
901
1026
|
color: "var(--ds-text-danger, ".concat(R500, ")")
|
|
902
1027
|
},
|
|
903
1028
|
'& .renderer-image': {
|
|
904
1029
|
maxWidth: '100%',
|
|
905
1030
|
display: 'block',
|
|
906
|
-
|
|
1031
|
+
marginTop: "var(--ds-space-300, 24px)",
|
|
1032
|
+
marginRight: 0,
|
|
1033
|
+
marginBottom: "var(--ds-space-300, 24px)",
|
|
1034
|
+
marginLeft: 0
|
|
907
1035
|
}
|
|
908
1036
|
}, ".".concat(richMediaClassName, ".rich-media-wrapped + .").concat(richMediaClassName, ":not(.rich-media-wrapped)"), {
|
|
909
1037
|
clear: 'both'
|
|
910
1038
|
}), "& .code-block,\n\t& blockquote,\n\t& hr,\n\t& > div > div:not(.rich-media-wrapped),\n\t.".concat(richMediaClassName, ".rich-media-wrapped + .rich-media-wrapped + *:not(.rich-media-wrapped),\n\t.").concat(richMediaClassName, ".rich-media-wrapped + div:not(.rich-media-wrapped),\n\t.").concat(richMediaClassName, ".image-align-start,\n\t\t.").concat(richMediaClassName, ".image-center,\n\t\t.").concat(richMediaClassName, ".image-align-end"), {
|
|
911
1039
|
clear: 'both'
|
|
912
1040
|
}), '& .rich-media-wrapped', {
|
|
913
|
-
'& +
|
|
914
|
-
|
|
1041
|
+
'& + .renderer-heading-wrapper': {
|
|
1042
|
+
'h1, h2, h3, h4, h5, h6': {
|
|
1043
|
+
marginTop: "var(--ds-space-100, 8px)"
|
|
1044
|
+
}
|
|
915
1045
|
}
|
|
916
1046
|
}), 'div[class^="image-wrap-"] + div[class^="image-wrap-"]', {
|
|
917
1047
|
marginLeft: 0,
|
|
@@ -943,7 +1073,7 @@ var baseOtherStyles = css(_defineProperty(_defineProperty(_defineProperty(_defin
|
|
|
943
1073
|
}), ".".concat(shadowObserverClassNames.SHADOW_CONTAINER, " .").concat(TableSharedCssClassName.TABLE_NODE_WRAPPER), {
|
|
944
1074
|
display: 'flex'
|
|
945
1075
|
})));
|
|
946
|
-
var
|
|
1076
|
+
var alignedHeadingAnchorStyleDuplicateAnchor = css({
|
|
947
1077
|
// Temporarily ignoring the below the owning team can add the ticket number for the TODO. Context: https://atlassian.slack.com/archives/CPUEVD9MY/p1741565387326829
|
|
948
1078
|
// eslint-disable-next-line @atlaskit/editor/enforce-todo-comment-format
|
|
949
1079
|
// TODO Delete this comment after verifying space token -> previous value `margin: 6px`
|
|
@@ -954,7 +1084,44 @@ var alignedHeadingAnchorStyle = css({
|
|
|
954
1084
|
},
|
|
955
1085
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
956
1086
|
'.fabric-editor-block-mark:not([data-align="center"])[data-align]': _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
957
|
-
|
|
1087
|
+
marginTop: 0,
|
|
1088
|
+
marginRight: "var(--ds-space-075, 6px)",
|
|
1089
|
+
marginBottom: 0,
|
|
1090
|
+
marginLeft: 0,
|
|
1091
|
+
// If the anchor is right aligned then the left side of the heading
|
|
1092
|
+
// is aligned with the left side of the anchor.
|
|
1093
|
+
// In order to align as expected we transform it the width of the element (plus our expected 6px)
|
|
1094
|
+
// to the left
|
|
1095
|
+
transform: "translateX(calc(-100% - ".concat("var(--ds-space-075, 6px)", "))")
|
|
1096
|
+
}), '@media (hover: hover) and (pointer: fine)', _defineProperty({}, ".".concat(HeadingAnchorWrapperClassName, " > button"), {
|
|
1097
|
+
transform: "translate(8px, 0px)"
|
|
1098
|
+
}))
|
|
1099
|
+
});
|
|
1100
|
+
var alignedHeadingAnchorStyle = css({
|
|
1101
|
+
// Temporarily ignoring the below the owning team can add the ticket number for the TODO. Context: https://atlassian.slack.com/archives/CPUEVD9MY/p1741565387326829
|
|
1102
|
+
// eslint-disable-next-line @atlaskit/editor/enforce-todo-comment-format
|
|
1103
|
+
// TODO Delete this comment after verifying space token -> previous value `margin: 6px`
|
|
1104
|
+
'.fabric-editor-block-mark[data-align] >': {
|
|
1105
|
+
'.renderer-heading-wrapper': {
|
|
1106
|
+
'h1, h2, h3, h4, h5, h6': {
|
|
1107
|
+
position: 'relative'
|
|
1108
|
+
}
|
|
1109
|
+
}
|
|
1110
|
+
},
|
|
1111
|
+
// Center alignment for heading wrapper - flex container needs justify-content instead of text-align
|
|
1112
|
+
'.fabric-editor-block-mark[data-align="center"] > .renderer-heading-wrapper': {
|
|
1113
|
+
justifyContent: 'center'
|
|
1114
|
+
},
|
|
1115
|
+
// Right/end alignment for heading wrapper - flex container needs justify-content instead of text-align
|
|
1116
|
+
'.fabric-editor-block-mark[data-align="end"] > .renderer-heading-wrapper': {
|
|
1117
|
+
justifyContent: 'flex-end'
|
|
1118
|
+
},
|
|
1119
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
1120
|
+
'.fabric-editor-block-mark:not([data-align="center"])[data-align]': _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
1121
|
+
marginTop: 0,
|
|
1122
|
+
marginRight: "var(--ds-space-075, 6px)",
|
|
1123
|
+
marginBottom: 0,
|
|
1124
|
+
marginLeft: 0,
|
|
958
1125
|
// If the anchor is right aligned then the left side of the heading
|
|
959
1126
|
// is aligned with the left side of the anchor.
|
|
960
1127
|
// In order to align as expected we transform it the width of the element (plus our expected 6px)
|
|
@@ -1010,7 +1177,10 @@ var mediaSingleSharedStyle = css(_defineProperty(_defineProperty(_defineProperty
|
|
|
1010
1177
|
"div.mediaSingleView-content-wrap[layout='wrap-left'], div.mediaSingleView-content-wrap[data-layout='wrap-left'], div.mediaSingleView-content-wrap[layout='wrap-right'], div.mediaSingleView-content-wrap[data-layout='wrap-right']": {
|
|
1011
1178
|
float: 'none',
|
|
1012
1179
|
overflow: 'auto',
|
|
1013
|
-
|
|
1180
|
+
marginTop: "var(--ds-space-150, 12px)",
|
|
1181
|
+
marginRight: 0,
|
|
1182
|
+
marginBottom: "var(--ds-space-150, 12px)",
|
|
1183
|
+
marginLeft: 0
|
|
1014
1184
|
}
|
|
1015
1185
|
}));
|
|
1016
1186
|
|
|
@@ -1083,7 +1253,10 @@ var tableSharedStyle = css(_defineProperty(_defineProperty(_defineProperty(_defi
|
|
|
1083
1253
|
}
|
|
1084
1254
|
}, ".".concat(TableSharedCssClassName.TABLE_CONTAINER), {
|
|
1085
1255
|
position: 'relative',
|
|
1086
|
-
|
|
1256
|
+
marginTop: 0,
|
|
1257
|
+
marginRight: 'auto',
|
|
1258
|
+
marginBottom: "var(--ds-space-200, 16px)",
|
|
1259
|
+
marginLeft: 'auto',
|
|
1087
1260
|
boxSizing: 'border-box',
|
|
1088
1261
|
/**
|
|
1089
1262
|
* Fix block top alignment inside table cells.
|
|
@@ -1100,9 +1273,15 @@ var tableSharedStyle = css(_defineProperty(_defineProperty(_defineProperty(_defi
|
|
|
1100
1273
|
}), ".".concat(TableSharedCssClassName.TABLE_RESIZER_CONTAINER, " table"), {
|
|
1101
1274
|
willChange: 'width'
|
|
1102
1275
|
}), ".".concat(TableSharedCssClassName.TABLE_NODE_WRAPPER, " > table"), {
|
|
1103
|
-
|
|
1276
|
+
marginTop: "var(--ds-space-300, 24px)",
|
|
1277
|
+
marginRight: 0,
|
|
1278
|
+
marginBottom: 0,
|
|
1279
|
+
marginLeft: 0
|
|
1104
1280
|
}), ".".concat(TableSharedCssClassName.TABLE_CONTAINER, " > table,\n\t.").concat(TableSharedCssClassName.TABLE_STICKY_WRAPPER, " > table"), {
|
|
1105
|
-
|
|
1281
|
+
marginTop: "var(--ds-space-300, 24px)",
|
|
1282
|
+
marginRight: "var(--ds-space-100, 8px)",
|
|
1283
|
+
marginBottom: 0,
|
|
1284
|
+
marginLeft: 0
|
|
1106
1285
|
}), ".".concat(TableSharedCssClassName.TABLE_CONTAINER, " > table,\n\t.").concat(TableSharedCssClassName.TABLE_NODE_WRAPPER, " > table,\n\t.").concat(TableSharedCssClassName.TABLE_STICKY_WRAPPER, " > table"), {
|
|
1107
1286
|
borderCollapse: 'collapse',
|
|
1108
1287
|
border: "".concat(tableCellBorderWidth, "px solid ", "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")")),
|
|
@@ -1161,7 +1340,10 @@ var tableRendererHeaderStylesForTableCellOnly = css(_defineProperty({}, ".".conc
|
|
|
1161
1340
|
border: "var(--ds-border-width, 1px)".concat(" solid ", "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")")),
|
|
1162
1341
|
borderRightWidth: 0,
|
|
1163
1342
|
borderBottomWidth: 0,
|
|
1164
|
-
|
|
1343
|
+
paddingTop: "var(--ds-space-100, 8px)",
|
|
1344
|
+
paddingRight: "var(--ds-space-100, 8px)",
|
|
1345
|
+
paddingBottom: "var(--ds-space-100, 8px)",
|
|
1346
|
+
paddingLeft: "var(--ds-space-100, 8px)",
|
|
1165
1347
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-selectors
|
|
1166
1348
|
'th p:not(:first-of-type), td p:not(:first-of-type)': {
|
|
1167
1349
|
marginTop: "var(--ds-space-150, 12px)"
|
|
@@ -1307,7 +1489,7 @@ var rendererTableColumnStyles = css(_defineProperty({}, ".".concat(RendererCssCl
|
|
|
1307
1489
|
borderRight: "0px none"
|
|
1308
1490
|
})
|
|
1309
1491
|
}));
|
|
1310
|
-
var
|
|
1492
|
+
var rendererTableHeaderEqualHeightStylesAllowNestedHeaderLinksDuplicateAnchor = css(_defineProperty({}, ".".concat(RendererCssClassName.DOCUMENT, " .").concat(TableSharedCssClassName.TABLE_CONTAINER), _defineProperty({}, ".".concat(TableSharedCssClassName.TABLE_NODE_WRAPPER, " > table, .").concat(TableSharedCssClassName.TABLE_STICKY_WRAPPER, " > table"), _defineProperty({}, ".".concat(RendererCssClassName.SORTABLE_COLUMN_WRAPPER), _defineProperty({}, ".".concat(RendererCssClassName.SORTABLE_COLUMN), _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
1311
1493
|
position: 'unset'
|
|
1312
1494
|
}), '>', {
|
|
1313
1495
|
'h1, h2, h3, h4, h5, h6': {
|
|
@@ -1315,6 +1497,14 @@ var rendererTableHeaderEqualHeightStylesAllowNestedHeaderLinks = css(_defineProp
|
|
|
1315
1497
|
marginRight: '30px'
|
|
1316
1498
|
}
|
|
1317
1499
|
}))))));
|
|
1500
|
+
var rendererTableHeaderEqualHeightStylesAllowNestedHeaderLinks = css(_defineProperty({}, ".".concat(RendererCssClassName.DOCUMENT, " .").concat(TableSharedCssClassName.TABLE_CONTAINER), _defineProperty({}, ".".concat(TableSharedCssClassName.TABLE_NODE_WRAPPER, " > table, .").concat(TableSharedCssClassName.TABLE_STICKY_WRAPPER, " > table"), _defineProperty({}, ".".concat(RendererCssClassName.SORTABLE_COLUMN_WRAPPER), _defineProperty({}, ".".concat(RendererCssClassName.SORTABLE_COLUMN), _defineProperty(_defineProperty({}, ".".concat(HeadingAnchorWrapperClassName), {
|
|
1501
|
+
position: 'unset'
|
|
1502
|
+
}), '> .renderer-heading-wrapper >', {
|
|
1503
|
+
'h1, h2, h3, h4, h5, h6': {
|
|
1504
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
1505
|
+
marginRight: '30px'
|
|
1506
|
+
}
|
|
1507
|
+
}))))));
|
|
1318
1508
|
|
|
1319
1509
|
// @ts-expect-error - throw TS error when use !import in position.
|
|
1320
1510
|
var stickyHeaderStyles = css({
|
|
@@ -1486,7 +1676,10 @@ var rendererAnnotationStyles = css({
|
|
|
1486
1676
|
borderBottom: "var(--ds-border-width-selected, 2px)".concat(" solid ", "var(--ds-border-accent-yellow, ".concat(Y300, ")")),
|
|
1487
1677
|
boxShadow: "var(--ds-shadow-overlay, ".concat("1px 2px 3px ".concat(N60A, ", -1px 2px 3px ").concat(N60A), ")"),
|
|
1488
1678
|
cursor: 'pointer',
|
|
1489
|
-
|
|
1679
|
+
paddingTop: "var(--ds-space-050, 4px)",
|
|
1680
|
+
paddingRight: "var(--ds-space-025, 2px)",
|
|
1681
|
+
paddingBottom: "var(--ds-space-050, 4px)",
|
|
1682
|
+
paddingLeft: "var(--ds-space-025, 2px)"
|
|
1490
1683
|
}
|
|
1491
1684
|
});
|
|
1492
1685
|
var rendererAnnotationStylesCommentHeightFix = css({
|
|
@@ -1494,8 +1687,12 @@ var rendererAnnotationStylesCommentHeightFix = css({
|
|
|
1494
1687
|
'& [data-annotation-draft-mark][data-annotation-inline-node]': {
|
|
1495
1688
|
borderBottom: "var(--ds-border-width-selected, 2px)".concat(" solid transparent"),
|
|
1496
1689
|
cursor: 'pointer',
|
|
1497
|
-
|
|
1498
|
-
|
|
1690
|
+
// eslint-disable-next-line @atlaskit/design-system/use-tokens-space
|
|
1691
|
+
paddingTop: '1px',
|
|
1692
|
+
paddingRight: 0,
|
|
1693
|
+
paddingBottom: "var(--ds-space-025, 2px)",
|
|
1694
|
+
paddingLeft: 0,
|
|
1695
|
+
backgroundColor: "var(--ds-background-accent-yellow-subtler, ".concat(Y75, ")"),
|
|
1499
1696
|
borderBottomColor: "var(--ds-border-accent-yellow, ".concat(Y300, ")"),
|
|
1500
1697
|
boxShadow: "var(--ds-shadow-overlay, ".concat("1px 2px 3px ".concat(N60A, ", -1px 2px 3px ").concat(N60A), ")")
|
|
1501
1698
|
},
|
|
@@ -1672,15 +1869,15 @@ export var RendererStyleContainer = function RendererStyleContainer(props) {
|
|
|
1672
1869
|
'--ak-renderer-editor-font-heading-h6': "".concat(editorUGCToken('editor.font.heading.h6')),
|
|
1673
1870
|
'--ak-renderer-editor-font-normal-text': "".concat(editorUGCToken('editor.font.body'))
|
|
1674
1871
|
},
|
|
1675
|
-
css: [baseStyles, hideHeadingCopyLinkWrapperStyles, appearance === 'full-page' && isPreviewPanelResponsivenessOn && rendererFullPageStylesWithReducedPadding, appearance === 'full-page' && !isPreviewPanelResponsivenessOn && rendererFullPageStyles, appearance === 'full-width' && rendererFullWidthStyles, (appearance === 'full-width' || appearance === 'max' && (expValEquals('editor_tinymce_full_width_mode', 'isEnabled', true) || expValEquals('confluence_max_width_content_appearance', 'isEnabled', true))) && !isTableResizingEnabled(appearance) && rendererFullWidthStylesForTableResizing, appearance === 'max' && (expValEquals('editor_tinymce_full_width_mode', 'isEnabled', true) || expValEquals('confluence_max_width_content_appearance', 'isEnabled', true)) && rendererMaxWidthStyles, rovoTelepointerStyles, whitespaceSharedStyles, blockquoteSharedStyles,
|
|
1872
|
+
css: [baseStyles, expValEquals('platform_editor_copy_link_a11y_inconsistency_fix', 'isEnabled', true) ? headingAnchorStyles : headingAnchorStylesDuplicateAnchor, expValEquals('platform_editor_copy_link_a11y_inconsistency_fix', 'isEnabled', true) ? hideHeadingCopyLinkWrapperStyles : hideHeadingCopyLinkWrapperStylesDuplicateAnchor, appearance === 'full-page' && isPreviewPanelResponsivenessOn && rendererFullPageStylesWithReducedPadding, appearance === 'full-page' && !isPreviewPanelResponsivenessOn && rendererFullPageStyles, appearance === 'full-width' && rendererFullWidthStyles, (appearance === 'full-width' || appearance === 'max' && (expValEquals('editor_tinymce_full_width_mode', 'isEnabled', true) || expValEquals('confluence_max_width_content_appearance', 'isEnabled', true))) && !isTableResizingEnabled(appearance) && rendererFullWidthStylesForTableResizing, appearance === 'max' && (expValEquals('editor_tinymce_full_width_mode', 'isEnabled', true) || expValEquals('confluence_max_width_content_appearance', 'isEnabled', true)) && rendererMaxWidthStyles, rovoTelepointerStyles, whitespaceSharedStyles, blockquoteSharedStyles, headingsSharedStylesWithEditorUGC, expValEquals('platform_editor_copy_link_a11y_inconsistency_fix', 'isEnabled', true) ? headingWithAlignmentStyles : headingWithAlignmentStylesDuplicateAnchor, ruleSharedStyles, contentMode === 'compact' && isCompactModeSupported && extensionStyle, fg('platform_editor_typography_ugc') ? isCompactModeSupported ? paragraphStylesUGCScaledMargin : paragraphSharedStylesWithEditorUGC : isCompactModeSupported ? paragraphSharedStyleScaledMargin : paragraphSharedStyles, listsSharedStyles, browser.gecko && listsSharedStylesForGekko, indentationSharedStyles, fg('platform_editor__renderer_indentation_text_margin') && indentationSharedStylesWithMarginFix, expValEquals('platform_editor_copy_link_a11y_inconsistency_fix', 'isEnabled', true) ? blockMarksSharedStyles : blockMarksSharedStylesDuplicateAnchor, codeMarkSharedStyles, shadowSharedStyle, dateSharedStyle, textColorStyles, backgroundColorStyles, expValEquals('platform_editor_text_highlight_padding', 'isEnabled', true) &&
|
|
1676
1873
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-imported-style-values
|
|
1677
1874
|
textHighlightPaddingStyles, tasksAndDecisionsStyles, smartCardStyles, smartCardStylesAvatarFix, editorExperiment('platform_editor_preview_panel_linking_exp', true) && headerSmartCardStyles, smartCardStylesAvatarMarginFix, smartCardStylesAvatarListZeroMarginTop, fg('editor_inline_comments_on_inline_nodes') && rendererAnnotationStyles,
|
|
1678
1875
|
// eslint-disable-next-line @atlaskit/platform/no-preconditioning
|
|
1679
|
-
fg('editor_inline_comments_on_inline_nodes') && rendererAnnotationStylesCommentHeightFix, baseOtherStyles,
|
|
1876
|
+
fg('editor_inline_comments_on_inline_nodes') && rendererAnnotationStylesCommentHeightFix, expValEquals('platform_editor_copy_link_a11y_inconsistency_fix', 'isEnabled', true) ? baseOtherStyles : baseOtherStylesDuplicateAnchor,
|
|
1680
1877
|
// this should be placed after baseOtherStyles
|
|
1681
|
-
expValEquals('platform_editor_render_bodied_extension_as_inline', 'isEnabled', true) && extensionAsInlineStyle, expValEquals('confluence_insert_excerpt_inline_vertical_align', 'isEnabled', true) && inlineExtensionRendererMarginFix, allowNestedHeaderLinks && alignedHeadingAnchorStyle, mediaSingleSharedStyle,
|
|
1878
|
+
expValEquals('platform_editor_render_bodied_extension_as_inline', 'isEnabled', true) && extensionAsInlineStyle, expValEquals('confluence_insert_excerpt_inline_vertical_align', 'isEnabled', true) && inlineExtensionRendererMarginFix, allowNestedHeaderLinks && (expValEquals('platform_editor_copy_link_a11y_inconsistency_fix', 'isEnabled', true) ? alignedHeadingAnchorStyle : alignedHeadingAnchorStyleDuplicateAnchor), mediaSingleSharedStyle,
|
|
1682
1879
|
// merge firstWrappedMediaStyles with mediaSingleSharedStyle when clean up platform_editor_fix_media_in_renderer
|
|
1683
|
-
fg('platform_editor_fix_media_in_renderer') && firstWrappedMediaStyles, tableSharedStyle, tableRendererHeaderStylesForTableCellOnly, fg('platform_editor_bordered_panel_nested_in_table') && tableRendererNestedPanelStyles, isBackgroundClipBrowserFixNeeded() && tableStylesBackGroundClipForGeckoForTableCellOnly, fg('platform_editor_nested_dnd_styles_changes') ? firstNodeWithNotMarginTopWithNestedDnD : firstNodeWithNotMarginTop, rendererTableStyles, isStickyScrollbarEnabled(appearance) && stickyScrollbarStyles, rendererTableHeaderEqualHeightStylesForTableCellOnly, allowColumnSorting && rendererTableSortableColumnStyles, allowColumnSorting && allowNestedHeaderLinks && rendererTableHeaderEqualHeightStylesAllowNestedHeaderLinks, rendererTableColumnStyles, stickyHeaderStyles, codeBlockAndLayoutStyles, columnLayoutSharedStyle, isAdvancedLayoutsOn && columnLayoutResponsiveSharedStyle, isAdvancedLayoutsOn && columnLayoutResponsiveRendererStyles, isAdvancedLayoutsOn && layoutSectionForAdvancedLayoutsStyles, !useBlockRenderForCodeBlock && gridRenderForCodeBlockStyles, browser.safari && codeBlockInListSafariFixStyles, appearance === 'full-page' && !isPreviewPanelResponsivenessOn && responsiveBreakoutWidth, appearance === 'full-page' && isPreviewPanelResponsivenessOn && responsiveBreakoutWidthWithReducedPadding, (appearance === 'full-width' || appearance === 'max' && (expValEquals('editor_tinymce_full_width_mode', 'isEnabled', true) || expValEquals('confluence_max_width_content_appearance', 'isEnabled', true))) && responsiveBreakoutWidthFullWidth, expValEquals('platform_editor_lovability_emoji_scaling', 'isEnabled', true) ? isCompactModeEnabled ? scaledDenseEmojiStyles : scaledEmojiStyles : isCompactModeEnabled ? denseStyles : undefined, expValEquals('platform_synced_block', 'isEnabled', true) && syncBlockStyles, expValEquals('platform_synced_block', 'isEnabled', true) && fg('platform_synced_block_dogfooding') && syncBlockOverflowStyles],
|
|
1880
|
+
fg('platform_editor_fix_media_in_renderer') && firstWrappedMediaStyles, tableSharedStyle, tableRendererHeaderStylesForTableCellOnly, fg('platform_editor_bordered_panel_nested_in_table') && tableRendererNestedPanelStyles, isBackgroundClipBrowserFixNeeded() && tableStylesBackGroundClipForGeckoForTableCellOnly, fg('platform_editor_nested_dnd_styles_changes') ? firstNodeWithNotMarginTopWithNestedDnD : firstNodeWithNotMarginTop, rendererTableStyles, isStickyScrollbarEnabled(appearance) && stickyScrollbarStyles, rendererTableHeaderEqualHeightStylesForTableCellOnly, allowColumnSorting && rendererTableSortableColumnStyles, allowColumnSorting && allowNestedHeaderLinks && (expValEquals('platform_editor_copy_link_a11y_inconsistency_fix', 'isEnabled', true) ? rendererTableHeaderEqualHeightStylesAllowNestedHeaderLinks : rendererTableHeaderEqualHeightStylesAllowNestedHeaderLinksDuplicateAnchor), rendererTableColumnStyles, stickyHeaderStyles, codeBlockAndLayoutStyles, columnLayoutSharedStyle, isAdvancedLayoutsOn && columnLayoutResponsiveSharedStyle, isAdvancedLayoutsOn && columnLayoutResponsiveRendererStyles, isAdvancedLayoutsOn && layoutSectionForAdvancedLayoutsStyles, !useBlockRenderForCodeBlock && gridRenderForCodeBlockStyles, browser.safari && codeBlockInListSafariFixStyles, appearance === 'full-page' && !isPreviewPanelResponsivenessOn && responsiveBreakoutWidth, appearance === 'full-page' && isPreviewPanelResponsivenessOn && responsiveBreakoutWidthWithReducedPadding, (appearance === 'full-width' || appearance === 'max' && (expValEquals('editor_tinymce_full_width_mode', 'isEnabled', true) || expValEquals('confluence_max_width_content_appearance', 'isEnabled', true))) && responsiveBreakoutWidthFullWidth, expValEquals('platform_editor_lovability_emoji_scaling', 'isEnabled', true) ? isCompactModeEnabled ? scaledDenseEmojiStyles : scaledEmojiStyles : isCompactModeEnabled ? denseStyles : undefined, expValEquals('platform_synced_block', 'isEnabled', true) && syncBlockStyles, expValEquals('platform_synced_block', 'isEnabled', true) && fg('platform_synced_block_dogfooding') && syncBlockOverflowStyles],
|
|
1684
1881
|
"data-testid": testId
|
|
1685
1882
|
}, children)
|
|
1686
1883
|
);
|