Merge branch 'feature'
This commit is contained in:
@@ -27,4 +27,15 @@ export default class App extends Vue
|
||||
// Debug output TODO: Remove this
|
||||
console.log(courses);
|
||||
}
|
||||
|
||||
/**
|
||||
* This is called when a navigation tab is clicked
|
||||
*
|
||||
* @param tab Tab name
|
||||
*/
|
||||
public onNavigate(tab: string)
|
||||
{
|
||||
// Debug output TODO: Remove this
|
||||
console.log(tab);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<div id="app">
|
||||
<login v-if="showLogin" v-on:login:courses="onLogin"></login>
|
||||
<navigation :courses="courses"></navigation>
|
||||
<navigation :courses="courses" v-on:navigation:select="onNavigate"></navigation>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
||||
@@ -24,5 +24,7 @@ export default class Navigation extends Vue
|
||||
// Update active index
|
||||
this.activeIndex = index;
|
||||
|
||||
// Call custom event
|
||||
this.$emit('navigation:select', this.activeIndex);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user