2017-12-01 14:45:45 +00:00
|
|
|
import {GlobalStore} from './lib/gstore-es6'
|
|
|
|
|
|
|
|
window.gstore = new GlobalStore();
|
2017-12-03 15:02:18 +00:00
|
|
|
|
|
|
|
// Header
|
2017-12-01 14:45:45 +00:00
|
|
|
window.gstore.add('header_title', 'ndli1718');
|
2017-12-03 15:02:18 +00:00
|
|
|
window.gstore.add('info', {
|
2017-12-01 14:45:45 +00:00
|
|
|
active: false,
|
|
|
|
type: 'warning',
|
|
|
|
message: 'Warning! blabla'
|
|
|
|
});
|
2017-12-03 15:02:18 +00:00
|
|
|
window.gstore.add('notif', [
|
2017-12-04 16:30:33 +00:00
|
|
|
{ class: 'bell', data: [] },
|
|
|
|
{ class: 'message', data: [] },
|
2017-12-04 09:26:10 +00:00
|
|
|
{ class: 'search', data: [] },
|
|
|
|
{ class: 'menu', data: [] }
|
2017-12-03 15:02:18 +00:00
|
|
|
])
|
|
|
|
|
|
|
|
// Menu
|
2017-12-01 14:45:45 +00:00
|
|
|
window.gstore.add('menu_item', {
|
|
|
|
dashboard: {
|
|
|
|
label: 'Dashboard',
|
|
|
|
icon: 'dashboard'
|
|
|
|
}, profile: {
|
|
|
|
label: 'Profil',
|
|
|
|
icon: 'profile'
|
|
|
|
}, inbox: {
|
|
|
|
label: 'Boîte de réception',
|
|
|
|
icon: 'messages'
|
|
|
|
}
|
2017-12-03 15:02:18 +00:00
|
|
|
});
|
2017-12-04 10:48:32 +00:00
|
|
|
window.gstore.add('menu_item_active', 'dashboard');
|
|
|
|
window.gstore.add('min_menu', true);
|
|
|
|
|
|
|
|
|
|
|
|
// Functions
|
|
|
|
window.gstore.add('func', {
|
|
|
|
toggleMenuSize: function(){ window.gstore.data.min_menu=!window.gstore.data.min_menu; }
|
|
|
|
});
|