diff --git a/package.json b/package.json index ab2e3bc4..0c2738a7 100644 --- a/package.json +++ b/package.json @@ -50,8 +50,7 @@ "react": "17.0.1", "react-dom": "17.0.1", "react-helmet": "6.1.0", - "react-i18next": "11.8.4", - "typed.js": "2.0.11" + "react-i18next": "11.8.4" }, "devDependencies": { "@babel/cli": "7.12.10", diff --git a/src/components/sections/Hello.tsx b/src/components/sections/Hello.tsx index 47905d15..e685d460 100644 --- a/src/components/sections/Hello.tsx +++ b/src/components/sections/Hello.tsx @@ -1,7 +1,6 @@ -import React, { useEffect, useRef } from 'react'; +import React from 'react'; import { graphql, useStaticQuery } from 'gatsby'; import { useI18next } from 'gatsby-plugin-react-i18next'; -import Typed, { TypedOptions } from 'typed.js'; import { Typography, Grid, Button, makeStyles } from '@material-ui/core'; import { Breakpoint } from '@material-ui/core/styles/createBreakpoints'; import { BicstoneIcon } from '../'; @@ -20,24 +19,6 @@ export const Hello: React.FC = () => { const { t, language } = useI18next(); const width = useBreakPoint(); const BUTTON_SMALL_WIDTH: Breakpoint[] = ['xs']; - const wrapEl = useRef(null); - useEffect(() => { - if (wrapEl.current) { - const options: TypedOptions = { - typeSpeed: 60, - showCursor: false, - autoInsertCss: false, - strings: [t('hello.title')], - }; - // @see https://github.com/mattboldt/typed.js/pull/461 - // eslint-disable-next-line @typescript-eslint/ban-ts-comment - // @ts-ignore: Typedの型定義が誤っており、HTMLSpanElementは割当可能 - const typed = new Typed(wrapEl.current, options); - return () => { - typed.destroy(); - }; - } - }, [wrapEl.current]); const { allContentfulHello }: HelloDataQuery = useStaticQuery( graphql` query HelloData { @@ -64,8 +45,7 @@ export const Hello: React.FC = () => { - -   + {t('hello.title')} {t('hello.description')} diff --git a/yarn.lock b/yarn.lock index 4b6e9d9e..d6fdf585 100644 --- a/yarn.lock +++ b/yarn.lock @@ -15932,11 +15932,6 @@ type@^2.0.0: resolved "https://registry.yarnpkg.com/type/-/type-2.1.0.tgz#9bdc22c648cf8cf86dd23d32336a41cfb6475e3f" integrity sha512-G9absDWvhAWCV2gmF1zKud3OyC61nZDwWvBL2DApaVFogI07CprggiQAOOjvp2NRjYWFzPyu7vwtDrQFq8jeSA== -typed.js@2.0.11: - version "2.0.11" - resolved "https://registry.yarnpkg.com/typed.js/-/typed.js-2.0.11.tgz#d298a91f959f11a3803bf48b841a6fadd29640d9" - integrity sha512-1ZORHalEyLob34q738mqmwp0pT6syMigB1SZuTItqdhovWBKFIt7I5uVALXAGQZCg2MCtihCt6uqkoqPJK+9iQ== - typedarray-to-buffer@^3.1.5: version "3.1.5" resolved "https://registry.yarnpkg.com/typedarray-to-buffer/-/typedarray-to-buffer-3.1.5.tgz#a97ee7a9ff42691b9f783ff1bc5112fe3fca9080"