@lvce-editor/title-bar-worker 4.15.9 → 4.16.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.
|
@@ -5152,13 +5152,18 @@ const selectIndexNone = async (state, item) => {
|
|
|
5152
5152
|
uid
|
|
5153
5153
|
} = state;
|
|
5154
5154
|
await executeMenuItemCommand(item);
|
|
5155
|
-
const
|
|
5156
|
-
|
|
5155
|
+
const storedState = get(uid);
|
|
5156
|
+
const latestState = storedState?.newState ?? state;
|
|
5157
|
+
const newState = {
|
|
5157
5158
|
...latestState,
|
|
5158
5159
|
focusedIndex: -1,
|
|
5159
5160
|
isMenuOpen: false,
|
|
5160
5161
|
menus: []
|
|
5161
5162
|
};
|
|
5163
|
+
if (storedState) {
|
|
5164
|
+
set(uid, storedState.oldState, newState, newState);
|
|
5165
|
+
}
|
|
5166
|
+
return newState;
|
|
5162
5167
|
};
|
|
5163
5168
|
|
|
5164
5169
|
const selectIndexRestoreEditorFocus = async (state, item) => {
|