Skip to content

Commit

Permalink
Merge pull request #164 from GSA/top-banner
Browse files Browse the repository at this point in the history
Added description for the top banner
  • Loading branch information
yerramshilpa authored Feb 28, 2020
2 parents a70de6f + cfeae5a commit 7720a69
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
<sds-header #header [model]="modelHeader" (linkEvent)="linkEvent.next($event)"></sds-header>
<sds-header #header [model]="modelHeader" (linkEvent)="linkEvent.next($event)"
topBannerDescription="Authoritative site for Assistance Listings and Wage Determinations only"
></sds-header>
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
<sds-top-banner *ngIf="showTopBanner"></sds-top-banner>
<sds-top-banner *ngIf="showTopBanner"
[description]="topBannerDescription"
></sds-top-banner>
<div
class="usa-overlay"
[class.is-visible]="mobileNavActive"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export class SdsHeaderComponent {
*/
@Input() model: HeaderModel;

@Input() topBannerDescription: string = '';
/**
* Takes in a text string and removes all white space characters and returns the new string
* @param text
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,9 @@
>
<span class="usa-banner__button-text">Here’s how you know</span>
</button>
<div class="usa-banner__header-description">
<em>{{ description }}</em>
</div>
</div>
</header>
<div
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Component } from '@angular/core';
import { Component, Input } from '@angular/core';

@Component({
selector: 'sds-top-banner',
Expand All @@ -7,6 +7,7 @@ import { Component } from '@angular/core';
})
export class SdsTopBannerComponent {
showDetail = false;
@Input() description = '';

toggleDetails() {
this.showDetail = !this.showDetail;
Expand Down

0 comments on commit 7720a69

Please sign in to comment.