Skip to content

Commit

Permalink
Merge branch 'master' into tzhelev/esf-load-on-demand-sample
Browse files Browse the repository at this point in the history
  • Loading branch information
tachojelev authored Aug 26, 2019
2 parents b46797f + 54778c9 commit 4850f58
Show file tree
Hide file tree
Showing 7 changed files with 104 additions and 2 deletions.
11 changes: 11 additions & 0 deletions live-editing/configs/NavbarConfigGenerator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
import { IgxIconModule, IgxNavbarModule } from "igniteui-angular";
import { NavbarSample1Component } from "../../src/app/menus/navbar/navbar-sample-1/navbar-sample-1.component";
import { NavbarSample2Component } from "../../src/app/menus/navbar/navbar-sample-2/navbar-sample-2.component";
import { NavbarStyleComponent } from "../../src/app/menus/navbar/navbar-style/navbar-style.component";
import { NavbarComponent } from "../../src/app/menus/navbar/navbar.component";
import { AppModuleConfig } from "./core/AppModuleConfig";
import { Config } from "./core/Config";
Expand Down Expand Up @@ -41,6 +42,16 @@ export class NavbarConfigGenerator implements IConfigGenerator {
shortenComponentPathBy: "/menus/navbar/"
}));

configs.push(new Config({
component: NavbarStyleComponent,
appModuleConfig: new AppModuleConfig({
imports: [IgxIconModule, IgxNavbarModule, NavbarStyleComponent],
ngDeclarations: [NavbarStyleComponent],
ngImports: [IgxIconModule, IgxNavbarModule]
}),
shortenComponentPathBy: "/menus/navbar/"
}));

return configs;
}
}
3 changes: 2 additions & 1 deletion src/app/menus/menus-routes-data.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
export const menusRoutesData = {
"navbar": { displayName: "Navbar Overview", parentName: "Navbar" },
"navbar-sample-1": { displayName: "Navbar Action Button Icon", parentName: "Navbar" },
"navbar-sample-2": { displayName: "Navbar Custom Action Icon", parentName: "Navbar" }
"navbar-sample-2": { displayName: "Navbar Custom Action Icon", parentName: "Navbar" },
"navbar-style": { displayName: "Navbar Style", parentName: "Navbar" }
};
6 changes: 6 additions & 0 deletions src/app/menus/menus-routing.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ import { RouterModule, Routes } from "@angular/router";
import { menusRoutesData } from "./menus-routes-data";
import { NavbarSample1Component } from "./navbar/navbar-sample-1/navbar-sample-1.component";
import { NavbarSample2Component } from "./navbar/navbar-sample-2/navbar-sample-2.component";
import { NavbarStyleComponent } from "./navbar/navbar-style/navbar-style.component";
import { NavbarComponent } from "./navbar/navbar.component";
import { NavDrawerMiniComponent } from "./navdrawer/nav-drawer-mini/nav-drawer-mini.component";
import { NavDrawerPinComponent } from "./navdrawer/nav-drawer-pin/nav-drawer-pin.component";
Expand Down Expand Up @@ -41,6 +42,11 @@ export const menusRoutes: Routes = [
component: NavbarSample2Component,
data: menusRoutesData["navbar-sample-2"],
path: "navbar-sample-2"
},
{
component: NavbarStyleComponent,
data: menusRoutesData["navbar-style"],
path: "navbar-style"
}
];

Expand Down
4 changes: 3 additions & 1 deletion src/app/menus/menus.module.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import {
import { MenusRoutingModule } from "./menus-routing.module";
import { NavbarSample1Component } from "./navbar/navbar-sample-1/navbar-sample-1.component";
import { NavbarSample2Component } from "./navbar/navbar-sample-2/navbar-sample-2.component";
import { NavbarStyleComponent } from "./navbar/navbar-style/navbar-style.component";
import { NavbarComponent } from "./navbar/navbar.component";
import { NavDrawerMiniComponent } from "./navdrawer/nav-drawer-mini/nav-drawer-mini.component";
import { NavDrawerPinComponent } from "./navdrawer/nav-drawer-pin/nav-drawer-pin.component";
Expand All @@ -29,7 +30,8 @@ import { NavdrawerComponent } from "./navdrawer/navdrawer.component";
NavDrawerSimpleComponent,
NavbarComponent,
NavbarSample1Component,
NavbarSample2Component
NavbarSample2Component,
NavbarStyleComponent
],
imports: [
CommonModule,
Expand Down
9 changes: 9 additions & 0 deletions src/app/menus/navbar/navbar-style/navbar-style.component.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<article class="sample-column">
<div class="navbar-sample">
<igx-navbar title="Sample App" actionButtonIcon="menu" [isActionButtonVisible]="true">
<igx-icon>search</igx-icon>
<igx-icon>favorite</igx-icon>
<igx-icon>more_vert</igx-icon>
</igx-navbar>
</div>
</article>
59 changes: 59 additions & 0 deletions src/app/menus/navbar/navbar-style/navbar-style.component.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
@import '~igniteui-angular/lib/core/styles/themes/index';

/*BASIC THEMING*/

$dark-navbar: igx-navbar-theme(
$text-color: #FFCD0F,
$background: #292826,
$idle-icon-color: #FFCD0F,
$hover-icon-color: gray
);

/*ENHANCED APPROACHES*/

// $yellow-color: #FFCD0F;
// $black-color: #292826;
// $dark-palette: igx-palette($primary: $black-color, $secondary: $yellow-color);

/*PALETTE and IGX-COLOR*/

// $dark-navbar: igx-navbar-theme(
// $text-color: igx-color($dark-palette, "secondary", 400),
// $background: igx-color($dark-palette, "primary", 400),
// $idle-icon-color: igx-color($dark-palette, "secondary", 400),
// $hover-icon-color: gray
// );

/*SCHEMAS*/

// $dark-navbar-schema: extend($_dark-navbar,
// (
// text-color: (
// igx-color: ("secondary", 400)
// ),
// background: (
// igx-color: ("primary", 400)
// ),
// idle-icon-color:(
// igx-color: ("secondary", 400)
// ),
// hover-icon-color: gray
// )
// );

// $custom-dark-schema: extend($dark-schema,(
// igx-navbar: $dark-navbar-schema
// ));

// $dark-navbar: igx-navbar-theme(
// $palette: $dark-palette,
// $schema: $custom-dark-schema
// );

/*INCLUSION by DEFAULT ViewEncapsulation strategy*/

:host {
::ng-deep {
@include igx-navbar($dark-navbar);
}
}
14 changes: 14 additions & 0 deletions src/app/menus/navbar/navbar-style/navbar-style.component.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
import { Component, OnInit } from "@angular/core";

@Component({
selector: "app-navbar-style",
styleUrls: ["./navbar-style.component.scss"],
templateUrl: "./navbar-style.component.html"
})
export class NavbarStyleComponent implements OnInit {

constructor() { }

public ngOnInit() {
}
}

0 comments on commit 4850f58

Please sign in to comment.