Skip to content

Commit

Permalink
Activate first menu item if first cat is headless
Browse files Browse the repository at this point in the history
  • Loading branch information
RomanHotsiy committed Dec 2, 2016
1 parent 8731adf commit 82f4598
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions lib/services/menu.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,9 @@ export class MenuService {

setActiveByHash(hash) {
if (!hash) {
if (this.categories[0].headless) {
this.activate(0, 0);
}
return;
}
let catIdx, methodIdx;
Expand Down
1 change: 1 addition & 0 deletions lib/services/schema-helper.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ export interface MenuCategory {
empty?: string;
virtual?: boolean;
ready: boolean;
headless: boolean;
}

// global var for this module
Expand Down

0 comments on commit 82f4598

Please sign in to comment.