Skip to content

Commit b9856a1

Browse files
authoredNov 18, 2016
feat(homepage): Use static content in homepage (#16)
1 parent a87e3c6 commit b9856a1

File tree

2 files changed

+35
-43
lines changed

2 files changed

+35
-43
lines changed
 

‎material.angular.io/src/app/pages/homepage/homepage.html

+34-6
Original file line numberDiff line numberDiff line change
@@ -11,15 +11,43 @@ <h1>Angular Material</h1>
1111
</header>
1212

1313
<div class="docs-homepage-promo">
14-
<div *ngFor="let section of homePageContent"
15-
class="docs-homepage-row"
16-
[class.docs-homepage-reverse-row]="section.reverse">
14+
<div class="docs-homepage-row">
1715
<div class="docs-homepage-promo-img">
18-
<img [src]="getImagePath(section.img)" [alt]="section.title" />
16+
<img src="../assets/img/homepage/sprintzerotoapp.svg" alt="Sprint from Zero to App" />
1917
</div>
2018
<div class="docs-homepage-promo-desc">
21-
<h2>{{section.title}}</h2>
22-
<p>{{section.content}}</p>
19+
<h2>Sprint from Zero to App</h2>
20+
<p>Hit the ground running with comprehensive, modern UI components that work across
21+
the web, mobile and desktop</p>
22+
</div>
23+
</div>
24+
<div class="docs-homepage-row docs-homepage-reverse-row">
25+
<div class="docs-homepage-promo-img">
26+
<img src="../assets/img/homepage/fastandconsistent.svg" alt="Fast and Consistent" />
27+
</div>
28+
<div class="docs-homepage-promo-desc">
29+
<h2>Fast and Consistent</h2>
30+
<p>Finely tunes performance, because every millisecond counts. Fully tested across
31+
modern browsers.</p>
32+
</div>
33+
</div>
34+
<div class="docs-homepage-row">
35+
<div class="docs-homepage-promo-img">
36+
<img src="../assets/img/homepage/versatile.svg" alt="Versatile" />
37+
</div>
38+
<div class="docs-homepage-promo-desc">
39+
<h2>Versatile</h2>
40+
<p>Themable, for when you need to stay on brand or just have a facourite color.
41+
Accessible and internationalized so that all users are welcome.</p>
42+
</div>
43+
</div>
44+
<div class="docs-homepage-row docs-homepage-reverse-row">
45+
<div class="docs-homepage-promo-img">
46+
<img src="../assets/img/homepage/optimized.svg" alt="Optimized for Angular" />
47+
</div>
48+
<div class="docs-homepage-promo-desc">
49+
<h2>Optimized for Angular</h2>
50+
<p>Built by the Angular team to integrate seamlessly with Angular 2.</p>
2351
</div>
2452
</div>
2553
<div class="docs-homepage-bottom-start">

‎material.angular.io/src/app/pages/homepage/homepage.ts

+1-37
Original file line numberDiff line numberDiff line change
@@ -5,40 +5,4 @@ import { Component} from '@angular/core';
55
templateUrl: 'homepage.html',
66
styleUrls: ['homepage.scss']
77
})
8-
export class Homepage {
9-
private _imagePath: string = '../assets/img/homepage/';
10-
11-
homePageContent = [
12-
{
13-
title: 'Sprint from Zero to App',
14-
content: `Hit the ground running with comprehensive, modern UI components that work across
15-
the web, mobile and desktop`,
16-
reverse: false,
17-
img: 'sprintzerotoapp.svg',
18-
},
19-
{
20-
title: 'Fast and Consistent',
21-
content: `Finely tunes performance, because every millisecond counts. Fully tested across
22-
modern browsers.`,
23-
reverse: true,
24-
img: 'fastandconsistent.svg',
25-
},
26-
{
27-
title: 'Versatile',
28-
content: `Themable, for when you need to stay on brand or just have a facourite color.
29-
Accessible and internationalized so that all users are welcome.`,
30-
reverse: false,
31-
img: 'versatile.svg',
32-
},
33-
{
34-
title: 'Optimized for Angular',
35-
content: 'Built by the Angular team to integrate seamlessly with Angular 2.',
36-
reverse: true,
37-
img: 'optimized.svg',
38-
},
39-
];
40-
41-
getImagePath(srcSvg: string): string {
42-
return this._imagePath + srcSvg;
43-
}
44-
}
8+
export class Homepage {}

0 commit comments

Comments
 (0)
Please sign in to comment.