minor fix front
This commit is contained in:
@ -18,7 +18,6 @@ body {
|
|||||||
height: 100vh;
|
height: 100vh;
|
||||||
background: linear-gradient(242.94deg, #000000 39.07%, #3b4187 184.73%);
|
background: linear-gradient(242.94deg, #000000 39.07%, #3b4187 184.73%);
|
||||||
font-family: 'Benzin-Bold' !important;
|
font-family: 'Benzin-Bold' !important;
|
||||||
overflow-y: hidden;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
|||||||
@ -20,6 +20,8 @@ import Marketplace from './pages/Marketplace';
|
|||||||
import { Registration } from './pages/Registration';
|
import { Registration } from './pages/Registration';
|
||||||
import { FullScreenLoader } from './components/FullScreenLoader';
|
import { FullScreenLoader } from './components/FullScreenLoader';
|
||||||
import { News } from './pages/News';
|
import { News } from './pages/News';
|
||||||
|
import PageHeader from './components/PageHeader';
|
||||||
|
import { useLocation } from 'react-router-dom';
|
||||||
|
|
||||||
const AuthCheck = ({ children }: { children: ReactNode }) => {
|
const AuthCheck = ({ children }: { children: ReactNode }) => {
|
||||||
const [isAuthenticated, setIsAuthenticated] = useState<boolean | null>(null);
|
const [isAuthenticated, setIsAuthenticated] = useState<boolean | null>(null);
|
||||||
@ -95,11 +97,21 @@ const AuthCheck = ({ children }: { children: ReactNode }) => {
|
|||||||
};
|
};
|
||||||
|
|
||||||
const App = () => {
|
const App = () => {
|
||||||
|
return (
|
||||||
|
<Router>
|
||||||
|
<AppLayout />
|
||||||
|
</Router>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
const AppLayout = () => {
|
||||||
// Просто используйте window.open без useNavigate
|
// Просто используйте window.open без useNavigate
|
||||||
const handleRegister = () => {
|
const handleRegister = () => {
|
||||||
window.open('https://account.ely.by/register', '_blank');
|
window.open('https://account.ely.by/register', '_blank');
|
||||||
};
|
};
|
||||||
const [username, setUsername] = useState<string | null>(null);
|
const [username, setUsername] = useState<string | null>(null);
|
||||||
|
const location = useLocation();
|
||||||
|
const path = location.pathname;
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const savedConfig = localStorage.getItem('launcher_config');
|
const savedConfig = localStorage.getItem('launcher_config');
|
||||||
@ -112,23 +124,26 @@ const App = () => {
|
|||||||
}, []);
|
}, []);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Router>
|
<Box
|
||||||
<Box
|
sx={{
|
||||||
sx={{
|
height: '100vh',
|
||||||
height: '100vh',
|
width: '100vw',
|
||||||
width: '100vw',
|
position: 'relative',
|
||||||
position: 'relative',
|
display: 'flex',
|
||||||
display: 'flex',
|
flexDirection: 'column',
|
||||||
flexDirection: 'column',
|
alignItems: 'center',
|
||||||
alignItems: 'center',
|
justifyContent: location.pathname === '/profile'
|
||||||
justifyContent: 'center',
|
? 'center'
|
||||||
overflowX: 'hidden',
|
: 'flex-start',
|
||||||
}}
|
overflowX: 'hidden',
|
||||||
>
|
}}
|
||||||
|
>
|
||||||
<MinecraftBackground />
|
<MinecraftBackground />
|
||||||
<TopBar onRegister={handleRegister} username={username || ''} />
|
<TopBar onRegister={handleRegister} username={username || ''} />
|
||||||
|
<PageHeader />
|
||||||
<Notifier />
|
<Notifier />
|
||||||
<Routes>
|
|
||||||
|
<Routes>
|
||||||
<Route
|
<Route
|
||||||
path="/login"
|
path="/login"
|
||||||
element={<Login onLoginSuccess={setUsername} />}
|
element={<Login onLoginSuccess={setUsername} />}
|
||||||
@ -182,9 +197,8 @@ const App = () => {
|
|||||||
</AuthCheck>
|
</AuthCheck>
|
||||||
}
|
}
|
||||||
/>
|
/>
|
||||||
</Routes>
|
</Routes>
|
||||||
</Box>
|
</Box>
|
||||||
</Router>
|
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@ -81,7 +81,7 @@ export const BonusShopItem: React.FC<BonusShopItemProps> = ({
|
|||||||
sx={{
|
sx={{
|
||||||
position: 'relative',
|
position: 'relative',
|
||||||
width: '100%',
|
width: '100%',
|
||||||
maxWidth: 300,
|
maxWidth: 220,
|
||||||
height: 440,
|
height: 440,
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
flexDirection: 'column',
|
flexDirection: 'column',
|
||||||
@ -95,8 +95,8 @@ export const BonusShopItem: React.FC<BonusShopItemProps> = ({
|
|||||||
transition: 'transform 0.35s ease, box-shadow 0.35s ease',
|
transition: 'transform 0.35s ease, box-shadow 0.35s ease',
|
||||||
|
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
transform: 'scale(1.05)',
|
transform: 'scale(1.01)',
|
||||||
boxShadow: '0 20px 60px rgba(242,113,33,0.45)',
|
boxShadow: '0 10px 20px rgba(242,113,33,0.1)',
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@ -151,7 +151,7 @@ export const BonusShopItem: React.FC<BonusShopItemProps> = ({
|
|||||||
<Typography
|
<Typography
|
||||||
sx={{
|
sx={{
|
||||||
fontFamily: 'Benzin-Bold',
|
fontFamily: 'Benzin-Bold',
|
||||||
fontSize: '1.05rem',
|
fontSize: '1rem',
|
||||||
mb: 0.5,
|
mb: 0.5,
|
||||||
backgroundImage:
|
backgroundImage:
|
||||||
'linear-gradient(136deg, rgb(242,113,33), rgb(233,64,87), rgb(138,35,135))',
|
'linear-gradient(136deg, rgb(242,113,33), rgb(233,64,87), rgb(138,35,135))',
|
||||||
@ -165,7 +165,7 @@ export const BonusShopItem: React.FC<BonusShopItemProps> = ({
|
|||||||
<Typography
|
<Typography
|
||||||
sx={{
|
sx={{
|
||||||
color: 'rgba(255,255,255,0.7)',
|
color: 'rgba(255,255,255,0.7)',
|
||||||
fontSize: '0.8rem',
|
fontSize: '0.7rem',
|
||||||
mb: 0.8,
|
mb: 0.8,
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@ -177,11 +177,9 @@ export const BonusShopItem: React.FC<BonusShopItemProps> = ({
|
|||||||
<Typography
|
<Typography
|
||||||
sx={{
|
sx={{
|
||||||
color: 'rgba(255,255,255,0.75)',
|
color: 'rgba(255,255,255,0.75)',
|
||||||
fontSize: '0.85rem',
|
fontSize: '0.7rem',
|
||||||
mb: 1.2,
|
mb: 1.2,
|
||||||
minHeight: 40,
|
minHeight: 40,
|
||||||
maxHeight: 40,
|
|
||||||
overflow: 'hidden',
|
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{description}
|
{description}
|
||||||
@ -294,7 +292,7 @@ export const BonusShopItem: React.FC<BonusShopItemProps> = ({
|
|||||||
color: '#fff',
|
color: '#fff',
|
||||||
opacity: buttonDisabled ? 0.6 : 1,
|
opacity: buttonDisabled ? 0.6 : 1,
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
transform: buttonDisabled ? 'none' : 'scale(1.1)',
|
transform: buttonDisabled ? 'none' : 'scale(1.05)',
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
|||||||
@ -408,7 +408,7 @@ export default function CaseRoulette({
|
|||||||
opacity: animationFinished ? 1 : 0.4,
|
opacity: animationFinished ? 1 : 0.4,
|
||||||
pointerEvents: animationFinished ? 'auto' : 'none',
|
pointerEvents: animationFinished ? 'auto' : 'none',
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
transform: 'scale(1.1)',
|
transform: 'scale(1.02)',
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
|||||||
114
src/renderer/components/PageHeader.tsx
Normal file
114
src/renderer/components/PageHeader.tsx
Normal file
@ -0,0 +1,114 @@
|
|||||||
|
import { Box, Typography } from '@mui/material';
|
||||||
|
import { useLocation } from 'react-router-dom';
|
||||||
|
import { useMemo } from 'react';
|
||||||
|
|
||||||
|
interface HeaderConfig {
|
||||||
|
title: string;
|
||||||
|
subtitle: string;
|
||||||
|
hidden?: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default function PageHeader() {
|
||||||
|
const location = useLocation();
|
||||||
|
|
||||||
|
const headerConfig: HeaderConfig | null = useMemo(() => {
|
||||||
|
const path = location.pathname;
|
||||||
|
|
||||||
|
// Страницы без заголовка
|
||||||
|
if (
|
||||||
|
path === '/login' ||
|
||||||
|
path === '/registration' ||
|
||||||
|
path === '/marketplace' ||
|
||||||
|
path === '/profile' ||
|
||||||
|
path.startsWith('/launch')
|
||||||
|
) {
|
||||||
|
return { title: '', subtitle: '', hidden: true };
|
||||||
|
}
|
||||||
|
|
||||||
|
if (path === '/news') {
|
||||||
|
return {
|
||||||
|
title: 'Новости',
|
||||||
|
subtitle: 'Последние обновления лаунчера, сервера и ивентов',
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
if (path === '/') {
|
||||||
|
return {
|
||||||
|
title: 'Выбор версию клиента',
|
||||||
|
subtitle: 'Выберите установленную версию или добавьте новую сборку',
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
if (path.startsWith('/profile')) {
|
||||||
|
return {
|
||||||
|
title: 'Профиль пользователя',
|
||||||
|
subtitle: 'Профиль пользователя для личных настроек',
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
if (path.startsWith('/shop')) {
|
||||||
|
return {
|
||||||
|
title: 'Внутриигровой магазин',
|
||||||
|
subtitle: 'Тратьте свою уникалькую, виртуальную валюту - Попы!',
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
if (path.startsWith('/marketplace')) {
|
||||||
|
return {
|
||||||
|
title: 'Маркетплейс',
|
||||||
|
subtitle: 'Покупайте или продавайте - торговая площадка между игроками',
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
// Дефолт на всякий случай
|
||||||
|
return {
|
||||||
|
title: 'test',
|
||||||
|
subtitle: 'test',
|
||||||
|
};
|
||||||
|
}, [location.pathname]);
|
||||||
|
|
||||||
|
if (!headerConfig || headerConfig.hidden) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return (
|
||||||
|
<Box
|
||||||
|
sx={{
|
||||||
|
width: '100%',
|
||||||
|
maxWidth: '85%',
|
||||||
|
mt: '10vh',
|
||||||
|
mb: '2vh',
|
||||||
|
display: 'flex',
|
||||||
|
flexDirection: 'column',
|
||||||
|
alignItems: 'flex-start',
|
||||||
|
pointerEvents: 'none',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
<Typography
|
||||||
|
variant="h3"
|
||||||
|
sx={{
|
||||||
|
fontFamily: 'Benzin-Bold',
|
||||||
|
fontSize: '3vw',
|
||||||
|
backgroundImage:
|
||||||
|
'linear-gradient(71deg, #F27121 0%, #E940CD 60%, #8A2387 100%)',
|
||||||
|
WebkitBackgroundClip: 'text',
|
||||||
|
WebkitTextFillColor: 'transparent',
|
||||||
|
textTransform: 'uppercase',
|
||||||
|
letterSpacing: '0.08em',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{headerConfig.title}
|
||||||
|
</Typography>
|
||||||
|
|
||||||
|
<Typography
|
||||||
|
variant="body2"
|
||||||
|
sx={{
|
||||||
|
mt: 0.5,
|
||||||
|
color: 'rgba(255,255,255,1)',
|
||||||
|
}}
|
||||||
|
>
|
||||||
|
{headerConfig.subtitle}
|
||||||
|
</Typography>
|
||||||
|
</Box>
|
||||||
|
);
|
||||||
|
}
|
||||||
@ -24,7 +24,13 @@ const CapePreviewModal: React.FC<CapePreviewModalProps> = ({
|
|||||||
skinUrl,
|
skinUrl,
|
||||||
}) => {
|
}) => {
|
||||||
return (
|
return (
|
||||||
<Dialog open={open} onClose={onClose} maxWidth="sm" fullWidth>
|
<Dialog open={open} onClose={onClose} maxWidth="sm" fullWidth
|
||||||
|
sx={{
|
||||||
|
'& .MuiPaper-root': {
|
||||||
|
backgroundColor: 'transparent',
|
||||||
|
borderRadius: '2vw',
|
||||||
|
},
|
||||||
|
}}>
|
||||||
<DialogContent
|
<DialogContent
|
||||||
sx={{
|
sx={{
|
||||||
bgcolor: 'rgba(5, 5, 15, 0.96)',
|
bgcolor: 'rgba(5, 5, 15, 0.96)',
|
||||||
|
|||||||
@ -66,8 +66,8 @@ export default function ShopItem({
|
|||||||
transition: 'transform 0.35s ease, box-shadow 0.35s ease',
|
transition: 'transform 0.35s ease, box-shadow 0.35s ease',
|
||||||
|
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
transform: 'scale(1.05)',
|
transform: 'scale(1.01)',
|
||||||
boxShadow: '0 20px 60px rgba(242,113,33,0.45)',
|
boxShadow: '0 20px 20px rgba(242,113,33,0.1)',
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@ -124,8 +124,9 @@ export default function ShopItem({
|
|||||||
background:
|
background:
|
||||||
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
transform: 'scale(1.1)',
|
transform: 'scale(1.05)',
|
||||||
},
|
},
|
||||||
|
transition: 'all 0.5s ease'
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<VisibilityIcon fontSize="small" />
|
<VisibilityIcon fontSize="small" />
|
||||||
@ -219,7 +220,7 @@ export default function ShopItem({
|
|||||||
borderRadius: '2.5vw',
|
borderRadius: '2.5vw',
|
||||||
fontSize: '0.85rem',
|
fontSize: '0.85rem',
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
transform: 'scale(1.1)',
|
transform: 'scale(1.02)',
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
|
|||||||
@ -375,7 +375,7 @@ export default function TopBar({ onRegister, username }: TopBarProps) {
|
|||||||
'&:hover': {
|
'&:hover': {
|
||||||
background:
|
background:
|
||||||
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
||||||
transform: 'scale(1.05)',
|
transform: 'scale(1.01)',
|
||||||
boxShadow: '0 4px 15px rgba(242, 113, 33, 0.4)',
|
boxShadow: '0 4px 15px rgba(242, 113, 33, 0.4)',
|
||||||
},
|
},
|
||||||
boxShadow: '0 2px 8px rgba(0, 0, 0, 0.3)',
|
boxShadow: '0 2px 8px rgba(0, 0, 0, 0.3)',
|
||||||
@ -411,7 +411,7 @@ export default function TopBar({ onRegister, username }: TopBarProps) {
|
|||||||
'&:hover': {
|
'&:hover': {
|
||||||
background:
|
background:
|
||||||
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
||||||
transform: 'scale(1.05)',
|
transform: 'scale(1.01)',
|
||||||
boxShadow: '0 4px 15px rgba(242, 113, 33, 0.4)',
|
boxShadow: '0 4px 15px rgba(242, 113, 33, 0.4)',
|
||||||
},
|
},
|
||||||
'&:active': {
|
'&:active': {
|
||||||
|
|||||||
@ -411,8 +411,8 @@ const LaunchPage = ({
|
|||||||
value={progress}
|
value={progress}
|
||||||
valueBuffer={buffer}
|
valueBuffer={buffer}
|
||||||
sx={{
|
sx={{
|
||||||
height: 12,
|
height: '0.45vw',
|
||||||
borderRadius: 6,
|
borderRadius: '1vw',
|
||||||
|
|
||||||
// Фон прогресс-бара (buffer background)
|
// Фон прогресс-бара (buffer background)
|
||||||
backgroundColor: 'rgba(255,255,255,0.1)',
|
backgroundColor: 'rgba(255,255,255,0.1)',
|
||||||
@ -426,7 +426,7 @@ const LaunchPage = ({
|
|||||||
|
|
||||||
'& .MuiLinearProgress-bar2Buffer': {
|
'& .MuiLinearProgress-bar2Buffer': {
|
||||||
// Buffer линия (вторая линия)
|
// Buffer линия (вторая линия)
|
||||||
backgroundColor: 'rgba(255,255,255,0.25)',
|
backgroundColor: 'rgba(255,255,255,0)',
|
||||||
borderRadius: 6,
|
borderRadius: 6,
|
||||||
},
|
},
|
||||||
|
|
||||||
@ -473,7 +473,7 @@ const LaunchPage = ({
|
|||||||
background: 'linear-gradient(71deg, #555 0%, #777 100%)',
|
background: 'linear-gradient(71deg, #555 0%, #777 100%)',
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
background: 'linear-gradient(71deg, #666 0%, #888 100%)',
|
background: 'linear-gradient(71deg, #666 0%, #888 100%)',
|
||||||
transform: 'scale(1.05)',
|
transform: 'scale(1.01)',
|
||||||
boxShadow: '0 4px 15px rgba(100, 100, 100, 0.4)',
|
boxShadow: '0 4px 15px rgba(100, 100, 100, 0.4)',
|
||||||
},
|
},
|
||||||
boxShadow: '0 2px 8px rgba(0, 0, 0, 0.3)',
|
boxShadow: '0 2px 8px rgba(0, 0, 0, 0.3)',
|
||||||
@ -485,10 +485,11 @@ const LaunchPage = ({
|
|||||||
'&:hover': {
|
'&:hover': {
|
||||||
background:
|
background:
|
||||||
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
||||||
transform: 'scale(1.05)',
|
transform: 'scale(1.01)',
|
||||||
boxShadow: '0 4px 15px rgba(242, 113, 33, 0.4)',
|
boxShadow: '0 4px 15px rgba(242, 113, 33, 0.4)',
|
||||||
},
|
},
|
||||||
boxShadow: '0 2px 8px rgba(0, 0, 0, 0.3)',
|
boxShadow: '0 2px 8px rgba(0, 0, 0, 0.3)',
|
||||||
|
transition: 'all 0.25s ease',
|
||||||
}),
|
}),
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@ -506,13 +507,13 @@ const LaunchPage = ({
|
|||||||
minHeight: 'unset',
|
minHeight: 'unset',
|
||||||
minWidth: 'unset',
|
minWidth: 'unset',
|
||||||
height: '100%', // занимает полную высоту родителя
|
height: '100%', // занимает полную высоту родителя
|
||||||
transition: 'transform 0.3s ease',
|
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
background:
|
background:
|
||||||
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
'linear-gradient(71deg, #F27121 0%, #E940CD 70%, #8A2387 100%)',
|
||||||
transform: 'scale(1.05)',
|
transform: 'scale(1.05)',
|
||||||
boxShadow: '0 4px 15px rgba(242, 113, 33, 0.4)',
|
boxShadow: '0 4px 15px rgba(242, 113, 33, 0.4)',
|
||||||
},
|
},
|
||||||
|
transition: 'transform 0.25s ease, box-shadow 0.25s ease',
|
||||||
}}
|
}}
|
||||||
onClick={handleOpen}
|
onClick={handleOpen}
|
||||||
>
|
>
|
||||||
|
|||||||
@ -254,7 +254,7 @@ export default function Marketplace() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Box sx={{ padding: 3, width: '95%', height: '80%' }}>
|
<Box sx={{ padding: '0 2vw 2vw 2vw', width: '95%', height: '100%', mt: '10vh' }}>
|
||||||
<Box sx={{ display: 'flex', alignItems: 'center', gap: '1vw' }}>
|
<Box sx={{ display: 'flex', alignItems: 'center', gap: '1vw' }}>
|
||||||
<Typography variant="h4" color="white" gutterBottom>
|
<Typography variant="h4" color="white" gutterBottom>
|
||||||
Рынок сервера{' '}
|
Рынок сервера{' '}
|
||||||
|
|||||||
@ -151,48 +151,15 @@ export const News = () => {
|
|||||||
return (
|
return (
|
||||||
<Box
|
<Box
|
||||||
sx={{
|
sx={{
|
||||||
mt: '7vh',
|
|
||||||
px: '7vw',
|
px: '7vw',
|
||||||
pb: '4vh',
|
pb: '4vh',
|
||||||
maxHeight: '90vh',
|
maxHeight: '100vh',
|
||||||
overflowY: 'auto',
|
overflowY: 'auto',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
flexDirection: 'column',
|
flexDirection: 'column',
|
||||||
gap: '2vh',
|
gap: '2vh',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{/* Заголовок страницы */}
|
|
||||||
<Box
|
|
||||||
sx={{
|
|
||||||
mb: '2vh',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<Typography
|
|
||||||
variant="h3"
|
|
||||||
sx={{
|
|
||||||
fontFamily: 'Benzin-Bold',
|
|
||||||
fontSize: '3vw',
|
|
||||||
backgroundImage:
|
|
||||||
'linear-gradient(71deg, #F27121 0%, #E940CD 60%, #8A2387 100%)',
|
|
||||||
WebkitBackgroundClip: 'text',
|
|
||||||
WebkitTextFillColor: 'transparent',
|
|
||||||
textTransform: 'uppercase',
|
|
||||||
letterSpacing: '0.08em',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
Новости
|
|
||||||
</Typography>
|
|
||||||
<Typography
|
|
||||||
variant="body2"
|
|
||||||
sx={{
|
|
||||||
mt: 0.5,
|
|
||||||
color: 'rgba(255,255,255,0.6)',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
Последние обновления лаунчера, сервера и ивентов
|
|
||||||
</Typography>
|
|
||||||
</Box>
|
|
||||||
|
|
||||||
{/* Админский редактор */}
|
{/* Админский редактор */}
|
||||||
{isAdmin && (
|
{isAdmin && (
|
||||||
<Paper
|
<Paper
|
||||||
@ -229,6 +196,7 @@ export const News = () => {
|
|||||||
'& .MuiInputBase-root': {
|
'& .MuiInputBase-root': {
|
||||||
backgroundColor: 'rgba(0,0,0,0.6)',
|
backgroundColor: 'rgba(0,0,0,0.6)',
|
||||||
color: 'white',
|
color: 'white',
|
||||||
|
borderRadius: '1.2vw'
|
||||||
},
|
},
|
||||||
'& .MuiInputLabel-root': {
|
'& .MuiInputLabel-root': {
|
||||||
color: 'rgba(255,255,255,0.7)',
|
color: 'rgba(255,255,255,0.7)',
|
||||||
@ -247,6 +215,7 @@ export const News = () => {
|
|||||||
'& .MuiInputBase-root': {
|
'& .MuiInputBase-root': {
|
||||||
backgroundColor: 'rgba(0,0,0,0.6)',
|
backgroundColor: 'rgba(0,0,0,0.6)',
|
||||||
color: 'white',
|
color: 'white',
|
||||||
|
borderRadius: '1.2vw',
|
||||||
},
|
},
|
||||||
'& .MuiInputLabel-root': {
|
'& .MuiInputLabel-root': {
|
||||||
color: 'rgba(255,255,255,0.7)',
|
color: 'rgba(255,255,255,0.7)',
|
||||||
@ -259,21 +228,23 @@ export const News = () => {
|
|||||||
mb: 2,
|
mb: 2,
|
||||||
'& .EasyMDEContainer': {
|
'& .EasyMDEContainer': {
|
||||||
backgroundColor: 'rgba(0,0,0,0.6)',
|
backgroundColor: 'rgba(0,0,0,0.6)',
|
||||||
borderRadius: '0.8vw',
|
borderRadius: '1.2vw',
|
||||||
overflow: 'hidden',
|
overflow: 'hidden',
|
||||||
border: '1px solid rgba(255,255,255,0.15)',
|
border: 'none'
|
||||||
},
|
},
|
||||||
'& .editor-toolbar': {
|
'& .editor-toolbar': { // полоски(разделители) иконок
|
||||||
background: 'transparent',
|
background: 'transparent',
|
||||||
borderBottom: '1px solid rgba(255, 255, 255, 1)',
|
color: 'white',
|
||||||
|
border: 'none',
|
||||||
|
borderBottom: '1px solid #FFFFFF'
|
||||||
|
},
|
||||||
|
'& .editor-toolbar .fa': { // все иконки
|
||||||
color: 'white',
|
color: 'white',
|
||||||
},
|
},
|
||||||
'& .editor-toolbar .fa': {
|
'& .CodeMirror': { // поле ввода
|
||||||
color: 'white',
|
|
||||||
},
|
|
||||||
'& .CodeMirror': {
|
|
||||||
backgroundColor: 'transparent',
|
backgroundColor: 'transparent',
|
||||||
color: 'white',
|
color: 'white',
|
||||||
|
border: 'none'
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
@ -302,7 +273,7 @@ export const News = () => {
|
|||||||
borderRadius: '999px',
|
borderRadius: '999px',
|
||||||
textTransform: 'uppercase',
|
textTransform: 'uppercase',
|
||||||
fontFamily: 'Benzin-Bold',
|
fontFamily: 'Benzin-Bold',
|
||||||
fontSize: '0.8vw',
|
fontSize: '1vw',
|
||||||
letterSpacing: '0.08em',
|
letterSpacing: '0.08em',
|
||||||
backgroundImage:
|
backgroundImage:
|
||||||
'linear-gradient(71deg, #F27121 0%, #E940CD 60%, #8A2387 100%)',
|
'linear-gradient(71deg, #F27121 0%, #E940CD 60%, #8A2387 100%)',
|
||||||
@ -310,7 +281,9 @@ export const News = () => {
|
|||||||
'&:hover': {
|
'&:hover': {
|
||||||
boxShadow: '0 18px 40px rgba(0,0,0,1)',
|
boxShadow: '0 18px 40px rgba(0,0,0,1)',
|
||||||
filter: 'brightness(1.05)',
|
filter: 'brightness(1.05)',
|
||||||
|
transform: 'scale(1.02)',
|
||||||
},
|
},
|
||||||
|
transition: 'all 0.5s ease'
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{creating ? 'Публикация...' : 'Опубликовать'}
|
{creating ? 'Публикация...' : 'Опубликовать'}
|
||||||
@ -381,12 +354,13 @@ export const News = () => {
|
|||||||
boxShadow: '0 18px 45px rgba(0, 0, 0, 0.7)',
|
boxShadow: '0 18px 45px rgba(0, 0, 0, 0.7)',
|
||||||
backdropFilter: 'blur(14px)',
|
backdropFilter: 'blur(14px)',
|
||||||
width: '80vw',
|
width: '80vw',
|
||||||
transition:
|
// transition:
|
||||||
'transform 0.25s ease, box-shadow 0.25s.ease, border-color 0.25s ease',
|
// 'transform 0.25s ease, box-shadow 0.25s.ease, border-color 0.25s ease',
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
boxShadow: '0 24px 60px rgba(0, 0, 0, 0.9)',
|
boxShadow: '0 24px 60px rgba(0, 0, 0, 0.9)',
|
||||||
borderColor: 'rgba(242,113,33,0.5)',
|
borderColor: 'rgba(242,113,33,0.5)',
|
||||||
},
|
},
|
||||||
|
transition: 'all 0.25s ease',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{/* Шапка новости */}
|
{/* Шапка новости */}
|
||||||
@ -453,19 +427,20 @@ export const News = () => {
|
|||||||
</Box>
|
</Box>
|
||||||
|
|
||||||
<IconButton
|
<IconButton
|
||||||
|
disableRipple
|
||||||
|
disableFocusRipple
|
||||||
|
disableTouchRipple
|
||||||
onClick={() => handleToggleExpand(item.id)}
|
onClick={() => handleToggleExpand(item.id)}
|
||||||
sx={{
|
sx={{
|
||||||
ml: 1,
|
|
||||||
alignSelf: 'center',
|
|
||||||
transform: isExpanded ? 'rotate(180deg)' : 'rotate(0deg)',
|
transform: isExpanded ? 'rotate(180deg)' : 'rotate(0deg)',
|
||||||
transition: 'transform 0.25s ease, background 0.25s ease',
|
|
||||||
background:
|
background:
|
||||||
'linear-gradient(140deg, rgba(242,113,33,0.15), rgba(233,64,87,0.15))',
|
'rgba(242,113,33,0.15)',
|
||||||
borderRadius: '1.4vw',
|
borderRadius: '1.4vw',
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
background:
|
background:
|
||||||
'linear-gradient(140deg, rgba(242,113,33,0.4), rgba(233,64,87,0.4))',
|
'rgba(242,113,33,0.4)',
|
||||||
},
|
},
|
||||||
|
transition: 'all 0.25s ease',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<ExpandMoreIcon
|
<ExpandMoreIcon
|
||||||
@ -474,20 +449,22 @@ export const News = () => {
|
|||||||
</IconButton>
|
</IconButton>
|
||||||
{isAdmin && (
|
{isAdmin && (
|
||||||
<IconButton
|
<IconButton
|
||||||
|
disableRipple
|
||||||
|
disableFocusRipple
|
||||||
|
disableTouchRipple
|
||||||
onClick={() => handleDeleteNews(item.id)}
|
onClick={() => handleDeleteNews(item.id)}
|
||||||
sx={{
|
sx={{
|
||||||
mt: 0.5,
|
background: 'rgba(255, 77, 77, 0.1)',
|
||||||
backgroundColor: 'rgba(255, 77, 77, 0.1)',
|
|
||||||
borderRadius: '1.4vw',
|
borderRadius: '1.4vw',
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
backgroundColor: 'rgba(255, 77, 77, 0.3)',
|
background: 'rgba(255, 77, 77, 0.3)',
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<DeleteOutlineIcon
|
<DeleteOutlineIcon
|
||||||
sx={{
|
sx={{
|
||||||
color: 'rgba(255, 120, 120, 0.9)',
|
color: 'rgba(255, 120, 120, 0.9)',
|
||||||
fontSize: '1.2vw',
|
fontSize: '1.4vw',
|
||||||
}}
|
}}
|
||||||
/>
|
/>
|
||||||
</IconButton>
|
</IconButton>
|
||||||
|
|||||||
@ -407,6 +407,7 @@ export default function Shop() {
|
|||||||
height: '100%',
|
height: '100%',
|
||||||
justifyContent: 'center',
|
justifyContent: 'center',
|
||||||
alignItems: 'center',
|
alignItems: 'center',
|
||||||
|
overflow: 'hidden',
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{(loading || onlineCheckLoading) && (
|
{(loading || onlineCheckLoading) && (
|
||||||
@ -418,14 +419,13 @@ export default function Shop() {
|
|||||||
sx={{
|
sx={{
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
flexDirection: 'column',
|
flexDirection: 'column',
|
||||||
width: '90%',
|
width: '100%',
|
||||||
height: '80%',
|
height: '100%',
|
||||||
gap: '2vw',
|
gap: '2vw',
|
||||||
overflow: 'auto',
|
overflow: 'auto',
|
||||||
paddingTop: '3vh',
|
paddingBottom: '5vw',
|
||||||
paddingBottom: '10vh',
|
paddingLeft: '2.5vw',
|
||||||
paddingLeft: '5vw',
|
paddingRight: '1.5vw',
|
||||||
paddingRight: '5vw',
|
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{/* Блок прокачки */}
|
{/* Блок прокачки */}
|
||||||
@ -434,6 +434,7 @@ export default function Shop() {
|
|||||||
display: 'flex',
|
display: 'flex',
|
||||||
flexDirection: 'column',
|
flexDirection: 'column',
|
||||||
gap: 2,
|
gap: 2,
|
||||||
|
mt: '2vh'
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
<Typography
|
<Typography
|
||||||
@ -546,6 +547,9 @@ export default function Shop() {
|
|||||||
|
|
||||||
{!isOnline && (
|
{!isOnline && (
|
||||||
<Button
|
<Button
|
||||||
|
disableRipple
|
||||||
|
disableFocusRipple
|
||||||
|
disableTouchRipple
|
||||||
variant="outlined"
|
variant="outlined"
|
||||||
size="small"
|
size="small"
|
||||||
sx={{
|
sx={{
|
||||||
@ -558,8 +562,9 @@ export default function Shop() {
|
|||||||
fontSize: '0.8em',
|
fontSize: '0.8em',
|
||||||
color: 'white',
|
color: 'white',
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
transform: 'scale(1.1)',
|
transform: 'scale(1.02)',
|
||||||
},
|
},
|
||||||
|
border: 'none',
|
||||||
}}
|
}}
|
||||||
onClick={() => {
|
onClick={() => {
|
||||||
checkPlayerStatus(); // обновляем онлайн-статус
|
checkPlayerStatus(); // обновляем онлайн-статус
|
||||||
|
|||||||
@ -285,63 +285,14 @@ export const VersionsExplorer = () => {
|
|||||||
return (
|
return (
|
||||||
<Box
|
<Box
|
||||||
sx={{
|
sx={{
|
||||||
|
px: '7vw',
|
||||||
|
overflowY: 'auto',
|
||||||
display: 'flex',
|
display: 'flex',
|
||||||
flexDirection: 'column',
|
flexDirection: 'column',
|
||||||
alignItems: 'center',
|
gap: '2vh',
|
||||||
paddingLeft: '5vw',
|
height: '100%',
|
||||||
paddingRight: '5vw',
|
|
||||||
position: 'relative',
|
|
||||||
flexGrow: 1,
|
|
||||||
height: 'calc(100vh - 64px)',
|
|
||||||
overflow: 'hidden',
|
|
||||||
}}
|
}}
|
||||||
>
|
>
|
||||||
{/* Заголовок страницы в стиле Registration */}
|
|
||||||
<Box
|
|
||||||
sx={{
|
|
||||||
mt: '7vh',
|
|
||||||
mb: '1vh',
|
|
||||||
textAlign: 'center',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
<Typography
|
|
||||||
variant="h3"
|
|
||||||
sx={{
|
|
||||||
fontFamily: 'Benzin-Bold',
|
|
||||||
fontSize: '3vw',
|
|
||||||
backgroundImage: gradientPrimary,
|
|
||||||
WebkitBackgroundClip: 'text',
|
|
||||||
WebkitTextFillColor: 'transparent',
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
Выбор версии клиента
|
|
||||||
</Typography>
|
|
||||||
<Typography
|
|
||||||
variant="subtitle1"
|
|
||||||
sx={{
|
|
||||||
color: 'rgba(255,255,255,0.7)',
|
|
||||||
mt: 1,
|
|
||||||
}}
|
|
||||||
>
|
|
||||||
Выберите установленную версию или добавьте новую сборку
|
|
||||||
</Typography>
|
|
||||||
</Box>
|
|
||||||
|
|
||||||
{/* Глобальный фоновый слой (мягкий эффект) */}
|
|
||||||
{/* <Box
|
|
||||||
sx={{
|
|
||||||
position: 'fixed',
|
|
||||||
top: 0,
|
|
||||||
left: 0,
|
|
||||||
right: 0,
|
|
||||||
bottom: 0,
|
|
||||||
background:
|
|
||||||
'radial-gradient(circle at top, rgba(242,113,33,0.12), transparent 55%)',
|
|
||||||
pointerEvents: 'none',
|
|
||||||
zIndex: 0,
|
|
||||||
}}
|
|
||||||
/> */}
|
|
||||||
|
|
||||||
{loading ? (
|
{loading ? (
|
||||||
<FullScreenLoader message="Загрузка ваших версий..." />
|
<FullScreenLoader message="Загрузка ваших версий..." />
|
||||||
) : (
|
) : (
|
||||||
@ -525,7 +476,7 @@ export const VersionsExplorer = () => {
|
|||||||
fontSize: '1vw',
|
fontSize: '1vw',
|
||||||
textTransform: 'none',
|
textTransform: 'none',
|
||||||
'&:hover': {
|
'&:hover': {
|
||||||
transform: 'scale(1.05)',
|
transform: 'scale(1.01)',
|
||||||
boxShadow: '0 10px 30px rgba(0,0,0,0.6)',
|
boxShadow: '0 10px 30px rgba(0,0,0,0.6)',
|
||||||
},
|
},
|
||||||
}}
|
}}
|
||||||
|
|||||||
Reference in New Issue
Block a user