@lvce-editor/source-control-worker 1.12.0 → 1.14.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/README.md +1 -1
- package/dist/sourceControlWorkerMain.js +13 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -696,14 +696,14 @@ const unwrapJsonRpcResult = responseMessage => {
|
|
|
696
696
|
}
|
|
697
697
|
throw new JsonRpcError('unexpected response message');
|
|
698
698
|
};
|
|
699
|
-
const warn = (...args) => {
|
|
699
|
+
const warn$1 = (...args) => {
|
|
700
700
|
console.warn(...args);
|
|
701
701
|
};
|
|
702
702
|
const resolve = (id, response) => {
|
|
703
703
|
const fn = get$3(id);
|
|
704
704
|
if (!fn) {
|
|
705
705
|
console.log(response);
|
|
706
|
-
warn(`callback ${id} may already be disposed`);
|
|
706
|
+
warn$1(`callback ${id} may already be disposed`);
|
|
707
707
|
return;
|
|
708
708
|
}
|
|
709
709
|
fn(response);
|
|
@@ -1541,6 +1541,10 @@ const getIndex = (state, eventX, eventY) => {
|
|
|
1541
1541
|
return index;
|
|
1542
1542
|
};
|
|
1543
1543
|
|
|
1544
|
+
const warn = (...args) => {
|
|
1545
|
+
console.warn(...args);
|
|
1546
|
+
};
|
|
1547
|
+
|
|
1544
1548
|
const refresh = async state => {
|
|
1545
1549
|
const {
|
|
1546
1550
|
itemHeight,
|
|
@@ -1549,13 +1553,13 @@ const refresh = async state => {
|
|
|
1549
1553
|
fileIconCache,
|
|
1550
1554
|
enabledProviderIds,
|
|
1551
1555
|
splitButtonEnabled,
|
|
1552
|
-
actionsCache
|
|
1553
|
-
expandedGroups
|
|
1556
|
+
actionsCache
|
|
1554
1557
|
} = state;
|
|
1555
1558
|
const {
|
|
1556
1559
|
allGroups,
|
|
1557
1560
|
gitRoot
|
|
1558
1561
|
} = await getGroups(enabledProviderIds);
|
|
1562
|
+
const expandedGroups = restoreExpandedGroups(allGroups);
|
|
1559
1563
|
const displayItems = getDisplayItems(allGroups, expandedGroups);
|
|
1560
1564
|
const total = displayItems.length;
|
|
1561
1565
|
const contentHeight = total * itemHeight;
|
|
@@ -1589,8 +1593,12 @@ const handleClickSourceControlButtons = async (state, index, name) => {
|
|
|
1589
1593
|
if (!item) {
|
|
1590
1594
|
return state;
|
|
1591
1595
|
}
|
|
1592
|
-
const
|
|
1596
|
+
const {
|
|
1597
|
+
buttons
|
|
1598
|
+
} = item;
|
|
1599
|
+
const button = buttons.find(button => button.label === name);
|
|
1593
1600
|
if (!button) {
|
|
1601
|
+
warn(`[source-control-worker] Button not found ${name}`);
|
|
1594
1602
|
return state;
|
|
1595
1603
|
}
|
|
1596
1604
|
const file = item.file;
|