Vibe-code дизайн fix
This commit is contained in:
parent
c750e19443
commit
57779cacbd
@ -2,6 +2,9 @@
|
|||||||
<html>
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8" />
|
<meta charset="utf-8" />
|
||||||
|
<meta http-equiv="Cache-Control" content="no-cache, no-store, must-revalidate" />
|
||||||
|
<meta http-equiv="Pragma" content="no-cache" />
|
||||||
|
<meta http-equiv="Expires" content="0" />
|
||||||
<title>Webpack App</title>
|
<title>Webpack App</title>
|
||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
|
|||||||
@ -2,6 +2,7 @@
|
|||||||
<html lang="en">
|
<html lang="en">
|
||||||
<head>
|
<head>
|
||||||
<meta charset="utf-8" />
|
<meta charset="utf-8" />
|
||||||
|
<meta http-equiv="Cache-Control" content="no-cache, must-revalidate" />
|
||||||
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
|
<link rel="icon" href="%PUBLIC_URL%/favicon.ico" />
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
||||||
<meta name="theme-color" content="#000000" />
|
<meta name="theme-color" content="#000000" />
|
||||||
@ -30,7 +31,31 @@
|
|||||||
<body>
|
<body>
|
||||||
<!-- Yandex.Metrika counter --> <script type="text/javascript" > (function(m,e,t,r,i,k,a){m[i]=m[i]||function(){(m[i].a=m[i].a||[]).push(arguments)}; m[i].l=1*new Date(); for (var j = 0; j < document.scripts.length; j++) {if (document.scripts[j].src === r) { return; }} k=e.createElement(t),a=e.getElementsByTagName(t)[0],k.async=1,k.src=r,a.parentNode.insertBefore(k,a)}) (window, document, "script", "https://mc.yandex.ru/metrika/tag.js", "ym"); ym(99502794, "init", { clickmap:true, trackLinks:true, accurateTrackBounce:true, webvisor:true }); </script> <noscript><div><img src="https://mc.yandex.ru/watch/99502794" style="position:absolute; left:-9999px;" alt="" /></div></noscript> <!-- /Yandex.Metrika counter -->
|
<!-- Yandex.Metrika counter --> <script type="text/javascript" > (function(m,e,t,r,i,k,a){m[i]=m[i]||function(){(m[i].a=m[i].a||[]).push(arguments)}; m[i].l=1*new Date(); for (var j = 0; j < document.scripts.length; j++) {if (document.scripts[j].src === r) { return; }} k=e.createElement(t),a=e.getElementsByTagName(t)[0],k.async=1,k.src=r,a.parentNode.insertBefore(k,a)}) (window, document, "script", "https://mc.yandex.ru/metrika/tag.js", "ym"); ym(99502794, "init", { clickmap:true, trackLinks:true, accurateTrackBounce:true, webvisor:true }); </script> <noscript><div><img src="https://mc.yandex.ru/watch/99502794" style="position:absolute; left:-9999px;" alt="" /></div></noscript> <!-- /Yandex.Metrika counter -->
|
||||||
<noscript>You need to enable JavaScript to run this app.</noscript>
|
<noscript>You need to enable JavaScript to run this app.</noscript>
|
||||||
<script type="text/babel" src="./index_bundle.js"></script>
|
<script>
|
||||||
|
(function () {
|
||||||
|
var VERSION = 'v1.0.1';
|
||||||
|
var stored = localStorage.getItem('app_version');
|
||||||
|
if (stored !== VERSION) {
|
||||||
|
localStorage.setItem('app_version', VERSION);
|
||||||
|
if ('caches' in window) {
|
||||||
|
caches.keys().then(function (names) {
|
||||||
|
names.forEach(function (name) { caches.delete(name); });
|
||||||
|
});
|
||||||
|
}
|
||||||
|
if ('serviceWorker' in navigator) {
|
||||||
|
navigator.serviceWorker.getRegistrations().then(function (regs) {
|
||||||
|
regs.forEach(function (r) { r.unregister(); });
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// bfcache: если страница восстановлена из back-forward cache — перезагружаем
|
||||||
|
window.addEventListener('pageshow', function (event) {
|
||||||
|
if (event.persisted) {
|
||||||
|
window.location.reload();
|
||||||
|
}
|
||||||
|
});
|
||||||
|
})();
|
||||||
|
</script>
|
||||||
<div id="root"></div>
|
<div id="root"></div>
|
||||||
<!--
|
<!--
|
||||||
This HTML file is a template.
|
This HTML file is a template.
|
||||||
|
|||||||
@ -74,7 +74,7 @@ function AppBarContent() {
|
|||||||
<Box sx={{ display: 'flex', alignItems: 'center', gap: 2 }}>
|
<Box sx={{ display: 'flex', alignItems: 'center', gap: 2 }}>
|
||||||
<img src="/images/dowdelogo.png" alt="logo" style={{ height: 32, cursor: 'pointer' }} onClick={handleLogoClick}/>
|
<img src="/images/dowdelogo.png" alt="logo" style={{ height: 32, cursor: 'pointer' }} onClick={handleLogoClick}/>
|
||||||
<LogoText variant="h6" sx={{ textDecoration: 'none', cursor: 'pointer' }} onClick={handleLogoClick}>
|
<LogoText variant="h6" sx={{ textDecoration: 'none', cursor: 'pointer' }} onClick={handleLogoClick}>
|
||||||
Autogenerated wiki
|
Wiki
|
||||||
</LogoText>
|
</LogoText>
|
||||||
</Box>
|
</Box>
|
||||||
<ThemeToggle onClick={toggleTheme} size="large">
|
<ThemeToggle onClick={toggleTheme} size="large">
|
||||||
@ -90,7 +90,7 @@ function AppBarContent() {
|
|||||||
<Box sx={{ display: 'flex', alignItems: 'center', gap: 2 }}>
|
<Box sx={{ display: 'flex', alignItems: 'center', gap: 2 }}>
|
||||||
<img src="/images/dowdelogo.png" alt="logo" style={{ height: 32, cursor: 'pointer' }} onClick={handleLogoClick}/>
|
<img src="/images/dowdelogo.png" alt="logo" style={{ height: 32, cursor: 'pointer' }} onClick={handleLogoClick}/>
|
||||||
<LogoText variant="h6" sx={{ textDecoration: 'none', cursor: 'pointer' }} onClick={handleLogoClick}>
|
<LogoText variant="h6" sx={{ textDecoration: 'none', cursor: 'pointer' }} onClick={handleLogoClick}>
|
||||||
Autogenerated wiki
|
Wiki
|
||||||
</LogoText>
|
</LogoText>
|
||||||
</Box>
|
</Box>
|
||||||
<ThemeToggleLight onClick={toggleTheme} size="large">
|
<ThemeToggleLight onClick={toggleTheme} size="large">
|
||||||
|
|||||||
@ -3,7 +3,6 @@ import {styled} from '@mui/material/styles';
|
|||||||
export const DescriptionBox = styled('div')(({ theme }) => ({
|
export const DescriptionBox = styled('div')(({ theme }) => ({
|
||||||
color: theme.palette.text.primary,
|
color: theme.palette.text.primary,
|
||||||
lineHeight: 1.7,
|
lineHeight: 1.7,
|
||||||
fontSize: '0.95rem',
|
|
||||||
padding: theme.spacing(3),
|
padding: theme.spacing(3),
|
||||||
background: theme.palette.mode === 'dark' ? 'rgba(255, 255, 255, 0.03)' : 'rgba(0, 0, 0, 0.03)',
|
background: theme.palette.mode === 'dark' ? 'rgba(255, 255, 255, 0.03)' : 'rgba(0, 0, 0, 0.03)',
|
||||||
borderRadius: '12px',
|
borderRadius: '12px',
|
||||||
|
|||||||
@ -93,7 +93,7 @@ const UnitListItem = styled(ListItem)(({ theme }) => ({
|
|||||||
borderRadius: '8px',
|
borderRadius: '8px',
|
||||||
border: `1px solid ${theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.05)' : 'rgba(0,0,0,0.05)'}`,
|
border: `1px solid ${theme.palette.mode === 'dark' ? 'rgba(255,255,255,0.05)' : 'rgba(0,0,0,0.05)'}`,
|
||||||
transition: 'all 0.2s ease',
|
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 {
|
interface UintPageState {
|
||||||
|
|||||||
@ -15,7 +15,7 @@ import {
|
|||||||
Divider,
|
Divider,
|
||||||
useTheme,
|
useTheme,
|
||||||
Paper,
|
Paper,
|
||||||
LinearProgress
|
LinearProgress,
|
||||||
} from "@mui/material";
|
} from "@mui/material";
|
||||||
import { styled } from '@mui/material/styles';
|
import { styled } from '@mui/material/styles';
|
||||||
|
|
||||||
@ -280,8 +280,6 @@ function Mods({ mods }: ModsProps) {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<Box>
|
<Box>
|
||||||
|
|
||||||
|
|
||||||
<Grid container spacing={3}>
|
<Grid container spacing={3}>
|
||||||
{[...new Set(sortedMods.map(m => m.name))].map((modName, index) => (
|
{[...new Set(sortedMods.map(m => m.name))].map((modName, index) => (
|
||||||
<Grid item xs={12} sm={6} md={4} >
|
<Grid item xs={12} sm={6} md={4} >
|
||||||
@ -310,6 +308,23 @@ class ModsPage extends React.Component<any, ModsPageState> {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async componentDidMount() {
|
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 {
|
try {
|
||||||
const response = await fetch(AvailableMods);
|
const response = await fetch(AvailableMods);
|
||||||
const data: IMod[] = await response.json();
|
const data: IMod[] = await response.json();
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user