@lvce-editor/title-bar-worker 2.1.0 → 2.2.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.
@@ -3214,12 +3214,15 @@ const selectIndexSubMenu = async (state, menu, index) => {
3214
3214
  };
3215
3215
  };
3216
3216
 
3217
- const handleMenuClick = (state, level, index) => {
3217
+ const handleMenuClick = async (state, level, index) => {
3218
3218
  const {
3219
3219
  menus
3220
3220
  } = state;
3221
3221
  const menu = menus[level];
3222
3222
  const item = menu.items[index];
3223
+ if (!item) {
3224
+ return state;
3225
+ }
3223
3226
  switch (item.flags) {
3224
3227
  case None$1:
3225
3228
  return selectIndexNone(state, item);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@lvce-editor/title-bar-worker",
3
- "version": "2.1.0",
3
+ "version": "2.2.0",
4
4
  "description": "Title Bar Worker",
5
5
  "repository": {
6
6
  "type": "git",