update
This commit is contained in:
1 parent
f899f75780
commit
73566d3aca
10 files changed
+92
-51
No files matched your search
@@ -13,6 +13,12 @@ import { Box } from "@/ui/Box"
|
||||
import { Button } from "@/ui/Button"
|
||||
import { EyeOpenIcon } from "@radix-ui/react-icons"
|
||||
import { useTheme } from "@/ui/theme/useTheme"
|
||||
import { Copyright } from "../Copyright"
|
||||
import { Spacer } from "../Spacer"
|
||||
import { Author } from "../Author"
|
||||
import { Title } from "@/ui/Title"
|
||||
import { Panel } from "@/ui/Panel"
|
||||
import { Contacts } from "../Contacts"
|
||||
|
||||
export type AppProps = {
|
||||
showAuthor?: boolean
|
||||
@@ -54,23 +60,46 @@ export const App: React.FC<AppProps> = ({ showAuthor = false, menu, ...props })
|
||||
</header>
|
||||
)}
|
||||
footer={(
|
||||
<Footer
|
||||
showAuthor={showAuthor}
|
||||
>
|
||||
<Footer>
|
||||
<Box gap={40} align={false} style={{
|
||||
marginBottom: "var(--size-l)",
|
||||
}}>
|
||||
<Panel ghost>
|
||||
<Contacts />
|
||||
</Panel>
|
||||
|
||||
<Panel ghost>
|
||||
<Title level={3}>
|
||||
Версия для слабовидящих
|
||||
</Title>
|
||||
<Button theme="icon" size="default" onClick={() => {
|
||||
setTheme(theme === "default" ? "contrast" : "default")
|
||||
}}>
|
||||
<EyeOpenIcon width={24} height={24} />
|
||||
</Button>
|
||||
</Panel>
|
||||
</Box>
|
||||
|
||||
<div style={{
|
||||
backgroundColor: "white",
|
||||
padding: 10,
|
||||
borderRadius: 10,
|
||||
marginBottom: 30,
|
||||
}}>
|
||||
<Gosuslugi />
|
||||
{/* <Gosuslugi /> */}
|
||||
</div>
|
||||
|
||||
<Button theme="icon" size="default" onClick={() => {
|
||||
setTheme(theme === "default" ? "contrast" : "default")
|
||||
}}>
|
||||
<EyeOpenIcon width={24} height={24} />
|
||||
</Button>
|
||||
|
||||
<Box>
|
||||
<Copyright />
|
||||
|
||||
{!showAuthor ? null : (
|
||||
<>
|
||||
<Spacer as={"span"} />
|
||||
<Author />
|
||||
</>
|
||||
)}
|
||||
</Box>
|
||||
</Footer>
|
||||
)}
|
||||
>
|
||||
|
||||
File renamed without changes.
@@ -3,13 +3,14 @@ import s from "./contacts.module.css"
|
||||
import { useContext } from "react"
|
||||
import { ConfigContext } from "src/context/ConfigContext"
|
||||
import Link from "next/link"
|
||||
import { Title } from "@/ui/Title"
|
||||
|
||||
export const Contacts: React.FC = props => {
|
||||
const { contacts } = useContext(ConfigContext)
|
||||
|
||||
return (
|
||||
<>
|
||||
<strong className={s.strong}>Контактная информация</strong>
|
||||
<Title level={3}>Контактная информация</Title>
|
||||
|
||||
{contacts.map((x, i) => (
|
||||
<p key={i} className={s.link}>
|
||||
|
||||
@@ -7,4 +7,3 @@
|
||||
border-top-left-radius: var(--radius);
|
||||
border-top-right-radius: var(--radius);
|
||||
}
|
||||
|
||||
@@ -1,46 +1,12 @@
|
||||
import s from "./footer.module.css"
|
||||
|
||||
import cx from "classnames"
|
||||
import { Copyright } from "../Copyright"
|
||||
import { Author } from "./Author"
|
||||
import { Spacer } from "../Spacer"
|
||||
import { Contacts } from "../Contacts"
|
||||
import { Box } from "@/ui/Box"
|
||||
import { Panel } from "@/ui/Panel"
|
||||
|
||||
export type FooterProps = {
|
||||
showAuthor: boolean
|
||||
children?: React.ReactNode
|
||||
}
|
||||
|
||||
export const Footer: React.FC<FooterProps> = ({ showAuthor, children }) => (
|
||||
<footer className={cx(s.footer, "opposite")}>
|
||||
<Box>
|
||||
<Box vertical align={false} style={{
|
||||
marginBottom: "var(--size-l)",
|
||||
}}>
|
||||
<Contacts />
|
||||
</Box>
|
||||
|
||||
<Panel style={{
|
||||
marginBottom: "var(--size-l)",
|
||||
}}>
|
||||
<Contacts />
|
||||
</Panel>
|
||||
</Box>
|
||||
|
||||
export const Footer: React.FC<FooterProps> = ({ children }) => (
|
||||
<footer className={`${s.footer} opposite`}>
|
||||
{children}
|
||||
|
||||
<Box>
|
||||
<Copyright />
|
||||
|
||||
{!showAuthor ? null : (
|
||||
<>
|
||||
<Spacer as={"span"} />
|
||||
<Author />
|
||||
</>
|
||||
)}
|
||||
</Box>
|
||||
</footer >
|
||||
</footer>
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user