diff --git a/demo-shell-ng2/app/app.component.html b/demo-shell-ng2/app/app.component.html index 26a5d89061..98abb43bfc 100644 --- a/demo-shell-ng2/app/app.component.html +++ b/demo-shell-ng2/app/app.component.html @@ -1,3 +1,4 @@ + +--> + + +
+
+
+ + Alfresco + +
+ + + + + +
    +
  • Some Action
  • +
  • Another Action
  • +
  • Disabled Action
  • +
  • Yet Another Action
  • +
  • Login
  • +
  • Logout
  • +
+
+
+
+ Alfresco + +
+
+
+ + +
+
+
diff --git a/demo-shell-ng2/app/app.component.ts b/demo-shell-ng2/app/app.component.ts index 6098fe70ed..404a273013 100644 --- a/demo-shell-ng2/app/app.component.ts +++ b/demo-shell-ng2/app/app.component.ts @@ -7,11 +7,14 @@ import {HomeView} from './components/home.view'; import {Page1View} from './components/page1.view'; import {Page2View} from './components/page2.view'; import {AlfrescoService} from 'ng2-alfresco-documentlist/ng2-alfresco-documentlist'; +import {MDL} from './components/MaterialDesignLiteUpgradeElement'; + +declare var document: any; @Component({ selector: 'my-app', templateUrl: 'app/app.component.html', - directives: [ROUTER_DIRECTIVES, AuthRouterOutlet] + directives: [ROUTER_DIRECTIVES, AuthRouterOutlet, MDL] }) @RouteConfig([ {path: '/', name: 'Home', component: HomeView, useAsDefault: true}, @@ -42,4 +45,9 @@ export class AppComponent { () => this.router.navigate(['Login']) ); } + + hideDrawer() { + // todo: workaround for drawer closing + document.querySelector('.mdl-layout').MaterialLayout.toggleDrawer(); + } } diff --git a/demo-shell-ng2/app/components/home.view.ts b/demo-shell-ng2/app/components/home.view.ts index 88abd1c8b5..d3c59b02f0 100644 --- a/demo-shell-ng2/app/components/home.view.ts +++ b/demo-shell-ng2/app/components/home.view.ts @@ -1,5 +1,6 @@ import {Component} from 'angular2/core'; import {DocumentList} from 'ng2-alfresco-documentlist/ng2-alfresco-documentlist'; +import {MDL} from './MaterialDesignLiteUpgradeElement'; @Component({ selector: 'home-view', @@ -8,10 +9,30 @@ import {DocumentList} from 'ng2-alfresco-documentlist/ng2-alfresco-documentlist'

`, - directives: [DocumentList] + directives: [DocumentList, MDL] }) export class HomeView { thumbnails: boolean = true; diff --git a/demo-shell-ng2/app/css/app.css b/demo-shell-ng2/app/css/app.css index f52219b4a0..242dd5936f 100644 --- a/demo-shell-ng2/app/css/app.css +++ b/demo-shell-ng2/app/css/app.css @@ -1,5 +1,3 @@ -body { padding-top: 70px; } - /* Utils */ .p-10 {