Vibe-code дизайн fix

This commit is contained in:
anibus
2026-07-23 11:15:57 +03:00
parent c750e19443
commit 57779cacbd
6 changed files with 50 additions and 8 deletions
+2 -2
View File
@@ -74,7 +74,7 @@ function AppBarContent() {
<Box sx={{ display: 'flex', alignItems: 'center', gap: 2 }}>
<img src="/images/dowdelogo.png" alt="logo" style={{ height: 32, cursor: 'pointer' }} onClick={handleLogoClick}/>
<LogoText variant="h6" sx={{ textDecoration: 'none', cursor: 'pointer' }} onClick={handleLogoClick}>
Autogenerated wiki
Wiki
</LogoText>
</Box>
<ThemeToggle onClick={toggleTheme} size="large">
@@ -90,7 +90,7 @@ function AppBarContent() {
<Box sx={{ display: 'flex', alignItems: 'center', gap: 2 }}>
<img src="/images/dowdelogo.png" alt="logo" style={{ height: 32, cursor: 'pointer' }} onClick={handleLogoClick}/>
<LogoText variant="h6" sx={{ textDecoration: 'none', cursor: 'pointer' }} onClick={handleLogoClick}>
Autogenerated wiki
Wiki
</LogoText>
</Box>
<ThemeToggleLight onClick={toggleTheme} size="large">
-1
View File
@@ -3,7 +3,6 @@ import {styled} from '@mui/material/styles';
export const DescriptionBox = styled('div')(({ theme }) => ({
color: theme.palette.text.primary,
lineHeight: 1.7,
fontSize: '0.95rem',
padding: theme.spacing(3),
background: theme.palette.mode === 'dark' ? 'rgba(255, 255, 255, 0.03)' : 'rgba(0, 0, 0, 0.03)',
borderRadius: '12px',
+1 -1
View File
@@ -93,7 +93,7 @@ const UnitListItem = styled(ListItem)(({ theme }) => ({
borderRadius: '8px',
border: `1px solid ${theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.05)' : 'rgba(0,0,0,0.05)'}`,
transition: 'all 0.2s ease',
'&:hover': { background: theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.1)' : 'rgba(233, 69, 96, 0.1)', borderColor: theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.3)' : 'rgba(233, 69, 96, 0.3)' },
'&:hover': { background: theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.1)' : 'rgba(0,0,0,0.08)', borderColor: theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.3)' : 'rgba(0,0,0,0.2)' },
}));
interface UintPageState {
+18 -3
View File
@@ -15,7 +15,7 @@ import {
Divider,
useTheme,
Paper,
LinearProgress
LinearProgress,
} from "@mui/material";
import { styled } from '@mui/material/styles';
@@ -280,8 +280,6 @@ function Mods({ mods }: ModsProps) {
return (
<Box>
<Grid container spacing={3}>
{[...new Set(sortedMods.map(m => m.name))].map((modName, index) => (
<Grid item xs={12} sm={6} md={4} >
@@ -310,6 +308,23 @@ class ModsPage extends React.Component<any, ModsPageState> {
}
async componentDidMount() {
// Очистка кэша сайта при заходе на главную страницу (один раз за сессию)
if (!sessionStorage.getItem('cache_cleared')) {
sessionStorage.setItem('cache_cleared', '1');
try {
if ('caches' in window) {
const names = await caches.keys();
await Promise.all(names.map(name => caches.delete(name)));
}
if ('serviceWorker' in navigator) {
const regs = await navigator.serviceWorker.getRegistrations();
await Promise.all(regs.map(r => r.unregister()));
}
} catch (e) {
console.error('Cache clear failed:', e);
}
}
try {
const response = await fetch(AvailableMods);
const data: IMod[] = await response.json();