2015-10-18 20:05:30 +02:00
|
|
|
/// <reference path="../typings/tsd.d.ts" />
|
2015-10-17 14:12:04 +02:00
|
|
|
|
2015-10-21 22:05:49 +02:00
|
|
|
/// <reference path="menu/menu.controller.ts" />
|
|
|
|
/// <reference path="services/data.service.ts" />
|
|
|
|
/// <reference path="services/selectedWord.service.ts" />
|
2015-10-17 14:12:04 +02:00
|
|
|
|
2015-10-21 22:05:49 +02:00
|
|
|
module tagIt {
|
2015-10-17 14:12:04 +02:00
|
|
|
|
2015-10-21 22:05:49 +02:00
|
|
|
angular.module('tagit', [])
|
|
|
|
.service('DataService', DataService)
|
|
|
|
.service('SelectedWordService', SelectedWordService)
|
|
|
|
.controller('MenuCtrl', MenuCtrl);
|
|
|
|
|
|
|
|
export function init (callback: () => void) {
|
|
|
|
var $ = jQuery;
|
|
|
|
$.get('menu.tpl.html', function (htmlData) {
|
|
|
|
$('body').children().wrapAll('<div class="tagit-body" />');
|
|
|
|
$('.tagit-body').before(htmlData);
|
|
|
|
angular.bootstrap(document.getElementById("tagit-menu"), ['tagit']);
|
|
|
|
console.log('TagIt menu loaded');
|
|
|
|
if(callback) callback();
|
2015-10-19 08:47:40 +02:00
|
|
|
});
|
2015-10-21 22:05:49 +02:00
|
|
|
}
|
2015-10-17 14:12:04 +02:00
|
|
|
}
|
|
|
|
|