-
Notifications
You must be signed in to change notification settings - Fork 915
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: adjust theming mechanism, add bootstrap for grid, static module…
… for static content
- Loading branch information
1 parent
43a177f
commit b1753ad
Showing
30 changed files
with
253 additions
and
82 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,14 @@ | ||
# Angular, ngrx & Material Starter by [@tomastrajan](https://twitter.com/tomastrajan) [![Build Status](https://travis-ci.org/tomastrajan/angular-ngrx-material-starter.svg?branch=master)](https://travis-ci.org/tomastrajan/angular-ngrx-material-starter) | ||
# Angular, ngrx and Angular Material Starter by [@tomastrajan](https://twitter.com/tomastrajan) [![Build Status](https://travis-ci.org/tomastrajan/angular-ngrx-material-starter.svg?branch=master)](https://travis-ci.org/tomastrajan/angular-ngrx-material-starter) | ||
Check out [Demo & Documentation](http://tomastrajan.github.io/angular-ngrx-material-starter/) | ||
Check out [Demo & Documentation](http://tomastrajan.github.io/angular-ngrx-material-starter/) | ||
|
||
## Features | ||
|
||
* Angular | ||
* ngrx | ||
* Angular Material | ||
* Bootstrap 4 (only reset and grids) | ||
|
||
## Build | ||
|
||
Built with [Angular CLI](https://github.com/angular/angular-cli) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,33 @@ | ||
<div [class]="themeClass"> | ||
<md-toolbar color="primary" class="toolbar"> | ||
<span>Angular NGrx Material Starter</span> | ||
<span class="spacer"></span> | ||
<button md-button>About</button> | ||
<button md-button>Features</button> | ||
<button md-button>Examples</button> | ||
<button md-icon-button [mdMenuTriggerFor]="toolbarMenu"> | ||
<md-icon>more_vert</md-icon> | ||
</button> | ||
<md-menu #toolbarMenu="mdMenu"> | ||
<button md-menu-item> | ||
<md-icon>person</md-icon> | ||
<span>Manage account</span> | ||
<md-toolbar color="primary" class="toolbar"> | ||
<span>Angular NGrx Material Starter</span> | ||
<span class="spacer"></span> | ||
<button md-button routerLink="about" routerLinkActive="active">About</button> | ||
<button md-button routerLink="features" routerLinkActive="active">Features</button> | ||
<button md-button>Examples</button> | ||
<button md-icon-button [mdMenuTriggerFor]="toolbarMenu"> | ||
<md-icon>more_vert</md-icon> | ||
</button> | ||
<button md-menu-item routerLink="settings"> | ||
<md-icon>settings</md-icon> | ||
<span>Settings</span> | ||
</button> | ||
<button md-menu-item> | ||
<md-icon>power_settings_new</md-icon> | ||
<span>Logout</span> | ||
</button> | ||
</md-menu> | ||
</md-toolbar> | ||
<h1> | ||
{{title}} | ||
</h1> | ||
|
||
<router-outlet></router-outlet> | ||
<md-menu #toolbarMenu="mdMenu"> | ||
<button md-menu-item disabled> | ||
<md-icon>person</md-icon> | ||
<span>Manage account</span> | ||
</button> | ||
<button md-menu-item routerLink="settings"> | ||
<md-icon>settings</md-icon> | ||
<span>Settings</span> | ||
</button> | ||
<button md-menu-item disabled> | ||
<md-icon>power_settings_new</md-icon> | ||
<span>Logout</span> | ||
</button> | ||
</md-menu> | ||
</md-toolbar> | ||
<div class="container-fluid"> | ||
<div class="row"> | ||
<div class="col-sm-12"> | ||
<router-outlet></router-outlet> | ||
</div> | ||
</div> | ||
</div> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
|
||
|
||
.toolbar{ | ||
|
||
button { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
@import '~@angular/material/theming'; | ||
@import 'default-theme.scss'; | ||
@import 'alternative-theme.scss'; | ||
|
||
@mixin app-component-theme($theme) { | ||
$accent: map-get($theme, accent); | ||
|
||
.toolbar{ | ||
button { | ||
&.active { | ||
background-color: mat-color($accent); | ||
} | ||
} | ||
} | ||
} | ||
|
||
.default-theme { | ||
@include app-component-theme($anms-theme); | ||
} | ||
|
||
.alternative-theme { | ||
@include app-component-theme($anms-alternative-theme); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,12 @@ | ||
<md-select placeholder="Select theme" [ngModel]="theme" (change)="onThemeSelect($event)" name="theme"> | ||
<md-option *ngFor="let t of themes" [value]="t.value"> | ||
{{t.label}} | ||
</md-option> | ||
</md-select> | ||
<div class="row"> | ||
<div class="col-sm-12"><h1>Settings</h1></div> | ||
</div> | ||
<br> | ||
<div class="row"> | ||
<md-select class="col-md-4" placeholder="Select theme" name="theme" | ||
[ngModel]="theme" (change)="onThemeSelect($event)"> | ||
<md-option *ngFor="let t of themes" [value]="t.value"> | ||
{{t.label}} | ||
</md-option> | ||
</md-select> | ||
</div> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<p> | ||
about works! | ||
</p> |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; | ||
|
||
import { AboutComponent } from './about.component'; | ||
|
||
describe('AboutComponent', () => { | ||
let component: AboutComponent; | ||
let fixture: ComponentFixture<AboutComponent>; | ||
|
||
beforeEach(async(() => { | ||
TestBed.configureTestingModule({ | ||
declarations: [ AboutComponent ] | ||
}) | ||
.compileComponents(); | ||
})); | ||
|
||
beforeEach(() => { | ||
fixture = TestBed.createComponent(AboutComponent); | ||
component = fixture.componentInstance; | ||
fixture.detectChanges(); | ||
}); | ||
|
||
it('should be created', () => { | ||
expect(component).toBeTruthy(); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import { Component, OnInit } from '@angular/core'; | ||
|
||
@Component({ | ||
selector: 'anms-about', | ||
templateUrl: './about.component.html', | ||
styleUrls: ['./about.component.scss'] | ||
}) | ||
export class AboutComponent implements OnInit { | ||
|
||
constructor() { } | ||
|
||
ngOnInit() { | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
<p> | ||
features works! | ||
</p> |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
import { async, ComponentFixture, TestBed } from '@angular/core/testing'; | ||
|
||
import { FeaturesComponent } from './features.component'; | ||
|
||
describe('FeaturesComponent', () => { | ||
let component: FeaturesComponent; | ||
let fixture: ComponentFixture<FeaturesComponent>; | ||
|
||
beforeEach(async(() => { | ||
TestBed.configureTestingModule({ | ||
declarations: [ FeaturesComponent ] | ||
}) | ||
.compileComponents(); | ||
})); | ||
|
||
beforeEach(() => { | ||
fixture = TestBed.createComponent(FeaturesComponent); | ||
component = fixture.componentInstance; | ||
fixture.detectChanges(); | ||
}); | ||
|
||
it('should be created', () => { | ||
expect(component).toBeTruthy(); | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import { Component, OnInit } from '@angular/core'; | ||
|
||
@Component({ | ||
selector: 'anms-features', | ||
templateUrl: './features.component.html', | ||
styleUrls: ['./features.component.scss'] | ||
}) | ||
export class FeaturesComponent implements OnInit { | ||
|
||
constructor() { } | ||
|
||
ngOnInit() { | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
export * from './static-routing.module'; | ||
export * from './static.module'; | ||
export * from './about/about.component'; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { NgModule } from '@angular/core'; | ||
import { Routes, RouterModule } from '@angular/router'; | ||
|
||
import { AboutComponent } from './about/about.component'; | ||
import { FeaturesComponent } from './features/features.component'; | ||
|
||
const routes: Routes = [ | ||
{ path: 'about', component: AboutComponent }, | ||
{ path: 'features', component: FeaturesComponent } | ||
]; | ||
|
||
@NgModule({ | ||
imports: [RouterModule.forChild(routes)], | ||
exports: [RouterModule] | ||
}) | ||
export class StaticRoutingModule { } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { NgModule } from '@angular/core'; | ||
import { CommonModule } from '@angular/common'; | ||
|
||
import { SharedModule } from '../shared'; | ||
|
||
import { StaticRoutingModule } from './static-routing.module'; | ||
import { AboutComponent } from './about/about.component'; | ||
import { FeaturesComponent } from './features/features.component'; | ||
|
||
@NgModule({ | ||
imports: [ | ||
CommonModule, | ||
SharedModule, | ||
StaticRoutingModule | ||
], | ||
declarations: [ | ||
AboutComponent, | ||
FeaturesComponent | ||
] | ||
}) | ||
export class StaticModule { } |
Oops, something went wrong.