From b414c0e8ab65b0104dca58526687d046bb07b6df Mon Sep 17 00:00:00 2001 From: Tatyana Date: Wed, 30 Jul 2025 16:37:34 +0300 Subject: [PATCH] =?UTF-8?q?mainContent=20=D0=BC=D0=B5=D0=BD=D1=8F=D0=B5?= =?UTF-8?q?=D1=82=D1=81=D1=8F,=20=D1=85=D0=B5=D0=B4=D0=B5=D1=80=20=D1=84?= =?UTF-8?q?=D1=83=D1=82=D0=B5=D1=80=20-=20=D0=BD=D0=B0=20=D0=B2=D1=81?= =?UTF-8?q?=D0=B5=D1=85=20=D0=BE=D1=81=D1=82=D0=B0=D0=B5=D1=82=D1=81=D1=8F?= =?UTF-8?q?=20+=20=D1=81=D1=81=D1=8B=D0=BB=D0=BA=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/App.tsx | 30 +++++++++++++++++++++--------- src/AppRoutes.tsx | 16 ++++++++++++++++ src/components/Header.tsx | 8 ++++++-- src/pages/Home.tsx | 10 +--------- src/pages/Register.tsx | 18 ++++++++++-------- 5 files changed, 54 insertions(+), 28 deletions(-) diff --git a/src/App.tsx b/src/App.tsx index adf8934..7a4474b 100644 --- a/src/App.tsx +++ b/src/App.tsx @@ -1,24 +1,36 @@ import React from 'react'; import { IonApp, IonRouterOutlet } from '@ionic/react'; import { IonReactRouter } from '@ionic/react-router'; -import { Switch, Route, Redirect } from 'react-router-dom'; - -import Home from './pages/Home'; +import AppRoutes from './AppRoutes'; import './index.css' import '@ionic/react/css/core.css'; +import Header from './components/Header'; +import Footer from './components/Footer'; const App: React.FC = () => ( - - - - - - + + {/* Постоянный Header */} +
+ + {/* Основной контейнер для контента */} +
+ + +
+ + + +
+ + {/* Постоянный Footer */} +
+ +
); diff --git a/src/AppRoutes.tsx b/src/AppRoutes.tsx index e69de29..b84559e 100644 --- a/src/AppRoutes.tsx +++ b/src/AppRoutes.tsx @@ -0,0 +1,16 @@ +import React from 'react'; +import { Route } from 'react-router-dom'; + +import Home from './pages/Home'; +import Login from './pages/Login'; +import Register from './pages/Register'; + +const AppRoutes = () => ( + <> + + + + +); + +export default AppRoutes; \ No newline at end of file diff --git a/src/components/Header.tsx b/src/components/Header.tsx index a551eea..be63652 100644 --- a/src/components/Header.tsx +++ b/src/components/Header.tsx @@ -1,9 +1,13 @@ - +import React from 'react'; +import { IonRouterLink } from '@ionic/react'; function Header() { return ( -
+ ); } diff --git a/src/pages/Home.tsx b/src/pages/Home.tsx index 77deee1..b22097e 100644 --- a/src/pages/Home.tsx +++ b/src/pages/Home.tsx @@ -1,16 +1,8 @@ -import Header from '../components/Header'; -import Footer from '../components/Footer'; -import MainContent from '../components/MainContent'; - function Home() { return ( <> -
-
- -
-
+

Домашняя страница

); } diff --git a/src/pages/Register.tsx b/src/pages/Register.tsx index a6fd72d..c95c62a 100644 --- a/src/pages/Register.tsx +++ b/src/pages/Register.tsx @@ -1,11 +1,13 @@ -function Login() { - return ( -
-

Зарегистрироваться

- -
- ); + +function Auth() { + return ( +
+ +

Страница регистрации

+ +
+ ); } -export default Login; \ No newline at end of file +export default Auth; \ No newline at end of file