Skip to content

Commit 8879df0

Browse files
authored
feat(blog): welcome message (#401)
1 parent 59d723e commit 8879df0

File tree

5 files changed

+44
-0
lines changed

5 files changed

+44
-0
lines changed

apps/blog/src/assets/i18n/en.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
{
22
"homePage": {
3+
"welcomeMessage": {
4+
"description": "This is the place where you can learn Angular, discover best practices, explore advanced techniques, and stay updated with the latest news and trends.",
5+
"descriptionAriaLabel": "Visit House of Angular website"
6+
},
37
"seeAll": "See all the articles",
48
"latest": "Latest Articles",
59
"recommended": "Recommended Articles",

apps/blog/src/assets/i18n/pl.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,9 @@
11
{
22
"homePage": {
3+
"welcomeMessage": {
4+
"description": "Miejsce, gdzie możesz nauczyć się Angulara, odkrywać najlepsze praktyki, eksplorować zaawansowane techniki i być na bieżąco z najnowszymi Angularowymi wiadomościami oraz trendami.",
5+
"descriptionAriaLabel": "Sprawdź stronę House of Angular"
6+
},
37
"seeAll": "Zobacz wszystkie",
48
"latest": "Najnowsze Artykuły",
59
"recommended": "Polecane Artykuły",

libs/blog/home/feature-home/src/lib/home-page/home-page.component.html

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
<al-welcome-message />
2+
13
<al-latest-articles />
24

35
<al-articles-list />

libs/blog/home/feature-home/src/lib/home-page/home-page.component.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ import { PartnersComponent } from '@angular-love/blog/partners/ui-partners';
66
import { FeatureLatestArticlesComponent } from '@angular-love/feature-latest-articles';
77

88
import { hoaHireUs, partnersList } from './partners';
9+
import { WelcomeMessageComponent } from './welcome-message/welcome-message.component';
910

1011
@Component({
1112
selector: 'al-home-page',
@@ -14,6 +15,7 @@ import { hoaHireUs, partnersList } from './partners';
1415
PartnersComponent,
1516
FeatureLatestArticlesComponent,
1617
ArticlesListContainerComponent,
18+
WelcomeMessageComponent,
1719
],
1820
templateUrl: './home-page.component.html',
1921
styleUrls: ['./home-page.component.scss'],
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
import { ChangeDetectionStrategy, Component } from '@angular/core';
2+
import { TranslocoDirective } from '@jsverse/transloco';
3+
4+
@Component({
5+
standalone: true,
6+
selector: 'al-welcome-message',
7+
template: `
8+
<section
9+
*transloco="let t; read: 'homePage.welcomeMessage'"
10+
class="flex flex-col items-center justify-center space-y-3 py-3 text-center"
11+
>
12+
<h1 class="text-4xl font-bold">Angular.love Blog</h1>
13+
<p class="px-8">
14+
{{ t('description') }}
15+
</p>
16+
<p class="px-8">
17+
Powered by
18+
<a
19+
class="text-al-primary font-bold hover:underline"
20+
[attr.aria-label]="t('descriptionAriaLabel')"
21+
target="_blank"
22+
href="https://houseofangular.io/"
23+
>
24+
House of Angular
25+
</a>
26+
</p>
27+
</section>
28+
`,
29+
changeDetection: ChangeDetectionStrategy.OnPush,
30+
imports: [TranslocoDirective],
31+
})
32+
export class WelcomeMessageComponent {}

0 commit comments

Comments
 (0)