Updated html component
This commit is contained in:
parent
ec2ddd719c
commit
11f7309f57
2 changed files with 12 additions and 6 deletions
|
|
@ -16,10 +16,10 @@
|
|||
@extend .body
|
||||
font-family: fonts.$Montserrat
|
||||
|
||||
.opensans
|
||||
.open-sans
|
||||
@extend .body
|
||||
font-family: fonts.$OpenSans
|
||||
|
||||
.publicsans
|
||||
.public-sans
|
||||
@extend .body
|
||||
font-family: fonts.$PublicSans
|
||||
|
|
|
|||
|
|
@ -1,12 +1,12 @@
|
|||
import './HTML.sass'
|
||||
import type { JSXElement } from 'solid-js'
|
||||
import { type JSXElement, Show } from 'solid-js'
|
||||
|
||||
interface Props {
|
||||
title: string
|
||||
name: string
|
||||
description: string
|
||||
children: JSXElement
|
||||
font?: string
|
||||
font?: 'roboto' | 'inter' | 'montserrat' | 'open-sans' | 'public-sans'
|
||||
}
|
||||
|
||||
export default (props: Props) => {
|
||||
|
|
@ -14,16 +14,22 @@ export default (props: Props) => {
|
|||
<>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8" />
|
||||
<link rel="icon" type="image/svg+xml" href="/favicon.png" />
|
||||
<base href="/" />
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no, viewport-fit=cover" />
|
||||
<meta name="name" content={props.name} />
|
||||
<meta name="description" content={props.description} />
|
||||
<meta property="og:title" content={props.name} />
|
||||
<meta property="og:description" content={props.description} />
|
||||
<meta property="og:type" content="website" />
|
||||
<link rel="icon" type="image/svg+xml" href="/favicon.png" />
|
||||
<link rel="preload" href={`https://cdn.jsdelivr.net/fontsource/fonts/${props.font}:vf@latest/latin-wght-normal.woff2`} crossorigin="anonymous" as="font" type="font/woff2" />
|
||||
<title>{props.title}</title>
|
||||
</head>
|
||||
|
||||
<body class={props.font}>{props.children}</body>
|
||||
</html>
|
||||
s
|
||||
</>
|
||||
)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue