Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

🔥 actions/plus pages (NGC-1470) #793

Open
wants to merge 2 commits into
base: preprod
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion next.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,6 @@ const nextConfig = {
'*': ['.next/cache/webpack', '.git/**/*', 'cypress/**/*'],
'/blog': ['public/NGC_Kit.diffusion.zip'],
'/nouveautes': ['public/images/blog', 'public/NGC_Kit.diffusion.zip'],
'/actions/plus': ['public/images/blog', 'public/NGC_Kit.diffusion.zip'],
'/sitemap.xml': ['public/images/blog', 'public/NGC_Kit.diffusion.zip'],
},
optimizePackageImports: ['@incubateur-ademe/nosgestesclimat'],
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,7 @@
import Link from '@/components/Link'
import BookClosedIcon from '@/components/icons/BookClosedIcon'
import Trans from '@/components/translation/Trans'
import {
actionsClickActionsPlus,
actionsClickAdeme,
} from '@/constants/tracking/pages/actions'
import { actionsClickAdeme } from '@/constants/tracking/pages/actions'
import Card from '@/design-system/layout/Card'
import { useClientTranslation } from '@/hooks/useClientTranslation'
import { trackEvent } from '@/utils/matomo/trackEvent'
Expand All @@ -25,21 +22,7 @@ export default function AllerPlusLoin() {
</div>

<div>
<p className="text-white">
Au-delà d'un simple chiffre, découvrez les enjeux qui se cachent
derrière chaque action :
</p>

<ul>
<li className="mb-1">
<Link
className="block text-white underline hover:text-primary-200"
href="/actions/plus"
onClick={() => trackEvent(actionsClickActionsPlus)}>
<Trans>Explorez le détail de nos actions clés</Trans>
</Link>
</li>

<li>
<Link
className="block text-white underline hover:text-primary-200"
Expand Down

This file was deleted.

This file was deleted.

46 changes: 0 additions & 46 deletions src/app/(simulation)/(large-layout)/actions/plus/page.tsx

This file was deleted.

4 changes: 0 additions & 4 deletions src/app/(simulation)/(large-layout)/plan-du-site/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,6 @@ export default async function PlanDuSitePage() {
title: t('Nos actions pour réduire votre empreinte'),
href: '/actions',
},
actionsPlus: {
title: t('Les actions phares'),
href: '/actions/plus',
},
},
'Comparez votre empreinte': {
organisation: {
Expand Down
17 changes: 1 addition & 16 deletions src/app/sitemap.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { getPosts } from '@/helpers/markdown/getPosts'
import { encodeRuleName } from '@/utils/publicodes/encodeRuleName'
import rules from '@incubateur-ademe/nosgestesclimat/public/co2-model.FR-lang.fr-opti.json'
import type { MetadataRoute } from 'next'
import { utils } from 'publicodes'
Expand All @@ -8,7 +7,6 @@ export default async function sitemap(): Promise<MetadataRoute.Sitemap> {
const staticPages = [
'',
'personas',
'actions/plus',
'nouveautes',
'a-propos',
'contact',
Expand Down Expand Up @@ -50,18 +48,5 @@ export default async function sitemap(): Promise<MetadataRoute.Sitemap> {
priority: 0.6,
}))

const actionPosts = await getPosts(`src/locales/actions-plus/fr/`)
const actionUrls = actionPosts.map((post) => ({
url: `https://nosgestesclimat.fr/actions/plus/${encodeRuleName(post?.slug ?? '')}`,
lastModified: new Date(),
priority: 0.8,
}))

return [
...staticUrls,
...blogUrls,
...actionUrls,
...releaseUrls,
...documentationUrls,
]
return [...staticUrls, ...blogUrls, ...releaseUrls, ...documentationUrls]
}
8 changes: 0 additions & 8 deletions src/constants/tracking/pages/actions.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,14 +46,6 @@ export const actionsOpenAction = (action: DottedName) => [
`Open Action ${action}`,
]

// Figma comment #114
export const actionsClickActionsPlus = [
'trackEvent',
'Actions',
'Click More infos',
'Click Actions Plus',
]

// Figma comment #114
export const actionsClickAdeme = [
'trackEvent',
Expand Down
Loading