From 8a0d067716a22840adf9d685988994aedc356bad Mon Sep 17 00:00:00 2001 From: Barsnes Date: Wed, 12 Jun 2024 12:09:40 +0200 Subject: [PATCH] post layouts --- .../Layout => (frontpage)}/layout.module.css | 0 .../blog-layout.tsx => (frontpage)/layout.tsx} | 4 +++- .../app/bloggen/{ => (frontpage)}/page.mdx | 5 ++--- .../page.mdx | 5 ++--- .../app/bloggen/2024/altinn-studio/page.mdx | 5 ++--- .../app/bloggen/2024/bachelor-temavelger/page.mdx | 5 ++--- .../app/bloggen/2024/fluid-typography/page.mdx | 5 ++--- apps/storefront/app/bloggen/2024/layout.tsx | 5 ----- apps/storefront/app/bloggen/2024/v1rc1/page.mdx | 5 ++--- .../bloggen/_components}/Figures.tsx | 0 .../_components/PostLayout/PostLayout.module.css} | 0 .../bloggen/_components/PostLayout/PostLayout.tsx} | 13 ++++++------- apps/storefront/app/bloggen/_components/index.ts | 3 ++- apps/storefront/layouts/index.tsx | 1 - 14 files changed, 23 insertions(+), 33 deletions(-) rename apps/storefront/app/bloggen/{_components/Layout => (frontpage)}/layout.module.css (100%) rename apps/storefront/app/bloggen/{_components/Layout/blog-layout.tsx => (frontpage)/layout.tsx} (87%) rename apps/storefront/app/bloggen/{ => (frontpage)}/page.mdx (93%) delete mode 100644 apps/storefront/app/bloggen/2024/layout.tsx rename apps/storefront/{layouts/BlogArticleLayout/components => app/bloggen/_components}/Figures.tsx (100%) rename apps/storefront/{layouts/BlogArticleLayout/BlogArticleLayout.module.css => app/bloggen/_components/PostLayout/PostLayout.module.css} (100%) rename apps/storefront/{layouts/BlogArticleLayout/BlogArticleLayout.tsx => app/bloggen/_components/PostLayout/PostLayout.tsx} (89%) diff --git a/apps/storefront/app/bloggen/_components/Layout/layout.module.css b/apps/storefront/app/bloggen/(frontpage)/layout.module.css similarity index 100% rename from apps/storefront/app/bloggen/_components/Layout/layout.module.css rename to apps/storefront/app/bloggen/(frontpage)/layout.module.css diff --git a/apps/storefront/app/bloggen/_components/Layout/blog-layout.tsx b/apps/storefront/app/bloggen/(frontpage)/layout.tsx similarity index 87% rename from apps/storefront/app/bloggen/_components/Layout/blog-layout.tsx rename to apps/storefront/app/bloggen/(frontpage)/layout.tsx index e3850e95ee..01fd35daf7 100644 --- a/apps/storefront/app/bloggen/_components/Layout/blog-layout.tsx +++ b/apps/storefront/app/bloggen/(frontpage)/layout.tsx @@ -9,7 +9,7 @@ import { import classes from './layout.module.css'; -export const Layout = ({ children }: { children: React.ReactNode }) => { +const Layout = ({ children }: { children: React.ReactNode }) => { return (
@@ -29,3 +29,5 @@ export const Layout = ({ children }: { children: React.ReactNode }) => {
); }; + +export default Layout; diff --git a/apps/storefront/app/bloggen/page.mdx b/apps/storefront/app/bloggen/(frontpage)/page.mdx similarity index 93% rename from apps/storefront/app/bloggen/page.mdx rename to apps/storefront/app/bloggen/(frontpage)/page.mdx index 4dc0591de3..5963815da1 100644 --- a/apps/storefront/app/bloggen/page.mdx +++ b/apps/storefront/app/bloggen/(frontpage)/page.mdx @@ -1,10 +1,9 @@ import { PencilIcon } from '@navikt/aksel-icons'; import { Meta } from '@components'; -import { Layout } from '@blog'; -import { BlogCard } from './_components'; +import { BlogCard } from '../_components'; -export default ({ children }) => {children}; +export default ({ children }) => <>{children}; ( - ( - ( - ( - { - return <>{children}; -}; - -export default Layout; diff --git a/apps/storefront/app/bloggen/2024/v1rc1/page.mdx b/apps/storefront/app/bloggen/2024/v1rc1/page.mdx index ebea531d8d..b76d8b019b 100644 --- a/apps/storefront/app/bloggen/2024/v1rc1/page.mdx +++ b/apps/storefront/app/bloggen/2024/v1rc1/page.mdx @@ -1,11 +1,10 @@ import { Link } from '@digdir/designsystemet-react'; -import { BlogArticleLayout } from '@layouts'; +import { PostLayout, Contributors } from '../../_components'; import { ResponsiveIframe, CodeSnippet } from '@components'; -import { Contributors } from '../../_components'; export default ({ children }) => ( -