Commit 37ac6be9 authored by prumde's avatar prumde

Updated


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@174204 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 3fd7459c
......@@ -376,16 +376,40 @@ ecm-search{
background-color: mediumvioletred;
}
.ecm-menu-icon {
width: 32px;
height: 4px;
background-color: white;
margin: 6px 0;
display: block;
opacity: 0.8;
}
.nav-menu-box {
height: 60px;
width: 60px;
}
.user-nav-menu {
cursor: pointer;
cursor: pointer;
padding: 13px 0px;
height: 60px;
min-width: 60px !important;
}
.ecm-menu-icon1 {
height: 3px;
width: 28px;
}
.ecm-menu-icon2 {
height: 3px;
width: 22px;
}
.ecm-menu-icon3 {
height: 2px;
width: 28px;
}
.onSelect {
background: rgba(68, 68, 68, 0.16);
}
@media screen and (max-width: 750px){
......
......@@ -57,16 +57,16 @@ Overlay End -->
<ng-template #fixedHeaderLarge>
<md-toolbar color="primary">
<div>
<span class="ecm-menu-icon"></span>
<span class="ecm-menu-icon"></span>
<span class="ecm-menu-icon"></span>
</div>
<button [ngClass]="{onSelect: selectedOption === 'MENU'}" md-button (click)="menuAction();" class="user-nav-menu">
<span class="ecm-menu-icon ecm-menu-icon1"></span>
<span class="ecm-menu-icon ecm-menu-icon2"></span>
<span class="ecm-menu-icon ecm-menu-icon3"></span>
</button>
<img class="fixed-header-logo img-logo-32" src="logo_32_32.svg" />
<span class="siteHeading">{{siteHeading}}</span>
<ecm-search [compFadeState]="headerFadeState" [headerState]="'fixed'"></ecm-search>
<span (click)="cartAction();" >
<button md-button class="square-button">
<button [ngClass]="{onSelect: selectedOption === 'CART'}" md-button class="square-button">
<span *ngIf="(cartItems | async)?.length!=0" class="fixed-header-badge">{{(cartItems | async)?.length}}</span>
<img mdTooltip="Show Cart" [mdTooltipPosition]="'below'" class="fixed-header-cart img-cart-32" src="cart_32_32.svg"/>
<!-- <img *ngIf="cartItems == 0" class="fixed-header-cart img-cart-32 no-badge" /> -->
......@@ -74,7 +74,7 @@ Overlay End -->
</button>
</span>
<span (click)="userAction();" >
<button md-button class="square-button">
<button [ngClass]="{onSelect: selectedOption === 'USER'}" md-button class="square-button">
<img *ngIf="userData" mdTooltip="Click here to Manage Account" [mdTooltipPosition]="'below'" [src]="profileImageLink" onerror="this.src = '/ecm/assets/images/svg/user_32_32.svg'; this.className = 'fixed-header-no-user'" title="{{userData.name}}" [ngClass]="( userImage.src.indexOf('/ibase/') > 0 ) ? 'fixed-header-user' : 'fixed-header-no-user' " #userImage/>
<img *ngIf="!userData" mdTooltip="Click here for Login" [mdTooltipPosition]="'below'" class="fixed-header-no-user img-user-32" src="user_32_32.svg"/>
<!--<md-icon class="example-icon">account_circle</md-icon>-->
......@@ -86,9 +86,9 @@ Overlay End -->
<ng-template #fixedHeaderSmall >
<md-toolbar color="primary">
<div (click)="menuAction();" class="user-nav-menu">
<span class="ecm-menu-icon"></span>
<span class="ecm-menu-icon"></span>
<span class="ecm-menu-icon"></span>
<span class="ecm-menu-icon ecm-menu-icon1"></span>
<span class="ecm-menu-icon ecm-menu-icon2"></span>
<span class="ecm-menu-icon ecm-menu-icon3"></span>
</div>
<img class="fixed-header-logo img-logo-32" src="logo_32_32.svg" />
<span class="siteHeading">{{siteHeading}}</span>
......
......@@ -219,13 +219,21 @@ export class ECMHeaderComponent implements OnInit, OnDestroy {
if ( this.userData )
{
//show sidepanel with user-option
this.ecmPanel.open({ type: 'inplace', option: 'USER_OPT', top:'65px', right: '20px', width:'300px', height: '400px' });
this.ecmPanel.open({ type: 'inplace', option: 'USER_OPT', top:'65px', left: '', right: '20px', width:'300px', height: '400px' });
}
else
{
//show overlay with sign-in-option
this.ecmPanel.open({ type: 'overlay', option: 'SIGNIN_OPT', top:'100px', left: 'calc( 50% - 375px / 2 )', width:'375px', height: '535px' });
}
if(this.selectedOption){
this.selectedOption = null;
this.closeMenu();
}
else{
this.selectedOption = "USER";
}
}
}
......@@ -244,11 +252,19 @@ export class ECMHeaderComponent implements OnInit, OnDestroy {
//show sidepanel with cart-option
if(this.cartCounter == 0)
{
this.ecmPanel.open({ type: 'inplace', option: 'CART_OPT', top:'65px', right: '75px', width:'300px' });
this.ecmPanel.open({ type: 'inplace', option: 'CART_OPT', top:'65px', left: '', right: '75px', width:'300px', height: '320px'});
}
else
{
this.ecmPanel.open({ type: 'inplace', option: 'CART_OPT', top:'65px', right: '75px', width:'360px', height: '400px' });
this.ecmPanel.open({ type: 'inplace', option: 'CART_OPT', top:'65px', left: '', right: '75px', width:'360px', height: '400px' });
}
if(this.selectedOption){
this.selectedOption = null;
this.closeMenu();
}
else{
this.selectedOption = "CART";
}
}
}
......@@ -256,15 +272,23 @@ export class ECMHeaderComponent implements OnInit, OnDestroy {
searchAction() {
//show overlay(height:60px) with ecm-search
this.ecmPanel.open('SEARCH_OPT');
this.ecmPanel.updatePosition({ top:'0px', left: '0px' });
this.ecmPanel.updateSize({ width:'100%', height: '60px' });
this.ecmPanel.open({ type: 'overlay', option: 'SEARCH_OPT', hideClose: true, top:'65px', right: '75px', left: '0px', width:'100%', height: '60px' });
}
menuAction() {
if( this.clientWidth < 640 ){
this.ecmPanel.open({ type: 'overlay', option: 'MENU_OPT', top:'', right: '', width:'80%' });
this.ecmPanel.open({ type: 'overlay', option: 'MENU_OPT', top:'', right: '', width:'80%', height: '100%' });
}
else {
this.ecmPanel.open({ type: 'inplace', option: 'MENU_OPT', hideClose: true , top:'60px', left: '16px', width:'280px', height: '70%' });
if(this.selectedOption){
this.selectedOption = null;
this.closeMenu();
}
else{
this.selectedOption = "MENU";
}
}
}
......@@ -284,6 +308,11 @@ export class ECMHeaderComponent implements OnInit, OnDestroy {
console.log(this.userImage.nativeElement.src.indexOf('/ecm/'));
}
closeMenu() {
console.log('Close------');
this.ecmPanel.close();
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment