Added luna template and deps
Change-Id: Idd3dcdee3a377a75733c333d4a754632111e17ee
diff --git a/src/index.ts b/src/index.ts
index f6da7d6..458f0a7 100644
--- a/src/index.ts
+++ b/src/index.ts
@@ -1,5 +1,6 @@
/// <reference path="../typings/index.d.ts" />
+
import * as angular from 'angular';
import 'angular-ui-router';
@@ -13,6 +14,8 @@
import {xosCore} from './app/core/index';
import {xosDataSources} from './app/datasources/index';
import {xosViews} from './app/views/index';
+import {xosTemplate} from './app/template/index';
+
import {
interceptorConfig, userStatusInterceptor, CredentialsInterceptor,
NoHyperlinksInterceptor
@@ -30,13 +33,30 @@
};
angular
- .module('app', [xosCore, xosDataSources, xosViews, 'ui.router', 'ngResource'])
+ .module('app', [
+ xosCore,
+ xosDataSources,
+ xosViews,
+ 'ui.router',
+ 'ngResource',
+ xosTemplate // template module
+ ])
.config(routesConfig)
.config(interceptorConfig)
.factory('UserStatusInterceptor', userStatusInterceptor)
.factory('CredentialsInterceptor', CredentialsInterceptor)
.factory('NoHyperlinksInterceptor', NoHyperlinksInterceptor)
.component('xos', main)
+ .run(function($rootScope: ng.IRootScopeService, $transitions: any) {
+ $transitions.onSuccess({ to: '**' }, (transtion) => {
+ if (transtion.$to().name === 'login') {
+ $rootScope['class'] = 'blank';
+ }
+ else {
+ $rootScope['class'] = '';
+ }
+ });
+ })
.run((
$location: ng.ILocationService,
$state: ng.ui.IStateService,