diff --git a/package.json b/package.json index 57cf4bc2..64725adb 100644 --- a/package.json +++ b/package.json @@ -12,6 +12,7 @@ "build:prod:aot": "npm run build:prod -- --aot", "build:ci": "npm-run-all -p -r build:prod build:prod:aot", "build:ghpages": "npm run build:prod:aot -- --base-href \"https://akveo.github.io/ng2-admin/\" && ngh", + "build:stg": "npm run build:prod:aot -- --base-href \"http://akveo.com/ngx-admin/\"", "test": "ng test -sr", "test:coverage": "rimraf coverage && npm run test -- -cc", "lint": "ng lint", diff --git a/src/app/@theme/components/header/header.component.ts b/src/app/@theme/components/header/header.component.ts index a29c0a55..36eca182 100644 --- a/src/app/@theme/components/header/header.component.ts +++ b/src/app/@theme/components/header/header.component.ts @@ -11,8 +11,9 @@ import { NgaThemeService } from '@nga/theme/services/theme.service'; + - + @@ -55,4 +56,8 @@ export class HeaderComponent { this.themeService.changeTheme('light'); } } + + selectDefaultTheme() { + this.themeService.changeTheme('default'); + } } diff --git a/src/app/@theme/styles/cosmic/cosmic.theme.scss b/src/app/@theme/styles/cosmic/cosmic.theme.scss index dca9bf15..29c5da0d 100644 --- a/src/app/@theme/styles/cosmic/cosmic.theme.scss +++ b/src/app/@theme/styles/cosmic/cosmic.theme.scss @@ -3,6 +3,7 @@ * Copyright Akveo. All Rights Reserved. * Licensed under the MIT License. See License.txt in the project root for license information. */ + @import '../components'; @import 'variables'; diff --git a/src/app/@theme/styles/default/default.theme.scss b/src/app/@theme/styles/default/default.theme.scss new file mode 100644 index 00000000..03ee2eed --- /dev/null +++ b/src/app/@theme/styles/default/default.theme.scss @@ -0,0 +1,30 @@ +/** + * @license + * Copyright Akveo. All Rights Reserved. + * Licensed under the MIT License. See License.txt in the project root for license information. + */ + +@import '../components'; +@import 'overrides/all'; + +@import '~@nga/theme/styles/themes/nga.theme.default'; + +$theme-name: 'default'; + +// @nga/theme module styles +@include nga-theme($theme-name) { + @include nga-theme-overrides($theme-name); + @include custom-components-theme($theme-name); +} + +// @nga/bootstrap module styles +@import '~@nga/theme/overrides/bootstrap/styles/themes/nga.theme.default'; +@include nga-bootstrap($theme-name); + +// @nga/maps module styles +@import '~@nga/theme/overrides/maps/styles/themes/nga.theme.default'; +@include nga-maps($theme-name); + +// @nga/typography module styles +@import '~@nga/theme/overrides/typography/styles/themes/nga.theme.default'; +@include nga-typography($theme-name); diff --git a/src/app/@theme/styles/default/overrides/all.scss b/src/app/@theme/styles/default/overrides/all.scss new file mode 100644 index 00000000..28a3e83c --- /dev/null +++ b/src/app/@theme/styles/default/overrides/all.scss @@ -0,0 +1,2 @@ +@mixin nga-theme-overrides($theme-name) { +} diff --git a/src/app/@theme/styles/light/light.theme.scss b/src/app/@theme/styles/light/light.theme.scss index b7b7cae8..f0c600a4 100644 --- a/src/app/@theme/styles/light/light.theme.scss +++ b/src/app/@theme/styles/light/light.theme.scss @@ -3,6 +3,7 @@ * Copyright Akveo. All Rights Reserved. * Licensed under the MIT License. See License.txt in the project root for license information. */ + @import '../components'; @import 'overrides/all'; diff --git a/src/app/pages/editors/ckeditor.component.ts b/src/app/pages/editors/ckeditor.component.ts deleted file mode 100644 index 8c7b926e..00000000 --- a/src/app/pages/editors/ckeditor.component.ts +++ /dev/null @@ -1,25 +0,0 @@ -import { - Component, - OnDestroy, - AfterViewInit, - Input, - Output, - EventEmitter, -} from '@angular/core'; - -import './ckeditor.loader'; -import 'ckeditor'; - -@Component({ - selector: 'ngx-ckeditor', - template: ` - - - - - - `, -}) -export class CKEditorComponent { - -} diff --git a/src/app/pages/editors/ckeditor.loader.ts b/src/app/pages/editors/ckeditor.loader.ts deleted file mode 100644 index 82322698..00000000 --- a/src/app/pages/editors/ckeditor.loader.ts +++ /dev/null @@ -1 +0,0 @@ -window['CKEDITOR_BASEPATH'] = '//cdn.ckeditor.com/4.6.2/full-all/'; diff --git a/src/app/pages/editors/editors-routing.module.ts b/src/app/pages/editors/editors-routing.module.ts index b136ce9c..fd3ae87c 100644 --- a/src/app/pages/editors/editors-routing.module.ts +++ b/src/app/pages/editors/editors-routing.module.ts @@ -3,7 +3,7 @@ import { Routes, RouterModule } from '@angular/router'; import { EditorsComponent } from './editors.component'; import { TinyMCEComponent } from './tiny-mce/tiny-mce.component'; -import { CKEditorComponent } from './ckeditor.component'; +import { CKEditorComponent } from './ckeditor/ckeditor.component'; const routes: Routes = [{ path: '', diff --git a/src/app/pages/pages-menu.ts b/src/app/pages/pages-menu.ts index 9dd1052f..9dd0c6a2 100644 --- a/src/app/pages/pages-menu.ts +++ b/src/app/pages/pages-menu.ts @@ -29,6 +29,9 @@ export const menuItems: List = List([{ }, { title: 'Typography', link: '/pages/ui-features/typography', + }, { + title: 'Tabs', + link: '/pages/ui-features/tabs', }]), }, { title: 'Components', diff --git a/src/app/pages/pages.component.ts b/src/app/pages/pages.component.ts index 27c81ddf..5311a094 100644 --- a/src/app/pages/pages.component.ts +++ b/src/app/pages/pages.component.ts @@ -2,6 +2,7 @@ import { Component } from '@angular/core'; import 'style-loader!../@theme/styles/cosmic/cosmic.theme.scss'; import 'style-loader!../@theme/styles/light/light.theme.scss'; +import 'style-loader!../@theme/styles/default/default.theme.scss'; @Component({ selector: 'ngx-pages', diff --git a/src/app/pages/ui-features/tabs/tabs.component.html b/src/app/pages/ui-features/tabs/tabs.component.html new file mode 100644 index 00000000..004cef61 --- /dev/null +++ b/src/app/pages/ui-features/tabs/tabs.component.html @@ -0,0 +1,26 @@ +
+
+ + Tabset + + + + Content #1 + + + Content #2 + + + Content #3 + + + + +
+
+ + Route Tabset + + +
+
diff --git a/src/app/pages/ui-features/tabs/tabs.component.scss b/src/app/pages/ui-features/tabs/tabs.component.scss new file mode 100644 index 00000000..e69de29b diff --git a/src/app/pages/ui-features/tabs/tabs.component.ts b/src/app/pages/ui-features/tabs/tabs.component.ts new file mode 100644 index 00000000..e12993c0 --- /dev/null +++ b/src/app/pages/ui-features/tabs/tabs.component.ts @@ -0,0 +1,9 @@ +import { Component } from '@angular/core'; + +@Component({ + selector: 'ngx-tabs', + styleUrls: ['./tabs.component.scss'], + templateUrl: './tabs.component.html', +}) +export class TabsComponent { +} diff --git a/src/app/pages/ui-features/ui-features-routing.module.ts b/src/app/pages/ui-features/ui-features-routing.module.ts index 159e4a31..a1119956 100644 --- a/src/app/pages/ui-features/ui-features-routing.module.ts +++ b/src/app/pages/ui-features/ui-features-routing.module.ts @@ -7,6 +7,7 @@ import { GridComponent } from './grid/grid.component'; import { IconsComponent } from './icons/icons.component'; import { ModalsComponent } from './modals/modals.component'; import { TypographyComponent } from './typography/typography.component'; +import { TabsComponent } from './tabs/tabs.component'; const routes: Routes = [{ path: '', @@ -26,6 +27,9 @@ const routes: Routes = [{ }, { path: 'typography', component: TypographyComponent, + }, { + path: 'tabs', + component: TabsComponent, }], }]; diff --git a/src/app/pages/ui-features/ui-features.module.ts b/src/app/pages/ui-features/ui-features.module.ts index 335a7453..59f4fade 100644 --- a/src/app/pages/ui-features/ui-features.module.ts +++ b/src/app/pages/ui-features/ui-features.module.ts @@ -1,4 +1,5 @@ import { NgModule } from '@angular/core'; +import { NgaTabsetModule, NgaRouteTabsetModule } from '@nga/theme'; import { SharedModule } from '../../shared.module'; @@ -18,6 +19,7 @@ import { GroupButtonsComponent } from './buttons/group/group.component'; import { LargeButtonsComponent } from './buttons/large/large.component'; import { ModalComponent } from './modals/modal/modal.component'; import { TypographyComponent } from './typography/typography.component'; +import { TabsComponent } from './tabs/tabs.component'; const COMPONENTS = [ UiFeaturesComponent, @@ -35,12 +37,15 @@ const COMPONENTS = [ LargeButtonsComponent, ModalComponent, TypographyComponent, + TabsComponent, ]; @NgModule({ imports: [ SharedModule, UiFeaturesRoutingModule, + NgaTabsetModule, + NgaRouteTabsetModule, ], declarations: [ ...COMPONENTS,