@fleetbase/ember-core 0.3.16 → 0.3.17

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.
@@ -446,7 +446,16 @@ export default class MenuService extends Service.extend(Evented) {
446
446
  */
447
447
  getHeaderMenuItems() {
448
448
  const items = this.registry.getRegistry('header', 'menu-item');
449
- return A(items).sortBy('priority');
449
+ // Sort extensions by priority first, then append shortcuts at the end.
450
+ // Shortcuts must never interleave with extensions in the sorted list
451
+ // because the default bar is built by slicing the first N items — if
452
+ // shortcuts sort between extensions (e.g. priority 1.1 between 1 and 2)
453
+ // they would displace real extensions from the default pinned bar.
454
+ const extensions = A(items)
455
+ .filter((i) => !i._isShortcut)
456
+ .sortBy('priority');
457
+ const shortcuts = A(items).filter((i) => i._isShortcut);
458
+ return A([...extensions, ...shortcuts]);
450
459
  }
451
460
 
452
461
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@fleetbase/ember-core",
3
- "version": "0.3.16",
3
+ "version": "0.3.17",
4
4
  "description": "Provides all the core services, decorators and utilities for building a Fleetbase extension for the Console.",
5
5
  "keywords": [
6
6
  "fleetbase-core",