@atlaskit/editor-plugin-table 7.3.1 → 7.3.3
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/types.js +4 -0
- package/dist/cjs/ui/DragHandle/index.js +2 -0
- package/dist/es2019/types.js +4 -0
- package/dist/es2019/ui/DragHandle/index.js +2 -0
- package/dist/esm/types.js +4 -0
- package/dist/esm/ui/DragHandle/index.js +2 -0
- package/dist/types/types.d.ts +6 -0
- package/dist/types-ts4.5/types.d.ts +6 -0
- package/package.json +1 -1
- package/src/types.ts +6 -0
- package/src/ui/DragHandle/index.tsx +2 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atlaskit/editor-plugin-table
|
|
2
2
|
|
|
3
|
+
## 7.3.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#70829](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/70829) [`18955263bc9a`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/18955263bc9a) - ED-17638: Marked permittedLayouts as deprecated
|
|
8
|
+
|
|
9
|
+
## 7.3.2
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#72081](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/72081) [`4487160917d2`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/4487160917d2) - [ux] ED-22052: adds button type attribute to non atlaskit button instances
|
|
14
|
+
|
|
3
15
|
## 7.3.1
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/dist/cjs/types.js
CHANGED
|
@@ -12,6 +12,10 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
12
12
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
13
13
|
var RESIZE_HANDLE_AREA_DECORATION_GAP = exports.RESIZE_HANDLE_AREA_DECORATION_GAP = 30;
|
|
14
14
|
|
|
15
|
+
/**
|
|
16
|
+
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6877 Internal documentation for deprecation (no external access)}
|
|
17
|
+
**/
|
|
18
|
+
|
|
15
19
|
/*
|
|
16
20
|
* This type represents the start and end from a cell in a column,
|
|
17
21
|
* for example, on this table the cell C1 will have
|
|
@@ -124,6 +124,7 @@ var DragHandleComponent = function DragHandleComponent(_ref) {
|
|
|
124
124
|
}, [tableLocalId, direction, indexes, isRow, editorView.state.selection, hasMergedCells]);
|
|
125
125
|
var showDragMenuAnchorId = isRow ? 'drag-handle-button-row' : 'drag-handle-button-column';
|
|
126
126
|
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, /*#__PURE__*/_react.default.createElement("button", {
|
|
127
|
+
type: "button",
|
|
127
128
|
className: _types.TableCssClassName.DRAG_HANDLE_BUTTON_CLICKABLE_ZONE,
|
|
128
129
|
"data-testid": "table-drag-handle-clickable-zone-button",
|
|
129
130
|
style: {
|
|
@@ -138,6 +139,7 @@ var DragHandleComponent = function DragHandleComponent(_ref) {
|
|
|
138
139
|
},
|
|
139
140
|
onClick: onClick
|
|
140
141
|
}), /*#__PURE__*/_react.default.createElement("button", {
|
|
142
|
+
type: "button",
|
|
141
143
|
id: isDragMenuTarget ? showDragMenuAnchorId : undefined,
|
|
142
144
|
className: (0, _classnames2.default)(_types.TableCssClassName.DRAG_HANDLE_BUTTON_CONTAINER, appearance, (0, _defineProperty2.default)({}, _types.TableCssClassName.DRAG_HANDLE_DISABLED, hasMergedCells)),
|
|
143
145
|
ref: dragHandleDivRef,
|
package/dist/es2019/types.js
CHANGED
|
@@ -2,6 +2,10 @@ import { tableCellSelector, tableHeaderSelector, tablePrefixSelector } from '@at
|
|
|
2
2
|
import { TableSharedCssClassName } from '@atlaskit/editor-common/styles';
|
|
3
3
|
export const RESIZE_HANDLE_AREA_DECORATION_GAP = 30;
|
|
4
4
|
|
|
5
|
+
/**
|
|
6
|
+
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6877 Internal documentation for deprecation (no external access)}
|
|
7
|
+
**/
|
|
8
|
+
|
|
5
9
|
/*
|
|
6
10
|
* This type represents the start and end from a cell in a column,
|
|
7
11
|
* for example, on this table the cell C1 will have
|
|
@@ -114,6 +114,7 @@ const DragHandleComponent = ({
|
|
|
114
114
|
}, [tableLocalId, direction, indexes, isRow, editorView.state.selection, hasMergedCells]);
|
|
115
115
|
const showDragMenuAnchorId = isRow ? 'drag-handle-button-row' : 'drag-handle-button-column';
|
|
116
116
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("button", {
|
|
117
|
+
type: "button",
|
|
117
118
|
className: ClassName.DRAG_HANDLE_BUTTON_CLICKABLE_ZONE,
|
|
118
119
|
"data-testid": "table-drag-handle-clickable-zone-button",
|
|
119
120
|
style: {
|
|
@@ -128,6 +129,7 @@ const DragHandleComponent = ({
|
|
|
128
129
|
},
|
|
129
130
|
onClick: onClick
|
|
130
131
|
}), /*#__PURE__*/React.createElement("button", {
|
|
132
|
+
type: "button",
|
|
131
133
|
id: isDragMenuTarget ? showDragMenuAnchorId : undefined,
|
|
132
134
|
className: classnames(ClassName.DRAG_HANDLE_BUTTON_CONTAINER, appearance, {
|
|
133
135
|
[ClassName.DRAG_HANDLE_DISABLED]: hasMergedCells
|
package/dist/esm/types.js
CHANGED
|
@@ -5,6 +5,10 @@ import { tableCellSelector, tableHeaderSelector, tablePrefixSelector } from '@at
|
|
|
5
5
|
import { TableSharedCssClassName } from '@atlaskit/editor-common/styles';
|
|
6
6
|
export var RESIZE_HANDLE_AREA_DECORATION_GAP = 30;
|
|
7
7
|
|
|
8
|
+
/**
|
|
9
|
+
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6877 Internal documentation for deprecation (no external access)}
|
|
10
|
+
**/
|
|
11
|
+
|
|
8
12
|
/*
|
|
9
13
|
* This type represents the start and end from a cell in a column,
|
|
10
14
|
* for example, on this table the cell C1 will have
|
|
@@ -114,6 +114,7 @@ var DragHandleComponent = function DragHandleComponent(_ref) {
|
|
|
114
114
|
}, [tableLocalId, direction, indexes, isRow, editorView.state.selection, hasMergedCells]);
|
|
115
115
|
var showDragMenuAnchorId = isRow ? 'drag-handle-button-row' : 'drag-handle-button-column';
|
|
116
116
|
return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("button", {
|
|
117
|
+
type: "button",
|
|
117
118
|
className: ClassName.DRAG_HANDLE_BUTTON_CLICKABLE_ZONE,
|
|
118
119
|
"data-testid": "table-drag-handle-clickable-zone-button",
|
|
119
120
|
style: {
|
|
@@ -128,6 +129,7 @@ var DragHandleComponent = function DragHandleComponent(_ref) {
|
|
|
128
129
|
},
|
|
129
130
|
onClick: onClick
|
|
130
131
|
}), /*#__PURE__*/React.createElement("button", {
|
|
132
|
+
type: "button",
|
|
131
133
|
id: isDragMenuTarget ? showDragMenuAnchorId : undefined,
|
|
132
134
|
className: classnames(ClassName.DRAG_HANDLE_BUTTON_CONTAINER, appearance, _defineProperty({}, ClassName.DRAG_HANDLE_DISABLED, hasMergedCells)),
|
|
133
135
|
ref: dragHandleDivRef,
|
package/dist/types/types.d.ts
CHANGED
|
@@ -11,6 +11,9 @@ import type { Edge } from '@atlaskit/pragmatic-drag-and-drop-hitbox/addon/closes
|
|
|
11
11
|
import type tablePlugin from './plugin';
|
|
12
12
|
export declare const RESIZE_HANDLE_AREA_DECORATION_GAP = 30;
|
|
13
13
|
export type RowInsertPosition = 'TOP' | 'BOTTOM';
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6877 Internal documentation for deprecation (no external access)}
|
|
16
|
+
**/
|
|
14
17
|
export type PermittedLayoutsDescriptor = TableLayout[] | 'all';
|
|
15
18
|
export type Cell = {
|
|
16
19
|
pos: number;
|
|
@@ -36,6 +39,9 @@ export interface PluginConfig {
|
|
|
36
39
|
allowAddColumnWithCustomStep?: boolean;
|
|
37
40
|
allowCollapse?: boolean;
|
|
38
41
|
isHeaderRowRequired?: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6877 Internal documentation for deprecation (no external access)}
|
|
44
|
+
**/
|
|
39
45
|
permittedLayouts?: PermittedLayoutsDescriptor;
|
|
40
46
|
allowControls?: boolean;
|
|
41
47
|
stickyHeaders?: boolean;
|
|
@@ -11,6 +11,9 @@ import type { Edge } from '@atlaskit/pragmatic-drag-and-drop-hitbox/addon/closes
|
|
|
11
11
|
import type tablePlugin from './plugin';
|
|
12
12
|
export declare const RESIZE_HANDLE_AREA_DECORATION_GAP = 30;
|
|
13
13
|
export type RowInsertPosition = 'TOP' | 'BOTTOM';
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6877 Internal documentation for deprecation (no external access)}
|
|
16
|
+
**/
|
|
14
17
|
export type PermittedLayoutsDescriptor = TableLayout[] | 'all';
|
|
15
18
|
export type Cell = {
|
|
16
19
|
pos: number;
|
|
@@ -36,6 +39,9 @@ export interface PluginConfig {
|
|
|
36
39
|
allowAddColumnWithCustomStep?: boolean;
|
|
37
40
|
allowCollapse?: boolean;
|
|
38
41
|
isHeaderRowRequired?: boolean;
|
|
42
|
+
/**
|
|
43
|
+
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6877 Internal documentation for deprecation (no external access)}
|
|
44
|
+
**/
|
|
39
45
|
permittedLayouts?: PermittedLayoutsDescriptor;
|
|
40
46
|
allowControls?: boolean;
|
|
41
47
|
stickyHeaders?: boolean;
|
package/package.json
CHANGED
package/src/types.ts
CHANGED
|
@@ -21,6 +21,9 @@ import type tablePlugin from './plugin';
|
|
|
21
21
|
export const RESIZE_HANDLE_AREA_DECORATION_GAP = 30;
|
|
22
22
|
export type RowInsertPosition = 'TOP' | 'BOTTOM';
|
|
23
23
|
|
|
24
|
+
/**
|
|
25
|
+
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6877 Internal documentation for deprecation (no external access)}
|
|
26
|
+
**/
|
|
24
27
|
export type PermittedLayoutsDescriptor = TableLayout[] | 'all';
|
|
25
28
|
export type Cell = { pos: number; start: number; node: PmNode };
|
|
26
29
|
export type CellTransform = (cell: Cell) => (tr: Transaction) => Transaction;
|
|
@@ -51,6 +54,9 @@ export interface PluginConfig {
|
|
|
51
54
|
allowAddColumnWithCustomStep?: boolean;
|
|
52
55
|
allowCollapse?: boolean;
|
|
53
56
|
isHeaderRowRequired?: boolean;
|
|
57
|
+
/**
|
|
58
|
+
* @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-6877 Internal documentation for deprecation (no external access)}
|
|
59
|
+
**/
|
|
54
60
|
permittedLayouts?: PermittedLayoutsDescriptor;
|
|
55
61
|
allowControls?: boolean;
|
|
56
62
|
stickyHeaders?: boolean;
|
|
@@ -157,6 +157,7 @@ const DragHandleComponent = ({
|
|
|
157
157
|
return (
|
|
158
158
|
<>
|
|
159
159
|
<button
|
|
160
|
+
type="button"
|
|
160
161
|
className={ClassName.DRAG_HANDLE_BUTTON_CLICKABLE_ZONE}
|
|
161
162
|
data-testid="table-drag-handle-clickable-zone-button"
|
|
162
163
|
style={{
|
|
@@ -174,6 +175,7 @@ const DragHandleComponent = ({
|
|
|
174
175
|
onClick={onClick}
|
|
175
176
|
/>
|
|
176
177
|
<button
|
|
178
|
+
type="button"
|
|
177
179
|
id={isDragMenuTarget ? showDragMenuAnchorId : undefined}
|
|
178
180
|
className={classnames(
|
|
179
181
|
ClassName.DRAG_HANDLE_BUTTON_CONTAINER,
|