Skip to content

Commit 4712cbd

Browse files
committed
Merge branch 'dev' into juhaj77/chore/600-fix-all-lint-errors-and-warnings-from-codebase
2 parents b7a73f3 + 28c29c8 commit 4712cbd

File tree

50 files changed

+517
-133
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

50 files changed

+517
-133
lines changed
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
import { redirect } from 'next/navigation';
2+
import { getRouteAllMusicCollectionsPage } from '@/shared/appLinks/RoutePaths';
3+
4+
export default function Page({ params }: { params: { lng: string; collection: string } }) {
5+
redirect(`/${params.lng}${getRouteAllMusicCollectionsPage()}`);
6+
}
Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
import { createPage } from '@/app/_helpers';
2+
import { EthicalGuidelinesPageProps } from '@/preparedPages/EthicalGuidelinesPage';
3+
import { makeEthicalGuidelinesSectionsWithI18n } from '@/entities/PresentationPackages';
4+
import { getServerTranslation } from '@/shared/i18n';
5+
import { getRouteEthicalGuidelinesPage } from '@/shared/appLinks/RoutePaths';
6+
import { defaultOpenGraph } from '@/shared/seoConstants';
7+
8+
export async function _getPage(lng: string) {
9+
const { t } = await getServerTranslation(lng, 'ethics');
10+
11+
return createPage<EthicalGuidelinesPageProps>({
12+
buildPage: () => ({
13+
sections: makeEthicalGuidelinesSectionsWithI18n(t),
14+
title: t('main-title'),
15+
}),
16+
buildSeo: () => ({
17+
title: t('main-title'),
18+
description: t('head-description'),
19+
keywords: t('head-keywords'),
20+
openGraph: {
21+
...defaultOpenGraph,
22+
title: t('og-title'),
23+
description: t('og-description'),
24+
url: `/${lng}${getRouteEthicalGuidelinesPage()}`,
25+
},
26+
alternates: {
27+
canonical: `/${lng}${getRouteEthicalGuidelinesPage()}`,
28+
},
29+
}),
30+
});
31+
}
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
export { PageLoader as default } from '@/widgets/PageLoader';
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
import { EthicalGuidelinesPage } from '@/preparedPages/EthicalGuidelinesPage';
2+
import { withPageData, withMetadataGenerator } from '@/app/_helpers';
3+
import { _getPage } from './_getPage';
4+
5+
export const generateMetadata = withMetadataGenerator(_getPage);
6+
export default withPageData(EthicalGuidelinesPage, _getPage);
Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,10 @@
11
import { ReactNode } from 'react';
2-
import { ScrollTop } from '@/features/ScrollTop';
32
import { FurnitureLayout } from '@/preparedPages/FurniturePages';
43

54
type Props = {
65
children: ReactNode;
76
};
87

98
export default function Layout({ children }: Props) {
10-
return (
11-
<FurnitureLayout>
12-
{children}
13-
<ScrollTop />
14-
</FurnitureLayout>
15-
);
9+
return <FurnitureLayout>{children}</FurnitureLayout>;
1610
}

frontend-next-migration/src/app/[lng]/(helper)/layout.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import { ReactNode } from 'react';
22
import { Footer } from '@/widgets/Footer';
33
import { Navbar } from '@/widgets/Navbar';
4+
import { ScrollTop } from '@/features/ScrollTop';
45
import LayoutDefault from '../../../preparedPages/Layouts/ui/LayoutDefault/LayoutDefault';
56

67
type Props = {
@@ -15,6 +16,7 @@ export default function HelperLayout({ children }: Props) {
1516
<div style={{ flex: 1 }}>
1617
<LayoutDefault>{children}</LayoutDefault>
1718
</div>
19+
<ScrollTop />
1820
<Footer />
1921
</div>
2022
);

frontend-next-migration/src/app/[lng]/(home)/_getPage.ts

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ export async function _getPage(lng: string) {
8080
href: getRouteAllHeroesPage(),
8181
},
8282
},
83-
gallery: {
83+
altZone: {
8484
title: t('project-description-title'),
8585
infoText: t('project-description-text'),
8686
socialsText: t('socials-text'),
@@ -97,23 +97,6 @@ export async function _getPage(lng: string) {
9797
videoLink: AppExternalLinks.previewVideoYoutube,
9898
gameImg: iPhone16,
9999
},
100-
galleryCopy: {
101-
title: t('project-description-title'),
102-
infoText: t('project-description-text'),
103-
socialsText: t('socials-text'),
104-
followUsText: t('follow-us-text'),
105-
seeMoreLink: {
106-
text: t('gallery-seeMore'),
107-
href: getRouteAboutPage(),
108-
},
109-
socialMediaLinks: [
110-
AppExternalLinks.igPost1,
111-
AppExternalLinks.igPost2,
112-
AppExternalLinks.fbPost1,
113-
],
114-
videoLink: AppExternalLinks.previewVideoYoutube,
115-
gameImg: gameImg,
116-
},
117100
contactSection: {
118101
title: t('contact-title'),
119102
googlePLayLink: AppExternalLinks.duunitori,

frontend-next-migration/src/app/[lng]/(home)/layout.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,8 @@ export default function HomeLayout({ children }: Props) {
1414
<div style={{ display: 'flex', flexDirection: 'column', minHeight: '100vh' }}>
1515
<Navbar />
1616
<div className={cls.joinUsLayout}>{children}</div>
17-
<Footer />
1817
<ScrollTop />
18+
<Footer />
1919
</div>
2020
);
2121
}

frontend-next-migration/src/entities/PresentationPackages/index.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,3 +9,6 @@ export { makeCookiesSectionsWithI18n } from '@/entities/PresentationPackages/mod
99

1010
export { PrivacySections } from '@/entities/PresentationPackages/model/data/privacySections';
1111
export { makePrivacySectionsWithI18n } from '@/entities/PresentationPackages/model/makeSectionsWithI18n';
12+
13+
export { EthicalGuidelinesSections } from '@/entities/PresentationPackages/model/data/ethicalGuidelinesSections';
14+
export { makeEthicalGuidelinesSectionsWithI18n } from '@/entities/PresentationPackages/model/makeSectionsWithI18n';
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
import { createSection } from '../createSection';
2+
3+
const i18nKeyPrefixes = ['intro', 'players', 'employees', 'business', 'society', 'law'];
4+
5+
const imageSrcs = [''];
6+
const logoSrc = '';
7+
8+
export const EthicalGuidelinesSections = i18nKeyPrefixes.map((key, index) =>
9+
createSection({
10+
prefix: key,
11+
index,
12+
image: {
13+
src: imageSrcs[index],
14+
alt: `${key}-image`,
15+
},
16+
logo: {
17+
src: logoSrc,
18+
alt: `${key}-logo`,
19+
},
20+
}),
21+
);

0 commit comments

Comments
 (0)