Optimize images
This commit is contained in:
parent
859967d7d3
commit
f39db5f343
|
|
@ -41,6 +41,7 @@
|
||||||
|
|
||||||
.logo {
|
.logo {
|
||||||
width: 2.5rem;
|
width: 2.5rem;
|
||||||
|
height: 2.5rem;
|
||||||
margin-right: 16px;
|
margin-right: 16px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -113,6 +114,7 @@
|
||||||
|
|
||||||
.bigLogo {
|
.bigLogo {
|
||||||
width: 80px;
|
width: 80px;
|
||||||
|
height: 80px;
|
||||||
transition: transform .15s;
|
transition: transform .15s;
|
||||||
animation: jelly .5s 1 .05s;
|
animation: jelly .5s 1 .05s;
|
||||||
user-select: none;
|
user-select: none;
|
||||||
|
|
|
||||||
|
|
@ -27,12 +27,12 @@ const Header = async ({ isFull, isSmall }: HeaderProps) => {
|
||||||
|
|
||||||
return <header className={styles.header} data-small={isSmall}>
|
return <header className={styles.header} data-small={isSmall}>
|
||||||
{isFull ? <>
|
{isFull ? <>
|
||||||
{!isSmall && <img className={styles.bigLogo} src={logo.src} alt="" />}
|
{!isSmall && <img className={styles.bigLogo} src={logo.src} height={512} width={512} alt="" />}
|
||||||
<span className={makeClass(styles.subtitle, samuraiBob.className, !/^[A-Za-z ]+$/.test(t('home:create')) && styles.hasAltChars)}>{t('home:create')}</span>
|
<span className={makeClass(styles.subtitle, samuraiBob.className, !/^[A-Za-z ]+$/.test(t('home:create')) && styles.hasAltChars)}>{t('home:create')}</span>
|
||||||
<h1 className={makeClass(styles.bigTitle, molot.className)}>CRAB FIT</h1>
|
<h1 className={makeClass(styles.bigTitle, molot.className)}>CRAB FIT</h1>
|
||||||
</> : <Link href="/" className={styles.link}>
|
</> : <Link href="/" className={styles.link}>
|
||||||
<div className={styles.top}>
|
<div className={styles.top}>
|
||||||
<img className={styles.logo} src={logo.src} alt="" />
|
<img className={styles.logo} src={logo.src} height={512} width={512} alt="" />
|
||||||
<span className={makeClass(styles.title, molot.className)}>CRAB FIT</span>
|
<span className={makeClass(styles.title, molot.className)}>CRAB FIT</span>
|
||||||
</div>
|
</div>
|
||||||
<span className={styles.tagline}>{t('common:tagline')}</span>
|
<span className={styles.tagline}>{t('common:tagline')}</span>
|
||||||
|
|
|
||||||
|
|
@ -31,6 +31,7 @@
|
||||||
|
|
||||||
img {
|
img {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
display: block;
|
display: block;
|
||||||
border-radius: inherit;
|
border-radius: inherit;
|
||||||
background-color: #CCC;
|
background-color: #CCC;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
import { useState } from 'react'
|
import { useState } from 'react'
|
||||||
|
|
||||||
import { useTranslation } from '/src/i18n/client'
|
import { useTranslation } from '/src/i18n/client'
|
||||||
import video_thumb from '/src/res/video_thumb.jpg'
|
import video_thumb from '/src/res/video_thumb.webp'
|
||||||
|
|
||||||
import styles from './Video.module.scss'
|
import styles from './Video.module.scss'
|
||||||
|
|
||||||
|
|
@ -34,7 +34,7 @@ const Video = () => {
|
||||||
setIsPlaying(true)
|
setIsPlaying(true)
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<img src={video_thumb.src} alt={t('video.button')} />
|
<img src={video_thumb.src} width={video_thumb.width} height={video_thumb.height} alt={t('video.button')} />
|
||||||
<span>{t('video.button')}</span>
|
<span>{t('video.button')}</span>
|
||||||
</a>
|
</a>
|
||||||
)
|
)
|
||||||
|
|
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 82 KiB |
BIN
frontend/src/res/video_thumb.webp
Normal file
BIN
frontend/src/res/video_thumb.webp
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 17 KiB |
Loading…
Reference in a new issue