@atlaskit/editor-tables 2.5.5 → 2.5.6
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
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @atlaskit/editor-tables
|
|
2
2
|
|
|
3
|
+
## 2.5.6
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#77516](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/77516) [`d6e79c5637c7`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/d6e79c5637c7) - [ux] fix expand current selection by shift click
|
|
8
|
+
|
|
3
9
|
## 2.5.5
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
|
@@ -140,9 +140,11 @@ function handleMouseDown(view, event, dragAndDropEnabled) {
|
|
|
140
140
|
}
|
|
141
141
|
var startDOMCell = domInCell(view, startEvent.target);
|
|
142
142
|
var $anchor = (0, _cells.cellAround)(view.state.selection.$anchor);
|
|
143
|
+
var targetElement = event.target instanceof HTMLElement && event.target;
|
|
144
|
+
var isDragHandleElement = targetElement && targetElement.matches('button.pm-table-drag-handle-button-container');
|
|
143
145
|
if (startEvent.shiftKey && view.state.selection instanceof _cellSelection.CellSelection) {
|
|
144
146
|
// Adding to an existing cell selection
|
|
145
|
-
if (dragAndDropEnabled) {
|
|
147
|
+
if (dragAndDropEnabled && isDragHandleElement) {
|
|
146
148
|
return false;
|
|
147
149
|
}
|
|
148
150
|
setCellSelection(view.state.selection.$anchorCell, startEvent);
|
|
@@ -139,9 +139,11 @@ export function handleMouseDown(view, event, dragAndDropEnabled) {
|
|
|
139
139
|
}
|
|
140
140
|
const startDOMCell = domInCell(view, startEvent.target);
|
|
141
141
|
const $anchor = cellAround(view.state.selection.$anchor);
|
|
142
|
+
const targetElement = event.target instanceof HTMLElement && event.target;
|
|
143
|
+
const isDragHandleElement = targetElement && targetElement.matches('button.pm-table-drag-handle-button-container');
|
|
142
144
|
if (startEvent.shiftKey && view.state.selection instanceof CellSelection) {
|
|
143
145
|
// Adding to an existing cell selection
|
|
144
|
-
if (dragAndDropEnabled) {
|
|
146
|
+
if (dragAndDropEnabled && isDragHandleElement) {
|
|
145
147
|
return false;
|
|
146
148
|
}
|
|
147
149
|
setCellSelection(view.state.selection.$anchorCell, startEvent);
|
|
@@ -132,9 +132,11 @@ export function handleMouseDown(view, event, dragAndDropEnabled) {
|
|
|
132
132
|
}
|
|
133
133
|
var startDOMCell = domInCell(view, startEvent.target);
|
|
134
134
|
var $anchor = cellAround(view.state.selection.$anchor);
|
|
135
|
+
var targetElement = event.target instanceof HTMLElement && event.target;
|
|
136
|
+
var isDragHandleElement = targetElement && targetElement.matches('button.pm-table-drag-handle-button-container');
|
|
135
137
|
if (startEvent.shiftKey && view.state.selection instanceof CellSelection) {
|
|
136
138
|
// Adding to an existing cell selection
|
|
137
|
-
if (dragAndDropEnabled) {
|
|
139
|
+
if (dragAndDropEnabled && isDragHandleElement) {
|
|
138
140
|
return false;
|
|
139
141
|
}
|
|
140
142
|
setCellSelection(view.state.selection.$anchorCell, startEvent);
|
package/package.json
CHANGED