@xh/hoist 73.0.0-SNAPSHOT.1744140932634 → 73.0.0-SNAPSHOT.1744141996401

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.
@@ -10,7 +10,7 @@ import {ViewManagerModel, ViewInfo} from '@xh/hoist/cmp/viewmanager';
10
10
  import {switchInput} from '@xh/hoist/desktop/cmp/input';
11
11
  import {Icon} from '@xh/hoist/icon';
12
12
  import {menu, menuDivider, menuItem} from '@xh/hoist/kit/blueprint';
13
- import {pluralize} from '@xh/hoist/utils/js';
13
+ import {consumeEvent, pluralize} from '@xh/hoist/utils/js';
14
14
  import {Dictionary} from 'express-serve-static-core';
15
15
  import {each, filter, groupBy, isEmpty, orderBy, some, startCase} from 'lodash';
16
16
  import {ReactNode} from 'react';
@@ -178,14 +178,19 @@ function viewMenuItem(view: ViewInfo, model: ViewManagerModel): ReactNode {
178
178
  icon,
179
179
  href,
180
180
  onClick: e => {
181
- if (!usingRouting || e.button !== 0) {
181
+ if (!usingRouting || (e.button === 0 && !e.ctrlKey && !e.metaKey)) {
182
+ consumeEvent(e);
182
183
  model.selectViewAsync(view).catchDefault();
183
184
  return false;
184
185
  }
185
186
 
186
- e.preventDefault();
187
- XH.navigate(href);
188
- return false;
187
+ if (e.button === 0) {
188
+ consumeEvent(e);
189
+ XH.navigate(href);
190
+ return false;
191
+ }
192
+
193
+ return true;
189
194
  }
190
195
  });
191
196
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xh/hoist",
3
- "version": "73.0.0-SNAPSHOT.1744140932634",
3
+ "version": "73.0.0-SNAPSHOT.1744141996401",
4
4
  "description": "Hoist add-on for building and deploying React Applications.",
5
5
  "repository": "github:xh/hoist-react",
6
6
  "homepage": "https://xh.io",