@atlaskit/editor-common 88.7.0 → 88.8.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +23 -0
- package/browser/package.json +15 -0
- package/dist/cjs/icons/index.js +7 -0
- package/dist/cjs/icons/shared/DynamicStrokeIconDecoration.js +46 -0
- package/dist/cjs/monitoring/error.js +1 -1
- package/dist/cjs/styles/index.js +6 -0
- package/dist/cjs/styles/shared/lists.js +2 -2
- package/dist/cjs/styles/shared/plugins.js +7 -1
- package/dist/cjs/styles/shared/table.js +3 -3
- package/dist/cjs/ui/DropList/index.js +1 -1
- package/dist/cjs/utils/analytics.js +7 -27
- package/dist/cjs/utils/browser.js +3 -4
- package/dist/cjs/utils/index.js +20 -5
- package/dist/cjs/utils/unsupportedContent/types.js +5 -0
- package/dist/es2019/icons/index.js +1 -0
- package/dist/es2019/icons/shared/DynamicStrokeIconDecoration.js +40 -0
- package/dist/es2019/monitoring/error.js +1 -1
- package/dist/es2019/styles/index.js +1 -1
- package/dist/es2019/styles/shared/lists.js +1 -1
- package/dist/es2019/styles/shared/plugins.js +6 -0
- package/dist/es2019/styles/shared/table.js +3 -3
- package/dist/es2019/ui/DropList/index.js +1 -1
- package/dist/es2019/utils/analytics.js +1 -2
- package/dist/es2019/utils/browser.js +1 -1
- package/dist/es2019/utils/index.js +47 -3
- package/dist/es2019/utils/unsupportedContent/types.js +1 -0
- package/dist/esm/icons/index.js +1 -0
- package/dist/esm/icons/shared/DynamicStrokeIconDecoration.js +39 -0
- package/dist/esm/monitoring/error.js +1 -1
- package/dist/esm/styles/index.js +1 -1
- package/dist/esm/styles/shared/lists.js +1 -1
- package/dist/esm/styles/shared/plugins.js +6 -0
- package/dist/esm/styles/shared/table.js +3 -3
- package/dist/esm/ui/DropList/index.js +1 -1
- package/dist/esm/utils/analytics.js +1 -2
- package/dist/esm/utils/browser.js +1 -1
- package/dist/esm/utils/index.js +47 -3
- package/dist/esm/utils/unsupportedContent/types.js +1 -0
- package/dist/types/icons/index.d.ts +1 -0
- package/dist/types/icons/shared/DynamicStrokeIconDecoration.d.ts +13 -0
- package/dist/types/styles/index.d.ts +1 -1
- package/dist/types/styles/shared/plugins.d.ts +1 -0
- package/dist/types/utils/analytics.d.ts +1 -20
- package/dist/types/utils/browser.d.ts +1 -1
- package/dist/types/utils/index.d.ts +48 -4
- package/dist/types/utils/track-unsupported-content.d.ts +1 -1
- package/dist/types/utils/unsupportedContent/types.d.ts +18 -0
- package/dist/types/utils/validate-using-spec.d.ts +1 -1
- package/dist/types-ts4.5/icons/index.d.ts +1 -0
- package/dist/types-ts4.5/icons/shared/DynamicStrokeIconDecoration.d.ts +13 -0
- package/dist/types-ts4.5/styles/index.d.ts +1 -1
- package/dist/types-ts4.5/styles/shared/plugins.d.ts +1 -0
- package/dist/types-ts4.5/utils/analytics.d.ts +1 -20
- package/dist/types-ts4.5/utils/browser.d.ts +1 -1
- package/dist/types-ts4.5/utils/index.d.ts +48 -4
- package/dist/types-ts4.5/utils/track-unsupported-content.d.ts +1 -1
- package/dist/types-ts4.5/utils/unsupportedContent/types.d.ts +18 -0
- package/dist/types-ts4.5/utils/validate-using-spec.d.ts +1 -1
- package/package.json +4 -5
- package/utils/analytics/package.json +15 -0
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @jsxRuntime classic
|
|
3
|
+
* @jsx jsx
|
|
4
|
+
*/
|
|
5
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
6
|
+
import { css, jsx } from '@emotion/react';
|
|
7
|
+
import { Box, xcss } from '@atlaskit/primitives';
|
|
8
|
+
var barStyles = css({
|
|
9
|
+
position: 'absolute',
|
|
10
|
+
left: 0,
|
|
11
|
+
right: 0,
|
|
12
|
+
top: "var(--ds-space-250, 20px)",
|
|
13
|
+
margin: 'auto',
|
|
14
|
+
width: "var(--ds-space-200, 16px)",
|
|
15
|
+
height: '3px'
|
|
16
|
+
});
|
|
17
|
+
var textColorIconWrapper = xcss({
|
|
18
|
+
position: 'relative'
|
|
19
|
+
});
|
|
20
|
+
var getBackground = function getBackground(selectedColor, disabled) {
|
|
21
|
+
if (selectedColor) {
|
|
22
|
+
return selectedColor;
|
|
23
|
+
}
|
|
24
|
+
return disabled ? "var(--ds-icon-disabled, #091E424F)" : "var(--ds-icon, #44546F)";
|
|
25
|
+
};
|
|
26
|
+
export var DynamicStrokeIconDecoration = function DynamicStrokeIconDecoration(_ref) {
|
|
27
|
+
var selectedColor = _ref.selectedColor,
|
|
28
|
+
disabled = _ref.disabled,
|
|
29
|
+
icon = _ref.icon;
|
|
30
|
+
return jsx(Box, {
|
|
31
|
+
xcss: textColorIconWrapper
|
|
32
|
+
}, icon, jsx("div", {
|
|
33
|
+
"data-testid": "toolbar-icon-dynamic-stroke",
|
|
34
|
+
style: {
|
|
35
|
+
background: getBackground(selectedColor, disabled)
|
|
36
|
+
},
|
|
37
|
+
css: barStyles
|
|
38
|
+
}));
|
|
39
|
+
};
|
|
@@ -7,7 +7,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
7
7
|
import { isFedRamp } from './environment';
|
|
8
8
|
var SENTRY_DSN = 'https://0b10c8e02fb44d8796c047b102c9bee8@o55978.ingest.sentry.io/4505129224110080';
|
|
9
9
|
var packageName = 'editor-common'; // Sentry doesn't accept '/' in its releases https://docs.sentry.io/platforms/javascript/configuration/releases/
|
|
10
|
-
var packageVersion = "88.
|
|
10
|
+
var packageVersion = "88.8.1";
|
|
11
11
|
var sanitiseSentryEvents = function sanitiseSentryEvents(data, _hint) {
|
|
12
12
|
// Remove URL as it has UGC
|
|
13
13
|
// TODO: Sanitise the URL instead of just removing it
|
package/dist/esm/styles/index.js
CHANGED
|
@@ -27,7 +27,7 @@ export { resizerStyles, resizerHandleClassName, resizerHandleTrackClassName, res
|
|
|
27
27
|
export { gridStyles, GRID_GUTTER } from './shared/grid';
|
|
28
28
|
export { smartCardStyles, FLOATING_TOOLBAR_LINKPICKER_CLASSNAME, DATASOURCE_INNER_CONTAINER_CLASSNAME } from './shared/smartCard';
|
|
29
29
|
export { embedCardStyles, embedSpacingStyles } from './shared/embedCard';
|
|
30
|
-
export { buttonGroupStyle, separatorStyles, wrapperStyle, triggerWrapperStyles } from './shared/plugins';
|
|
30
|
+
export { buttonGroupStyle, separatorStyles, wrapperStyle, triggerWrapperStyles, triggerWrapperStylesWithPadding } from './shared/plugins';
|
|
31
31
|
export { UnsupportedSharedCssClassName, unsupportedStyles } from './shared/unsupported-content';
|
|
32
32
|
export { expandIconWrapperStyle, expandClassNames, expandIconContainerStyle } from './shared/expand';
|
|
33
33
|
export { sharedExpandStyles } from '../ui/Expand/sharedStyles';
|
|
@@ -5,7 +5,7 @@ var _templateObject;
|
|
|
5
5
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
6
6
|
import { css } from '@emotion/react';
|
|
7
7
|
import { bulletListSelector, orderedListSelector } from '@atlaskit/adf-schema';
|
|
8
|
-
import browser from '../../utils/browser';
|
|
8
|
+
import { browser } from '../../utils/browser';
|
|
9
9
|
export var listItemCounterPadding = 24;
|
|
10
10
|
var CSS_VAR_NAMES = /*#__PURE__*/function (CSS_VAR_NAMES) {
|
|
11
11
|
CSS_VAR_NAMES["ITEM_COUNTER_PADDING"] = "--ed--list--item-counter--padding";
|
|
@@ -42,4 +42,10 @@ export var wrapperStyle = css({
|
|
|
42
42
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
43
43
|
export var triggerWrapperStyles = css({
|
|
44
44
|
display: 'flex'
|
|
45
|
+
});
|
|
46
|
+
|
|
47
|
+
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles
|
|
48
|
+
export var triggerWrapperStylesWithPadding = css({
|
|
49
|
+
display: 'flex',
|
|
50
|
+
paddingRight: "var(--ds-space-025, 2px)"
|
|
45
51
|
});
|
|
@@ -4,8 +4,8 @@ var _templateObject;
|
|
|
4
4
|
import { css } from '@emotion/react';
|
|
5
5
|
import { tableCellContentDomSelector, tableCellSelector, tableHeaderSelector, tablePrefixSelector } from '@atlaskit/adf-schema';
|
|
6
6
|
import { akEditorBreakoutPadding, akEditorFullWidthLayoutWidth, akEditorSelectedNodeClassName, akEditorTableBorder, akEditorTableNumberColumnWidth, akEditorTableToolbar, akEditorWideLayoutWidth, overflowShadow } from '@atlaskit/editor-shared-styles';
|
|
7
|
-
import {
|
|
8
|
-
import browser from '../../utils/browser';
|
|
7
|
+
import { editorExperiment } from '@atlaskit/tmp-editor-statsig/experiments';
|
|
8
|
+
import { browser } from '../../utils/browser';
|
|
9
9
|
import { CodeBlockSharedCssClassName } from './code-block';
|
|
10
10
|
import { tableCellBackgroundStyleOverride } from './tableCell';
|
|
11
11
|
export var tableMarginTop = 24;
|
|
@@ -41,7 +41,7 @@ export var TableSharedCssClassName = {
|
|
|
41
41
|
|
|
42
42
|
// eslint-disable-next-line @atlaskit/design-system/no-css-tagged-template-expression -- Appears safe to auto-fix, but leaving it up to the team to remediate as the readability only gets worse with autofixing
|
|
43
43
|
var tableSharedStyle = function tableSharedStyle() {
|
|
44
|
-
return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\t", "\n\t.", " {\n\t\tposition: relative;\n\t\tmargin: 0 auto ", ";\n\t\tbox-sizing: border-box;\n\n\t\t/**\n * Fix block top alignment inside table cells.\n */\n\t\t.decisionItemView-content-wrap:first-of-type > div {\n\t\t\tmargin-top: 0;\n\t\t}\n\t}\n\t.", "[data-number-column='true'] {\n\t\tpadding-left: ", "px;\n\t\tclear: both;\n\t}\n\n\t.", " {\n\t\twill-change: width, margin-left;\n\t}\n\n\t.", " table {\n\t\twill-change: width;\n\t}\n\n\t.", " > table {\n\t\tmargin: ", " 0 0 0;\n\t}\n\n\t.", " > table,\n\t.", " > table {\n\t\tmargin: ", " ", " 0 0;\n\t}\n\n\t/* avoid applying styles to nested tables (possible via extensions) */\n\t.", " > table,\n\t.", " > table,\n\t.", " > table {\n\t\tborder-collapse: collapse;\n\t\tborder: ", "px solid\n\t\t\t", ";\n\t\ttable-layout: fixed;\n\t\tfont-size: 1em;\n\t\twidth: 100%;\n\n\t\t&[data-autosize='true'] {\n\t\t\ttable-layout: auto;\n\t\t}\n\n\t\t& {\n\t\t\t* {\n\t\t\t\tbox-sizing: border-box;\n\t\t\t}\n\t\t\thr {\n\t\t\t\tbox-sizing: content-box;\n\t\t\t}\n\n\t\t\ttbody {\n\t\t\t\tborder-bottom: none;\n\t\t\t}\n\t\t\tth td {\n\t\t\t\tbackground-color: ", ";\n\t\t\t}\n\t\t\tth,\n\t\t\ttd {\n\t\t\t\tmin-width: ", "px;\n\t\t\t\tfont-weight: normal;\n\t\t\t\tvertical-align: top;\n\t\t\t\tborder: 1px solid ", ";\n\t\t\t\tborder-right-width: 0;\n\t\t\t\tborder-bottom-width: 0;\n\n\t\t\t\tpadding: ", ";\n\t\t\t\t/* https://stackoverflow.com/questions/7517127/borders-not-shown-in-firefox-with-border-collapse-on-table-position-relative-o */\n\t\t\t\t", "\n\n\t\t\t\t> :first-child:not(style),\n > style:first-child + * {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\n\t\t\t\t> .ProseMirror-gapcursor:first-child + *,\n\t\t\t\t> style:first-child + .ProseMirror-gapcursor + * {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\n\t\t\t\t> .ProseMirror-gapcursor:first-child + span + *,\n\t\t\t\t> style:first-child + .ProseMirror-gapcursor + span + * {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\n\t\t\t\tth p:not(:first-of-type),\n\t\t\t\ttd p:not(:first-of-type) {\n\t\t\t\t\tmargin-top: ", ";\n\t\t\t\t}\n\t\t\t}\n\t\t\tth {\n\t\t\t\tbackground-color: ", ";\n\t\t\t\ttext-align: left;\n\n\t\t\t\t/* only apply this styling to codeblocks in default background headercells */\n\t\t\t\t/* TODO this needs to be overhauled as it relies on unsafe selectors */\n\t\t\t\t&:not([style]):not(.danger) {\n\t\t\t\t\t.", ":not(.danger) {\n\t\t\t\t\t\tbackground-color: ", ";\n\n\t\t\t\t\t\t:not(.", ") {\n\t\t\t\t\t\t\tbox-shadow: 0px 0px 0px 1px ", ";\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t.", " {\n\t\t\t\t\t\t\tbackground-image: ", ";\n\n\t\t\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t.", " {\n\t\t\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/* this is only relevant to the element taken care of by renderer */\n\t\t\t\t\t\t> [data-ds--code--code-block] {\n\t\t\t\t\t\t\tbackground-image: ", "!important;\n\n\t\t\t\t\t\t\tbackground-color: ", "!important;\n\n\t\t\t\t\t\t\t// selector lives inside @atlaskit/code\n\t\t\t\t\t\t\t--ds--code--line-number-bg-color: ", ";\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n"])), tableCellBackgroundStyleOverride(), TableSharedCssClassName.TABLE_CONTAINER, "var(--ds-space-200, 16px)", TableSharedCssClassName.TABLE_CONTAINER, akEditorTableNumberColumnWidth - 1, TableSharedCssClassName.TABLE_RESIZER_CONTAINER, TableSharedCssClassName.TABLE_RESIZER_CONTAINER, TableSharedCssClassName.TABLE_NODE_WRAPPER, "var(--ds-space-300, 24px)", TableSharedCssClassName.TABLE_CONTAINER, TableSharedCssClassName.TABLE_STICKY_WRAPPER, "var(--ds-space-300, 24px)", "var(--ds-space-100, 8px)", TableSharedCssClassName.TABLE_CONTAINER, TableSharedCssClassName.TABLE_NODE_WRAPPER, TableSharedCssClassName.TABLE_STICKY_WRAPPER, tableCellBorderWidth, "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")"), "var(--ds-background-neutral-subtle, white)", tableCellMinWidth, "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")"),
|
|
44
|
+
return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n\t", "\n\t.", " {\n\t\tposition: relative;\n\t\tmargin: 0 auto ", ";\n\t\tbox-sizing: border-box;\n\n\t\t/**\n * Fix block top alignment inside table cells.\n */\n\t\t.decisionItemView-content-wrap:first-of-type > div {\n\t\t\tmargin-top: 0;\n\t\t}\n\t}\n\t.", "[data-number-column='true'] {\n\t\tpadding-left: ", "px;\n\t\tclear: both;\n\t}\n\n\t.", " {\n\t\twill-change: width, margin-left;\n\t}\n\n\t.", " table {\n\t\twill-change: width;\n\t}\n\n\t.", " > table {\n\t\tmargin: ", " 0 0 0;\n\t}\n\n\t.", " > table,\n\t.", " > table {\n\t\tmargin: ", " ", " 0 0;\n\t}\n\n\t/* avoid applying styles to nested tables (possible via extensions) */\n\t.", " > table,\n\t.", " > table,\n\t.", " > table {\n\t\tborder-collapse: collapse;\n\t\tborder: ", "px solid\n\t\t\t", ";\n\t\ttable-layout: fixed;\n\t\tfont-size: 1em;\n\t\twidth: 100%;\n\n\t\t&[data-autosize='true'] {\n\t\t\ttable-layout: auto;\n\t\t}\n\n\t\t& {\n\t\t\t* {\n\t\t\t\tbox-sizing: border-box;\n\t\t\t}\n\t\t\thr {\n\t\t\t\tbox-sizing: content-box;\n\t\t\t}\n\n\t\t\ttbody {\n\t\t\t\tborder-bottom: none;\n\t\t\t}\n\t\t\tth td {\n\t\t\t\tbackground-color: ", ";\n\t\t\t}\n\t\t\tth,\n\t\t\ttd {\n\t\t\t\tmin-width: ", "px;\n\t\t\t\tfont-weight: normal;\n\t\t\t\tvertical-align: top;\n\t\t\t\tborder: 1px solid ", ";\n\t\t\t\tborder-right-width: 0;\n\t\t\t\tborder-bottom-width: 0;\n\n\t\t\t\tpadding: ", ";\n\t\t\t\t/* https://stackoverflow.com/questions/7517127/borders-not-shown-in-firefox-with-border-collapse-on-table-position-relative-o */\n\t\t\t\t", "\n\n\t\t\t\t> :first-child:not(style),\n > style:first-child + * {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\n\t\t\t\t> .ProseMirror-gapcursor:first-child + *,\n\t\t\t\t> style:first-child + .ProseMirror-gapcursor + * {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\n\t\t\t\t> .ProseMirror-gapcursor:first-child + span + *,\n\t\t\t\t> style:first-child + .ProseMirror-gapcursor + span + * {\n\t\t\t\t\tmargin-top: 0;\n\t\t\t\t}\n\n\t\t\t\tth p:not(:first-of-type),\n\t\t\t\ttd p:not(:first-of-type) {\n\t\t\t\t\tmargin-top: ", ";\n\t\t\t\t}\n\t\t\t}\n\t\t\tth {\n\t\t\t\tbackground-color: ", ";\n\t\t\t\ttext-align: left;\n\n\t\t\t\t/* only apply this styling to codeblocks in default background headercells */\n\t\t\t\t/* TODO this needs to be overhauled as it relies on unsafe selectors */\n\t\t\t\t&:not([style]):not(.danger) {\n\t\t\t\t\t.", ":not(.danger) {\n\t\t\t\t\t\tbackground-color: ", ";\n\n\t\t\t\t\t\t:not(.", ") {\n\t\t\t\t\t\t\tbox-shadow: 0px 0px 0px 1px ", ";\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t.", " {\n\t\t\t\t\t\t\tbackground-image: ", ";\n\n\t\t\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t.", " {\n\t\t\t\t\t\t\tbackground-color: ", ";\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/* this is only relevant to the element taken care of by renderer */\n\t\t\t\t\t\t> [data-ds--code--code-block] {\n\t\t\t\t\t\t\tbackground-image: ", "!important;\n\n\t\t\t\t\t\t\tbackground-color: ", "!important;\n\n\t\t\t\t\t\t\t// selector lives inside @atlaskit/code\n\t\t\t\t\t\t\t--ds--code--line-number-bg-color: ", ";\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n"])), tableCellBackgroundStyleOverride(), TableSharedCssClassName.TABLE_CONTAINER, "var(--ds-space-200, 16px)", TableSharedCssClassName.TABLE_CONTAINER, akEditorTableNumberColumnWidth - 1, TableSharedCssClassName.TABLE_RESIZER_CONTAINER, TableSharedCssClassName.TABLE_RESIZER_CONTAINER, TableSharedCssClassName.TABLE_NODE_WRAPPER, "var(--ds-space-300, 24px)", TableSharedCssClassName.TABLE_CONTAINER, TableSharedCssClassName.TABLE_STICKY_WRAPPER, "var(--ds-space-300, 24px)", "var(--ds-space-100, 8px)", TableSharedCssClassName.TABLE_CONTAINER, TableSharedCssClassName.TABLE_NODE_WRAPPER, TableSharedCssClassName.TABLE_STICKY_WRAPPER, tableCellBorderWidth, "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")"), "var(--ds-background-neutral-subtle, white)", tableCellMinWidth, "var(--ds-background-accent-gray-subtler, ".concat(akEditorTableBorder, ")"), editorExperiment('table-nested-dnd', true) ? "var(--ds-space-100, 8px)".concat(" ", "var(--ds-space-250, 20px)") : "var(--ds-space-100, 8px)", browser.gecko || browser.ie || browser.mac && browser.chrome ? 'background-clip: padding-box;' : '', "var(--ds-space-150, 12px)", "var(--ds-background-accent-gray-subtlest, ".concat(akEditorTableToolbar, ")"), CodeBlockSharedCssClassName.CODEBLOCK_CONTAINER, "var(--ds-surface-raised, rgb(235, 237, 240))", akEditorSelectedNodeClassName, "var(--ds-border, transparent)", CodeBlockSharedCssClassName.CODEBLOCK_CONTENT_WRAPPER, overflowShadow({
|
|
45
45
|
leftCoverWidth: "var(--ds-space-300, 24px)"
|
|
46
46
|
}), "var(--ds-background-neutral, rgb(235, 237, 240))", CodeBlockSharedCssClassName.CODEBLOCK_LINE_NUMBER_GUTTER, "var(--ds-background-neutral, rgb(226, 229, 233))", overflowShadow({
|
|
47
47
|
leftCoverWidth: "var(--ds-space-300, 24px)"
|
|
@@ -22,7 +22,7 @@ import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
|
22
22
|
import { N0, N50A, N60A, N900 } from '@atlaskit/theme/colors';
|
|
23
23
|
import Layer from '../Layer';
|
|
24
24
|
var packageName = "@atlaskit/editor-common";
|
|
25
|
-
var packageVersion = "88.
|
|
25
|
+
var packageVersion = "88.8.1";
|
|
26
26
|
var halfFocusRing = 1;
|
|
27
27
|
var dropOffset = '0, 8';
|
|
28
28
|
var DropList = /*#__PURE__*/function (_Component) {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { EDITOR_APPEARANCE_CONTEXT } from '@atlaskit/analytics-namespaced-context';
|
|
1
|
+
import { EDITOR_APPEARANCE_CONTEXT } from '@atlaskit/analytics-namespaced-context/FabricEditorAnalyticsContext';
|
|
2
2
|
export var getAnalyticsAppearance = function getAnalyticsAppearance(appearance) {
|
|
3
3
|
switch (appearance) {
|
|
4
4
|
case 'full-page':
|
|
@@ -31,5 +31,4 @@ export var SEVERITY = /*#__PURE__*/function (SEVERITY) {
|
|
|
31
31
|
SEVERITY["BLOCKING"] = "blocking";
|
|
32
32
|
return SEVERITY;
|
|
33
33
|
}({});
|
|
34
|
-
export { UNSUPPORTED_CONTENT_LEVEL_SEVERITY, getUnsupportedContentLevelData, UNSUPPORTED_CONTENT_LEVEL_SEVERITY_THRESHOLD_DEFAULTS } from './unsupportedContent/get-unsupported-content-level-data';
|
|
35
34
|
export var analyticsEventKey = 'EDITOR_ANALYTICS_EVENT';
|
|
@@ -36,4 +36,4 @@ if (typeof navigator !== 'undefined') {
|
|
|
36
36
|
result.supportsIntersectionObserver = typeof window !== 'undefined' && 'IntersectionObserver' in window && 'IntersectionObserverEntry' in window && 'intersectionRatio' in window.IntersectionObserverEntry.prototype;
|
|
37
37
|
result.supportsResizeObserver = typeof window !== 'undefined' && 'ResizeObserver' in window && 'ResizeObserverEntry' in window;
|
|
38
38
|
}
|
|
39
|
-
export
|
|
39
|
+
export { result as browser };
|
package/dist/esm/utils/index.js
CHANGED
|
@@ -4,18 +4,56 @@ import { isEmptyParagraph } from './editor-core-utils';
|
|
|
4
4
|
export { shouldAutoLinkifyMatch } from './should-auto-linkify-tld';
|
|
5
5
|
export { getAnnotationMarksForPos, canApplyAnnotationOnRange, containsAnyAnnotations, getAnnotationIdsFromRange, getAnnotationInlineNodeTypes, hasAnnotationMark, getRangeInlineNodeNames } from './annotation';
|
|
6
6
|
export { getExtensionLozengeData } from './macro';
|
|
7
|
-
export {
|
|
7
|
+
export {
|
|
8
|
+
/**
|
|
9
|
+
* @private
|
|
10
|
+
* @deprecated
|
|
11
|
+
*
|
|
12
|
+
* Please use `@atlaskit/editor-common/browser` entry-point instead.
|
|
13
|
+
*/
|
|
14
|
+
browser } from './browser';
|
|
8
15
|
export { default as ErrorReporter } from './error-reporter';
|
|
9
16
|
export { isPastDate, timestampToIsoFormat, timestampToString, timestampToTaskContext, timestampToUTCDate, todayTimestampInUTC } from './date';
|
|
10
17
|
export { isElementInTableCell, isTextSelection, isLastItemMediaGroup, setNodeSelection, setTextSelection, setAllSelection, setCellSelection, nonNullable, stepAddsOneOf, stepHasSlice, extractSliceFromStep, isValidPosition, isEmptyParagraph, isInLayoutColumn, removeBlockMarks, filterChildrenBetween } from './editor-core-utils';
|
|
11
18
|
export { withImageLoader } from './imageLoader';
|
|
12
19
|
export { absoluteBreakoutWidth, calcBreakoutWidth, calcWideWidth, breakoutConsts, calculateBreakoutStyles, calcBreakoutWidthPx, getNextBreakoutMode, getTitle } from './breakout';
|
|
13
|
-
export {
|
|
20
|
+
export {
|
|
21
|
+
/**
|
|
22
|
+
* @private
|
|
23
|
+
* @deprecated
|
|
24
|
+
*
|
|
25
|
+
* This is only used in editor-core and shouldn't be used anywhere else.
|
|
26
|
+
* If you do need it please reach out to #cc-editor-lego
|
|
27
|
+
*/
|
|
28
|
+
findChangedNodesFromTransaction,
|
|
29
|
+
/**
|
|
30
|
+
* @private
|
|
31
|
+
* @deprecated
|
|
32
|
+
*
|
|
33
|
+
* This is only used in editor-core and shouldn't be used anywhere else.
|
|
34
|
+
* If you do need it please reach out to #cc-editor-lego
|
|
35
|
+
*/
|
|
36
|
+
validNode,
|
|
37
|
+
/**
|
|
38
|
+
* @private
|
|
39
|
+
* @deprecated
|
|
40
|
+
*
|
|
41
|
+
* This is only used in editor-core and shouldn't be used anywhere else.
|
|
42
|
+
* If you do need it please reach out to #cc-editor-lego
|
|
43
|
+
*/
|
|
44
|
+
validateNodes, isType, isParagraph, isText, isLinkMark, SelectedState, isNodeSelectedOrInRange, isSupportedInParent, isMediaNode, isNodeBeforeMediaNode } from './nodes';
|
|
14
45
|
export { pluginFactory } from './plugin-state-factory';
|
|
15
46
|
export { getFragmentBackingArray, mapFragment, mapSlice, flatmap, mapChildren } from './slice';
|
|
16
47
|
export { walkUpTreeUntil, unwrap, removeNestedEmptyEls, containsClassName, closest, closestElement, parsePx, mapElem, maphElem } from './dom';
|
|
17
48
|
export { default as ADFTraversor } from './traversor';
|
|
18
|
-
|
|
49
|
+
/**
|
|
50
|
+
* @private
|
|
51
|
+
* @deprecated
|
|
52
|
+
*
|
|
53
|
+
* Use entry-point `@atlaskit/editor-common/utils/analytics` instead
|
|
54
|
+
*/
|
|
55
|
+
export { analyticsEventKey, getAnalyticsAppearance, getAnalyticsEditorAppearance, getAnalyticsEventSeverity, SEVERITY } from './analytics';
|
|
56
|
+
export { getUnsupportedContentLevelData, UNSUPPORTED_CONTENT_LEVEL_SEVERITY, UNSUPPORTED_CONTENT_LEVEL_SEVERITY_THRESHOLD_DEFAULTS } from './unsupportedContent/get-unsupported-content-level-data';
|
|
19
57
|
export { findAndTrackUnsupportedContentNodes } from './track-unsupported-content';
|
|
20
58
|
export { getDistortedDurationMonitor, measureRender } from './performance/measure-render';
|
|
21
59
|
export { startMeasure, stopMeasure, clearMeasure } from './performance/measure';
|
|
@@ -39,6 +77,12 @@ export { RenderCountProfiler, PROFILER_KEY } from './profiler/render-count';
|
|
|
39
77
|
export { validateADFEntity, validationErrorHandler } from './validate-using-spec';
|
|
40
78
|
export { getShallowPropsDifference, getPropsDifference } from './compare-props';
|
|
41
79
|
export { useComponentRenderTracking } from './performance/hooks/use-component-render-tracking';
|
|
80
|
+
/**
|
|
81
|
+
* @private
|
|
82
|
+
* @deprecated
|
|
83
|
+
*
|
|
84
|
+
* Private API do not use
|
|
85
|
+
*/
|
|
42
86
|
export { isOutdatedBrowser } from './outdated-browsers';
|
|
43
87
|
export { autoJoinTr } from './prosemirror/autojoin';
|
|
44
88
|
export { isReferencedSource, removeConnectedNodes, getChildrenInfo, getNodeName } from './referentiality';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -8,4 +8,5 @@ export { PanelSuccessIcon } from './shared/PanelSuccessIcon';
|
|
|
8
8
|
export { PanelNoteIcon } from './shared/PanelNoteIcon';
|
|
9
9
|
export { BorderIcon } from './shared/BorderIcon';
|
|
10
10
|
export { SteppedRainbowIconDecoration } from './shared/SteppedRainbowIconDecoration';
|
|
11
|
+
export { DynamicStrokeIconDecoration } from './shared/DynamicStrokeIconDecoration';
|
|
11
12
|
export declare const IconTable: React.ComponentType<React.PropsWithChildren<IconProps>> & Loadable.LoadableComponent;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
/**
|
|
3
|
+
* @jsxRuntime classic
|
|
4
|
+
* @jsx jsx
|
|
5
|
+
*/
|
|
6
|
+
import { jsx } from '@emotion/react';
|
|
7
|
+
type DynamicStrokeIconDecorationProps = {
|
|
8
|
+
selectedColor?: string | null;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
icon: React.ReactNode;
|
|
11
|
+
};
|
|
12
|
+
export declare const DynamicStrokeIconDecoration: ({ selectedColor, disabled, icon, }: DynamicStrokeIconDecorationProps) => jsx.JSX.Element;
|
|
13
|
+
export {};
|
|
@@ -27,7 +27,7 @@ export { resizerStyles, resizerHandleClassName, resizerHandleTrackClassName, res
|
|
|
27
27
|
export { gridStyles, GRID_GUTTER } from './shared/grid';
|
|
28
28
|
export { smartCardStyles, FLOATING_TOOLBAR_LINKPICKER_CLASSNAME, DATASOURCE_INNER_CONTAINER_CLASSNAME, } from './shared/smartCard';
|
|
29
29
|
export { embedCardStyles, embedSpacingStyles } from './shared/embedCard';
|
|
30
|
-
export { buttonGroupStyle, separatorStyles, wrapperStyle, triggerWrapperStyles, } from './shared/plugins';
|
|
30
|
+
export { buttonGroupStyle, separatorStyles, wrapperStyle, triggerWrapperStyles, triggerWrapperStylesWithPadding, } from './shared/plugins';
|
|
31
31
|
export { UnsupportedSharedCssClassName, unsupportedStyles } from './shared/unsupported-content';
|
|
32
32
|
export { expandIconWrapperStyle, expandClassNames, expandIconContainerStyle, } from './shared/expand';
|
|
33
33
|
export { sharedExpandStyles } from '../ui/Expand/sharedStyles';
|
|
@@ -2,3 +2,4 @@ export declare const buttonGroupStyle: import("@emotion/react").SerializedStyles
|
|
|
2
2
|
export declare const separatorStyles: import("@emotion/react").SerializedStyles;
|
|
3
3
|
export declare const wrapperStyle: import("@emotion/react").SerializedStyles;
|
|
4
4
|
export declare const triggerWrapperStyles: import("@emotion/react").SerializedStyles;
|
|
5
|
+
export declare const triggerWrapperStylesWithPadding: import("@emotion/react").SerializedStyles;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { EDITOR_APPEARANCE_CONTEXT } from '@atlaskit/analytics-namespaced-context';
|
|
2
|
-
import { type ACTION, type ACTION_SUBJECT, type ACTION_SUBJECT_ID, type EVENT_TYPE } from '../analytics';
|
|
1
|
+
import { EDITOR_APPEARANCE_CONTEXT } from '@atlaskit/analytics-namespaced-context/FabricEditorAnalyticsContext';
|
|
3
2
|
export declare const getAnalyticsAppearance: (appearance?: string) => EDITOR_APPEARANCE_CONTEXT | undefined;
|
|
4
3
|
export declare const getAnalyticsEditorAppearance: (editorAppearance?: string) => string;
|
|
5
4
|
export declare const getAnalyticsEventSeverity: (duration: number, normalThreshold: number, degradedThreshold: number) => SEVERITY;
|
|
@@ -8,22 +7,4 @@ export declare enum SEVERITY {
|
|
|
8
7
|
DEGRADED = "degraded",
|
|
9
8
|
BLOCKING = "blocking"
|
|
10
9
|
}
|
|
11
|
-
export { UNSUPPORTED_CONTENT_LEVEL_SEVERITY, getUnsupportedContentLevelData, UNSUPPORTED_CONTENT_LEVEL_SEVERITY_THRESHOLD_DEFAULTS, } from './unsupportedContent/get-unsupported-content-level-data';
|
|
12
|
-
export type { UnsupportedContentLevelsTracking } from './unsupportedContent/get-unsupported-content-level-data';
|
|
13
|
-
type AEP<Action, ActionSubject, ActionSubjectID, Attributes, EventType> = {
|
|
14
|
-
action: Action;
|
|
15
|
-
actionSubject: ActionSubject;
|
|
16
|
-
actionSubjectId?: ActionSubjectID;
|
|
17
|
-
attributes?: Attributes;
|
|
18
|
-
eventType: EventType;
|
|
19
|
-
};
|
|
20
|
-
type TrackAEP<Action, ActionSubject, ActionSubjectID, Attributes> = AEP<Action, ActionSubject, ActionSubjectID, Attributes, EVENT_TYPE.TRACK>;
|
|
21
|
-
type UnsupportedContentEncounteredAEP = TrackAEP<ACTION.UNSUPPORTED_CONTENT_ENCOUNTERED, ACTION_SUBJECT.DOCUMENT, ACTION_SUBJECT_ID, {
|
|
22
|
-
unsupportedNode: Record<string, any>;
|
|
23
|
-
errorCode?: String;
|
|
24
|
-
}>;
|
|
25
|
-
export type UnsupportedContentPayload = UnsupportedContentEncounteredAEP;
|
|
26
|
-
export type UnsupportedContentTooltipPayload = AEP<ACTION.UNSUPPORTED_TOOLTIP_VIEWED, ACTION_SUBJECT.TOOLTIP, ACTION_SUBJECT_ID.ON_UNSUPPORTED_BLOCK | ACTION_SUBJECT_ID.ON_UNSUPPORTED_INLINE, {
|
|
27
|
-
unsupportedNodeType: string | undefined;
|
|
28
|
-
}, EVENT_TYPE.UI>;
|
|
29
10
|
export declare const analyticsEventKey = "EDITOR_ANALYTICS_EVENT";
|
|
@@ -5,7 +5,14 @@ export { shouldAutoLinkifyMatch } from './should-auto-linkify-tld';
|
|
|
5
5
|
export { getAnnotationMarksForPos, canApplyAnnotationOnRange, containsAnyAnnotations, getAnnotationIdsFromRange, getAnnotationInlineNodeTypes, hasAnnotationMark, getRangeInlineNodeNames, } from './annotation';
|
|
6
6
|
export { getExtensionLozengeData } from './macro';
|
|
7
7
|
export type { Params } from './macro';
|
|
8
|
-
export {
|
|
8
|
+
export {
|
|
9
|
+
/**
|
|
10
|
+
* @private
|
|
11
|
+
* @deprecated
|
|
12
|
+
*
|
|
13
|
+
* Please use `@atlaskit/editor-common/browser` entry-point instead.
|
|
14
|
+
*/
|
|
15
|
+
browser, } from './browser';
|
|
9
16
|
export { default as ErrorReporter } from './error-reporter';
|
|
10
17
|
export type { ErrorReportingHandler } from './error-reporter';
|
|
11
18
|
export { isPastDate, timestampToIsoFormat, timestampToString, timestampToTaskContext, timestampToUTCDate, todayTimestampInUTC, } from './date';
|
|
@@ -14,7 +21,31 @@ export { isElementInTableCell, isTextSelection, isLastItemMediaGroup, setNodeSel
|
|
|
14
21
|
export { withImageLoader } from './imageLoader';
|
|
15
22
|
export type { ImageLoaderProps, ImageLoaderState, ImageStatus } from './imageLoader';
|
|
16
23
|
export { absoluteBreakoutWidth, calcBreakoutWidth, calcWideWidth, breakoutConsts, calculateBreakoutStyles, calcBreakoutWidthPx, getNextBreakoutMode, getTitle, } from './breakout';
|
|
17
|
-
export {
|
|
24
|
+
export {
|
|
25
|
+
/**
|
|
26
|
+
* @private
|
|
27
|
+
* @deprecated
|
|
28
|
+
*
|
|
29
|
+
* This is only used in editor-core and shouldn't be used anywhere else.
|
|
30
|
+
* If you do need it please reach out to #cc-editor-lego
|
|
31
|
+
*/
|
|
32
|
+
findChangedNodesFromTransaction,
|
|
33
|
+
/**
|
|
34
|
+
* @private
|
|
35
|
+
* @deprecated
|
|
36
|
+
*
|
|
37
|
+
* This is only used in editor-core and shouldn't be used anywhere else.
|
|
38
|
+
* If you do need it please reach out to #cc-editor-lego
|
|
39
|
+
*/
|
|
40
|
+
validNode,
|
|
41
|
+
/**
|
|
42
|
+
* @private
|
|
43
|
+
* @deprecated
|
|
44
|
+
*
|
|
45
|
+
* This is only used in editor-core and shouldn't be used anywhere else.
|
|
46
|
+
* If you do need it please reach out to #cc-editor-lego
|
|
47
|
+
*/
|
|
48
|
+
validateNodes, isType, isParagraph, isText, isLinkMark, SelectedState, isNodeSelectedOrInRange, isSupportedInParent, isMediaNode, isNodeBeforeMediaNode, } from './nodes';
|
|
18
49
|
export type { Reducer } from './plugin-state-factory';
|
|
19
50
|
export { pluginFactory } from './plugin-state-factory';
|
|
20
51
|
export { getFragmentBackingArray, mapFragment, mapSlice, flatmap, mapChildren } from './slice';
|
|
@@ -22,8 +53,15 @@ export type { FlatMapCallback, MapWithCallback } from './slice';
|
|
|
22
53
|
export { walkUpTreeUntil, unwrap, removeNestedEmptyEls, containsClassName, closest, closestElement, parsePx, mapElem, maphElem, } from './dom';
|
|
23
54
|
export type { MapCallback } from './dom';
|
|
24
55
|
export { default as ADFTraversor } from './traversor';
|
|
25
|
-
|
|
26
|
-
|
|
56
|
+
/**
|
|
57
|
+
* @private
|
|
58
|
+
* @deprecated
|
|
59
|
+
*
|
|
60
|
+
* Use entry-point `@atlaskit/editor-common/utils/analytics` instead
|
|
61
|
+
*/
|
|
62
|
+
export { analyticsEventKey, getAnalyticsAppearance, getAnalyticsEditorAppearance, getAnalyticsEventSeverity, SEVERITY, } from './analytics';
|
|
63
|
+
export { getUnsupportedContentLevelData, UNSUPPORTED_CONTENT_LEVEL_SEVERITY, UNSUPPORTED_CONTENT_LEVEL_SEVERITY_THRESHOLD_DEFAULTS, type UnsupportedContentLevelsTracking, } from './unsupportedContent/get-unsupported-content-level-data';
|
|
64
|
+
export type { UnsupportedContentTooltipPayload, UnsupportedContentPayload, } from './unsupportedContent/types';
|
|
27
65
|
export { findAndTrackUnsupportedContentNodes } from './track-unsupported-content';
|
|
28
66
|
export { getDistortedDurationMonitor, measureRender } from './performance/measure-render';
|
|
29
67
|
export { startMeasure, stopMeasure, clearMeasure } from './performance/measure';
|
|
@@ -51,6 +89,12 @@ export { getShallowPropsDifference, getPropsDifference } from './compare-props';
|
|
|
51
89
|
export type { ShallowPropsDifference, PropsDifference } from './compare-props';
|
|
52
90
|
export { useComponentRenderTracking } from './performance/hooks/use-component-render-tracking';
|
|
53
91
|
export type { UseComponentRenderTrackingArgs } from './performance/hooks/use-component-render-tracking';
|
|
92
|
+
/**
|
|
93
|
+
* @private
|
|
94
|
+
* @deprecated
|
|
95
|
+
*
|
|
96
|
+
* Private API do not use
|
|
97
|
+
*/
|
|
54
98
|
export { isOutdatedBrowser } from './outdated-browsers';
|
|
55
99
|
export { autoJoinTr } from './prosemirror/autojoin';
|
|
56
100
|
export { isReferencedSource, removeConnectedNodes, getChildrenInfo, getNodeName, } from './referentiality';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Node as PMNode, Schema } from '@atlaskit/editor-prosemirror/model';
|
|
2
2
|
import { ACTION_SUBJECT_ID } from '../analytics';
|
|
3
|
-
import type { UnsupportedContentPayload, UnsupportedContentTooltipPayload } from './
|
|
3
|
+
import type { UnsupportedContentPayload, UnsupportedContentTooltipPayload } from './unsupportedContent/types';
|
|
4
4
|
type DispatchAnalyticsEvent = (payload: UnsupportedContentPayload) => void;
|
|
5
5
|
type DispatchAnalyticsEventTooltip = (payload: UnsupportedContentTooltipPayload) => void;
|
|
6
6
|
export declare const findAndTrackUnsupportedContentNodes: (node: PMNode, schema: Schema, dispatchAnalyticsEvent: DispatchAnalyticsEvent, ancestorHierarchy?: string) => void;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type ACTION, type ACTION_SUBJECT, type ACTION_SUBJECT_ID, type EVENT_TYPE } from '../../analytics';
|
|
2
|
+
type AEP<Action, ActionSubject, ActionSubjectID, Attributes, EventType> = {
|
|
3
|
+
action: Action;
|
|
4
|
+
actionSubject: ActionSubject;
|
|
5
|
+
actionSubjectId?: ActionSubjectID;
|
|
6
|
+
attributes?: Attributes;
|
|
7
|
+
eventType: EventType;
|
|
8
|
+
};
|
|
9
|
+
type TrackAEP<Action, ActionSubject, ActionSubjectID, Attributes> = AEP<Action, ActionSubject, ActionSubjectID, Attributes, EVENT_TYPE.TRACK>;
|
|
10
|
+
type UnsupportedContentEncounteredAEP = TrackAEP<ACTION.UNSUPPORTED_CONTENT_ENCOUNTERED, ACTION_SUBJECT.DOCUMENT, ACTION_SUBJECT_ID, {
|
|
11
|
+
unsupportedNode: Record<string, any>;
|
|
12
|
+
errorCode?: String;
|
|
13
|
+
}>;
|
|
14
|
+
export type UnsupportedContentPayload = UnsupportedContentEncounteredAEP;
|
|
15
|
+
export type UnsupportedContentTooltipPayload = AEP<ACTION.UNSUPPORTED_TOOLTIP_VIEWED, ACTION_SUBJECT.TOOLTIP, ACTION_SUBJECT_ID.ON_UNSUPPORTED_BLOCK | ACTION_SUBJECT_ID.ON_UNSUPPORTED_INLINE, {
|
|
16
|
+
unsupportedNodeType: string | undefined;
|
|
17
|
+
}, EVENT_TYPE.UI>;
|
|
18
|
+
export {};
|
|
@@ -2,7 +2,7 @@ import type { ADFEntity } from '@atlaskit/adf-utils/types';
|
|
|
2
2
|
import type { ErrorCallbackOptions, Validate, ValidationError } from '@atlaskit/adf-utils/validatorTypes';
|
|
3
3
|
import type { Schema } from '@atlaskit/editor-prosemirror/model';
|
|
4
4
|
export declare const UNSUPPORTED_NODE_ATTRIBUTE = "unsupportedNodeAttribute";
|
|
5
|
-
import type { UnsupportedContentPayload } from './
|
|
5
|
+
import type { UnsupportedContentPayload } from './unsupportedContent/types';
|
|
6
6
|
export type DispatchAnalyticsEvent = (event: UnsupportedContentPayload) => void;
|
|
7
7
|
export declare const validationErrorHandler: (entity: ADFEntity, error: ValidationError, options: ErrorCallbackOptions, marks: string[], validate: Validate, dispatchAnalyticsEvent?: DispatchAnalyticsEvent) => ADFEntity | {
|
|
8
8
|
type: string;
|
|
@@ -8,4 +8,5 @@ export { PanelSuccessIcon } from './shared/PanelSuccessIcon';
|
|
|
8
8
|
export { PanelNoteIcon } from './shared/PanelNoteIcon';
|
|
9
9
|
export { BorderIcon } from './shared/BorderIcon';
|
|
10
10
|
export { SteppedRainbowIconDecoration } from './shared/SteppedRainbowIconDecoration';
|
|
11
|
+
export { DynamicStrokeIconDecoration } from './shared/DynamicStrokeIconDecoration';
|
|
11
12
|
export declare const IconTable: React.ComponentType<React.PropsWithChildren<IconProps>> & Loadable.LoadableComponent;
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
/**
|
|
3
|
+
* @jsxRuntime classic
|
|
4
|
+
* @jsx jsx
|
|
5
|
+
*/
|
|
6
|
+
import { jsx } from '@emotion/react';
|
|
7
|
+
type DynamicStrokeIconDecorationProps = {
|
|
8
|
+
selectedColor?: string | null;
|
|
9
|
+
disabled?: boolean;
|
|
10
|
+
icon: React.ReactNode;
|
|
11
|
+
};
|
|
12
|
+
export declare const DynamicStrokeIconDecoration: ({ selectedColor, disabled, icon, }: DynamicStrokeIconDecorationProps) => jsx.JSX.Element;
|
|
13
|
+
export {};
|
|
@@ -27,7 +27,7 @@ export { resizerStyles, resizerHandleClassName, resizerHandleTrackClassName, res
|
|
|
27
27
|
export { gridStyles, GRID_GUTTER } from './shared/grid';
|
|
28
28
|
export { smartCardStyles, FLOATING_TOOLBAR_LINKPICKER_CLASSNAME, DATASOURCE_INNER_CONTAINER_CLASSNAME, } from './shared/smartCard';
|
|
29
29
|
export { embedCardStyles, embedSpacingStyles } from './shared/embedCard';
|
|
30
|
-
export { buttonGroupStyle, separatorStyles, wrapperStyle, triggerWrapperStyles, } from './shared/plugins';
|
|
30
|
+
export { buttonGroupStyle, separatorStyles, wrapperStyle, triggerWrapperStyles, triggerWrapperStylesWithPadding, } from './shared/plugins';
|
|
31
31
|
export { UnsupportedSharedCssClassName, unsupportedStyles } from './shared/unsupported-content';
|
|
32
32
|
export { expandIconWrapperStyle, expandClassNames, expandIconContainerStyle, } from './shared/expand';
|
|
33
33
|
export { sharedExpandStyles } from '../ui/Expand/sharedStyles';
|
|
@@ -2,3 +2,4 @@ export declare const buttonGroupStyle: import("@emotion/react").SerializedStyles
|
|
|
2
2
|
export declare const separatorStyles: import("@emotion/react").SerializedStyles;
|
|
3
3
|
export declare const wrapperStyle: import("@emotion/react").SerializedStyles;
|
|
4
4
|
export declare const triggerWrapperStyles: import("@emotion/react").SerializedStyles;
|
|
5
|
+
export declare const triggerWrapperStylesWithPadding: import("@emotion/react").SerializedStyles;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { EDITOR_APPEARANCE_CONTEXT } from '@atlaskit/analytics-namespaced-context';
|
|
2
|
-
import { type ACTION, type ACTION_SUBJECT, type ACTION_SUBJECT_ID, type EVENT_TYPE } from '../analytics';
|
|
1
|
+
import { EDITOR_APPEARANCE_CONTEXT } from '@atlaskit/analytics-namespaced-context/FabricEditorAnalyticsContext';
|
|
3
2
|
export declare const getAnalyticsAppearance: (appearance?: string) => EDITOR_APPEARANCE_CONTEXT | undefined;
|
|
4
3
|
export declare const getAnalyticsEditorAppearance: (editorAppearance?: string) => string;
|
|
5
4
|
export declare const getAnalyticsEventSeverity: (duration: number, normalThreshold: number, degradedThreshold: number) => SEVERITY;
|
|
@@ -8,22 +7,4 @@ export declare enum SEVERITY {
|
|
|
8
7
|
DEGRADED = "degraded",
|
|
9
8
|
BLOCKING = "blocking"
|
|
10
9
|
}
|
|
11
|
-
export { UNSUPPORTED_CONTENT_LEVEL_SEVERITY, getUnsupportedContentLevelData, UNSUPPORTED_CONTENT_LEVEL_SEVERITY_THRESHOLD_DEFAULTS, } from './unsupportedContent/get-unsupported-content-level-data';
|
|
12
|
-
export type { UnsupportedContentLevelsTracking } from './unsupportedContent/get-unsupported-content-level-data';
|
|
13
|
-
type AEP<Action, ActionSubject, ActionSubjectID, Attributes, EventType> = {
|
|
14
|
-
action: Action;
|
|
15
|
-
actionSubject: ActionSubject;
|
|
16
|
-
actionSubjectId?: ActionSubjectID;
|
|
17
|
-
attributes?: Attributes;
|
|
18
|
-
eventType: EventType;
|
|
19
|
-
};
|
|
20
|
-
type TrackAEP<Action, ActionSubject, ActionSubjectID, Attributes> = AEP<Action, ActionSubject, ActionSubjectID, Attributes, EVENT_TYPE.TRACK>;
|
|
21
|
-
type UnsupportedContentEncounteredAEP = TrackAEP<ACTION.UNSUPPORTED_CONTENT_ENCOUNTERED, ACTION_SUBJECT.DOCUMENT, ACTION_SUBJECT_ID, {
|
|
22
|
-
unsupportedNode: Record<string, any>;
|
|
23
|
-
errorCode?: String;
|
|
24
|
-
}>;
|
|
25
|
-
export type UnsupportedContentPayload = UnsupportedContentEncounteredAEP;
|
|
26
|
-
export type UnsupportedContentTooltipPayload = AEP<ACTION.UNSUPPORTED_TOOLTIP_VIEWED, ACTION_SUBJECT.TOOLTIP, ACTION_SUBJECT_ID.ON_UNSUPPORTED_BLOCK | ACTION_SUBJECT_ID.ON_UNSUPPORTED_INLINE, {
|
|
27
|
-
unsupportedNodeType: string | undefined;
|
|
28
|
-
}, EVENT_TYPE.UI>;
|
|
29
10
|
export declare const analyticsEventKey = "EDITOR_ANALYTICS_EVENT";
|
|
@@ -5,7 +5,14 @@ export { shouldAutoLinkifyMatch } from './should-auto-linkify-tld';
|
|
|
5
5
|
export { getAnnotationMarksForPos, canApplyAnnotationOnRange, containsAnyAnnotations, getAnnotationIdsFromRange, getAnnotationInlineNodeTypes, hasAnnotationMark, getRangeInlineNodeNames, } from './annotation';
|
|
6
6
|
export { getExtensionLozengeData } from './macro';
|
|
7
7
|
export type { Params } from './macro';
|
|
8
|
-
export {
|
|
8
|
+
export {
|
|
9
|
+
/**
|
|
10
|
+
* @private
|
|
11
|
+
* @deprecated
|
|
12
|
+
*
|
|
13
|
+
* Please use `@atlaskit/editor-common/browser` entry-point instead.
|
|
14
|
+
*/
|
|
15
|
+
browser, } from './browser';
|
|
9
16
|
export { default as ErrorReporter } from './error-reporter';
|
|
10
17
|
export type { ErrorReportingHandler } from './error-reporter';
|
|
11
18
|
export { isPastDate, timestampToIsoFormat, timestampToString, timestampToTaskContext, timestampToUTCDate, todayTimestampInUTC, } from './date';
|
|
@@ -14,7 +21,31 @@ export { isElementInTableCell, isTextSelection, isLastItemMediaGroup, setNodeSel
|
|
|
14
21
|
export { withImageLoader } from './imageLoader';
|
|
15
22
|
export type { ImageLoaderProps, ImageLoaderState, ImageStatus } from './imageLoader';
|
|
16
23
|
export { absoluteBreakoutWidth, calcBreakoutWidth, calcWideWidth, breakoutConsts, calculateBreakoutStyles, calcBreakoutWidthPx, getNextBreakoutMode, getTitle, } from './breakout';
|
|
17
|
-
export {
|
|
24
|
+
export {
|
|
25
|
+
/**
|
|
26
|
+
* @private
|
|
27
|
+
* @deprecated
|
|
28
|
+
*
|
|
29
|
+
* This is only used in editor-core and shouldn't be used anywhere else.
|
|
30
|
+
* If you do need it please reach out to #cc-editor-lego
|
|
31
|
+
*/
|
|
32
|
+
findChangedNodesFromTransaction,
|
|
33
|
+
/**
|
|
34
|
+
* @private
|
|
35
|
+
* @deprecated
|
|
36
|
+
*
|
|
37
|
+
* This is only used in editor-core and shouldn't be used anywhere else.
|
|
38
|
+
* If you do need it please reach out to #cc-editor-lego
|
|
39
|
+
*/
|
|
40
|
+
validNode,
|
|
41
|
+
/**
|
|
42
|
+
* @private
|
|
43
|
+
* @deprecated
|
|
44
|
+
*
|
|
45
|
+
* This is only used in editor-core and shouldn't be used anywhere else.
|
|
46
|
+
* If you do need it please reach out to #cc-editor-lego
|
|
47
|
+
*/
|
|
48
|
+
validateNodes, isType, isParagraph, isText, isLinkMark, SelectedState, isNodeSelectedOrInRange, isSupportedInParent, isMediaNode, isNodeBeforeMediaNode, } from './nodes';
|
|
18
49
|
export type { Reducer } from './plugin-state-factory';
|
|
19
50
|
export { pluginFactory } from './plugin-state-factory';
|
|
20
51
|
export { getFragmentBackingArray, mapFragment, mapSlice, flatmap, mapChildren } from './slice';
|
|
@@ -22,8 +53,15 @@ export type { FlatMapCallback, MapWithCallback } from './slice';
|
|
|
22
53
|
export { walkUpTreeUntil, unwrap, removeNestedEmptyEls, containsClassName, closest, closestElement, parsePx, mapElem, maphElem, } from './dom';
|
|
23
54
|
export type { MapCallback } from './dom';
|
|
24
55
|
export { default as ADFTraversor } from './traversor';
|
|
25
|
-
|
|
26
|
-
|
|
56
|
+
/**
|
|
57
|
+
* @private
|
|
58
|
+
* @deprecated
|
|
59
|
+
*
|
|
60
|
+
* Use entry-point `@atlaskit/editor-common/utils/analytics` instead
|
|
61
|
+
*/
|
|
62
|
+
export { analyticsEventKey, getAnalyticsAppearance, getAnalyticsEditorAppearance, getAnalyticsEventSeverity, SEVERITY, } from './analytics';
|
|
63
|
+
export { getUnsupportedContentLevelData, UNSUPPORTED_CONTENT_LEVEL_SEVERITY, UNSUPPORTED_CONTENT_LEVEL_SEVERITY_THRESHOLD_DEFAULTS, type UnsupportedContentLevelsTracking, } from './unsupportedContent/get-unsupported-content-level-data';
|
|
64
|
+
export type { UnsupportedContentTooltipPayload, UnsupportedContentPayload, } from './unsupportedContent/types';
|
|
27
65
|
export { findAndTrackUnsupportedContentNodes } from './track-unsupported-content';
|
|
28
66
|
export { getDistortedDurationMonitor, measureRender } from './performance/measure-render';
|
|
29
67
|
export { startMeasure, stopMeasure, clearMeasure } from './performance/measure';
|
|
@@ -51,6 +89,12 @@ export { getShallowPropsDifference, getPropsDifference } from './compare-props';
|
|
|
51
89
|
export type { ShallowPropsDifference, PropsDifference } from './compare-props';
|
|
52
90
|
export { useComponentRenderTracking } from './performance/hooks/use-component-render-tracking';
|
|
53
91
|
export type { UseComponentRenderTrackingArgs } from './performance/hooks/use-component-render-tracking';
|
|
92
|
+
/**
|
|
93
|
+
* @private
|
|
94
|
+
* @deprecated
|
|
95
|
+
*
|
|
96
|
+
* Private API do not use
|
|
97
|
+
*/
|
|
54
98
|
export { isOutdatedBrowser } from './outdated-browsers';
|
|
55
99
|
export { autoJoinTr } from './prosemirror/autojoin';
|
|
56
100
|
export { isReferencedSource, removeConnectedNodes, getChildrenInfo, getNodeName, } from './referentiality';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import type { Node as PMNode, Schema } from '@atlaskit/editor-prosemirror/model';
|
|
2
2
|
import { ACTION_SUBJECT_ID } from '../analytics';
|
|
3
|
-
import type { UnsupportedContentPayload, UnsupportedContentTooltipPayload } from './
|
|
3
|
+
import type { UnsupportedContentPayload, UnsupportedContentTooltipPayload } from './unsupportedContent/types';
|
|
4
4
|
type DispatchAnalyticsEvent = (payload: UnsupportedContentPayload) => void;
|
|
5
5
|
type DispatchAnalyticsEventTooltip = (payload: UnsupportedContentTooltipPayload) => void;
|
|
6
6
|
export declare const findAndTrackUnsupportedContentNodes: (node: PMNode, schema: Schema, dispatchAnalyticsEvent: DispatchAnalyticsEvent, ancestorHierarchy?: string) => void;
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { type ACTION, type ACTION_SUBJECT, type ACTION_SUBJECT_ID, type EVENT_TYPE } from '../../analytics';
|
|
2
|
+
type AEP<Action, ActionSubject, ActionSubjectID, Attributes, EventType> = {
|
|
3
|
+
action: Action;
|
|
4
|
+
actionSubject: ActionSubject;
|
|
5
|
+
actionSubjectId?: ActionSubjectID;
|
|
6
|
+
attributes?: Attributes;
|
|
7
|
+
eventType: EventType;
|
|
8
|
+
};
|
|
9
|
+
type TrackAEP<Action, ActionSubject, ActionSubjectID, Attributes> = AEP<Action, ActionSubject, ActionSubjectID, Attributes, EVENT_TYPE.TRACK>;
|
|
10
|
+
type UnsupportedContentEncounteredAEP = TrackAEP<ACTION.UNSUPPORTED_CONTENT_ENCOUNTERED, ACTION_SUBJECT.DOCUMENT, ACTION_SUBJECT_ID, {
|
|
11
|
+
unsupportedNode: Record<string, any>;
|
|
12
|
+
errorCode?: String;
|
|
13
|
+
}>;
|
|
14
|
+
export type UnsupportedContentPayload = UnsupportedContentEncounteredAEP;
|
|
15
|
+
export type UnsupportedContentTooltipPayload = AEP<ACTION.UNSUPPORTED_TOOLTIP_VIEWED, ACTION_SUBJECT.TOOLTIP, ACTION_SUBJECT_ID.ON_UNSUPPORTED_BLOCK | ACTION_SUBJECT_ID.ON_UNSUPPORTED_INLINE, {
|
|
16
|
+
unsupportedNodeType: string | undefined;
|
|
17
|
+
}, EVENT_TYPE.UI>;
|
|
18
|
+
export {};
|