mirror of
https://github.com/yudejp/yude.jp.git
synced 2025-05-11 14:38:41 +00:00
Improve banner animation
This commit is contained in:
parent
65dd7bf23c
commit
3a1f024a90
@ -23,6 +23,7 @@
|
||||
"postcss": "^8.4.33",
|
||||
"react": "^18.2.0",
|
||||
"react-dom": "^18.2.0",
|
||||
"react-fast-marquee": "^1.6.4",
|
||||
"react-katex": "^3.0.1",
|
||||
"react-markdown": "^9.0.1",
|
||||
"react-scroll-percentage": "^4.3.2",
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -32,19 +32,19 @@ type Props = {
|
||||
};
|
||||
|
||||
export const ThemeSwitcher = () => {
|
||||
const {theme, toggleTheme} = useTheme();
|
||||
const { theme, toggleTheme } = useTheme();
|
||||
|
||||
return (
|
||||
<button
|
||||
type="button"
|
||||
className="btn btn-secondary"
|
||||
className="btn btn-secondary drop-shadow-md"
|
||||
onClick={toggleTheme}
|
||||
aria-label="テーマの切り替え"
|
||||
>
|
||||
>
|
||||
{theme === "light" ? (
|
||||
<FontAwesomeIcon icon={faMoon} />
|
||||
<FontAwesomeIcon icon={faMoon} />
|
||||
) : (
|
||||
<FontAwesomeIcon icon={faSun} />
|
||||
<FontAwesomeIcon icon={faSun} />
|
||||
)}
|
||||
</button>
|
||||
)
|
||||
|
@ -6,17 +6,7 @@ export default {
|
||||
"./src/**/*.{js,ts,jsx,tsx}",
|
||||
],
|
||||
theme: {
|
||||
extend: {
|
||||
animation: {
|
||||
marquee: 'marquee 30s linear infinite'
|
||||
},
|
||||
keyframes: {
|
||||
marquee: {
|
||||
'0%': { transform: 'translateX(100%)' },
|
||||
'100%': { transform: 'translateX(-160%)' }
|
||||
}
|
||||
}
|
||||
},
|
||||
extend: {},
|
||||
},
|
||||
plugins: [
|
||||
require('@tailwindcss/typography'),
|
||||
|
Loading…
x
Reference in New Issue
Block a user