From 89ac48df4c1a80bab351fadf6a857aafde91bbd5 Mon Sep 17 00:00:00 2001 From: Patrick Alvin Alcala Date: Mon, 1 Sep 2025 10:20:18 +0800 Subject: [PATCH 1/2] Combined head and body to html component --- fwt/components/HTML/HTML.sass | 13 +++++++++++++ fwt/components/HTML/HTML.tsx | 28 ++++++++++++++++++++++++++++ fwt/components/Head/Head.tsx | 20 -------------------- 3 files changed, 41 insertions(+), 20 deletions(-) create mode 100644 fwt/components/HTML/HTML.sass create mode 100644 fwt/components/HTML/HTML.tsx delete mode 100644 fwt/components/Head/Head.tsx diff --git a/fwt/components/HTML/HTML.sass b/fwt/components/HTML/HTML.sass new file mode 100644 index 0000000..8f2ac4b --- /dev/null +++ b/fwt/components/HTML/HTML.sass @@ -0,0 +1,13 @@ +@use '/src/styles/variables.sass' as vars +@use '/src/styles/fonts.sass' as fonts + +.body + color: vars.$textColor + +.inter + @extend .body + font-family: fonts.$Inter + +.roboto + @extend .body + font-family: fonts.$Roboto diff --git a/fwt/components/HTML/HTML.tsx b/fwt/components/HTML/HTML.tsx new file mode 100644 index 0000000..b5ead9e --- /dev/null +++ b/fwt/components/HTML/HTML.tsx @@ -0,0 +1,28 @@ +import './HTML.sass' + +interface Props { + title: string + name: string + description: string + children: any + font?: string +} + +export default (props: Props) => { + return ( + <> + + + + + + + + {props.title} + + + {props.children} + + + ) +} diff --git a/fwt/components/Head/Head.tsx b/fwt/components/Head/Head.tsx deleted file mode 100644 index 8299bc9..0000000 --- a/fwt/components/Head/Head.tsx +++ /dev/null @@ -1,20 +0,0 @@ -interface Props { - title: string - name: string - description: string -} - -export default (props: Props) => { - return ( - <> - - - - - - - {props.title} - - - ) -} From f8c7d24cb53d955aa98551b7b8a9a76e8308f413 Mon Sep 17 00:00:00 2001 From: Patrick Alvin Alcala Date: Mon, 1 Sep 2025 10:20:27 +0800 Subject: [PATCH 2/2] Used new html component --- src/layouts/Layout.astro | 23 +++++------------------ 1 file changed, 5 insertions(+), 18 deletions(-) diff --git a/src/layouts/Layout.astro b/src/layouts/Layout.astro index 7275c1a..ee94ef6 100644 --- a/src/layouts/Layout.astro +++ b/src/layouts/Layout.astro @@ -6,23 +6,10 @@ const websiteDescription = 'This is just a template.' import Background from '../../fwt/components/Background/Background' import OptimizeBackground from '../../fwt/components/Optimizer/OptimizeBackground' -import Head from '../../fwt/components/Head/Head' +import HTML from '../../fwt/components/HTML/HTML' --- - - - - - - - - - - + + + +