@atlaskit/editor-plugin-card 0.10.7 → 0.10.8
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-plugin-card
|
|
2
2
|
|
|
3
|
+
## 0.10.8
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#42586](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/42586) [`ed2a549e705`](https://bitbucket.org/atlassian/atlassian-frontend/commits/ed2a549e705) - ED-20177 Use updated transaction when closing modal
|
|
8
|
+
|
|
3
9
|
## 0.10.7
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
|
@@ -37,8 +37,8 @@ var DatasourceModal = exports.DatasourceModal = function DatasourceModal(_ref) {
|
|
|
37
37
|
parameters = _useFetchDatasourceIn.parameters,
|
|
38
38
|
ready = _useFetchDatasourceIn.ready;
|
|
39
39
|
var onClose = (0, _react.useCallback)(function () {
|
|
40
|
-
dispatch((0, _actions.hideDatasourceModal)(state.tr));
|
|
41
|
-
}, [dispatch, state.tr]);
|
|
40
|
+
dispatch((0, _actions.hideDatasourceModal)(view.state.tr));
|
|
41
|
+
}, [dispatch, view.state.tr]);
|
|
42
42
|
var onInsert = (0, _react.useCallback)(function (newAdf, analyticEvent) {
|
|
43
43
|
if (analyticEvent) {
|
|
44
44
|
analyticEvent.update(function (payload) {
|
|
@@ -50,11 +50,11 @@ var DatasourceModal = exports.DatasourceModal = function DatasourceModal(_ref) {
|
|
|
50
50
|
});
|
|
51
51
|
}
|
|
52
52
|
if (existingNode) {
|
|
53
|
-
(0, _doc.updateCardFromDatasourceModal)(state, existingNode, newAdf, view, analyticEvent);
|
|
53
|
+
(0, _doc.updateCardFromDatasourceModal)(view.state, existingNode, newAdf, view, analyticEvent);
|
|
54
54
|
} else {
|
|
55
|
-
(0, _doc.insertDatasource)(state, newAdf, view, analyticEvent);
|
|
55
|
+
(0, _doc.insertDatasource)(view.state, newAdf, view, analyticEvent);
|
|
56
56
|
}
|
|
57
|
-
}, [existingNode,
|
|
57
|
+
}, [existingNode, view]);
|
|
58
58
|
if (modalType === 'jira') {
|
|
59
59
|
var _existingNode$attrs3, _tableView$properties;
|
|
60
60
|
if (!ready) {
|
|
@@ -29,8 +29,8 @@ export const DatasourceModal = ({
|
|
|
29
29
|
nodeParameters: existingNode === null || existingNode === void 0 ? void 0 : (_existingNode$attrs2 = existingNode.attrs) === null || _existingNode$attrs2 === void 0 ? void 0 : (_existingNode$attrs2$ = _existingNode$attrs2.datasource) === null || _existingNode$attrs2$ === void 0 ? void 0 : _existingNode$attrs2$.parameters
|
|
30
30
|
});
|
|
31
31
|
const onClose = useCallback(() => {
|
|
32
|
-
dispatch(hideDatasourceModal(state.tr));
|
|
33
|
-
}, [dispatch, state.tr]);
|
|
32
|
+
dispatch(hideDatasourceModal(view.state.tr));
|
|
33
|
+
}, [dispatch, view.state.tr]);
|
|
34
34
|
const onInsert = useCallback((newAdf, analyticEvent) => {
|
|
35
35
|
if (analyticEvent) {
|
|
36
36
|
analyticEvent.update(payload => ({
|
|
@@ -42,11 +42,11 @@ export const DatasourceModal = ({
|
|
|
42
42
|
}));
|
|
43
43
|
}
|
|
44
44
|
if (existingNode) {
|
|
45
|
-
updateCardFromDatasourceModal(state, existingNode, newAdf, view, analyticEvent);
|
|
45
|
+
updateCardFromDatasourceModal(view.state, existingNode, newAdf, view, analyticEvent);
|
|
46
46
|
} else {
|
|
47
|
-
insertDatasource(state, newAdf, view, analyticEvent);
|
|
47
|
+
insertDatasource(view.state, newAdf, view, analyticEvent);
|
|
48
48
|
}
|
|
49
|
-
}, [existingNode,
|
|
49
|
+
}, [existingNode, view]);
|
|
50
50
|
if (modalType === 'jira') {
|
|
51
51
|
var _existingNode$attrs3, _tableView$properties;
|
|
52
52
|
if (!ready) {
|
|
@@ -27,8 +27,8 @@ export var DatasourceModal = function DatasourceModal(_ref) {
|
|
|
27
27
|
parameters = _useFetchDatasourceIn.parameters,
|
|
28
28
|
ready = _useFetchDatasourceIn.ready;
|
|
29
29
|
var onClose = useCallback(function () {
|
|
30
|
-
dispatch(hideDatasourceModal(state.tr));
|
|
31
|
-
}, [dispatch, state.tr]);
|
|
30
|
+
dispatch(hideDatasourceModal(view.state.tr));
|
|
31
|
+
}, [dispatch, view.state.tr]);
|
|
32
32
|
var onInsert = useCallback(function (newAdf, analyticEvent) {
|
|
33
33
|
if (analyticEvent) {
|
|
34
34
|
analyticEvent.update(function (payload) {
|
|
@@ -40,11 +40,11 @@ export var DatasourceModal = function DatasourceModal(_ref) {
|
|
|
40
40
|
});
|
|
41
41
|
}
|
|
42
42
|
if (existingNode) {
|
|
43
|
-
updateCardFromDatasourceModal(state, existingNode, newAdf, view, analyticEvent);
|
|
43
|
+
updateCardFromDatasourceModal(view.state, existingNode, newAdf, view, analyticEvent);
|
|
44
44
|
} else {
|
|
45
|
-
insertDatasource(state, newAdf, view, analyticEvent);
|
|
45
|
+
insertDatasource(view.state, newAdf, view, analyticEvent);
|
|
46
46
|
}
|
|
47
|
-
}, [existingNode,
|
|
47
|
+
}, [existingNode, view]);
|
|
48
48
|
if (modalType === 'jira') {
|
|
49
49
|
var _existingNode$attrs3, _tableView$properties;
|
|
50
50
|
if (!ready) {
|