Compare commits
24 Commits
Author | SHA1 | Date | |
---|---|---|---|
075f2e1011 | |||
a45b9695c9 | |||
17706d97d1 | |||
a6c48a9fe7 | |||
1e0a05314a | |||
ad972b3004 | |||
d1fa529aca | |||
31bc9c7f85 | |||
53d6a412fd | |||
0f688cd350 | |||
166c1acb42 | |||
7f7f47304a | |||
28ac5a270c | |||
3866ba5ce0 | |||
822b0df255 | |||
7f920dd722 | |||
cbcc23a80a | |||
1595decb97 | |||
e1d82cfc62 | |||
20d4dd42a7 | |||
246a556b33 | |||
b0ade359db | |||
3863d8710d | |||
fc2b6083cc |
20
.eslintrc.cjs
Normal file
20
.eslintrc.cjs
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
module.exports = {
|
||||||
|
root: true,
|
||||||
|
env: { browser: true, es2020: true },
|
||||||
|
extends: [
|
||||||
|
'eslint:recommended',
|
||||||
|
'plugin:react/recommended',
|
||||||
|
'plugin:react/jsx-runtime',
|
||||||
|
'plugin:react-hooks/recommended',
|
||||||
|
],
|
||||||
|
ignorePatterns: ['dist', '.eslintrc.cjs'],
|
||||||
|
parserOptions: { ecmaVersion: 'latest', sourceType: 'module' },
|
||||||
|
settings: { react: { version: '18.2' } },
|
||||||
|
plugins: ['react-refresh'],
|
||||||
|
rules: {
|
||||||
|
'react-refresh/only-export-components': [
|
||||||
|
'warn',
|
||||||
|
{ allowConstantExport: true },
|
||||||
|
],
|
||||||
|
},
|
||||||
|
}
|
146
.gitignore
vendored
146
.gitignore
vendored
@ -1,146 +1,24 @@
|
|||||||
# ---> Node
|
|
||||||
# Logs
|
# Logs
|
||||||
logs
|
logs
|
||||||
*.log
|
*.log
|
||||||
npm-debug.log*
|
npm-debug.log*
|
||||||
yarn-debug.log*
|
yarn-debug.log*
|
||||||
yarn-error.log*
|
yarn-error.log*
|
||||||
|
pnpm-debug.log*
|
||||||
lerna-debug.log*
|
lerna-debug.log*
|
||||||
.pnpm-debug.log*
|
|
||||||
|
|
||||||
# Diagnostic reports (https://nodejs.org/api/report.html)
|
node_modules
|
||||||
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json
|
|
||||||
|
|
||||||
# Runtime data
|
|
||||||
pids
|
|
||||||
*.pid
|
|
||||||
*.seed
|
|
||||||
*.pid.lock
|
|
||||||
|
|
||||||
# Directory for instrumented libs generated by jscoverage/JSCover
|
|
||||||
lib-cov
|
|
||||||
|
|
||||||
# Coverage directory used by tools like istanbul
|
|
||||||
coverage
|
|
||||||
*.lcov
|
|
||||||
|
|
||||||
# nyc test coverage
|
|
||||||
.nyc_output
|
|
||||||
|
|
||||||
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files)
|
|
||||||
.grunt
|
|
||||||
|
|
||||||
# Bower dependency directory (https://bower.io/)
|
|
||||||
bower_components
|
|
||||||
|
|
||||||
# node-waf configuration
|
|
||||||
.lock-wscript
|
|
||||||
|
|
||||||
# Compiled binary addons (https://nodejs.org/api/addons.html)
|
|
||||||
build/Release
|
|
||||||
|
|
||||||
# Dependency directories
|
|
||||||
node_modules/
|
|
||||||
jspm_packages/
|
|
||||||
|
|
||||||
# Snowpack dependency directory (https://snowpack.dev/)
|
|
||||||
web_modules/
|
|
||||||
|
|
||||||
# TypeScript cache
|
|
||||||
*.tsbuildinfo
|
|
||||||
|
|
||||||
# Optional npm cache directory
|
|
||||||
.npm
|
|
||||||
|
|
||||||
# Optional eslint cache
|
|
||||||
.eslintcache
|
|
||||||
|
|
||||||
# Optional stylelint cache
|
|
||||||
.stylelintcache
|
|
||||||
|
|
||||||
# Microbundle cache
|
|
||||||
.rpt2_cache/
|
|
||||||
.rts2_cache_cjs/
|
|
||||||
.rts2_cache_es/
|
|
||||||
.rts2_cache_umd/
|
|
||||||
|
|
||||||
# Optional REPL history
|
|
||||||
.node_repl_history
|
|
||||||
|
|
||||||
# Output of 'npm pack'
|
|
||||||
*.tgz
|
|
||||||
|
|
||||||
# Yarn Integrity file
|
|
||||||
.yarn-integrity
|
|
||||||
|
|
||||||
# dotenv environment variable files
|
|
||||||
.env
|
|
||||||
.env.development.local
|
|
||||||
.env.test.local
|
|
||||||
.env.production.local
|
|
||||||
.env.local
|
|
||||||
|
|
||||||
# parcel-bundler cache (https://parceljs.org/)
|
|
||||||
.cache
|
|
||||||
.parcel-cache
|
|
||||||
|
|
||||||
# Next.js build output
|
|
||||||
.next
|
|
||||||
out
|
|
||||||
|
|
||||||
# Nuxt.js build / generate output
|
|
||||||
.nuxt
|
|
||||||
dist
|
dist
|
||||||
|
dist-ssr
|
||||||
|
*.local
|
||||||
|
|
||||||
# Gatsby files
|
# Editor directories and files
|
||||||
.cache/
|
|
||||||
# Comment in the public line in if your project uses Gatsby and not Next.js
|
|
||||||
# https://nextjs.org/blog/next-9-1#public-directory-support
|
|
||||||
# public
|
|
||||||
|
|
||||||
# vuepress build output
|
|
||||||
.vuepress/dist
|
|
||||||
|
|
||||||
# vuepress v2.x temp and cache directory
|
|
||||||
.temp
|
|
||||||
.cache
|
|
||||||
|
|
||||||
# Docusaurus cache and generated files
|
|
||||||
.docusaurus
|
|
||||||
|
|
||||||
# Serverless directories
|
|
||||||
.serverless/
|
|
||||||
|
|
||||||
# FuseBox cache
|
|
||||||
.fusebox/
|
|
||||||
|
|
||||||
# DynamoDB Local files
|
|
||||||
.dynamodb/
|
|
||||||
|
|
||||||
# TernJS port file
|
|
||||||
.tern-port
|
|
||||||
|
|
||||||
# Stores VSCode versions used for testing VSCode extensions
|
|
||||||
.vscode-test
|
|
||||||
|
|
||||||
# yarn v2
|
|
||||||
.yarn/cache
|
|
||||||
.yarn/unplugged
|
|
||||||
.yarn/build-state.yml
|
|
||||||
.yarn/install-state.gz
|
|
||||||
.pnp.*
|
|
||||||
|
|
||||||
# ---> VisualStudioCode
|
|
||||||
.vscode/*
|
.vscode/*
|
||||||
!.vscode/settings.json
|
|
||||||
!.vscode/tasks.json
|
|
||||||
!.vscode/launch.json
|
|
||||||
!.vscode/extensions.json
|
!.vscode/extensions.json
|
||||||
!.vscode/*.code-snippets
|
.idea
|
||||||
|
.DS_Store
|
||||||
# Local History for Visual Studio Code
|
*.suo
|
||||||
.history/
|
*.ntvs*
|
||||||
|
*.njsproj
|
||||||
# Built Visual Studio Code Extensions
|
*.sln
|
||||||
*.vsix
|
*.sw?
|
||||||
|
|
||||||
|
@ -1,2 +1,8 @@
|
|||||||
# IP_PIbd-21_Potapov
|
# React + Vite
|
||||||
|
|
||||||
|
This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.
|
||||||
|
|
||||||
|
Currently, two official plugins are available:
|
||||||
|
|
||||||
|
- [@vitejs/plugin-react](https://github.com/vitejs/vite-plugin-react/blob/main/packages/plugin-react/README.md) uses [Babel](https://babeljs.io/) for Fast Refresh
|
||||||
|
- [@vitejs/plugin-react-swc](https://github.com/vitejs/vite-plugin-react-swc) uses [SWC](https://swc.rs/) for Fast Refresh
|
||||||
|
13
favicon.svg
Normal file
13
favicon.svg
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
<svg width="142" height="72" viewBox="0 0 142 72" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M0.955078 72V65.8477L8.91406 64.4805V8.47461L0.955078 7.10742V0.90625H26.4922V7.10742L18.5332 8.47461V33.0352H52.5176V8.47461L44.5586 7.10742V0.90625H52.5176H62.1367H70.0957V7.10742L62.1367 8.47461V64.4805L70.0957 65.8477V72H44.5586V65.8477L52.5176 64.4805V40.6035H18.5332V64.4805L26.4922 65.8477V72H0.955078ZM77.5176 72V65.8477L85.4766 64.4805V8.47461L77.5176 7.10742V0.90625H103.055V7.10742L95.0957 8.47461V32.9375H102.859L118.924 9.79297C121.561 6.14714 123.855 3.67318 125.809 2.37109C127.762 1.03646 130.024 0.369141 132.596 0.369141C134.126 0.369141 135.411 0.564453 136.453 0.955078C137.527 1.31315 138.65 1.85026 139.822 2.56641L138.406 9.35352C137.527 9.19076 136.746 9.06055 136.062 8.96289C135.411 8.83268 134.76 8.76758 134.109 8.76758C132.579 8.76758 131.277 9.17448 130.203 9.98828C129.161 10.8021 127.941 12.1855 126.541 14.1387L111.258 35.4277L134.891 64.627L141.58 65.8477V72H118.24V65.8477L123.66 65.1641L123.465 64.9199L104.275 41.043H95.0957V64.4805L103.055 65.8477V72H77.5176Z"/>
|
||||||
|
<style>
|
||||||
|
path {
|
||||||
|
fill: black;
|
||||||
|
}
|
||||||
|
@media (prefers-color-scheme: dark) {
|
||||||
|
path {
|
||||||
|
fill: white;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
</svg>
|
After Width: | Height: | Size: 1.2 KiB |
13
index.html
Normal file
13
index.html
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
<!DOCTYPE html>
|
||||||
|
<html lang="ru">
|
||||||
|
<head>
|
||||||
|
<meta charset="UTF-8" />
|
||||||
|
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||||
|
<link rel="shortcut icon" href="favicon.svg" type="image/svg+xml" />
|
||||||
|
<title>Неконтакте</title>
|
||||||
|
</head>
|
||||||
|
<body>
|
||||||
|
<div id="root" class="min-vh-100 d-flex flex-column"></div>
|
||||||
|
<script type="module" src="/src/main.jsx"></script>
|
||||||
|
</body>
|
||||||
|
</html>
|
14
jsconfig.json
Normal file
14
jsconfig.json
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
{
|
||||||
|
"compilerOptions": {
|
||||||
|
"module": "ESNext",
|
||||||
|
"moduleResolution": "Node",
|
||||||
|
"target": "ES2020",
|
||||||
|
"jsx": "react",
|
||||||
|
"strictNullChecks": true,
|
||||||
|
"strictFunctionTypes": true
|
||||||
|
},
|
||||||
|
"exclude": [
|
||||||
|
"node_modules",
|
||||||
|
"**/node_modules/*"
|
||||||
|
]
|
||||||
|
}
|
7709
package-lock.json
generated
Normal file
7709
package-lock.json
generated
Normal file
File diff suppressed because it is too large
Load Diff
41
package.json
Normal file
41
package.json
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
{
|
||||||
|
"name": "ip-pibd-21-potapov",
|
||||||
|
"private": true,
|
||||||
|
"version": "0.0.0",
|
||||||
|
"type": "module",
|
||||||
|
"scripts": {
|
||||||
|
"start": "vite",
|
||||||
|
"dev": "npm-run-all --parallel start",
|
||||||
|
"serve": "http-server -p 80 ./dist/",
|
||||||
|
"build": "vite build",
|
||||||
|
"lint": "eslint . --ext js,jsx --report-unused-disable-directives --max-warnings 0",
|
||||||
|
"preview": "vite preview",
|
||||||
|
"prod": "npm-run-all build --parallel serve"
|
||||||
|
},
|
||||||
|
"dependencies": {
|
||||||
|
"bootstrap": "^5.3.2",
|
||||||
|
"prop-types": "^15.8.1",
|
||||||
|
"react": "^18.2.0",
|
||||||
|
"react-bootstrap": "^2.9.1",
|
||||||
|
"react-bootstrap-icons": "^1.10.3",
|
||||||
|
"react-dom": "^18.2.0",
|
||||||
|
"react-router-dom": "^6.19.0"
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"@types/react": "^18.2.15",
|
||||||
|
"@types/react-dom": "^18.2.7",
|
||||||
|
"@vitejs/plugin-react": "^4.0.3",
|
||||||
|
"eslint": "^8.53.0",
|
||||||
|
"eslint-config-airbnb-base": "^15.0.0",
|
||||||
|
"eslint-plugin-import": "^2.29.0",
|
||||||
|
"eslint-plugin-react": "^7.32.2",
|
||||||
|
"eslint-plugin-react-hooks": "^4.6.0",
|
||||||
|
"eslint-plugin-react-refresh": "^0.4.3",
|
||||||
|
"http-server": "^14.1.1",
|
||||||
|
"i": "^0.3.7",
|
||||||
|
"json-server": "^0.17.4",
|
||||||
|
"npm-run-all": "^4.1.5",
|
||||||
|
"react-devtools": "^4.28.5",
|
||||||
|
"vite": "^4.4.5"
|
||||||
|
}
|
||||||
|
}
|
202
public/fonts/Roboto_Slab/LICENSE.txt
Normal file
202
public/fonts/Roboto_Slab/LICENSE.txt
Normal file
@ -0,0 +1,202 @@
|
|||||||
|
|
||||||
|
Apache License
|
||||||
|
Version 2.0, January 2004
|
||||||
|
http://www.apache.org/licenses/
|
||||||
|
|
||||||
|
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
||||||
|
|
||||||
|
1. Definitions.
|
||||||
|
|
||||||
|
"License" shall mean the terms and conditions for use, reproduction,
|
||||||
|
and distribution as defined by Sections 1 through 9 of this document.
|
||||||
|
|
||||||
|
"Licensor" shall mean the copyright owner or entity authorized by
|
||||||
|
the copyright owner that is granting the License.
|
||||||
|
|
||||||
|
"Legal Entity" shall mean the union of the acting entity and all
|
||||||
|
other entities that control, are controlled by, or are under common
|
||||||
|
control with that entity. For the purposes of this definition,
|
||||||
|
"control" means (i) the power, direct or indirect, to cause the
|
||||||
|
direction or management of such entity, whether by contract or
|
||||||
|
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
||||||
|
outstanding shares, or (iii) beneficial ownership of such entity.
|
||||||
|
|
||||||
|
"You" (or "Your") shall mean an individual or Legal Entity
|
||||||
|
exercising permissions granted by this License.
|
||||||
|
|
||||||
|
"Source" form shall mean the preferred form for making modifications,
|
||||||
|
including but not limited to software source code, documentation
|
||||||
|
source, and configuration files.
|
||||||
|
|
||||||
|
"Object" form shall mean any form resulting from mechanical
|
||||||
|
transformation or translation of a Source form, including but
|
||||||
|
not limited to compiled object code, generated documentation,
|
||||||
|
and conversions to other media types.
|
||||||
|
|
||||||
|
"Work" shall mean the work of authorship, whether in Source or
|
||||||
|
Object form, made available under the License, as indicated by a
|
||||||
|
copyright notice that is included in or attached to the work
|
||||||
|
(an example is provided in the Appendix below).
|
||||||
|
|
||||||
|
"Derivative Works" shall mean any work, whether in Source or Object
|
||||||
|
form, that is based on (or derived from) the Work and for which the
|
||||||
|
editorial revisions, annotations, elaborations, or other modifications
|
||||||
|
represent, as a whole, an original work of authorship. For the purposes
|
||||||
|
of this License, Derivative Works shall not include works that remain
|
||||||
|
separable from, or merely link (or bind by name) to the interfaces of,
|
||||||
|
the Work and Derivative Works thereof.
|
||||||
|
|
||||||
|
"Contribution" shall mean any work of authorship, including
|
||||||
|
the original version of the Work and any modifications or additions
|
||||||
|
to that Work or Derivative Works thereof, that is intentionally
|
||||||
|
submitted to Licensor for inclusion in the Work by the copyright owner
|
||||||
|
or by an individual or Legal Entity authorized to submit on behalf of
|
||||||
|
the copyright owner. For the purposes of this definition, "submitted"
|
||||||
|
means any form of electronic, verbal, or written communication sent
|
||||||
|
to the Licensor or its representatives, including but not limited to
|
||||||
|
communication on electronic mailing lists, source code control systems,
|
||||||
|
and issue tracking systems that are managed by, or on behalf of, the
|
||||||
|
Licensor for the purpose of discussing and improving the Work, but
|
||||||
|
excluding communication that is conspicuously marked or otherwise
|
||||||
|
designated in writing by the copyright owner as "Not a Contribution."
|
||||||
|
|
||||||
|
"Contributor" shall mean Licensor and any individual or Legal Entity
|
||||||
|
on behalf of whom a Contribution has been received by Licensor and
|
||||||
|
subsequently incorporated within the Work.
|
||||||
|
|
||||||
|
2. Grant of Copyright License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
copyright license to reproduce, prepare Derivative Works of,
|
||||||
|
publicly display, publicly perform, sublicense, and distribute the
|
||||||
|
Work and such Derivative Works in Source or Object form.
|
||||||
|
|
||||||
|
3. Grant of Patent License. Subject to the terms and conditions of
|
||||||
|
this License, each Contributor hereby grants to You a perpetual,
|
||||||
|
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
||||||
|
(except as stated in this section) patent license to make, have made,
|
||||||
|
use, offer to sell, sell, import, and otherwise transfer the Work,
|
||||||
|
where such license applies only to those patent claims licensable
|
||||||
|
by such Contributor that are necessarily infringed by their
|
||||||
|
Contribution(s) alone or by combination of their Contribution(s)
|
||||||
|
with the Work to which such Contribution(s) was submitted. If You
|
||||||
|
institute patent litigation against any entity (including a
|
||||||
|
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
||||||
|
or a Contribution incorporated within the Work constitutes direct
|
||||||
|
or contributory patent infringement, then any patent licenses
|
||||||
|
granted to You under this License for that Work shall terminate
|
||||||
|
as of the date such litigation is filed.
|
||||||
|
|
||||||
|
4. Redistribution. You may reproduce and distribute copies of the
|
||||||
|
Work or Derivative Works thereof in any medium, with or without
|
||||||
|
modifications, and in Source or Object form, provided that You
|
||||||
|
meet the following conditions:
|
||||||
|
|
||||||
|
(a) You must give any other recipients of the Work or
|
||||||
|
Derivative Works a copy of this License; and
|
||||||
|
|
||||||
|
(b) You must cause any modified files to carry prominent notices
|
||||||
|
stating that You changed the files; and
|
||||||
|
|
||||||
|
(c) You must retain, in the Source form of any Derivative Works
|
||||||
|
that You distribute, all copyright, patent, trademark, and
|
||||||
|
attribution notices from the Source form of the Work,
|
||||||
|
excluding those notices that do not pertain to any part of
|
||||||
|
the Derivative Works; and
|
||||||
|
|
||||||
|
(d) If the Work includes a "NOTICE" text file as part of its
|
||||||
|
distribution, then any Derivative Works that You distribute must
|
||||||
|
include a readable copy of the attribution notices contained
|
||||||
|
within such NOTICE file, excluding those notices that do not
|
||||||
|
pertain to any part of the Derivative Works, in at least one
|
||||||
|
of the following places: within a NOTICE text file distributed
|
||||||
|
as part of the Derivative Works; within the Source form or
|
||||||
|
documentation, if provided along with the Derivative Works; or,
|
||||||
|
within a display generated by the Derivative Works, if and
|
||||||
|
wherever such third-party notices normally appear. The contents
|
||||||
|
of the NOTICE file are for informational purposes only and
|
||||||
|
do not modify the License. You may add Your own attribution
|
||||||
|
notices within Derivative Works that You distribute, alongside
|
||||||
|
or as an addendum to the NOTICE text from the Work, provided
|
||||||
|
that such additional attribution notices cannot be construed
|
||||||
|
as modifying the License.
|
||||||
|
|
||||||
|
You may add Your own copyright statement to Your modifications and
|
||||||
|
may provide additional or different license terms and conditions
|
||||||
|
for use, reproduction, or distribution of Your modifications, or
|
||||||
|
for any such Derivative Works as a whole, provided Your use,
|
||||||
|
reproduction, and distribution of the Work otherwise complies with
|
||||||
|
the conditions stated in this License.
|
||||||
|
|
||||||
|
5. Submission of Contributions. Unless You explicitly state otherwise,
|
||||||
|
any Contribution intentionally submitted for inclusion in the Work
|
||||||
|
by You to the Licensor shall be under the terms and conditions of
|
||||||
|
this License, without any additional terms or conditions.
|
||||||
|
Notwithstanding the above, nothing herein shall supersede or modify
|
||||||
|
the terms of any separate license agreement you may have executed
|
||||||
|
with Licensor regarding such Contributions.
|
||||||
|
|
||||||
|
6. Trademarks. This License does not grant permission to use the trade
|
||||||
|
names, trademarks, service marks, or product names of the Licensor,
|
||||||
|
except as required for reasonable and customary use in describing the
|
||||||
|
origin of the Work and reproducing the content of the NOTICE file.
|
||||||
|
|
||||||
|
7. Disclaimer of Warranty. Unless required by applicable law or
|
||||||
|
agreed to in writing, Licensor provides the Work (and each
|
||||||
|
Contributor provides its Contributions) on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
||||||
|
implied, including, without limitation, any warranties or conditions
|
||||||
|
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
||||||
|
PARTICULAR PURPOSE. You are solely responsible for determining the
|
||||||
|
appropriateness of using or redistributing the Work and assume any
|
||||||
|
risks associated with Your exercise of permissions under this License.
|
||||||
|
|
||||||
|
8. Limitation of Liability. In no event and under no legal theory,
|
||||||
|
whether in tort (including negligence), contract, or otherwise,
|
||||||
|
unless required by applicable law (such as deliberate and grossly
|
||||||
|
negligent acts) or agreed to in writing, shall any Contributor be
|
||||||
|
liable to You for damages, including any direct, indirect, special,
|
||||||
|
incidental, or consequential damages of any character arising as a
|
||||||
|
result of this License or out of the use or inability to use the
|
||||||
|
Work (including but not limited to damages for loss of goodwill,
|
||||||
|
work stoppage, computer failure or malfunction, or any and all
|
||||||
|
other commercial damages or losses), even if such Contributor
|
||||||
|
has been advised of the possibility of such damages.
|
||||||
|
|
||||||
|
9. Accepting Warranty or Additional Liability. While redistributing
|
||||||
|
the Work or Derivative Works thereof, You may choose to offer,
|
||||||
|
and charge a fee for, acceptance of support, warranty, indemnity,
|
||||||
|
or other liability obligations and/or rights consistent with this
|
||||||
|
License. However, in accepting such obligations, You may act only
|
||||||
|
on Your own behalf and on Your sole responsibility, not on behalf
|
||||||
|
of any other Contributor, and only if You agree to indemnify,
|
||||||
|
defend, and hold each Contributor harmless for any liability
|
||||||
|
incurred by, or claims asserted against, such Contributor by reason
|
||||||
|
of your accepting any such warranty or additional liability.
|
||||||
|
|
||||||
|
END OF TERMS AND CONDITIONS
|
||||||
|
|
||||||
|
APPENDIX: How to apply the Apache License to your work.
|
||||||
|
|
||||||
|
To apply the Apache License to your work, attach the following
|
||||||
|
boilerplate notice, with the fields enclosed by brackets "[]"
|
||||||
|
replaced with your own identifying information. (Don't include
|
||||||
|
the brackets!) The text should be enclosed in the appropriate
|
||||||
|
comment syntax for the file format. We also recommend that a
|
||||||
|
file or class name and description of purpose be included on the
|
||||||
|
same "printed page" as the copyright notice for easier
|
||||||
|
identification within third-party archives.
|
||||||
|
|
||||||
|
Copyright [yyyy] [name of copyright owner]
|
||||||
|
|
||||||
|
Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
you may not use this file except in compliance with the License.
|
||||||
|
You may obtain a copy of the License at
|
||||||
|
|
||||||
|
http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
|
||||||
|
Unless required by applicable law or agreed to in writing, software
|
||||||
|
distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
See the License for the specific language governing permissions and
|
||||||
|
limitations under the License.
|
71
public/fonts/Roboto_Slab/README.txt
Normal file
71
public/fonts/Roboto_Slab/README.txt
Normal file
@ -0,0 +1,71 @@
|
|||||||
|
Roboto Slab Variable Font
|
||||||
|
=========================
|
||||||
|
|
||||||
|
This download contains Roboto Slab as both a variable font and static fonts.
|
||||||
|
|
||||||
|
Roboto Slab is a variable font with this axis:
|
||||||
|
wght
|
||||||
|
|
||||||
|
This means all the styles are contained in a single file:
|
||||||
|
RobotoSlab-VariableFont_wght.ttf
|
||||||
|
|
||||||
|
If your app fully supports variable fonts, you can now pick intermediate styles
|
||||||
|
that aren’t available as static fonts. Not all apps support variable fonts, and
|
||||||
|
in those cases you can use the static font files for Roboto Slab:
|
||||||
|
static/RobotoSlab-Thin.ttf
|
||||||
|
static/RobotoSlab-ExtraLight.ttf
|
||||||
|
static/RobotoSlab-Light.ttf
|
||||||
|
static/RobotoSlab-Regular.ttf
|
||||||
|
static/RobotoSlab-Medium.ttf
|
||||||
|
static/RobotoSlab-SemiBold.ttf
|
||||||
|
static/RobotoSlab-Bold.ttf
|
||||||
|
static/RobotoSlab-ExtraBold.ttf
|
||||||
|
static/RobotoSlab-Black.ttf
|
||||||
|
|
||||||
|
Get started
|
||||||
|
-----------
|
||||||
|
|
||||||
|
1. Install the font files you want to use
|
||||||
|
|
||||||
|
2. Use your app's font picker to view the font family and all the
|
||||||
|
available styles
|
||||||
|
|
||||||
|
Learn more about variable fonts
|
||||||
|
-------------------------------
|
||||||
|
|
||||||
|
https://developers.google.com/web/fundamentals/design-and-ux/typography/variable-fonts
|
||||||
|
https://variablefonts.typenetwork.com
|
||||||
|
https://medium.com/variable-fonts
|
||||||
|
|
||||||
|
In desktop apps
|
||||||
|
|
||||||
|
https://theblog.adobe.com/can-variable-fonts-illustrator-cc
|
||||||
|
https://helpx.adobe.com/nz/photoshop/using/fonts.html#variable_fonts
|
||||||
|
|
||||||
|
Online
|
||||||
|
|
||||||
|
https://developers.google.com/fonts/docs/getting_started
|
||||||
|
https://developer.mozilla.org/en-US/docs/Web/CSS/CSS_Fonts/Variable_Fonts_Guide
|
||||||
|
https://developer.microsoft.com/en-us/microsoft-edge/testdrive/demos/variable-fonts
|
||||||
|
|
||||||
|
Installing fonts
|
||||||
|
|
||||||
|
MacOS: https://support.apple.com/en-us/HT201749
|
||||||
|
Linux: https://www.google.com/search?q=how+to+install+a+font+on+gnu%2Blinux
|
||||||
|
Windows: https://support.microsoft.com/en-us/help/314960/how-to-install-or-remove-a-font-in-windows
|
||||||
|
|
||||||
|
Android Apps
|
||||||
|
|
||||||
|
https://developers.google.com/fonts/docs/android
|
||||||
|
https://developer.android.com/guide/topics/ui/look-and-feel/downloadable-fonts
|
||||||
|
|
||||||
|
License
|
||||||
|
-------
|
||||||
|
Please read the full license text (LICENSE.txt) to understand the permissions,
|
||||||
|
restrictions and requirements for usage, redistribution, and modification.
|
||||||
|
|
||||||
|
You can use them in your products & projects – print or digital,
|
||||||
|
commercial or otherwise.
|
||||||
|
|
||||||
|
This isn't legal advice, please consider consulting a lawyer and see the full
|
||||||
|
license for all details.
|
BIN
public/fonts/Roboto_Slab/RobotoSlab-VariableFont_wght.ttf
Normal file
BIN
public/fonts/Roboto_Slab/RobotoSlab-VariableFont_wght.ttf
Normal file
Binary file not shown.
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Black.ttf
Normal file
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Black.ttf
Normal file
Binary file not shown.
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Bold.ttf
Normal file
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Bold.ttf
Normal file
Binary file not shown.
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-ExtraBold.ttf
Normal file
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-ExtraBold.ttf
Normal file
Binary file not shown.
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-ExtraLight.ttf
Normal file
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-ExtraLight.ttf
Normal file
Binary file not shown.
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Light.ttf
Normal file
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Light.ttf
Normal file
Binary file not shown.
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Medium.ttf
Normal file
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Medium.ttf
Normal file
Binary file not shown.
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Regular.ttf
Normal file
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Regular.ttf
Normal file
Binary file not shown.
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-SemiBold.ttf
Normal file
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-SemiBold.ttf
Normal file
Binary file not shown.
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Thin.ttf
Normal file
BIN
public/fonts/Roboto_Slab/static/RobotoSlab-Thin.ttf
Normal file
Binary file not shown.
1
public/vite.svg
Normal file
1
public/vite.svg
Normal file
@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" class="iconify iconify--logos" width="31.88" height="32" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 257"><defs><linearGradient id="IconifyId1813088fe1fbc01fb466" x1="-.828%" x2="57.636%" y1="7.652%" y2="78.411%"><stop offset="0%" stop-color="#41D1FF"></stop><stop offset="100%" stop-color="#BD34FE"></stop></linearGradient><linearGradient id="IconifyId1813088fe1fbc01fb467" x1="43.376%" x2="50.316%" y1="2.242%" y2="89.03%"><stop offset="0%" stop-color="#FFEA83"></stop><stop offset="8.333%" stop-color="#FFDD35"></stop><stop offset="100%" stop-color="#FFA800"></stop></linearGradient></defs><path fill="url(#IconifyId1813088fe1fbc01fb466)" d="M255.153 37.938L134.897 252.976c-2.483 4.44-8.862 4.466-11.382.048L.875 37.958c-2.746-4.814 1.371-10.646 6.827-9.67l120.385 21.517a6.537 6.537 0 0 0 2.322-.004l117.867-21.483c5.438-.991 9.574 4.796 6.877 9.62Z"></path><path fill="url(#IconifyId1813088fe1fbc01fb467)" d="M185.432.063L96.44 17.501a3.268 3.268 0 0 0-2.634 3.014l-5.474 92.456a3.268 3.268 0 0 0 3.997 3.378l24.777-5.718c2.318-.535 4.413 1.507 3.936 3.838l-7.361 36.047c-.495 2.426 1.782 4.5 4.151 3.78l15.304-4.649c2.372-.72 4.652 1.36 4.15 3.788l-11.698 56.621c-.732 3.542 3.979 5.473 5.943 2.437l1.313-2.028l72.516-144.72c1.215-2.423-.88-5.186-3.54-4.672l-25.505 4.922c-2.396.462-4.435-1.77-3.759-4.114l16.646-57.705c.677-2.35-1.37-4.583-3.769-4.113Z"></path></svg>
|
After Width: | Height: | Size: 1.5 KiB |
27
src/App.jsx
Normal file
27
src/App.jsx
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
import PropTypes from 'prop-types'
|
||||||
|
import Header from './components/header/header'
|
||||||
|
import Footer from './components/footer/footer'
|
||||||
|
import { Outlet } from 'react-router-dom';
|
||||||
|
import { Container } from 'react-bootstrap'
|
||||||
|
import BottomMenu from './components/bottommenu/bottommenu';
|
||||||
|
import LeftMenu from './components/leftmenu/leftmenu';
|
||||||
|
|
||||||
|
const App = ({ routes }) => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<Header routes={routes}></Header>
|
||||||
|
<Container as="main" className="px-1 px-sm-2 px-lg-4 pt-2 pt-sm-4 d-flex position-relative flex-fill">
|
||||||
|
<LeftMenu routes={routes} />
|
||||||
|
<Outlet />
|
||||||
|
</Container>
|
||||||
|
<BottomMenu routes={routes} />
|
||||||
|
<Footer></Footer>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
App.propTypes = {
|
||||||
|
routes: PropTypes.array,
|
||||||
|
};
|
||||||
|
|
||||||
|
export default App
|
BIN
src/assets/gachi.jpg
Normal file
BIN
src/assets/gachi.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 14 KiB |
BIN
src/assets/korgi.jpg
Normal file
BIN
src/assets/korgi.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 140 KiB |
1
src/assets/react.svg
Normal file
1
src/assets/react.svg
Normal file
@ -0,0 +1 @@
|
|||||||
|
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" aria-hidden="true" role="img" class="iconify iconify--logos" width="35.93" height="32" preserveAspectRatio="xMidYMid meet" viewBox="0 0 256 228"><path fill="#00D8FF" d="M210.483 73.824a171.49 171.49 0 0 0-8.24-2.597c.465-1.9.893-3.777 1.273-5.621c6.238-30.281 2.16-54.676-11.769-62.708c-13.355-7.7-35.196.329-57.254 19.526a171.23 171.23 0 0 0-6.375 5.848a155.866 155.866 0 0 0-4.241-3.917C100.759 3.829 77.587-4.822 63.673 3.233C50.33 10.957 46.379 33.89 51.995 62.588a170.974 170.974 0 0 0 1.892 8.48c-3.28.932-6.445 1.924-9.474 2.98C17.309 83.498 0 98.307 0 113.668c0 15.865 18.582 31.778 46.812 41.427a145.52 145.52 0 0 0 6.921 2.165a167.467 167.467 0 0 0-2.01 9.138c-5.354 28.2-1.173 50.591 12.134 58.266c13.744 7.926 36.812-.22 59.273-19.855a145.567 145.567 0 0 0 5.342-4.923a168.064 168.064 0 0 0 6.92 6.314c21.758 18.722 43.246 26.282 56.54 18.586c13.731-7.949 18.194-32.003 12.4-61.268a145.016 145.016 0 0 0-1.535-6.842c1.62-.48 3.21-.974 4.76-1.488c29.348-9.723 48.443-25.443 48.443-41.52c0-15.417-17.868-30.326-45.517-39.844Zm-6.365 70.984c-1.4.463-2.836.91-4.3 1.345c-3.24-10.257-7.612-21.163-12.963-32.432c5.106-11 9.31-21.767 12.459-31.957c2.619.758 5.16 1.557 7.61 2.4c23.69 8.156 38.14 20.213 38.14 29.504c0 9.896-15.606 22.743-40.946 31.14Zm-10.514 20.834c2.562 12.94 2.927 24.64 1.23 33.787c-1.524 8.219-4.59 13.698-8.382 15.893c-8.067 4.67-25.32-1.4-43.927-17.412a156.726 156.726 0 0 1-6.437-5.87c7.214-7.889 14.423-17.06 21.459-27.246c12.376-1.098 24.068-2.894 34.671-5.345a134.17 134.17 0 0 1 1.386 6.193ZM87.276 214.515c-7.882 2.783-14.16 2.863-17.955.675c-8.075-4.657-11.432-22.636-6.853-46.752a156.923 156.923 0 0 1 1.869-8.499c10.486 2.32 22.093 3.988 34.498 4.994c7.084 9.967 14.501 19.128 21.976 27.15a134.668 134.668 0 0 1-4.877 4.492c-9.933 8.682-19.886 14.842-28.658 17.94ZM50.35 144.747c-12.483-4.267-22.792-9.812-29.858-15.863c-6.35-5.437-9.555-10.836-9.555-15.216c0-9.322 13.897-21.212 37.076-29.293c2.813-.98 5.757-1.905 8.812-2.773c3.204 10.42 7.406 21.315 12.477 32.332c-5.137 11.18-9.399 22.249-12.634 32.792a134.718 134.718 0 0 1-6.318-1.979Zm12.378-84.26c-4.811-24.587-1.616-43.134 6.425-47.789c8.564-4.958 27.502 2.111 47.463 19.835a144.318 144.318 0 0 1 3.841 3.545c-7.438 7.987-14.787 17.08-21.808 26.988c-12.04 1.116-23.565 2.908-34.161 5.309a160.342 160.342 0 0 1-1.76-7.887Zm110.427 27.268a347.8 347.8 0 0 0-7.785-12.803c8.168 1.033 15.994 2.404 23.343 4.08c-2.206 7.072-4.956 14.465-8.193 22.045a381.151 381.151 0 0 0-7.365-13.322Zm-45.032-43.861c5.044 5.465 10.096 11.566 15.065 18.186a322.04 322.04 0 0 0-30.257-.006c4.974-6.559 10.069-12.652 15.192-18.18ZM82.802 87.83a323.167 323.167 0 0 0-7.227 13.238c-3.184-7.553-5.909-14.98-8.134-22.152c7.304-1.634 15.093-2.97 23.209-3.984a321.524 321.524 0 0 0-7.848 12.897Zm8.081 65.352c-8.385-.936-16.291-2.203-23.593-3.793c2.26-7.3 5.045-14.885 8.298-22.6a321.187 321.187 0 0 0 7.257 13.246c2.594 4.48 5.28 8.868 8.038 13.147Zm37.542 31.03c-5.184-5.592-10.354-11.779-15.403-18.433c4.902.192 9.899.29 14.978.29c5.218 0 10.376-.117 15.453-.343c-4.985 6.774-10.018 12.97-15.028 18.486Zm52.198-57.817c3.422 7.8 6.306 15.345 8.596 22.52c-7.422 1.694-15.436 3.058-23.88 4.071a382.417 382.417 0 0 0 7.859-13.026a347.403 347.403 0 0 0 7.425-13.565Zm-16.898 8.101a358.557 358.557 0 0 1-12.281 19.815a329.4 329.4 0 0 1-23.444.823c-7.967 0-15.716-.248-23.178-.732a310.202 310.202 0 0 1-12.513-19.846h.001a307.41 307.41 0 0 1-10.923-20.627a310.278 310.278 0 0 1 10.89-20.637l-.001.001a307.318 307.318 0 0 1 12.413-19.761c7.613-.576 15.42-.876 23.31-.876H128c7.926 0 15.743.303 23.354.883a329.357 329.357 0 0 1 12.335 19.695a358.489 358.489 0 0 1 11.036 20.54a329.472 329.472 0 0 1-11 20.722Zm22.56-122.124c8.572 4.944 11.906 24.881 6.52 51.026c-.344 1.668-.73 3.367-1.15 5.09c-10.622-2.452-22.155-4.275-34.23-5.408c-7.034-10.017-14.323-19.124-21.64-27.008a160.789 160.789 0 0 1 5.888-5.4c18.9-16.447 36.564-22.941 44.612-18.3ZM128 90.808c12.625 0 22.86 10.235 22.86 22.86s-10.235 22.86-22.86 22.86s-22.86-10.235-22.86-22.86s10.235-22.86 22.86-22.86Z"></path></svg>
|
After Width: | Height: | Size: 4.0 KiB |
11
src/components/bottommenu/bottommenu.css
Normal file
11
src/components/bottommenu/bottommenu.css
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
.bottom-menu {
|
||||||
|
background-color: #235D70;
|
||||||
|
}
|
||||||
|
|
||||||
|
.bottom-menu * {
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
|
.bottom-menu span {
|
||||||
|
font-size: smaller;
|
||||||
|
}
|
26
src/components/bottommenu/bottommenu.jsx
Normal file
26
src/components/bottommenu/bottommenu.jsx
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
import PropTypes from 'prop-types';
|
||||||
|
import { Link } from 'react-router-dom';
|
||||||
|
import './bottommenu.css';
|
||||||
|
|
||||||
|
const BottomMenu = ({ routes }) => {
|
||||||
|
const pages = routes.filter((route) => route.showInBottomMenu);
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<div className="bottom-menu d-flex d-sm-none justify-content-around sticky-bottom">
|
||||||
|
{
|
||||||
|
pages.map((route) =>
|
||||||
|
<Link to={route.path} key={route.path} className="bottom-menu-item d-flex flex-column rounded-2 align-items-center py-1">
|
||||||
|
{route.menuIcon}
|
||||||
|
<span>{route.title}</span>
|
||||||
|
</Link>)
|
||||||
|
}
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
BottomMenu.propTypes = {
|
||||||
|
routes: PropTypes.array,
|
||||||
|
};
|
||||||
|
|
||||||
|
export default BottomMenu;
|
63
src/components/center/center.css
Normal file
63
src/components/center/center.css
Normal file
@ -0,0 +1,63 @@
|
|||||||
|
.center {
|
||||||
|
width: 70%;
|
||||||
|
z-index: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.user-message-trucated-text {
|
||||||
|
max-width: 60vw;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media screen and (min-width: 992px) {
|
||||||
|
.user-message-trucated-text {
|
||||||
|
max-width: 30vw;
|
||||||
|
}
|
||||||
|
|
||||||
|
.center {
|
||||||
|
width: 40%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@media screen and (max-width: 576px) {
|
||||||
|
.user-message-trucated-text {
|
||||||
|
max-width: 70vw;
|
||||||
|
}
|
||||||
|
|
||||||
|
.center {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
#post-editor {
|
||||||
|
min-height: calc(1em + 26px);
|
||||||
|
}
|
||||||
|
|
||||||
|
#title-image-preview {
|
||||||
|
width: 100%;
|
||||||
|
min-height: 100px;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
|
font-size: 50px;
|
||||||
|
cursor: pointer;
|
||||||
|
border: solid;
|
||||||
|
border-width: 1px;
|
||||||
|
}
|
||||||
|
|
||||||
|
#title-image-preview i {
|
||||||
|
opacity: 0.3;
|
||||||
|
transition: opacity .3s;
|
||||||
|
}
|
||||||
|
|
||||||
|
#title-image-preview:hover i {
|
||||||
|
opacity: 1.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
#input-title-image {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
#selected-title-image {
|
||||||
|
width: 100%;
|
||||||
|
display: none;
|
||||||
|
}
|
18
src/components/center/center.jsx
Normal file
18
src/components/center/center.jsx
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
import PropTypes from 'prop-types';
|
||||||
|
import './center.css';
|
||||||
|
|
||||||
|
const Center = ({ children }) => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<div className="center d-flex flex-column">
|
||||||
|
{children}
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
Center.propTypes = {
|
||||||
|
children: PropTypes.node,
|
||||||
|
};
|
||||||
|
|
||||||
|
export default Center;
|
0
src/components/chatrow/chatrow.css
Normal file
0
src/components/chatrow/chatrow.css
Normal file
24
src/components/chatrow/chatrow.jsx
Normal file
24
src/components/chatrow/chatrow.jsx
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
import './chatrow.css';
|
||||||
|
|
||||||
|
const ChatRow = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<a className="people-row hoverable border-bottom border-dark p-2 d-flex justify-content-between align-items-center">
|
||||||
|
<div className="d-flex justify-content-start align-items-center" style={{ fontSize: "small" }}>
|
||||||
|
<img src="/src/assets/gachi.jpg" className="user-avatar avatar-small img-fluid rounded-circle" />
|
||||||
|
<div className="user-info ms-2 d-flex flex-column justify-content-center w-100">
|
||||||
|
<div className="user-name">Валерий Никифоров</div>
|
||||||
|
<div className="user-message-trucated-text px-2 py-1 rounded-3 text-truncate" style={{ fontSize: "smaller" }}>
|
||||||
|
Табличку по баллам сведу к понедельнику.
|
||||||
|
Больше никакие лабы присылать нельзя, литкод
|
||||||
|
можно. Плюс поверьте, что у вас 7 ответов по
|
||||||
|
лекциям
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</a >
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default ChatRow;
|
4
src/components/footer/footer.css
Normal file
4
src/components/footer/footer.css
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
.footer {
|
||||||
|
color: var(--alternative-font-color);
|
||||||
|
--bs-border-color: var(--alternative-font-color);
|
||||||
|
}
|
13
src/components/footer/footer.jsx
Normal file
13
src/components/footer/footer.jsx
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
import './footer.css'
|
||||||
|
|
||||||
|
const Footer = () => {
|
||||||
|
const year = new Date().getFullYear();
|
||||||
|
|
||||||
|
return (
|
||||||
|
<footer className="footer py-2 d-none d-sm-flex justify-content-center border-top">
|
||||||
|
© {year} Неконтакте
|
||||||
|
</footer>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default Footer;
|
7
src/components/friendrow/friendrow.css
Normal file
7
src/components/friendrow/friendrow.css
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
.btn-delete-from-friends svg {
|
||||||
|
transition: .3s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.btn-delete-from-friends:hover svg {
|
||||||
|
fill: red;
|
||||||
|
}
|
27
src/components/friendrow/friendrow.jsx
Normal file
27
src/components/friendrow/friendrow.jsx
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
import { Trash } from 'react-bootstrap-icons';
|
||||||
|
import './friendrow.css'
|
||||||
|
|
||||||
|
const FriendRow = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<div className="people-row hoverable border-bottom border-dark p-2 d-flex justify-content-between align-items-center">
|
||||||
|
<a className="d-flex justify-content-start align-items-center" style={{ fontSize: "small" }}>
|
||||||
|
<img src="/src/assets/gachi.jpg" className="user-avatar avatar-small img-fluid rounded-circle" />
|
||||||
|
<div className="user-info ms-2 d-flex flex-column justify-content-center">
|
||||||
|
<div className="user-name">
|
||||||
|
Валентина Лаврентьева
|
||||||
|
</div>
|
||||||
|
<div className="user-meta">
|
||||||
|
г. Калининград, 20 лет
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
<button className="btn btn-delete-from-friends" title="Удалить из друзей">
|
||||||
|
<Trash />
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default FriendRow;
|
11
src/components/header/header.css
Normal file
11
src/components/header/header.css
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
.navbar {
|
||||||
|
background-color: var(--dark-background-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar * {
|
||||||
|
color: var(--dark-font-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
.navbar-brand {
|
||||||
|
z-index: 10;
|
||||||
|
}
|
35
src/components/header/header.jsx
Normal file
35
src/components/header/header.jsx
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
import PropTypes from 'prop-types';
|
||||||
|
import { Container, Navbar } from 'react-bootstrap';
|
||||||
|
import { Link, useLocation } from 'react-router-dom';
|
||||||
|
import './header.css';
|
||||||
|
|
||||||
|
const Header = ({ routes }) => {
|
||||||
|
const location = useLocation();
|
||||||
|
const indexPageLink = routes.filter((route) => route.index === false).shift();
|
||||||
|
const currentPage = routes.filter((route) => route.path === location.pathname)[0];
|
||||||
|
return (
|
||||||
|
<header className='sticky-top'>
|
||||||
|
<Navbar>
|
||||||
|
<Container fluid className='d-flex justify-content-between position-relative'>
|
||||||
|
<Navbar.Brand as={Link} to={indexPageLink?.path ?? '/'}>
|
||||||
|
<span className='logo-small d-sm-none'>
|
||||||
|
нк
|
||||||
|
</span>
|
||||||
|
<span className='logo-full d-none d-sm-block'>
|
||||||
|
неконтакте
|
||||||
|
</span>
|
||||||
|
</Navbar.Brand>
|
||||||
|
</Container>
|
||||||
|
<div className='page-title position-absolute w-100 text-center'>
|
||||||
|
{currentPage.title}
|
||||||
|
</div>
|
||||||
|
</Navbar >
|
||||||
|
</header>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
Header.propTypes = {
|
||||||
|
routes: PropTypes.array,
|
||||||
|
};
|
||||||
|
|
||||||
|
export default Header;
|
10
src/components/leftmenu/leftmenu.css
Normal file
10
src/components/leftmenu/leftmenu.css
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
#left-menu {
|
||||||
|
--bs-border-color: var(--alternative-font-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-menu-item {
|
||||||
|
transition: .1s;
|
||||||
|
border-style: solid;
|
||||||
|
border-width: 1px;
|
||||||
|
border-color: rgba(0, 0, 0, 0);
|
||||||
|
}
|
28
src/components/leftmenu/leftmenu.jsx
Normal file
28
src/components/leftmenu/leftmenu.jsx
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
import PropTypes from "prop-types";
|
||||||
|
import { Link } from 'react-router-dom';
|
||||||
|
import './leftmenu.css';
|
||||||
|
|
||||||
|
const LeftMenu = ({ routes }) => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<div
|
||||||
|
id="left-menu"
|
||||||
|
className="p-3 d-none d-sm-flex flex-column justify-content-center align-content-around border rounded-2 position-fixed"
|
||||||
|
>
|
||||||
|
{
|
||||||
|
routes.map((route) =>
|
||||||
|
<Link to={route.path} key={route.path} className="hoverable left-menu-item d-flex flex-row align-items-center rounded-2 py-1 px-2" title={route.title}>
|
||||||
|
{route.menuIcon}
|
||||||
|
<span className="ms-2 d-none d-lg-block">{route.title}</span>
|
||||||
|
</Link>)
|
||||||
|
}
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
LeftMenu.propTypes = {
|
||||||
|
routes: PropTypes.array,
|
||||||
|
};
|
||||||
|
|
||||||
|
export default LeftMenu;
|
45
src/components/post/post.css
Normal file
45
src/components/post/post.css
Normal file
@ -0,0 +1,45 @@
|
|||||||
|
.post {
|
||||||
|
background-color: var(--alternative-backgrond-color);
|
||||||
|
--bs-border-color: var(--alternative-font-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-meta {
|
||||||
|
font-size: small;
|
||||||
|
}
|
||||||
|
|
||||||
|
.counter-block {
|
||||||
|
transition: .1s;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.counter-block:hover {
|
||||||
|
background-color: #e8e8e8;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-body-img {
|
||||||
|
width: 100%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-body a {
|
||||||
|
color: #4a9cb7;
|
||||||
|
text-decoration: none;
|
||||||
|
background-image: linear-gradient(currentColor, currentColor);
|
||||||
|
background-position: 0% 100%;
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-size: 0% 2px;
|
||||||
|
transition: background-size .3s;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-body a:hover {
|
||||||
|
background-size: 100% 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.post-body-text {
|
||||||
|
white-space: pre-wrap;
|
||||||
|
}
|
||||||
|
|
||||||
|
.avatar-small {
|
||||||
|
width: 35px;
|
||||||
|
height: 35px;
|
||||||
|
object-fit: cover;
|
||||||
|
}
|
79
src/components/post/post.jsx
Normal file
79
src/components/post/post.jsx
Normal file
@ -0,0 +1,79 @@
|
|||||||
|
import './post.css';
|
||||||
|
|
||||||
|
const Post = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<div className="post mb-2 mb-sm-4 w-100 d-flex flex-column border rounded-2">
|
||||||
|
<div className="post-header py-1 ps-1 pe-2 d-flex border-bottom justify-content-between align-items-center">
|
||||||
|
<a className="hoverable d-flex justify-content-start align-items-center rounded-pill px-1">
|
||||||
|
<div className="post-author-avatar-wrapper">
|
||||||
|
<img src="/src/assets/gachi.jpg" className="post-author-avatar avatar-small rounded-circle" />
|
||||||
|
</div>
|
||||||
|
<div className="post-meta mx-2 d-flex flex-column justify-content-center">
|
||||||
|
<div className="post-author-name">
|
||||||
|
Алексей Смирнов
|
||||||
|
</div>
|
||||||
|
<div className="post-publication-datetime">
|
||||||
|
15 сентября, 15:22
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</a>
|
||||||
|
<a>
|
||||||
|
<i className="bi bi-three-dots fs-4"></i>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<div className="post-body">
|
||||||
|
<div className="post-body-text m-2">
|
||||||
|
<p>
|
||||||
|
Корги – королевская порода с дружелюбным
|
||||||
|
характером
|
||||||
|
</p>
|
||||||
|
<p>
|
||||||
|
Привет, друзья! Сегодня я хочу
|
||||||
|
рассказать вам о замечательной породе
|
||||||
|
собак – корги. Эти милые создания с
|
||||||
|
короткими лапами и длинными ушами
|
||||||
|
покорили сердца многих людей, и не зря!
|
||||||
|
Корги – это небольшие собаки, которые
|
||||||
|
произошли из Уэльса. Они были выведены
|
||||||
|
для охоты на зайцев и других мелких
|
||||||
|
животных.
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
<img src="/src/assets/korgi.jpg" className="post-body-img img-fluid" />
|
||||||
|
</div>
|
||||||
|
<div className="post-footer py-1 px-2 border-top d-flex">
|
||||||
|
<div className="hoverable counter-block likes-block px-2 me-1 d-flex align-items-center rounded-4">
|
||||||
|
<svg height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<g fill="none" fillRule="evenodd">
|
||||||
|
<path d="M0 0h24v24H0z"></path>
|
||||||
|
<path d="M16 4a5.95 5.95 0 0 0-3.89 1.7l-.12.11-.12-.11A5.96 5.96 0 0 0 7.73 4 5.73 5.73 0 0 0 2 9.72c0 3.08 1.13 4.55 6.18 8.54l2.69 2.1c.66.52 1.6.52 2.26 0l2.36-1.84.94-.74c4.53-3.64 5.57-5.1 5.57-8.06A5.73 5.73 0 0 0 16.27 4zm.27 1.8a3.93 3.93 0 0 1 3.93 3.92v.3c-.08 2.15-1.07 3.33-5.51 6.84l-2.67 2.08a.04.04 0 0 1-.04 0L9.6 17.1l-.87-.7C4.6 13.1 3.8 11.98 3.8 9.73A3.93 3.93 0 0 1 7.73 5.8c1.34 0 2.51.62 3.57 1.92a.9.9 0 0 0 1.4-.01c1.04-1.3 2.2-1.91 3.57-1.91z" fill="currentColor" fillRule="nonzero"></path>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
<span className="count ms-1">734</span>
|
||||||
|
</div>
|
||||||
|
<div className="hoverable counter-block comments-block px-2 me-1 d-flex align-items-center rounded-4">
|
||||||
|
<svg height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<g fill="none" fillRule="evenodd">
|
||||||
|
<path d="M0 0h24v24H0z"></path>
|
||||||
|
<path d="M16.9 4H7.1c-1.15 0-1.73.11-2.35.44-.56.3-1 .75-1.31 1.31C3.11 6.37 3 6.95 3 8.1v5.8c0 1.15.11 1.73.44 2.35.3.56.75 1 1.31 1.31l.15.07c.51.25 1.04.35 1.95.37h.25v2.21c0 .44.17.85.47 1.16l.12.1c.64.55 1.6.52 2.21-.08L13.37 18h3.53c1.15 0 1.73-.11 2.35-.44.56-.3 1-.75 1.31-1.31.33-.62.44-1.2.44-2.35V8.1c0-1.15-.11-1.73-.44-2.35a3.17 3.17 0 0 0-1.31-1.31A4.51 4.51 0 0 0 16.9 4zM6.9 5.8h9.99c.88 0 1.18.06 1.5.23.25.13.44.32.57.57.17.32.23.62.23 1.5v6.16c-.02.61-.09.87-.23 1.14-.13.25-.32.44-.57.57-.32.17-.62.23-1.5.23h-4.02a.9.9 0 0 0-.51.26l-3.47 3.4V17.1c0-.5-.4-.9-.9-.9H6.74a2.3 2.3 0 0 1-1.14-.23 1.37 1.37 0 0 1-.57-.57c-.17-.32-.23-.62-.23-1.5V7.74c.02-.61.09-.87.23-1.14.13-.25.32-.44.57-.57.3-.16.58-.22 1.31-.23z" fill="currentColor" fillRule="nonzero"></path>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
<span className="count ms-1">344</span>
|
||||||
|
</div>
|
||||||
|
<div className="hoverable counter-block replies-block px-2 d-flex align-items-center rounded-4">
|
||||||
|
<svg height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<g fill="none" fillRule="evenodd">
|
||||||
|
<path d="M0 0h24v24H0z"></path>
|
||||||
|
<path d="M12 3.73c-1.12.07-2 1-2 2.14v2.12h-.02a9.9 9.9 0 0 0-7.83 10.72.9.9 0 0 0 1.61.46l.19-.24a9.08 9.08 0 0 1 5.84-3.26l.2-.03.01 2.5a2.15 2.15 0 0 0 3.48 1.69l7.82-6.14a2.15 2.15 0 0 0 0-3.38l-7.82-6.13c-.38-.3-.85-.46-1.33-.46zm.15 1.79c.08 0 .15.03.22.07l7.82 6.14a.35.35 0 0 1 0 .55l-7.82 6.13a.35.35 0 0 1-.57-.28V14.7a.9.9 0 0 0-.92-.9h-.23l-.34.02c-2.28.14-4.4.98-6.12 2.36l-.17.15.02-.14a8.1 8.1 0 0 1 6.97-6.53.9.9 0 0 0 .79-.9V5.87c0-.2.16-.35.35-.35z" fill="currentColor" fillRule="nonzero"></path>
|
||||||
|
</g>
|
||||||
|
</svg>
|
||||||
|
<span className="count ms-1">1</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default Post;
|
12
src/components/postinputform/postinputform.css
Normal file
12
src/components/postinputform/postinputform.css
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
#post-editor {
|
||||||
|
--bs-border-color: var(--alternative-font-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
#title-image-block * {
|
||||||
|
--bs-border-color: var(--alternative-font-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
#post-publication-button {
|
||||||
|
--bs-btn-bg: var(--dark-background-color);
|
||||||
|
--bs-btn-border-color: var(--dark-background-color);
|
||||||
|
}
|
31
src/components/postinputform/postinputform.jsx
Normal file
31
src/components/postinputform/postinputform.jsx
Normal file
@ -0,0 +1,31 @@
|
|||||||
|
import './postinputform.css';
|
||||||
|
import { Camera } from 'react-bootstrap-icons';
|
||||||
|
|
||||||
|
const PostInputForm = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<textarea placeholder="Что нового?" id="post-editor" className="border rounded-2 mb-2 p-2"></textarea>
|
||||||
|
<div id="title-image-block">
|
||||||
|
<input id="check-title-image" type="checkbox" style={{ display: "none" }} />
|
||||||
|
<input id="input-title-image" className='border' name="titleImage" accept="image/*" type="file" />
|
||||||
|
<label id="title-image-preview" htmlFor="input-title-image" title="Добавить изображение" className="border rounded-2 mb-2">
|
||||||
|
<Camera id="empty-title-image" />
|
||||||
|
<img id="selected-title-image" className="rounded-2" />
|
||||||
|
</label>
|
||||||
|
</div>
|
||||||
|
<button className="btn btn-primary mb-2" id="post-publication-button">
|
||||||
|
Опубликовать
|
||||||
|
</button>
|
||||||
|
<div className="d-none d-flex mb-2 w-100" id="edit-block">
|
||||||
|
<button className="btn btn-danger me-2 w-100" id="edit-post-button-cancel">
|
||||||
|
Отмена
|
||||||
|
</button>
|
||||||
|
<button className="btn btn-success w-100" id="edit-post-button-accept">
|
||||||
|
Применить
|
||||||
|
</button>
|
||||||
|
</div >
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default PostInputForm;
|
4
src/components/searchgroup/searchgroup.css
Normal file
4
src/components/searchgroup/searchgroup.css
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
#button-addon:hover svg {
|
||||||
|
fill: white;
|
||||||
|
transition: .3s;
|
||||||
|
}
|
17
src/components/searchgroup/searchgroup.jsx
Normal file
17
src/components/searchgroup/searchgroup.jsx
Normal file
@ -0,0 +1,17 @@
|
|||||||
|
import { Search } from "react-bootstrap-icons";
|
||||||
|
import './searchgroup.css';
|
||||||
|
|
||||||
|
const SearchGroup = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<div className="input-group mb-3">
|
||||||
|
<input type="text" className="form-control" placeholder="Найти друзей" />
|
||||||
|
<button className="btn btn-outline-secondary" type="button" id="button-addon">
|
||||||
|
<Search />
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default SearchGroup;
|
35
src/components/userprofileblock/userprofileblock.jsx
Normal file
35
src/components/userprofileblock/userprofileblock.jsx
Normal file
@ -0,0 +1,35 @@
|
|||||||
|
import './userprofileblock.css';
|
||||||
|
import { People, Calendar as Calendar, GeoAlt } from 'react-bootstrap-icons';
|
||||||
|
|
||||||
|
const UserProfileBlock = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<div className="user-profile p-3 mb-2 mb-sm-4 w-100 d-flex flex-column flex-sm-row border rounded-2 border-dark">
|
||||||
|
<div className='d-flex align-items-center justify-content-center me-0 me-sm-3 mb-3 mb-sm-0'>
|
||||||
|
<img src="/src/assets/gachi.jpg" className="user-photo rounded-2 img-fluid" />
|
||||||
|
</div>
|
||||||
|
<div className="user-meta-wrapper d-flex flex-column">
|
||||||
|
<span className="fs-5 mb-2">Алексей Смирнов</span>
|
||||||
|
<span style={{ fontSize: "small" }} className="mb-2 fst-italic">
|
||||||
|
Прежде чем задать вопрос, подумай, хочешь ли ты
|
||||||
|
знать на него правдивый ответ...
|
||||||
|
</span>
|
||||||
|
<span style={{ fontSize: "small" }} className='d-flex align-items-center'>
|
||||||
|
<GeoAlt className='me-1' />
|
||||||
|
Ульяновск
|
||||||
|
</span>
|
||||||
|
<span style={{ fontSize: "small" }} className='d-flex align-items-center'>
|
||||||
|
<Calendar className='me-1' />
|
||||||
|
23.04.1998г.
|
||||||
|
</span>
|
||||||
|
<span style={{ fontSize: "small" }} className='d-flex align-items-center'>
|
||||||
|
<People className='me-1' />
|
||||||
|
234 друга
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div >
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default UserProfileBlock;
|
3
src/components/wrapper/wrapper.css
Normal file
3
src/components/wrapper/wrapper.css
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
.wrapper {
|
||||||
|
width: 100%;
|
||||||
|
}
|
18
src/components/wrapper/wrapper.jsx
Normal file
18
src/components/wrapper/wrapper.jsx
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
import PropTypes from 'prop-types';
|
||||||
|
import './wrapper.css';
|
||||||
|
|
||||||
|
const Wrapper = ({ children }) => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<div className="wrapper d-flex justify-content-center">
|
||||||
|
{children}
|
||||||
|
</div>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
|
Wrapper.propTypes = {
|
||||||
|
children: PropTypes.node,
|
||||||
|
};
|
||||||
|
|
||||||
|
export default Wrapper;
|
61
src/index.css
Normal file
61
src/index.css
Normal file
@ -0,0 +1,61 @@
|
|||||||
|
@font-face {
|
||||||
|
font-family: Roboto Slab;
|
||||||
|
src: url("/fonts/Roboto_Slab/RobotoSlab-VariableFont_wght.ttf");
|
||||||
|
}
|
||||||
|
|
||||||
|
:root {
|
||||||
|
color-scheme: light dark;
|
||||||
|
|
||||||
|
font-synthesis: none;
|
||||||
|
text-rendering: optimizeLegibility;
|
||||||
|
-webkit-font-smoothing: antialiased;
|
||||||
|
-moz-osx-font-smoothing: grayscale;
|
||||||
|
-webkit-text-size-adjust: 100%;
|
||||||
|
|
||||||
|
--color-darkblue: #235D70;
|
||||||
|
--color-blue: #5EB5F7;
|
||||||
|
--color-gray: #7F91A4;
|
||||||
|
--color-white: #F5F5F5;
|
||||||
|
--color-dark: #17212B;
|
||||||
|
--color-black: #0E1621;
|
||||||
|
--color-lightgray: #242F3D;
|
||||||
|
|
||||||
|
--light-background-color: var(--color-white);
|
||||||
|
--dark-background-color: var(--color-darkblue);
|
||||||
|
--dark-font-color: var(--color-white);
|
||||||
|
--light-font-color: var(--color-black);
|
||||||
|
--alternative-font-color: var(--color-black);
|
||||||
|
--alternative-backgrond-color: var(--light-background-color);
|
||||||
|
--hover-background-color: rgba(0, 0, 0, 0.08);
|
||||||
|
}
|
||||||
|
|
||||||
|
* {
|
||||||
|
font-family: Roboto Slab;
|
||||||
|
color: var(--light-font-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
body {
|
||||||
|
background-color: var(--light-background-color);
|
||||||
|
}
|
||||||
|
|
||||||
|
a {
|
||||||
|
text-decoration: none;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
@media (prefers-color-scheme: dark) {
|
||||||
|
:root {
|
||||||
|
--dark-background-color: var(--color-black);
|
||||||
|
--light-background-color: var(--color-lightgray);
|
||||||
|
--light-font-color: var(--color-white);
|
||||||
|
--dark-font-color: var(--color-white);
|
||||||
|
--alternative-font-color: var(--color-gray);
|
||||||
|
--alternative-backgrond-color: var(--color-black);
|
||||||
|
--hover-background-color: rgba(255, 255, 255, 0.2);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
.hoverable:hover {
|
||||||
|
background-color: var(--hover-background-color);
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
59
src/main.jsx
Normal file
59
src/main.jsx
Normal file
@ -0,0 +1,59 @@
|
|||||||
|
import 'bootstrap/dist/css/bootstrap.min.css'
|
||||||
|
import React from 'react'
|
||||||
|
import ReactDOM from 'react-dom/client'
|
||||||
|
import { RouterProvider, createBrowserRouter } from 'react-router-dom'
|
||||||
|
import ErrorPage from './pages/ErrorPage.jsx'
|
||||||
|
import FeedPage from './pages/FeedPage.jsx'
|
||||||
|
import UserProfilePage from './pages/UserProfilePage.jsx'
|
||||||
|
import ChatPage from './pages/ChatPage.jsx'
|
||||||
|
import FriendsPage from './pages/FriendsPage.jsx'
|
||||||
|
import App from './App.jsx'
|
||||||
|
import './index.css'
|
||||||
|
import { Person, LayoutTextSidebarReverse, ChatText, People } from 'react-bootstrap-icons';
|
||||||
|
|
||||||
|
const routes = [
|
||||||
|
{
|
||||||
|
index: true,
|
||||||
|
path: '/',
|
||||||
|
element: <FeedPage />,
|
||||||
|
title: 'Новости',
|
||||||
|
menuIcon: <LayoutTextSidebarReverse />,
|
||||||
|
showInBottomMenu: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/me',
|
||||||
|
element: <UserProfilePage />,
|
||||||
|
title: 'Моя страница',
|
||||||
|
menuIcon: <Person />,
|
||||||
|
showInBottomMenu: false
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/chat',
|
||||||
|
element: <ChatPage />,
|
||||||
|
title: 'Сообщения',
|
||||||
|
menuIcon: <ChatText />,
|
||||||
|
showInBottomMenu: true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/friends',
|
||||||
|
element: <FriendsPage />,
|
||||||
|
title: 'Друзья',
|
||||||
|
menuIcon: <People />,
|
||||||
|
showInBottomMenu: true
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
const router = createBrowserRouter([
|
||||||
|
{
|
||||||
|
path: '/',
|
||||||
|
element: <App routes={routes} />,
|
||||||
|
children: routes,
|
||||||
|
errorElement: <ErrorPage />,
|
||||||
|
},
|
||||||
|
]);
|
||||||
|
|
||||||
|
ReactDOM.createRoot(document.getElementById('root')).render(
|
||||||
|
<React.StrictMode>
|
||||||
|
<RouterProvider router={router} />
|
||||||
|
</React.StrictMode>,
|
||||||
|
)
|
23
src/pages/ChatPage.jsx
Normal file
23
src/pages/ChatPage.jsx
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
import Wrapper from "../components/wrapper/wrapper";
|
||||||
|
import Center from "../components/center/center";
|
||||||
|
import ChatRow from "../components/chatrow/chatrow";
|
||||||
|
|
||||||
|
const ChatPage = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<Wrapper>
|
||||||
|
<Center>
|
||||||
|
<ChatRow />
|
||||||
|
<ChatRow />
|
||||||
|
<ChatRow />
|
||||||
|
<ChatRow />
|
||||||
|
<ChatRow />
|
||||||
|
<ChatRow />
|
||||||
|
<ChatRow />
|
||||||
|
</Center>
|
||||||
|
</Wrapper>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default ChatPage;
|
19
src/pages/ErrorPage.jsx
Normal file
19
src/pages/ErrorPage.jsx
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
import { Alert, Button, Container } from 'react-bootstrap';
|
||||||
|
import { useNavigate } from 'react-router-dom';
|
||||||
|
|
||||||
|
const ErrorPage = () => {
|
||||||
|
const navigate = useNavigate();
|
||||||
|
|
||||||
|
return (
|
||||||
|
<Container fluid className="p-2 row justify-content-center">
|
||||||
|
<Container className='col-md-6'>
|
||||||
|
<Alert variant="danger">
|
||||||
|
Страница не найдена
|
||||||
|
</Alert>
|
||||||
|
<Button className="w-25 mt-2" variant="primary" onClick={() => navigate(-1)}>Назад</Button>
|
||||||
|
</Container>
|
||||||
|
</Container>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default ErrorPage
|
26
src/pages/FeedPage.jsx
Normal file
26
src/pages/FeedPage.jsx
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
import Wrapper from "../components/wrapper/wrapper";
|
||||||
|
import Center from "../components/center/center";
|
||||||
|
import PostInputForm from "../components/postinputform/postinputform";
|
||||||
|
import Post from "../components/post/post";
|
||||||
|
|
||||||
|
|
||||||
|
const FeedPage = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<Wrapper>
|
||||||
|
<Center>
|
||||||
|
<PostInputForm />
|
||||||
|
<div className="posts-wrapper">
|
||||||
|
<Post />
|
||||||
|
<Post />
|
||||||
|
<Post />
|
||||||
|
<Post />
|
||||||
|
<Post />
|
||||||
|
</div>
|
||||||
|
</Center>
|
||||||
|
</Wrapper>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default FeedPage;
|
25
src/pages/FriendsPage.jsx
Normal file
25
src/pages/FriendsPage.jsx
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
import Wrapper from "../components/wrapper/wrapper";
|
||||||
|
import Center from "../components/center/center";
|
||||||
|
import SearchGroup from "../components/searchgroup/searchgroup";
|
||||||
|
import FriendRow from "../components/friendrow/friendrow";
|
||||||
|
|
||||||
|
const FriendsPage = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<Wrapper>
|
||||||
|
<Center>
|
||||||
|
<SearchGroup />
|
||||||
|
<FriendRow />
|
||||||
|
<FriendRow />
|
||||||
|
<FriendRow />
|
||||||
|
<FriendRow />
|
||||||
|
<FriendRow />
|
||||||
|
<FriendRow />
|
||||||
|
<FriendRow />
|
||||||
|
</Center>
|
||||||
|
</Wrapper>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default FriendsPage;
|
27
src/pages/UserProfilePage.jsx
Normal file
27
src/pages/UserProfilePage.jsx
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
import Wrapper from "../components/wrapper/wrapper";
|
||||||
|
import Center from "../components/center/center";
|
||||||
|
import PostInputForm from "../components/postinputform/postinputform";
|
||||||
|
import Post from "../components/post/post";
|
||||||
|
import UserProfileBlock from "../components/userprofileblock/userprofileblock";
|
||||||
|
|
||||||
|
const UserProfilePage = () => {
|
||||||
|
return (
|
||||||
|
<>
|
||||||
|
<Wrapper>
|
||||||
|
<Center>
|
||||||
|
<UserProfileBlock />
|
||||||
|
<PostInputForm />
|
||||||
|
<div className="posts-wrapper">
|
||||||
|
<Post />
|
||||||
|
<Post />
|
||||||
|
<Post />
|
||||||
|
<Post />
|
||||||
|
<Post />
|
||||||
|
</div>
|
||||||
|
</Center>
|
||||||
|
</Wrapper>
|
||||||
|
</>
|
||||||
|
);
|
||||||
|
};
|
||||||
|
|
||||||
|
export default UserProfilePage;
|
7
vite.config.js
Normal file
7
vite.config.js
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
import { defineConfig } from 'vite'
|
||||||
|
import react from '@vitejs/plugin-react'
|
||||||
|
|
||||||
|
// https://vitejs.dev/config/
|
||||||
|
export default defineConfig({
|
||||||
|
plugins: [react()],
|
||||||
|
})
|
BIN
отчеты/ПИбд-21 Потапов отчет ИП лаб1.docx
Normal file
BIN
отчеты/ПИбд-21 Потапов отчет ИП лаб1.docx
Normal file
Binary file not shown.
BIN
отчеты/ПИбд-21 Потапов отчет ИП лаб2.docx
Normal file
BIN
отчеты/ПИбд-21 Потапов отчет ИП лаб2.docx
Normal file
Binary file not shown.
BIN
отчеты/ПИбд-21 Потапов отчет ИП лаб3.docx
Normal file
BIN
отчеты/ПИбд-21 Потапов отчет ИП лаб3.docx
Normal file
Binary file not shown.
BIN
отчеты/ПИбд-21 Потапов отчет ИП лаб4.docx
Normal file
BIN
отчеты/ПИбд-21 Потапов отчет ИП лаб4.docx
Normal file
Binary file not shown.
Loading…
Reference in New Issue
Block a user