/
lyudmleb
/
useref
Обзор
Документация
Войти
/
lyudmleb
/
useref
Код
Запросы
1
Задачи
Вики
Пакеты
0
Релизы
0
CI/CD
Аналитика
Безопасность
develop
src/widgets/header/ui/Header.tsx
54 строки
1 KB
Liudmila Lebedeva
finished
22 ноя 2025, 14:53
22 ноя 2025, 14:53
ff9bb37
Код
Авторство
О чём код?
import React from "react"; import { Link as RouterLink } from "react-router-dom"; import { AppBar, Link as MuiLink, Toolbar, Typography } from "@mui/material"; const linkProps = { sx: { color: "inherit", underline: "hover", fontWeight: "medium", "&.active": { fontWeight: "bold", textDecoration: "underline", }, }, }; const Header: React.FC = () => { return ( <AppBar position="static" color="primary"> <Toolbar sx={{ display: "flex", justifyContent: "space-between" }}> <Typography variant="h6" component="div"> <MuiLink component={RouterLink} to="/" color="inherit" underline="none" sx={{ fontWeight: "bold" }} > Home </MuiLink> </Typography> <div style={{ display: "flex", gap: "16px", }} > <MuiLink component={RouterLink} to="/click-timer" {...linkProps}> Click Timer </MuiLink> <MuiLink component={RouterLink} to="/previous-input" {...linkProps}> Previous input </MuiLink> <MuiLink component={RouterLink} to="/focus-tracker" {...linkProps}> Focus Tracker </MuiLink> </div> </Toolbar> </AppBar> ); }; export default Header;